content stringlengths 7 1.05M | fixed_cases stringlengths 1 1.28M |
|---|---|
class StaticRoute:
def __init__(self, interface_name, network_uuid, network_name, gateway_host):
self.static_route = {
"interfaceName": interface_name,
"selectedNetworks": [{"type": "Network", "overridable": False, "id": network_uuid, "name": network_name}],
"gateway": {"literal": {"type": "Host", "value": gateway_host}},
"metricValue": 1,
"type": "IPv4StaticRoute",
"isTunneled": False,
}
def to_json(self):
return self.static_route
| class Staticroute:
def __init__(self, interface_name, network_uuid, network_name, gateway_host):
self.static_route = {'interfaceName': interface_name, 'selectedNetworks': [{'type': 'Network', 'overridable': False, 'id': network_uuid, 'name': network_name}], 'gateway': {'literal': {'type': 'Host', 'value': gateway_host}}, 'metricValue': 1, 'type': 'IPv4StaticRoute', 'isTunneled': False}
def to_json(self):
return self.static_route |
N = int(input())
arr = list(map(int, input().split()))
tmp = [2] * len(arr)
for i in range(2, len(tmp)):
if not (arr[i - 2] <= arr[i - 1] and arr[i - 1] <= arr[i]) and not (arr[i - 2] >= arr[i - 1] and arr[i - 1] >= arr[i]):
tmp[i] = tmp[i - 1] + 1
print(max(tmp))
| n = int(input())
arr = list(map(int, input().split()))
tmp = [2] * len(arr)
for i in range(2, len(tmp)):
if not (arr[i - 2] <= arr[i - 1] and arr[i - 1] <= arr[i]) and (not (arr[i - 2] >= arr[i - 1] and arr[i - 1] >= arr[i])):
tmp[i] = tmp[i - 1] + 1
print(max(tmp)) |
#!/usr/bin/env python3
# https://codeforces.com/problemset/problem/1223/A
t = int(input())
for _ in range(t):
n = int(input())
print(n%2 if n>3 else 4-n)
| t = int(input())
for _ in range(t):
n = int(input())
print(n % 2 if n > 3 else 4 - n) |
# encoding: utf-8
__doc__ = 'Data Importer'
__version__ = '3.1.1'
__author__ = 'Valder Gallo <valdergallo@gmail.com>'
| __doc__ = 'Data Importer'
__version__ = '3.1.1'
__author__ = 'Valder Gallo <valdergallo@gmail.com>' |
S = input()
T = input()
count = 0
if S[0] == T[0]:
count += 1
if S[1] == T[1]:
count += 1
if S[2] == T[2]:
count += 1
print(count) | s = input()
t = input()
count = 0
if S[0] == T[0]:
count += 1
if S[1] == T[1]:
count += 1
if S[2] == T[2]:
count += 1
print(count) |
class Solution:
# @return an integer
def maxArea(self, height):
left = 0
right = len(height) - 1
max = 0
while left < right:
h = height[left]
if height[right] < h:
h = height[right]
s = ( right - left ) * h
if s > max:
max = s
if height[right] < height[left]:
right -= 1
else:
left += 1
return max
| class Solution:
def max_area(self, height):
left = 0
right = len(height) - 1
max = 0
while left < right:
h = height[left]
if height[right] < h:
h = height[right]
s = (right - left) * h
if s > max:
max = s
if height[right] < height[left]:
right -= 1
else:
left += 1
return max |
class AbstractConfigProvider:
"""
Abstract provider defining methods for loading and writing configuration.
for upto 3 levels:
root level: Defaults for totem for all clusters.
cluster level: Defaults for particular cluster.
organization level: Defaults for particular organization
repository: Defaults for particular repository
ref level: Defaults for particular tag or a branch
The implementation (like S3) must support multi level layout.
"""
def not_supported(self):
"""
Raises NotImplementedError with a message
:return:
"""
raise NotImplementedError(
'Provider: %s does not support this operation' % self.__class__)
def load(self, name, *paths):
"""
Load config at given path.
:param name: Name of the config to be loaded
:type name: str
:param paths: Tuple consisting of nested level path
:return: Parsed Config
:rtype: dict
:raise NotImplementedError: If provider does not support this method.
"""
self.not_supported()
def write(self, name, config, *paths):
"""
Writes config at given path.
:param name: Name of the config to be written
:type name: str
:param config: Configuration
:type config: dict
:param paths: Nested level path
:type paths: tuple
:return: None
:raise NotImplementedError: If provider does not support this method.
"""
self.not_supported()
def delete(self, name, *paths):
"""
Performs safe delete of the configuration at given path.
:param name: Name of the config to be deleted
:type name: str
:param paths: Nested level path
:type paths: tuple
:return: None
:raise NotImplementedError: If provider does not support this method.
"""
self.not_supported()
| class Abstractconfigprovider:
"""
Abstract provider defining methods for loading and writing configuration.
for upto 3 levels:
root level: Defaults for totem for all clusters.
cluster level: Defaults for particular cluster.
organization level: Defaults for particular organization
repository: Defaults for particular repository
ref level: Defaults for particular tag or a branch
The implementation (like S3) must support multi level layout.
"""
def not_supported(self):
"""
Raises NotImplementedError with a message
:return:
"""
raise not_implemented_error('Provider: %s does not support this operation' % self.__class__)
def load(self, name, *paths):
"""
Load config at given path.
:param name: Name of the config to be loaded
:type name: str
:param paths: Tuple consisting of nested level path
:return: Parsed Config
:rtype: dict
:raise NotImplementedError: If provider does not support this method.
"""
self.not_supported()
def write(self, name, config, *paths):
"""
Writes config at given path.
:param name: Name of the config to be written
:type name: str
:param config: Configuration
:type config: dict
:param paths: Nested level path
:type paths: tuple
:return: None
:raise NotImplementedError: If provider does not support this method.
"""
self.not_supported()
def delete(self, name, *paths):
"""
Performs safe delete of the configuration at given path.
:param name: Name of the config to be deleted
:type name: str
:param paths: Nested level path
:type paths: tuple
:return: None
:raise NotImplementedError: If provider does not support this method.
"""
self.not_supported() |
def banner_text(text=' ',screen_width=80):
"""
This will create a banner with text with the string and width provided.
example:
banner_text('*',10)
banner_text('Hello',10)
banner_text('*',10)
`int`
if no width is provided... it will default to 80
example:
banner_text('Hello world')
if neither string , nor width have been provided... it will print a blank line
"""
if len(text) > screen_width - 4:
raise ValueError(f'String {text} is larger than specified width {screen_width}')
if text == '*':
print('*'*screen_width)
else:
centred_text = text.center(screen_width - 4)
output_string = f"**{centred_text}**"
print(output_string)
# banner_text("*")
# banner_text("Hello from Python")
# banner_text()
# banner_text("This is Advik from india")
# banner_text("*") | def banner_text(text=' ', screen_width=80):
"""
This will create a banner with text with the string and width provided.
example:
banner_text('*',10)
banner_text('Hello',10)
banner_text('*',10)
`int`
if no width is provided... it will default to 80
example:
banner_text('Hello world')
if neither string , nor width have been provided... it will print a blank line
"""
if len(text) > screen_width - 4:
raise value_error(f'String {text} is larger than specified width {screen_width}')
if text == '*':
print('*' * screen_width)
else:
centred_text = text.center(screen_width - 4)
output_string = f'**{centred_text}**'
print(output_string) |
_base_ = [
'./_base_/default_runtime.py'
]
# dataset settings
dataset_type = 'Filelist'
img_norm_cfg = dict(
mean=[125.09, 102.01, 93.19],
std=[71.35, 63.75, 61.46],
to_rgb=True)
train_pipeline = [
# dict(type='RandomCrop', size=32, padding=4),
dict(type='LoadImageFromFile'),
dict(type='Resize', size=(512, -1)),
dict(type='RandomFlip', flip_prob=0.5, direction='horizontal'),
dict(type='Normalize', **img_norm_cfg),
dict(type='ImageToTensor', keys=['img']),
dict(type='ToTensor', keys=['gt_label']),
dict(type='Collect', keys=['img', 'gt_label'])
]
test_pipeline = [
dict(type='LoadImageFromFile'),
dict(type='Resize', size=(512, -1)),
dict(type='Normalize', **img_norm_cfg),
dict(type='ImageToTensor', keys=['img']),
dict(type='Collect', keys=['img']),
]
data = dict(
samples_per_gpu=16,
workers_per_gpu=2,
train=dict(
type=dataset_type, data_prefix='data/gender_1102',
ann_file='data/gender_1102/train.txt',
pipeline=train_pipeline,
classes=['male', 'female']),
val=dict(
type=dataset_type,
data_prefix='data/gender_1102',
ann_file='data/gender_1102/val.txt',
pipeline=test_pipeline,
test_mode=True,
classes=['male', 'female']),
test=dict(
type=dataset_type,
# data_prefix='data/cifar10',
pipeline=test_pipeline,
test_mode=True,
classes=['male', 'female']),
)
# model settings
model = dict(
type='ImageClassifier',
backbone=dict(type='MobileNetV3', arch='small'),
neck=dict(type='GlobalAveragePooling'),
head=dict(
type='StackedLinearClsHead',
num_classes=2,
in_channels=576,
mid_channels=[1280],
act_cfg=dict(type='HSwish'),
loss=dict(type='LabelSmoothLoss', label_smooth_val=0.1, loss_weight=1.0),
# loss=dict(type='CrossEntropyLoss', loss_weight=1.0),
topk=(1,)
),
)
load_from = 'https://download.openmmlab.com/mmclassification/v0/mobilenet_v3/convert/mobilenet_v3_small-8427ecf0.pth'
# optimizer
optimizer = dict(type='SGD', lr=0.001, momentum=0.9, weight_decay=0.0001)
optimizer_config = dict(grad_clip=None)
lr_config = dict(policy='step', step=[15, 25])
runner = dict(type='EpochBasedRunner', max_epochs=30)
| _base_ = ['./_base_/default_runtime.py']
dataset_type = 'Filelist'
img_norm_cfg = dict(mean=[125.09, 102.01, 93.19], std=[71.35, 63.75, 61.46], to_rgb=True)
train_pipeline = [dict(type='LoadImageFromFile'), dict(type='Resize', size=(512, -1)), dict(type='RandomFlip', flip_prob=0.5, direction='horizontal'), dict(type='Normalize', **img_norm_cfg), dict(type='ImageToTensor', keys=['img']), dict(type='ToTensor', keys=['gt_label']), dict(type='Collect', keys=['img', 'gt_label'])]
test_pipeline = [dict(type='LoadImageFromFile'), dict(type='Resize', size=(512, -1)), dict(type='Normalize', **img_norm_cfg), dict(type='ImageToTensor', keys=['img']), dict(type='Collect', keys=['img'])]
data = dict(samples_per_gpu=16, workers_per_gpu=2, train=dict(type=dataset_type, data_prefix='data/gender_1102', ann_file='data/gender_1102/train.txt', pipeline=train_pipeline, classes=['male', 'female']), val=dict(type=dataset_type, data_prefix='data/gender_1102', ann_file='data/gender_1102/val.txt', pipeline=test_pipeline, test_mode=True, classes=['male', 'female']), test=dict(type=dataset_type, pipeline=test_pipeline, test_mode=True, classes=['male', 'female']))
model = dict(type='ImageClassifier', backbone=dict(type='MobileNetV3', arch='small'), neck=dict(type='GlobalAveragePooling'), head=dict(type='StackedLinearClsHead', num_classes=2, in_channels=576, mid_channels=[1280], act_cfg=dict(type='HSwish'), loss=dict(type='LabelSmoothLoss', label_smooth_val=0.1, loss_weight=1.0), topk=(1,)))
load_from = 'https://download.openmmlab.com/mmclassification/v0/mobilenet_v3/convert/mobilenet_v3_small-8427ecf0.pth'
optimizer = dict(type='SGD', lr=0.001, momentum=0.9, weight_decay=0.0001)
optimizer_config = dict(grad_clip=None)
lr_config = dict(policy='step', step=[15, 25])
runner = dict(type='EpochBasedRunner', max_epochs=30) |
#! /usr/bin/env python2
#
# Copyright 2015 Google Inc. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
class Runner:
@staticmethod
def get_supported_languages():
"""
Returns:
[string]: list of supported languages
"""
return []
def run(self, test, env):
"""
Execute the test in a specified environment.
Args:
test (string): the test code
env (implementation specific): environment to run the test
Returns:
bool: result of the test
"""
raise NotImplementedError
| class Runner:
@staticmethod
def get_supported_languages():
"""
Returns:
[string]: list of supported languages
"""
return []
def run(self, test, env):
"""
Execute the test in a specified environment.
Args:
test (string): the test code
env (implementation specific): environment to run the test
Returns:
bool: result of the test
"""
raise NotImplementedError |
def parse_dict(args, attr, default_ok=True):
'''Parse an "nargs='*'" field from an ArgumentParser's parsed arguments
Each argument value should be of the form <k>=<v>, and a dict() of those mappings will be returned
At most one argument value can simply be of the form <v>, in which case it will be assigned to the None value in the returned dict
'''
arg = getattr(args, attr)
ret = {}
if isinstance(arg, list):
for entry in arg:
pcs = entry.split('=', 1)
if len(pcs) == 2:
[ repository, arg ] = pcs
ret[repository] = arg
elif len(pcs) == 1 and default_ok:
if None in ret:
raise ValueError(f'Invalid --{attr}: multiple default values ({ret[None]}, {pcs[0]})')
ret[None] = arg
else:
raise ValueError(f'Invalid --{attr}: {arg}')
return ret
| def parse_dict(args, attr, default_ok=True):
"""Parse an "nargs='*'" field from an ArgumentParser's parsed arguments
Each argument value should be of the form <k>=<v>, and a dict() of those mappings will be returned
At most one argument value can simply be of the form <v>, in which case it will be assigned to the None value in the returned dict
"""
arg = getattr(args, attr)
ret = {}
if isinstance(arg, list):
for entry in arg:
pcs = entry.split('=', 1)
if len(pcs) == 2:
[repository, arg] = pcs
ret[repository] = arg
elif len(pcs) == 1 and default_ok:
if None in ret:
raise value_error(f'Invalid --{attr}: multiple default values ({ret[None]}, {pcs[0]})')
ret[None] = arg
else:
raise value_error(f'Invalid --{attr}: {arg}')
return ret |
my_string = "abc"
id(my_string)
#Output = 22838720
"""
By checking the id of the object, we can determine that any time we assign a new value to the
variable, its identity changes.
"""
| my_string = 'abc'
id(my_string)
'\nBy checking the id of the object, we can determine that any time we assign a new value to the\nvariable, its identity changes.\n' |
#!/usr/bin/env python
# -*- coding: utf8 -*-
def echo(bot, update):
"""
Description: echoes the string that follows the command /echo.
Hand: command
"""
bot.sendMessage(update.message.chat_id, text=update.message.text[6:])
| def echo(bot, update):
"""
Description: echoes the string that follows the command /echo.
Hand: command
"""
bot.sendMessage(update.message.chat_id, text=update.message.text[6:]) |
# When we delete the max element and all elements to its right,
# the new max element must be the max before the deleted element was
# added to the array.
for case in range(int(input())):
N = int(input())
max_x, peaks = 0, 0
for x in map(int, input().split()):
if x > max_x:
max_x = x
peaks += 1
print('BOB' if peaks % 2 else 'ANDY')
| for case in range(int(input())):
n = int(input())
(max_x, peaks) = (0, 0)
for x in map(int, input().split()):
if x > max_x:
max_x = x
peaks += 1
print('BOB' if peaks % 2 else 'ANDY') |
def set_and_shift_values(big_muddy_io, values):
for value in values:
set_and_shift_single(big_muddy_io, value)
def set_and_shift_single(big_muddy_io, value):
big_muddy_io.set_data_pins(value)
big_muddy_io.shifting.pulse() | def set_and_shift_values(big_muddy_io, values):
for value in values:
set_and_shift_single(big_muddy_io, value)
def set_and_shift_single(big_muddy_io, value):
big_muddy_io.set_data_pins(value)
big_muddy_io.shifting.pulse() |
sizes = [
5000,
2353,
43234,
3634,
23421,
324,
23432,
2342,
2341
]
for i, value in enumerate(sizes):
sizes[i] = value * 0.3
print(sizes)
| sizes = [5000, 2353, 43234, 3634, 23421, 324, 23432, 2342, 2341]
for (i, value) in enumerate(sizes):
sizes[i] = value * 0.3
print(sizes) |
def main():
start, end = map(int, input().split())
hours = (end - start + 24) % 24
if hours == 0:
hours = 24
print('O JOGO DUROU {} HORA(S)'.format(hours))
if __name__ == '__main__':
main()
| def main():
(start, end) = map(int, input().split())
hours = (end - start + 24) % 24
if hours == 0:
hours = 24
print('O JOGO DUROU {} HORA(S)'.format(hours))
if __name__ == '__main__':
main() |
#https://www.acmicpc.net/problem/4673
a = [0 for i in range(10000)]
def d(n):
total = n
n10000 = n//10000
if n10000 != 0:
n -= 10000*n10000
n1000 = n//1000
if n1000 != 0:
n -= 1000*n1000
n100 = n//100
if n100 != 0:
n -= 100*n100
n10 = n//10
if n10 != 0:
n -= 10*n10
n1 = n
sum_num = total + n10000 + n1000 + n100 + n10 + n1
if sum_num <= 10000:
a[sum_num-1] = 1
for i in range(1, 10001):
d(i)
for idx, var in enumerate(a):
if var == 0:
print(idx+1) | a = [0 for i in range(10000)]
def d(n):
total = n
n10000 = n // 10000
if n10000 != 0:
n -= 10000 * n10000
n1000 = n // 1000
if n1000 != 0:
n -= 1000 * n1000
n100 = n // 100
if n100 != 0:
n -= 100 * n100
n10 = n // 10
if n10 != 0:
n -= 10 * n10
n1 = n
sum_num = total + n10000 + n1000 + n100 + n10 + n1
if sum_num <= 10000:
a[sum_num - 1] = 1
for i in range(1, 10001):
d(i)
for (idx, var) in enumerate(a):
if var == 0:
print(idx + 1) |
# Different versions of Bazel (e.g. 4.2.2 vs 5.0-pre) can output the query results
# in a different order. It does not appear to be possible to provide a value for
# `--order_output` to `genquery`. So, we will sort the results using this macro.
def sorted_genquery(name, expression, scope, testonly):
raw_query_name = name + "_raw"
native.genquery(
name = raw_query_name,
testonly = testonly,
expression = expression,
scope = scope,
)
native.genrule(
name = name,
srcs = [raw_query_name],
outs = [name],
testonly = testonly,
cmd = """\
# cat $(location {src}) | sort > $@
sort -o "$@" "$(location {src})"
""".format(src = raw_query_name),
)
| def sorted_genquery(name, expression, scope, testonly):
raw_query_name = name + '_raw'
native.genquery(name=raw_query_name, testonly=testonly, expression=expression, scope=scope)
native.genrule(name=name, srcs=[raw_query_name], outs=[name], testonly=testonly, cmd='# cat $(location {src}) | sort > $@\nsort -o "$@" "$(location {src})"\n'.format(src=raw_query_name)) |
def test_empty_build(flamingo_env):
flamingo_env.setup()
flamingo_env.build()
def test_basic_build(flamingo_env):
flamingo_env.write('/content/home.png', '1')
flamingo_env.write('/content/home-2.png', '2')
flamingo_env.write('/theme/static/test.css', '3')
flamingo_env.write('/content/home.rst', """
author: me
Home
====
Hello world
.. img:: home.png
""")
flamingo_env.build()
# there should be a cleaned title and something that seems like html
assert flamingo_env.read('/output/home.html').startswith('Home\n<')
assert flamingo_env.read('/output/media/home.png') == '1'
assert flamingo_env.read('/output/static/test.css') == '3'
# home-2.png is referenced, so it should not be part of the output
assert not flamingo_env.exists('/output/media/home-2.png')
def test_chardet(flamingo_env):
flamingo_env.settings.USE_CHARDET = True
flamingo_env.write('/content/home.html', """
index
""")
flamingo_env.build()
assert flamingo_env.read('/output/home.html').strip() == 'index'
| def test_empty_build(flamingo_env):
flamingo_env.setup()
flamingo_env.build()
def test_basic_build(flamingo_env):
flamingo_env.write('/content/home.png', '1')
flamingo_env.write('/content/home-2.png', '2')
flamingo_env.write('/theme/static/test.css', '3')
flamingo_env.write('/content/home.rst', '\n author: me\n\n\n Home\n ====\n\n Hello world\n\n .. img:: home.png\n ')
flamingo_env.build()
assert flamingo_env.read('/output/home.html').startswith('Home\n<')
assert flamingo_env.read('/output/media/home.png') == '1'
assert flamingo_env.read('/output/static/test.css') == '3'
assert not flamingo_env.exists('/output/media/home-2.png')
def test_chardet(flamingo_env):
flamingo_env.settings.USE_CHARDET = True
flamingo_env.write('/content/home.html', '\n\n\n index\n ')
flamingo_env.build()
assert flamingo_env.read('/output/home.html').strip() == 'index' |
segundos = int(input(""))
horas = segundos/3600
minutos = (segundos%3600)/60
segundos = (segundos%60)
print("%d:%d:%d" %(horas,minutos,segundos))
| segundos = int(input(''))
horas = segundos / 3600
minutos = segundos % 3600 / 60
segundos = segundos % 60
print('%d:%d:%d' % (horas, minutos, segundos)) |
class Solution:
def sortedSquares(self, nums: List[int]) -> List[int]:
leftIndex = 0
rightIndex = len(nums) - 1
result = [0] * len(nums)
resultIndex = len(nums) - 1
while leftIndex <= rightIndex:
if nums[leftIndex] ** 2 > nums[rightIndex] ** 2:
result[resultIndex] = nums[leftIndex] ** 2
leftIndex += 1
resultIndex -= 1
else:
result[resultIndex] = nums[rightIndex] ** 2
rightIndex -= 1
resultIndex -= 1
return result | class Solution:
def sorted_squares(self, nums: List[int]) -> List[int]:
left_index = 0
right_index = len(nums) - 1
result = [0] * len(nums)
result_index = len(nums) - 1
while leftIndex <= rightIndex:
if nums[leftIndex] ** 2 > nums[rightIndex] ** 2:
result[resultIndex] = nums[leftIndex] ** 2
left_index += 1
result_index -= 1
else:
result[resultIndex] = nums[rightIndex] ** 2
right_index -= 1
result_index -= 1
return result |
#!/usr/bin/python3
def new_in_list(my_list, idx, element):
if idx < 0 or (len(my_list) - 1) < idx:
return (my_list)
new_list = my_list.copy()
new_list[idx] = element
return (new_list)
| def new_in_list(my_list, idx, element):
if idx < 0 or len(my_list) - 1 < idx:
return my_list
new_list = my_list.copy()
new_list[idx] = element
return new_list |
class Exchange(object):
def __init__(self, name, asset_types, country_code):
'''
Parameters
----------
name : str
asset_types : list
country_code : str
'''
self._name = name
self._asset_types = asset_types
self._country_code = country_code
| class Exchange(object):
def __init__(self, name, asset_types, country_code):
"""
Parameters
----------
name : str
asset_types : list
country_code : str
"""
self._name = name
self._asset_types = asset_types
self._country_code = country_code |
def summa1(jarjend):
tulemus = jarjend[0]
if isinstance(jarjend[1], int):
tulemus += jarjend[1]
else:
tulemus += summa1(jarjend[1])
return tulemus
def summa2(jarjend):
tulemus = jarjend[0]
while isinstance(jarjend[1], list):
jarjend = jarjend[1]
tulemus += jarjend[0]
tulemus += jarjend[1]
return tulemus | def summa1(jarjend):
tulemus = jarjend[0]
if isinstance(jarjend[1], int):
tulemus += jarjend[1]
else:
tulemus += summa1(jarjend[1])
return tulemus
def summa2(jarjend):
tulemus = jarjend[0]
while isinstance(jarjend[1], list):
jarjend = jarjend[1]
tulemus += jarjend[0]
tulemus += jarjend[1]
return tulemus |
line_input1, line_input2 = sorted(input().split(), key=lambda x: -len(x))
result = 0
for ch in range(len(line_input1)):
if ch < len(line_input2):
result += (ord(line_input1[ch]) * ord(line_input2[ch]))
else:
result += ord(line_input1[ch])
print(result)
| (line_input1, line_input2) = sorted(input().split(), key=lambda x: -len(x))
result = 0
for ch in range(len(line_input1)):
if ch < len(line_input2):
result += ord(line_input1[ch]) * ord(line_input2[ch])
else:
result += ord(line_input1[ch])
print(result) |
pyliterals = {
'for': 'The Loop King',
'if': 'The Conditional Master',
'tuple': 'Too Stubborn to be changed',
'list': 'As free as water',
'dictionary': 'Emperor of Information Storage'
}
for literal in pyliterals:
print(literal+": "+pyliterals[literal]+"\n") | pyliterals = {'for': 'The Loop King', 'if': 'The Conditional Master', 'tuple': 'Too Stubborn to be changed', 'list': 'As free as water', 'dictionary': 'Emperor of Information Storage'}
for literal in pyliterals:
print(literal + ': ' + pyliterals[literal] + '\n') |
# -*- coding: utf-8 -*-
# Copyright (c) 2019, Silvio Peroni <essepuntato@gmail.com>
#
# Permission to use, copy, modify, and/or distribute this software for any purpose
# with or without fee is hereby granted, provided that the above copyright notice
# and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
# FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT,
# OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
# DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
# ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
# SOFTWARE.
def f(cur_digit):
c_list = list()
c_list.append("a")
c_list.append("b")
c_list.extend(c_list)
c_list.extend(c_list)
c_list.append("c")
for i in range(cur_digit):
if c_list[i] != "a" and "a" in c_list:
c_list.remove("a")
else:
c_list.insert(i, "c")
return c_list
my_digit = int(input("Please provide an integer number from 0 to 9: ").strip())
print("Result:", f(my_digit))
| def f(cur_digit):
c_list = list()
c_list.append('a')
c_list.append('b')
c_list.extend(c_list)
c_list.extend(c_list)
c_list.append('c')
for i in range(cur_digit):
if c_list[i] != 'a' and 'a' in c_list:
c_list.remove('a')
else:
c_list.insert(i, 'c')
return c_list
my_digit = int(input('Please provide an integer number from 0 to 9: ').strip())
print('Result:', f(my_digit)) |
class Solution:
# @return a list of lists of integers
def generate(self, numRows):
if numRows < 1:
return []
result = [[1]]
for i in range(numRows - 1):
tri = [1]
result.append(tri)
preTri = result[len(result) - 2]
for j in range(len(preTri) - 1):
tri.append(preTri[j] + preTri[j + 1])
tri.append(1)
return result | class Solution:
def generate(self, numRows):
if numRows < 1:
return []
result = [[1]]
for i in range(numRows - 1):
tri = [1]
result.append(tri)
pre_tri = result[len(result) - 2]
for j in range(len(preTri) - 1):
tri.append(preTri[j] + preTri[j + 1])
tri.append(1)
return result |
# -*- coding: utf-8 -*-
class GildedRose(object):
MAX_QUALITY = 50
MIN_QUALITY = 0
def __init__(self, items):
self.items = items
def update_quality_brie(self, item):
item.sell_in -= 1
item.quality = min(self.MAX_QUALITY, item.quality +1 )
def update_quality_backstage(self, item):
item.sell_in -= 1
if item.sell_in >= 10:
item.quality = min(self.MAX_QUALITY, item.quality +1 )
elif item.sell_in >= 5:
item.quality = min(self.MAX_QUALITY, item.quality +2 )
elif item.sell_in >= 0:
item.quality = min(self.MAX_QUALITY, item.quality +3 )
else:
item.quality = self.MIN_QUALITY
def update_quality_conjured(self, item):
item.sell_in -= 1
if item.sell_in < 0:
# passed sell-in degrades 4 point per day
item.quality = max(self.MIN_QUALITY, item.quality -4 )
else:
item.quality = max(self.MIN_QUALITY, item.quality -2 )
def update_quality_standard(self, item):
item.sell_in -= 1
if item.sell_in < 0:
item.quality = max(self.MIN_QUALITY, item.quality -2 )
else:
item.quality = max(self.MIN_QUALITY, item.quality -1 )
def update_quality(self):
for item in self.items:
if item.name == item.BRIE:
self.update_quality_brie(item)
elif item.name == item.BACKSTAGE:
self.update_quality_backstage(item)
elif item.name == item.CONJURED:
self.update_quality_conjured(item)
elif item.name != item.SULFURAS:
self.update_quality_standard(item)
# for SULFURAS do nothing!
class Item:
SULFURAS = "Sulfuras, Hand of Ragnaros"
BACKSTAGE = "Backstage passes to a TAFKAL80ETC concert"
BRIE = "Aged Brie"
CONJURED = "Conjured Mana Cake"
def __init__(self, name, sell_in, quality):
self.name = name
self.sell_in = sell_in
self.quality = quality
def __repr__(self):
return "%s, %s, %s" % (self.name, self.sell_in, self.quality)
| class Gildedrose(object):
max_quality = 50
min_quality = 0
def __init__(self, items):
self.items = items
def update_quality_brie(self, item):
item.sell_in -= 1
item.quality = min(self.MAX_QUALITY, item.quality + 1)
def update_quality_backstage(self, item):
item.sell_in -= 1
if item.sell_in >= 10:
item.quality = min(self.MAX_QUALITY, item.quality + 1)
elif item.sell_in >= 5:
item.quality = min(self.MAX_QUALITY, item.quality + 2)
elif item.sell_in >= 0:
item.quality = min(self.MAX_QUALITY, item.quality + 3)
else:
item.quality = self.MIN_QUALITY
def update_quality_conjured(self, item):
item.sell_in -= 1
if item.sell_in < 0:
item.quality = max(self.MIN_QUALITY, item.quality - 4)
else:
item.quality = max(self.MIN_QUALITY, item.quality - 2)
def update_quality_standard(self, item):
item.sell_in -= 1
if item.sell_in < 0:
item.quality = max(self.MIN_QUALITY, item.quality - 2)
else:
item.quality = max(self.MIN_QUALITY, item.quality - 1)
def update_quality(self):
for item in self.items:
if item.name == item.BRIE:
self.update_quality_brie(item)
elif item.name == item.BACKSTAGE:
self.update_quality_backstage(item)
elif item.name == item.CONJURED:
self.update_quality_conjured(item)
elif item.name != item.SULFURAS:
self.update_quality_standard(item)
class Item:
sulfuras = 'Sulfuras, Hand of Ragnaros'
backstage = 'Backstage passes to a TAFKAL80ETC concert'
brie = 'Aged Brie'
conjured = 'Conjured Mana Cake'
def __init__(self, name, sell_in, quality):
self.name = name
self.sell_in = sell_in
self.quality = quality
def __repr__(self):
return '%s, %s, %s' % (self.name, self.sell_in, self.quality) |
class GenericRecordError(Exception):
pass
class ValidationError(GenericRecordError):
pass
class TableNotSupported(GenericRecordError):
pass
class DuplicateSignature(GenericRecordError):
pass
class GenericVBRError(Exception):
pass
class ConnectionFailedError(GenericVBRError):
pass
class RecordNotFoundError(GenericVBRError):
pass
class NotUniqueError(GenericVBRError):
pass
| class Genericrecorderror(Exception):
pass
class Validationerror(GenericRecordError):
pass
class Tablenotsupported(GenericRecordError):
pass
class Duplicatesignature(GenericRecordError):
pass
class Genericvbrerror(Exception):
pass
class Connectionfailederror(GenericVBRError):
pass
class Recordnotfounderror(GenericVBRError):
pass
class Notuniqueerror(GenericVBRError):
pass |
class DBSPEC(object):
TB_CHECKIN = "bk_checkin"
TB_USER = "bk_user"
TB_FRIENDSHIP = "bk_friendship"
| class Dbspec(object):
tb_checkin = 'bk_checkin'
tb_user = 'bk_user'
tb_friendship = 'bk_friendship' |
# Copyright (c) 2001-2013, Scott D. Peckham
#
#-----------------------------------------------------------------------
#
# unit_test()
#
#-----------------------------------------------------------------------
def unit_test( n_steps=10 ):
c = erosion_component()
c.CCA = False
c.DEBUG = False
c.SILENT = True # (now the default in CSDMS_base.py)
## c.DEBUG = True
## c.SILENT = False
## c.REPORT = True
#-------------------------------------------------
# NOTE: The Treynor_Iowa DEM has no depressions!
#-------------------------------------------------
## directory = tf_utils.TF_Test_Directory()
## site_prefix = tf_utils.TF_Test_Site_Prefix()
## case_prefix = tf_utils.TF_Test_Case_Prefix()
#-----------------------------------
# Use these when running on Mac.
#-----------------------------------
## cfg_directory = '/Applications/Erode/Data/Test_50x50/'
## cfg_prefix = 'Test'
## cfg_directory = '/Applications/Erode/Data/Test_100x100/'
## cfg_prefix = 'Test'
## cfg_directory = '/Applications/Erode/Data/Test_200x200/'
## cfg_prefix = 'Test'
## cfg_directory = '/Applications/Erode/Data/Test_400x400/'
## cfg_prefix = 'Test'
# These next few are obsolete now.
## cfg_directory = '/Applications/Erode/Data/Test2/'
## ## cfg_directory = '/data/sims/erode/3.1/Test2/'
## cfg_prefix = 'Test2'
## cfg_directory = '/Applications/Erode/Data/Test4/' # (80x80, 11/8/10)
## cfg_prefix = 'Test4'
## cfg_directory = '/Applications/Erode/Data/Test2B/' # (50x50, 11/8/10)
## cfg_prefix = 'Test2B'
## cfg_directory = '/Applications/Erode/Data/Test3/' # (20x20)
## ## cfg_directory = '/data/sims/erode/3.1/Test3/'
## cfg_prefix = 'Test3'
#------------------------------------------------
# Use this when running on beach, but copy into
# a separate sub directory when finished.
#------------------------------------------------
cfg_directory = '/home/beach/faculty/peckhams/CMT_Output/Erode_Global/'
cfg_prefix = 'Test'
## cfg_directory = '/home/beach/faculty/peckhams/ERODE3/Tests/Test_100x100/' # (9/1/11)
## cfg_prefix = 'Test'
## cfg_directory = '/home/beach/faculty/peckhams/ERODE3/Tests/Test_200x200/' # (10/4/11)
## cfg_prefix = 'Test'
## cfg_directory = '/home/beach/faculty/peckhams/ERODE3/Test_400x400/' # (10/4/11)
## cfg_prefix = 'Test'
#--------------------------------------------------------
# Note: CSDMS_base.run_model() changes to cfg_directory
#--------------------------------------------------------
c.run_model( cfg_directory=cfg_directory,
cfg_prefix=cfg_prefix,
n_steps=n_steps )
#-------------------------------------------
# Call initialize() and call update() once
#-------------------------------------------
## print 'STATUS =', c.get_status()
## c.initialize(cfg_prefix=cfg_prefix, mode="driver")
## print 'STATUS =', c.get_status()
## time = float64(0)
## c.update(time)
## print 'STATUS =', c.get_status()
# unit_test()
#-----------------------------------------------------------------------
| def unit_test(n_steps=10):
c = erosion_component()
c.CCA = False
c.DEBUG = False
c.SILENT = True
cfg_directory = '/home/beach/faculty/peckhams/CMT_Output/Erode_Global/'
cfg_prefix = 'Test'
c.run_model(cfg_directory=cfg_directory, cfg_prefix=cfg_prefix, n_steps=n_steps) |
def all_clans():
return {
'Legendary Monks':'#PCCUPG9R',
'SN JAIN':'#2029V92QV',
'Brute Force':'#22PQL2L0R',
'PBfPN':'#22QL8YUC8',
'Wookies':'#298092P99',
'Mini Matter':'#2PJYCQYV9',
'Endor':'#2YLL8UVPY',
'Mos Eisley':'#2YUVPQQCU',
'Killer_Black_Wf':'#8VQYR2LR',
'Golden Clan':'#C2QPR82Q',
'Optimus Prime*':'#JR8CQRR',
'PETARUNG SEJATI':'#PCP02V8C',
'Dark Matter':'#Q2VYY8C8',
'barudak sunda':'#RRJ02JGC',
'Sheer Force':'#VUCVG2J0',
'UnitedAsOne':'#YVPVGPP2',
'ReqReceiveN WAR':'#J2PVJ2GU',
'ONE KINGS':'#P9C8YJRQ',
'Mini Matter':'#2PJYCQYV9',
}
| def all_clans():
return {'Legendary Monks': '#PCCUPG9R', 'SN JAIN': '#2029V92QV', 'Brute Force': '#22PQL2L0R', 'PBfPN': '#22QL8YUC8', 'Wookies': '#298092P99', 'Mini Matter': '#2PJYCQYV9', 'Endor': '#2YLL8UVPY', 'Mos Eisley': '#2YUVPQQCU', 'Killer_Black_Wf': '#8VQYR2LR', 'Golden Clan': '#C2QPR82Q', 'Optimus Prime*': '#JR8CQRR', 'PETARUNG SEJATI': '#PCP02V8C', 'Dark Matter': '#Q2VYY8C8', 'barudak sunda': '#RRJ02JGC', 'Sheer Force': '#VUCVG2J0', 'UnitedAsOne': '#YVPVGPP2', 'ReqReceiveN WAR': '#J2PVJ2GU', 'ONE KINGS': '#P9C8YJRQ', 'Mini Matter': '#2PJYCQYV9'} |
"""
URL: https://codeforces.com/problemset/problem/1206/B
Author: Safiul Kabir [safiulanik at gmail.com]
Tags: dp, implementation, *900
"""
n = int(input())
a = map(int, input().split())
move_count, count_gtz, count_ltz, count_zero = 0, 0, 0, 0
for i in a:
if i == 0:
count_zero += 1
elif i > 0:
count_gtz += 1
move_count += i - 1
else:
count_ltz += 1
move_count += abs(i - -1)
if count_ltz % 2 == 0:
move_count += count_zero
else:
if count_zero > 0:
move_count += count_zero
else:
move_count += 2
print(move_count)
| """
URL: https://codeforces.com/problemset/problem/1206/B
Author: Safiul Kabir [safiulanik at gmail.com]
Tags: dp, implementation, *900
"""
n = int(input())
a = map(int, input().split())
(move_count, count_gtz, count_ltz, count_zero) = (0, 0, 0, 0)
for i in a:
if i == 0:
count_zero += 1
elif i > 0:
count_gtz += 1
move_count += i - 1
else:
count_ltz += 1
move_count += abs(i - -1)
if count_ltz % 2 == 0:
move_count += count_zero
elif count_zero > 0:
move_count += count_zero
else:
move_count += 2
print(move_count) |
img_size = (992, 736)
img_norm_cfg = dict(mean=[0, 0, 0], std=[255, 255, 255], to_rgb=True)
train_pipeline = [
dict(type='LoadImageFromFile'),
dict(type='LoadAnnotations', with_bbox=True),
dict(
type='MinIoURandomCrop',
min_ious=(0.1, 0.3, 0.5, 0.7, 0.9),
min_crop_size=0.3),
dict(
type='Resize',
img_scale=[(992, 736), (896, 736), (1088, 736), (992, 672), (992, 800)],
multiscale_mode='value',
keep_ratio=False),
dict(type='RandomFlip', flip_ratio=0.5),
dict(type='Normalize', **img_norm_cfg),
dict(type='DefaultFormatBundle'),
dict(type='Collect', keys=['img', 'gt_bboxes', 'gt_labels'])
]
test_pipeline = [
dict(type='LoadImageFromFile'),
dict(
type='MultiScaleFlipAug',
img_scale=img_size,
flip=False,
transforms=[
dict(type='Resize', keep_ratio=False),
dict(type='RandomFlip'),
dict(type='Normalize', **img_norm_cfg),
dict(type='ImageToTensor', keys=['img']),
dict(type='Collect', keys=['img'])
])
]
| img_size = (992, 736)
img_norm_cfg = dict(mean=[0, 0, 0], std=[255, 255, 255], to_rgb=True)
train_pipeline = [dict(type='LoadImageFromFile'), dict(type='LoadAnnotations', with_bbox=True), dict(type='MinIoURandomCrop', min_ious=(0.1, 0.3, 0.5, 0.7, 0.9), min_crop_size=0.3), dict(type='Resize', img_scale=[(992, 736), (896, 736), (1088, 736), (992, 672), (992, 800)], multiscale_mode='value', keep_ratio=False), dict(type='RandomFlip', flip_ratio=0.5), dict(type='Normalize', **img_norm_cfg), dict(type='DefaultFormatBundle'), dict(type='Collect', keys=['img', 'gt_bboxes', 'gt_labels'])]
test_pipeline = [dict(type='LoadImageFromFile'), dict(type='MultiScaleFlipAug', img_scale=img_size, flip=False, transforms=[dict(type='Resize', keep_ratio=False), dict(type='RandomFlip'), dict(type='Normalize', **img_norm_cfg), dict(type='ImageToTensor', keys=['img']), dict(type='Collect', keys=['img'])])] |
global edge_id
edge_id = 0
class Edge:
def __init__(self, source, target, weight=1):
global edge_id
self.id = edge_id
edge_id += 1
self.source = source
self.target = target
self.weight = weight
| global edge_id
edge_id = 0
class Edge:
def __init__(self, source, target, weight=1):
global edge_id
self.id = edge_id
edge_id += 1
self.source = source
self.target = target
self.weight = weight |
def main():
# input
N = int(input())
A = list(map(int, input().split()))
B = list(map(int, input().split()))
C = list(map(int, input().split()))
# compute
DA = [0]*N
DBC =[0]*N
for i in range(N):
DA[A[i]-1] += 1
for i in range(N):
DBC[B[C[i]-1]-1] += 1
s = 0
for i in range(N):
s += DA[i]*DBC[i]
# output
print(s)
if __name__ == '__main__':
main()
| def main():
n = int(input())
a = list(map(int, input().split()))
b = list(map(int, input().split()))
c = list(map(int, input().split()))
da = [0] * N
dbc = [0] * N
for i in range(N):
DA[A[i] - 1] += 1
for i in range(N):
DBC[B[C[i] - 1] - 1] += 1
s = 0
for i in range(N):
s += DA[i] * DBC[i]
print(s)
if __name__ == '__main__':
main() |
"""List of API endpoints for OPEN XBL."""
API_PATH = {
"account": "/account",
"account_xuid": "/account/{xuid}",
"achievements": "/achievements",
"achievements_game": "/achievements/title/{titleId}",
"achievements_game_xuid": "/achievements/player/{xuid}/title/{titleid}",
"achievements_history": "/achievements/{titleId}",
"achievements_xuid": "/achievements/player/{xuid}",
"activity_feed": "/activity/feed",
"activity_history": "/activity/history",
"alerts": "/alerts",
"club_recommendations": "/clubs/recommendations",
"club_summary": "/clubs/{clubId}",
"clubs_create": "/clubs/create",
"clubs_owned": "/clubs/owned",
"clubs_reserve": "/clubs/reserve",
"clubs_search": "/clubs/find",
"conversation_requests": "/conversations/requests",
"conversations": "/conversations",
"conversations_xuid": "/conversations/{xuid}",
"dvr_gameclips": "/dvr/gameclips",
"dvr_gameclips_delete": "/dvr/gameclips/delete/{{GameContentID}}",
"dvr_screenshots": "/dvr/screenshots",
"friends": "/friends",
"friends_add": "/friends/add/{xuid}",
"friends_favorite": "/friends/favorite",
"friends_favorite_remove": "/friends/favorite/remove",
"friends_remove": "/friends/remove/{xuid}",
"friends_search": "/friends/search",
"friends_xuid": "/friends",
"generate_gamertag": "/generate/gamertag",
"group": "/group",
"group_create": "/group/create",
"group_invite": "/group/invite/voice",
"group_kick": "/group/kick",
"group_leave": "/group/leave",
"group_messages": "/group/messages/{group id}",
"group_rename": "/group/rename",
"group_send": "/group/send",
"group_summary": "/group/summary/{group id}",
"party": "/party",
"party_invite": "/party/invite/{sessionId/scid}",
"player_summary": "/player/summary",
"presence": "/presence",
"presence_xuid": "/{xuid}/presence",
"recent_players": "/recent-players",
"stats_game": "/achievements/stats/{titleId}",
}
| """List of API endpoints for OPEN XBL."""
api_path = {'account': '/account', 'account_xuid': '/account/{xuid}', 'achievements': '/achievements', 'achievements_game': '/achievements/title/{titleId}', 'achievements_game_xuid': '/achievements/player/{xuid}/title/{titleid}', 'achievements_history': '/achievements/{titleId}', 'achievements_xuid': '/achievements/player/{xuid}', 'activity_feed': '/activity/feed', 'activity_history': '/activity/history', 'alerts': '/alerts', 'club_recommendations': '/clubs/recommendations', 'club_summary': '/clubs/{clubId}', 'clubs_create': '/clubs/create', 'clubs_owned': '/clubs/owned', 'clubs_reserve': '/clubs/reserve', 'clubs_search': '/clubs/find', 'conversation_requests': '/conversations/requests', 'conversations': '/conversations', 'conversations_xuid': '/conversations/{xuid}', 'dvr_gameclips': '/dvr/gameclips', 'dvr_gameclips_delete': '/dvr/gameclips/delete/{{GameContentID}}', 'dvr_screenshots': '/dvr/screenshots', 'friends': '/friends', 'friends_add': '/friends/add/{xuid}', 'friends_favorite': '/friends/favorite', 'friends_favorite_remove': '/friends/favorite/remove', 'friends_remove': '/friends/remove/{xuid}', 'friends_search': '/friends/search', 'friends_xuid': '/friends', 'generate_gamertag': '/generate/gamertag', 'group': '/group', 'group_create': '/group/create', 'group_invite': '/group/invite/voice', 'group_kick': '/group/kick', 'group_leave': '/group/leave', 'group_messages': '/group/messages/{group id}', 'group_rename': '/group/rename', 'group_send': '/group/send', 'group_summary': '/group/summary/{group id}', 'party': '/party', 'party_invite': '/party/invite/{sessionId/scid}', 'player_summary': '/player/summary', 'presence': '/presence', 'presence_xuid': '/{xuid}/presence', 'recent_players': '/recent-players', 'stats_game': '/achievements/stats/{titleId}'} |
#This is given a list of mutations, and get the read names that contain the mutation
#Note: We use the CS tag in the alignments, thus each alignment should contain this tag.
class ReadsTracer():
def __init__(self):
pass
#
def trace_reads_from_mutation(self):
pass
#only catch mismatch here
def parse_snp_from_CS_tag(self, i_start_pos, s_CS_tag):
pass
| class Readstracer:
def __init__(self):
pass
def trace_reads_from_mutation(self):
pass
def parse_snp_from_cs_tag(self, i_start_pos, s_CS_tag):
pass |
code ={
"CONTINUE":100,
"SWITCHING_PROTOCOLS":101,
"PROCESSING":101,
"OK":200,
"CREATED":201,
"ACCEPTED":202,
"NON_AUTHORITATIVE_INFORMATION":203,
"NO_CONTENT":204,
"RESET_CONTENT":205,
"PARTIAL_CONTENT":206,
"MULTI_STATUS":207,
"ALREADY_REPORTED":208,
"IM_USED":226,
"MULTIPLE_CHOICES":300,
"MOVED_PERMANENTLY":301,
"FOUND":302,
"SEE_OTHER":303,
"NOT_MODIFIED":304,
"USE_PROXY":305,
"TEMPORARY_REDIRECT":307,
"PERMANENT_REDIRECT":308,
"BAD_REQUEST":400,
"UNAUTHORIZED":401,
"PAYMENT_REQUIRED":402,
"FORBIDDEN":403,
"NOT_FOUND":404,
"METHOD_NOT_ALLOWED":405,
"NOT_ACCEPTABLE":406,
"PROXY_AUTHENTICATION_REQUIRED":407,
"REQUEST_TIMEOUT":408,
"CONFLICT":409,
"GONE":410,
"LENGTH_REQUIRED":411,
"PRECONDITION_FAILED":412,
"REQUEST_ENTITY_TOO_LARGE":413,
"REQUEST_URI_TOO_LONG":414,
"UNSUPPORTED_MEDIA_TYPE":415,
"REQUEST_RANGE_NOT_SATISFIABLE":416,
"EXPECTATION_FAILED":417,
"UNPROCESSABLE_ENTITY":422,
"LOCKED":423,
"FAILED_DEPENDENCY":424,
"UPGRADE_REQUIRED":426,
"PRECONDITION_REQUIRED":428,
"TOO_MANY_REQUESTS":429,
"REQUEST_HEADER_FIELDS_TOO_LARGE":431,
"INTERNAL_SERVER_ERROR":500,
"NOT_IMPLEMENTED":501,
"BAD_GATEWAY":502,
"SERVICE_UNAVAILABLE":503,
"GATEWAY_TIMEOUT":504,
"HTTP_VERSION_NOT_SUPPORTED":505,
"VARIANT_ALSO_NEGOTIATES":506,
"INSUFFICIENT_STORAGE":507,
"LOOP_DETECTED":508,
"NOT_EXTENDED":510,
"NETWORK_AUTHENTICATION_REQUIRED":511
}
| code = {'CONTINUE': 100, 'SWITCHING_PROTOCOLS': 101, 'PROCESSING': 101, 'OK': 200, 'CREATED': 201, 'ACCEPTED': 202, 'NON_AUTHORITATIVE_INFORMATION': 203, 'NO_CONTENT': 204, 'RESET_CONTENT': 205, 'PARTIAL_CONTENT': 206, 'MULTI_STATUS': 207, 'ALREADY_REPORTED': 208, 'IM_USED': 226, 'MULTIPLE_CHOICES': 300, 'MOVED_PERMANENTLY': 301, 'FOUND': 302, 'SEE_OTHER': 303, 'NOT_MODIFIED': 304, 'USE_PROXY': 305, 'TEMPORARY_REDIRECT': 307, 'PERMANENT_REDIRECT': 308, 'BAD_REQUEST': 400, 'UNAUTHORIZED': 401, 'PAYMENT_REQUIRED': 402, 'FORBIDDEN': 403, 'NOT_FOUND': 404, 'METHOD_NOT_ALLOWED': 405, 'NOT_ACCEPTABLE': 406, 'PROXY_AUTHENTICATION_REQUIRED': 407, 'REQUEST_TIMEOUT': 408, 'CONFLICT': 409, 'GONE': 410, 'LENGTH_REQUIRED': 411, 'PRECONDITION_FAILED': 412, 'REQUEST_ENTITY_TOO_LARGE': 413, 'REQUEST_URI_TOO_LONG': 414, 'UNSUPPORTED_MEDIA_TYPE': 415, 'REQUEST_RANGE_NOT_SATISFIABLE': 416, 'EXPECTATION_FAILED': 417, 'UNPROCESSABLE_ENTITY': 422, 'LOCKED': 423, 'FAILED_DEPENDENCY': 424, 'UPGRADE_REQUIRED': 426, 'PRECONDITION_REQUIRED': 428, 'TOO_MANY_REQUESTS': 429, 'REQUEST_HEADER_FIELDS_TOO_LARGE': 431, 'INTERNAL_SERVER_ERROR': 500, 'NOT_IMPLEMENTED': 501, 'BAD_GATEWAY': 502, 'SERVICE_UNAVAILABLE': 503, 'GATEWAY_TIMEOUT': 504, 'HTTP_VERSION_NOT_SUPPORTED': 505, 'VARIANT_ALSO_NEGOTIATES': 506, 'INSUFFICIENT_STORAGE': 507, 'LOOP_DETECTED': 508, 'NOT_EXTENDED': 510, 'NETWORK_AUTHENTICATION_REQUIRED': 511} |
"""
A file to contain helper functions.
"""
def get_answer():
"""Get an answer."""
return True
| """
A file to contain helper functions.
"""
def get_answer():
"""Get an answer."""
return True |
#lovely lovesea descriotion
lovely_loveseat_description = """ Lovely Loveseat. Tufted polyester blend on wood. 32 inches high x 40 inches wide x inches deep. Red or white"""
lovely_loveseat_price = 254.00
#Stylish settee
stylish_sette_description = """ Stylish settee. Faux leaather on brich. 29.50 inches high x 54.75 inches wide x 28 inches deep. Black."""
Stylist_settee_price = 180.50
#luxurious lamp
luxurious_lamp_description = """ Luxurious Lamp. Glass and iron.36 inches tall.brown with cream shade."""
luxurious_lamp_price = 52.15
#sale tax
sales_tax = 0.88
customer_one_total = 0
customer_one_itemization = ""
# customer one shoppping
customer_one_total += lovely_loveseat_price
customer_one_itemization = lovely_loveseat_description
customer_one_total += luxurious_lamp_price
customer_one_itemization = "\n"+ lovely_loveseat_description + "\n " + luxurious_lamp_description
customer_one_tax = customer_one_total * sales_tax
customer_one_total += customer_one_tax
print("Customer One Items:" + customer_one_itemization )
print("Customer One Total:"+ str (customer_one_total))
| lovely_loveseat_description = ' Lovely Loveseat. Tufted polyester blend on wood. 32 inches high x 40 inches wide x inches deep. Red or white'
lovely_loveseat_price = 254.0
stylish_sette_description = ' Stylish settee. Faux leaather on brich. 29.50 inches high x 54.75 inches wide x 28 inches deep. Black.'
stylist_settee_price = 180.5
luxurious_lamp_description = ' Luxurious Lamp. Glass and iron.36 inches tall.brown with cream shade.'
luxurious_lamp_price = 52.15
sales_tax = 0.88
customer_one_total = 0
customer_one_itemization = ''
customer_one_total += lovely_loveseat_price
customer_one_itemization = lovely_loveseat_description
customer_one_total += luxurious_lamp_price
customer_one_itemization = '\n' + lovely_loveseat_description + '\n ' + luxurious_lamp_description
customer_one_tax = customer_one_total * sales_tax
customer_one_total += customer_one_tax
print('Customer One Items:' + customer_one_itemization)
print('Customer One Total:' + str(customer_one_total)) |
# Space: O(n)
# Time: O(n)
class Solution:
def maxArea(self, h, w, horizontalCuts, verticalCuts):
horizontalCuts = [0] + horizontalCuts + [h]
verticalCuts = [0] + verticalCuts + [w]
horizontalCuts = sorted(horizontalCuts)
verticalCuts = sorted(verticalCuts)
h_max = max(horizontalCuts[i] - horizontalCuts[i - 1] for i in range(1, len(horizontalCuts)))
v_max = max(verticalCuts[i] - verticalCuts[i - 1] for i in range(1, len(verticalCuts)))
return (h_max * v_max) % (pow(10, 9) + 7)
| class Solution:
def max_area(self, h, w, horizontalCuts, verticalCuts):
horizontal_cuts = [0] + horizontalCuts + [h]
vertical_cuts = [0] + verticalCuts + [w]
horizontal_cuts = sorted(horizontalCuts)
vertical_cuts = sorted(verticalCuts)
h_max = max((horizontalCuts[i] - horizontalCuts[i - 1] for i in range(1, len(horizontalCuts))))
v_max = max((verticalCuts[i] - verticalCuts[i - 1] for i in range(1, len(verticalCuts))))
return h_max * v_max % (pow(10, 9) + 7) |
class UndoRedoException(Exception):
"""
Here we create UndoRedoService exceptions that may occur.
"""
def __init__(self, message=''):
self.message = message
# def __str__(self):
# return self.message
class UndoRedoService:
"""
This is undo & redo class.
"""
def __init__(self):
"""
This is the creator of UndoRedoService.
* history is a list, containing the function for undoing the last function called and the function for redoing,
which is in fact, the initial function
so, (undo_function, redo_function) is an element of history list
"""
self.history = []
self.index = -1
def record(self, operation):
"""
Here we record a certain operation, meaning that we add to history the undo-redo pair of functions
:param operation: the undo-redo pair of functions -> (undo_function, redo_function)
"""
self.history.append(operation)
self.index += 1
def undo(self):
"""
Here we use history to undo an operation.
:return: true if all is good
"""
if self.index == -1:
raise UndoRedoException("no more undos")
self.history[self.index].undo()
self.index -= 1
return True
def redo(self):
"""
Here we use history to redo an operation.
:return: true if all is good
"""
if self.index == len(self.history) - 1:
raise UndoRedoException("no more redos")
self.index += 1
self.history[self.index].redo()
return True
class CascadedOperation:
"""
This is CascadedOperation class.
"""
def __init__(self, *operations):
"""
Here is the constructor of CascadedOperation class.
If for example we want to delete a student, we also have to delete its grades.
same thing for assignments.
:param operations: the given operation
"""
self.operations = operations
def undo(self):
for operation in self.operations:
operation.undo()
def redo(self):
for operation in self.operations:
operation.redo()
class Operation:
"""
Here we create an operation wich contains an undo and a redo function call.
"""
def __init__(self, function_call_undo, function_call_redo):
self.function_call_undo = function_call_undo
self.function_call_redo = function_call_redo
def undo(self):
self.function_call_undo()
def redo(self):
self.function_call_redo()
class FunctionCall:
"""
Here we create a FunctionCall.
"""
def __init__(self, function_name, *function_parameters):
self.function_name = function_name
self.function_parameters = function_parameters
def call(self):
return self.function_name(*self.function_parameters)
def __call__(self):
return self.call() | class Undoredoexception(Exception):
"""
Here we create UndoRedoService exceptions that may occur.
"""
def __init__(self, message=''):
self.message = message
class Undoredoservice:
"""
This is undo & redo class.
"""
def __init__(self):
"""
This is the creator of UndoRedoService.
* history is a list, containing the function for undoing the last function called and the function for redoing,
which is in fact, the initial function
so, (undo_function, redo_function) is an element of history list
"""
self.history = []
self.index = -1
def record(self, operation):
"""
Here we record a certain operation, meaning that we add to history the undo-redo pair of functions
:param operation: the undo-redo pair of functions -> (undo_function, redo_function)
"""
self.history.append(operation)
self.index += 1
def undo(self):
"""
Here we use history to undo an operation.
:return: true if all is good
"""
if self.index == -1:
raise undo_redo_exception('no more undos')
self.history[self.index].undo()
self.index -= 1
return True
def redo(self):
"""
Here we use history to redo an operation.
:return: true if all is good
"""
if self.index == len(self.history) - 1:
raise undo_redo_exception('no more redos')
self.index += 1
self.history[self.index].redo()
return True
class Cascadedoperation:
"""
This is CascadedOperation class.
"""
def __init__(self, *operations):
"""
Here is the constructor of CascadedOperation class.
If for example we want to delete a student, we also have to delete its grades.
same thing for assignments.
:param operations: the given operation
"""
self.operations = operations
def undo(self):
for operation in self.operations:
operation.undo()
def redo(self):
for operation in self.operations:
operation.redo()
class Operation:
"""
Here we create an operation wich contains an undo and a redo function call.
"""
def __init__(self, function_call_undo, function_call_redo):
self.function_call_undo = function_call_undo
self.function_call_redo = function_call_redo
def undo(self):
self.function_call_undo()
def redo(self):
self.function_call_redo()
class Functioncall:
"""
Here we create a FunctionCall.
"""
def __init__(self, function_name, *function_parameters):
self.function_name = function_name
self.function_parameters = function_parameters
def call(self):
return self.function_name(*self.function_parameters)
def __call__(self):
return self.call() |
class chipManager():
def __init__(self,chipsize,chipNums):
self.player1chips = chipNums
self.player2chips = chipNums
self.chipsize = chipsize
def getP1Chips():
return self.player1chips
def getP2Chips():
return self.player2chips
def transferToDealer(txToDealer):
if txToDealer:
self.player1chips = self.player1chips - self.chipsize
self.player2chips = self.player2chips + self.chipsize
else:
self.player1chips = self.player1chips + self.chipsize
self.player2chips = self.player2chips - self.chipsize
| class Chipmanager:
def __init__(self, chipsize, chipNums):
self.player1chips = chipNums
self.player2chips = chipNums
self.chipsize = chipsize
def get_p1_chips():
return self.player1chips
def get_p2_chips():
return self.player2chips
def transfer_to_dealer(txToDealer):
if txToDealer:
self.player1chips = self.player1chips - self.chipsize
self.player2chips = self.player2chips + self.chipsize
else:
self.player1chips = self.player1chips + self.chipsize
self.player2chips = self.player2chips - self.chipsize |
'''
Catalan number `cat(n)`.
Recursive formula:
cat(5) = cat(0)*cat(4) + cat(1)*cat(3) + .. cat(4)*cat(0)
Direct formula:
cat(n) = (2n)! / (n+1)!(n)!
Answer for:
- Number of BST given the number of unique keys.
- Number of binary trees with the same preorder traversal.
- Number of balanced parantheses sequence --> HOW??
- Number of full binary trees with n+1 leaves.
- Number of ways of associating n applications of a binary operator.
For n = 3, for example, we have the following five different parenthesizations of four factors:
((ab)c)d (a(bc))d (ab)(cd) a((bc)d) a(b(cd))
Actually, successive applications of a binary operator can be represented in terms of a full binary tree.
'''
| """
Catalan number `cat(n)`.
Recursive formula:
cat(5) = cat(0)*cat(4) + cat(1)*cat(3) + .. cat(4)*cat(0)
Direct formula:
cat(n) = (2n)! / (n+1)!(n)!
Answer for:
- Number of BST given the number of unique keys.
- Number of binary trees with the same preorder traversal.
- Number of balanced parantheses sequence --> HOW??
- Number of full binary trees with n+1 leaves.
- Number of ways of associating n applications of a binary operator.
For n = 3, for example, we have the following five different parenthesizations of four factors:
((ab)c)d (a(bc))d (ab)(cd) a((bc)d) a(b(cd))
Actually, successive applications of a binary operator can be represented in terms of a full binary tree.
""" |
# Input : arr[] = {15, 18, 2, 3, 6, 12}
# Output: 2
# Explanation : Initial array must be {2, 3,
# 6, 12, 15, 18}. We get the given array after
# rotating the initial array twice.
# Input : arr[] = {7, 9, 11, 12, 5}
# Output: 4
# Input: arr[] = {7, 9, 11, 12, 15};
# Output: 0
def single_rotation(arr, l):
temp = arr[0]
for i in range(l - 1):
arr[i] = arr[i + 1]
arr[l - 1] = temp
def find_min(arr, l):
min = arr[0]
for i in range(l):
if min < arr[i]:
min = arr[i]
minimum = min
for i in range(l):
if min == arr[i]:
index = i + 1
for i in range(index):
single_rotation(arr, len(arr))
return index
# def print_array(arr,l):
# for i in range(l):
# print(arr[i])
arr = [15, 18, 2, 3, 6, 12]
rotations = find_min(arr, len(arr))
print("number of rotations:" + str(rotations))
# print_array(arr,len(arr))
print
| def single_rotation(arr, l):
temp = arr[0]
for i in range(l - 1):
arr[i] = arr[i + 1]
arr[l - 1] = temp
def find_min(arr, l):
min = arr[0]
for i in range(l):
if min < arr[i]:
min = arr[i]
minimum = min
for i in range(l):
if min == arr[i]:
index = i + 1
for i in range(index):
single_rotation(arr, len(arr))
return index
arr = [15, 18, 2, 3, 6, 12]
rotations = find_min(arr, len(arr))
print('number of rotations:' + str(rotations))
print |
__version__ = (1, 0, 0, "final", 0)
ADMIN_PIPELINE_CSS = {
'admin_bs3': {
'source_filenames': (
'admintools_bootstrap/chosen/chosen.css',
'admintools_bootstrap/lib/bootstrap-datetimepicker.css',
'admintools_bootstrap/lib/bootstrap-fileupload.scss',
'admintools_bootstrap/sass/admin.scss',
'admintools_bootstrap/css/mmenu.css',
),
'output_filename': 'css/admin_bs3.css',
'extra_context': {
'media': 'screen,projection',
},
},
'admin_bs3_dashboard': {
'source_filenames': (
'admin_dashboard.css',
'admintools_bootstrap/sass/dashboard.scss',
),
'output_filename': 'css/admin_bs3_dashboard.css',
'extra_context': {
'media': 'screen,projection',
},
},
}
ADMIN_PIPELINE_JS = {
'admin_bs3': {
'source_filenames': (
'admintools_bootstrap/js/lazyload.js',
'admintools_bootstrap/js/jquery-1.9.1.js',
'admintools_bootstrap/js/jquery-ui-1.10.3.custom.js',
'admintools_bootstrap/js/json2.js',
'admin_tools/js/jquery/jquery.cookie.min.js',
'admin_tools/js/jquery/jquery.dashboard.js',
'admin_tools/js/menu.js',
'admintools_bootstrap/chosen/chosen.jquery.js',
'admintools_bootstrap/js/bootstrap/dropdown.js',
'admintools_bootstrap/js/bootstrap/alert.js',
'admintools_bootstrap/js/bootstrap-datetimepicker.js',
'admintools_bootstrap/js/bootstrap-fileupload.js',
'admintools_bootstrap/js/dismissAddAnotherPopup.js',
'admintools_bootstrap/js/admin.js',
),
'output_filename': 'js/admin_bs3_dashboard.js',
'extra_context': {
'media': 'screen,projection',
},
},
}
| __version__ = (1, 0, 0, 'final', 0)
admin_pipeline_css = {'admin_bs3': {'source_filenames': ('admintools_bootstrap/chosen/chosen.css', 'admintools_bootstrap/lib/bootstrap-datetimepicker.css', 'admintools_bootstrap/lib/bootstrap-fileupload.scss', 'admintools_bootstrap/sass/admin.scss', 'admintools_bootstrap/css/mmenu.css'), 'output_filename': 'css/admin_bs3.css', 'extra_context': {'media': 'screen,projection'}}, 'admin_bs3_dashboard': {'source_filenames': ('admin_dashboard.css', 'admintools_bootstrap/sass/dashboard.scss'), 'output_filename': 'css/admin_bs3_dashboard.css', 'extra_context': {'media': 'screen,projection'}}}
admin_pipeline_js = {'admin_bs3': {'source_filenames': ('admintools_bootstrap/js/lazyload.js', 'admintools_bootstrap/js/jquery-1.9.1.js', 'admintools_bootstrap/js/jquery-ui-1.10.3.custom.js', 'admintools_bootstrap/js/json2.js', 'admin_tools/js/jquery/jquery.cookie.min.js', 'admin_tools/js/jquery/jquery.dashboard.js', 'admin_tools/js/menu.js', 'admintools_bootstrap/chosen/chosen.jquery.js', 'admintools_bootstrap/js/bootstrap/dropdown.js', 'admintools_bootstrap/js/bootstrap/alert.js', 'admintools_bootstrap/js/bootstrap-datetimepicker.js', 'admintools_bootstrap/js/bootstrap-fileupload.js', 'admintools_bootstrap/js/dismissAddAnotherPopup.js', 'admintools_bootstrap/js/admin.js'), 'output_filename': 'js/admin_bs3_dashboard.js', 'extra_context': {'media': 'screen,projection'}}} |
class DataGenerator(KU.Sequence):
"""An iterable that returns images and corresponding target class ids,
bounding box deltas, and masks. It inherits from keras.utils.Sequence to avoid data redundancy
when multiprocessing=True.
dataset: The Dataset object to pick data from
config: The model config object
shuffle: If True, shuffles the samples before every epoch
augmentation: Optional. An imgaug (https://github.com/aleju/imgaug) augmentation.
For example, passing imgaug.augmenters.Fliplr(0.5) flips images
right/left 50% of the time.
random_rois: If > 0 then generate proposals to be used to train the
network classifier and mask heads. Useful if training
the Mask RCNN part without the RPN.
detection_targets: If True, generate detection targets (class IDs, bbox
deltas, and masks). Typically for debugging or visualizations because
in trainig detection targets are generated by DetectionTargetLayer.
Returns a Python iterable. Upon calling __getitem__() on it, the
iterable returns two lists, inputs and outputs. The contents
of the lists differ depending on the received arguments:
inputs list:
- images: [batch, H, W, C]
- image_meta: [batch, (meta data)] Image details. See compose_image_meta()
- rpn_match: [batch, N] Integer (1=positive anchor, -1=negative, 0=neutral)
- rpn_bbox: [batch, N, (dy, dx, log(dh), log(dw))] Anchor bbox deltas.
- gt_class_ids: [batch, MAX_GT_INSTANCES] Integer class IDs
- gt_boxes: [batch, MAX_GT_INSTANCES, (y1, x1, y2, x2)]
- gt_masks: [batch, height, width, MAX_GT_INSTANCES]. The height and width
are those of the image unless use_mini_mask is True, in which
case they are defined in MINI_MASK_SHAPE.
outputs list: Usually empty in regular training. But if detection_targets
is True then the outputs list contains target class_ids, bbox deltas,
and masks.
"""
def __init__(self, dataset, config, shuffle=True, augmentation=None,
random_rois=0, detection_targets=False):
self.image_ids = np.copy(dataset.image_ids)
self.dataset = dataset
self.config = config
# Anchors
# [anchor_count, (y1, x1, y2, x2)]
self.backbone_shapes = compute_backbone_shapes(config, config.IMAGE_SHAPE)
self.anchors = utils.generate_pyramid_anchors(config.RPN_ANCHOR_SCALES,
config.RPN_ANCHOR_RATIOS,
self.backbone_shapes,
config.BACKBONE_STRIDES,
config.RPN_ANCHOR_STRIDE)
self.shuffle = shuffle
self.augmentation = augmentation
self.random_rois = random_rois
self.batch_size = self.config.BATCH_SIZE
self.detection_targets = detection_targets
def __len__(self):
return int(np.ceil(len(self.image_ids) / float(self.batch_size)))
def __getitem__(self, idx):
b = 0
image_index = -1
while b < self.batch_size:
# Increment index to pick next image. Shuffle if at the start of an epoch.
image_index = (image_index + 1) % len(self.image_ids)
if self.shuffle and image_index == 0:
np.random.shuffle(self.image_ids)
# Get GT bounding boxes and masks for image.
image_id = self.image_ids[image_index]
image, image_meta, gt_class_ids, gt_boxes, gt_masks = \
load_image_gt(self.dataset, self.config, image_id,
augmentation=self.augmentation)
# Skip images that have no instances. This can happen in cases
# where we train on a subset of classes and the image doesn't
# have any of the classes we care about.
if not np.any(gt_class_ids > 0):
continue
# RPN Targets
rpn_match, rpn_bbox = build_rpn_targets(image.shape, self.anchors,
gt_class_ids, gt_boxes, self.config)
# Mask R-CNN Targets
if self.random_rois:
rpn_rois = generate_random_rois(
image.shape, self.random_rois, gt_class_ids, gt_boxes)
if self.detection_targets:
rois, mrcnn_class_ids, mrcnn_bbox, mrcnn_mask = \
build_detection_targets(
rpn_rois, gt_class_ids, gt_boxes, gt_masks, self.config)
# Init batch arrays
if b == 0:
batch_image_meta = np.zeros(
(self.batch_size,) + image_meta.shape, dtype=image_meta.dtype)
batch_rpn_match = np.zeros(
[self.batch_size, self.anchors.shape[0], 1], dtype=rpn_match.dtype)
batch_rpn_bbox = np.zeros(
[self.batch_size, self.config.RPN_TRAIN_ANCHORS_PER_IMAGE, 4], dtype=rpn_bbox.dtype)
batch_images = np.zeros(
(self.batch_size,) + image.shape, dtype=np.float32)
batch_gt_class_ids = np.zeros(
(self.batch_size, self.config.MAX_GT_INSTANCES), dtype=np.int32)
batch_gt_boxes = np.zeros(
(self.batch_size, self.config.MAX_GT_INSTANCES, 4), dtype=np.int32)
batch_gt_masks = np.zeros(
(self.batch_size, gt_masks.shape[0], gt_masks.shape[1],
self.config.MAX_GT_INSTANCES), dtype=gt_masks.dtype)
if self.random_rois:
batch_rpn_rois = np.zeros(
(self.batch_size, rpn_rois.shape[0], 4), dtype=rpn_rois.dtype)
if self.detection_targets:
batch_rois = np.zeros(
(self.batch_size,) + rois.shape, dtype=rois.dtype)
batch_mrcnn_class_ids = np.zeros(
(self.batch_size,) + mrcnn_class_ids.shape, dtype=mrcnn_class_ids.dtype)
batch_mrcnn_bbox = np.zeros(
(self.batch_size,) + mrcnn_bbox.shape, dtype=mrcnn_bbox.dtype)
batch_mrcnn_mask = np.zeros(
(self.batch_size,) + mrcnn_mask.shape, dtype=mrcnn_mask.dtype)
# If more instances than fits in the array, sub-sample from them.
if gt_boxes.shape[0] > self.config.MAX_GT_INSTANCES:
ids = np.random.choice(
np.arange(gt_boxes.shape[0]), self.config.MAX_GT_INSTANCES, replace=False)
gt_class_ids = gt_class_ids[ids]
gt_boxes = gt_boxes[ids]
gt_masks = gt_masks[:, :, ids]
# Add to batch
batch_image_meta[b] = image_meta
batch_rpn_match[b] = rpn_match[:, np.newaxis]
batch_rpn_bbox[b] = rpn_bbox
batch_images[b] = mold_image(image.astype(np.float32), self.config)
batch_gt_class_ids[b, :gt_class_ids.shape[0]] = gt_class_ids
batch_gt_boxes[b, :gt_boxes.shape[0]] = gt_boxes
batch_gt_masks[b, :, :, :gt_masks.shape[-1]] = gt_masks
if self.random_rois:
batch_rpn_rois[b] = rpn_rois
if self.detection_targets:
batch_rois[b] = rois
batch_mrcnn_class_ids[b] = mrcnn_class_ids
batch_mrcnn_bbox[b] = mrcnn_bbox
batch_mrcnn_mask[b] = mrcnn_mask
b += 1
inputs = [batch_images, batch_image_meta, batch_rpn_match, batch_rpn_bbox,
batch_gt_class_ids, batch_gt_boxes, batch_gt_masks]
outputs = []
if self.random_rois:
inputs.extend([batch_rpn_rois])
if self.detection_targets:
inputs.extend([batch_rois])
# Keras requires that output and targets have the same number of dimensions
batch_mrcnn_class_ids = np.expand_dims(
batch_mrcnn_class_ids, -1)
outputs.extend(
[batch_mrcnn_class_ids, batch_mrcnn_bbox, batch_mrcnn_mask])
return inputs, outputs | class Datagenerator(KU.Sequence):
"""An iterable that returns images and corresponding target class ids,
bounding box deltas, and masks. It inherits from keras.utils.Sequence to avoid data redundancy
when multiprocessing=True.
dataset: The Dataset object to pick data from
config: The model config object
shuffle: If True, shuffles the samples before every epoch
augmentation: Optional. An imgaug (https://github.com/aleju/imgaug) augmentation.
For example, passing imgaug.augmenters.Fliplr(0.5) flips images
right/left 50% of the time.
random_rois: If > 0 then generate proposals to be used to train the
network classifier and mask heads. Useful if training
the Mask RCNN part without the RPN.
detection_targets: If True, generate detection targets (class IDs, bbox
deltas, and masks). Typically for debugging or visualizations because
in trainig detection targets are generated by DetectionTargetLayer.
Returns a Python iterable. Upon calling __getitem__() on it, the
iterable returns two lists, inputs and outputs. The contents
of the lists differ depending on the received arguments:
inputs list:
- images: [batch, H, W, C]
- image_meta: [batch, (meta data)] Image details. See compose_image_meta()
- rpn_match: [batch, N] Integer (1=positive anchor, -1=negative, 0=neutral)
- rpn_bbox: [batch, N, (dy, dx, log(dh), log(dw))] Anchor bbox deltas.
- gt_class_ids: [batch, MAX_GT_INSTANCES] Integer class IDs
- gt_boxes: [batch, MAX_GT_INSTANCES, (y1, x1, y2, x2)]
- gt_masks: [batch, height, width, MAX_GT_INSTANCES]. The height and width
are those of the image unless use_mini_mask is True, in which
case they are defined in MINI_MASK_SHAPE.
outputs list: Usually empty in regular training. But if detection_targets
is True then the outputs list contains target class_ids, bbox deltas,
and masks.
"""
def __init__(self, dataset, config, shuffle=True, augmentation=None, random_rois=0, detection_targets=False):
self.image_ids = np.copy(dataset.image_ids)
self.dataset = dataset
self.config = config
self.backbone_shapes = compute_backbone_shapes(config, config.IMAGE_SHAPE)
self.anchors = utils.generate_pyramid_anchors(config.RPN_ANCHOR_SCALES, config.RPN_ANCHOR_RATIOS, self.backbone_shapes, config.BACKBONE_STRIDES, config.RPN_ANCHOR_STRIDE)
self.shuffle = shuffle
self.augmentation = augmentation
self.random_rois = random_rois
self.batch_size = self.config.BATCH_SIZE
self.detection_targets = detection_targets
def __len__(self):
return int(np.ceil(len(self.image_ids) / float(self.batch_size)))
def __getitem__(self, idx):
b = 0
image_index = -1
while b < self.batch_size:
image_index = (image_index + 1) % len(self.image_ids)
if self.shuffle and image_index == 0:
np.random.shuffle(self.image_ids)
image_id = self.image_ids[image_index]
(image, image_meta, gt_class_ids, gt_boxes, gt_masks) = load_image_gt(self.dataset, self.config, image_id, augmentation=self.augmentation)
if not np.any(gt_class_ids > 0):
continue
(rpn_match, rpn_bbox) = build_rpn_targets(image.shape, self.anchors, gt_class_ids, gt_boxes, self.config)
if self.random_rois:
rpn_rois = generate_random_rois(image.shape, self.random_rois, gt_class_ids, gt_boxes)
if self.detection_targets:
(rois, mrcnn_class_ids, mrcnn_bbox, mrcnn_mask) = build_detection_targets(rpn_rois, gt_class_ids, gt_boxes, gt_masks, self.config)
if b == 0:
batch_image_meta = np.zeros((self.batch_size,) + image_meta.shape, dtype=image_meta.dtype)
batch_rpn_match = np.zeros([self.batch_size, self.anchors.shape[0], 1], dtype=rpn_match.dtype)
batch_rpn_bbox = np.zeros([self.batch_size, self.config.RPN_TRAIN_ANCHORS_PER_IMAGE, 4], dtype=rpn_bbox.dtype)
batch_images = np.zeros((self.batch_size,) + image.shape, dtype=np.float32)
batch_gt_class_ids = np.zeros((self.batch_size, self.config.MAX_GT_INSTANCES), dtype=np.int32)
batch_gt_boxes = np.zeros((self.batch_size, self.config.MAX_GT_INSTANCES, 4), dtype=np.int32)
batch_gt_masks = np.zeros((self.batch_size, gt_masks.shape[0], gt_masks.shape[1], self.config.MAX_GT_INSTANCES), dtype=gt_masks.dtype)
if self.random_rois:
batch_rpn_rois = np.zeros((self.batch_size, rpn_rois.shape[0], 4), dtype=rpn_rois.dtype)
if self.detection_targets:
batch_rois = np.zeros((self.batch_size,) + rois.shape, dtype=rois.dtype)
batch_mrcnn_class_ids = np.zeros((self.batch_size,) + mrcnn_class_ids.shape, dtype=mrcnn_class_ids.dtype)
batch_mrcnn_bbox = np.zeros((self.batch_size,) + mrcnn_bbox.shape, dtype=mrcnn_bbox.dtype)
batch_mrcnn_mask = np.zeros((self.batch_size,) + mrcnn_mask.shape, dtype=mrcnn_mask.dtype)
if gt_boxes.shape[0] > self.config.MAX_GT_INSTANCES:
ids = np.random.choice(np.arange(gt_boxes.shape[0]), self.config.MAX_GT_INSTANCES, replace=False)
gt_class_ids = gt_class_ids[ids]
gt_boxes = gt_boxes[ids]
gt_masks = gt_masks[:, :, ids]
batch_image_meta[b] = image_meta
batch_rpn_match[b] = rpn_match[:, np.newaxis]
batch_rpn_bbox[b] = rpn_bbox
batch_images[b] = mold_image(image.astype(np.float32), self.config)
batch_gt_class_ids[b, :gt_class_ids.shape[0]] = gt_class_ids
batch_gt_boxes[b, :gt_boxes.shape[0]] = gt_boxes
batch_gt_masks[b, :, :, :gt_masks.shape[-1]] = gt_masks
if self.random_rois:
batch_rpn_rois[b] = rpn_rois
if self.detection_targets:
batch_rois[b] = rois
batch_mrcnn_class_ids[b] = mrcnn_class_ids
batch_mrcnn_bbox[b] = mrcnn_bbox
batch_mrcnn_mask[b] = mrcnn_mask
b += 1
inputs = [batch_images, batch_image_meta, batch_rpn_match, batch_rpn_bbox, batch_gt_class_ids, batch_gt_boxes, batch_gt_masks]
outputs = []
if self.random_rois:
inputs.extend([batch_rpn_rois])
if self.detection_targets:
inputs.extend([batch_rois])
batch_mrcnn_class_ids = np.expand_dims(batch_mrcnn_class_ids, -1)
outputs.extend([batch_mrcnn_class_ids, batch_mrcnn_bbox, batch_mrcnn_mask])
return (inputs, outputs) |
# TODO: move this into backend function
def tuple2str(tuple_in):
"""Converts a tuple into a string.
:param tuple_in: tuple to convert
:type tuple_in: tuple
:returns: concatenated string version of the tuple
:rtype: str
"""
string = ''
for i in tuple_in:
string += str(i)
return string
def numerise_params(prop_dict):
""" Returns drug properties with all qualitative values transformed into
numeric values
returns: numerically transformed property dictionaries
rtype: dict
"""
clearance_dict = {
'low (< 5.6)': 1,
'medium (5.6-30.5)': 4,
'low (< 3.7)': 1,
'good': 1,
'high (> 30.5)': 7,
'fair': 4,
'poor': 7,
'low (< 12)': 1,
'medium (12-44)': 4,
'medium (5.6-30.5)': 4
}
pampa_dict = {
'neg': 0,
'poor': 1,
'low': 2.5,
'fair': 5.5,
'med2high': 5.5,
'good': 6.5,
'best': 8
}
drug_properties = prop_dict
for k, v in clearance_dict.items():
if k == drug_properties['clearance_mouse']:
drug_properties['clearance_mouse'] = v
if k == drug_properties['clearance_human']:
drug_properties['clearance_human'] = v
for k, v in pampa_dict.items():
if k == drug_properties['pampa']:
drug_properties['pampa'] = v
if k == drug_properties['logd']:
drug_properties['logd'] = v
return (drug_properties) | def tuple2str(tuple_in):
"""Converts a tuple into a string.
:param tuple_in: tuple to convert
:type tuple_in: tuple
:returns: concatenated string version of the tuple
:rtype: str
"""
string = ''
for i in tuple_in:
string += str(i)
return string
def numerise_params(prop_dict):
""" Returns drug properties with all qualitative values transformed into
numeric values
returns: numerically transformed property dictionaries
rtype: dict
"""
clearance_dict = {'low (< 5.6)': 1, 'medium (5.6-30.5)': 4, 'low (< 3.7)': 1, 'good': 1, 'high (> 30.5)': 7, 'fair': 4, 'poor': 7, 'low (< 12)': 1, 'medium (12-44)': 4, 'medium (5.6-30.5)': 4}
pampa_dict = {'neg': 0, 'poor': 1, 'low': 2.5, 'fair': 5.5, 'med2high': 5.5, 'good': 6.5, 'best': 8}
drug_properties = prop_dict
for (k, v) in clearance_dict.items():
if k == drug_properties['clearance_mouse']:
drug_properties['clearance_mouse'] = v
if k == drug_properties['clearance_human']:
drug_properties['clearance_human'] = v
for (k, v) in pampa_dict.items():
if k == drug_properties['pampa']:
drug_properties['pampa'] = v
if k == drug_properties['logd']:
drug_properties['logd'] = v
return drug_properties |
t = int(input())
for _ in range(t):
s = [s_temp for s_temp in input().strip()]
#s_len = len(s)
#s_first_half = s[:s_len//2]
#s_second_half = s[s_len//2+s_len%2:][::-1]
op = 0
for i in range(len(s)//2):
#op += ord(max(s_first_half[i], s_second_half[i])) - ord(min(s_first_half[i], s_second_half[i]))
op += abs(ord(s[i]) - ord(s[len(s)-i-1]))
print (op) | t = int(input())
for _ in range(t):
s = [s_temp for s_temp in input().strip()]
op = 0
for i in range(len(s) // 2):
op += abs(ord(s[i]) - ord(s[len(s) - i - 1]))
print(op) |
def is_macro_action(unit_command_action, abilities):
"""
This function determines if a unit_command action is a macro action
based on the following criteria: if the action is related to training, morphing,
researching or building units or technologies, then it is a macro action. It
returns a boolean.
Feel free to add more stuff in macro_names by checking the stableid.json and
adding names that you feel should be stored as macro actions.
"""
macro_names = [
"Morph",
"Research",
"Train",
"ZergBuild",
"ProtossBuild",
"TerranBuild",
]
for name in macro_names:
ability = abilities[unit_command_action.ability_id]
# print(f"ability: {ability}")
if name in ability.link_name:
# we're also storing the the canceling of stuff.
# if hasattr(ability, 'button_name') and 'Cancel' in ability.button_name:
# return False
return True
return False
def get_human_name(action_doc, abilities):
ability = abilities[action_doc["ability_id"]]
return str(ability.link_name) + str(ability.button_name)
def get_actions(actions, abilities):
"""
This function is supposed to return macro actions from an observation.
Arguments:
-actions, actions for a given observation
-abilities, which is the result of controller.raw_data().abilities
Returns:
- a list macro_actions of all the macro actions found in obs.actions.
Raw observations and unit commands are defined in the protocol here:
https://github.com/Blizzard/s2client-proto/blob/aa41daa2da79431d3b88b115e6a17b23a9260529/s2clientprotocol/raw.proto#L160
TO-DO:
- clean the hasattr, it seems to be innecesary
"""
macro_actions = []
for action in actions:
if hasattr(action, "action_raw") and hasattr(action.action_raw, "unit_command"):
if is_macro_action(action.action_raw.unit_command, abilities):
action_doc = {}
if hasattr(action.action_raw.unit_command, "ability_id"):
action_doc["ability_id"] = action.action_raw.unit_command.ability_id
if hasattr(action.action_raw.unit_command, "unit_tags"):
action_doc["unit_tags"] = [
tag for tag in action.action_raw.unit_command.unit_tags
]
if hasattr(action.action_raw.unit_command, "target_unit_tag"):
action_doc[
"target_unit_tag"
] = action.action_raw.unit_command.target_unit_tag
if hasattr(action.action_raw.unit_command, "target_world_space_pos"):
action_doc["target_world_space_pos"] = {
"x": action.action_raw.unit_command.target_world_space_pos.x,
"y": action.action_raw.unit_command.target_world_space_pos.y,
}
macro_actions.append(action_doc)
return macro_actions
| def is_macro_action(unit_command_action, abilities):
"""
This function determines if a unit_command action is a macro action
based on the following criteria: if the action is related to training, morphing,
researching or building units or technologies, then it is a macro action. It
returns a boolean.
Feel free to add more stuff in macro_names by checking the stableid.json and
adding names that you feel should be stored as macro actions.
"""
macro_names = ['Morph', 'Research', 'Train', 'ZergBuild', 'ProtossBuild', 'TerranBuild']
for name in macro_names:
ability = abilities[unit_command_action.ability_id]
if name in ability.link_name:
return True
return False
def get_human_name(action_doc, abilities):
ability = abilities[action_doc['ability_id']]
return str(ability.link_name) + str(ability.button_name)
def get_actions(actions, abilities):
"""
This function is supposed to return macro actions from an observation.
Arguments:
-actions, actions for a given observation
-abilities, which is the result of controller.raw_data().abilities
Returns:
- a list macro_actions of all the macro actions found in obs.actions.
Raw observations and unit commands are defined in the protocol here:
https://github.com/Blizzard/s2client-proto/blob/aa41daa2da79431d3b88b115e6a17b23a9260529/s2clientprotocol/raw.proto#L160
TO-DO:
- clean the hasattr, it seems to be innecesary
"""
macro_actions = []
for action in actions:
if hasattr(action, 'action_raw') and hasattr(action.action_raw, 'unit_command'):
if is_macro_action(action.action_raw.unit_command, abilities):
action_doc = {}
if hasattr(action.action_raw.unit_command, 'ability_id'):
action_doc['ability_id'] = action.action_raw.unit_command.ability_id
if hasattr(action.action_raw.unit_command, 'unit_tags'):
action_doc['unit_tags'] = [tag for tag in action.action_raw.unit_command.unit_tags]
if hasattr(action.action_raw.unit_command, 'target_unit_tag'):
action_doc['target_unit_tag'] = action.action_raw.unit_command.target_unit_tag
if hasattr(action.action_raw.unit_command, 'target_world_space_pos'):
action_doc['target_world_space_pos'] = {'x': action.action_raw.unit_command.target_world_space_pos.x, 'y': action.action_raw.unit_command.target_world_space_pos.y}
macro_actions.append(action_doc)
return macro_actions |
def n_lower_cases(string):
return sum([int(c.islower()) for c in string])
def n_upper_cases(string):
return sum([int(c.isupper()) for c in string])
def n_whitespace(string):
cnt = 0.0
for c in string:
if c == '_':
cnt += 1
return cnt
string = input()
symb_amt = n_whitespace(string) + n_lower_cases(string) + n_upper_cases(string)
print(n_whitespace(string) / len(string ))
print(n_lower_cases(string) / len(string))
print(n_upper_cases(string) / len(string))
print( (len(string) - symb_amt) / len(string))
| def n_lower_cases(string):
return sum([int(c.islower()) for c in string])
def n_upper_cases(string):
return sum([int(c.isupper()) for c in string])
def n_whitespace(string):
cnt = 0.0
for c in string:
if c == '_':
cnt += 1
return cnt
string = input()
symb_amt = n_whitespace(string) + n_lower_cases(string) + n_upper_cases(string)
print(n_whitespace(string) / len(string))
print(n_lower_cases(string) / len(string))
print(n_upper_cases(string) / len(string))
print((len(string) - symb_amt) / len(string)) |
#!/usr/bin/env python3
inp = "01111010110010011"
def solve(target_len):
# translate input into numbers
state = [int(c) for c in inp]
# generate data
while len(state) < target_len:
state += [0] + [1-i for i in state[::-1]]
# compute checksujm
state = state[:target_len]
while len(state)%2 == 0:
for i in range(int(len(state)/2)):
state[i] = 1 if state[2*i] == state[2*i+1] else 0
state = state[:int(len(state)/2)]
print(''.join(map(str, state)))
solve(272)
solve(35651584) | inp = '01111010110010011'
def solve(target_len):
state = [int(c) for c in inp]
while len(state) < target_len:
state += [0] + [1 - i for i in state[::-1]]
state = state[:target_len]
while len(state) % 2 == 0:
for i in range(int(len(state) / 2)):
state[i] = 1 if state[2 * i] == state[2 * i + 1] else 0
state = state[:int(len(state) / 2)]
print(''.join(map(str, state)))
solve(272)
solve(35651584) |
class Solution(object):
def countBinarySubstrings(self, s):
"""
:type s: str
:rtype: int
"""
N = len(s)
curlen = 1
res = []
for i in range(1, N):
if s[i] == s[i - 1]:
curlen += 1
else:
res.append(curlen)
curlen = 1
res.append(curlen)
return sum(min(x, y) for x, y in zip(res[:-1], res[1:]))
p = Solution()
S = "00110011"
print(p.countBinarySubstrings(S)) | class Solution(object):
def count_binary_substrings(self, s):
"""
:type s: str
:rtype: int
"""
n = len(s)
curlen = 1
res = []
for i in range(1, N):
if s[i] == s[i - 1]:
curlen += 1
else:
res.append(curlen)
curlen = 1
res.append(curlen)
return sum((min(x, y) for (x, y) in zip(res[:-1], res[1:])))
p = solution()
s = '00110011'
print(p.countBinarySubstrings(S)) |
# Data Center URL
DATA_FILES_BASE_URL = "https://www.meps.ahrq.gov/mepsweb/data_files/pufs/"
DATA_STATS_BASE_URL = "https://www.meps.ahrq.gov/data_stats/download_data/pufs/"
# Base Year List
DATA_FILES_YEARS = [
2018,
2017,
2016,
2015,
2014,
2013,
2012,
2011,
2010,
2009,
2008,
2007,
2006,
2005,
]
BASE_MODELS = [
"DentalVisits",
"EmergencyRoomVisits",
"HomeHealth",
"HospitalInpatientStays",
"MedicalConditions",
"OfficeBasedVisits",
"OtherMedicalExpenses",
"OutpatientVisits",
"PopulationCharacteristics",
"PrescribedMedicines",
]
# Full Year Population Characteristics Data Files
FYPCDF_PUF_LOOKUP = {
2018: "h209",
2017: "h201",
2016: "h192",
2015: "h181",
2014: "h171",
2013: "h163",
2012: "h155",
2011: "h147",
2010: "h138",
2009: "h129",
2008: "h121",
2007: "h113",
2006: "h105",
2005: "h97",
}
# Medical Conditions Data Files
MCDF_PUF_LOOKUP = {
2018: "h207",
2017: "h199",
2016: "h190",
2015: "h180",
2014: "h170",
2013: "h162",
2012: "h154",
2011: "h146",
2010: "h137",
2009: "h128",
2008: "h120",
2007: "h112",
2006: "h104",
2005: "h96",
}
# Prescribed Medicines Data Files
PMDF_PUF_LOOKUP = {
2018: "h206a",
2017: "h197a",
2016: "h188a",
2015: "h178a",
2014: "h168a",
2013: "h160a",
2012: "h152a",
2011: "h144a",
2010: "h135a",
2009: "h126a",
2008: "h118a",
2007: "h110a",
2006: "h102a",
2005: "h94a",
}
# Dental Visits Data Files
DVDF_PUF_LOOKUP = {
2018: "h206b",
2017: "h197b",
2016: "h188b",
2015: "h178b",
2014: "h168b",
2013: "h160b",
2012: "h152b",
2011: "h144b",
2010: "h135b",
2009: "h126b",
2008: "h118b",
2007: "h110b",
2006: "h102b",
2005: "h94b",
}
# Other Medical Expenses Data Files
OMEDF_PUF_LOOKUP = {
2018: "h206c",
2017: "h197c",
2016: "h188c",
2015: "h178c",
2014: "h168c",
2013: "h160c",
2012: "h152c",
2011: "h144c",
2010: "h135c",
2009: "h126c",
2008: "h118c",
2007: "h110c",
2006: "h102c",
2005: "h94c",
}
# Hospital Inpatient Stays Data Files
HISDF_PUF_LOOKUP = {
2018: "h206d",
2017: "h197d",
2016: "h188d",
2015: "h178d",
2014: "h168d",
2013: "h160d",
2012: "h152d",
2011: "h144d",
2010: "h135d",
2009: "h126d",
2008: "h118d",
2007: "h110d",
2006: "h102d",
2005: "h94d",
}
# Emergency Room Visits Data Files
ERVDF_PUF_LOOKUP = {
2018: "h206e",
2017: "h197e",
2016: "h188e",
2015: "h178e",
2014: "h168e",
2013: "h160e",
2012: "h152e",
2011: "h144e",
2010: "h135e",
2009: "h126e",
2008: "h118e",
2007: "h110e",
2006: "h102e",
2005: "h94e",
}
# Outpatient Visits Data Files
OVDF_PUF_LOOKUP = {
2018: "h206f",
2017: "h197f",
2016: "h188f",
2015: "h178f",
2014: "h168f",
2013: "h160f",
2012: "h152f",
2011: "h144f",
2010: "h135f",
2009: "h126f",
2008: "h118f",
2007: "h110f",
2006: "h102f",
2005: "h94f",
}
# Office-Based Medical Provider Visits Data Files
OBMPVDF_PUF_LOOKUP = {
2018: "h206g",
2017: "h197g",
2016: "h188g",
2015: "h178g",
2014: "h168g",
2013: "h160g",
2012: "h152g",
2011: "h144g",
2010: "h135g",
2009: "h126g",
2008: "h118g",
2007: "h110g",
2006: "h102g",
2005: "h94g",
}
# Home Health Data Files
HHDF_PUF_LOOKUP = {
2018: "h206h",
2017: "h197h",
2016: "h188h",
2015: "h178h",
2014: "h168h",
2013: "h160h",
2012: "h152h",
2011: "h144h",
2010: "h135h",
2009: "h126h",
2008: "h118h",
2007: "h110h",
2006: "h102h",
2005: "h94h",
}
| data_files_base_url = 'https://www.meps.ahrq.gov/mepsweb/data_files/pufs/'
data_stats_base_url = 'https://www.meps.ahrq.gov/data_stats/download_data/pufs/'
data_files_years = [2018, 2017, 2016, 2015, 2014, 2013, 2012, 2011, 2010, 2009, 2008, 2007, 2006, 2005]
base_models = ['DentalVisits', 'EmergencyRoomVisits', 'HomeHealth', 'HospitalInpatientStays', 'MedicalConditions', 'OfficeBasedVisits', 'OtherMedicalExpenses', 'OutpatientVisits', 'PopulationCharacteristics', 'PrescribedMedicines']
fypcdf_puf_lookup = {2018: 'h209', 2017: 'h201', 2016: 'h192', 2015: 'h181', 2014: 'h171', 2013: 'h163', 2012: 'h155', 2011: 'h147', 2010: 'h138', 2009: 'h129', 2008: 'h121', 2007: 'h113', 2006: 'h105', 2005: 'h97'}
mcdf_puf_lookup = {2018: 'h207', 2017: 'h199', 2016: 'h190', 2015: 'h180', 2014: 'h170', 2013: 'h162', 2012: 'h154', 2011: 'h146', 2010: 'h137', 2009: 'h128', 2008: 'h120', 2007: 'h112', 2006: 'h104', 2005: 'h96'}
pmdf_puf_lookup = {2018: 'h206a', 2017: 'h197a', 2016: 'h188a', 2015: 'h178a', 2014: 'h168a', 2013: 'h160a', 2012: 'h152a', 2011: 'h144a', 2010: 'h135a', 2009: 'h126a', 2008: 'h118a', 2007: 'h110a', 2006: 'h102a', 2005: 'h94a'}
dvdf_puf_lookup = {2018: 'h206b', 2017: 'h197b', 2016: 'h188b', 2015: 'h178b', 2014: 'h168b', 2013: 'h160b', 2012: 'h152b', 2011: 'h144b', 2010: 'h135b', 2009: 'h126b', 2008: 'h118b', 2007: 'h110b', 2006: 'h102b', 2005: 'h94b'}
omedf_puf_lookup = {2018: 'h206c', 2017: 'h197c', 2016: 'h188c', 2015: 'h178c', 2014: 'h168c', 2013: 'h160c', 2012: 'h152c', 2011: 'h144c', 2010: 'h135c', 2009: 'h126c', 2008: 'h118c', 2007: 'h110c', 2006: 'h102c', 2005: 'h94c'}
hisdf_puf_lookup = {2018: 'h206d', 2017: 'h197d', 2016: 'h188d', 2015: 'h178d', 2014: 'h168d', 2013: 'h160d', 2012: 'h152d', 2011: 'h144d', 2010: 'h135d', 2009: 'h126d', 2008: 'h118d', 2007: 'h110d', 2006: 'h102d', 2005: 'h94d'}
ervdf_puf_lookup = {2018: 'h206e', 2017: 'h197e', 2016: 'h188e', 2015: 'h178e', 2014: 'h168e', 2013: 'h160e', 2012: 'h152e', 2011: 'h144e', 2010: 'h135e', 2009: 'h126e', 2008: 'h118e', 2007: 'h110e', 2006: 'h102e', 2005: 'h94e'}
ovdf_puf_lookup = {2018: 'h206f', 2017: 'h197f', 2016: 'h188f', 2015: 'h178f', 2014: 'h168f', 2013: 'h160f', 2012: 'h152f', 2011: 'h144f', 2010: 'h135f', 2009: 'h126f', 2008: 'h118f', 2007: 'h110f', 2006: 'h102f', 2005: 'h94f'}
obmpvdf_puf_lookup = {2018: 'h206g', 2017: 'h197g', 2016: 'h188g', 2015: 'h178g', 2014: 'h168g', 2013: 'h160g', 2012: 'h152g', 2011: 'h144g', 2010: 'h135g', 2009: 'h126g', 2008: 'h118g', 2007: 'h110g', 2006: 'h102g', 2005: 'h94g'}
hhdf_puf_lookup = {2018: 'h206h', 2017: 'h197h', 2016: 'h188h', 2015: 'h178h', 2014: 'h168h', 2013: 'h160h', 2012: 'h152h', 2011: 'h144h', 2010: 'h135h', 2009: 'h126h', 2008: 'h118h', 2007: 'h110h', 2006: 'h102h', 2005: 'h94h'} |
class CompositorNodeFlip:
axis = None
def update(self):
pass
| class Compositornodeflip:
axis = None
def update(self):
pass |
"""utility functions manipulating object data attributes"""
def get_params(imputer):
"""return general parameters of an imputer object
input
an imputer obj
output:
a dict of parameters"""
return {
'max_iter' : imputer.max_iter,
'init_imp' : imputer.init_imp,
'partition' : imputer.partition,
'n_nodes' : imputer.n_nodes,
'n_cores' : imputer.n_cores,
'memory' : imputer.memory,
'time' : imputer.time
}
def get_params_rf(imputer):
"""return random forest parameters of an imputer object
input
an imputer obj
output:
a dict of parameters"""
return {
'n_estimators' : imputer.n_estimators,
'max_depth' : imputer.max_depth,
'min_samples_split' : imputer.min_samples_split,
'min_samples_leaf' : imputer.min_samples_leaf,
'min_weight_fraction_leaf' : imputer.min_weight_fraction_leaf,
'max_features' : imputer.max_features,
'max_leaf_nodes' : imputer.max_leaf_nodes,
'min_impurity_decrease' : imputer.min_impurity_decrease,
'bootstrap' : imputer.bootstrap,
'n_jobs' : imputer.n_cores,
'random_state' : imputer.random_state,
'verbose' : imputer.verbose,
'warm_start' : imputer.warm_start,
'class_weight' : imputer.class_weight
} | """utility functions manipulating object data attributes"""
def get_params(imputer):
"""return general parameters of an imputer object
input
an imputer obj
output:
a dict of parameters"""
return {'max_iter': imputer.max_iter, 'init_imp': imputer.init_imp, 'partition': imputer.partition, 'n_nodes': imputer.n_nodes, 'n_cores': imputer.n_cores, 'memory': imputer.memory, 'time': imputer.time}
def get_params_rf(imputer):
"""return random forest parameters of an imputer object
input
an imputer obj
output:
a dict of parameters"""
return {'n_estimators': imputer.n_estimators, 'max_depth': imputer.max_depth, 'min_samples_split': imputer.min_samples_split, 'min_samples_leaf': imputer.min_samples_leaf, 'min_weight_fraction_leaf': imputer.min_weight_fraction_leaf, 'max_features': imputer.max_features, 'max_leaf_nodes': imputer.max_leaf_nodes, 'min_impurity_decrease': imputer.min_impurity_decrease, 'bootstrap': imputer.bootstrap, 'n_jobs': imputer.n_cores, 'random_state': imputer.random_state, 'verbose': imputer.verbose, 'warm_start': imputer.warm_start, 'class_weight': imputer.class_weight} |
def add_native_methods(clazz):
def flattenAlternative__com_sun_org_apache_xalan_internal_xsltc_compiler_Pattern__com_sun_org_apache_xalan_internal_xsltc_compiler_Template__java_util_Map_java_lang_String__com_sun_org_apache_xalan_internal_xsltc_compiler_Key___(a0, a1, a2, a3, a4):
raise NotImplementedError()
clazz.flattenAlternative__com_sun_org_apache_xalan_internal_xsltc_compiler_Pattern__com_sun_org_apache_xalan_internal_xsltc_compiler_Template__java_util_Map_java_lang_String__com_sun_org_apache_xalan_internal_xsltc_compiler_Key___ = flattenAlternative__com_sun_org_apache_xalan_internal_xsltc_compiler_Pattern__com_sun_org_apache_xalan_internal_xsltc_compiler_Template__java_util_Map_java_lang_String__com_sun_org_apache_xalan_internal_xsltc_compiler_Key___
| def add_native_methods(clazz):
def flatten_alternative__com_sun_org_apache_xalan_internal_xsltc_compiler__pattern__com_sun_org_apache_xalan_internal_xsltc_compiler__template__java_util__map_java_lang__string__com_sun_org_apache_xalan_internal_xsltc_compiler__key___(a0, a1, a2, a3, a4):
raise not_implemented_error()
clazz.flattenAlternative__com_sun_org_apache_xalan_internal_xsltc_compiler_Pattern__com_sun_org_apache_xalan_internal_xsltc_compiler_Template__java_util_Map_java_lang_String__com_sun_org_apache_xalan_internal_xsltc_compiler_Key___ = flattenAlternative__com_sun_org_apache_xalan_internal_xsltc_compiler_Pattern__com_sun_org_apache_xalan_internal_xsltc_compiler_Template__java_util_Map_java_lang_String__com_sun_org_apache_xalan_internal_xsltc_compiler_Key___ |
"""
8-9 code
"""
# c = 50
# def add(x,y):
# c = x + y
# print(c)
#
#
# add(1, 2)
# print(c)
# c = 10
# def demo():
# print(c)
#
#
# demo()
# def demo():
# c = 50
# for i in range(0,9):
# a = 'a'
# c += 1
# print(c)
# print(a)
#
#
# demo()
c = 1
def func1():
c = 2
def func2():
# c = 3
print(c)
func2()
func1()
| """
8-9 code
"""
c = 1
def func1():
c = 2
def func2():
print(c)
func2()
func1() |
entrada = str(input()).split(' ')
p = int(entrada[0])
j1 = int(entrada[1])
j2 = int(entrada[2])
r = int(entrada[3])
a = int(entrada[4])
if r == 0 and a == 0:
if (j1 + j2) % 2 == 0 and p == 1: print('Jogador 1 ganha!')
elif (j1 + j2) % 2 != 0 and p == 0: print('Jogador 1 ganha!')
else: print('Jogador 2 ganha!')
elif r == 1 and a == 0: print('Jogador 1 ganha!')
elif r == 0 and a == 1: print('Jogador 1 ganha!')
elif r == 1 and a == 1: print('Jogador 2 ganha!')
| entrada = str(input()).split(' ')
p = int(entrada[0])
j1 = int(entrada[1])
j2 = int(entrada[2])
r = int(entrada[3])
a = int(entrada[4])
if r == 0 and a == 0:
if (j1 + j2) % 2 == 0 and p == 1:
print('Jogador 1 ganha!')
elif (j1 + j2) % 2 != 0 and p == 0:
print('Jogador 1 ganha!')
else:
print('Jogador 2 ganha!')
elif r == 1 and a == 0:
print('Jogador 1 ganha!')
elif r == 0 and a == 1:
print('Jogador 1 ganha!')
elif r == 1 and a == 1:
print('Jogador 2 ganha!') |
with open("cells_to_link.txt", "r") as f:
lines = f.readlines()
def formTuples(x):
x = x.split()
return zip(x[0::2], x[1::2])
tuples_by_line = map(formTuples, lines)
vba = """Public loc_map As Collection
Private Sub Workbook_Open()
Set loc_map = New Collection"""
for index, tuples in enumerate(tuples_by_line):
vba = vba + """
ReDim loc_set(0 To """+ str(len(tuples) - 1) + """) As String
"""
for i, tup in enumerate(tuples):
vba = vba + """ loc_set(""" + str(i) + """) = \"""" + " ".join(tup) + """\"
"""
vba = vba + ("""
Dim loc As Variant
""" if index == 0 else "")
vba = vba + """
For i = 0 To UBound(loc_set)
loc_map.Add Minus(loc_set, loc_set(i)), loc_set(i)
Next
Erase loc_set
"""
vba = vba + """
End Sub
Private Function Minus(ByRef old_list() As String, loc As Variant) As String()
Dim split_loc() As String
split_loc = Split(loc)
Dim new_list() As String
ReDim new_list(0 To Application.CountA(old_list) - 1) As String
Dim i As Integer
i = 0
Dim Val As Variant
For Each Val In old_list
Dim split_val() As String
split_val = Split(Val)
If StrComp(split_val(0) = split_loc(0), vbTextCompare) <> 0 Or StrComp(split_val(1) = split_loc(1), vbTextCompare) <> 0 Then
new_list(i) = Val
i = i + 1
End If
Next
Minus = new_list
End Function
Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
Application.EnableEvents = False
Dim cur_loc As String
cur_loc = Target.address & " " & Target.Parent.name
If Contains(loc_map, cur_loc) = True Then
Dim loc As Variant
For Each loc In loc_map.Item(cur_loc)
Dim split_loc() As String
split_loc = Split(loc)
Sheets(split_loc(1)).Range(split_loc(0)).Value = Target.Value
Next
End If
Application.EnableEvents = True
End Sub
Public Function Contains(col As Collection, key As Variant) As Boolean
Dim obj As Variant
On Error GoTo err
Contains = True
obj = col(key)
Exit Function
err:
Contains = False
End Function"""
with open("vba_code.txt", "w") as f:
f.write(vba)
| with open('cells_to_link.txt', 'r') as f:
lines = f.readlines()
def form_tuples(x):
x = x.split()
return zip(x[0::2], x[1::2])
tuples_by_line = map(formTuples, lines)
vba = 'Public loc_map As Collection\n\nPrivate Sub Workbook_Open()\n\n Set loc_map = New Collection'
for (index, tuples) in enumerate(tuples_by_line):
vba = vba + '\n ReDim loc_set(0 To ' + str(len(tuples) - 1) + ') As String \n\n'
for (i, tup) in enumerate(tuples):
vba = vba + ' loc_set(' + str(i) + ') = "' + ' '.join(tup) + '"\n'
vba = vba + ('\n Dim loc As Variant\n' if index == 0 else '')
vba = vba + '\n For i = 0 To UBound(loc_set)\n loc_map.Add Minus(loc_set, loc_set(i)), loc_set(i)\n Next\n \n Erase loc_set\n'
vba = vba + '\nEnd Sub\n\nPrivate Function Minus(ByRef old_list() As String, loc As Variant) As String()\n\n Dim split_loc() As String\n split_loc = Split(loc)\n\n Dim new_list() As String\n ReDim new_list(0 To Application.CountA(old_list) - 1) As String\n\n Dim i As Integer\n i = 0\n\n Dim Val As Variant\n For Each Val In old_list\n Dim split_val() As String\n split_val = Split(Val)\n If StrComp(split_val(0) = split_loc(0), vbTextCompare) <> 0 Or StrComp(split_val(1) = split_loc(1), vbTextCompare) <> 0 Then\n new_list(i) = Val\n i = i + 1\n End If\n Next\n \n Minus = new_list\n \nEnd Function\n\nPrivate Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)\n Application.EnableEvents = False\n Dim cur_loc As String\n cur_loc = Target.address & " " & Target.Parent.name\n If Contains(loc_map, cur_loc) = True Then\n Dim loc As Variant\n For Each loc In loc_map.Item(cur_loc)\n Dim split_loc() As String\n split_loc = Split(loc)\n Sheets(split_loc(1)).Range(split_loc(0)).Value = Target.Value\n Next\n End If\n Application.EnableEvents = True\nEnd Sub\n\nPublic Function Contains(col As Collection, key As Variant) As Boolean\n Dim obj As Variant\n On Error GoTo err\n Contains = True\n obj = col(key)\n Exit Function\nerr:\n Contains = False\nEnd Function'
with open('vba_code.txt', 'w') as f:
f.write(vba) |
class CatalogPage:
"""
Class for page in Catalog tree
"""
name = ''
url = ''
is_index = False
parent = None
subpages_cache = []
def get_subpages_internal(self):
return []
def get_subpages(self):
if not self.subpages_cache:
subpages_cache = self.get_subpages_internal()
return subpages_cache
def get_subpage(self, url):
subpages = self.get_subpages()
for page in subpages:
if page.url == url:
return page
return None
# pylint: disable=too-many-arguments
def __init__(
self, name='', url='', instance=None, is_index=False, parent=None):
self.is_index = is_index
self.parent = parent
if instance:
self.name = str(instance)
self.url = instance.get_absolute_url()
else:
self.name = str(name)
self.url = url
def get_index(self):
if self.is_index:
return self
if self.parent:
return self.parent.get_index()
return None
def get_breadcrumbs(self):
if self.parent:
return self.parent.get_breadcrumbs() + [self]
return [self]
def render_selected(self):
return self.name
def render(self):
return '<a href="%s">%s</a>' % (self.url, self.name)
def get_caption(self):
caption = self.name
if caption:
caption = caption[0].upper() + caption[1:]
return caption
def catalog_index(self, subpage='', rendered_subpage=''):
subpages = self.get_subpages()
if subpages:
result = ''
for page in subpages:
if page.name == subpage:
if rendered_subpage:
result = '%s<li>%s</li>' % (result, rendered_subpage,)
else:
result = '%s<li>%s</li>' % (
result, page.render_selected(),)
else:
result = '%s<li>%s</li>' % (result, page.render(),)
result = '<ul class="catalogindex">%s</ul>' % (result, )
else:
if rendered_subpage:
result = '%s<ul><li>%s</li></ul>' % (
self.render(), rendered_subpage)
else:
result = self.name
result = '<ul class="catalogindex"><li>%s</li></ul>' % (result,)
if self.is_index or (not self.parent):
return result
return self.parent.catalog_index(self.name, result)
def catalog_caption(self):
if self.is_index or (not self.parent):
return self.get_caption()
return "%s - %s" % (
self.parent.catalog_caption(), self.get_caption())
| class Catalogpage:
"""
Class for page in Catalog tree
"""
name = ''
url = ''
is_index = False
parent = None
subpages_cache = []
def get_subpages_internal(self):
return []
def get_subpages(self):
if not self.subpages_cache:
subpages_cache = self.get_subpages_internal()
return subpages_cache
def get_subpage(self, url):
subpages = self.get_subpages()
for page in subpages:
if page.url == url:
return page
return None
def __init__(self, name='', url='', instance=None, is_index=False, parent=None):
self.is_index = is_index
self.parent = parent
if instance:
self.name = str(instance)
self.url = instance.get_absolute_url()
else:
self.name = str(name)
self.url = url
def get_index(self):
if self.is_index:
return self
if self.parent:
return self.parent.get_index()
return None
def get_breadcrumbs(self):
if self.parent:
return self.parent.get_breadcrumbs() + [self]
return [self]
def render_selected(self):
return self.name
def render(self):
return '<a href="%s">%s</a>' % (self.url, self.name)
def get_caption(self):
caption = self.name
if caption:
caption = caption[0].upper() + caption[1:]
return caption
def catalog_index(self, subpage='', rendered_subpage=''):
subpages = self.get_subpages()
if subpages:
result = ''
for page in subpages:
if page.name == subpage:
if rendered_subpage:
result = '%s<li>%s</li>' % (result, rendered_subpage)
else:
result = '%s<li>%s</li>' % (result, page.render_selected())
else:
result = '%s<li>%s</li>' % (result, page.render())
result = '<ul class="catalogindex">%s</ul>' % (result,)
else:
if rendered_subpage:
result = '%s<ul><li>%s</li></ul>' % (self.render(), rendered_subpage)
else:
result = self.name
result = '<ul class="catalogindex"><li>%s</li></ul>' % (result,)
if self.is_index or not self.parent:
return result
return self.parent.catalog_index(self.name, result)
def catalog_caption(self):
if self.is_index or not self.parent:
return self.get_caption()
return '%s - %s' % (self.parent.catalog_caption(), self.get_caption()) |
# -*- coding:utf-8 -*-
#https://leetcode.com/problems/valid-parentheses/description/
class Solution(object):
def isValid(self, s):
"""
:type s: str
:rtype: bool
"""
stack = []
for ch in s:
if ch == '(':
stack.append(')')
elif ch == '{':
stack.append('}')
elif ch == '[':
stack.append(']')
elif not stack or stack.pop() != ch:
return False
return not stack | class Solution(object):
def is_valid(self, s):
"""
:type s: str
:rtype: bool
"""
stack = []
for ch in s:
if ch == '(':
stack.append(')')
elif ch == '{':
stack.append('}')
elif ch == '[':
stack.append(']')
elif not stack or stack.pop() != ch:
return False
return not stack |
# -*- coding: utf-8 -*-
class VariableTypeAlreadyRegistered(Exception):
pass
class InvalidType(Exception):
pass
| class Variabletypealreadyregistered(Exception):
pass
class Invalidtype(Exception):
pass |
# Find Pivot Index
'''
Given an array of integers nums, write a method that returns the "pivot" index of this array.
We define the pivot index as the index where the sum of all the numbers to the left of the index is equal to the sum of all the numbers to the right of the index.
If no such index exists, we should return -1. If there are multiple pivot indexes, you should return the left-most pivot index.
Example 1:
Input: nums = [1,7,3,6,5,6]
Output: 3
Explanation:
The sum of the numbers to the left of index 3 (nums[3] = 6) is equal to the sum of numbers to the right of index 3.
Also, 3 is the first index where this occurs.
Example 2:
Input: nums = [1,2,3]
Output: -1
Explanation:
There is no index that satisfies the conditions in the problem statement.
Constraints:
The length of nums will be in the range [0, 10000].
Each element nums[i] will be an integer in the range [-1000, 1000].
Hide Hint #1
We can precompute prefix sums P[i] = nums[0] + nums[1] + ... + nums[i-1]. Then for each index, the left sum is P[i], and the right sum is P[P.length - 1] - P[i] - nums[i].
'''
class Solution:
def pivotIndex(self, nums: List[int]) -> int:
if not nums:
return -1
lsum = 0
rsum = sum(nums)
for i in range(len(nums)):
rsum -= nums[i]
if rsum == lsum:
return i
lsum += nums[i]
return -1
| """
Given an array of integers nums, write a method that returns the "pivot" index of this array.
We define the pivot index as the index where the sum of all the numbers to the left of the index is equal to the sum of all the numbers to the right of the index.
If no such index exists, we should return -1. If there are multiple pivot indexes, you should return the left-most pivot index.
Example 1:
Input: nums = [1,7,3,6,5,6]
Output: 3
Explanation:
The sum of the numbers to the left of index 3 (nums[3] = 6) is equal to the sum of numbers to the right of index 3.
Also, 3 is the first index where this occurs.
Example 2:
Input: nums = [1,2,3]
Output: -1
Explanation:
There is no index that satisfies the conditions in the problem statement.
Constraints:
The length of nums will be in the range [0, 10000].
Each element nums[i] will be an integer in the range [-1000, 1000].
Hide Hint #1
We can precompute prefix sums P[i] = nums[0] + nums[1] + ... + nums[i-1]. Then for each index, the left sum is P[i], and the right sum is P[P.length - 1] - P[i] - nums[i].
"""
class Solution:
def pivot_index(self, nums: List[int]) -> int:
if not nums:
return -1
lsum = 0
rsum = sum(nums)
for i in range(len(nums)):
rsum -= nums[i]
if rsum == lsum:
return i
lsum += nums[i]
return -1 |
#!/usr/local/bin/python3.5 -u
answer = 42
print(answer)
| answer = 42
print(answer) |
"""
from datetime import datetime
from django.db import models
from workflow.models import Program, ProjectAgreement
from .service import StartEndDates
class TrainingAttendance(StartEndDates):
training_name = models.CharField(max_length=255)
program = models.ForeignKey(
Program, null=True, blank=True, on_delete=models.SET_NULL)
project_agreement = models.ForeignKey(
ProjectAgreement, null=True, blank=True,
verbose_name="Project Initiation", on_delete=models.SET_NULL)
implementer = models.CharField(max_length=255, null=True, blank=True)
reporting_period = models.CharField(max_length=255, null=True, blank=True)
total_participants = models.IntegerField(null=True, blank=True)
location = models.CharField(max_length=255, null=True, blank=True)
community = models.CharField(max_length=255, null=True, blank=True)
training_duration = models.CharField(max_length=255, null=True, blank=True)
trainer_name = models.CharField(max_length=255, null=True, blank=True)
trainer_contact_num = models.CharField(
max_length=255, null=True, blank=True)
form_filled_by = models.CharField(max_length=255, null=True, blank=True)
form_filled_by_contact_num = models.CharField(
max_length=255, null=True, blank=True)
total_male = models.IntegerField(null=True, blank=True)
total_female = models.IntegerField(null=True, blank=True)
total_age_0_14_male = models.IntegerField(null=True, blank=True)
total_age_0_14_female = models.IntegerField(null=True, blank=True)
total_age_15_24_male = models.IntegerField(null=True, blank=True)
total_age_15_24_female = models.IntegerField(null=True, blank=True)
total_age_25_59_male = models.IntegerField(null=True, blank=True)
total_age_25_59_female = models.IntegerField(null=True, blank=True)
create_date = models.DateTimeField(null=True, blank=True)
edit_date = models.DateTimeField(null=True, blank=True)
class Meta:
ordering = ('training_name',)
# on save add create date or update edit date
def save(self, *args, **kwargs):
if self.create_date is None:
self.create_date = datetime.now()
self.edit_date = datetime.now()
super(TrainingAttendance, self).save()
# displayed in admin templates
def __str__(self):
return self.training_name
# ? Attendance tracking needs more reflexion
# ? Tracking of attendance needs the notion of a session/class: track the `attendees`
# ? from the list of registered into the program
# class Attendance(models.Model):
# Attendance "sheet" to keep track of Individuals/Household participations to trainings.
# Spec: https://github.com/hikaya-io/activity/issues/422
# number_of_sessions = models.IntegerField()
"""
| """
from datetime import datetime
from django.db import models
from workflow.models import Program, ProjectAgreement
from .service import StartEndDates
class TrainingAttendance(StartEndDates):
training_name = models.CharField(max_length=255)
program = models.ForeignKey(
Program, null=True, blank=True, on_delete=models.SET_NULL)
project_agreement = models.ForeignKey(
ProjectAgreement, null=True, blank=True,
verbose_name="Project Initiation", on_delete=models.SET_NULL)
implementer = models.CharField(max_length=255, null=True, blank=True)
reporting_period = models.CharField(max_length=255, null=True, blank=True)
total_participants = models.IntegerField(null=True, blank=True)
location = models.CharField(max_length=255, null=True, blank=True)
community = models.CharField(max_length=255, null=True, blank=True)
training_duration = models.CharField(max_length=255, null=True, blank=True)
trainer_name = models.CharField(max_length=255, null=True, blank=True)
trainer_contact_num = models.CharField(
max_length=255, null=True, blank=True)
form_filled_by = models.CharField(max_length=255, null=True, blank=True)
form_filled_by_contact_num = models.CharField(
max_length=255, null=True, blank=True)
total_male = models.IntegerField(null=True, blank=True)
total_female = models.IntegerField(null=True, blank=True)
total_age_0_14_male = models.IntegerField(null=True, blank=True)
total_age_0_14_female = models.IntegerField(null=True, blank=True)
total_age_15_24_male = models.IntegerField(null=True, blank=True)
total_age_15_24_female = models.IntegerField(null=True, blank=True)
total_age_25_59_male = models.IntegerField(null=True, blank=True)
total_age_25_59_female = models.IntegerField(null=True, blank=True)
create_date = models.DateTimeField(null=True, blank=True)
edit_date = models.DateTimeField(null=True, blank=True)
class Meta:
ordering = ('training_name',)
# on save add create date or update edit date
def save(self, *args, **kwargs):
if self.create_date is None:
self.create_date = datetime.now()
self.edit_date = datetime.now()
super(TrainingAttendance, self).save()
# displayed in admin templates
def __str__(self):
return self.training_name
# ? Attendance tracking needs more reflexion
# ? Tracking of attendance needs the notion of a session/class: track the `attendees`
# ? from the list of registered into the program
# class Attendance(models.Model):
# Attendance "sheet" to keep track of Individuals/Household participations to trainings.
# Spec: https://github.com/hikaya-io/activity/issues/422
# number_of_sessions = models.IntegerField()
""" |
#!/bin/python3
h = list(map(int, input().strip().split(' ')))
word = input().strip()
max_height = 0
for w in word:
i = ord(w)-97
max_height = max(max_height, h[i])
print (len(word)*max_height)
| h = list(map(int, input().strip().split(' ')))
word = input().strip()
max_height = 0
for w in word:
i = ord(w) - 97
max_height = max(max_height, h[i])
print(len(word) * max_height) |
def hangman(word, letters):
result = 0
a = 0
for item in letters:
if 6 <= a:
return False
b = word.count(item)
if 0 == b:
a += 1
else:
result += b
return len(word) == result
| def hangman(word, letters):
result = 0
a = 0
for item in letters:
if 6 <= a:
return False
b = word.count(item)
if 0 == b:
a += 1
else:
result += b
return len(word) == result |
class AreaKnowledge:
def __init__(self, text=None):
self.text = text
self._peoples_names = set()
self.peoples_info = list()
def set_text(self, text):
self.text = text
def update_people_photos(self, persons):
for person in persons:
self.update_people_photo(person.display_name, person.photo_id)
def update_people_photo(self, name, photo_id):
if name not in self._peoples_names:
return
for p in self.peoples_info:
if name == p['name']:
p['photo_id'] = photo_id
return
def add_people_names(self, names):
for name in names:
self.add_people(name, None)
def add_people(self, name, photo_id):
if name in self._peoples_names:
return
else:
self._peoples_names.add(name)
self.peoples_info.append(dict(name=name, photo_id=photo_id))
def get_mapping(self):
return dict(
area=self.text,
peoples=self.peoples_info
)
| class Areaknowledge:
def __init__(self, text=None):
self.text = text
self._peoples_names = set()
self.peoples_info = list()
def set_text(self, text):
self.text = text
def update_people_photos(self, persons):
for person in persons:
self.update_people_photo(person.display_name, person.photo_id)
def update_people_photo(self, name, photo_id):
if name not in self._peoples_names:
return
for p in self.peoples_info:
if name == p['name']:
p['photo_id'] = photo_id
return
def add_people_names(self, names):
for name in names:
self.add_people(name, None)
def add_people(self, name, photo_id):
if name in self._peoples_names:
return
else:
self._peoples_names.add(name)
self.peoples_info.append(dict(name=name, photo_id=photo_id))
def get_mapping(self):
return dict(area=self.text, peoples=self.peoples_info) |
class PTestException(Exception):
pass
class ScreenshotError(PTestException):
pass
| class Ptestexception(Exception):
pass
class Screenshoterror(PTestException):
pass |
# -*- coding: utf-8 -*-
"""
smallparts.text
text subpackage
"""
# vim:fileencoding=utf-8 autoindent ts=4 sw=4 sts=4 expandtab:
| """
smallparts.text
text subpackage
""" |
#
# PySNMP MIB module BFD-STD-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/BFD-STD-MIB
# Produced by pysmi-0.3.4 at Wed May 1 11:37:46 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27 2019, 09:23:15)
#
OctetString, Integer, ObjectIdentifier = mibBuilder.importSymbols("ASN1", "OctetString", "Integer", "ObjectIdentifier")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ConstraintsUnion, ValueSizeConstraint, ConstraintsIntersection, ValueRangeConstraint, SingleValueConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ConstraintsUnion", "ValueSizeConstraint", "ConstraintsIntersection", "ValueRangeConstraint", "SingleValueConstraint")
BfdSessIndexTC, BfdMultiplierTC, BfdIntervalTC, BfdCtrlSourcePortNumberTC, BfdCtrlDestPortNumberTC = mibBuilder.importSymbols("BFD-TC-STD-MIB", "BfdSessIndexTC", "BfdMultiplierTC", "BfdIntervalTC", "BfdCtrlSourcePortNumberTC", "BfdCtrlDestPortNumberTC")
IndexIntegerNextFree, = mibBuilder.importSymbols("DIFFSERV-DSCP-TC", "IndexIntegerNextFree")
IANAbfdSessAuthenticationTypeTC, IANAbfdSessAuthenticationKeyTC, IANAbfdSessTypeTC, IANAbfdDiagTC, IANAbfdSessStateTC, IANAbfdSessOperModeTC = mibBuilder.importSymbols("IANA-BFD-TC-STD-MIB", "IANAbfdSessAuthenticationTypeTC", "IANAbfdSessAuthenticationKeyTC", "IANAbfdSessTypeTC", "IANAbfdDiagTC", "IANAbfdSessStateTC", "IANAbfdSessOperModeTC")
InterfaceIndexOrZero, = mibBuilder.importSymbols("IF-MIB", "InterfaceIndexOrZero")
InetAddress, InetPortNumber, InetAddressType = mibBuilder.importSymbols("INET-ADDRESS-MIB", "InetAddress", "InetPortNumber", "InetAddressType")
NotificationGroup, ObjectGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ObjectGroup", "ModuleCompliance")
MibIdentifier, Bits, NotificationType, TimeTicks, ModuleIdentity, Gauge32, Unsigned32, Counter64, IpAddress, ObjectIdentity, Counter32, iso, MibScalar, MibTable, MibTableRow, MibTableColumn, Integer32, mib_2 = mibBuilder.importSymbols("SNMPv2-SMI", "MibIdentifier", "Bits", "NotificationType", "TimeTicks", "ModuleIdentity", "Gauge32", "Unsigned32", "Counter64", "IpAddress", "ObjectIdentity", "Counter32", "iso", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "Integer32", "mib-2")
TimeStamp, TextualConvention, RowStatus, TruthValue, StorageType, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TimeStamp", "TextualConvention", "RowStatus", "TruthValue", "StorageType", "DisplayString")
bfdMIB = ModuleIdentity((1, 3, 6, 1, 2, 1, 222))
bfdMIB.setRevisions(('2014-08-12 00:00',))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts: bfdMIB.setRevisionsDescriptions(('Initial version. Published as RFC 7331.',))
if mibBuilder.loadTexts: bfdMIB.setLastUpdated('201408120000Z')
if mibBuilder.loadTexts: bfdMIB.setOrganization('IETF Bidirectional Forwarding Detection Working Group')
if mibBuilder.loadTexts: bfdMIB.setContactInfo('Thomas D. Nadeau Brocade Email: tnadeau@lucidvision.com Zafar Ali Cisco Systems, Inc. Email: zali@cisco.com Nobo Akiya Cisco Systems, Inc. Email: nobo@cisco.com Comments about this document should be emailed directly to the BFD Working Group mailing list at rtg-bfd@ietf.org')
if mibBuilder.loadTexts: bfdMIB.setDescription("Bidirectional Forwarding Management Information Base. Copyright (c) 2014 IETF Trust and the persons identified as authors of the code. All rights reserved. Redistribution and use in source and binary forms, with or without modification, is permitted pursuant to, and subject to the license terms contained in, the Simplified BSD License set forth in Section 4.c of the IETF Trust's Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info).")
bfdNotifications = MibIdentifier((1, 3, 6, 1, 2, 1, 222, 0))
bfdObjects = MibIdentifier((1, 3, 6, 1, 2, 1, 222, 1))
bfdConformance = MibIdentifier((1, 3, 6, 1, 2, 1, 222, 2))
bfdScalarObjects = MibIdentifier((1, 3, 6, 1, 2, 1, 222, 1, 1))
bfdAdminStatus = MibScalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("enabled", 1), ("disabled", 2), ("adminDown", 3), ("down", 4)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: bfdAdminStatus.setStatus('current')
if mibBuilder.loadTexts: bfdAdminStatus.setDescription('The desired global administrative status of the BFD system in this device.')
bfdOperStatus = MibScalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("up", 1), ("down", 2), ("adminDown", 3)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdOperStatus.setStatus('current')
if mibBuilder.loadTexts: bfdOperStatus.setDescription('Indicates the actual operational status of the BFD system in this device. When this value is down(2), all entries in the bfdSessTable MUST have their bfdSessOperStatus as down(2) as well. When this value is adminDown(3), all entries in the bfdSessTable MUST have their bfdSessOperStatus as adminDown(3) as well.')
bfdNotificationsEnable = MibScalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 3), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: bfdNotificationsEnable.setReference('See also RFC3413 for explanation that notifications are under the ultimate control of the MIB modules in this document.')
if mibBuilder.loadTexts: bfdNotificationsEnable.setStatus('current')
if mibBuilder.loadTexts: bfdNotificationsEnable.setDescription('If this object is set to true(1), then it enables the emission of bfdSessUp and bfdSessDown notifications; otherwise these notifications are not emitted.')
bfdSessIndexNext = MibScalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 4), IndexIntegerNextFree().subtype(subtypeSpec=ValueRangeConstraint(0, 4294967295))).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessIndexNext.setStatus('current')
if mibBuilder.loadTexts: bfdSessIndexNext.setDescription('This object contains an unused value for bfdSessIndex that can be used when creating entries in the table. A zero indicates that no entries are available, but MUST NOT be used as a valid index. ')
bfdSessTable = MibTable((1, 3, 6, 1, 2, 1, 222, 1, 2), )
if mibBuilder.loadTexts: bfdSessTable.setReference('Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessTable.setStatus('current')
if mibBuilder.loadTexts: bfdSessTable.setDescription('The BFD Session Table describes the BFD sessions.')
bfdSessEntry = MibTableRow((1, 3, 6, 1, 2, 1, 222, 1, 2, 1), ).setIndexNames((0, "BFD-STD-MIB", "bfdSessIndex"))
if mibBuilder.loadTexts: bfdSessEntry.setStatus('current')
if mibBuilder.loadTexts: bfdSessEntry.setDescription('The BFD Session Entry describes BFD session.')
bfdSessIndex = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 1), BfdSessIndexTC())
if mibBuilder.loadTexts: bfdSessIndex.setStatus('current')
if mibBuilder.loadTexts: bfdSessIndex.setDescription('This object contains an index used to represent a unique BFD session on this device. Managers should obtain new values for row creation in this table by reading bfdSessIndexNext.')
bfdSessVersionNumber = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 2), Unsigned32().subtype(subtypeSpec=ValueRangeConstraint(0, 7)).clone(1)).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessVersionNumber.setReference('Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessVersionNumber.setStatus('current')
if mibBuilder.loadTexts: bfdSessVersionNumber.setDescription('The version number of the BFD protocol that this session is running in. Write access is available for this object to provide ability to set desired version for this BFD session.')
bfdSessType = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 3), IANAbfdSessTypeTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessType.setStatus('current')
if mibBuilder.loadTexts: bfdSessType.setDescription('This object specifies the type of this BFD session.')
bfdSessDiscriminator = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 4), Unsigned32().subtype(subtypeSpec=ValueRangeConstraint(1, 4294967295))).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessDiscriminator.setStatus('current')
if mibBuilder.loadTexts: bfdSessDiscriminator.setDescription('This object specifies the local discriminator for this BFD session, used to uniquely identify it.')
bfdSessRemoteDiscr = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 5), Unsigned32().subtype(subtypeSpec=ConstraintsUnion(ValueRangeConstraint(0, 0), ValueRangeConstraint(1, 4294967295), ))).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessRemoteDiscr.setReference('Section 6.8.6, from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessRemoteDiscr.setStatus('current')
if mibBuilder.loadTexts: bfdSessRemoteDiscr.setDescription('This object specifies the session discriminator chosen by the remote system for this BFD session. The value may be zero(0) if the remote discriminator is not yet known or if the session is in the down or adminDown(1) state.')
bfdSessDestinationUdpPort = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 6), BfdCtrlDestPortNumberTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessDestinationUdpPort.setStatus('current')
if mibBuilder.loadTexts: bfdSessDestinationUdpPort.setDescription("This object specifies the destination UDP port number used for this BFD session's control packets. The value may be zero(0) if the session is in adminDown(1) state.")
bfdSessSourceUdpPort = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 7), BfdCtrlSourcePortNumberTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessSourceUdpPort.setStatus('current')
if mibBuilder.loadTexts: bfdSessSourceUdpPort.setDescription("This object specifies the source UDP port number used for this BFD session's control packets. The value may be zero(0) if the session is in adminDown(1) state. Upon creation of a new BFD session via this MIB, the value of zero(0) specified would permit the implementation to choose its own source port number.")
bfdSessEchoSourceUdpPort = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 8), InetPortNumber()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessEchoSourceUdpPort.setStatus('current')
if mibBuilder.loadTexts: bfdSessEchoSourceUdpPort.setDescription("This object specifies the source UDP port number used for this BFD session's echo packets. The value may be zero(0) if the session is not running in the echo mode, or the session is in adminDown(1) state. Upon creation of a new BFD session via this MIB, the value of zero(0) would permit the implementation to choose its own source port number.")
bfdSessAdminStatus = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 9), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("enabled", 1), ("disabled", 2), ("adminDown", 3), ("down", 4)))).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessAdminStatus.setStatus('current')
if mibBuilder.loadTexts: bfdSessAdminStatus.setDescription('Denotes the desired operational status of the BFD Session. A transition to enabled(1) will start the BFD state machine for the session. The state machine will have an initial state of down(2). A transition to disabled(2) will stop the BFD state machine for the session. The state machine may first transition to adminDown(1) prior to stopping. A transition to adminDown(3) will cause the BFD state machine to transition to adminDown(1), and will cause the session to remain in this state. A transition to down(4) will cause the BFD state machine to transition to down(2), and will cause the session to remain in this state. Care should be used in providing write access to this object without adequate authentication.')
bfdSessOperStatus = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 10), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("up", 1), ("down", 2), ("adminDown", 3)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessOperStatus.setStatus('current')
if mibBuilder.loadTexts: bfdSessOperStatus.setDescription('Denotes the actual operational status of the BFD Session. If the value of bfdOperStatus is down(2), this value MUST eventually be down(2) as well. If the value of bfdOperStatus is adminDown(3), this value MUST eventually be adminDown(3) as well.')
bfdSessState = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 11), IANAbfdSessStateTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessState.setStatus('current')
if mibBuilder.loadTexts: bfdSessState.setDescription('Configured BFD session state.')
bfdSessRemoteHeardFlag = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 12), TruthValue()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessRemoteHeardFlag.setReference('Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessRemoteHeardFlag.setStatus('current')
if mibBuilder.loadTexts: bfdSessRemoteHeardFlag.setDescription('This object specifies status of BFD packet reception from the remote system. Specifically, it is set to true(1) if the local system is actively receiving BFD packets from the remote system, and is set to false(2) if the local system has not received BFD packets recently (within the detection time) or if the local system is attempting to tear down the BFD session.')
bfdSessDiag = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 13), IANAbfdDiagTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessDiag.setStatus('current')
if mibBuilder.loadTexts: bfdSessDiag.setDescription("A diagnostic code specifying the local system's reason for the last transition of the session from up(4) to some other state.")
bfdSessOperMode = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 14), IANAbfdSessOperModeTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessOperMode.setStatus('current')
if mibBuilder.loadTexts: bfdSessOperMode.setDescription('This object specifies the operational mode of this BFD session.')
bfdSessDemandModeDesiredFlag = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 15), TruthValue().clone('false')).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessDemandModeDesiredFlag.setStatus('current')
if mibBuilder.loadTexts: bfdSessDemandModeDesiredFlag.setDescription("This object indicates that the local system's desire to use Demand mode. Specifically, it is set to true(1) if the local system wishes to use Demand mode or false(2) if not")
bfdSessControlPlaneIndepFlag = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 16), TruthValue().clone('false')).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessControlPlaneIndepFlag.setStatus('current')
if mibBuilder.loadTexts: bfdSessControlPlaneIndepFlag.setDescription("This object indicates that the local system's ability to continue to function through a disruption of the control plane. Specifically, it is set to true(1) if the local system BFD implementation is independent of the control plane. Otherwise, the value is set to false(2)")
bfdSessMultipointFlag = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 17), TruthValue().clone('false')).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessMultipointFlag.setStatus('current')
if mibBuilder.loadTexts: bfdSessMultipointFlag.setDescription('This object indicates the Multipoint (M) bit for this session. It is set to true(1) if Multipoint (M) bit is set to 1. Otherwise, the value is set to false(2)')
bfdSessInterface = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 18), InterfaceIndexOrZero()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessInterface.setStatus('current')
if mibBuilder.loadTexts: bfdSessInterface.setDescription('This object contains an interface index used to indicate the interface which this BFD session is running on. This value can be zero if there is no interface associated with this BFD session.')
bfdSessSrcAddrType = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 19), InetAddressType()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessSrcAddrType.setStatus('current')
if mibBuilder.loadTexts: bfdSessSrcAddrType.setDescription('This object specifies IP address type of the source IP address of this BFD session. The value of unknown(0) is allowed only when the session is singleHop(1) and the source IP address of this BFD session is derived from the outgoing interface, or when the BFD session is not associated with a specific interface. If any other unsupported values are attempted in a set operation, the agent MUST return an inconsistentValue error.')
bfdSessSrcAddr = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 20), InetAddress().subtype(subtypeSpec=ValueSizeConstraint(4, 4)).setFixedLength(4)).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessSrcAddr.setStatus('current')
if mibBuilder.loadTexts: bfdSessSrcAddr.setDescription('This object specifies the source IP address of this BFD session. The format of this object is controlled by the bfdSessSrcAddrType object.')
bfdSessDstAddrType = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 21), InetAddressType()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessDstAddrType.setStatus('current')
if mibBuilder.loadTexts: bfdSessDstAddrType.setDescription('This object specifies IP address type of the neighboring IP address which is being monitored with this BFD session. The value of unknown(0) is allowed only when the session is singleHop(1) and the outgoing interface is of type point-to-point, or when the BFD session is not associated with a specific interface. If any other unsupported values are attempted in a set operation, the agent MUST return an inconsistentValue error.')
bfdSessDstAddr = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 22), InetAddress().subtype(subtypeSpec=ValueSizeConstraint(4, 4)).setFixedLength(4)).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessDstAddr.setStatus('current')
if mibBuilder.loadTexts: bfdSessDstAddr.setDescription('This object specifies the neighboring IP address which is being monitored with this BFD session. The format of this object is controlled by the bfdSessDstAddrType object.')
bfdSessGTSM = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 23), TruthValue().clone('true')).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessGTSM.setReference('RFC5082, The Generalized TTL Security Mechanism (GTSM). RFC5881, Section 5')
if mibBuilder.loadTexts: bfdSessGTSM.setStatus('current')
if mibBuilder.loadTexts: bfdSessGTSM.setDescription('Setting the value of this object to false(2) will disable GTSM protection of the BFD session. GTSM MUST be enabled on a singleHop(1) session if no authentication is in use.')
bfdSessGTSMTTL = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 24), Unsigned32().subtype(subtypeSpec=ValueRangeConstraint(0, 255)).clone(255)).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessGTSMTTL.setReference('RFC5082, The Generalized TTL Security Mechanism (GTSM). RFC5881, Section 5')
if mibBuilder.loadTexts: bfdSessGTSMTTL.setStatus('current')
if mibBuilder.loadTexts: bfdSessGTSMTTL.setDescription('This object is valid only when bfdSessGTSM protection is enabled on the system. This object indicates the minimum allowed TTL for received BFD control packets. For a singleHop(1) session, if GTSM protection is enabled, this object SHOULD be set to maximum TTL value allowed for single hop. By default, GTSM is enabled and TTL value is 255. For a multihop session, updating of maximum TTL value allowed is likely required.')
bfdSessDesiredMinTxInterval = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 25), BfdIntervalTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessDesiredMinTxInterval.setReference('Section 4.1 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessDesiredMinTxInterval.setStatus('current')
if mibBuilder.loadTexts: bfdSessDesiredMinTxInterval.setDescription('This object specifies the minimum interval, in microseconds, that the local system would like to use when transmitting BFD Control packets. The value of zero(0) is reserved in this case, and should not be used.')
bfdSessReqMinRxInterval = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 26), BfdIntervalTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessReqMinRxInterval.setReference('Section 4.1 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessReqMinRxInterval.setStatus('current')
if mibBuilder.loadTexts: bfdSessReqMinRxInterval.setDescription('This object specifies the minimum interval, in microseconds, between received BFD Control packets the local system is capable of supporting. The value of zero(0) can be specified when the transmitting system does not want the remote system to send any periodic BFD control packets.')
bfdSessReqMinEchoRxInterval = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 27), BfdIntervalTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessReqMinEchoRxInterval.setStatus('current')
if mibBuilder.loadTexts: bfdSessReqMinEchoRxInterval.setDescription('This object specifies the minimum interval, in microseconds, between received BFD Echo packets that this system is capable of supporting. Value must be zero(0) if this is a multihop BFD session.')
bfdSessDetectMult = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 28), BfdMultiplierTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessDetectMult.setStatus('current')
if mibBuilder.loadTexts: bfdSessDetectMult.setDescription('This object specifies the Detect time multiplier.')
bfdSessNegotiatedInterval = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 29), BfdIntervalTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessNegotiatedInterval.setStatus('current')
if mibBuilder.loadTexts: bfdSessNegotiatedInterval.setDescription('This object specifies the negotiated interval, in microseconds, that the local system is transmitting BFD Control packets.')
bfdSessNegotiatedEchoInterval = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 30), BfdIntervalTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessNegotiatedEchoInterval.setStatus('current')
if mibBuilder.loadTexts: bfdSessNegotiatedEchoInterval.setDescription('This object specifies the negotiated interval, in microseconds, that the local system is transmitting BFD echo packets. Value is expected to be zero if the sessions is not running in echo mode.')
bfdSessNegotiatedDetectMult = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 31), BfdMultiplierTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessNegotiatedDetectMult.setStatus('current')
if mibBuilder.loadTexts: bfdSessNegotiatedDetectMult.setDescription('This object specifies the Detect time multiplier.')
bfdSessAuthPresFlag = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 32), TruthValue().clone('false')).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessAuthPresFlag.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessAuthPresFlag.setStatus('current')
if mibBuilder.loadTexts: bfdSessAuthPresFlag.setDescription("This object indicates that the local system's desire to use Authentication. Specifically, it is set to true(1) if the local system wishes the session to be authenticated or false(2) if not.")
bfdSessAuthenticationType = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 33), IANAbfdSessAuthenticationTypeTC().clone('noAuthentication')).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessAuthenticationType.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessAuthenticationType.setStatus('current')
if mibBuilder.loadTexts: bfdSessAuthenticationType.setDescription('The Authentication Type used for this BFD session. This field is valid only when the Authentication Present bit is set. Max-access to this object as well as other authentication related objects are set to read-create in order to support management of a single key ID at a time, key rotation is not handled. Key update in practice must be done by atomic update using a set containing all affected objects in the same varBindList or otherwise risk the session dropping.')
bfdSessAuthenticationKeyID = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 34), Integer32().subtype(subtypeSpec=ConstraintsUnion(ValueRangeConstraint(-1, -1), ValueRangeConstraint(0, 255), )).clone(-1)).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessAuthenticationKeyID.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessAuthenticationKeyID.setStatus('current')
if mibBuilder.loadTexts: bfdSessAuthenticationKeyID.setDescription('The authentication key ID in use for this session. This object permits multiple keys to be active simultaneously. The value -1 indicates that no Authentication Key ID will be present in the optional BFD Authentication Section.')
bfdSessAuthenticationKey = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 35), IANAbfdSessAuthenticationKeyTC()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessAuthenticationKey.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts: bfdSessAuthenticationKey.setStatus('current')
if mibBuilder.loadTexts: bfdSessAuthenticationKey.setDescription('The authentication key. When the bfdSessAuthenticationType is simplePassword(1), the value of this object is the password present in the BFD packets. When the bfdSessAuthenticationType is one of the keyed authentication types, this value is used in the computation of the key present in the BFD authentication packet.')
bfdSessStorageType = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 36), StorageType()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessStorageType.setStatus('current')
if mibBuilder.loadTexts: bfdSessStorageType.setDescription("This variable indicates the storage type for this object. Conceptual rows having the value 'permanent' need not allow write-access to any columnar objects in the row.")
bfdSessRowStatus = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 37), RowStatus()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: bfdSessRowStatus.setStatus('current')
if mibBuilder.loadTexts: bfdSessRowStatus.setDescription('This variable is used to create, modify, and/or delete a row in this table. When a row in this table has a row in the active(1) state, no objects in this row can be modified except the bfdSessRowStatus and bfdSessStorageType.')
bfdSessPerfTable = MibTable((1, 3, 6, 1, 2, 1, 222, 1, 3), )
if mibBuilder.loadTexts: bfdSessPerfTable.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfTable.setDescription('This table specifies BFD Session performance counters.')
bfdSessPerfEntry = MibTableRow((1, 3, 6, 1, 2, 1, 222, 1, 3, 1), )
bfdSessEntry.registerAugmentions(("BFD-STD-MIB", "bfdSessPerfEntry"))
bfdSessPerfEntry.setIndexNames(*bfdSessEntry.getIndexNames())
if mibBuilder.loadTexts: bfdSessPerfEntry.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEntry.setDescription('An entry in this table is created by a BFD-enabled node for every BFD Session. bfdSessPerfDiscTime is used to indicate potential discontinuity for all counter objects in this table.')
bfdSessPerfCtrlPktIn = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 1), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfCtrlPktIn.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfCtrlPktIn.setDescription('The total number of BFD control messages received for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfCtrlPktInHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfCtrlPktOut = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 2), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfCtrlPktOut.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfCtrlPktOut.setDescription('The total number of BFD control messages sent for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfCtrlPktOutHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfCtrlPktDrop = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 3), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfCtrlPktDrop.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfCtrlPktDrop.setDescription('The total number of BFD control messages received for this session yet dropped for being invalid. It MUST be equal to the least significant 32 bits of bfdSessPerfCtrlPktDropHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfCtrlPktDropLastTime = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 4), TimeStamp()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfCtrlPktDropLastTime.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfCtrlPktDropLastTime.setDescription('The value of sysUpTime on the most recent occasion at which received BFD control message for this session was dropped. If no such up event exists, this object contains a zero value.')
bfdSessPerfEchoPktIn = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 5), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfEchoPktIn.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEchoPktIn.setDescription('The total number of BFD echo messages received for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfEchoPktInHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfEchoPktOut = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfEchoPktOut.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEchoPktOut.setDescription('The total number of BFD echo messages sent for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfEchoPktOutHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfEchoPktDrop = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfEchoPktDrop.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEchoPktDrop.setDescription('The total number of BFD echo messages received for this session yet dropped for being invalid. It MUST be equal to the least significant 32 bits of bfdSessPerfEchoPktDropHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfEchoPktDropLastTime = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 8), TimeStamp()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfEchoPktDropLastTime.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEchoPktDropLastTime.setDescription('The value of sysUpTime on the most recent occasion at which received BFD echo message for this session was dropped. If no such up event has been issued, this object contains a zero value.')
bfdSessUpTime = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 9), TimeStamp()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessUpTime.setStatus('current')
if mibBuilder.loadTexts: bfdSessUpTime.setDescription('The value of sysUpTime on the most recent occasion at which the session came up. If no such event has been issued, this object contains a zero value.')
bfdSessPerfLastSessDownTime = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 10), TimeStamp()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfLastSessDownTime.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfLastSessDownTime.setDescription('The value of sysUpTime on the most recent occasion at which the last time communication was lost with the neighbor. If no down event has been issued this object contains a zero value.')
bfdSessPerfLastCommLostDiag = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 11), IANAbfdDiagTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfLastCommLostDiag.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfLastCommLostDiag.setDescription('The BFD diag code for the last time communication was lost with the neighbor. If such an event has not been issued this object contains a zero value.')
bfdSessPerfSessUpCount = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 12), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfSessUpCount.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfSessUpCount.setDescription('The number of times this session has gone into the Up state since the system last rebooted.')
bfdSessPerfDiscTime = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 13), TimeStamp()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfDiscTime.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfDiscTime.setDescription('The value of sysUpTime on the most recent occasion at which any one or more of the session counters suffered a discontinuity. The relevant counters are the specific instances associated with this BFD session of any Counter32 object contained in the BfdSessPerfTable. If no such discontinuities have occurred since the last re-initialization of the local management subsystem, then this object contains a zero value.')
bfdSessPerfCtrlPktInHC = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 14), Counter64()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfCtrlPktInHC.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfCtrlPktInHC.setDescription('This value represents the total number of BFD control messages received for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfCtrlPktIn, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfCtrlPktOutHC = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 15), Counter64()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfCtrlPktOutHC.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfCtrlPktOutHC.setDescription('This value represents the total number of BFD control messages transmitted for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfCtrlPktOut, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfCtrlPktDropHC = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 16), Counter64()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfCtrlPktDropHC.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfCtrlPktDropHC.setDescription('This value represents the total number of BFD control messages received for this BFD session yet dropped for being invalid. The least significant 32 bits MUST equal to bfdSessPerfCtrlPktDrop, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfEchoPktInHC = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 17), Counter64()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfEchoPktInHC.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEchoPktInHC.setDescription('This value represents the total number of BFD echo messages received for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfEchoPktIn, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfEchoPktOutHC = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 18), Counter64()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfEchoPktOutHC.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEchoPktOutHC.setDescription('This value represents the total number of BFD echo messages transmitted for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfEchoPktOut, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessPerfEchoPktDropHC = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 19), Counter64()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessPerfEchoPktDropHC.setStatus('current')
if mibBuilder.loadTexts: bfdSessPerfEchoPktDropHC.setDescription('This value represents the total number of BFD echo messages received for this BFD session yet dropped for being invalid. The least significant 32 bits MUST equal to bfdSessPerfEchoPktDrop, and MUST do so with the rules spelled out in RFC 2863.')
bfdSessDiscMapTable = MibTable((1, 3, 6, 1, 2, 1, 222, 1, 4), )
if mibBuilder.loadTexts: bfdSessDiscMapTable.setStatus('current')
if mibBuilder.loadTexts: bfdSessDiscMapTable.setDescription("The BFD Session Discriminator Mapping Table maps a local discriminator value to associated BFD session's bfdSessIndex found in the bfdSessionTable.")
bfdSessDiscMapEntry = MibTableRow((1, 3, 6, 1, 2, 1, 222, 1, 4, 1), ).setIndexNames((0, "BFD-STD-MIB", "bfdSessDiscriminator"))
if mibBuilder.loadTexts: bfdSessDiscMapEntry.setStatus('current')
if mibBuilder.loadTexts: bfdSessDiscMapEntry.setDescription('The BFD Session Discriminator Mapping Entry specifies a mapping between a local discriminator and a BFD session.')
bfdSessDiscMapIndex = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 4, 1, 1), BfdSessIndexTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessDiscMapIndex.setStatus('current')
if mibBuilder.loadTexts: bfdSessDiscMapIndex.setDescription('This object specifies a mapping between a local discriminator and a BFD Session in the BfdSessTable.')
bfdSessIpMapTable = MibTable((1, 3, 6, 1, 2, 1, 222, 1, 5), )
if mibBuilder.loadTexts: bfdSessIpMapTable.setStatus('current')
if mibBuilder.loadTexts: bfdSessIpMapTable.setDescription('The BFD Session IP Mapping Table maps given bfdSessInterface, bfdSessSrcAddrType, bfdSessSrcAddr, bfdSessDstAddrType and bfdSessDstAddr to an associated BFD session found in the bfdSessionTable.')
bfdSessIpMapEntry = MibTableRow((1, 3, 6, 1, 2, 1, 222, 1, 5, 1), ).setIndexNames((0, "BFD-STD-MIB", "bfdSessInterface"), (0, "BFD-STD-MIB", "bfdSessSrcAddrType"), (0, "BFD-STD-MIB", "bfdSessSrcAddr"), (0, "BFD-STD-MIB", "bfdSessDstAddrType"), (0, "BFD-STD-MIB", "bfdSessDstAddr"))
if mibBuilder.loadTexts: bfdSessIpMapEntry.setStatus('current')
if mibBuilder.loadTexts: bfdSessIpMapEntry.setDescription('The BFD Session IP Map Entry contains a mapping from the IP information for a session, to the session in the bfdSessionTable.')
bfdSessIpMapIndex = MibTableColumn((1, 3, 6, 1, 2, 1, 222, 1, 5, 1, 1), BfdSessIndexTC()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bfdSessIpMapIndex.setStatus('current')
if mibBuilder.loadTexts: bfdSessIpMapIndex.setDescription('This object specifies the BfdSessIndexTC referred to by the indexes of this row. In essence, a mapping is provided between these indexes and the BfdSessTable.')
bfdSessUp = NotificationType((1, 3, 6, 1, 2, 1, 222, 0, 1)).setObjects(("BFD-STD-MIB", "bfdSessDiag"), ("BFD-STD-MIB", "bfdSessDiag"))
if mibBuilder.loadTexts: bfdSessUp.setStatus('current')
if mibBuilder.loadTexts: bfdSessUp.setDescription('This notification is generated when the bfdSessState object for one or more contiguous entries in bfdSessTable are about to enter the up(4) state from some other state. The included values of bfdSessDiag MUST both be set equal to this new state (i.e: up(4)). The two instances of bfdSessDiag in this notification indicate the range of indexes that are affected. Note that all the indexes of the two ends of the range can be derived from the instance identifiers of these two objects. For the cases where a contiguous range of sessions have transitioned into the up(4) state at roughly the same time, the device SHOULD issue a single notification for each range of contiguous indexes in an effort to minimize the emission of a large number of notifications. If a notification has to be issued for just a single bfdSessEntry, then the instance identifier (and values) of the two bfdSessDiag objects MUST be the identical.')
bfdSessDown = NotificationType((1, 3, 6, 1, 2, 1, 222, 0, 2)).setObjects(("BFD-STD-MIB", "bfdSessDiag"), ("BFD-STD-MIB", "bfdSessDiag"))
if mibBuilder.loadTexts: bfdSessDown.setStatus('current')
if mibBuilder.loadTexts: bfdSessDown.setDescription('This notification is generated when the bfdSessState object for one or more contiguous entries in bfdSessTable are about to enter the down(2) or adminDown(1) states from some other state. The included values of bfdSessDiag MUST both be set equal to this new state (i.e: down(2) or adminDown(1)). The two instances of bfdSessDiag in this notification indicate the range of indexes that are affected. Note that all the indexes of the two ends of the range can be derived from the instance identifiers of these two objects. For cases where a contiguous range of sessions have transitioned into the down(2) or adminDown(1) states at roughly the same time, the device SHOULD issue a single notification for each range of contiguous indexes in an effort to minimize the emission of a large number of notifications. If a notification has to be issued for just a single bfdSessEntry, then the instance identifier (and values) of the two bfdSessDiag objects MUST be the identical.')
bfdGroups = MibIdentifier((1, 3, 6, 1, 2, 1, 222, 2, 1))
bfdCompliances = MibIdentifier((1, 3, 6, 1, 2, 1, 222, 2, 2))
bfdModuleFullCompliance = ModuleCompliance((1, 3, 6, 1, 2, 1, 222, 2, 2, 1)).setObjects(("BFD-STD-MIB", "bfdSessionGroup"), ("BFD-STD-MIB", "bfdSessionReadOnlyGroup"), ("BFD-STD-MIB", "bfdSessionPerfGroup"), ("BFD-STD-MIB", "bfdNotificationGroup"), ("BFD-STD-MIB", "bfdSessionPerfHCGroup"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfdModuleFullCompliance = bfdModuleFullCompliance.setStatus('current')
if mibBuilder.loadTexts: bfdModuleFullCompliance.setDescription('Compliance statement for agents that provide full support for the BFD-MIB module. Such devices can then be monitored and also be configured using this MIB module.')
bfdModuleReadOnlyCompliance = ModuleCompliance((1, 3, 6, 1, 2, 1, 222, 2, 2, 2)).setObjects(("BFD-STD-MIB", "bfdSessionGroup"), ("BFD-STD-MIB", "bfdSessionReadOnlyGroup"), ("BFD-STD-MIB", "bfdSessionPerfGroup"), ("BFD-STD-MIB", "bfdNotificationGroup"), ("BFD-STD-MIB", "bfdSessionPerfHCGroup"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfdModuleReadOnlyCompliance = bfdModuleReadOnlyCompliance.setStatus('current')
if mibBuilder.loadTexts: bfdModuleReadOnlyCompliance.setDescription('Compliance requirement for implementations that only provide read-only support for BFD-MIB. Such devices can then be monitored but cannot be configured using this MIB module.')
bfdSessionGroup = ObjectGroup((1, 3, 6, 1, 2, 1, 222, 2, 1, 1)).setObjects(("BFD-STD-MIB", "bfdAdminStatus"), ("BFD-STD-MIB", "bfdOperStatus"), ("BFD-STD-MIB", "bfdNotificationsEnable"), ("BFD-STD-MIB", "bfdSessVersionNumber"), ("BFD-STD-MIB", "bfdSessType"), ("BFD-STD-MIB", "bfdSessIndexNext"), ("BFD-STD-MIB", "bfdSessDiscriminator"), ("BFD-STD-MIB", "bfdSessDestinationUdpPort"), ("BFD-STD-MIB", "bfdSessSourceUdpPort"), ("BFD-STD-MIB", "bfdSessEchoSourceUdpPort"), ("BFD-STD-MIB", "bfdSessAdminStatus"), ("BFD-STD-MIB", "bfdSessOperStatus"), ("BFD-STD-MIB", "bfdSessOperMode"), ("BFD-STD-MIB", "bfdSessDemandModeDesiredFlag"), ("BFD-STD-MIB", "bfdSessControlPlaneIndepFlag"), ("BFD-STD-MIB", "bfdSessMultipointFlag"), ("BFD-STD-MIB", "bfdSessInterface"), ("BFD-STD-MIB", "bfdSessSrcAddrType"), ("BFD-STD-MIB", "bfdSessSrcAddr"), ("BFD-STD-MIB", "bfdSessDstAddrType"), ("BFD-STD-MIB", "bfdSessDstAddr"), ("BFD-STD-MIB", "bfdSessGTSM"), ("BFD-STD-MIB", "bfdSessGTSMTTL"), ("BFD-STD-MIB", "bfdSessDesiredMinTxInterval"), ("BFD-STD-MIB", "bfdSessReqMinRxInterval"), ("BFD-STD-MIB", "bfdSessReqMinEchoRxInterval"), ("BFD-STD-MIB", "bfdSessDetectMult"), ("BFD-STD-MIB", "bfdSessAuthPresFlag"), ("BFD-STD-MIB", "bfdSessAuthenticationType"), ("BFD-STD-MIB", "bfdSessAuthenticationKeyID"), ("BFD-STD-MIB", "bfdSessAuthenticationKey"), ("BFD-STD-MIB", "bfdSessStorageType"), ("BFD-STD-MIB", "bfdSessRowStatus"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfdSessionGroup = bfdSessionGroup.setStatus('current')
if mibBuilder.loadTexts: bfdSessionGroup.setDescription('Collection of objects needed for BFD sessions.')
bfdSessionReadOnlyGroup = ObjectGroup((1, 3, 6, 1, 2, 1, 222, 2, 1, 2)).setObjects(("BFD-STD-MIB", "bfdSessRemoteDiscr"), ("BFD-STD-MIB", "bfdSessState"), ("BFD-STD-MIB", "bfdSessRemoteHeardFlag"), ("BFD-STD-MIB", "bfdSessDiag"), ("BFD-STD-MIB", "bfdSessNegotiatedInterval"), ("BFD-STD-MIB", "bfdSessNegotiatedEchoInterval"), ("BFD-STD-MIB", "bfdSessNegotiatedDetectMult"), ("BFD-STD-MIB", "bfdSessDiscMapIndex"), ("BFD-STD-MIB", "bfdSessIpMapIndex"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfdSessionReadOnlyGroup = bfdSessionReadOnlyGroup.setStatus('current')
if mibBuilder.loadTexts: bfdSessionReadOnlyGroup.setDescription('Collection of read-only objects needed for BFD sessions.')
bfdSessionPerfGroup = ObjectGroup((1, 3, 6, 1, 2, 1, 222, 2, 1, 3)).setObjects(("BFD-STD-MIB", "bfdSessPerfCtrlPktIn"), ("BFD-STD-MIB", "bfdSessPerfCtrlPktOut"), ("BFD-STD-MIB", "bfdSessPerfCtrlPktDrop"), ("BFD-STD-MIB", "bfdSessPerfCtrlPktDropLastTime"), ("BFD-STD-MIB", "bfdSessPerfEchoPktIn"), ("BFD-STD-MIB", "bfdSessPerfEchoPktOut"), ("BFD-STD-MIB", "bfdSessPerfEchoPktDrop"), ("BFD-STD-MIB", "bfdSessPerfEchoPktDropLastTime"), ("BFD-STD-MIB", "bfdSessUpTime"), ("BFD-STD-MIB", "bfdSessPerfLastSessDownTime"), ("BFD-STD-MIB", "bfdSessPerfLastCommLostDiag"), ("BFD-STD-MIB", "bfdSessPerfSessUpCount"), ("BFD-STD-MIB", "bfdSessPerfDiscTime"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfdSessionPerfGroup = bfdSessionPerfGroup.setStatus('current')
if mibBuilder.loadTexts: bfdSessionPerfGroup.setDescription('Collection of objects needed to monitor the performance of BFD sessions.')
bfdSessionPerfHCGroup = ObjectGroup((1, 3, 6, 1, 2, 1, 222, 2, 1, 4)).setObjects(("BFD-STD-MIB", "bfdSessPerfCtrlPktInHC"), ("BFD-STD-MIB", "bfdSessPerfCtrlPktOutHC"), ("BFD-STD-MIB", "bfdSessPerfCtrlPktDropHC"), ("BFD-STD-MIB", "bfdSessPerfEchoPktInHC"), ("BFD-STD-MIB", "bfdSessPerfEchoPktOutHC"), ("BFD-STD-MIB", "bfdSessPerfEchoPktDropHC"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfdSessionPerfHCGroup = bfdSessionPerfHCGroup.setStatus('current')
if mibBuilder.loadTexts: bfdSessionPerfHCGroup.setDescription('Collection of objects needed to monitor the performance of BFD sessions for which the values of bfdSessPerfPktIn, bfdSessPerfPktOut wrap around too quickly.')
bfdNotificationGroup = NotificationGroup((1, 3, 6, 1, 2, 1, 222, 2, 1, 5)).setObjects(("BFD-STD-MIB", "bfdSessUp"), ("BFD-STD-MIB", "bfdSessDown"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfdNotificationGroup = bfdNotificationGroup.setStatus('current')
if mibBuilder.loadTexts: bfdNotificationGroup.setDescription('Set of notifications implemented in this module.')
mibBuilder.exportSymbols("BFD-STD-MIB", bfdSessDstAddr=bfdSessDstAddr, bfdSessVersionNumber=bfdSessVersionNumber, bfdSessUp=bfdSessUp, bfdSessDiscMapIndex=bfdSessDiscMapIndex, bfdSessPerfLastSessDownTime=bfdSessPerfLastSessDownTime, bfdGroups=bfdGroups, PYSNMP_MODULE_ID=bfdMIB, bfdSessSourceUdpPort=bfdSessSourceUdpPort, bfdScalarObjects=bfdScalarObjects, bfdCompliances=bfdCompliances, bfdSessSrcAddr=bfdSessSrcAddr, bfdSessPerfCtrlPktDropHC=bfdSessPerfCtrlPktDropHC, bfdSessPerfCtrlPktIn=bfdSessPerfCtrlPktIn, bfdSessEchoSourceUdpPort=bfdSessEchoSourceUdpPort, bfdSessRemoteHeardFlag=bfdSessRemoteHeardFlag, bfdSessionGroup=bfdSessionGroup, bfdSessOperStatus=bfdSessOperStatus, bfdSessDestinationUdpPort=bfdSessDestinationUdpPort, bfdSessDetectMult=bfdSessDetectMult, bfdSessStorageType=bfdSessStorageType, bfdSessReqMinEchoRxInterval=bfdSessReqMinEchoRxInterval, bfdSessDiscriminator=bfdSessDiscriminator, bfdSessControlPlaneIndepFlag=bfdSessControlPlaneIndepFlag, bfdSessMultipointFlag=bfdSessMultipointFlag, bfdSessPerfEchoPktOutHC=bfdSessPerfEchoPktOutHC, bfdSessOperMode=bfdSessOperMode, bfdSessNegotiatedInterval=bfdSessNegotiatedInterval, bfdSessPerfEntry=bfdSessPerfEntry, bfdSessPerfSessUpCount=bfdSessPerfSessUpCount, bfdSessPerfCtrlPktOutHC=bfdSessPerfCtrlPktOutHC, bfdNotificationsEnable=bfdNotificationsEnable, bfdSessSrcAddrType=bfdSessSrcAddrType, bfdSessUpTime=bfdSessUpTime, bfdSessPerfEchoPktDropHC=bfdSessPerfEchoPktDropHC, bfdSessState=bfdSessState, bfdSessIpMapTable=bfdSessIpMapTable, bfdSessAuthenticationKeyID=bfdSessAuthenticationKeyID, bfdNotificationGroup=bfdNotificationGroup, bfdSessInterface=bfdSessInterface, bfdSessGTSMTTL=bfdSessGTSMTTL, bfdSessPerfLastCommLostDiag=bfdSessPerfLastCommLostDiag, bfdSessPerfEchoPktIn=bfdSessPerfEchoPktIn, bfdSessIndexNext=bfdSessIndexNext, bfdNotifications=bfdNotifications, bfdSessDstAddrType=bfdSessDstAddrType, bfdSessDiscMapEntry=bfdSessDiscMapEntry, bfdSessIpMapIndex=bfdSessIpMapIndex, bfdSessAuthPresFlag=bfdSessAuthPresFlag, bfdSessNegotiatedEchoInterval=bfdSessNegotiatedEchoInterval, bfdSessPerfCtrlPktOut=bfdSessPerfCtrlPktOut, bfdSessAuthenticationType=bfdSessAuthenticationType, bfdSessDiag=bfdSessDiag, bfdSessGTSM=bfdSessGTSM, bfdSessTable=bfdSessTable, bfdSessPerfCtrlPktDrop=bfdSessPerfCtrlPktDrop, bfdSessionPerfHCGroup=bfdSessionPerfHCGroup, bfdSessPerfTable=bfdSessPerfTable, bfdObjects=bfdObjects, bfdModuleFullCompliance=bfdModuleFullCompliance, bfdSessDesiredMinTxInterval=bfdSessDesiredMinTxInterval, bfdSessAuthenticationKey=bfdSessAuthenticationKey, bfdSessPerfCtrlPktInHC=bfdSessPerfCtrlPktInHC, bfdSessReqMinRxInterval=bfdSessReqMinRxInterval, bfdSessIpMapEntry=bfdSessIpMapEntry, bfdModuleReadOnlyCompliance=bfdModuleReadOnlyCompliance, bfdSessIndex=bfdSessIndex, bfdSessType=bfdSessType, bfdSessionPerfGroup=bfdSessionPerfGroup, bfdSessRemoteDiscr=bfdSessRemoteDiscr, bfdSessEntry=bfdSessEntry, bfdSessPerfDiscTime=bfdSessPerfDiscTime, bfdSessPerfEchoPktInHC=bfdSessPerfEchoPktInHC, bfdConformance=bfdConformance, bfdSessPerfCtrlPktDropLastTime=bfdSessPerfCtrlPktDropLastTime, bfdSessRowStatus=bfdSessRowStatus, bfdSessAdminStatus=bfdSessAdminStatus, bfdSessPerfEchoPktOut=bfdSessPerfEchoPktOut, bfdSessDown=bfdSessDown, bfdSessPerfEchoPktDropLastTime=bfdSessPerfEchoPktDropLastTime, bfdSessionReadOnlyGroup=bfdSessionReadOnlyGroup, bfdOperStatus=bfdOperStatus, bfdSessDiscMapTable=bfdSessDiscMapTable, bfdMIB=bfdMIB, bfdAdminStatus=bfdAdminStatus, bfdSessPerfEchoPktDrop=bfdSessPerfEchoPktDrop, bfdSessDemandModeDesiredFlag=bfdSessDemandModeDesiredFlag, bfdSessNegotiatedDetectMult=bfdSessNegotiatedDetectMult)
| (octet_string, integer, object_identifier) = mibBuilder.importSymbols('ASN1', 'OctetString', 'Integer', 'ObjectIdentifier')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(constraints_union, value_size_constraint, constraints_intersection, value_range_constraint, single_value_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ConstraintsUnion', 'ValueSizeConstraint', 'ConstraintsIntersection', 'ValueRangeConstraint', 'SingleValueConstraint')
(bfd_sess_index_tc, bfd_multiplier_tc, bfd_interval_tc, bfd_ctrl_source_port_number_tc, bfd_ctrl_dest_port_number_tc) = mibBuilder.importSymbols('BFD-TC-STD-MIB', 'BfdSessIndexTC', 'BfdMultiplierTC', 'BfdIntervalTC', 'BfdCtrlSourcePortNumberTC', 'BfdCtrlDestPortNumberTC')
(index_integer_next_free,) = mibBuilder.importSymbols('DIFFSERV-DSCP-TC', 'IndexIntegerNextFree')
(ian_abfd_sess_authentication_type_tc, ian_abfd_sess_authentication_key_tc, ian_abfd_sess_type_tc, ian_abfd_diag_tc, ian_abfd_sess_state_tc, ian_abfd_sess_oper_mode_tc) = mibBuilder.importSymbols('IANA-BFD-TC-STD-MIB', 'IANAbfdSessAuthenticationTypeTC', 'IANAbfdSessAuthenticationKeyTC', 'IANAbfdSessTypeTC', 'IANAbfdDiagTC', 'IANAbfdSessStateTC', 'IANAbfdSessOperModeTC')
(interface_index_or_zero,) = mibBuilder.importSymbols('IF-MIB', 'InterfaceIndexOrZero')
(inet_address, inet_port_number, inet_address_type) = mibBuilder.importSymbols('INET-ADDRESS-MIB', 'InetAddress', 'InetPortNumber', 'InetAddressType')
(notification_group, object_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ObjectGroup', 'ModuleCompliance')
(mib_identifier, bits, notification_type, time_ticks, module_identity, gauge32, unsigned32, counter64, ip_address, object_identity, counter32, iso, mib_scalar, mib_table, mib_table_row, mib_table_column, integer32, mib_2) = mibBuilder.importSymbols('SNMPv2-SMI', 'MibIdentifier', 'Bits', 'NotificationType', 'TimeTicks', 'ModuleIdentity', 'Gauge32', 'Unsigned32', 'Counter64', 'IpAddress', 'ObjectIdentity', 'Counter32', 'iso', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'Integer32', 'mib-2')
(time_stamp, textual_convention, row_status, truth_value, storage_type, display_string) = mibBuilder.importSymbols('SNMPv2-TC', 'TimeStamp', 'TextualConvention', 'RowStatus', 'TruthValue', 'StorageType', 'DisplayString')
bfd_mib = module_identity((1, 3, 6, 1, 2, 1, 222))
bfdMIB.setRevisions(('2014-08-12 00:00',))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts:
bfdMIB.setRevisionsDescriptions(('Initial version. Published as RFC 7331.',))
if mibBuilder.loadTexts:
bfdMIB.setLastUpdated('201408120000Z')
if mibBuilder.loadTexts:
bfdMIB.setOrganization('IETF Bidirectional Forwarding Detection Working Group')
if mibBuilder.loadTexts:
bfdMIB.setContactInfo('Thomas D. Nadeau Brocade Email: tnadeau@lucidvision.com Zafar Ali Cisco Systems, Inc. Email: zali@cisco.com Nobo Akiya Cisco Systems, Inc. Email: nobo@cisco.com Comments about this document should be emailed directly to the BFD Working Group mailing list at rtg-bfd@ietf.org')
if mibBuilder.loadTexts:
bfdMIB.setDescription("Bidirectional Forwarding Management Information Base. Copyright (c) 2014 IETF Trust and the persons identified as authors of the code. All rights reserved. Redistribution and use in source and binary forms, with or without modification, is permitted pursuant to, and subject to the license terms contained in, the Simplified BSD License set forth in Section 4.c of the IETF Trust's Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info).")
bfd_notifications = mib_identifier((1, 3, 6, 1, 2, 1, 222, 0))
bfd_objects = mib_identifier((1, 3, 6, 1, 2, 1, 222, 1))
bfd_conformance = mib_identifier((1, 3, 6, 1, 2, 1, 222, 2))
bfd_scalar_objects = mib_identifier((1, 3, 6, 1, 2, 1, 222, 1, 1))
bfd_admin_status = mib_scalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4))).clone(namedValues=named_values(('enabled', 1), ('disabled', 2), ('adminDown', 3), ('down', 4)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
bfdAdminStatus.setStatus('current')
if mibBuilder.loadTexts:
bfdAdminStatus.setDescription('The desired global administrative status of the BFD system in this device.')
bfd_oper_status = mib_scalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('up', 1), ('down', 2), ('adminDown', 3)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdOperStatus.setStatus('current')
if mibBuilder.loadTexts:
bfdOperStatus.setDescription('Indicates the actual operational status of the BFD system in this device. When this value is down(2), all entries in the bfdSessTable MUST have their bfdSessOperStatus as down(2) as well. When this value is adminDown(3), all entries in the bfdSessTable MUST have their bfdSessOperStatus as adminDown(3) as well.')
bfd_notifications_enable = mib_scalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 3), truth_value().clone('false')).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
bfdNotificationsEnable.setReference('See also RFC3413 for explanation that notifications are under the ultimate control of the MIB modules in this document.')
if mibBuilder.loadTexts:
bfdNotificationsEnable.setStatus('current')
if mibBuilder.loadTexts:
bfdNotificationsEnable.setDescription('If this object is set to true(1), then it enables the emission of bfdSessUp and bfdSessDown notifications; otherwise these notifications are not emitted.')
bfd_sess_index_next = mib_scalar((1, 3, 6, 1, 2, 1, 222, 1, 1, 4), index_integer_next_free().subtype(subtypeSpec=value_range_constraint(0, 4294967295))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessIndexNext.setStatus('current')
if mibBuilder.loadTexts:
bfdSessIndexNext.setDescription('This object contains an unused value for bfdSessIndex that can be used when creating entries in the table. A zero indicates that no entries are available, but MUST NOT be used as a valid index. ')
bfd_sess_table = mib_table((1, 3, 6, 1, 2, 1, 222, 1, 2))
if mibBuilder.loadTexts:
bfdSessTable.setReference('Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessTable.setStatus('current')
if mibBuilder.loadTexts:
bfdSessTable.setDescription('The BFD Session Table describes the BFD sessions.')
bfd_sess_entry = mib_table_row((1, 3, 6, 1, 2, 1, 222, 1, 2, 1)).setIndexNames((0, 'BFD-STD-MIB', 'bfdSessIndex'))
if mibBuilder.loadTexts:
bfdSessEntry.setStatus('current')
if mibBuilder.loadTexts:
bfdSessEntry.setDescription('The BFD Session Entry describes BFD session.')
bfd_sess_index = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 1), bfd_sess_index_tc())
if mibBuilder.loadTexts:
bfdSessIndex.setStatus('current')
if mibBuilder.loadTexts:
bfdSessIndex.setDescription('This object contains an index used to represent a unique BFD session on this device. Managers should obtain new values for row creation in this table by reading bfdSessIndexNext.')
bfd_sess_version_number = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 2), unsigned32().subtype(subtypeSpec=value_range_constraint(0, 7)).clone(1)).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessVersionNumber.setReference('Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessVersionNumber.setStatus('current')
if mibBuilder.loadTexts:
bfdSessVersionNumber.setDescription('The version number of the BFD protocol that this session is running in. Write access is available for this object to provide ability to set desired version for this BFD session.')
bfd_sess_type = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 3), ian_abfd_sess_type_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessType.setStatus('current')
if mibBuilder.loadTexts:
bfdSessType.setDescription('This object specifies the type of this BFD session.')
bfd_sess_discriminator = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 4), unsigned32().subtype(subtypeSpec=value_range_constraint(1, 4294967295))).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessDiscriminator.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDiscriminator.setDescription('This object specifies the local discriminator for this BFD session, used to uniquely identify it.')
bfd_sess_remote_discr = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 5), unsigned32().subtype(subtypeSpec=constraints_union(value_range_constraint(0, 0), value_range_constraint(1, 4294967295)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessRemoteDiscr.setReference('Section 6.8.6, from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessRemoteDiscr.setStatus('current')
if mibBuilder.loadTexts:
bfdSessRemoteDiscr.setDescription('This object specifies the session discriminator chosen by the remote system for this BFD session. The value may be zero(0) if the remote discriminator is not yet known or if the session is in the down or adminDown(1) state.')
bfd_sess_destination_udp_port = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 6), bfd_ctrl_dest_port_number_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessDestinationUdpPort.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDestinationUdpPort.setDescription("This object specifies the destination UDP port number used for this BFD session's control packets. The value may be zero(0) if the session is in adminDown(1) state.")
bfd_sess_source_udp_port = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 7), bfd_ctrl_source_port_number_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessSourceUdpPort.setStatus('current')
if mibBuilder.loadTexts:
bfdSessSourceUdpPort.setDescription("This object specifies the source UDP port number used for this BFD session's control packets. The value may be zero(0) if the session is in adminDown(1) state. Upon creation of a new BFD session via this MIB, the value of zero(0) specified would permit the implementation to choose its own source port number.")
bfd_sess_echo_source_udp_port = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 8), inet_port_number()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessEchoSourceUdpPort.setStatus('current')
if mibBuilder.loadTexts:
bfdSessEchoSourceUdpPort.setDescription("This object specifies the source UDP port number used for this BFD session's echo packets. The value may be zero(0) if the session is not running in the echo mode, or the session is in adminDown(1) state. Upon creation of a new BFD session via this MIB, the value of zero(0) would permit the implementation to choose its own source port number.")
bfd_sess_admin_status = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 9), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4))).clone(namedValues=named_values(('enabled', 1), ('disabled', 2), ('adminDown', 3), ('down', 4)))).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessAdminStatus.setStatus('current')
if mibBuilder.loadTexts:
bfdSessAdminStatus.setDescription('Denotes the desired operational status of the BFD Session. A transition to enabled(1) will start the BFD state machine for the session. The state machine will have an initial state of down(2). A transition to disabled(2) will stop the BFD state machine for the session. The state machine may first transition to adminDown(1) prior to stopping. A transition to adminDown(3) will cause the BFD state machine to transition to adminDown(1), and will cause the session to remain in this state. A transition to down(4) will cause the BFD state machine to transition to down(2), and will cause the session to remain in this state. Care should be used in providing write access to this object without adequate authentication.')
bfd_sess_oper_status = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 10), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('up', 1), ('down', 2), ('adminDown', 3)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessOperStatus.setStatus('current')
if mibBuilder.loadTexts:
bfdSessOperStatus.setDescription('Denotes the actual operational status of the BFD Session. If the value of bfdOperStatus is down(2), this value MUST eventually be down(2) as well. If the value of bfdOperStatus is adminDown(3), this value MUST eventually be adminDown(3) as well.')
bfd_sess_state = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 11), ian_abfd_sess_state_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessState.setStatus('current')
if mibBuilder.loadTexts:
bfdSessState.setDescription('Configured BFD session state.')
bfd_sess_remote_heard_flag = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 12), truth_value()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessRemoteHeardFlag.setReference('Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessRemoteHeardFlag.setStatus('current')
if mibBuilder.loadTexts:
bfdSessRemoteHeardFlag.setDescription('This object specifies status of BFD packet reception from the remote system. Specifically, it is set to true(1) if the local system is actively receiving BFD packets from the remote system, and is set to false(2) if the local system has not received BFD packets recently (within the detection time) or if the local system is attempting to tear down the BFD session.')
bfd_sess_diag = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 13), ian_abfd_diag_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessDiag.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDiag.setDescription("A diagnostic code specifying the local system's reason for the last transition of the session from up(4) to some other state.")
bfd_sess_oper_mode = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 14), ian_abfd_sess_oper_mode_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessOperMode.setStatus('current')
if mibBuilder.loadTexts:
bfdSessOperMode.setDescription('This object specifies the operational mode of this BFD session.')
bfd_sess_demand_mode_desired_flag = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 15), truth_value().clone('false')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessDemandModeDesiredFlag.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDemandModeDesiredFlag.setDescription("This object indicates that the local system's desire to use Demand mode. Specifically, it is set to true(1) if the local system wishes to use Demand mode or false(2) if not")
bfd_sess_control_plane_indep_flag = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 16), truth_value().clone('false')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessControlPlaneIndepFlag.setStatus('current')
if mibBuilder.loadTexts:
bfdSessControlPlaneIndepFlag.setDescription("This object indicates that the local system's ability to continue to function through a disruption of the control plane. Specifically, it is set to true(1) if the local system BFD implementation is independent of the control plane. Otherwise, the value is set to false(2)")
bfd_sess_multipoint_flag = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 17), truth_value().clone('false')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessMultipointFlag.setStatus('current')
if mibBuilder.loadTexts:
bfdSessMultipointFlag.setDescription('This object indicates the Multipoint (M) bit for this session. It is set to true(1) if Multipoint (M) bit is set to 1. Otherwise, the value is set to false(2)')
bfd_sess_interface = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 18), interface_index_or_zero()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessInterface.setStatus('current')
if mibBuilder.loadTexts:
bfdSessInterface.setDescription('This object contains an interface index used to indicate the interface which this BFD session is running on. This value can be zero if there is no interface associated with this BFD session.')
bfd_sess_src_addr_type = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 19), inet_address_type()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessSrcAddrType.setStatus('current')
if mibBuilder.loadTexts:
bfdSessSrcAddrType.setDescription('This object specifies IP address type of the source IP address of this BFD session. The value of unknown(0) is allowed only when the session is singleHop(1) and the source IP address of this BFD session is derived from the outgoing interface, or when the BFD session is not associated with a specific interface. If any other unsupported values are attempted in a set operation, the agent MUST return an inconsistentValue error.')
bfd_sess_src_addr = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 20), inet_address().subtype(subtypeSpec=value_size_constraint(4, 4)).setFixedLength(4)).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessSrcAddr.setStatus('current')
if mibBuilder.loadTexts:
bfdSessSrcAddr.setDescription('This object specifies the source IP address of this BFD session. The format of this object is controlled by the bfdSessSrcAddrType object.')
bfd_sess_dst_addr_type = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 21), inet_address_type()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessDstAddrType.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDstAddrType.setDescription('This object specifies IP address type of the neighboring IP address which is being monitored with this BFD session. The value of unknown(0) is allowed only when the session is singleHop(1) and the outgoing interface is of type point-to-point, or when the BFD session is not associated with a specific interface. If any other unsupported values are attempted in a set operation, the agent MUST return an inconsistentValue error.')
bfd_sess_dst_addr = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 22), inet_address().subtype(subtypeSpec=value_size_constraint(4, 4)).setFixedLength(4)).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessDstAddr.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDstAddr.setDescription('This object specifies the neighboring IP address which is being monitored with this BFD session. The format of this object is controlled by the bfdSessDstAddrType object.')
bfd_sess_gtsm = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 23), truth_value().clone('true')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessGTSM.setReference('RFC5082, The Generalized TTL Security Mechanism (GTSM). RFC5881, Section 5')
if mibBuilder.loadTexts:
bfdSessGTSM.setStatus('current')
if mibBuilder.loadTexts:
bfdSessGTSM.setDescription('Setting the value of this object to false(2) will disable GTSM protection of the BFD session. GTSM MUST be enabled on a singleHop(1) session if no authentication is in use.')
bfd_sess_gtsmttl = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 24), unsigned32().subtype(subtypeSpec=value_range_constraint(0, 255)).clone(255)).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessGTSMTTL.setReference('RFC5082, The Generalized TTL Security Mechanism (GTSM). RFC5881, Section 5')
if mibBuilder.loadTexts:
bfdSessGTSMTTL.setStatus('current')
if mibBuilder.loadTexts:
bfdSessGTSMTTL.setDescription('This object is valid only when bfdSessGTSM protection is enabled on the system. This object indicates the minimum allowed TTL for received BFD control packets. For a singleHop(1) session, if GTSM protection is enabled, this object SHOULD be set to maximum TTL value allowed for single hop. By default, GTSM is enabled and TTL value is 255. For a multihop session, updating of maximum TTL value allowed is likely required.')
bfd_sess_desired_min_tx_interval = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 25), bfd_interval_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessDesiredMinTxInterval.setReference('Section 4.1 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessDesiredMinTxInterval.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDesiredMinTxInterval.setDescription('This object specifies the minimum interval, in microseconds, that the local system would like to use when transmitting BFD Control packets. The value of zero(0) is reserved in this case, and should not be used.')
bfd_sess_req_min_rx_interval = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 26), bfd_interval_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessReqMinRxInterval.setReference('Section 4.1 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessReqMinRxInterval.setStatus('current')
if mibBuilder.loadTexts:
bfdSessReqMinRxInterval.setDescription('This object specifies the minimum interval, in microseconds, between received BFD Control packets the local system is capable of supporting. The value of zero(0) can be specified when the transmitting system does not want the remote system to send any periodic BFD control packets.')
bfd_sess_req_min_echo_rx_interval = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 27), bfd_interval_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessReqMinEchoRxInterval.setStatus('current')
if mibBuilder.loadTexts:
bfdSessReqMinEchoRxInterval.setDescription('This object specifies the minimum interval, in microseconds, between received BFD Echo packets that this system is capable of supporting. Value must be zero(0) if this is a multihop BFD session.')
bfd_sess_detect_mult = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 28), bfd_multiplier_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessDetectMult.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDetectMult.setDescription('This object specifies the Detect time multiplier.')
bfd_sess_negotiated_interval = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 29), bfd_interval_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessNegotiatedInterval.setStatus('current')
if mibBuilder.loadTexts:
bfdSessNegotiatedInterval.setDescription('This object specifies the negotiated interval, in microseconds, that the local system is transmitting BFD Control packets.')
bfd_sess_negotiated_echo_interval = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 30), bfd_interval_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessNegotiatedEchoInterval.setStatus('current')
if mibBuilder.loadTexts:
bfdSessNegotiatedEchoInterval.setDescription('This object specifies the negotiated interval, in microseconds, that the local system is transmitting BFD echo packets. Value is expected to be zero if the sessions is not running in echo mode.')
bfd_sess_negotiated_detect_mult = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 31), bfd_multiplier_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessNegotiatedDetectMult.setStatus('current')
if mibBuilder.loadTexts:
bfdSessNegotiatedDetectMult.setDescription('This object specifies the Detect time multiplier.')
bfd_sess_auth_pres_flag = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 32), truth_value().clone('false')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessAuthPresFlag.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessAuthPresFlag.setStatus('current')
if mibBuilder.loadTexts:
bfdSessAuthPresFlag.setDescription("This object indicates that the local system's desire to use Authentication. Specifically, it is set to true(1) if the local system wishes the session to be authenticated or false(2) if not.")
bfd_sess_authentication_type = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 33), ian_abfd_sess_authentication_type_tc().clone('noAuthentication')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessAuthenticationType.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessAuthenticationType.setStatus('current')
if mibBuilder.loadTexts:
bfdSessAuthenticationType.setDescription('The Authentication Type used for this BFD session. This field is valid only when the Authentication Present bit is set. Max-access to this object as well as other authentication related objects are set to read-create in order to support management of a single key ID at a time, key rotation is not handled. Key update in practice must be done by atomic update using a set containing all affected objects in the same varBindList or otherwise risk the session dropping.')
bfd_sess_authentication_key_id = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 34), integer32().subtype(subtypeSpec=constraints_union(value_range_constraint(-1, -1), value_range_constraint(0, 255))).clone(-1)).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessAuthenticationKeyID.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessAuthenticationKeyID.setStatus('current')
if mibBuilder.loadTexts:
bfdSessAuthenticationKeyID.setDescription('The authentication key ID in use for this session. This object permits multiple keys to be active simultaneously. The value -1 indicates that no Authentication Key ID will be present in the optional BFD Authentication Section.')
bfd_sess_authentication_key = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 35), ian_abfd_sess_authentication_key_tc()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessAuthenticationKey.setReference('Sections 4.2 - 4.4 from Katz, D. and D. Ward, Bidirectional Forwarding Detection (BFD), RFC 5880, June 2012.')
if mibBuilder.loadTexts:
bfdSessAuthenticationKey.setStatus('current')
if mibBuilder.loadTexts:
bfdSessAuthenticationKey.setDescription('The authentication key. When the bfdSessAuthenticationType is simplePassword(1), the value of this object is the password present in the BFD packets. When the bfdSessAuthenticationType is one of the keyed authentication types, this value is used in the computation of the key present in the BFD authentication packet.')
bfd_sess_storage_type = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 36), storage_type()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessStorageType.setStatus('current')
if mibBuilder.loadTexts:
bfdSessStorageType.setDescription("This variable indicates the storage type for this object. Conceptual rows having the value 'permanent' need not allow write-access to any columnar objects in the row.")
bfd_sess_row_status = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 2, 1, 37), row_status()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
bfdSessRowStatus.setStatus('current')
if mibBuilder.loadTexts:
bfdSessRowStatus.setDescription('This variable is used to create, modify, and/or delete a row in this table. When a row in this table has a row in the active(1) state, no objects in this row can be modified except the bfdSessRowStatus and bfdSessStorageType.')
bfd_sess_perf_table = mib_table((1, 3, 6, 1, 2, 1, 222, 1, 3))
if mibBuilder.loadTexts:
bfdSessPerfTable.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfTable.setDescription('This table specifies BFD Session performance counters.')
bfd_sess_perf_entry = mib_table_row((1, 3, 6, 1, 2, 1, 222, 1, 3, 1))
bfdSessEntry.registerAugmentions(('BFD-STD-MIB', 'bfdSessPerfEntry'))
bfdSessPerfEntry.setIndexNames(*bfdSessEntry.getIndexNames())
if mibBuilder.loadTexts:
bfdSessPerfEntry.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEntry.setDescription('An entry in this table is created by a BFD-enabled node for every BFD Session. bfdSessPerfDiscTime is used to indicate potential discontinuity for all counter objects in this table.')
bfd_sess_perf_ctrl_pkt_in = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 1), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktIn.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktIn.setDescription('The total number of BFD control messages received for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfCtrlPktInHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_ctrl_pkt_out = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 2), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktOut.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktOut.setDescription('The total number of BFD control messages sent for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfCtrlPktOutHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_ctrl_pkt_drop = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 3), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktDrop.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktDrop.setDescription('The total number of BFD control messages received for this session yet dropped for being invalid. It MUST be equal to the least significant 32 bits of bfdSessPerfCtrlPktDropHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_ctrl_pkt_drop_last_time = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 4), time_stamp()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktDropLastTime.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktDropLastTime.setDescription('The value of sysUpTime on the most recent occasion at which received BFD control message for this session was dropped. If no such up event exists, this object contains a zero value.')
bfd_sess_perf_echo_pkt_in = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 5), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktIn.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktIn.setDescription('The total number of BFD echo messages received for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfEchoPktInHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_echo_pkt_out = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktOut.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktOut.setDescription('The total number of BFD echo messages sent for this BFD session. It MUST be equal to the least significant 32 bits of bfdSessPerfEchoPktOutHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_echo_pkt_drop = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktDrop.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktDrop.setDescription('The total number of BFD echo messages received for this session yet dropped for being invalid. It MUST be equal to the least significant 32 bits of bfdSessPerfEchoPktDropHC if supported, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_echo_pkt_drop_last_time = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 8), time_stamp()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktDropLastTime.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktDropLastTime.setDescription('The value of sysUpTime on the most recent occasion at which received BFD echo message for this session was dropped. If no such up event has been issued, this object contains a zero value.')
bfd_sess_up_time = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 9), time_stamp()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessUpTime.setStatus('current')
if mibBuilder.loadTexts:
bfdSessUpTime.setDescription('The value of sysUpTime on the most recent occasion at which the session came up. If no such event has been issued, this object contains a zero value.')
bfd_sess_perf_last_sess_down_time = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 10), time_stamp()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfLastSessDownTime.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfLastSessDownTime.setDescription('The value of sysUpTime on the most recent occasion at which the last time communication was lost with the neighbor. If no down event has been issued this object contains a zero value.')
bfd_sess_perf_last_comm_lost_diag = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 11), ian_abfd_diag_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfLastCommLostDiag.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfLastCommLostDiag.setDescription('The BFD diag code for the last time communication was lost with the neighbor. If such an event has not been issued this object contains a zero value.')
bfd_sess_perf_sess_up_count = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 12), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfSessUpCount.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfSessUpCount.setDescription('The number of times this session has gone into the Up state since the system last rebooted.')
bfd_sess_perf_disc_time = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 13), time_stamp()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfDiscTime.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfDiscTime.setDescription('The value of sysUpTime on the most recent occasion at which any one or more of the session counters suffered a discontinuity. The relevant counters are the specific instances associated with this BFD session of any Counter32 object contained in the BfdSessPerfTable. If no such discontinuities have occurred since the last re-initialization of the local management subsystem, then this object contains a zero value.')
bfd_sess_perf_ctrl_pkt_in_hc = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 14), counter64()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktInHC.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktInHC.setDescription('This value represents the total number of BFD control messages received for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfCtrlPktIn, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_ctrl_pkt_out_hc = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 15), counter64()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktOutHC.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktOutHC.setDescription('This value represents the total number of BFD control messages transmitted for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfCtrlPktOut, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_ctrl_pkt_drop_hc = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 16), counter64()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktDropHC.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfCtrlPktDropHC.setDescription('This value represents the total number of BFD control messages received for this BFD session yet dropped for being invalid. The least significant 32 bits MUST equal to bfdSessPerfCtrlPktDrop, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_echo_pkt_in_hc = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 17), counter64()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktInHC.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktInHC.setDescription('This value represents the total number of BFD echo messages received for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfEchoPktIn, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_echo_pkt_out_hc = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 18), counter64()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktOutHC.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktOutHC.setDescription('This value represents the total number of BFD echo messages transmitted for this BFD session. The least significant 32 bits MUST equal to bfdSessPerfEchoPktOut, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_perf_echo_pkt_drop_hc = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 3, 1, 19), counter64()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktDropHC.setStatus('current')
if mibBuilder.loadTexts:
bfdSessPerfEchoPktDropHC.setDescription('This value represents the total number of BFD echo messages received for this BFD session yet dropped for being invalid. The least significant 32 bits MUST equal to bfdSessPerfEchoPktDrop, and MUST do so with the rules spelled out in RFC 2863.')
bfd_sess_disc_map_table = mib_table((1, 3, 6, 1, 2, 1, 222, 1, 4))
if mibBuilder.loadTexts:
bfdSessDiscMapTable.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDiscMapTable.setDescription("The BFD Session Discriminator Mapping Table maps a local discriminator value to associated BFD session's bfdSessIndex found in the bfdSessionTable.")
bfd_sess_disc_map_entry = mib_table_row((1, 3, 6, 1, 2, 1, 222, 1, 4, 1)).setIndexNames((0, 'BFD-STD-MIB', 'bfdSessDiscriminator'))
if mibBuilder.loadTexts:
bfdSessDiscMapEntry.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDiscMapEntry.setDescription('The BFD Session Discriminator Mapping Entry specifies a mapping between a local discriminator and a BFD session.')
bfd_sess_disc_map_index = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 4, 1, 1), bfd_sess_index_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessDiscMapIndex.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDiscMapIndex.setDescription('This object specifies a mapping between a local discriminator and a BFD Session in the BfdSessTable.')
bfd_sess_ip_map_table = mib_table((1, 3, 6, 1, 2, 1, 222, 1, 5))
if mibBuilder.loadTexts:
bfdSessIpMapTable.setStatus('current')
if mibBuilder.loadTexts:
bfdSessIpMapTable.setDescription('The BFD Session IP Mapping Table maps given bfdSessInterface, bfdSessSrcAddrType, bfdSessSrcAddr, bfdSessDstAddrType and bfdSessDstAddr to an associated BFD session found in the bfdSessionTable.')
bfd_sess_ip_map_entry = mib_table_row((1, 3, 6, 1, 2, 1, 222, 1, 5, 1)).setIndexNames((0, 'BFD-STD-MIB', 'bfdSessInterface'), (0, 'BFD-STD-MIB', 'bfdSessSrcAddrType'), (0, 'BFD-STD-MIB', 'bfdSessSrcAddr'), (0, 'BFD-STD-MIB', 'bfdSessDstAddrType'), (0, 'BFD-STD-MIB', 'bfdSessDstAddr'))
if mibBuilder.loadTexts:
bfdSessIpMapEntry.setStatus('current')
if mibBuilder.loadTexts:
bfdSessIpMapEntry.setDescription('The BFD Session IP Map Entry contains a mapping from the IP information for a session, to the session in the bfdSessionTable.')
bfd_sess_ip_map_index = mib_table_column((1, 3, 6, 1, 2, 1, 222, 1, 5, 1, 1), bfd_sess_index_tc()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bfdSessIpMapIndex.setStatus('current')
if mibBuilder.loadTexts:
bfdSessIpMapIndex.setDescription('This object specifies the BfdSessIndexTC referred to by the indexes of this row. In essence, a mapping is provided between these indexes and the BfdSessTable.')
bfd_sess_up = notification_type((1, 3, 6, 1, 2, 1, 222, 0, 1)).setObjects(('BFD-STD-MIB', 'bfdSessDiag'), ('BFD-STD-MIB', 'bfdSessDiag'))
if mibBuilder.loadTexts:
bfdSessUp.setStatus('current')
if mibBuilder.loadTexts:
bfdSessUp.setDescription('This notification is generated when the bfdSessState object for one or more contiguous entries in bfdSessTable are about to enter the up(4) state from some other state. The included values of bfdSessDiag MUST both be set equal to this new state (i.e: up(4)). The two instances of bfdSessDiag in this notification indicate the range of indexes that are affected. Note that all the indexes of the two ends of the range can be derived from the instance identifiers of these two objects. For the cases where a contiguous range of sessions have transitioned into the up(4) state at roughly the same time, the device SHOULD issue a single notification for each range of contiguous indexes in an effort to minimize the emission of a large number of notifications. If a notification has to be issued for just a single bfdSessEntry, then the instance identifier (and values) of the two bfdSessDiag objects MUST be the identical.')
bfd_sess_down = notification_type((1, 3, 6, 1, 2, 1, 222, 0, 2)).setObjects(('BFD-STD-MIB', 'bfdSessDiag'), ('BFD-STD-MIB', 'bfdSessDiag'))
if mibBuilder.loadTexts:
bfdSessDown.setStatus('current')
if mibBuilder.loadTexts:
bfdSessDown.setDescription('This notification is generated when the bfdSessState object for one or more contiguous entries in bfdSessTable are about to enter the down(2) or adminDown(1) states from some other state. The included values of bfdSessDiag MUST both be set equal to this new state (i.e: down(2) or adminDown(1)). The two instances of bfdSessDiag in this notification indicate the range of indexes that are affected. Note that all the indexes of the two ends of the range can be derived from the instance identifiers of these two objects. For cases where a contiguous range of sessions have transitioned into the down(2) or adminDown(1) states at roughly the same time, the device SHOULD issue a single notification for each range of contiguous indexes in an effort to minimize the emission of a large number of notifications. If a notification has to be issued for just a single bfdSessEntry, then the instance identifier (and values) of the two bfdSessDiag objects MUST be the identical.')
bfd_groups = mib_identifier((1, 3, 6, 1, 2, 1, 222, 2, 1))
bfd_compliances = mib_identifier((1, 3, 6, 1, 2, 1, 222, 2, 2))
bfd_module_full_compliance = module_compliance((1, 3, 6, 1, 2, 1, 222, 2, 2, 1)).setObjects(('BFD-STD-MIB', 'bfdSessionGroup'), ('BFD-STD-MIB', 'bfdSessionReadOnlyGroup'), ('BFD-STD-MIB', 'bfdSessionPerfGroup'), ('BFD-STD-MIB', 'bfdNotificationGroup'), ('BFD-STD-MIB', 'bfdSessionPerfHCGroup'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfd_module_full_compliance = bfdModuleFullCompliance.setStatus('current')
if mibBuilder.loadTexts:
bfdModuleFullCompliance.setDescription('Compliance statement for agents that provide full support for the BFD-MIB module. Such devices can then be monitored and also be configured using this MIB module.')
bfd_module_read_only_compliance = module_compliance((1, 3, 6, 1, 2, 1, 222, 2, 2, 2)).setObjects(('BFD-STD-MIB', 'bfdSessionGroup'), ('BFD-STD-MIB', 'bfdSessionReadOnlyGroup'), ('BFD-STD-MIB', 'bfdSessionPerfGroup'), ('BFD-STD-MIB', 'bfdNotificationGroup'), ('BFD-STD-MIB', 'bfdSessionPerfHCGroup'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfd_module_read_only_compliance = bfdModuleReadOnlyCompliance.setStatus('current')
if mibBuilder.loadTexts:
bfdModuleReadOnlyCompliance.setDescription('Compliance requirement for implementations that only provide read-only support for BFD-MIB. Such devices can then be monitored but cannot be configured using this MIB module.')
bfd_session_group = object_group((1, 3, 6, 1, 2, 1, 222, 2, 1, 1)).setObjects(('BFD-STD-MIB', 'bfdAdminStatus'), ('BFD-STD-MIB', 'bfdOperStatus'), ('BFD-STD-MIB', 'bfdNotificationsEnable'), ('BFD-STD-MIB', 'bfdSessVersionNumber'), ('BFD-STD-MIB', 'bfdSessType'), ('BFD-STD-MIB', 'bfdSessIndexNext'), ('BFD-STD-MIB', 'bfdSessDiscriminator'), ('BFD-STD-MIB', 'bfdSessDestinationUdpPort'), ('BFD-STD-MIB', 'bfdSessSourceUdpPort'), ('BFD-STD-MIB', 'bfdSessEchoSourceUdpPort'), ('BFD-STD-MIB', 'bfdSessAdminStatus'), ('BFD-STD-MIB', 'bfdSessOperStatus'), ('BFD-STD-MIB', 'bfdSessOperMode'), ('BFD-STD-MIB', 'bfdSessDemandModeDesiredFlag'), ('BFD-STD-MIB', 'bfdSessControlPlaneIndepFlag'), ('BFD-STD-MIB', 'bfdSessMultipointFlag'), ('BFD-STD-MIB', 'bfdSessInterface'), ('BFD-STD-MIB', 'bfdSessSrcAddrType'), ('BFD-STD-MIB', 'bfdSessSrcAddr'), ('BFD-STD-MIB', 'bfdSessDstAddrType'), ('BFD-STD-MIB', 'bfdSessDstAddr'), ('BFD-STD-MIB', 'bfdSessGTSM'), ('BFD-STD-MIB', 'bfdSessGTSMTTL'), ('BFD-STD-MIB', 'bfdSessDesiredMinTxInterval'), ('BFD-STD-MIB', 'bfdSessReqMinRxInterval'), ('BFD-STD-MIB', 'bfdSessReqMinEchoRxInterval'), ('BFD-STD-MIB', 'bfdSessDetectMult'), ('BFD-STD-MIB', 'bfdSessAuthPresFlag'), ('BFD-STD-MIB', 'bfdSessAuthenticationType'), ('BFD-STD-MIB', 'bfdSessAuthenticationKeyID'), ('BFD-STD-MIB', 'bfdSessAuthenticationKey'), ('BFD-STD-MIB', 'bfdSessStorageType'), ('BFD-STD-MIB', 'bfdSessRowStatus'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfd_session_group = bfdSessionGroup.setStatus('current')
if mibBuilder.loadTexts:
bfdSessionGroup.setDescription('Collection of objects needed for BFD sessions.')
bfd_session_read_only_group = object_group((1, 3, 6, 1, 2, 1, 222, 2, 1, 2)).setObjects(('BFD-STD-MIB', 'bfdSessRemoteDiscr'), ('BFD-STD-MIB', 'bfdSessState'), ('BFD-STD-MIB', 'bfdSessRemoteHeardFlag'), ('BFD-STD-MIB', 'bfdSessDiag'), ('BFD-STD-MIB', 'bfdSessNegotiatedInterval'), ('BFD-STD-MIB', 'bfdSessNegotiatedEchoInterval'), ('BFD-STD-MIB', 'bfdSessNegotiatedDetectMult'), ('BFD-STD-MIB', 'bfdSessDiscMapIndex'), ('BFD-STD-MIB', 'bfdSessIpMapIndex'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfd_session_read_only_group = bfdSessionReadOnlyGroup.setStatus('current')
if mibBuilder.loadTexts:
bfdSessionReadOnlyGroup.setDescription('Collection of read-only objects needed for BFD sessions.')
bfd_session_perf_group = object_group((1, 3, 6, 1, 2, 1, 222, 2, 1, 3)).setObjects(('BFD-STD-MIB', 'bfdSessPerfCtrlPktIn'), ('BFD-STD-MIB', 'bfdSessPerfCtrlPktOut'), ('BFD-STD-MIB', 'bfdSessPerfCtrlPktDrop'), ('BFD-STD-MIB', 'bfdSessPerfCtrlPktDropLastTime'), ('BFD-STD-MIB', 'bfdSessPerfEchoPktIn'), ('BFD-STD-MIB', 'bfdSessPerfEchoPktOut'), ('BFD-STD-MIB', 'bfdSessPerfEchoPktDrop'), ('BFD-STD-MIB', 'bfdSessPerfEchoPktDropLastTime'), ('BFD-STD-MIB', 'bfdSessUpTime'), ('BFD-STD-MIB', 'bfdSessPerfLastSessDownTime'), ('BFD-STD-MIB', 'bfdSessPerfLastCommLostDiag'), ('BFD-STD-MIB', 'bfdSessPerfSessUpCount'), ('BFD-STD-MIB', 'bfdSessPerfDiscTime'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfd_session_perf_group = bfdSessionPerfGroup.setStatus('current')
if mibBuilder.loadTexts:
bfdSessionPerfGroup.setDescription('Collection of objects needed to monitor the performance of BFD sessions.')
bfd_session_perf_hc_group = object_group((1, 3, 6, 1, 2, 1, 222, 2, 1, 4)).setObjects(('BFD-STD-MIB', 'bfdSessPerfCtrlPktInHC'), ('BFD-STD-MIB', 'bfdSessPerfCtrlPktOutHC'), ('BFD-STD-MIB', 'bfdSessPerfCtrlPktDropHC'), ('BFD-STD-MIB', 'bfdSessPerfEchoPktInHC'), ('BFD-STD-MIB', 'bfdSessPerfEchoPktOutHC'), ('BFD-STD-MIB', 'bfdSessPerfEchoPktDropHC'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfd_session_perf_hc_group = bfdSessionPerfHCGroup.setStatus('current')
if mibBuilder.loadTexts:
bfdSessionPerfHCGroup.setDescription('Collection of objects needed to monitor the performance of BFD sessions for which the values of bfdSessPerfPktIn, bfdSessPerfPktOut wrap around too quickly.')
bfd_notification_group = notification_group((1, 3, 6, 1, 2, 1, 222, 2, 1, 5)).setObjects(('BFD-STD-MIB', 'bfdSessUp'), ('BFD-STD-MIB', 'bfdSessDown'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
bfd_notification_group = bfdNotificationGroup.setStatus('current')
if mibBuilder.loadTexts:
bfdNotificationGroup.setDescription('Set of notifications implemented in this module.')
mibBuilder.exportSymbols('BFD-STD-MIB', bfdSessDstAddr=bfdSessDstAddr, bfdSessVersionNumber=bfdSessVersionNumber, bfdSessUp=bfdSessUp, bfdSessDiscMapIndex=bfdSessDiscMapIndex, bfdSessPerfLastSessDownTime=bfdSessPerfLastSessDownTime, bfdGroups=bfdGroups, PYSNMP_MODULE_ID=bfdMIB, bfdSessSourceUdpPort=bfdSessSourceUdpPort, bfdScalarObjects=bfdScalarObjects, bfdCompliances=bfdCompliances, bfdSessSrcAddr=bfdSessSrcAddr, bfdSessPerfCtrlPktDropHC=bfdSessPerfCtrlPktDropHC, bfdSessPerfCtrlPktIn=bfdSessPerfCtrlPktIn, bfdSessEchoSourceUdpPort=bfdSessEchoSourceUdpPort, bfdSessRemoteHeardFlag=bfdSessRemoteHeardFlag, bfdSessionGroup=bfdSessionGroup, bfdSessOperStatus=bfdSessOperStatus, bfdSessDestinationUdpPort=bfdSessDestinationUdpPort, bfdSessDetectMult=bfdSessDetectMult, bfdSessStorageType=bfdSessStorageType, bfdSessReqMinEchoRxInterval=bfdSessReqMinEchoRxInterval, bfdSessDiscriminator=bfdSessDiscriminator, bfdSessControlPlaneIndepFlag=bfdSessControlPlaneIndepFlag, bfdSessMultipointFlag=bfdSessMultipointFlag, bfdSessPerfEchoPktOutHC=bfdSessPerfEchoPktOutHC, bfdSessOperMode=bfdSessOperMode, bfdSessNegotiatedInterval=bfdSessNegotiatedInterval, bfdSessPerfEntry=bfdSessPerfEntry, bfdSessPerfSessUpCount=bfdSessPerfSessUpCount, bfdSessPerfCtrlPktOutHC=bfdSessPerfCtrlPktOutHC, bfdNotificationsEnable=bfdNotificationsEnable, bfdSessSrcAddrType=bfdSessSrcAddrType, bfdSessUpTime=bfdSessUpTime, bfdSessPerfEchoPktDropHC=bfdSessPerfEchoPktDropHC, bfdSessState=bfdSessState, bfdSessIpMapTable=bfdSessIpMapTable, bfdSessAuthenticationKeyID=bfdSessAuthenticationKeyID, bfdNotificationGroup=bfdNotificationGroup, bfdSessInterface=bfdSessInterface, bfdSessGTSMTTL=bfdSessGTSMTTL, bfdSessPerfLastCommLostDiag=bfdSessPerfLastCommLostDiag, bfdSessPerfEchoPktIn=bfdSessPerfEchoPktIn, bfdSessIndexNext=bfdSessIndexNext, bfdNotifications=bfdNotifications, bfdSessDstAddrType=bfdSessDstAddrType, bfdSessDiscMapEntry=bfdSessDiscMapEntry, bfdSessIpMapIndex=bfdSessIpMapIndex, bfdSessAuthPresFlag=bfdSessAuthPresFlag, bfdSessNegotiatedEchoInterval=bfdSessNegotiatedEchoInterval, bfdSessPerfCtrlPktOut=bfdSessPerfCtrlPktOut, bfdSessAuthenticationType=bfdSessAuthenticationType, bfdSessDiag=bfdSessDiag, bfdSessGTSM=bfdSessGTSM, bfdSessTable=bfdSessTable, bfdSessPerfCtrlPktDrop=bfdSessPerfCtrlPktDrop, bfdSessionPerfHCGroup=bfdSessionPerfHCGroup, bfdSessPerfTable=bfdSessPerfTable, bfdObjects=bfdObjects, bfdModuleFullCompliance=bfdModuleFullCompliance, bfdSessDesiredMinTxInterval=bfdSessDesiredMinTxInterval, bfdSessAuthenticationKey=bfdSessAuthenticationKey, bfdSessPerfCtrlPktInHC=bfdSessPerfCtrlPktInHC, bfdSessReqMinRxInterval=bfdSessReqMinRxInterval, bfdSessIpMapEntry=bfdSessIpMapEntry, bfdModuleReadOnlyCompliance=bfdModuleReadOnlyCompliance, bfdSessIndex=bfdSessIndex, bfdSessType=bfdSessType, bfdSessionPerfGroup=bfdSessionPerfGroup, bfdSessRemoteDiscr=bfdSessRemoteDiscr, bfdSessEntry=bfdSessEntry, bfdSessPerfDiscTime=bfdSessPerfDiscTime, bfdSessPerfEchoPktInHC=bfdSessPerfEchoPktInHC, bfdConformance=bfdConformance, bfdSessPerfCtrlPktDropLastTime=bfdSessPerfCtrlPktDropLastTime, bfdSessRowStatus=bfdSessRowStatus, bfdSessAdminStatus=bfdSessAdminStatus, bfdSessPerfEchoPktOut=bfdSessPerfEchoPktOut, bfdSessDown=bfdSessDown, bfdSessPerfEchoPktDropLastTime=bfdSessPerfEchoPktDropLastTime, bfdSessionReadOnlyGroup=bfdSessionReadOnlyGroup, bfdOperStatus=bfdOperStatus, bfdSessDiscMapTable=bfdSessDiscMapTable, bfdMIB=bfdMIB, bfdAdminStatus=bfdAdminStatus, bfdSessPerfEchoPktDrop=bfdSessPerfEchoPktDrop, bfdSessDemandModeDesiredFlag=bfdSessDemandModeDesiredFlag, bfdSessNegotiatedDetectMult=bfdSessNegotiatedDetectMult) |
class Solution:
def judgeCircle(self, moves: str) -> bool:
x_axis = y_axis = 0
for move in moves:
if move == "U":
y_axis += 1
elif move == "D":
y_axis -= 1
elif move == "R":
x_axis += 1
elif move == "L":
x_axis -= 1
return not x_axis and not y_axis
| class Solution:
def judge_circle(self, moves: str) -> bool:
x_axis = y_axis = 0
for move in moves:
if move == 'U':
y_axis += 1
elif move == 'D':
y_axis -= 1
elif move == 'R':
x_axis += 1
elif move == 'L':
x_axis -= 1
return not x_axis and (not y_axis) |
with open("EX10.txt","r") as fp:
words = 0
for data in fp:
lines=data.split()
for line in lines:
words += 1
print("Total No.of Words:",words) | with open('EX10.txt', 'r') as fp:
words = 0
for data in fp:
lines = data.split()
for line in lines:
words += 1
print('Total No.of Words:', words) |
"""
Hello, World!
"""
# 1. Print a string
print("This line will be printed.")
# 2. Indentation for blocks (four spaces)
x = 1
if x == 1:
# indented four spaces
print("x is 1.")
| """
Hello, World!
"""
print('This line will be printed.')
x = 1
if x == 1:
print('x is 1.') |
__author__ = 'zoulida'
class people(object):
def __new__(cls, *args, **kargs):
return super(people, cls).__new__(cls)
def __init__(self, name):
self.name = name
def talk(self):
print("hello,I am %s" % self.name)
class student(people):
def __new__(cls, *args, **kargs):
if not hasattr(cls, "instance"):
cls.instance = super(student, cls).__new__(cls, *args, **kargs)
return cls.instance
def __init__(self, name):
if not hasattr(self, "init_fir"):
self.init_fir = True
super(student, self).__init__(name)
a = student("Timo")
print(a)
b = student("kysa")
c = student("Luyi")
a.talk()
b.talk()
print(c)
| __author__ = 'zoulida'
class People(object):
def __new__(cls, *args, **kargs):
return super(people, cls).__new__(cls)
def __init__(self, name):
self.name = name
def talk(self):
print('hello,I am %s' % self.name)
class Student(people):
def __new__(cls, *args, **kargs):
if not hasattr(cls, 'instance'):
cls.instance = super(student, cls).__new__(cls, *args, **kargs)
return cls.instance
def __init__(self, name):
if not hasattr(self, 'init_fir'):
self.init_fir = True
super(student, self).__init__(name)
a = student('Timo')
print(a)
b = student('kysa')
c = student('Luyi')
a.talk()
b.talk()
print(c) |
nombres=[]
sueldo=[]
totalsueldos=[]
for x in range(3):
nombres.append(input("Cual es tu nombre? "))
mes1=int(input("Cual fue tu sueldo de Junio? "))
mes2=int(input("Cual fue tu sueldo de Julio? "))
mes3=int(input("Cual fue tu sueldo de Agosto? "))
sueldo.append([mes1,mes2,mes3])
totalsueldos.append(mes1+mes2+mes3)
print(nombres)
print(sueldo)
print(totalsueldos) | nombres = []
sueldo = []
totalsueldos = []
for x in range(3):
nombres.append(input('Cual es tu nombre? '))
mes1 = int(input('Cual fue tu sueldo de Junio? '))
mes2 = int(input('Cual fue tu sueldo de Julio? '))
mes3 = int(input('Cual fue tu sueldo de Agosto? '))
sueldo.append([mes1, mes2, mes3])
totalsueldos.append(mes1 + mes2 + mes3)
print(nombres)
print(sueldo)
print(totalsueldos) |
# contains hyperparameters for our seq2seq model. you can add some more
config = {
'batch_size': 200,
'max_vocab_size': 20000,
'max_seq_len': 26, # decided based on the sentence length distribution of amazon corpus
'embedding_dim': 100, # we had trained a 100-dim w2v vecs in tut 1
}
| config = {'batch_size': 200, 'max_vocab_size': 20000, 'max_seq_len': 26, 'embedding_dim': 100} |
class Solution:
def isValid(self, s: str) -> bool:
stack = []
other_half = {")": "(", "]": "[", "}": "{"}
for char in s:
if char in "{[(":
stack.append(char)
elif char in ")]}" and stack and stack[-1] == other_half[char]:
stack.pop()
else:
return False
return not stack
if __name__ == "__main__":
solver = Solution()
print(solver.isValid("()[]{}"))
print(solver.isValid("([)]"))
| class Solution:
def is_valid(self, s: str) -> bool:
stack = []
other_half = {')': '(', ']': '[', '}': '{'}
for char in s:
if char in '{[(':
stack.append(char)
elif char in ')]}' and stack and (stack[-1] == other_half[char]):
stack.pop()
else:
return False
return not stack
if __name__ == '__main__':
solver = solution()
print(solver.isValid('()[]{}'))
print(solver.isValid('([)]')) |
skills = [
{
"id": "0001",
"name": "Liver of Steel",
"type": "Passive",
"isPermable": False,
"effects": {"maximumInebriety": "+5"},
},
{"id": "0002", "name": "Chronic Indigestion", "type": "Combat", "mpCost": 5},
{
"id": "0003",
"name": "The Smile of Mr. A.",
"type": "Buff",
"mpCost": 5,
"isPermable": False,
},
{
"id": "0004",
"name": "Arse Shoot",
"type": "Buff",
"mpCost": 5,
"isPermable": False,
},
{
"id": "0005",
"name": "Stomach of Steel",
"type": "Passive",
"isPermable": False,
"effects": {"maximumFullness": "+5"},
},
{
"id": "0006",
"name": "Spleen of Steel",
"type": "Passive",
"isPermable": False,
"effects": {"maximumSpleen": "+5"},
},
{
"id": "0010",
"name": "Powers of Observatiogn",
"type": "Passive",
"effects": {"itemDrop": "+10%"},
},
{
"id": "0011",
"name": "Gnefarious Pickpocketing",
"type": "Passive",
"effects": {"meatDrop": "+10%"},
},
{"id": "0012", "name": "Torso Awaregness", "type": "Passive"},
{
"id": "0013",
"name": "Gnomish Hardigness",
"type": "Passive",
"effects": {"maximumHP": "+5%"},
},
{
"id": "0014",
"name": "Cosmic Ugnderstanding",
"type": "Passive",
"effects": {"maximumMP": "+5%"},
},
{"id": "0015", "name": "CLEESH", "type": "Combat", "mpCost": 10},
{
"id": "0019",
"name": "Transcendent Olfaction",
"type": "Combat",
"mpCost": 40,
"isAutomaticallyPermed": True,
},
{
"id": "0020",
"name": "Really Expensive Jewelrycrafting",
"type": "Passive",
"isPermable": False,
},
{
"id": "0021",
"name": "Lust",
"type": "Passive",
"isPermable": False,
"effects": {
"combatInitiative": "+50%",
"spellDamage": "-5",
"meleeDamage": "-5",
},
},
{
"id": "0022",
"name": "Gluttony",
"type": "Passive",
"isPermable": False,
"effects": {"strengthensFood": True, "statsPerFight": "-2"},
},
{
"id": "0023",
"name": "Greed",
"type": "Passive",
"isPermable": False,
"effects": {"meatDrop": "+50%", "itemDrop": "-15%"},
},
{
"id": "0024",
"name": "Sloth",
"type": "Passive",
"isPermable": False,
"effects": {"damageReduction": "+8", "combatInitiative": "-25%"},
},
{
"id": "0025",
"name": "Wrath",
"type": "Passive",
"isPermable": False,
"effects": {
"spellDamage": "+10",
"meleeDamage": "+10",
"damageReduction": "-4",
},
},
{
"id": "0026",
"name": "Envy",
"type": "Passive",
"isPermable": False,
"effects": {"itemDrop": "+30%", "meatDrop": "-25%"},
},
{
"id": "0027",
"name": "Pride",
"type": "Passive",
"isPermable": False,
"effects": {"statsPerFight": "+4", "weakensFood": True},
},
{"id": "0028", "name": "Awesome Balls of Fire", "type": "Combat", "mpCost": 120},
{"id": "0029", "name": "Conjure Relaxing Campfire", "type": "Combat", "mpCost": 30},
{"id": "0030", "name": "Snowclone", "type": "Combat", "mpCost": 120},
{"id": "0031", "name": "Maximum Chill", "type": "Combat", "mpCost": 30},
{"id": "0032", "name": "Eggsplosion", "type": "Combat", "mpCost": 120},
{"id": "0033", "name": "Mudbath", "type": "Combat", "mpCost": 30},
{"id": "0036", "name": "Grease Lightning", "type": "Combat", "mpCost": 120},
{"id": "0037", "name": "Inappropriate Backrub", "type": "Combat", "mpCost": 30},
{
"id": "0038",
"name": "Natural Born Scrabbler",
"type": "Passive",
"effects": {"itemDrop": "+5%"},
},
{
"id": "0039",
"name": "Thrift and Grift",
"type": "Passive",
"effects": {"meatDrop": "+10%"},
},
{
"id": "0040",
"name": "Abs of Tin",
"type": "Passive",
"effects": {"maximumHP": "+10%"},
},
{
"id": "0041",
"name": "Marginally Insane",
"type": "Passive",
"effects": {"maximumMP": "+10%"},
},
{"id": "0042", "name": "Raise Backup Dancer", "type": "Combat", "mpCost": 120},
{"id": "0043", "name": "Creepy Lullaby", "type": "Combat", "mpCost": 30},
{"id": "0044", "name": "Rainbow Gravitation", "type": "Noncombat", "mpCost": 30},
{"id": "1000", "name": "Seal Clubbing Frenzy", "type": "Noncombat", "mpCost": 1},
{"id": "1003", "name": "Thrust-Smack", "type": "Combat", "mpCost": 3},
{"id": "1004", "name": "Lunge-Smack", "type": "Combat", "mpCost": 5},
{"id": "1005", "name": "Lunging Thrust-Smack", "type": "Combat", "mpCost": 8},
{"id": "1006", "name": "Super-Advanced Meatsmithing", "type": "Passive"},
{"id": "1007", "name": "Tongue of the Otter", "type": "Noncombat", "mpCost": 7},
{"id": "1008", "name": "Hide of the Otter", "type": "Passive"},
{"id": "1009", "name": "Claws of the Otter", "type": "Passive"},
{"id": "1010", "name": "Tongue of the Walrus", "type": "Noncombat", "mpCost": 10},
{"id": "1011", "name": "Hide of the Walrus", "type": "Passive"},
{"id": "1012", "name": "Claws of the Walrus", "type": "Passive"},
{"id": "1014", "name": "Eye of the Stoat", "type": "Passive"},
{"id": "1015", "name": "Rage of the Reindeer", "type": "Noncombat", "mpCost": 10},
{"id": "1016", "name": "Pulverize", "type": "Passive"},
{"id": "1017", "name": "Double-Fisted Skull Smashing", "type": "Passive"},
{"id": "1018", "name": "Northern Exposure", "type": "Passive"},
{"id": "1019", "name": "Musk of the Moose", "type": "Noncombat", "mpCost": 10},
{
"id": "1020",
"name": "Snarl of the Timberwolf",
"type": "Noncombat",
"mpCost": 10,
},
{
"id": "2000",
"name": "Patience of the Tortoise",
"type": "Noncombat",
"mpCost": 1,
},
{"id": "2003", "name": "Headbutt", "type": "Combat", "mpCost": 3},
{"id": "2004", "name": "Skin of the Leatherback", "type": "Passive"},
{"id": "2005", "name": "Shieldbutt", "type": "Combat", "mpCost": 5},
{"id": "2006", "name": "Armorcraftiness", "type": "Passive"},
{"id": "2007", "name": "Ghostly Shell", "type": "Buff", "mpCost": 6},
{"id": "2008", "name": "Reptilian Fortitude", "type": "Buff", "mpCost": 10},
{"id": "2009", "name": "Empathy of the Newt", "type": "Buff", "mpCost": 15},
{"id": "2010", "name": "Tenacity of the Snapper", "type": "Buff", "mpCost": 8},
{"id": "2011", "name": "Wisdom of the Elder Tortoises", "type": "Passive"},
{"id": "2012", "name": "Astral Shell", "type": "Buff", "mpCost": 10},
{"id": "2014", "name": "Amphibian Sympathy", "type": "Passive"},
{"id": "2015", "name": "Kneebutt", "type": "Combat", "mpCost": 4},
{"id": "2016", "name": "Cold-Blooded Fearlessness", "type": "Passive"},
{"id": "2020", "name": "Hero of the Half-Shell", "type": "Passive"},
{"id": "2021", "name": "Tao of the Terrapin", "type": "Passive"},
{"id": "2022", "name": "Spectral Snapper", "type": "Combat", "mpCost": 20},
{"id": "2103", "name": "Head + Knee Combo", "type": "Combat", "mpCost": 8},
{"id": "2105", "name": "Head + Shield Combo", "type": "Combat", "mpCost": 9},
{"id": "2106", "name": "Knee + Shield Combo", "type": "Combat", "mpCost": 10},
{
"id": "2107",
"name": "Head + Knee + Shield Combo",
"type": "Combat",
"mpCost": 13,
},
{"id": "3000", "name": "Manicotti Meditation", "type": "Noncombat", "mpCost": 1},
{"id": "3003", "name": "Ravioli Shurikens", "type": "Combat", "mpCost": 4},
{"id": "3004", "name": "Entangling Noodles", "type": "Combat", "mpCost": 3},
{"id": "3005", "name": "Cannelloni Cannon", "type": "Combat", "mpCost": 7},
{"id": "3006", "name": "Pastamastery", "type": "Noncombat", "mpCost": 10},
{"id": "3007", "name": "Stuffed Mortar Shell", "type": "Combat", "mpCost": 19},
{"id": "3008", "name": "Weapon of the Pastalord", "type": "Combat", "mpCost": 35},
{
"id": "3009",
"name": "Lasagna Bandages",
"type": "Combat / Noncombat",
"mpCost": 6,
},
{"id": "3010", "name": "Leash of Linguini", "type": "Noncombat", "mpCost": 12},
{"id": "3011", "name": "Spirit of Rigatoni", "type": "Passive"},
{"id": "3012", "name": "Cannelloni Cocoon", "type": "Noncombat", "mpCost": 20},
{"id": "3014", "name": "Spirit of Ravioli", "type": "Passive"},
{"id": "3015", "name": "Springy Fusilli", "type": "Noncombat", "mpCost": 10},
{"id": "3016", "name": "Tolerance of the Kitchen", "type": "Passive"},
{"id": "3017", "name": "Flavour of Magic", "type": "Noncombat", "mpCost": 10},
{"id": "3018", "name": "Transcendental Noodlecraft", "type": "Passive"},
{"id": "3019", "name": "Fearful Fettucini", "type": "Combat", "mpCost": 35},
{"id": "3020", "name": "Spaghetti Spear", "type": "Combat", "mpCost": 1},
{"id": "3101", "name": "Spirit of Cayenne", "type": "Noncombat", "mpCost": 10},
{"id": "3102", "name": "Spirit of Peppermint", "type": "Noncombat", "mpCost": 10},
{"id": "3103", "name": "Spirit of Garlic", "type": "Noncombat", "mpCost": 10},
{"id": "3104", "name": "Spirit of Wormwood", "type": "Noncombat", "mpCost": 10},
{"id": "3105", "name": "Spirit of Bacon Grease", "type": "Noncombat", "mpCost": 10},
{"id": "4000", "name": "Sauce Contemplation", "type": "Noncombat", "mpCost": 1},
{"id": "4003", "name": "Stream of Sauce", "type": "Combat", "mpCost": 3},
{"id": "4004", "name": "Expert Panhandling", "type": "Passive"},
{"id": "4005", "name": "Saucestorm", "type": "Combat", "mpCost": 12},
{"id": "4006", "name": "Advanced Saucecrafting", "type": "Noncombat", "mpCost": 10},
{"id": "4007", "name": "Elemental Saucesphere", "type": "Buff", "mpCost": 10},
{"id": "4008", "name": "Jalapeno Saucesphere", "type": "Buff", "mpCost": 5},
{"id": "4009", "name": "Wave of Sauce", "type": "Combat", "mpCost": 23},
{"id": "4010", "name": "Intrinsic Spiciness", "type": "Passive"},
{"id": "4011", "name": "Jabanero Saucesphere", "type": "Buff", "mpCost": 10},
{"id": "4012", "name": "Saucegeyser", "type": "Combat", "mpCost": 40},
{"id": "4014", "name": "Saucy Salve", "type": "Combat", "mpCost": 4},
{"id": "4015", "name": "Impetuous Sauciness", "type": "Passive"},
{"id": "4016", "name": "Diminished Gag Reflex", "type": "Passive"},
{"id": "4017", "name": "Immaculate Seasoning", "type": "Passive"},
{"id": "4018", "name": "The Way of Sauce", "type": "Passive"},
{"id": "4019", "name": "Scarysauce", "type": "Buff", "mpCost": 10},
{"id": "4020", "name": "Salsaball", "type": "Combat", "mpCost": 1},
{"id": "5000", "name": "Disco Aerobics", "type": "Noncombat", "mpCost": 1},
{"id": "5003", "name": "Disco Eye-Poke", "type": "Combat", "mpCost": 3},
{"id": "5004", "name": "Nimble Fingers", "type": "Passive"},
{"id": "5005", "name": "Disco Dance of Doom", "type": "Combat", "mpCost": 5},
{"id": "5006", "name": "Mad Looting Skillz", "type": "Passive"},
{"id": "5007", "name": "Disco Nap", "type": "Noncombat", "mpCost": 8},
{
"id": "5008",
"name": "Disco Dance II: Electric Boogaloo",
"type": "Combat",
"mpCost": 7,
},
{"id": "5009", "name": "Disco Fever", "type": "Passive"},
{
"id": "5010",
"name": "Overdeveloped Sense of Self Preservation",
"type": "Passive",
},
{"id": "5011", "name": "Disco Power Nap", "type": "Noncombat", "mpCost": 12},
{"id": "5012", "name": "Disco Face Stab", "type": "Combat", "mpCost": 10},
{
"id": "5014",
"name": "Advanced Cocktailcrafting",
"type": "Noncombat",
"mpCost": 10,
},
{"id": "5015", "name": "Ambidextrous Funkslinging", "type": "Passive"},
{"id": "5016", "name": "Heart of Polyester", "type": "Passive"},
{"id": "5017", "name": "Smooth Movement", "type": "Noncombat", "mpCost": 10},
{"id": "5018", "name": "Superhuman Cocktailcrafting", "type": "Passive"},
{"id": "5019", "name": "Tango of Terror", "type": "Combat", "mpCost": 8},
{"id": "6000", "name": "Moxie of the Mariachi", "type": "Noncombat", "mpCost": 1},
{
"id": "6003",
"name": "Aloysius' Antiphon of Aptitude",
"type": "Buff",
"mpCost": 40,
},
{"id": "6004", "name": "The Moxious Madrigal", "type": "Buff", "mpCost": 2},
{
"id": "6005",
"name": "Cletus's Canticle of Celerity",
"type": "Buff",
"mpCost": 4,
},
{"id": "6006", "name": "The Polka of Plenty", "type": "Buff", "mpCost": 7},
{
"id": "6007",
"name": "The Magical Mojomuscular Melody",
"type": "Buff",
"mpCost": 3,
},
{
"id": "6008",
"name": "The Power Ballad of the Arrowsmith",
"type": "Buff",
"mpCost": 5,
},
{
"id": "6009",
"name": "Brawnee's Anthem of Absorption",
"type": "Buff",
"mpCost": 13,
},
{"id": "6010", "name": "Fat Leon's Phat Loot Lyric", "type": "Buff", "mpCost": 11},
{"id": "6011", "name": "The Psalm of Pointiness", "type": "Buff", "mpCost": 15},
{
"id": "6012",
"name": "Jackasses' Symphony of Destruction",
"type": "Buff",
"mpCost": 9,
},
{
"id": "6013",
"name": "Stevedave's Shanty of Superiority",
"type": "Buff",
"mpCost": 30,
},
{"id": "6014", "name": "The Ode to Booze", "type": "Buff", "mpCost": 50},
{"id": "6015", "name": "The Sonata of Sneakiness", "type": "Buff", "mpCost": 20},
{
"id": "6016",
"name": "Carlweather's Cantata of Confrontation",
"type": "Buff",
"mpCost": 20,
},
{"id": "6017", "name": "Ur-Kel's Aria of Annoyance", "type": "Buff", "mpCost": 30},
{"id": "6018", "name": "Dirge of Dreadfulness", "type": "Buff", "mpCost": 9},
{
"id": "6020",
"name": "The Ballad of Richie Thingfinder",
"type": "Buff",
"mpCost": 50,
},
{
"id": "6021",
"name": "Benetton's Medley of Diversity",
"type": "Buff",
"mpCost": 50,
},
{"id": "6022", "name": "Elron's Explosive Etude", "type": "Buff", "mpCost": 50},
{"id": "6023", "name": "Chorale of Companionship", "type": "Buff", "mpCost": 50},
{"id": "6024", "name": "Prelude of Precision", "type": "Buff", "mpCost": 50},
{
"id": "7001",
"name": "Give In To Your Vampiric Urges",
"type": "Combat",
"mpCost": 0,
},
{"id": "7002", "name": "Shake Hands", "type": "Combat", "mpCost": 0},
{"id": "7003", "name": "Hot Breath", "type": "Combat", "mpCost": 5},
{"id": "7004", "name": "Cold Breath", "type": "Combat", "mpCost": 5},
{"id": "7005", "name": "Spooky Breath", "type": "Combat", "mpCost": 5},
{"id": "7006", "name": "Stinky Breath", "type": "Combat", "mpCost": 5},
{"id": "7007", "name": "Sleazy Breath", "type": "Combat", "mpCost": 5},
{"id": "7008", "name": "Moxious Maneuver", "type": "Combat"},
{"id": "7009", "name": "Magic Missile", "type": "Combat", "mpCost": 2},
{"id": "7010", "name": "Fire Red Bottle-Rocket", "type": "Combat", "mpCost": 5},
{"id": "7011", "name": "Fire Blue Bottle-Rocket", "type": "Combat", "mpCost": 5},
{"id": "7012", "name": "Fire Orange Bottle-Rocket", "type": "Combat", "mpCost": 5},
{"id": "7013", "name": "Fire Purple Bottle-Rocket", "type": "Combat", "mpCost": 5},
{"id": "7014", "name": "Fire Black Bottle-Rocket", "type": "Combat", "mpCost": 5},
{"id": "7015", "name": "Creepy Grin", "type": "Combat", "mpCost": 30},
{"id": "7016", "name": "Start Trash Fire", "type": "Combat", "mpCost": 100},
{
"id": "7017",
"name": "Overload Discarded Refrigerator",
"type": "Combat",
"mpCost": 100,
},
{"id": "7018", "name": "Trashquake", "type": "Combat", "mpCost": 100},
{"id": "7019", "name": "Zombo's Visage", "type": "Combat", "mpCost": 100},
{"id": "7020", "name": "Hypnotize Hobo", "type": "Combat", "mpCost": 100},
{"id": "7021", "name": "Ask Richard for a Bandage", "type": "Combat"},
{"id": "7022", "name": "Ask Richard for a Grenade", "type": "Combat"},
{"id": "7023", "name": "Ask Richard to Rough the Hobo Up a Bit", "type": "Combat"},
{"id": "7024", "name": "Summon Mayfly Swarm", "type": "Combat", "mpCost": 0},
{"id": "7025", "name": "Get a You-Eye View", "type": "Combat", "mpCost": 30},
{"id": "7038", "name": "Vicious Talon Slash", "type": "Combat", "mpCost": 5},
{
"id": "7039",
"name": "All-You-Can-Beat Wing Buffet",
"type": "Combat",
"mpCost": 10,
},
{"id": "7040", "name": "Tunnel Upwards", "type": "Combat", "mpCost": 0},
{"id": "7041", "name": "Tunnel Downwards", "type": "Combat", "mpCost": 0},
{"id": "7042", "name": "Rise From Your Ashes", "type": "Combat", "mpCost": 20},
{"id": "7043", "name": "Antarctic Flap", "type": "Combat", "mpCost": 10},
{"id": "7044", "name": "The Statue Treatment", "type": "Combat", "mpCost": 20},
{"id": "7045", "name": "Feast on Carrion", "type": "Combat", "mpCost": 20},
{
"id": "7046",
"name": 'Give Your Opponent "The Bird"',
"type": "Combat",
"mpCost": 20,
},
{"id": "7047", "name": "Ask the hobo for a drink", "type": "Combat", "mpCost": 0},
{
"id": "7048",
"name": "Ask the hobo for something to eat",
"type": "Combat",
"mpCost": 0,
},
{
"id": "7049",
"name": "Ask the hobo for some violence",
"type": "Combat",
"mpCost": 0,
},
{
"id": "7050",
"name": "Ask the hobo to tell you a joke",
"type": "Combat",
"mpCost": 0,
},
{
"id": "7051",
"name": "Ask the hobo to dance for you",
"type": "Combat",
"mpCost": 0,
},
{"id": "7052", "name": "Summon hobo underling", "type": "Combat", "mpCost": 0},
{"id": "7053", "name": "Rouse Sapling", "type": "Combat", "mpCost": 15},
{"id": "7054", "name": "Spray Sap", "type": "Combat", "mpCost": 15},
{"id": "7055", "name": "Put Down Roots", "type": "Combat", "mpCost": 15},
{"id": "7056", "name": "Fire off a Roman Candle", "type": "Combat", "mpCost": 10},
{"id": "7061", "name": "Spring Raindrop Attack", "type": "Combat", "mpCost": 0},
{"id": "7062", "name": "Summer Siesta", "type": "Combat", "mpCost": 10},
{"id": "7063", "name": "Falling Leaf Whirlwind", "type": "Combat", "mpCost": 10},
{"id": "7064", "name": "Winter's Bite Technique", "type": "Combat", "mpCost": 10},
{"id": "7065", "name": "The 17 Cuts", "type": "Combat", "mpCost": 10},
{
"id": "8000",
"name": "Summon Snowcones",
"type": "Mystical Bookshelf",
"mpCost": 5,
},
{"id": "8100", "name": "Summon Candy Heart", "type": "Mystical Bookshelf"},
{"id": "8101", "name": "Summon Party Favor", "type": "Mystical Bookshelf"},
{
"id": "8200",
"name": "Summon Hilarious Objects",
"type": "Mystical Bookshelf",
"mpCost": 5,
},
{
"id": "8201",
"name": 'Summon "Tasteful" Gifts',
"type": "Mystical Bookshelf",
"mpCost": 5,
},
]
| skills = [{'id': '0001', 'name': 'Liver of Steel', 'type': 'Passive', 'isPermable': False, 'effects': {'maximumInebriety': '+5'}}, {'id': '0002', 'name': 'Chronic Indigestion', 'type': 'Combat', 'mpCost': 5}, {'id': '0003', 'name': 'The Smile of Mr. A.', 'type': 'Buff', 'mpCost': 5, 'isPermable': False}, {'id': '0004', 'name': 'Arse Shoot', 'type': 'Buff', 'mpCost': 5, 'isPermable': False}, {'id': '0005', 'name': 'Stomach of Steel', 'type': 'Passive', 'isPermable': False, 'effects': {'maximumFullness': '+5'}}, {'id': '0006', 'name': 'Spleen of Steel', 'type': 'Passive', 'isPermable': False, 'effects': {'maximumSpleen': '+5'}}, {'id': '0010', 'name': 'Powers of Observatiogn', 'type': 'Passive', 'effects': {'itemDrop': '+10%'}}, {'id': '0011', 'name': 'Gnefarious Pickpocketing', 'type': 'Passive', 'effects': {'meatDrop': '+10%'}}, {'id': '0012', 'name': 'Torso Awaregness', 'type': 'Passive'}, {'id': '0013', 'name': 'Gnomish Hardigness', 'type': 'Passive', 'effects': {'maximumHP': '+5%'}}, {'id': '0014', 'name': 'Cosmic Ugnderstanding', 'type': 'Passive', 'effects': {'maximumMP': '+5%'}}, {'id': '0015', 'name': 'CLEESH', 'type': 'Combat', 'mpCost': 10}, {'id': '0019', 'name': 'Transcendent Olfaction', 'type': 'Combat', 'mpCost': 40, 'isAutomaticallyPermed': True}, {'id': '0020', 'name': 'Really Expensive Jewelrycrafting', 'type': 'Passive', 'isPermable': False}, {'id': '0021', 'name': 'Lust', 'type': 'Passive', 'isPermable': False, 'effects': {'combatInitiative': '+50%', 'spellDamage': '-5', 'meleeDamage': '-5'}}, {'id': '0022', 'name': 'Gluttony', 'type': 'Passive', 'isPermable': False, 'effects': {'strengthensFood': True, 'statsPerFight': '-2'}}, {'id': '0023', 'name': 'Greed', 'type': 'Passive', 'isPermable': False, 'effects': {'meatDrop': '+50%', 'itemDrop': '-15%'}}, {'id': '0024', 'name': 'Sloth', 'type': 'Passive', 'isPermable': False, 'effects': {'damageReduction': '+8', 'combatInitiative': '-25%'}}, {'id': '0025', 'name': 'Wrath', 'type': 'Passive', 'isPermable': False, 'effects': {'spellDamage': '+10', 'meleeDamage': '+10', 'damageReduction': '-4'}}, {'id': '0026', 'name': 'Envy', 'type': 'Passive', 'isPermable': False, 'effects': {'itemDrop': '+30%', 'meatDrop': '-25%'}}, {'id': '0027', 'name': 'Pride', 'type': 'Passive', 'isPermable': False, 'effects': {'statsPerFight': '+4', 'weakensFood': True}}, {'id': '0028', 'name': 'Awesome Balls of Fire', 'type': 'Combat', 'mpCost': 120}, {'id': '0029', 'name': 'Conjure Relaxing Campfire', 'type': 'Combat', 'mpCost': 30}, {'id': '0030', 'name': 'Snowclone', 'type': 'Combat', 'mpCost': 120}, {'id': '0031', 'name': 'Maximum Chill', 'type': 'Combat', 'mpCost': 30}, {'id': '0032', 'name': 'Eggsplosion', 'type': 'Combat', 'mpCost': 120}, {'id': '0033', 'name': 'Mudbath', 'type': 'Combat', 'mpCost': 30}, {'id': '0036', 'name': 'Grease Lightning', 'type': 'Combat', 'mpCost': 120}, {'id': '0037', 'name': 'Inappropriate Backrub', 'type': 'Combat', 'mpCost': 30}, {'id': '0038', 'name': 'Natural Born Scrabbler', 'type': 'Passive', 'effects': {'itemDrop': '+5%'}}, {'id': '0039', 'name': 'Thrift and Grift', 'type': 'Passive', 'effects': {'meatDrop': '+10%'}}, {'id': '0040', 'name': 'Abs of Tin', 'type': 'Passive', 'effects': {'maximumHP': '+10%'}}, {'id': '0041', 'name': 'Marginally Insane', 'type': 'Passive', 'effects': {'maximumMP': '+10%'}}, {'id': '0042', 'name': 'Raise Backup Dancer', 'type': 'Combat', 'mpCost': 120}, {'id': '0043', 'name': 'Creepy Lullaby', 'type': 'Combat', 'mpCost': 30}, {'id': '0044', 'name': 'Rainbow Gravitation', 'type': 'Noncombat', 'mpCost': 30}, {'id': '1000', 'name': 'Seal Clubbing Frenzy', 'type': 'Noncombat', 'mpCost': 1}, {'id': '1003', 'name': 'Thrust-Smack', 'type': 'Combat', 'mpCost': 3}, {'id': '1004', 'name': 'Lunge-Smack', 'type': 'Combat', 'mpCost': 5}, {'id': '1005', 'name': 'Lunging Thrust-Smack', 'type': 'Combat', 'mpCost': 8}, {'id': '1006', 'name': 'Super-Advanced Meatsmithing', 'type': 'Passive'}, {'id': '1007', 'name': 'Tongue of the Otter', 'type': 'Noncombat', 'mpCost': 7}, {'id': '1008', 'name': 'Hide of the Otter', 'type': 'Passive'}, {'id': '1009', 'name': 'Claws of the Otter', 'type': 'Passive'}, {'id': '1010', 'name': 'Tongue of the Walrus', 'type': 'Noncombat', 'mpCost': 10}, {'id': '1011', 'name': 'Hide of the Walrus', 'type': 'Passive'}, {'id': '1012', 'name': 'Claws of the Walrus', 'type': 'Passive'}, {'id': '1014', 'name': 'Eye of the Stoat', 'type': 'Passive'}, {'id': '1015', 'name': 'Rage of the Reindeer', 'type': 'Noncombat', 'mpCost': 10}, {'id': '1016', 'name': 'Pulverize', 'type': 'Passive'}, {'id': '1017', 'name': 'Double-Fisted Skull Smashing', 'type': 'Passive'}, {'id': '1018', 'name': 'Northern Exposure', 'type': 'Passive'}, {'id': '1019', 'name': 'Musk of the Moose', 'type': 'Noncombat', 'mpCost': 10}, {'id': '1020', 'name': 'Snarl of the Timberwolf', 'type': 'Noncombat', 'mpCost': 10}, {'id': '2000', 'name': 'Patience of the Tortoise', 'type': 'Noncombat', 'mpCost': 1}, {'id': '2003', 'name': 'Headbutt', 'type': 'Combat', 'mpCost': 3}, {'id': '2004', 'name': 'Skin of the Leatherback', 'type': 'Passive'}, {'id': '2005', 'name': 'Shieldbutt', 'type': 'Combat', 'mpCost': 5}, {'id': '2006', 'name': 'Armorcraftiness', 'type': 'Passive'}, {'id': '2007', 'name': 'Ghostly Shell', 'type': 'Buff', 'mpCost': 6}, {'id': '2008', 'name': 'Reptilian Fortitude', 'type': 'Buff', 'mpCost': 10}, {'id': '2009', 'name': 'Empathy of the Newt', 'type': 'Buff', 'mpCost': 15}, {'id': '2010', 'name': 'Tenacity of the Snapper', 'type': 'Buff', 'mpCost': 8}, {'id': '2011', 'name': 'Wisdom of the Elder Tortoises', 'type': 'Passive'}, {'id': '2012', 'name': 'Astral Shell', 'type': 'Buff', 'mpCost': 10}, {'id': '2014', 'name': 'Amphibian Sympathy', 'type': 'Passive'}, {'id': '2015', 'name': 'Kneebutt', 'type': 'Combat', 'mpCost': 4}, {'id': '2016', 'name': 'Cold-Blooded Fearlessness', 'type': 'Passive'}, {'id': '2020', 'name': 'Hero of the Half-Shell', 'type': 'Passive'}, {'id': '2021', 'name': 'Tao of the Terrapin', 'type': 'Passive'}, {'id': '2022', 'name': 'Spectral Snapper', 'type': 'Combat', 'mpCost': 20}, {'id': '2103', 'name': 'Head + Knee Combo', 'type': 'Combat', 'mpCost': 8}, {'id': '2105', 'name': 'Head + Shield Combo', 'type': 'Combat', 'mpCost': 9}, {'id': '2106', 'name': 'Knee + Shield Combo', 'type': 'Combat', 'mpCost': 10}, {'id': '2107', 'name': 'Head + Knee + Shield Combo', 'type': 'Combat', 'mpCost': 13}, {'id': '3000', 'name': 'Manicotti Meditation', 'type': 'Noncombat', 'mpCost': 1}, {'id': '3003', 'name': 'Ravioli Shurikens', 'type': 'Combat', 'mpCost': 4}, {'id': '3004', 'name': 'Entangling Noodles', 'type': 'Combat', 'mpCost': 3}, {'id': '3005', 'name': 'Cannelloni Cannon', 'type': 'Combat', 'mpCost': 7}, {'id': '3006', 'name': 'Pastamastery', 'type': 'Noncombat', 'mpCost': 10}, {'id': '3007', 'name': 'Stuffed Mortar Shell', 'type': 'Combat', 'mpCost': 19}, {'id': '3008', 'name': 'Weapon of the Pastalord', 'type': 'Combat', 'mpCost': 35}, {'id': '3009', 'name': 'Lasagna Bandages', 'type': 'Combat / Noncombat', 'mpCost': 6}, {'id': '3010', 'name': 'Leash of Linguini', 'type': 'Noncombat', 'mpCost': 12}, {'id': '3011', 'name': 'Spirit of Rigatoni', 'type': 'Passive'}, {'id': '3012', 'name': 'Cannelloni Cocoon', 'type': 'Noncombat', 'mpCost': 20}, {'id': '3014', 'name': 'Spirit of Ravioli', 'type': 'Passive'}, {'id': '3015', 'name': 'Springy Fusilli', 'type': 'Noncombat', 'mpCost': 10}, {'id': '3016', 'name': 'Tolerance of the Kitchen', 'type': 'Passive'}, {'id': '3017', 'name': 'Flavour of Magic', 'type': 'Noncombat', 'mpCost': 10}, {'id': '3018', 'name': 'Transcendental Noodlecraft', 'type': 'Passive'}, {'id': '3019', 'name': 'Fearful Fettucini', 'type': 'Combat', 'mpCost': 35}, {'id': '3020', 'name': 'Spaghetti Spear', 'type': 'Combat', 'mpCost': 1}, {'id': '3101', 'name': 'Spirit of Cayenne', 'type': 'Noncombat', 'mpCost': 10}, {'id': '3102', 'name': 'Spirit of Peppermint', 'type': 'Noncombat', 'mpCost': 10}, {'id': '3103', 'name': 'Spirit of Garlic', 'type': 'Noncombat', 'mpCost': 10}, {'id': '3104', 'name': 'Spirit of Wormwood', 'type': 'Noncombat', 'mpCost': 10}, {'id': '3105', 'name': 'Spirit of Bacon Grease', 'type': 'Noncombat', 'mpCost': 10}, {'id': '4000', 'name': 'Sauce Contemplation', 'type': 'Noncombat', 'mpCost': 1}, {'id': '4003', 'name': 'Stream of Sauce', 'type': 'Combat', 'mpCost': 3}, {'id': '4004', 'name': 'Expert Panhandling', 'type': 'Passive'}, {'id': '4005', 'name': 'Saucestorm', 'type': 'Combat', 'mpCost': 12}, {'id': '4006', 'name': 'Advanced Saucecrafting', 'type': 'Noncombat', 'mpCost': 10}, {'id': '4007', 'name': 'Elemental Saucesphere', 'type': 'Buff', 'mpCost': 10}, {'id': '4008', 'name': 'Jalapeno Saucesphere', 'type': 'Buff', 'mpCost': 5}, {'id': '4009', 'name': 'Wave of Sauce', 'type': 'Combat', 'mpCost': 23}, {'id': '4010', 'name': 'Intrinsic Spiciness', 'type': 'Passive'}, {'id': '4011', 'name': 'Jabanero Saucesphere', 'type': 'Buff', 'mpCost': 10}, {'id': '4012', 'name': 'Saucegeyser', 'type': 'Combat', 'mpCost': 40}, {'id': '4014', 'name': 'Saucy Salve', 'type': 'Combat', 'mpCost': 4}, {'id': '4015', 'name': 'Impetuous Sauciness', 'type': 'Passive'}, {'id': '4016', 'name': 'Diminished Gag Reflex', 'type': 'Passive'}, {'id': '4017', 'name': 'Immaculate Seasoning', 'type': 'Passive'}, {'id': '4018', 'name': 'The Way of Sauce', 'type': 'Passive'}, {'id': '4019', 'name': 'Scarysauce', 'type': 'Buff', 'mpCost': 10}, {'id': '4020', 'name': 'Salsaball', 'type': 'Combat', 'mpCost': 1}, {'id': '5000', 'name': 'Disco Aerobics', 'type': 'Noncombat', 'mpCost': 1}, {'id': '5003', 'name': 'Disco Eye-Poke', 'type': 'Combat', 'mpCost': 3}, {'id': '5004', 'name': 'Nimble Fingers', 'type': 'Passive'}, {'id': '5005', 'name': 'Disco Dance of Doom', 'type': 'Combat', 'mpCost': 5}, {'id': '5006', 'name': 'Mad Looting Skillz', 'type': 'Passive'}, {'id': '5007', 'name': 'Disco Nap', 'type': 'Noncombat', 'mpCost': 8}, {'id': '5008', 'name': 'Disco Dance II: Electric Boogaloo', 'type': 'Combat', 'mpCost': 7}, {'id': '5009', 'name': 'Disco Fever', 'type': 'Passive'}, {'id': '5010', 'name': 'Overdeveloped Sense of Self Preservation', 'type': 'Passive'}, {'id': '5011', 'name': 'Disco Power Nap', 'type': 'Noncombat', 'mpCost': 12}, {'id': '5012', 'name': 'Disco Face Stab', 'type': 'Combat', 'mpCost': 10}, {'id': '5014', 'name': 'Advanced Cocktailcrafting', 'type': 'Noncombat', 'mpCost': 10}, {'id': '5015', 'name': 'Ambidextrous Funkslinging', 'type': 'Passive'}, {'id': '5016', 'name': 'Heart of Polyester', 'type': 'Passive'}, {'id': '5017', 'name': 'Smooth Movement', 'type': 'Noncombat', 'mpCost': 10}, {'id': '5018', 'name': 'Superhuman Cocktailcrafting', 'type': 'Passive'}, {'id': '5019', 'name': 'Tango of Terror', 'type': 'Combat', 'mpCost': 8}, {'id': '6000', 'name': 'Moxie of the Mariachi', 'type': 'Noncombat', 'mpCost': 1}, {'id': '6003', 'name': "Aloysius' Antiphon of Aptitude", 'type': 'Buff', 'mpCost': 40}, {'id': '6004', 'name': 'The Moxious Madrigal', 'type': 'Buff', 'mpCost': 2}, {'id': '6005', 'name': "Cletus's Canticle of Celerity", 'type': 'Buff', 'mpCost': 4}, {'id': '6006', 'name': 'The Polka of Plenty', 'type': 'Buff', 'mpCost': 7}, {'id': '6007', 'name': 'The Magical Mojomuscular Melody', 'type': 'Buff', 'mpCost': 3}, {'id': '6008', 'name': 'The Power Ballad of the Arrowsmith', 'type': 'Buff', 'mpCost': 5}, {'id': '6009', 'name': "Brawnee's Anthem of Absorption", 'type': 'Buff', 'mpCost': 13}, {'id': '6010', 'name': "Fat Leon's Phat Loot Lyric", 'type': 'Buff', 'mpCost': 11}, {'id': '6011', 'name': 'The Psalm of Pointiness', 'type': 'Buff', 'mpCost': 15}, {'id': '6012', 'name': "Jackasses' Symphony of Destruction", 'type': 'Buff', 'mpCost': 9}, {'id': '6013', 'name': "Stevedave's Shanty of Superiority", 'type': 'Buff', 'mpCost': 30}, {'id': '6014', 'name': 'The Ode to Booze', 'type': 'Buff', 'mpCost': 50}, {'id': '6015', 'name': 'The Sonata of Sneakiness', 'type': 'Buff', 'mpCost': 20}, {'id': '6016', 'name': "Carlweather's Cantata of Confrontation", 'type': 'Buff', 'mpCost': 20}, {'id': '6017', 'name': "Ur-Kel's Aria of Annoyance", 'type': 'Buff', 'mpCost': 30}, {'id': '6018', 'name': 'Dirge of Dreadfulness', 'type': 'Buff', 'mpCost': 9}, {'id': '6020', 'name': 'The Ballad of Richie Thingfinder', 'type': 'Buff', 'mpCost': 50}, {'id': '6021', 'name': "Benetton's Medley of Diversity", 'type': 'Buff', 'mpCost': 50}, {'id': '6022', 'name': "Elron's Explosive Etude", 'type': 'Buff', 'mpCost': 50}, {'id': '6023', 'name': 'Chorale of Companionship', 'type': 'Buff', 'mpCost': 50}, {'id': '6024', 'name': 'Prelude of Precision', 'type': 'Buff', 'mpCost': 50}, {'id': '7001', 'name': 'Give In To Your Vampiric Urges', 'type': 'Combat', 'mpCost': 0}, {'id': '7002', 'name': 'Shake Hands', 'type': 'Combat', 'mpCost': 0}, {'id': '7003', 'name': 'Hot Breath', 'type': 'Combat', 'mpCost': 5}, {'id': '7004', 'name': 'Cold Breath', 'type': 'Combat', 'mpCost': 5}, {'id': '7005', 'name': 'Spooky Breath', 'type': 'Combat', 'mpCost': 5}, {'id': '7006', 'name': 'Stinky Breath', 'type': 'Combat', 'mpCost': 5}, {'id': '7007', 'name': 'Sleazy Breath', 'type': 'Combat', 'mpCost': 5}, {'id': '7008', 'name': 'Moxious Maneuver', 'type': 'Combat'}, {'id': '7009', 'name': 'Magic Missile', 'type': 'Combat', 'mpCost': 2}, {'id': '7010', 'name': 'Fire Red Bottle-Rocket', 'type': 'Combat', 'mpCost': 5}, {'id': '7011', 'name': 'Fire Blue Bottle-Rocket', 'type': 'Combat', 'mpCost': 5}, {'id': '7012', 'name': 'Fire Orange Bottle-Rocket', 'type': 'Combat', 'mpCost': 5}, {'id': '7013', 'name': 'Fire Purple Bottle-Rocket', 'type': 'Combat', 'mpCost': 5}, {'id': '7014', 'name': 'Fire Black Bottle-Rocket', 'type': 'Combat', 'mpCost': 5}, {'id': '7015', 'name': 'Creepy Grin', 'type': 'Combat', 'mpCost': 30}, {'id': '7016', 'name': 'Start Trash Fire', 'type': 'Combat', 'mpCost': 100}, {'id': '7017', 'name': 'Overload Discarded Refrigerator', 'type': 'Combat', 'mpCost': 100}, {'id': '7018', 'name': 'Trashquake', 'type': 'Combat', 'mpCost': 100}, {'id': '7019', 'name': "Zombo's Visage", 'type': 'Combat', 'mpCost': 100}, {'id': '7020', 'name': 'Hypnotize Hobo', 'type': 'Combat', 'mpCost': 100}, {'id': '7021', 'name': 'Ask Richard for a Bandage', 'type': 'Combat'}, {'id': '7022', 'name': 'Ask Richard for a Grenade', 'type': 'Combat'}, {'id': '7023', 'name': 'Ask Richard to Rough the Hobo Up a Bit', 'type': 'Combat'}, {'id': '7024', 'name': 'Summon Mayfly Swarm', 'type': 'Combat', 'mpCost': 0}, {'id': '7025', 'name': 'Get a You-Eye View', 'type': 'Combat', 'mpCost': 30}, {'id': '7038', 'name': 'Vicious Talon Slash', 'type': 'Combat', 'mpCost': 5}, {'id': '7039', 'name': 'All-You-Can-Beat Wing Buffet', 'type': 'Combat', 'mpCost': 10}, {'id': '7040', 'name': 'Tunnel Upwards', 'type': 'Combat', 'mpCost': 0}, {'id': '7041', 'name': 'Tunnel Downwards', 'type': 'Combat', 'mpCost': 0}, {'id': '7042', 'name': 'Rise From Your Ashes', 'type': 'Combat', 'mpCost': 20}, {'id': '7043', 'name': 'Antarctic Flap', 'type': 'Combat', 'mpCost': 10}, {'id': '7044', 'name': 'The Statue Treatment', 'type': 'Combat', 'mpCost': 20}, {'id': '7045', 'name': 'Feast on Carrion', 'type': 'Combat', 'mpCost': 20}, {'id': '7046', 'name': 'Give Your Opponent "The Bird"', 'type': 'Combat', 'mpCost': 20}, {'id': '7047', 'name': 'Ask the hobo for a drink', 'type': 'Combat', 'mpCost': 0}, {'id': '7048', 'name': 'Ask the hobo for something to eat', 'type': 'Combat', 'mpCost': 0}, {'id': '7049', 'name': 'Ask the hobo for some violence', 'type': 'Combat', 'mpCost': 0}, {'id': '7050', 'name': 'Ask the hobo to tell you a joke', 'type': 'Combat', 'mpCost': 0}, {'id': '7051', 'name': 'Ask the hobo to dance for you', 'type': 'Combat', 'mpCost': 0}, {'id': '7052', 'name': 'Summon hobo underling', 'type': 'Combat', 'mpCost': 0}, {'id': '7053', 'name': 'Rouse Sapling', 'type': 'Combat', 'mpCost': 15}, {'id': '7054', 'name': 'Spray Sap', 'type': 'Combat', 'mpCost': 15}, {'id': '7055', 'name': 'Put Down Roots', 'type': 'Combat', 'mpCost': 15}, {'id': '7056', 'name': 'Fire off a Roman Candle', 'type': 'Combat', 'mpCost': 10}, {'id': '7061', 'name': 'Spring Raindrop Attack', 'type': 'Combat', 'mpCost': 0}, {'id': '7062', 'name': 'Summer Siesta', 'type': 'Combat', 'mpCost': 10}, {'id': '7063', 'name': 'Falling Leaf Whirlwind', 'type': 'Combat', 'mpCost': 10}, {'id': '7064', 'name': "Winter's Bite Technique", 'type': 'Combat', 'mpCost': 10}, {'id': '7065', 'name': 'The 17 Cuts', 'type': 'Combat', 'mpCost': 10}, {'id': '8000', 'name': 'Summon Snowcones', 'type': 'Mystical Bookshelf', 'mpCost': 5}, {'id': '8100', 'name': 'Summon Candy Heart', 'type': 'Mystical Bookshelf'}, {'id': '8101', 'name': 'Summon Party Favor', 'type': 'Mystical Bookshelf'}, {'id': '8200', 'name': 'Summon Hilarious Objects', 'type': 'Mystical Bookshelf', 'mpCost': 5}, {'id': '8201', 'name': 'Summon "Tasteful" Gifts', 'type': 'Mystical Bookshelf', 'mpCost': 5}] |
load("@bazel_gazelle//:deps.bzl", "go_repository")
def go_repositories():
go_repository(
name = "co_honnef_go_tools",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "honnef.co/go/tools",
sum = "h1:MNh1AVMyVX23VUHE2O27jm6lNj3vjO5DexS4A1xvnzk=",
version = "v0.2.2",
)
go_repository(
name = "com_github_alecthomas_template",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/alecthomas/template",
sum = "h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM=",
version = "v0.0.0-20190718012654-fb15b899a751",
)
go_repository(
name = "com_github_alecthomas_units",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/alecthomas/units",
sum = "h1:UQZhZ2O0vMHr2cI+DC1Mbh0TJxzA3RcLoMsFw+aXw7E=",
version = "v0.0.0-20190924025748-f65c72e2690d",
)
go_repository(
name = "com_github_andreasbriese_bbloom",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/AndreasBriese/bbloom",
sum = "h1:cTp8I5+VIoKjsnZuH8vjyaysT/ses3EvZeaV/1UkF2M=",
version = "v0.0.0-20190825152654-46b345b51c96",
)
go_repository(
name = "com_github_antihax_optional",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/antihax/optional",
sum = "h1:xK2lYat7ZLaVVcIuj82J8kIro4V6kDe0AUDFboUCwcg=",
version = "v1.0.0",
)
go_repository(
name = "com_github_armon_consul_api",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/armon/consul-api",
sum = "h1:G1bPvciwNyF7IUmKXNt9Ak3m6u9DE1rF+RmtIkBpVdA=",
version = "v0.0.0-20180202201655-eb2c6b5be1b6",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2",
sum = "h1:1XIXAfxsEmbhbj5ry3D3vX+6ZcUYvIqSm4CWWEuGZCA=",
version = "v1.13.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_aws_protocol_eventstream",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream",
sum = "h1:scBthy70MB3m4LCMFaBcmYCyR2XWOz6MxSfdSu/+fQo=",
version = "v1.2.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_config",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/config",
sum = "h1:yLv8bfNoT4r+UvUKQKqRtdnvuWGMK5a82l4ru9Jvnuo=",
version = "v1.13.1",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_credentials",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/credentials",
sum = "h1:8Ow0WcyDesGNL0No11jcgb1JAtE+WtubqXjgxau+S0o=",
version = "v1.8.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_feature_ec2_imds",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/feature/ec2/imds",
sum = "h1:NITDuUZO34mqtOwFWZiXo7yAHj7kf+XPE+EiKuCBNUI=",
version = "v1.10.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_feature_s3_manager",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/feature/s3/manager",
sum = "h1:oUCLhAKNaXyTqdJyw+KEjDVVBs1V5mCy8YDLMi08LL8=",
version = "v1.9.1",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_internal_configsources",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/internal/configsources",
sum = "h1:CRiQJ4E2RhfDdqbie1ZYDo8QtIo75Mk7oTdJSfwJTMQ=",
version = "v1.1.4",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_internal_endpoints_v2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/internal/endpoints/v2",
sum = "h1:3ADoioDMOtF4uiK59vCpplpCwugEU+v4ZFD29jDL3RQ=",
version = "v2.2.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_internal_ini",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/internal/ini",
sum = "h1:ixotxbfTCFpqbuwFv/RcZwyzhkxPSYDYEMcj4niB5Uk=",
version = "v1.3.5",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_service_internal_accept_encoding",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding",
sum = "h1:F1diQIOkNn8jcez4173r+PLPdkWK7chy74r3fKpDrLI=",
version = "v1.7.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_service_internal_presigned_url",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/service/internal/presigned-url",
sum = "h1:4QAOB3KrvI1ApJK14sliGr3Ie2pjyvNypn/lfzDHfUw=",
version = "v1.7.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_service_internal_s3shared",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/service/internal/s3shared",
sum = "h1:XAe+PDnaBELHr25qaJKfB415V4CKFWE8H+prUreql8k=",
version = "v1.11.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_service_s3",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/service/s3",
sum = "h1:zAU2P99CLTz8kUGl+IptU2ycAXuMaLAvgIv+UH4U8pY=",
version = "v1.24.1",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_service_sso",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/service/sso",
sum = "h1:1qLJeQGBmNQW3mBNzK2CFmrQNmoXWrscPqsrAaU1aTA=",
version = "v1.9.0",
)
go_repository(
name = "com_github_aws_aws_sdk_go_v2_service_sts",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/aws-sdk-go-v2/service/sts",
sum = "h1:ksiDXhvNYg0D2/UFkLejsaz3LqpW5yjNQ8Nx9Sn2c0E=",
version = "v1.14.0",
)
go_repository(
name = "com_github_aws_smithy_go",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/aws/smithy-go",
sum = "h1:gsoZQMNHnX+PaghNw4ynPsyGP7aUCqx5sY2dlPQsZ0w=",
version = "v1.10.0",
)
go_repository(
name = "com_github_benbjohnson_clock",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/benbjohnson/clock",
sum = "h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8=",
version = "v1.1.0",
)
go_repository(
name = "com_github_beorn7_perks",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/beorn7/perks",
sum = "h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=",
version = "v1.0.1",
)
go_repository(
name = "com_github_bkaradzic_go_lz4",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/bkaradzic/go-lz4",
sum = "h1:RXc4wYsyz985CkXXeX04y4VnZFGG8Rd43pRaHsOXAKk=",
version = "v1.0.0",
)
go_repository(
name = "com_github_burntsushi_toml",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/BurntSushi/toml",
sum = "h1:dtDWrepsVPfW9H/4y7dDgFc2MBUSeJhlaDtK13CxFlU=",
version = "v1.0.0",
)
go_repository(
name = "com_github_burntsushi_xgb",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/BurntSushi/xgb",
sum = "h1:1BDTz0u9nC3//pOCMdNH+CiXJVYJh5UQNCOBG7jbELc=",
version = "v0.0.0-20160522181843-27f122750802",
)
go_repository(
name = "com_github_census_instrumentation_opencensus_proto",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/census-instrumentation/opencensus-proto",
sum = "h1:glEXhBS5PSLLv4IXzLA5yPRVX4bilULVyxxbrfOtDAk=",
version = "v0.2.1",
)
go_repository(
name = "com_github_cespare_xxhash",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/cespare/xxhash",
sum = "h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko=",
version = "v1.1.0",
)
go_repository(
name = "com_github_cespare_xxhash_v2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/cespare/xxhash/v2",
sum = "h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE=",
version = "v2.1.2",
)
go_repository(
name = "com_github_chzyer_logex",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/chzyer/logex",
sum = "h1:Swpa1K6QvQznwJRcfTfQJmTE72DqScAa40E+fbHEXEE=",
version = "v1.1.10",
)
go_repository(
name = "com_github_chzyer_readline",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/chzyer/readline",
sum = "h1:fY5BOSpyZCqRo5OhCuC+XN+r/bBCmeuuJtjz+bCNIf8=",
version = "v0.0.0-20180603132655-2972be24d48e",
)
go_repository(
name = "com_github_chzyer_test",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/chzyer/test",
sum = "h1:q763qf9huN11kDQavWsoZXJNW3xEE4JJyHa5Q25/sd8=",
version = "v0.0.0-20180213035817-a1ea475d72b1",
)
go_repository(
name = "com_github_clickhouse_clickhouse_go",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/ClickHouse/clickhouse-go",
sum = "h1:cKjXeYLNWVJIx2J1K6H2CqyRmfwVJVY1OV1coaaFcI0=",
version = "v1.5.4",
)
go_repository(
name = "com_github_client9_misspell",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/client9/misspell",
sum = "h1:ta993UF76GwbvJcIo3Y68y/M3WxlpEHPWIGDkJYwzJI=",
version = "v0.3.4",
)
go_repository(
name = "com_github_cloudflare_golz4",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/cloudflare/golz4",
sum = "h1:F1EaeKL/ta07PY/k9Os/UFtwERei2/XzGemhpGnBKNg=",
version = "v0.0.0-20150217214814-ef862a3cdc58",
)
go_repository(
name = "com_github_cncf_udpa_go",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/cncf/udpa/go",
sum = "h1:hzAQntlaYRkVSFEfj9OTWlVV1H155FMD8BTKktLv0QI=",
version = "v0.0.0-20210930031921-04548b0d99d4",
)
go_repository(
name = "com_github_cncf_xds_go",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/cncf/xds/go",
sum = "h1:zH8ljVhhq7yC0MIeUL/IviMtY8hx2mK8cN9wEYb8ggw=",
version = "v0.0.0-20211011173535-cb28da3451f1",
)
go_repository(
name = "com_github_coreos_etcd",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/coreos/etcd",
sum = "h1:jFneRYjIvLMLhDLCzuTuU4rSJUjRplcJQ7pD7MnhC04=",
version = "v3.3.10+incompatible",
)
go_repository(
name = "com_github_coreos_go_etcd",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/coreos/go-etcd",
sum = "h1:bXhRBIXoTm9BYHS3gE0TtQuyNZyeEMux2sDi4oo5YOo=",
version = "v2.0.0+incompatible",
)
go_repository(
name = "com_github_coreos_go_semver",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/coreos/go-semver",
sum = "h1:3Jm3tLmsgAYcjC+4Up7hJrFBPr+n7rAqYeSw/SZazuY=",
version = "v0.2.0",
)
go_repository(
name = "com_github_cpuguy83_go_md2man",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/cpuguy83/go-md2man",
sum = "h1:BSKMNlYxDvnunlTymqtgONjNnaRV1sTpcovwwjF22jk=",
version = "v1.0.10",
)
go_repository(
name = "com_github_creack_pty",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/creack/pty",
sum = "h1:uDmaGzcdjhF4i/plgjmEsriH11Y0o7RKapEf/LDaM3w=",
version = "v1.1.9",
)
go_repository(
name = "com_github_davecgh_go_spew",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/davecgh/go-spew",
sum = "h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=",
version = "v1.1.1",
)
go_repository(
name = "com_github_dgraph_io_badger",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/dgraph-io/badger",
sum = "h1:mNw0qs90GVgGGWylh0umH5iag1j6n/PeJtNvL6KY/x8=",
version = "v1.6.2",
)
go_repository(
name = "com_github_dgraph_io_ristretto",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/dgraph-io/ristretto",
sum = "h1:a5WaUrDa0qm0YrAAS1tUykT5El3kt62KNZZeMxQn3po=",
version = "v0.0.2",
)
go_repository(
name = "com_github_dgryski_go_farm",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/dgryski/go-farm",
sum = "h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y=",
version = "v0.0.0-20200201041132-a6ae2369ad13",
)
go_repository(
name = "com_github_dustin_go_humanize",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/dustin/go-humanize",
sum = "h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo=",
version = "v1.0.0",
)
go_repository(
name = "com_github_envoyproxy_go_control_plane",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/envoyproxy/go-control-plane",
sum = "h1:fP+fF0up6oPY49OrjPrhIJ8yQfdIM85NXMLkMg1EXVs=",
version = "v0.9.10-0.20210907150352-cf90f659a021",
)
go_repository(
name = "com_github_envoyproxy_protoc_gen_validate",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/envoyproxy/protoc-gen-validate",
sum = "h1:EQciDnbrYxy13PgWoY8AqoxGiPrpgBZ1R8UNe3ddc+A=",
version = "v0.1.0",
)
go_repository(
name = "com_github_fsnotify_fsnotify",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/fsnotify/fsnotify",
sum = "h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I=",
version = "v1.4.7",
)
go_repository(
name = "com_github_ghodss_yaml",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/ghodss/yaml",
sum = "h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk=",
version = "v1.0.0",
)
go_repository(
name = "com_github_go_gl_glfw",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/go-gl/glfw",
sum = "h1:QbL/5oDUmRBzO9/Z7Seo6zf912W/a6Sr4Eu0G/3Jho0=",
version = "v0.0.0-20190409004039-e6da0acd62b1",
)
go_repository(
name = "com_github_go_gl_glfw_v3_3_glfw",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/go-gl/glfw/v3.3/glfw",
sum = "h1:WtGNWLvXpe6ZudgnXrq0barxBImvnnJoMEhXAzcbM0I=",
version = "v0.0.0-20200222043503-6f7a984d4dc4",
)
go_repository(
name = "com_github_go_kit_kit",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/go-kit/kit",
sum = "h1:wDJmvq38kDhkVxi50ni9ykkdUr1PKgqKOoi01fa0Mdk=",
version = "v0.9.0",
)
go_repository(
name = "com_github_go_kit_log",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/go-kit/log",
sum = "h1:DGJh0Sm43HbOeYDNnVZFl8BvcYVvjD5bqYJvp0REbwQ=",
version = "v0.1.0",
)
go_repository(
name = "com_github_go_logfmt_logfmt",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/go-logfmt/logfmt",
sum = "h1:TrB8swr/68K7m9CcGut2g3UOihhbcbiMAYiuTXdEih4=",
version = "v0.5.0",
)
go_repository(
name = "com_github_go_sql_driver_mysql",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/go-sql-driver/mysql",
sum = "h1:7LxgVwFb2hIQtMm87NdgAVfXjnt4OePseqT1tKx+opk=",
version = "v1.4.0",
)
go_repository(
name = "com_github_go_stack_stack",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/go-stack/stack",
sum = "h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk=",
version = "v1.8.0",
)
go_repository(
name = "com_github_gogo_protobuf",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/gogo/protobuf",
sum = "h1:72R+M5VuhED/KujmZVcIquuo8mBgX4oVda//DQb3PXo=",
version = "v1.1.1",
)
go_repository(
name = "com_github_golang_glog",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/golang/glog",
sum = "h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58=",
version = "v0.0.0-20160126235308-23def4e6c14b",
)
go_repository(
name = "com_github_golang_groupcache",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/golang/groupcache",
sum = "h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE=",
version = "v0.0.0-20210331224755-41bb18bfe9da",
)
go_repository(
name = "com_github_golang_mock",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/golang/mock",
sum = "h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc=",
version = "v1.6.0",
)
go_repository(
name = "com_github_golang_protobuf",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/golang/protobuf",
sum = "h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw=",
version = "v1.5.2",
)
go_repository(
name = "com_github_golang_snappy",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/golang/snappy",
sum = "h1:fHPg5GQYlCeLIPB9BZqMVR5nR9A+IM5zcgeTdjMYmLA=",
version = "v0.0.3",
)
go_repository(
name = "com_github_google_btree",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/btree",
sum = "h1:0udJVsspx3VBr5FwtLhQQtuAsVc79tTq0ocGIPAU6qo=",
version = "v1.0.0",
)
go_repository(
name = "com_github_google_go_cmp",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/go-cmp",
sum = "h1:81/ik6ipDQS2aGcBfIN5dHDB36BwrStyeAQquSYCV4o=",
version = "v0.5.7",
)
go_repository(
name = "com_github_google_gofuzz",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/gofuzz",
sum = "h1:A8PeW59pxE9IoFRqBp37U+mSNaQoZ46F1f0f863XSXw=",
version = "v1.0.0",
)
go_repository(
name = "com_github_google_martian",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/martian",
sum = "h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no=",
version = "v2.1.0+incompatible",
)
go_repository(
name = "com_github_google_martian_v3",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/martian/v3",
sum = "h1:d8MncMlErDFTwQGBK1xhv026j9kqhvw1Qv9IbWT1VLQ=",
version = "v3.2.1",
)
go_repository(
name = "com_github_google_pprof",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/pprof",
sum = "h1:K6RDEckDVWvDI9JAJYCmNdQXq6neHJOYx3V6jnqNEec=",
version = "v0.0.0-20210720184732-4bb14d4b1be1",
)
go_repository(
name = "com_github_google_renameio",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/renameio",
sum = "h1:GOZbcHa3HfsPKPlmyPyN2KEohoMXOhdMbHrvbpl2QaA=",
version = "v0.1.0",
)
go_repository(
name = "com_github_google_uuid",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/google/uuid",
sum = "h1:EVhdT+1Kseyi1/pUmXKaFxYsDNy9RQYkMWRH68J/W7Y=",
version = "v1.1.2",
)
go_repository(
name = "com_github_googleapis_gax_go_v2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/googleapis/gax-go/v2",
sum = "h1:dp3bWCh+PPO1zjRRiCSczJav13sBvG4UhNyVTa1KqdU=",
version = "v2.1.1",
)
go_repository(
name = "com_github_grpc_ecosystem_grpc_gateway",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/grpc-ecosystem/grpc-gateway",
sum = "h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo=",
version = "v1.16.0",
)
go_repository(
name = "com_github_hashicorp_golang_lru",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/hashicorp/golang-lru",
sum = "h1:0hERBMJE1eitiLkihrMvRVBYAkpHzc/J3QdDN+dAcgU=",
version = "v0.5.1",
)
go_repository(
name = "com_github_hashicorp_hcl",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/hashicorp/hcl",
sum = "h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4=",
version = "v1.0.0",
)
go_repository(
name = "com_github_ianlancetaylor_demangle",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/ianlancetaylor/demangle",
sum = "h1:mV02weKRL81bEnm8A0HT1/CAelMQDBuQIfLw8n+d6xI=",
version = "v0.0.0-20200824232613-28f6c0f3b639",
)
go_repository(
name = "com_github_inconshreveable_mousetrap",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/inconshreveable/mousetrap",
sum = "h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM=",
version = "v1.0.0",
)
go_repository(
name = "com_github_jmespath_go_jmespath",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/jmespath/go-jmespath",
sum = "h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=",
version = "v0.4.0",
)
go_repository(
name = "com_github_jmespath_go_jmespath_internal_testify",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/jmespath/go-jmespath/internal/testify",
sum = "h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=",
version = "v1.5.1",
)
go_repository(
name = "com_github_jmoiron_sqlx",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/jmoiron/sqlx",
sum = "h1:41Ip0zITnmWNR/vHV+S4m+VoUivnWY5E4OJfLZjCJMA=",
version = "v1.2.0",
)
go_repository(
name = "com_github_jpillora_backoff",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/jpillora/backoff",
sum = "h1:uvFg412JmmHBHw7iwprIxkPMI+sGQ4kzOWsMeHnm2EA=",
version = "v1.0.0",
)
go_repository(
name = "com_github_json_iterator_go",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/json-iterator/go",
sum = "h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=",
version = "v1.1.12",
)
go_repository(
name = "com_github_jstemmer_go_junit_report",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/jstemmer/go-junit-report",
sum = "h1:6QPYqodiu3GuPL+7mfx+NwDdp2eTkp9IfEUpgAwUN0o=",
version = "v0.9.1",
)
go_repository(
name = "com_github_julienschmidt_httprouter",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/julienschmidt/httprouter",
sum = "h1:U0609e9tgbseu3rBINet9P48AI/D3oJs4dN7jwJOQ1U=",
version = "v1.3.0",
)
go_repository(
name = "com_github_kisielk_gotool",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/kisielk/gotool",
sum = "h1:AV2c/EiW3KqPNT9ZKl07ehoAGi4C5/01Cfbblndcapg=",
version = "v1.0.0",
)
go_repository(
name = "com_github_konsorten_go_windows_terminal_sequences",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/konsorten/go-windows-terminal-sequences",
sum = "h1:CE8S1cTafDpPvMhIxNJKvHsGVBgn1xWYf1NbHQhywc8=",
version = "v1.0.3",
)
go_repository(
name = "com_github_kr_logfmt",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/kr/logfmt",
sum = "h1:T+h1c/A9Gawja4Y9mFVWj2vyii2bbUNDw3kt9VxK2EY=",
version = "v0.0.0-20140226030751-b84e30acd515",
)
go_repository(
name = "com_github_kr_pretty",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/kr/pretty",
sum = "h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0=",
version = "v0.3.0",
)
go_repository(
name = "com_github_kr_pty",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/kr/pty",
sum = "h1:VkoXIwSboBpnk99O/KFauAEILuNHv5DVFKZMBN/gUgw=",
version = "v1.1.1",
)
go_repository(
name = "com_github_kr_text",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/kr/text",
sum = "h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=",
version = "v0.2.0",
)
go_repository(
name = "com_github_lib_pq",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/lib/pq",
sum = "h1:X5PMW56eZitiTeO7tKzZxFCSpbFZJtkMMooicw2us9A=",
version = "v1.0.0",
)
go_repository(
name = "com_github_magiconair_properties",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/magiconair/properties",
sum = "h1:LLgXmsheXeRoUOBOjtwPQCWIYqM/LU1ayDtDePerRcY=",
version = "v1.8.0",
)
go_repository(
name = "com_github_mattn_go_sqlite3",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/mattn/go-sqlite3",
sum = "h1:pDRiWfl+++eC2FEFRy6jXmQlvp4Yh3z1MJKg4UeYM/4=",
version = "v1.9.0",
)
go_repository(
name = "com_github_matttproud_golang_protobuf_extensions",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/matttproud/golang_protobuf_extensions",
sum = "h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU=",
version = "v1.0.1",
)
go_repository(
name = "com_github_mitchellh_go_homedir",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/mitchellh/go-homedir",
sum = "h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=",
version = "v1.1.0",
)
go_repository(
name = "com_github_mitchellh_mapstructure",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/mitchellh/mapstructure",
sum = "h1:fmNYVwqnSfB9mZU6OS2O6GsXM+wcskZDuKQzvN1EDeE=",
version = "v1.1.2",
)
go_repository(
name = "com_github_modern_go_concurrent",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/modern-go/concurrent",
sum = "h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=",
version = "v0.0.0-20180306012644-bacd9c7ef1dd",
)
go_repository(
name = "com_github_modern_go_reflect2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/modern-go/reflect2",
sum = "h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=",
version = "v1.0.2",
)
go_repository(
name = "com_github_mwitkow_go_conntrack",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/mwitkow/go-conntrack",
sum = "h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU=",
version = "v0.0.0-20190716064945-2f068394615f",
)
go_repository(
name = "com_github_oneofone_xxhash",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/OneOfOne/xxhash",
sum = "h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE=",
version = "v1.2.2",
)
go_repository(
name = "com_github_pelletier_go_toml",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/pelletier/go-toml",
sum = "h1:T5zMGML61Wp+FlcbWjRDT7yAxhJNAiPPLOFECq181zc=",
version = "v1.2.0",
)
go_repository(
name = "com_github_pierrec_lz4",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/pierrec/lz4",
sum = "h1:9UY3+iC23yxF0UfGaYrGplQ+79Rg+h/q9FV9ix19jjM=",
version = "v2.6.1+incompatible",
)
go_repository(
name = "com_github_pkg_errors",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/pkg/errors",
sum = "h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=",
version = "v0.9.1",
)
go_repository(
name = "com_github_pmezard_go_difflib",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/pmezard/go-difflib",
sum = "h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=",
version = "v1.0.0",
)
go_repository(
name = "com_github_prometheus_client_golang",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/prometheus/client_golang",
sum = "h1:ZiaPsmm9uiBeaSMRznKsCDNtPCS0T3JVDGF+06gjBzk=",
version = "v1.12.1",
)
go_repository(
name = "com_github_prometheus_client_model",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/prometheus/client_model",
sum = "h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M=",
version = "v0.2.0",
)
go_repository(
name = "com_github_prometheus_common",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/prometheus/common",
sum = "h1:hWIdL3N2HoUx3B8j3YN9mWor0qhY/NlEKZEaXxuIRh4=",
version = "v0.32.1",
)
go_repository(
name = "com_github_prometheus_procfs",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/prometheus/procfs",
sum = "h1:4jVXhlkAyzOScmCkXBTOLRLTz8EeU+eyjrwB/EPq0VU=",
version = "v0.7.3",
)
go_repository(
name = "com_github_rogpeppe_fastuuid",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/rogpeppe/fastuuid",
sum = "h1:Ppwyp6VYCF1nvBTXL3trRso7mXMlRrw9ooo375wvi2s=",
version = "v1.2.0",
)
go_repository(
name = "com_github_rogpeppe_go_internal",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/rogpeppe/go-internal",
sum = "h1:/FiVV8dS/e+YqF2JvO3yXRFbBLTIuSDkuC7aBOAvL+k=",
version = "v1.6.1",
)
go_repository(
name = "com_github_rs_xid",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/rs/xid",
sum = "h1:6NjYksEUlhurdVehpc7S7dk6DAmcKv8V9gG0FsVN2U4=",
version = "v1.3.0",
)
go_repository(
name = "com_github_russross_blackfriday",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/russross/blackfriday",
sum = "h1:HyvC0ARfnZBqnXwABFeSZHpKvJHJJfPz81GNueLj0oo=",
version = "v1.5.2",
)
go_repository(
name = "com_github_sirupsen_logrus",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/sirupsen/logrus",
sum = "h1:UBcNElsrwanuuMsnGSlYmtmgbb23qDR5dG+6X6Oo89I=",
version = "v1.6.0",
)
go_repository(
name = "com_github_spaolacci_murmur3",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/spaolacci/murmur3",
sum = "h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI=",
version = "v1.1.0",
)
go_repository(
name = "com_github_spf13_afero",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/spf13/afero",
sum = "h1:m8/z1t7/fwjysjQRYbP0RD+bUIF/8tJwPdEZsI83ACI=",
version = "v1.1.2",
)
go_repository(
name = "com_github_spf13_cast",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/spf13/cast",
sum = "h1:oget//CVOEoFewqQxwr0Ej5yjygnqGkvggSE/gB35Q8=",
version = "v1.3.0",
)
go_repository(
name = "com_github_spf13_cobra",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/spf13/cobra",
sum = "h1:f0B+LkLX6DtmRH1isoNA9VTtNUK9K8xYd28JNNfOv/s=",
version = "v0.0.5",
)
go_repository(
name = "com_github_spf13_jwalterweatherman",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/spf13/jwalterweatherman",
sum = "h1:XHEdyB+EcvlqZamSM4ZOMGlc93t6AcsBEu9Gc1vn7yk=",
version = "v1.0.0",
)
go_repository(
name = "com_github_spf13_pflag",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/spf13/pflag",
sum = "h1:zPAT6CGy6wXeQ7NtTnaTerfKOsV6V6F8agHXFiazDkg=",
version = "v1.0.3",
)
go_repository(
name = "com_github_spf13_viper",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/spf13/viper",
sum = "h1:VUFqw5KcqRf7i70GOzW7N+Q7+gxVBkSSqiXB12+JQ4M=",
version = "v1.3.2",
)
go_repository(
name = "com_github_stretchr_objx",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/stretchr/objx",
sum = "h1:2vfRuCMp5sSVIDSqO8oNnWJq7mPa6KVP3iPIwFBuy8A=",
version = "v0.1.1",
)
go_repository(
name = "com_github_stretchr_testify",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/stretchr/testify",
sum = "h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=",
version = "v1.7.0",
)
go_repository(
name = "com_github_ugorji_go_codec",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/ugorji/go/codec",
sum = "h1:3SVOIvH7Ae1KRYyQWRjXWJEA9sS/c/pjvH++55Gr648=",
version = "v0.0.0-20181204163529-d75b2dcb6bc8",
)
go_repository(
name = "com_github_xordataexchange_crypt",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/xordataexchange/crypt",
sum = "h1:ESFSdwYZvkeru3RtdrYueztKhOBCSAAzS4Gf+k0tEow=",
version = "v0.0.3-0.20170626215501-b2862e3d0a77",
)
go_repository(
name = "com_github_yuin_goldmark",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "github.com/yuin/goldmark",
sum = "h1:/vn0k+RBvwlxEmP5E7SZMqNxPhfMVFEJiykr15/0XKM=",
version = "v1.4.1",
)
go_repository(
name = "com_google_cloud_go",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "cloud.google.com/go",
sum = "h1:t9Iw5QH5v4XtlEQaCtUY7x6sCABps8sW0acw7e2WQ6Y=",
version = "v0.100.2",
)
go_repository(
name = "com_google_cloud_go_bigquery",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "cloud.google.com/go/bigquery",
sum = "h1:PQcPefKFdaIzjQFbiyOgAqyx8q5djaE7x9Sqe712DPA=",
version = "v1.8.0",
)
go_repository(
name = "com_google_cloud_go_compute",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "cloud.google.com/go/compute",
sum = "h1:EKki8sSdvDU0OO9mAXGwPXOTOgPz2l08R0/IutDH11I=",
version = "v1.2.0",
)
go_repository(
name = "com_google_cloud_go_datastore",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "cloud.google.com/go/datastore",
sum = "h1:/May9ojXjRkPBNVrq+oWLqmWCkr4OU5uRY29bu0mRyQ=",
version = "v1.1.0",
)
go_repository(
name = "com_google_cloud_go_iam",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "cloud.google.com/go/iam",
sum = "h1:4CapQyNFjiksks1/x7jsvsygFPhihslYk5GptIrlX68=",
version = "v0.1.1",
)
go_repository(
name = "com_google_cloud_go_pubsub",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "cloud.google.com/go/pubsub",
sum = "h1:ukjixP1wl0LpnZ6LWtZJ0mX5tBmjp1f8Sqer8Z2OMUU=",
version = "v1.3.1",
)
go_repository(
name = "com_google_cloud_go_storage",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "cloud.google.com/go/storage",
sum = "h1:Ljj+ZXVEhCr/1+4ZhvtteN1ND7UUsNTlduGclLh8GO0=",
version = "v1.15.0",
)
go_repository(
name = "com_shuralyov_dmitri_gpu_mtl",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "dmitri.shuralyov.com/gpu/mtl",
sum = "h1:VpgP7xuJadIUuKccphEpTJnWhS2jkQyMt6Y7pJCD7fY=",
version = "v0.0.0-20190408044501-666a987793e9",
)
go_repository(
name = "in_gopkg_alecthomas_kingpin_v2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "gopkg.in/alecthomas/kingpin.v2",
sum = "h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc=",
version = "v2.2.6",
)
go_repository(
name = "in_gopkg_check_v1",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "gopkg.in/check.v1",
sum = "h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=",
version = "v1.0.0-20201130134442-10cb98267c6c",
)
go_repository(
name = "in_gopkg_errgo_v2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "gopkg.in/errgo.v2",
sum = "h1:0vLT13EuvQ0hNvakwLuFZ/jYrLp5F3kcWHXdRggjCE8=",
version = "v2.1.0",
)
go_repository(
name = "in_gopkg_yaml_v2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "gopkg.in/yaml.v2",
sum = "h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=",
version = "v2.4.0",
)
go_repository(
name = "in_gopkg_yaml_v3",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "gopkg.in/yaml.v3",
sum = "h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo=",
version = "v3.0.0-20210107192922-496545a6307b",
)
go_repository(
name = "io_opencensus_go",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "go.opencensus.io",
sum = "h1:gqCw0LfLxScz8irSi8exQc7fyQ0fKQU/qnC/X8+V/1M=",
version = "v0.23.0",
)
go_repository(
name = "io_opentelemetry_go_proto_otlp",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "go.opentelemetry.io/proto/otlp",
sum = "h1:rwOQPCuKAKmwGKq2aVNnYIibI6wnV7EvzgfTCzcdGg8=",
version = "v0.7.0",
)
go_repository(
name = "io_rsc_binaryregexp",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "rsc.io/binaryregexp",
sum = "h1:HfqmD5MEmC0zvwBuF187nq9mdnXjXsSivRiXN7SmRkE=",
version = "v0.2.0",
)
go_repository(
name = "io_rsc_quote_v3",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "rsc.io/quote/v3",
sum = "h1:9JKUTTIUgS6kzR9mK1YuGKv6Nl+DijDNIc0ghT58FaY=",
version = "v3.1.0",
)
go_repository(
name = "io_rsc_sampler",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "rsc.io/sampler",
sum = "h1:7uVkIFmeBqHfdjD+gZwtXXI+RODJ2Wc4O7MPEh/QiW4=",
version = "v1.3.0",
)
go_repository(
name = "org_golang_google_api",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "google.golang.org/api",
sum = "h1:9eJiHhwJKIYX6sX2fUZxQLi7pDRA/MYu8c12q6WbJik=",
version = "v0.68.0",
)
go_repository(
name = "org_golang_google_appengine",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "google.golang.org/appengine",
sum = "h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c=",
version = "v1.6.7",
)
go_repository(
name = "org_golang_google_genproto",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "google.golang.org/genproto",
sum = "h1:2X+CNIheCutWRyKRte8szGxrE5ggtV4U+NKAbh/oLhg=",
version = "v0.0.0-20220211171837-173942840c17",
)
go_repository(
name = "org_golang_google_grpc",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "google.golang.org/grpc",
sum = "h1:weqSxi/TMs1SqFRMHCtBgXRs8k3X39QIDEZ0pRcttUg=",
version = "v1.44.0",
)
go_repository(
name = "org_golang_google_grpc_cmd_protoc_gen_go_grpc",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "google.golang.org/grpc/cmd/protoc-gen-go-grpc",
sum = "h1:M1YKkFIboKNieVO5DLUEVzQfGwJD30Nv2jfUgzb5UcE=",
version = "v1.1.0",
)
go_repository(
name = "org_golang_google_protobuf",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "google.golang.org/protobuf",
sum = "h1:SnqbnDw1V7RiZcXPx5MEeqPv2s79L9i7BJUlG/+RurQ=",
version = "v1.27.1",
)
go_repository(
name = "org_golang_x_crypto",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/crypto",
sum = "h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI=",
version = "v0.0.0-20200622213623-75b288015ac9",
)
go_repository(
name = "org_golang_x_exp",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/exp",
sum = "h1:QE6XYQK6naiK1EPAe1g/ILLxN5RBoH5xkJk3CqlMI/Y=",
version = "v0.0.0-20200224162631-6cc2880d07d6",
)
go_repository(
name = "org_golang_x_image",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/image",
sum = "h1:+qEpEAPhDZ1o0x3tHzZTQDArnOixOzGD9HUJfcg0mb4=",
version = "v0.0.0-20190802002840-cff245a6509b",
)
go_repository(
name = "org_golang_x_lint",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/lint",
sum = "h1:VLliZ0d+/avPrXXH+OakdXhpJuEoBZuwh1m2j7U6Iug=",
version = "v0.0.0-20210508222113-6edffad5e616",
)
go_repository(
name = "org_golang_x_mobile",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/mobile",
sum = "h1:4+4C/Iv2U4fMZBiMCc98MG1In4gJY5YRhtpDNeDeHWs=",
version = "v0.0.0-20190719004257-d2bd2a29d028",
)
go_repository(
name = "org_golang_x_mod",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/mod",
sum = "h1:OJxoQ/rynoF0dcCdI7cLPktw/hR2cueqYfjm43oqK38=",
version = "v0.5.1",
)
go_repository(
name = "org_golang_x_net",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/net",
sum = "h1:O7DYs+zxREGLKzKoMQrtrEacpb0ZVXA5rIwylE2Xchk=",
version = "v0.0.0-20220127200216-cd36cc0744dd",
)
go_repository(
name = "org_golang_x_oauth2",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/oauth2",
sum = "h1:RerP+noqYHUQ8CMRcPlC2nvTa4dcBIjegkuWdcUDuqg=",
version = "v0.0.0-20211104180415-d3ed0bb246c8",
)
go_repository(
name = "org_golang_x_sync",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/sync",
sum = "h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ=",
version = "v0.0.0-20210220032951-036812b2e83c",
)
go_repository(
name = "org_golang_x_sys",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/sys",
sum = "h1:rm+CHSpPEEW2IsXUib1ThaHIjuBVZjxNgSKmBLFfD4c=",
version = "v0.0.0-20220209214540-3681064d5158",
)
go_repository(
name = "org_golang_x_term",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/term",
sum = "h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY=",
version = "v0.0.0-20210927222741-03fcf44c2211",
)
go_repository(
name = "org_golang_x_text",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/text",
sum = "h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=",
version = "v0.3.7",
)
go_repository(
name = "org_golang_x_time",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/time",
sum = "h1:/5xXl8Y5W96D+TtHSlonuFqGHIWVuyCkGJLwGh9JJFs=",
version = "v0.0.0-20191024005414-555d28b269f0",
)
go_repository(
name = "org_golang_x_tools",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/tools",
sum = "h1:j9KsMiaP1c3B0OTQGth0/k+miLGTgLsAFUCrF2vLcF8=",
version = "v0.1.9",
)
go_repository(
name = "org_golang_x_xerrors",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "golang.org/x/xerrors",
sum = "h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE=",
version = "v0.0.0-20200804184101-5ec99f83aff1",
)
go_repository(
name = "org_uber_go_atomic",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "go.uber.org/atomic",
sum = "h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE=",
version = "v1.9.0",
)
go_repository(
name = "org_uber_go_goleak",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "go.uber.org/goleak",
sum = "h1:wy28qYRKZgnJTxGxvye5/wgWr1EKjmUDGYox5mGlRlI=",
version = "v1.1.11",
)
go_repository(
name = "org_uber_go_multierr",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "go.uber.org/multierr",
sum = "h1:zaiO/rmgFjbmCXdSYJWQcdvOCsthmdaHfr3Gm2Kx4Ec=",
version = "v1.7.0",
)
go_repository(
name = "org_uber_go_zap",
build_extra_args = ["-exclude=**/testdata", "-exclude=go/packages/packagestest"],
importpath = "go.uber.org/zap",
sum = "h1:WefMeulhovoZ2sYXz7st6K0sLj7bBhpiFaud4r4zST8=",
version = "v1.21.0",
)
| load('@bazel_gazelle//:deps.bzl', 'go_repository')
def go_repositories():
go_repository(name='co_honnef_go_tools', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='honnef.co/go/tools', sum='h1:MNh1AVMyVX23VUHE2O27jm6lNj3vjO5DexS4A1xvnzk=', version='v0.2.2')
go_repository(name='com_github_alecthomas_template', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/alecthomas/template', sum='h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM=', version='v0.0.0-20190718012654-fb15b899a751')
go_repository(name='com_github_alecthomas_units', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/alecthomas/units', sum='h1:UQZhZ2O0vMHr2cI+DC1Mbh0TJxzA3RcLoMsFw+aXw7E=', version='v0.0.0-20190924025748-f65c72e2690d')
go_repository(name='com_github_andreasbriese_bbloom', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/AndreasBriese/bbloom', sum='h1:cTp8I5+VIoKjsnZuH8vjyaysT/ses3EvZeaV/1UkF2M=', version='v0.0.0-20190825152654-46b345b51c96')
go_repository(name='com_github_antihax_optional', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/antihax/optional', sum='h1:xK2lYat7ZLaVVcIuj82J8kIro4V6kDe0AUDFboUCwcg=', version='v1.0.0')
go_repository(name='com_github_armon_consul_api', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/armon/consul-api', sum='h1:G1bPvciwNyF7IUmKXNt9Ak3m6u9DE1rF+RmtIkBpVdA=', version='v0.0.0-20180202201655-eb2c6b5be1b6')
go_repository(name='com_github_aws_aws_sdk_go_v2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2', sum='h1:1XIXAfxsEmbhbj5ry3D3vX+6ZcUYvIqSm4CWWEuGZCA=', version='v1.13.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_aws_protocol_eventstream', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream', sum='h1:scBthy70MB3m4LCMFaBcmYCyR2XWOz6MxSfdSu/+fQo=', version='v1.2.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_config', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/config', sum='h1:yLv8bfNoT4r+UvUKQKqRtdnvuWGMK5a82l4ru9Jvnuo=', version='v1.13.1')
go_repository(name='com_github_aws_aws_sdk_go_v2_credentials', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/credentials', sum='h1:8Ow0WcyDesGNL0No11jcgb1JAtE+WtubqXjgxau+S0o=', version='v1.8.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_feature_ec2_imds', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/feature/ec2/imds', sum='h1:NITDuUZO34mqtOwFWZiXo7yAHj7kf+XPE+EiKuCBNUI=', version='v1.10.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_feature_s3_manager', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/feature/s3/manager', sum='h1:oUCLhAKNaXyTqdJyw+KEjDVVBs1V5mCy8YDLMi08LL8=', version='v1.9.1')
go_repository(name='com_github_aws_aws_sdk_go_v2_internal_configsources', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/internal/configsources', sum='h1:CRiQJ4E2RhfDdqbie1ZYDo8QtIo75Mk7oTdJSfwJTMQ=', version='v1.1.4')
go_repository(name='com_github_aws_aws_sdk_go_v2_internal_endpoints_v2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/internal/endpoints/v2', sum='h1:3ADoioDMOtF4uiK59vCpplpCwugEU+v4ZFD29jDL3RQ=', version='v2.2.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_internal_ini', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/internal/ini', sum='h1:ixotxbfTCFpqbuwFv/RcZwyzhkxPSYDYEMcj4niB5Uk=', version='v1.3.5')
go_repository(name='com_github_aws_aws_sdk_go_v2_service_internal_accept_encoding', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding', sum='h1:F1diQIOkNn8jcez4173r+PLPdkWK7chy74r3fKpDrLI=', version='v1.7.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_service_internal_presigned_url', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/service/internal/presigned-url', sum='h1:4QAOB3KrvI1ApJK14sliGr3Ie2pjyvNypn/lfzDHfUw=', version='v1.7.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_service_internal_s3shared', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/service/internal/s3shared', sum='h1:XAe+PDnaBELHr25qaJKfB415V4CKFWE8H+prUreql8k=', version='v1.11.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_service_s3', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/service/s3', sum='h1:zAU2P99CLTz8kUGl+IptU2ycAXuMaLAvgIv+UH4U8pY=', version='v1.24.1')
go_repository(name='com_github_aws_aws_sdk_go_v2_service_sso', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/service/sso', sum='h1:1qLJeQGBmNQW3mBNzK2CFmrQNmoXWrscPqsrAaU1aTA=', version='v1.9.0')
go_repository(name='com_github_aws_aws_sdk_go_v2_service_sts', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/aws-sdk-go-v2/service/sts', sum='h1:ksiDXhvNYg0D2/UFkLejsaz3LqpW5yjNQ8Nx9Sn2c0E=', version='v1.14.0')
go_repository(name='com_github_aws_smithy_go', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/aws/smithy-go', sum='h1:gsoZQMNHnX+PaghNw4ynPsyGP7aUCqx5sY2dlPQsZ0w=', version='v1.10.0')
go_repository(name='com_github_benbjohnson_clock', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/benbjohnson/clock', sum='h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8=', version='v1.1.0')
go_repository(name='com_github_beorn7_perks', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/beorn7/perks', sum='h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=', version='v1.0.1')
go_repository(name='com_github_bkaradzic_go_lz4', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/bkaradzic/go-lz4', sum='h1:RXc4wYsyz985CkXXeX04y4VnZFGG8Rd43pRaHsOXAKk=', version='v1.0.0')
go_repository(name='com_github_burntsushi_toml', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/BurntSushi/toml', sum='h1:dtDWrepsVPfW9H/4y7dDgFc2MBUSeJhlaDtK13CxFlU=', version='v1.0.0')
go_repository(name='com_github_burntsushi_xgb', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/BurntSushi/xgb', sum='h1:1BDTz0u9nC3//pOCMdNH+CiXJVYJh5UQNCOBG7jbELc=', version='v0.0.0-20160522181843-27f122750802')
go_repository(name='com_github_census_instrumentation_opencensus_proto', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/census-instrumentation/opencensus-proto', sum='h1:glEXhBS5PSLLv4IXzLA5yPRVX4bilULVyxxbrfOtDAk=', version='v0.2.1')
go_repository(name='com_github_cespare_xxhash', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/cespare/xxhash', sum='h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko=', version='v1.1.0')
go_repository(name='com_github_cespare_xxhash_v2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/cespare/xxhash/v2', sum='h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE=', version='v2.1.2')
go_repository(name='com_github_chzyer_logex', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/chzyer/logex', sum='h1:Swpa1K6QvQznwJRcfTfQJmTE72DqScAa40E+fbHEXEE=', version='v1.1.10')
go_repository(name='com_github_chzyer_readline', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/chzyer/readline', sum='h1:fY5BOSpyZCqRo5OhCuC+XN+r/bBCmeuuJtjz+bCNIf8=', version='v0.0.0-20180603132655-2972be24d48e')
go_repository(name='com_github_chzyer_test', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/chzyer/test', sum='h1:q763qf9huN11kDQavWsoZXJNW3xEE4JJyHa5Q25/sd8=', version='v0.0.0-20180213035817-a1ea475d72b1')
go_repository(name='com_github_clickhouse_clickhouse_go', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/ClickHouse/clickhouse-go', sum='h1:cKjXeYLNWVJIx2J1K6H2CqyRmfwVJVY1OV1coaaFcI0=', version='v1.5.4')
go_repository(name='com_github_client9_misspell', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/client9/misspell', sum='h1:ta993UF76GwbvJcIo3Y68y/M3WxlpEHPWIGDkJYwzJI=', version='v0.3.4')
go_repository(name='com_github_cloudflare_golz4', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/cloudflare/golz4', sum='h1:F1EaeKL/ta07PY/k9Os/UFtwERei2/XzGemhpGnBKNg=', version='v0.0.0-20150217214814-ef862a3cdc58')
go_repository(name='com_github_cncf_udpa_go', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/cncf/udpa/go', sum='h1:hzAQntlaYRkVSFEfj9OTWlVV1H155FMD8BTKktLv0QI=', version='v0.0.0-20210930031921-04548b0d99d4')
go_repository(name='com_github_cncf_xds_go', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/cncf/xds/go', sum='h1:zH8ljVhhq7yC0MIeUL/IviMtY8hx2mK8cN9wEYb8ggw=', version='v0.0.0-20211011173535-cb28da3451f1')
go_repository(name='com_github_coreos_etcd', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/coreos/etcd', sum='h1:jFneRYjIvLMLhDLCzuTuU4rSJUjRplcJQ7pD7MnhC04=', version='v3.3.10+incompatible')
go_repository(name='com_github_coreos_go_etcd', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/coreos/go-etcd', sum='h1:bXhRBIXoTm9BYHS3gE0TtQuyNZyeEMux2sDi4oo5YOo=', version='v2.0.0+incompatible')
go_repository(name='com_github_coreos_go_semver', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/coreos/go-semver', sum='h1:3Jm3tLmsgAYcjC+4Up7hJrFBPr+n7rAqYeSw/SZazuY=', version='v0.2.0')
go_repository(name='com_github_cpuguy83_go_md2man', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/cpuguy83/go-md2man', sum='h1:BSKMNlYxDvnunlTymqtgONjNnaRV1sTpcovwwjF22jk=', version='v1.0.10')
go_repository(name='com_github_creack_pty', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/creack/pty', sum='h1:uDmaGzcdjhF4i/plgjmEsriH11Y0o7RKapEf/LDaM3w=', version='v1.1.9')
go_repository(name='com_github_davecgh_go_spew', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/davecgh/go-spew', sum='h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=', version='v1.1.1')
go_repository(name='com_github_dgraph_io_badger', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/dgraph-io/badger', sum='h1:mNw0qs90GVgGGWylh0umH5iag1j6n/PeJtNvL6KY/x8=', version='v1.6.2')
go_repository(name='com_github_dgraph_io_ristretto', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/dgraph-io/ristretto', sum='h1:a5WaUrDa0qm0YrAAS1tUykT5El3kt62KNZZeMxQn3po=', version='v0.0.2')
go_repository(name='com_github_dgryski_go_farm', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/dgryski/go-farm', sum='h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y=', version='v0.0.0-20200201041132-a6ae2369ad13')
go_repository(name='com_github_dustin_go_humanize', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/dustin/go-humanize', sum='h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo=', version='v1.0.0')
go_repository(name='com_github_envoyproxy_go_control_plane', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/envoyproxy/go-control-plane', sum='h1:fP+fF0up6oPY49OrjPrhIJ8yQfdIM85NXMLkMg1EXVs=', version='v0.9.10-0.20210907150352-cf90f659a021')
go_repository(name='com_github_envoyproxy_protoc_gen_validate', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/envoyproxy/protoc-gen-validate', sum='h1:EQciDnbrYxy13PgWoY8AqoxGiPrpgBZ1R8UNe3ddc+A=', version='v0.1.0')
go_repository(name='com_github_fsnotify_fsnotify', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/fsnotify/fsnotify', sum='h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I=', version='v1.4.7')
go_repository(name='com_github_ghodss_yaml', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/ghodss/yaml', sum='h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk=', version='v1.0.0')
go_repository(name='com_github_go_gl_glfw', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/go-gl/glfw', sum='h1:QbL/5oDUmRBzO9/Z7Seo6zf912W/a6Sr4Eu0G/3Jho0=', version='v0.0.0-20190409004039-e6da0acd62b1')
go_repository(name='com_github_go_gl_glfw_v3_3_glfw', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/go-gl/glfw/v3.3/glfw', sum='h1:WtGNWLvXpe6ZudgnXrq0barxBImvnnJoMEhXAzcbM0I=', version='v0.0.0-20200222043503-6f7a984d4dc4')
go_repository(name='com_github_go_kit_kit', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/go-kit/kit', sum='h1:wDJmvq38kDhkVxi50ni9ykkdUr1PKgqKOoi01fa0Mdk=', version='v0.9.0')
go_repository(name='com_github_go_kit_log', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/go-kit/log', sum='h1:DGJh0Sm43HbOeYDNnVZFl8BvcYVvjD5bqYJvp0REbwQ=', version='v0.1.0')
go_repository(name='com_github_go_logfmt_logfmt', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/go-logfmt/logfmt', sum='h1:TrB8swr/68K7m9CcGut2g3UOihhbcbiMAYiuTXdEih4=', version='v0.5.0')
go_repository(name='com_github_go_sql_driver_mysql', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/go-sql-driver/mysql', sum='h1:7LxgVwFb2hIQtMm87NdgAVfXjnt4OePseqT1tKx+opk=', version='v1.4.0')
go_repository(name='com_github_go_stack_stack', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/go-stack/stack', sum='h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk=', version='v1.8.0')
go_repository(name='com_github_gogo_protobuf', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/gogo/protobuf', sum='h1:72R+M5VuhED/KujmZVcIquuo8mBgX4oVda//DQb3PXo=', version='v1.1.1')
go_repository(name='com_github_golang_glog', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/golang/glog', sum='h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58=', version='v0.0.0-20160126235308-23def4e6c14b')
go_repository(name='com_github_golang_groupcache', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/golang/groupcache', sum='h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE=', version='v0.0.0-20210331224755-41bb18bfe9da')
go_repository(name='com_github_golang_mock', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/golang/mock', sum='h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc=', version='v1.6.0')
go_repository(name='com_github_golang_protobuf', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/golang/protobuf', sum='h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw=', version='v1.5.2')
go_repository(name='com_github_golang_snappy', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/golang/snappy', sum='h1:fHPg5GQYlCeLIPB9BZqMVR5nR9A+IM5zcgeTdjMYmLA=', version='v0.0.3')
go_repository(name='com_github_google_btree', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/btree', sum='h1:0udJVsspx3VBr5FwtLhQQtuAsVc79tTq0ocGIPAU6qo=', version='v1.0.0')
go_repository(name='com_github_google_go_cmp', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/go-cmp', sum='h1:81/ik6ipDQS2aGcBfIN5dHDB36BwrStyeAQquSYCV4o=', version='v0.5.7')
go_repository(name='com_github_google_gofuzz', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/gofuzz', sum='h1:A8PeW59pxE9IoFRqBp37U+mSNaQoZ46F1f0f863XSXw=', version='v1.0.0')
go_repository(name='com_github_google_martian', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/martian', sum='h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no=', version='v2.1.0+incompatible')
go_repository(name='com_github_google_martian_v3', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/martian/v3', sum='h1:d8MncMlErDFTwQGBK1xhv026j9kqhvw1Qv9IbWT1VLQ=', version='v3.2.1')
go_repository(name='com_github_google_pprof', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/pprof', sum='h1:K6RDEckDVWvDI9JAJYCmNdQXq6neHJOYx3V6jnqNEec=', version='v0.0.0-20210720184732-4bb14d4b1be1')
go_repository(name='com_github_google_renameio', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/renameio', sum='h1:GOZbcHa3HfsPKPlmyPyN2KEohoMXOhdMbHrvbpl2QaA=', version='v0.1.0')
go_repository(name='com_github_google_uuid', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/google/uuid', sum='h1:EVhdT+1Kseyi1/pUmXKaFxYsDNy9RQYkMWRH68J/W7Y=', version='v1.1.2')
go_repository(name='com_github_googleapis_gax_go_v2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/googleapis/gax-go/v2', sum='h1:dp3bWCh+PPO1zjRRiCSczJav13sBvG4UhNyVTa1KqdU=', version='v2.1.1')
go_repository(name='com_github_grpc_ecosystem_grpc_gateway', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/grpc-ecosystem/grpc-gateway', sum='h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo=', version='v1.16.0')
go_repository(name='com_github_hashicorp_golang_lru', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/hashicorp/golang-lru', sum='h1:0hERBMJE1eitiLkihrMvRVBYAkpHzc/J3QdDN+dAcgU=', version='v0.5.1')
go_repository(name='com_github_hashicorp_hcl', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/hashicorp/hcl', sum='h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4=', version='v1.0.0')
go_repository(name='com_github_ianlancetaylor_demangle', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/ianlancetaylor/demangle', sum='h1:mV02weKRL81bEnm8A0HT1/CAelMQDBuQIfLw8n+d6xI=', version='v0.0.0-20200824232613-28f6c0f3b639')
go_repository(name='com_github_inconshreveable_mousetrap', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/inconshreveable/mousetrap', sum='h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM=', version='v1.0.0')
go_repository(name='com_github_jmespath_go_jmespath', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/jmespath/go-jmespath', sum='h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=', version='v0.4.0')
go_repository(name='com_github_jmespath_go_jmespath_internal_testify', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/jmespath/go-jmespath/internal/testify', sum='h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=', version='v1.5.1')
go_repository(name='com_github_jmoiron_sqlx', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/jmoiron/sqlx', sum='h1:41Ip0zITnmWNR/vHV+S4m+VoUivnWY5E4OJfLZjCJMA=', version='v1.2.0')
go_repository(name='com_github_jpillora_backoff', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/jpillora/backoff', sum='h1:uvFg412JmmHBHw7iwprIxkPMI+sGQ4kzOWsMeHnm2EA=', version='v1.0.0')
go_repository(name='com_github_json_iterator_go', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/json-iterator/go', sum='h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=', version='v1.1.12')
go_repository(name='com_github_jstemmer_go_junit_report', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/jstemmer/go-junit-report', sum='h1:6QPYqodiu3GuPL+7mfx+NwDdp2eTkp9IfEUpgAwUN0o=', version='v0.9.1')
go_repository(name='com_github_julienschmidt_httprouter', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/julienschmidt/httprouter', sum='h1:U0609e9tgbseu3rBINet9P48AI/D3oJs4dN7jwJOQ1U=', version='v1.3.0')
go_repository(name='com_github_kisielk_gotool', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/kisielk/gotool', sum='h1:AV2c/EiW3KqPNT9ZKl07ehoAGi4C5/01Cfbblndcapg=', version='v1.0.0')
go_repository(name='com_github_konsorten_go_windows_terminal_sequences', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/konsorten/go-windows-terminal-sequences', sum='h1:CE8S1cTafDpPvMhIxNJKvHsGVBgn1xWYf1NbHQhywc8=', version='v1.0.3')
go_repository(name='com_github_kr_logfmt', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/kr/logfmt', sum='h1:T+h1c/A9Gawja4Y9mFVWj2vyii2bbUNDw3kt9VxK2EY=', version='v0.0.0-20140226030751-b84e30acd515')
go_repository(name='com_github_kr_pretty', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/kr/pretty', sum='h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0=', version='v0.3.0')
go_repository(name='com_github_kr_pty', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/kr/pty', sum='h1:VkoXIwSboBpnk99O/KFauAEILuNHv5DVFKZMBN/gUgw=', version='v1.1.1')
go_repository(name='com_github_kr_text', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/kr/text', sum='h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=', version='v0.2.0')
go_repository(name='com_github_lib_pq', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/lib/pq', sum='h1:X5PMW56eZitiTeO7tKzZxFCSpbFZJtkMMooicw2us9A=', version='v1.0.0')
go_repository(name='com_github_magiconair_properties', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/magiconair/properties', sum='h1:LLgXmsheXeRoUOBOjtwPQCWIYqM/LU1ayDtDePerRcY=', version='v1.8.0')
go_repository(name='com_github_mattn_go_sqlite3', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/mattn/go-sqlite3', sum='h1:pDRiWfl+++eC2FEFRy6jXmQlvp4Yh3z1MJKg4UeYM/4=', version='v1.9.0')
go_repository(name='com_github_matttproud_golang_protobuf_extensions', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/matttproud/golang_protobuf_extensions', sum='h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU=', version='v1.0.1')
go_repository(name='com_github_mitchellh_go_homedir', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/mitchellh/go-homedir', sum='h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=', version='v1.1.0')
go_repository(name='com_github_mitchellh_mapstructure', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/mitchellh/mapstructure', sum='h1:fmNYVwqnSfB9mZU6OS2O6GsXM+wcskZDuKQzvN1EDeE=', version='v1.1.2')
go_repository(name='com_github_modern_go_concurrent', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/modern-go/concurrent', sum='h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg=', version='v0.0.0-20180306012644-bacd9c7ef1dd')
go_repository(name='com_github_modern_go_reflect2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/modern-go/reflect2', sum='h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=', version='v1.0.2')
go_repository(name='com_github_mwitkow_go_conntrack', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/mwitkow/go-conntrack', sum='h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU=', version='v0.0.0-20190716064945-2f068394615f')
go_repository(name='com_github_oneofone_xxhash', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/OneOfOne/xxhash', sum='h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE=', version='v1.2.2')
go_repository(name='com_github_pelletier_go_toml', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/pelletier/go-toml', sum='h1:T5zMGML61Wp+FlcbWjRDT7yAxhJNAiPPLOFECq181zc=', version='v1.2.0')
go_repository(name='com_github_pierrec_lz4', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/pierrec/lz4', sum='h1:9UY3+iC23yxF0UfGaYrGplQ+79Rg+h/q9FV9ix19jjM=', version='v2.6.1+incompatible')
go_repository(name='com_github_pkg_errors', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/pkg/errors', sum='h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=', version='v0.9.1')
go_repository(name='com_github_pmezard_go_difflib', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/pmezard/go-difflib', sum='h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=', version='v1.0.0')
go_repository(name='com_github_prometheus_client_golang', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/prometheus/client_golang', sum='h1:ZiaPsmm9uiBeaSMRznKsCDNtPCS0T3JVDGF+06gjBzk=', version='v1.12.1')
go_repository(name='com_github_prometheus_client_model', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/prometheus/client_model', sum='h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M=', version='v0.2.0')
go_repository(name='com_github_prometheus_common', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/prometheus/common', sum='h1:hWIdL3N2HoUx3B8j3YN9mWor0qhY/NlEKZEaXxuIRh4=', version='v0.32.1')
go_repository(name='com_github_prometheus_procfs', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/prometheus/procfs', sum='h1:4jVXhlkAyzOScmCkXBTOLRLTz8EeU+eyjrwB/EPq0VU=', version='v0.7.3')
go_repository(name='com_github_rogpeppe_fastuuid', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/rogpeppe/fastuuid', sum='h1:Ppwyp6VYCF1nvBTXL3trRso7mXMlRrw9ooo375wvi2s=', version='v1.2.0')
go_repository(name='com_github_rogpeppe_go_internal', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/rogpeppe/go-internal', sum='h1:/FiVV8dS/e+YqF2JvO3yXRFbBLTIuSDkuC7aBOAvL+k=', version='v1.6.1')
go_repository(name='com_github_rs_xid', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/rs/xid', sum='h1:6NjYksEUlhurdVehpc7S7dk6DAmcKv8V9gG0FsVN2U4=', version='v1.3.0')
go_repository(name='com_github_russross_blackfriday', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/russross/blackfriday', sum='h1:HyvC0ARfnZBqnXwABFeSZHpKvJHJJfPz81GNueLj0oo=', version='v1.5.2')
go_repository(name='com_github_sirupsen_logrus', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/sirupsen/logrus', sum='h1:UBcNElsrwanuuMsnGSlYmtmgbb23qDR5dG+6X6Oo89I=', version='v1.6.0')
go_repository(name='com_github_spaolacci_murmur3', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/spaolacci/murmur3', sum='h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI=', version='v1.1.0')
go_repository(name='com_github_spf13_afero', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/spf13/afero', sum='h1:m8/z1t7/fwjysjQRYbP0RD+bUIF/8tJwPdEZsI83ACI=', version='v1.1.2')
go_repository(name='com_github_spf13_cast', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/spf13/cast', sum='h1:oget//CVOEoFewqQxwr0Ej5yjygnqGkvggSE/gB35Q8=', version='v1.3.0')
go_repository(name='com_github_spf13_cobra', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/spf13/cobra', sum='h1:f0B+LkLX6DtmRH1isoNA9VTtNUK9K8xYd28JNNfOv/s=', version='v0.0.5')
go_repository(name='com_github_spf13_jwalterweatherman', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/spf13/jwalterweatherman', sum='h1:XHEdyB+EcvlqZamSM4ZOMGlc93t6AcsBEu9Gc1vn7yk=', version='v1.0.0')
go_repository(name='com_github_spf13_pflag', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/spf13/pflag', sum='h1:zPAT6CGy6wXeQ7NtTnaTerfKOsV6V6F8agHXFiazDkg=', version='v1.0.3')
go_repository(name='com_github_spf13_viper', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/spf13/viper', sum='h1:VUFqw5KcqRf7i70GOzW7N+Q7+gxVBkSSqiXB12+JQ4M=', version='v1.3.2')
go_repository(name='com_github_stretchr_objx', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/stretchr/objx', sum='h1:2vfRuCMp5sSVIDSqO8oNnWJq7mPa6KVP3iPIwFBuy8A=', version='v0.1.1')
go_repository(name='com_github_stretchr_testify', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/stretchr/testify', sum='h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=', version='v1.7.0')
go_repository(name='com_github_ugorji_go_codec', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/ugorji/go/codec', sum='h1:3SVOIvH7Ae1KRYyQWRjXWJEA9sS/c/pjvH++55Gr648=', version='v0.0.0-20181204163529-d75b2dcb6bc8')
go_repository(name='com_github_xordataexchange_crypt', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/xordataexchange/crypt', sum='h1:ESFSdwYZvkeru3RtdrYueztKhOBCSAAzS4Gf+k0tEow=', version='v0.0.3-0.20170626215501-b2862e3d0a77')
go_repository(name='com_github_yuin_goldmark', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='github.com/yuin/goldmark', sum='h1:/vn0k+RBvwlxEmP5E7SZMqNxPhfMVFEJiykr15/0XKM=', version='v1.4.1')
go_repository(name='com_google_cloud_go', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='cloud.google.com/go', sum='h1:t9Iw5QH5v4XtlEQaCtUY7x6sCABps8sW0acw7e2WQ6Y=', version='v0.100.2')
go_repository(name='com_google_cloud_go_bigquery', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='cloud.google.com/go/bigquery', sum='h1:PQcPefKFdaIzjQFbiyOgAqyx8q5djaE7x9Sqe712DPA=', version='v1.8.0')
go_repository(name='com_google_cloud_go_compute', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='cloud.google.com/go/compute', sum='h1:EKki8sSdvDU0OO9mAXGwPXOTOgPz2l08R0/IutDH11I=', version='v1.2.0')
go_repository(name='com_google_cloud_go_datastore', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='cloud.google.com/go/datastore', sum='h1:/May9ojXjRkPBNVrq+oWLqmWCkr4OU5uRY29bu0mRyQ=', version='v1.1.0')
go_repository(name='com_google_cloud_go_iam', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='cloud.google.com/go/iam', sum='h1:4CapQyNFjiksks1/x7jsvsygFPhihslYk5GptIrlX68=', version='v0.1.1')
go_repository(name='com_google_cloud_go_pubsub', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='cloud.google.com/go/pubsub', sum='h1:ukjixP1wl0LpnZ6LWtZJ0mX5tBmjp1f8Sqer8Z2OMUU=', version='v1.3.1')
go_repository(name='com_google_cloud_go_storage', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='cloud.google.com/go/storage', sum='h1:Ljj+ZXVEhCr/1+4ZhvtteN1ND7UUsNTlduGclLh8GO0=', version='v1.15.0')
go_repository(name='com_shuralyov_dmitri_gpu_mtl', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='dmitri.shuralyov.com/gpu/mtl', sum='h1:VpgP7xuJadIUuKccphEpTJnWhS2jkQyMt6Y7pJCD7fY=', version='v0.0.0-20190408044501-666a987793e9')
go_repository(name='in_gopkg_alecthomas_kingpin_v2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='gopkg.in/alecthomas/kingpin.v2', sum='h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc=', version='v2.2.6')
go_repository(name='in_gopkg_check_v1', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='gopkg.in/check.v1', sum='h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=', version='v1.0.0-20201130134442-10cb98267c6c')
go_repository(name='in_gopkg_errgo_v2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='gopkg.in/errgo.v2', sum='h1:0vLT13EuvQ0hNvakwLuFZ/jYrLp5F3kcWHXdRggjCE8=', version='v2.1.0')
go_repository(name='in_gopkg_yaml_v2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='gopkg.in/yaml.v2', sum='h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=', version='v2.4.0')
go_repository(name='in_gopkg_yaml_v3', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='gopkg.in/yaml.v3', sum='h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo=', version='v3.0.0-20210107192922-496545a6307b')
go_repository(name='io_opencensus_go', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='go.opencensus.io', sum='h1:gqCw0LfLxScz8irSi8exQc7fyQ0fKQU/qnC/X8+V/1M=', version='v0.23.0')
go_repository(name='io_opentelemetry_go_proto_otlp', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='go.opentelemetry.io/proto/otlp', sum='h1:rwOQPCuKAKmwGKq2aVNnYIibI6wnV7EvzgfTCzcdGg8=', version='v0.7.0')
go_repository(name='io_rsc_binaryregexp', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='rsc.io/binaryregexp', sum='h1:HfqmD5MEmC0zvwBuF187nq9mdnXjXsSivRiXN7SmRkE=', version='v0.2.0')
go_repository(name='io_rsc_quote_v3', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='rsc.io/quote/v3', sum='h1:9JKUTTIUgS6kzR9mK1YuGKv6Nl+DijDNIc0ghT58FaY=', version='v3.1.0')
go_repository(name='io_rsc_sampler', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='rsc.io/sampler', sum='h1:7uVkIFmeBqHfdjD+gZwtXXI+RODJ2Wc4O7MPEh/QiW4=', version='v1.3.0')
go_repository(name='org_golang_google_api', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='google.golang.org/api', sum='h1:9eJiHhwJKIYX6sX2fUZxQLi7pDRA/MYu8c12q6WbJik=', version='v0.68.0')
go_repository(name='org_golang_google_appengine', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='google.golang.org/appengine', sum='h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c=', version='v1.6.7')
go_repository(name='org_golang_google_genproto', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='google.golang.org/genproto', sum='h1:2X+CNIheCutWRyKRte8szGxrE5ggtV4U+NKAbh/oLhg=', version='v0.0.0-20220211171837-173942840c17')
go_repository(name='org_golang_google_grpc', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='google.golang.org/grpc', sum='h1:weqSxi/TMs1SqFRMHCtBgXRs8k3X39QIDEZ0pRcttUg=', version='v1.44.0')
go_repository(name='org_golang_google_grpc_cmd_protoc_gen_go_grpc', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='google.golang.org/grpc/cmd/protoc-gen-go-grpc', sum='h1:M1YKkFIboKNieVO5DLUEVzQfGwJD30Nv2jfUgzb5UcE=', version='v1.1.0')
go_repository(name='org_golang_google_protobuf', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='google.golang.org/protobuf', sum='h1:SnqbnDw1V7RiZcXPx5MEeqPv2s79L9i7BJUlG/+RurQ=', version='v1.27.1')
go_repository(name='org_golang_x_crypto', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/crypto', sum='h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI=', version='v0.0.0-20200622213623-75b288015ac9')
go_repository(name='org_golang_x_exp', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/exp', sum='h1:QE6XYQK6naiK1EPAe1g/ILLxN5RBoH5xkJk3CqlMI/Y=', version='v0.0.0-20200224162631-6cc2880d07d6')
go_repository(name='org_golang_x_image', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/image', sum='h1:+qEpEAPhDZ1o0x3tHzZTQDArnOixOzGD9HUJfcg0mb4=', version='v0.0.0-20190802002840-cff245a6509b')
go_repository(name='org_golang_x_lint', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/lint', sum='h1:VLliZ0d+/avPrXXH+OakdXhpJuEoBZuwh1m2j7U6Iug=', version='v0.0.0-20210508222113-6edffad5e616')
go_repository(name='org_golang_x_mobile', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/mobile', sum='h1:4+4C/Iv2U4fMZBiMCc98MG1In4gJY5YRhtpDNeDeHWs=', version='v0.0.0-20190719004257-d2bd2a29d028')
go_repository(name='org_golang_x_mod', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/mod', sum='h1:OJxoQ/rynoF0dcCdI7cLPktw/hR2cueqYfjm43oqK38=', version='v0.5.1')
go_repository(name='org_golang_x_net', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/net', sum='h1:O7DYs+zxREGLKzKoMQrtrEacpb0ZVXA5rIwylE2Xchk=', version='v0.0.0-20220127200216-cd36cc0744dd')
go_repository(name='org_golang_x_oauth2', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/oauth2', sum='h1:RerP+noqYHUQ8CMRcPlC2nvTa4dcBIjegkuWdcUDuqg=', version='v0.0.0-20211104180415-d3ed0bb246c8')
go_repository(name='org_golang_x_sync', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/sync', sum='h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ=', version='v0.0.0-20210220032951-036812b2e83c')
go_repository(name='org_golang_x_sys', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/sys', sum='h1:rm+CHSpPEEW2IsXUib1ThaHIjuBVZjxNgSKmBLFfD4c=', version='v0.0.0-20220209214540-3681064d5158')
go_repository(name='org_golang_x_term', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/term', sum='h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY=', version='v0.0.0-20210927222741-03fcf44c2211')
go_repository(name='org_golang_x_text', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/text', sum='h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=', version='v0.3.7')
go_repository(name='org_golang_x_time', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/time', sum='h1:/5xXl8Y5W96D+TtHSlonuFqGHIWVuyCkGJLwGh9JJFs=', version='v0.0.0-20191024005414-555d28b269f0')
go_repository(name='org_golang_x_tools', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/tools', sum='h1:j9KsMiaP1c3B0OTQGth0/k+miLGTgLsAFUCrF2vLcF8=', version='v0.1.9')
go_repository(name='org_golang_x_xerrors', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='golang.org/x/xerrors', sum='h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE=', version='v0.0.0-20200804184101-5ec99f83aff1')
go_repository(name='org_uber_go_atomic', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='go.uber.org/atomic', sum='h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE=', version='v1.9.0')
go_repository(name='org_uber_go_goleak', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='go.uber.org/goleak', sum='h1:wy28qYRKZgnJTxGxvye5/wgWr1EKjmUDGYox5mGlRlI=', version='v1.1.11')
go_repository(name='org_uber_go_multierr', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='go.uber.org/multierr', sum='h1:zaiO/rmgFjbmCXdSYJWQcdvOCsthmdaHfr3Gm2Kx4Ec=', version='v1.7.0')
go_repository(name='org_uber_go_zap', build_extra_args=['-exclude=**/testdata', '-exclude=go/packages/packagestest'], importpath='go.uber.org/zap', sum='h1:WefMeulhovoZ2sYXz7st6K0sLj7bBhpiFaud4r4zST8=', version='v1.21.0') |
def main(shot_name):
# load air shot behind Microbone to Getter NP-10H
info('extracting {}'.format(shot_name))
#for testing just sleep a few seconds
#sleep(5)
# this action blocks until completed
extract_pipette(shot_name)
#isolate microbone
close(description='Microbone to Turbo')
close('C')
#delay to ensure valve is closed and air shot not factionated
sleep(2)
#expand air shot to microbone
#info('equilibrate with microbone')
#open(description='Microbone to Getter NP-10H')
#close('M')
sleep(3)
#isolate microbone ?
#close(description='Microbone to Getter NP-10H')
| def main(shot_name):
info('extracting {}'.format(shot_name))
extract_pipette(shot_name)
close(description='Microbone to Turbo')
close('C')
sleep(2)
sleep(3) |
# Enquete: Utilize o codigo em favorite_language.py
# Crie uma lista de pessoas que devam participar da enquete sobre linguagem favorita. Inclua alguns nomes que ja' estejam no dicionario e outros que nao estao.
# Percorra a lista de pessoas que devem participar da enquete. Se elas ja tiverem respondido `a enquete, mostre uma mensagem agradecendo-lhe por responder. Se ainda nao participaram da enquete, apresente uma mensagem convidando-as a responder.
favorite_languages = {
'jen': 'python',
'sarah': 'c',
'edward': 'ruby',
'phil': 'python',
'chefe': 'javascript',
'edgar': 'php'
}
list_name = ['edgar', 'marcia','jen', 'augusto', 'retirante', 'sarah', 'chefe', 'madalena', 'joao', 'goza-montinho']
for key in list_name:
if key in favorite_languages:
print(f"Muito obrigado por sua resposta, {key}.")
print("=="*20)
elif key not in favorite_languages:
print(f"{key}, por favor, responda a questao.")
print("=="*20) | favorite_languages = {'jen': 'python', 'sarah': 'c', 'edward': 'ruby', 'phil': 'python', 'chefe': 'javascript', 'edgar': 'php'}
list_name = ['edgar', 'marcia', 'jen', 'augusto', 'retirante', 'sarah', 'chefe', 'madalena', 'joao', 'goza-montinho']
for key in list_name:
if key in favorite_languages:
print(f'Muito obrigado por sua resposta, {key}.')
print('==' * 20)
elif key not in favorite_languages:
print(f'{key}, por favor, responda a questao.')
print('==' * 20) |
def reverse_filter( s ):
return s[ ::-1 ]
def string_trim_upper( value ):
return value.strip().upper()
def string_trim_lower( value ):
return value.strip().lower()
def datetimeformat( value, format='%H:%M / %d-%m-%Y' ):
return value.strftime( format )
| def reverse_filter(s):
return s[::-1]
def string_trim_upper(value):
return value.strip().upper()
def string_trim_lower(value):
return value.strip().lower()
def datetimeformat(value, format='%H:%M / %d-%m-%Y'):
return value.strftime(format) |
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
def bazel_sonarqube_repositories(
sonar_scanner_cli_version = "4.5.0.2216",
sonar_scanner_cli_sha256 = "a271a933d14da6e8705d58996d30afd0b4afc93c0bfe957eb377bed808c4fa89"):
http_archive(
name = "org_sonarsource_scanner_cli_sonar_scanner_cli",
build_file = "@bazel_sonarqube//:BUILD.sonar_scanner",
sha256 = sonar_scanner_cli_sha256,
strip_prefix = "sonar-scanner-" + sonar_scanner_cli_version,
urls = [
"https://repo1.maven.org/maven2/org/sonarsource/scanner/cli/sonar-scanner-cli/%s/sonar-scanner-cli-%s.zip" % (sonar_scanner_cli_version, sonar_scanner_cli_version),
"https://jcenter.bintray.com/org/sonarsource/scanner/cli/sonar-scanner-cli/%s/sonar-scanner-cli-%s.zip" % (sonar_scanner_cli_version, sonar_scanner_cli_version),
],
)
| load('@bazel_tools//tools/build_defs/repo:http.bzl', 'http_archive')
def bazel_sonarqube_repositories(sonar_scanner_cli_version='4.5.0.2216', sonar_scanner_cli_sha256='a271a933d14da6e8705d58996d30afd0b4afc93c0bfe957eb377bed808c4fa89'):
http_archive(name='org_sonarsource_scanner_cli_sonar_scanner_cli', build_file='@bazel_sonarqube//:BUILD.sonar_scanner', sha256=sonar_scanner_cli_sha256, strip_prefix='sonar-scanner-' + sonar_scanner_cli_version, urls=['https://repo1.maven.org/maven2/org/sonarsource/scanner/cli/sonar-scanner-cli/%s/sonar-scanner-cli-%s.zip' % (sonar_scanner_cli_version, sonar_scanner_cli_version), 'https://jcenter.bintray.com/org/sonarsource/scanner/cli/sonar-scanner-cli/%s/sonar-scanner-cli-%s.zip' % (sonar_scanner_cli_version, sonar_scanner_cli_version)]) |
rawInstructions = [line.rstrip() for line in open("day12_input.txt")]
instructions=[]
for line in rawInstructions:
instructions.append([line[0], int(line[1:])])
orientations = [[0,1], [1,0], [0,-1], [-1,0]]
position = [0, 0, 1]
def makeMove1(position, instruction):
x = position[0]
y = position[1]
orientation = position[2]
if instruction[0] == "L":
orientation = int((position[2] - instruction[1] / 90) % 4)
if instruction[0] == "R":
orientation = int((position[2] + instruction[1] / 90) % 4)
if instruction[0] == "F":
x += instruction[1] * orientations[orientation][0]
y += instruction[1] * orientations[orientation][1]
if instruction[0] == "N":
y += instruction[1]
if instruction[0] == "E":
x += instruction[1]
if instruction[0] == "S":
y -= instruction[1]
if instruction[0] == "W":
x -= instruction[1]
return([x,y, orientation])
for line in instructions:
print(line)
position = makeMove1(position, line)
position2 = [0,0,1,10,1]
ccw_rotate = {1: lambda x, y: (-y, x),
2: lambda x, y: (-x, -y),
3: lambda x, y: (y, -x)}
cw_rotate = {1: lambda x, y: (y, -x),
2: lambda x, y: (-x, -y),
3: lambda x, y: (-y, x)}
def makeMove2(position, instruction):
x = position2[0]
y = position2[1]
orientation = position2[2]
neworientation = orientation
x1 = position2[3]
y1 = position2[4]
if instruction[0] == "L":
x1, y1 = ccw_rotate.get(int(instruction[1] / 90))(x1,y1)
if instruction[0] == "R":
x1, y1 = cw_rotate.get(int(instruction[1] / 90))(x1,y1)
if instruction[0] == "F":
x += instruction[1] * x1
y += instruction[1] * y1
if instruction[0] == "N":
y1 += instruction[1]
if instruction[0] == "E":
x1 += instruction[1]
if instruction[0] == "S":
y1 -= instruction[1]
if instruction[0] == "W":
x1 -= instruction[1]
return([x,y, neworientation, x1, y1])
for line in instructions:
print(line)
position2 = makeMove2(position2, line)
print("Manhattan position 1 is: "+ str(abs(position[0])+abs(position[1])))
print("Manhattan position 2 is: "+ str(abs(position2[0])+abs(position2[1]))) | raw_instructions = [line.rstrip() for line in open('day12_input.txt')]
instructions = []
for line in rawInstructions:
instructions.append([line[0], int(line[1:])])
orientations = [[0, 1], [1, 0], [0, -1], [-1, 0]]
position = [0, 0, 1]
def make_move1(position, instruction):
x = position[0]
y = position[1]
orientation = position[2]
if instruction[0] == 'L':
orientation = int((position[2] - instruction[1] / 90) % 4)
if instruction[0] == 'R':
orientation = int((position[2] + instruction[1] / 90) % 4)
if instruction[0] == 'F':
x += instruction[1] * orientations[orientation][0]
y += instruction[1] * orientations[orientation][1]
if instruction[0] == 'N':
y += instruction[1]
if instruction[0] == 'E':
x += instruction[1]
if instruction[0] == 'S':
y -= instruction[1]
if instruction[0] == 'W':
x -= instruction[1]
return [x, y, orientation]
for line in instructions:
print(line)
position = make_move1(position, line)
position2 = [0, 0, 1, 10, 1]
ccw_rotate = {1: lambda x, y: (-y, x), 2: lambda x, y: (-x, -y), 3: lambda x, y: (y, -x)}
cw_rotate = {1: lambda x, y: (y, -x), 2: lambda x, y: (-x, -y), 3: lambda x, y: (-y, x)}
def make_move2(position, instruction):
x = position2[0]
y = position2[1]
orientation = position2[2]
neworientation = orientation
x1 = position2[3]
y1 = position2[4]
if instruction[0] == 'L':
(x1, y1) = ccw_rotate.get(int(instruction[1] / 90))(x1, y1)
if instruction[0] == 'R':
(x1, y1) = cw_rotate.get(int(instruction[1] / 90))(x1, y1)
if instruction[0] == 'F':
x += instruction[1] * x1
y += instruction[1] * y1
if instruction[0] == 'N':
y1 += instruction[1]
if instruction[0] == 'E':
x1 += instruction[1]
if instruction[0] == 'S':
y1 -= instruction[1]
if instruction[0] == 'W':
x1 -= instruction[1]
return [x, y, neworientation, x1, y1]
for line in instructions:
print(line)
position2 = make_move2(position2, line)
print('Manhattan position 1 is: ' + str(abs(position[0]) + abs(position[1])))
print('Manhattan position 2 is: ' + str(abs(position2[0]) + abs(position2[1]))) |
class DebugHeaders(object):
# List of headers we want to display
header_filter = (
'CONTENT_TYPE',
'HTTP_ACCEPT',
'HTTP_ACCEPT_CHARSET',
'HTTP_ACCEPT_ENCODING',
'HTTP_ACCEPT_LANGUAGE',
'HTTP_CACHE_CONTROL',
'HTTP_CONNECTION',
'HTTP_HOST',
'HTTP_KEEP_ALIVE',
'HTTP_REFERER',
'HTTP_USER_AGENT',
'QUERY_STRING',
'REMOTE_ADDR',
'REMOTE_HOST',
'REQUEST_METHOD',
'SCRIPT_NAME',
'SERVER_NAME',
'SERVER_PORT',
'SERVER_PROTOCOL',
'SERVER_SOFTWARE',
)
def available_headers(self, request):
return dict(
[(k, v) for k, v in request.META.items() if k in self.header_filter]
)
| class Debugheaders(object):
header_filter = ('CONTENT_TYPE', 'HTTP_ACCEPT', 'HTTP_ACCEPT_CHARSET', 'HTTP_ACCEPT_ENCODING', 'HTTP_ACCEPT_LANGUAGE', 'HTTP_CACHE_CONTROL', 'HTTP_CONNECTION', 'HTTP_HOST', 'HTTP_KEEP_ALIVE', 'HTTP_REFERER', 'HTTP_USER_AGENT', 'QUERY_STRING', 'REMOTE_ADDR', 'REMOTE_HOST', 'REQUEST_METHOD', 'SCRIPT_NAME', 'SERVER_NAME', 'SERVER_PORT', 'SERVER_PROTOCOL', 'SERVER_SOFTWARE')
def available_headers(self, request):
return dict([(k, v) for (k, v) in request.META.items() if k in self.header_filter]) |
"""
Demonstration #2
Given a non-empty array of integers `nums`, every element appears twice except except for one. Write a function that finds the element that only appears once.
Examples:
- single_number([3,3,2]) -> 2
- single_number([5,2,3,2,3]) -> 5
- single_number([10]) -> 10
"""
def single_number(nums):
# Your code here
counts = {}
for num in nums:
if num not in counts:
counts[num] = 1
else:
counts[num] += 1
print(counts)
# loop over the dict
for key, value in counts.items():
if value == 1:
return key
# for num in nums:
# #for each num count the nums in array
# count = nums.count(num)
# if count == 1:
# return num
print(single_number([3, 3, 2]))
print(single_number([5, 2, 3, 2, 3]))
print(single_number([10]))
# UPER
# input = array of len > 0 all nums
# output = a single_number
# it appears once
# is a number form the array
# PLAN
# -brute force = valid solutions
| """
Demonstration #2
Given a non-empty array of integers `nums`, every element appears twice except except for one. Write a function that finds the element that only appears once.
Examples:
- single_number([3,3,2]) -> 2
- single_number([5,2,3,2,3]) -> 5
- single_number([10]) -> 10
"""
def single_number(nums):
counts = {}
for num in nums:
if num not in counts:
counts[num] = 1
else:
counts[num] += 1
print(counts)
for (key, value) in counts.items():
if value == 1:
return key
print(single_number([3, 3, 2]))
print(single_number([5, 2, 3, 2, 3]))
print(single_number([10])) |
class Solution:
def plusOne(self, digits: 'List[int]') -> 'List[int]':
fl = 1
for i in range(len(digits)-1,-1,-1):
if digits[i] == 9 and fl == 1:
fl = 1
digits[i] = 0
else:
digits[i] += 1
fl = 0
break
if (fl):
digits.insert(0,1)
return digits
| class Solution:
def plus_one(self, digits: 'List[int]') -> 'List[int]':
fl = 1
for i in range(len(digits) - 1, -1, -1):
if digits[i] == 9 and fl == 1:
fl = 1
digits[i] = 0
else:
digits[i] += 1
fl = 0
break
if fl:
digits.insert(0, 1)
return digits |
dictionary = {
"CSS": "101",
"Python": ["101", "201", "301"]
}
print(dictionary.get("CSS", None))
print(dictionary.get("HTML", None)) | dictionary = {'CSS': '101', 'Python': ['101', '201', '301']}
print(dictionary.get('CSS', None))
print(dictionary.get('HTML', None)) |
# edit the following parameters which control the benchmark
mincpus = 16
maxcpus = 128
nsteps_cpus = 6
multigpu = (1,2,3,)
multithread = (1,2,4,8)
multithread = (8,)
multithread_gpu = (42,)
if (maxcpus < max(multigpu)):
raise ValueError('increase the number of processors')
systems = ['interface','lj']
runconfig = ['cpu-opt', 'cpu-omp','cpu-kokkos','cpu-kokkos-omp','cuda-kokkos','cuda-gpu', 'cuda-kokkos-omp', 'cuda-gpu-omp', 'cpu-bare']
excludeSystems = ['interface']
excludeSystemCompilerPairs = []
# this are fixed parameters
singlethread =(1,)
zerogpu = (0,)
threads = {
'cpu-bare' : singlethread,
'cpu-opt' : singlethread,
'cpu-omp' : multithread,
'cpu-kokkos' : singlethread,
'cpu-kokkos-omp' : multithread,
'cuda-gpu' : singlethread,
'cuda-kokkos' : singlethread,
'cuda-gpu-omp' : multithread_gpu,
'cuda-kokkos-omp' : multithread_gpu,
}
gpus = {
'cpu-bare' : zerogpu,
'cpu-opt' : zerogpu,
'cpu-omp' : zerogpu,
'cpu-kokkos' : zerogpu,
'cpu-kokkos-omp' : zerogpu,
'cuda-gpu' : multigpu,
'cuda-kokkos' : multigpu,
'cuda-gpu-omp' : multigpu,
'cuda-kokkos-omp' : multigpu,
}
# list of available versions, toolchan descriptoirs and modules
compilations = {
'29Sep2021': {
'foss-2020b-cuda-kokkos' :'GCC/10.2.0 CUDA/11.1.1 OpenMPI/4.0.5 LAMMPS/29Sep2021-CUDA-11.1.1-kokkos-omp',
'foss-2020b-cuda-kokkos-omp' :'GCC/10.2.0 CUDA/11.1.1 OpenMPI/4.0.5 LAMMPS/29Sep2021-CUDA-11.1.1-kokkos-omp',
'foss-2020b-cuda-gpu' :'GCC/10.2.0 CUDA/11.1.1 OpenMPI/4.0.5 LAMMPS/29Sep2021-CUDA-11.1.1-gpu',
'foss-2021b-cuda-kokkos' :'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-CUDA-11.4.1-kokkos-omp',
'foss-2021b-cuda-kokkos-omp' :'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-CUDA-11.4.1-kokkos-omp',
'foss-2021b-cuda-gpu' :'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-CUDA-11.4.1-gpu',
'foss-2020b-kokkos' :'GCC/10.2.0 OpenMPI/4.0.5 LAMMPS/29Sep2021-kokkos',
'foss-2021b-kokkos' :'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-kokkos',
'iomkl-2019b-kokkos' :'iccifort/2019.5.281 OpenMPI/3.1.4 LAMMPS/29Sep2021-kokkos',
'foss-2020b-kokkos-omp' :'GCC/10.2.0 OpenMPI/4.0.5 LAMMPS/29Sep2021-kokkos-omp',
'foss-2021b-kokkos-omp' :'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-kokkos-omp',
'iomkl-2019b-kokkos-omp' :'iccifort/2019.5.281 OpenMPI/3.1.4 LAMMPS/29Sep2021-kokkos-omp'
},
'3Mar2020': {
'foss-2020a-kokkos' :'GCC/9.3.0 OpenMPI/4.0.3 LAMMPS/3Mar2020-Python-3.8.2-kokkos',
'foss-2020a-kokkos-omp' :'GCC/9.3.0 OpenMPI/4.0.3 LAMMPS/3Mar2020-Python-3.8.2-kokkos-omp',
}
}
| mincpus = 16
maxcpus = 128
nsteps_cpus = 6
multigpu = (1, 2, 3)
multithread = (1, 2, 4, 8)
multithread = (8,)
multithread_gpu = (42,)
if maxcpus < max(multigpu):
raise value_error('increase the number of processors')
systems = ['interface', 'lj']
runconfig = ['cpu-opt', 'cpu-omp', 'cpu-kokkos', 'cpu-kokkos-omp', 'cuda-kokkos', 'cuda-gpu', 'cuda-kokkos-omp', 'cuda-gpu-omp', 'cpu-bare']
exclude_systems = ['interface']
exclude_system_compiler_pairs = []
singlethread = (1,)
zerogpu = (0,)
threads = {'cpu-bare': singlethread, 'cpu-opt': singlethread, 'cpu-omp': multithread, 'cpu-kokkos': singlethread, 'cpu-kokkos-omp': multithread, 'cuda-gpu': singlethread, 'cuda-kokkos': singlethread, 'cuda-gpu-omp': multithread_gpu, 'cuda-kokkos-omp': multithread_gpu}
gpus = {'cpu-bare': zerogpu, 'cpu-opt': zerogpu, 'cpu-omp': zerogpu, 'cpu-kokkos': zerogpu, 'cpu-kokkos-omp': zerogpu, 'cuda-gpu': multigpu, 'cuda-kokkos': multigpu, 'cuda-gpu-omp': multigpu, 'cuda-kokkos-omp': multigpu}
compilations = {'29Sep2021': {'foss-2020b-cuda-kokkos': 'GCC/10.2.0 CUDA/11.1.1 OpenMPI/4.0.5 LAMMPS/29Sep2021-CUDA-11.1.1-kokkos-omp', 'foss-2020b-cuda-kokkos-omp': 'GCC/10.2.0 CUDA/11.1.1 OpenMPI/4.0.5 LAMMPS/29Sep2021-CUDA-11.1.1-kokkos-omp', 'foss-2020b-cuda-gpu': 'GCC/10.2.0 CUDA/11.1.1 OpenMPI/4.0.5 LAMMPS/29Sep2021-CUDA-11.1.1-gpu', 'foss-2021b-cuda-kokkos': 'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-CUDA-11.4.1-kokkos-omp', 'foss-2021b-cuda-kokkos-omp': 'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-CUDA-11.4.1-kokkos-omp', 'foss-2021b-cuda-gpu': 'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-CUDA-11.4.1-gpu', 'foss-2020b-kokkos': 'GCC/10.2.0 OpenMPI/4.0.5 LAMMPS/29Sep2021-kokkos', 'foss-2021b-kokkos': 'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-kokkos', 'iomkl-2019b-kokkos': 'iccifort/2019.5.281 OpenMPI/3.1.4 LAMMPS/29Sep2021-kokkos', 'foss-2020b-kokkos-omp': 'GCC/10.2.0 OpenMPI/4.0.5 LAMMPS/29Sep2021-kokkos-omp', 'foss-2021b-kokkos-omp': 'GCC/11.2.0 OpenMPI/4.1.1 LAMMPS/29Sep2021-kokkos-omp', 'iomkl-2019b-kokkos-omp': 'iccifort/2019.5.281 OpenMPI/3.1.4 LAMMPS/29Sep2021-kokkos-omp'}, '3Mar2020': {'foss-2020a-kokkos': 'GCC/9.3.0 OpenMPI/4.0.3 LAMMPS/3Mar2020-Python-3.8.2-kokkos', 'foss-2020a-kokkos-omp': 'GCC/9.3.0 OpenMPI/4.0.3 LAMMPS/3Mar2020-Python-3.8.2-kokkos-omp'}} |
''' This file is a lookup table for The OpenQASM instructions '''
''' Ref: https://github.com/qevedo/openqasm/tree/master/src/libs '''
''' Tutorial: https://quantum-computing.ibm.com/docs/iqx/operations-glossary '''
''' TODO:
1. we should have a simple exclude/include mechanism for this colleciton so that one can easily
mix and match various instructions that are available to the GA search space
'''
"""
the commands are organized as such:
<string>: name of command
followed by an array of ints representing: [<input> <arguments>]
Examples:
U3(theta, phi, lambda) q -- 1 input (q), 3 arguments (theta, phi, lambda)
x a -- 1 input (a), 0 argument
"""
'''
Note that q should be in the form of q[0], q[1], etc.
'''
COMMANDS = {
#TODO: think about the 'c' control gate, and 'if' operation (if (c==0) x q[0];)
###############################################################################
# Obsolete gates
#u3 is obsolete and is now the u gate
#"u3": [1, 3], #U(theta,phi,lambda) q; - u3(theta, phi, lam) q[0]; // theta, phi, lam = arguments, default is pi/2, q[0] = input
#"u2": [1, 2], #U(phi/2, lambda) q; - u2(theta, phi) q[0]; // theta phi = arguments, defualt is pi/2, q[0] = input
#u1 is obsolete and is now the phase gate
#"u1": [1, 1], #U(0,0,lambda) q; - u1 (theta) q[0]; // theta = argument, default is pi/2, q[0] = input
# "id": [1, 0], #idle gate // OBSOLETE!
#"u0": [1, 1], #idle gate with length gamma *sqglen // ERROR!
#"cz": [2, 0], #controlled-Phase - cz q[0], q[1];
#"cy": [2, 0], #controlled-Y - cy q[0], q[1];
#"ch": [2, 0], #controlled H; ch q[0], q[1];
#"cswap":[3, 0], #cswap - cswap q[0], q[1], q[2];
#"crx": [2, 1], #controlled rx rotation - crx(angle) q[0], q[1]; // angle is argument, default: pi/2
#"cry": [2, 1], #controlled ry rotation - same as above
#"crz": [2, 1], #controlled rz rotation - same as above
#"cu1": [2, 1], #controlled phase rotation - cu1(angle) q[0], q[1]; // angle is arugment, default: pi/2
#"cu3": [2, 3], #cu3(alpha1, alpha2, alpha3) q[0], q[1]; // same as above
#"u0": [1, 0], #UNKNOWN (??)
###############################################################################
#0
"u": [1, 3], #u(theta, phi lam) q[0]; replaces u3, u2, cu3
"p": [1, 1], #phase gate - this replaces u1, cu1
"cx": [2, 0], #controlled NOT - cx q[0] q[1];
"x": [1, 0], #Pauli gate: bit-flip: x q[0]
"y": [1, 0], #Pauli gate: bit and phase flip - y q[0];
#6
"z": [1, 0], #Pauli gate: phase flip - z q[0];
"h": [1, 0], #Clifford gate: Hadamard - h q[0];
"s": [1, 0], #Clifford gate: sqrt(Z) phase gate - s q[0];
"sdg": [1, 0], #Clifford gate: conjugate of sqrt(Z) - sdg q[0];
"t": [1, 0], #C3 gate: sqrt(S) phase gate - t q[0];
#11
"tdg": [1, 0], #C3 gate: conjugate of sqrt(S) - tdg q[0];
#standard rotations
"rx": [1, 1], #Rotation around X-axis - rx(angle) q[0]; angle is argument, default: pi/2, q[0] is input
"ry": [1, 1], #rotation around Y-axis - ry(angle) q[0]; same as above
"rz": [1, 1], #rotation around Z-axis - rz(angle) q[0]; same as above
#QE Standard User-Defined Gates
"swap": [2, 0], #swap - swap q[0], q[1]
#16
"ccx": [3, 0], #toffoli ccx q[0], q[1], q[2];
"rxx": [2, 1], #molmer-sorensen gate - rxx(angle) q[0], q[1];
"rzz": [2, 1], #two-qubit ZZ rotation - rzz(angle) q[0], q[1];
"sx": [1, 0], #square root not gate - sx q[0];
"sxdg": [1, 0], #square root not dagger gate - sxdg q[0];
##### unimplemented
# barrier q;
# reset q[0];
# if (c==0) x q[0]; // c is a classic register
# measure q[0];
}
"""
OBSOLETE:
COMMANDSARRAY = [
"u3","u2","u1","cx",
#"id",
"u0","x","y","z","h","s","sdg","t","tgd","rx",
"ry","rz","cz","cy","swap","ch","ccx","cswap","crz","cu1","cu3","rzz",
]
"""
| """ This file is a lookup table for The OpenQASM instructions """
' Ref: https://github.com/qevedo/openqasm/tree/master/src/libs '
' Tutorial: https://quantum-computing.ibm.com/docs/iqx/operations-glossary '
' TODO:\n 1. we should have a simple exclude/include mechanism for this colleciton so that one can easily\n mix and match various instructions that are available to the GA search space\n'
'\nthe commands are organized as such:\n <string>: name of command\n followed by an array of ints representing: [<input> <arguments>]\n Examples: \n U3(theta, phi, lambda) q -- 1 input (q), 3 arguments (theta, phi, lambda)\n x a -- 1 input (a), 0 argument \n'
'\nNote that q should be in the form of q[0], q[1], etc. \n'
commands = {'u': [1, 3], 'p': [1, 1], 'cx': [2, 0], 'x': [1, 0], 'y': [1, 0], 'z': [1, 0], 'h': [1, 0], 's': [1, 0], 'sdg': [1, 0], 't': [1, 0], 'tdg': [1, 0], 'rx': [1, 1], 'ry': [1, 1], 'rz': [1, 1], 'swap': [2, 0], 'ccx': [3, 0], 'rxx': [2, 1], 'rzz': [2, 1], 'sx': [1, 0], 'sxdg': [1, 0]}
'\nOBSOLETE:\nCOMMANDSARRAY = [\n "u3","u2","u1","cx",\n #"id",\n "u0","x","y","z","h","s","sdg","t","tgd","rx",\n "ry","rz","cz","cy","swap","ch","ccx","cswap","crz","cu1","cu3","rzz",\n]\n' |
values = {
frozenset(("hardQuotaSize=1", "id=1", "hardQuotaUnit=TB")): {
"status_code": "200",
"text": {
"responseData": {},
"responseHeader": {
"now": 1492551097041,
"requestId": "WPaFuAoQgF4AADVcf4kAAAAz",
"status": "ok",
},
"responseStatus": "ok",
},
},
frozenset(("hardQuotaSize=1", "id=2", "hardQuotaUnit=TB")): {
"status_code": "400",
"text": {
"responseData": {},
"responseHeader": {
"now": 1492551097041,
"requestId": "WPaFuAoQgF4AADVcf4kAAAAz",
"status": "ok",
},
"responseStatus": "ok",
},
},
}
| values = {frozenset(('hardQuotaSize=1', 'id=1', 'hardQuotaUnit=TB')): {'status_code': '200', 'text': {'responseData': {}, 'responseHeader': {'now': 1492551097041, 'requestId': 'WPaFuAoQgF4AADVcf4kAAAAz', 'status': 'ok'}, 'responseStatus': 'ok'}}, frozenset(('hardQuotaSize=1', 'id=2', 'hardQuotaUnit=TB')): {'status_code': '400', 'text': {'responseData': {}, 'responseHeader': {'now': 1492551097041, 'requestId': 'WPaFuAoQgF4AADVcf4kAAAAz', 'status': 'ok'}, 'responseStatus': 'ok'}}} |
#
# Copyright (c) 2011 Daniel Truemper truemped@googlemail.com
#
# sink.py 02-Feb-2011
#
# 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.
#
"""
A sink of :class:`CrawlUri`.
"""
class AbstractCrawlUriSink(object):
"""
Abstract sink. Only overwrite the methods you are interested in.
"""
def process_successful_crawl(self, curi):
"""
We have crawled a uri successfully. If there are newly extracted links,
add them alongside the original uri to the frontier.
"""
pass
def process_not_found(self, curi):
"""
The uri we should have crawled was not found, i.e. HTTP Error 404. Do
something with that.
"""
pass
def process_redirect(self, curi):
"""
There have been too many redirects, i.e. in the default config there
have been more than 3 redirects.
"""
pass
def process_server_error(self, curi):
"""
There has been a server error, i.e. HTTP Error 50x. Maybe we should try
to crawl this uri again a little bit later.
"""
pass
| """
A sink of :class:`CrawlUri`.
"""
class Abstractcrawlurisink(object):
"""
Abstract sink. Only overwrite the methods you are interested in.
"""
def process_successful_crawl(self, curi):
"""
We have crawled a uri successfully. If there are newly extracted links,
add them alongside the original uri to the frontier.
"""
pass
def process_not_found(self, curi):
"""
The uri we should have crawled was not found, i.e. HTTP Error 404. Do
something with that.
"""
pass
def process_redirect(self, curi):
"""
There have been too many redirects, i.e. in the default config there
have been more than 3 redirects.
"""
pass
def process_server_error(self, curi):
"""
There has been a server error, i.e. HTTP Error 50x. Maybe we should try
to crawl this uri again a little bit later.
"""
pass |
input_file = __file__.split("/")
input_file[-1] = "input.txt"
with open("/".join(input_file)) as f:
actions = [entry.strip().split() for entry in f]
curr_aim = curr_depth = curr_horiz = 0
for direction, num in actions:
if direction in {"up", "down"}:
aim_change = int(num) if direction == "down" else int(num) * -1
curr_aim += aim_change
else:
curr_horiz += int(num)
curr_depth += (curr_aim) * int(num)
print(f"Part one: {curr_aim * curr_horiz}")
print(f"Part two: {curr_depth * curr_horiz}")
| input_file = __file__.split('/')
input_file[-1] = 'input.txt'
with open('/'.join(input_file)) as f:
actions = [entry.strip().split() for entry in f]
curr_aim = curr_depth = curr_horiz = 0
for (direction, num) in actions:
if direction in {'up', 'down'}:
aim_change = int(num) if direction == 'down' else int(num) * -1
curr_aim += aim_change
else:
curr_horiz += int(num)
curr_depth += curr_aim * int(num)
print(f'Part one: {curr_aim * curr_horiz}')
print(f'Part two: {curr_depth * curr_horiz}') |
__author__ = 'hvishwanath'
class CAMPModel(object):
def __init__(self):
pass
class Artifact(CAMPModel):
def __init__(self, atype, content, requirements):
self.type = atype
self.content = content
self.requirements = requirements
@classmethod
def create_from_dict(cls, d):
atype = d.get("artifact_type", None)
if "content" in d:
content = Content.create_from_dict(d.get("content"))
else:
content = None
if "requirements" in d:
requirements = []
reqs = d.get("requirements")
for r in reqs:
requirements.append(Requirement.create_from_dict(r))
else:
requirements = None
return Artifact(atype, content, requirements)
def __repr__(self):
return self.__str__()
def __str__(self):
msg = """
Artifact. Type: %s.
Requirements :
--------------
%s
"""
rm = []
for r in self.requirements:
rm.append(str(r))
return msg % (self.type, "\n\t".join(rm))
class Content(CAMPModel):
def __init__(self, href):
self.href = href
@classmethod
def create_from_dict(cls, d):
href = d.get("href", None)
return Content(href)
def __repr__(self):
return self.__str__()
def __str__(self):
return "<Content. href: %s>" % self.href
class Requirement(CAMPModel):
def __init__(self, rtype, options, fulfillment):
self.type = rtype
self.options = options
self.fulfillment = fulfillment
@classmethod
def create_from_dict(cls, d):
rtype = d.get("requirement_type")
d.pop("requirement_type")
options = d
return Requirement(rtype, options, None)
def __repr__(self):
return self.__str__()
def __str__(self):
return "Requirement. \n\tType: %s, \n\toptions: %s\n" % (self.type, self.options)
class Fulfillment(CAMPModel):
def __init__(self, options, fid, characteristics):
self.options = options
self.id = fid
self.characteristics = characteristics
@classmethod
def create_from_dict(cls, d):
pass
class Characteristic(CAMPModel):
def __init__(self, ctype, options):
self.type = ctype
self.options = options
@classmethod
def create_from_dict(cls, d):
pass
class Service(CAMPModel):
def __init__(self, sid, characteristics):
self.id = sid
self.characteristics = characteristics
@classmethod
def create_from_dict(cls, d):
pass
class CAMPPlan(CAMPModel):
def __init__(self, version, name, description, tags, artifacts=[], services=[]):
self.version = version
self.name = name
self.description = description
self.tags = tags
self.artifacts = artifacts
self.services = services
@classmethod
def create_from_dict(cls, d):
version = d.get("camp_version", "1.0")
name = d.get("name")
description = d.get("description")
tags = d.get("tags")
artifacts = []
services = []
if "artifacts" in d:
for a in d.get("artifacts"):
artifacts.append(Artifact.create_from_dict(a))
return CAMPPlan(version, name, description, tags, artifacts, services)
def __repr__(self):
return self.__str__()
def __str__(self):
msg = """
Plan:
-----
Name: %s
Description : %s
Artifacts:
---------
%s
Services:
----------
%s
"""
am = []
for a in self.artifacts:
am.append(str(a))
sm = []
for s in self.services:
sm.append(str(s))
return msg % (self.name, self.description, "\n\t".join(am), "\n\t".join(sm))
| __author__ = 'hvishwanath'
class Campmodel(object):
def __init__(self):
pass
class Artifact(CAMPModel):
def __init__(self, atype, content, requirements):
self.type = atype
self.content = content
self.requirements = requirements
@classmethod
def create_from_dict(cls, d):
atype = d.get('artifact_type', None)
if 'content' in d:
content = Content.create_from_dict(d.get('content'))
else:
content = None
if 'requirements' in d:
requirements = []
reqs = d.get('requirements')
for r in reqs:
requirements.append(Requirement.create_from_dict(r))
else:
requirements = None
return artifact(atype, content, requirements)
def __repr__(self):
return self.__str__()
def __str__(self):
msg = '\n\n Artifact. Type: %s.\n Requirements :\n --------------\n %s\n\n '
rm = []
for r in self.requirements:
rm.append(str(r))
return msg % (self.type, '\n\t'.join(rm))
class Content(CAMPModel):
def __init__(self, href):
self.href = href
@classmethod
def create_from_dict(cls, d):
href = d.get('href', None)
return content(href)
def __repr__(self):
return self.__str__()
def __str__(self):
return '<Content. href: %s>' % self.href
class Requirement(CAMPModel):
def __init__(self, rtype, options, fulfillment):
self.type = rtype
self.options = options
self.fulfillment = fulfillment
@classmethod
def create_from_dict(cls, d):
rtype = d.get('requirement_type')
d.pop('requirement_type')
options = d
return requirement(rtype, options, None)
def __repr__(self):
return self.__str__()
def __str__(self):
return 'Requirement. \n\tType: %s, \n\toptions: %s\n' % (self.type, self.options)
class Fulfillment(CAMPModel):
def __init__(self, options, fid, characteristics):
self.options = options
self.id = fid
self.characteristics = characteristics
@classmethod
def create_from_dict(cls, d):
pass
class Characteristic(CAMPModel):
def __init__(self, ctype, options):
self.type = ctype
self.options = options
@classmethod
def create_from_dict(cls, d):
pass
class Service(CAMPModel):
def __init__(self, sid, characteristics):
self.id = sid
self.characteristics = characteristics
@classmethod
def create_from_dict(cls, d):
pass
class Campplan(CAMPModel):
def __init__(self, version, name, description, tags, artifacts=[], services=[]):
self.version = version
self.name = name
self.description = description
self.tags = tags
self.artifacts = artifacts
self.services = services
@classmethod
def create_from_dict(cls, d):
version = d.get('camp_version', '1.0')
name = d.get('name')
description = d.get('description')
tags = d.get('tags')
artifacts = []
services = []
if 'artifacts' in d:
for a in d.get('artifacts'):
artifacts.append(Artifact.create_from_dict(a))
return camp_plan(version, name, description, tags, artifacts, services)
def __repr__(self):
return self.__str__()
def __str__(self):
msg = '\n Plan:\n -----\n Name: %s\n Description : %s\n\n Artifacts:\n ---------\n %s\n\n Services:\n ----------\n %s\n '
am = []
for a in self.artifacts:
am.append(str(a))
sm = []
for s in self.services:
sm.append(str(s))
return msg % (self.name, self.description, '\n\t'.join(am), '\n\t'.join(sm)) |
# To merge 2 array into a third array.
arr1 = []
arr2 = []
arr = []
n=int(input())
for i in range(0,n):
arr1.append(int(input()))
m=int(input())
for i in range(0,m):
arr2.append(int(input()))
"""
for i in range(0,n):
arr.append(arr1[i])
for i in range(0,m):
arr.append(arr2[i])
"""
arr = arr1 + arr2
print("Mergerd array arr[", m+n, "] : ")
for i in range(0,n+m):
print(arr[i], end=" ")
| arr1 = []
arr2 = []
arr = []
n = int(input())
for i in range(0, n):
arr1.append(int(input()))
m = int(input())
for i in range(0, m):
arr2.append(int(input()))
'\nfor i in range(0,n):\n arr.append(arr1[i])\nfor i in range(0,m):\n arr.append(arr2[i])\n '
arr = arr1 + arr2
print('Mergerd array arr[', m + n, '] : ')
for i in range(0, n + m):
print(arr[i], end=' ') |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.