content stringlengths 7 1.05M | fixed_cases stringlengths 1 1.28M |
|---|---|
#!/usr/bin/env python
# coding: utf-8
# In[2]:
def utopianTree(cycles):
h=1
for cyc_no in range(cycles):
if (cyc_no%2==0):
h=h*2
elif (cyc_no):
h+=1
return h
if __name__=='__main__':
n=int(input())
for itr in range(n):
cycles=int(input())
print(utopianTree(cycles))
# In[ ]:
| def utopian_tree(cycles):
h = 1
for cyc_no in range(cycles):
if cyc_no % 2 == 0:
h = h * 2
elif cyc_no:
h += 1
return h
if __name__ == '__main__':
n = int(input())
for itr in range(n):
cycles = int(input())
print(utopian_tree(cycles)) |
def divisors(integer):
aux = [i for i in range(2, integer) if integer % i == 0]
if len(aux) == 0:
return "{} is prime".format(integer)
else:
return aux | def divisors(integer):
aux = [i for i in range(2, integer) if integer % i == 0]
if len(aux) == 0:
return '{} is prime'.format(integer)
else:
return aux |
# coding: utf-8
pyslim_version = '0.700'
slim_file_version = '0.7'
# other file versions that require no modification
compatible_slim_file_versions = ['0.7']
| pyslim_version = '0.700'
slim_file_version = '0.7'
compatible_slim_file_versions = ['0.7'] |
def format_as_vsys(amount):
abs_amount = abs(amount)
whole = int(abs_amount / 100000000)
fraction = abs_amount % 100000000
if amount < 0:
whole *= -1
return f'{whole}.{str(fraction).rjust(8, "0")}'
| def format_as_vsys(amount):
abs_amount = abs(amount)
whole = int(abs_amount / 100000000)
fraction = abs_amount % 100000000
if amount < 0:
whole *= -1
return f"{whole}.{str(fraction).rjust(8, '0')}" |
class Solution:
def canVisitAllRooms(self, rooms):
stack = [0]
visited = set(stack)
while stack:
curr = stack.pop()
for room in rooms[curr]:
if room not in visited:
stack.append(room)
visited.add(room)
if len(visited) == len(rooms): return True
return len(visited) == len(rooms) | class Solution:
def can_visit_all_rooms(self, rooms):
stack = [0]
visited = set(stack)
while stack:
curr = stack.pop()
for room in rooms[curr]:
if room not in visited:
stack.append(room)
visited.add(room)
if len(visited) == len(rooms):
return True
return len(visited) == len(rooms) |
__author__ = 'spersinger'
class Configuration:
@staticmethod
def run():
Configuration.enforce_ttl = True
Configuration.ttl = 60
Configuration.run()
| __author__ = 'spersinger'
class Configuration:
@staticmethod
def run():
Configuration.enforce_ttl = True
Configuration.ttl = 60
Configuration.run() |
#####
# https://github.com/sushiswap/sushiswap-subgraph
# https://dev.sushi.com/api/overview
# https://github.com/sushiswap/sushiswap-analytics/blob/c6919d56523b4418d174224a6b8964982f2a7948/src/core/api/index.js
# CP_API_TOKEN = os.environ.get("cp_api_token")
#"https://gateway.thegraph.com/api/c8eae2e5ac9d2e9d5d5459c33fe7b1eb/subgraphs/id/0x4bb4c1b0745ef7b4642feeccd0740dec417ca0a0-0"
# "https://thegraph.com/legacy-explorer/subgraph/sushiswap/exchange"
#####
url = {
"sushiexchange" : "https://api.thegraph.com/subgraphs/name/sushiswap/exchange",
"sushibar" : "https://api.thegraph.com/subgraphs/name/matthewlilley/bar",
"aave" : "https://api.thegraph.com/subgraphs/name/aave/protocol-v2"
}
| url = {'sushiexchange': 'https://api.thegraph.com/subgraphs/name/sushiswap/exchange', 'sushibar': 'https://api.thegraph.com/subgraphs/name/matthewlilley/bar', 'aave': 'https://api.thegraph.com/subgraphs/name/aave/protocol-v2'} |
# -*- coding: utf-8 -*-
commands = {
'start_AfterAuthorized':
u'Welcome to remoteSsh_bot\n\n'
u'If you known password - use /on\n'
u'else - connect to admin',
'start_BeforeAuthorized':
u'Hello!\n'
u'If you want information about this bot - use /information\n'
u'If you want command list - use /help',
'help_AfterAuthorized':
u'If you known password - use /on\n'
u'else - connect to admin',
'help_BeforeAuthorized':
u'Command:\n'
u'/off - disconnect from bot\n'
u'/setsshUser - Set ssh user and ssh password\n'
u'/setsshHost - Set host(IP) for ssh connection\n'
u'/information - Show information, about ssh-connection\n'
u'/aboutBot - Information about bot and author\n',
'aboutBot': 'Author GitHub - https://github.com/vzemtsov\n'
u'Please write wishes to improve this bot',
} | commands = {'start_AfterAuthorized': u'Welcome to remoteSsh_bot\n\nIf you known password - use /on\nelse - connect to admin', 'start_BeforeAuthorized': u'Hello!\nIf you want information about this bot - use /information\nIf you want command list - use /help', 'help_AfterAuthorized': u'If you known password - use /on\nelse - connect to admin', 'help_BeforeAuthorized': u'Command:\n/off - disconnect from bot\n/setsshUser - Set ssh user and ssh password\n/setsshHost - Set host(IP) for ssh connection\n/information - Show information, about ssh-connection\n/aboutBot - Information about bot and author\n', 'aboutBot': 'Author GitHub - https://github.com/vzemtsov\nPlease write wishes to improve this bot'} |
'''
'''
def main():
info('Pump Microbone')
close(description="Jan Inlet")
if is_closed('F'):
open(description= 'Microbone to CO2 Laser')
else:
close(name="T", description="Microbone to CO2 Laser")
sleep(1)
close(description= 'CO2 Laser to Roughing')
#close(description= 'Microbone to Minibone')
open(description= 'Microbone to Turbo')
open(description= 'Microbone to Getter NP-10H')
open(description= 'Microbone to Getter NP-10C')
#open(description= 'Microbone to CO2 Laser')
open(description= 'Microbone to Inlet Pipette')
sleep(1)
set_resource(name='CO2PumpTimeFlag', value=30)
release('JanCO2Flag') | """
"""
def main():
info('Pump Microbone')
close(description='Jan Inlet')
if is_closed('F'):
open(description='Microbone to CO2 Laser')
else:
close(name='T', description='Microbone to CO2 Laser')
sleep(1)
close(description='CO2 Laser to Roughing')
open(description='Microbone to Turbo')
open(description='Microbone to Getter NP-10H')
open(description='Microbone to Getter NP-10C')
open(description='Microbone to Inlet Pipette')
sleep(1)
set_resource(name='CO2PumpTimeFlag', value=30)
release('JanCO2Flag') |
def findDecision(obj): #obj[0]: Driving_to, obj[1]: Passanger, obj[2]: Weather, obj[3]: Temperature, obj[4]: Time, obj[5]: Coupon, obj[6]: Coupon_validity, obj[7]: Gender, obj[8]: Age, obj[9]: Maritalstatus, obj[10]: Children, obj[11]: Education, obj[12]: Occupation, obj[13]: Income, obj[14]: Bar, obj[15]: Coffeehouse, obj[16]: Carryaway, obj[17]: Restaurantlessthan20, obj[18]: Restaurant20to50, obj[19]: Direction_same, obj[20]: Distance
# {"feature": "Education", "instances": 41, "metric_value": 0.9892, "depth": 1}
if obj[11]>1:
# {"feature": "Occupation", "instances": 26, "metric_value": 0.9612, "depth": 2}
if obj[12]>3:
# {"feature": "Income", "instances": 20, "metric_value": 1.0, "depth": 3}
if obj[13]>1:
# {"feature": "Maritalstatus", "instances": 17, "metric_value": 0.9774, "depth": 4}
if obj[9]<=1:
# {"feature": "Carryaway", "instances": 15, "metric_value": 0.9183, "depth": 5}
if obj[16]>1.0:
# {"feature": "Children", "instances": 13, "metric_value": 0.7793, "depth": 6}
if obj[10]<=0:
return 'True'
elif obj[10]>0:
# {"feature": "Gender", "instances": 6, "metric_value": 1.0, "depth": 7}
if obj[7]<=0:
return 'False'
elif obj[7]>0:
return 'True'
else: return 'True'
else: return 'False'
elif obj[16]<=1.0:
return 'False'
else: return 'False'
elif obj[9]>1:
return 'False'
else: return 'False'
elif obj[13]<=1:
return 'False'
else: return 'False'
elif obj[12]<=3:
return 'False'
else: return 'False'
elif obj[11]<=1:
# {"feature": "Income", "instances": 15, "metric_value": 0.5665, "depth": 2}
if obj[13]>2:
return 'True'
elif obj[13]<=2:
# {"feature": "Coffeehouse", "instances": 4, "metric_value": 1.0, "depth": 3}
if obj[15]<=0.0:
return 'False'
elif obj[15]>0.0:
return 'True'
else: return 'True'
else: return 'False'
else: return 'True'
| def find_decision(obj):
if obj[11] > 1:
if obj[12] > 3:
if obj[13] > 1:
if obj[9] <= 1:
if obj[16] > 1.0:
if obj[10] <= 0:
return 'True'
elif obj[10] > 0:
if obj[7] <= 0:
return 'False'
elif obj[7] > 0:
return 'True'
else:
return 'True'
else:
return 'False'
elif obj[16] <= 1.0:
return 'False'
else:
return 'False'
elif obj[9] > 1:
return 'False'
else:
return 'False'
elif obj[13] <= 1:
return 'False'
else:
return 'False'
elif obj[12] <= 3:
return 'False'
else:
return 'False'
elif obj[11] <= 1:
if obj[13] > 2:
return 'True'
elif obj[13] <= 2:
if obj[15] <= 0.0:
return 'False'
elif obj[15] > 0.0:
return 'True'
else:
return 'True'
else:
return 'False'
else:
return 'True' |
bil = 0
count = 0
hasil = 0
while(bil <= 100):
if(bil % 2 == 1):
count += 1
hasil += bil
print(bil)
bil += 1
print('Banyaknya bilangan ganjil :', count)
print('Jumlah seluruh bilangan :', hasil)
| bil = 0
count = 0
hasil = 0
while bil <= 100:
if bil % 2 == 1:
count += 1
hasil += bil
print(bil)
bil += 1
print('Banyaknya bilangan ganjil :', count)
print('Jumlah seluruh bilangan :', hasil) |
def mapping_Luo(t=1):
names = [ 'Yao_6_2', 'AB_TMA_2', 'ABA_TMA_2',
'ABAB_TMA_2', 'ABABA_TMA_2', 'ABABA_IPrMeP_2']
xlocs = [ 21400, 5500, -7200,
-11700, -17200, -30700]
ylocs = [ 0, 0, 0,
0, 0, 0]
zlocs = [ 2700, 2700, 2700,
2700, 2700, 2700]
x_range=[[0, 500, 21], [0, 500, 21], [0, 500, 21],
[0, 500, 21], [0, 500, 21], [0, 500, 21]]
y_range=[[0, 500, 101],[0, 500, 101],[0, 500, 101],
[0, 500, 101],[0, 500, 101],[0, 500, 101]]
wa_range=[ [0, 13, 3], [0, 13, 3], [0, 13, 3],
[0, 13, 3], [0, 13, 3], [0, 13, 3]]
# names = ['CRP_2_275', 'CRP_1_131', 'Yao_6', 'CRP_2_275F', 'CRP_1_275A', 'AB_TMA', 'iPrMeP_stat', 'ABA_TMA', 'ABAB_TMA', 'ABABA_TMA',
# 'TMA_stat', 'ABABA_IPrMeP' ]
# xlocs = [30400, 26100, 21400, 16200, 9600, 5500, -500, -7200,
# -11700, -17200, -23700, -30700]
# ylocs = [0, 0, 0, 0, 0, 0, 0, 0,
# 0, 0, 0, 0]
# zlocs = [2700, 2700, 2700, 2700, 2700, 2700, 2700, 2700,
# 2700, 2700, 2700, 2700]
# x_range=[[0, 500, 11], [0, 500, 11], [0, 500, 11], [0, 500, 11], [0, 500, 11], [0, 500, 11], [0, 500, 11], [0, 500, 11],
# [0, 500, 11], [0, 500, 11], [0, 500, 11], [0, 500, 11]]
# y_range=[[0, 500, 101],[0, 500, 101],[0, 500, 101],[0, 500, 101],[0, 500, 101],[0, 500, 101],[0, 500, 101],[0, 500, 101],
# [0, 500, 101],[0, 500, 101],[0, 500, 101],[0, 500, 101]]
# wa_range=[[0, 26, 5], [0, 13, 3], [0, 26, 5], [0, 26, 5], [0, 26, 5], [0, 13, 3], [0, 13, 3], [0, 13, 3],
# [0, 13, 3], [0, 13, 3], [0, 13, 3], [0, 13, 3]]
user = 'AL'
det_exposure_time(t,t)
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(names)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(ylocs)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(zlocs)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(x_range)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(y_range)})'
assert len(xlocs) == len(wa_range), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(wa_range)})'
# Detectors, motors:
dets = [pil300KW, pil1M]
for num, (x, y, sample, x_r, y_r, wax_ra) in enumerate(zip(xlocs, ylocs, names, x_range, y_range, wa_range)):
if num == 0:
proposal_id('2121_1', '307948_Luo')
else:
proposal_id('2121_1', '307948_Luo2')
pil1M.cam.file_path.put('/nsls2/xf12id2/data/images/users/2021_1/307948_Luo2/1M/%s'%sample)
pil300KW.cam.file_path.put('/nsls2/xf12id2/data/images/users/2021_1/307948_Luo2/300KW/%s'%sample)
for wa in np.linspace(wax_ra[0], wax_ra[1], wax_ra[2]):
yield from bps.mv(waxs, wa)
yield from bps.mv(piezo.x, x)
yield from bps.mv(piezo.y, y+500)
name_fmt = '{sam}_4m_16.1keV_wa{waxs}'
sample_name = name_fmt.format(sam=sample, waxs='%2.1f'%wa)
sample_id(user_name=user, sample_name=sample_name)
print(f'\n\t=== Sample: {sample_name} ===\n')
yield from bp.rel_grid_scan(dets, piezo.y, *y_r, piezo.x, *x_r, 0) #1 = snake, 0 = not-snake
sample_id(user_name='test', sample_name='test')
det_exposure_time(0.3,0.3)
| def mapping__luo(t=1):
names = ['Yao_6_2', 'AB_TMA_2', 'ABA_TMA_2', 'ABAB_TMA_2', 'ABABA_TMA_2', 'ABABA_IPrMeP_2']
xlocs = [21400, 5500, -7200, -11700, -17200, -30700]
ylocs = [0, 0, 0, 0, 0, 0]
zlocs = [2700, 2700, 2700, 2700, 2700, 2700]
x_range = [[0, 500, 21], [0, 500, 21], [0, 500, 21], [0, 500, 21], [0, 500, 21], [0, 500, 21]]
y_range = [[0, 500, 101], [0, 500, 101], [0, 500, 101], [0, 500, 101], [0, 500, 101], [0, 500, 101]]
wa_range = [[0, 13, 3], [0, 13, 3], [0, 13, 3], [0, 13, 3], [0, 13, 3], [0, 13, 3]]
user = 'AL'
det_exposure_time(t, t)
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(names)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(ylocs)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(zlocs)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(x_range)})'
assert len(xlocs) == len(names), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(y_range)})'
assert len(xlocs) == len(wa_range), f'Number of X coordinates ({len(xlocs)}) is different from number of samples ({len(wa_range)})'
dets = [pil300KW, pil1M]
for (num, (x, y, sample, x_r, y_r, wax_ra)) in enumerate(zip(xlocs, ylocs, names, x_range, y_range, wa_range)):
if num == 0:
proposal_id('2121_1', '307948_Luo')
else:
proposal_id('2121_1', '307948_Luo2')
pil1M.cam.file_path.put('/nsls2/xf12id2/data/images/users/2021_1/307948_Luo2/1M/%s' % sample)
pil300KW.cam.file_path.put('/nsls2/xf12id2/data/images/users/2021_1/307948_Luo2/300KW/%s' % sample)
for wa in np.linspace(wax_ra[0], wax_ra[1], wax_ra[2]):
yield from bps.mv(waxs, wa)
yield from bps.mv(piezo.x, x)
yield from bps.mv(piezo.y, y + 500)
name_fmt = '{sam}_4m_16.1keV_wa{waxs}'
sample_name = name_fmt.format(sam=sample, waxs='%2.1f' % wa)
sample_id(user_name=user, sample_name=sample_name)
print(f'\n\t=== Sample: {sample_name} ===\n')
yield from bp.rel_grid_scan(dets, piezo.y, *y_r, piezo.x, *x_r, 0)
sample_id(user_name='test', sample_name='test')
det_exposure_time(0.3, 0.3) |
def alpha_numeric(m):
return re.sub('[^A-Za-z0-9]+', ' ', m)
def uri_from_fields(fields):
string = '_'.join(alpha_numeric(f.strip().lower()) for f in fields)
if len(string) == len(fields)-1:
return ''
return string
def splitLocation(location):
return re.search('[NS]',location).start()
def getLatitude(s,l):
second = float(s[-2:])
minute = float(s[-4:-2])
degree = float(s[:-4])
if l == "N":
return str(degree+minute/60+second/3600)
else:
return str(-degree-minute/60-second/3600)
def getLongitude(s,l):
second = float(s[-2:])
minute = float(s[-4:-2])
degree = float(s[:-4])
if l == "E":
return str(degree+minute/60+second/3600)
else:
return str(-degree-minute/60-second/3600)
def ISOtime(s):
MM_dict = {"JAN":"01","FEB":"02","MAR":"03","APR":"04","MAY":"05","JUN":"06","JUL":"07","AUG":"08","SEP":"09","OCT":"10","NOV":"11","DEC":"12"}
return s[:4]+MM_dict[s[4:7]]+s[7:9]+"T"+s[9:11]+":"+s[11:]
def parseFstatOutput(s):
if s[-3:] == "NOP":
return "baseClosed"
if s[-3:] == "OPR":
return "baseOpen"
def parseEstatAction(action):
if action == "ABORT":
return "missionAbort"
elif action == "LANDED":
return "missionLanded"
elif action == "REFUEL":
return "aircraftRefuel"
elif action == "RTB":
return "missionReturnToBase"
elif action == "TAKEOFF":
return "aircraftTakeoff"
elif action == "ON STATION":
return "missionOnStation" | def alpha_numeric(m):
return re.sub('[^A-Za-z0-9]+', ' ', m)
def uri_from_fields(fields):
string = '_'.join((alpha_numeric(f.strip().lower()) for f in fields))
if len(string) == len(fields) - 1:
return ''
return string
def split_location(location):
return re.search('[NS]', location).start()
def get_latitude(s, l):
second = float(s[-2:])
minute = float(s[-4:-2])
degree = float(s[:-4])
if l == 'N':
return str(degree + minute / 60 + second / 3600)
else:
return str(-degree - minute / 60 - second / 3600)
def get_longitude(s, l):
second = float(s[-2:])
minute = float(s[-4:-2])
degree = float(s[:-4])
if l == 'E':
return str(degree + minute / 60 + second / 3600)
else:
return str(-degree - minute / 60 - second / 3600)
def is_otime(s):
mm_dict = {'JAN': '01', 'FEB': '02', 'MAR': '03', 'APR': '04', 'MAY': '05', 'JUN': '06', 'JUL': '07', 'AUG': '08', 'SEP': '09', 'OCT': '10', 'NOV': '11', 'DEC': '12'}
return s[:4] + MM_dict[s[4:7]] + s[7:9] + 'T' + s[9:11] + ':' + s[11:]
def parse_fstat_output(s):
if s[-3:] == 'NOP':
return 'baseClosed'
if s[-3:] == 'OPR':
return 'baseOpen'
def parse_estat_action(action):
if action == 'ABORT':
return 'missionAbort'
elif action == 'LANDED':
return 'missionLanded'
elif action == 'REFUEL':
return 'aircraftRefuel'
elif action == 'RTB':
return 'missionReturnToBase'
elif action == 'TAKEOFF':
return 'aircraftTakeoff'
elif action == 'ON STATION':
return 'missionOnStation' |
def solve(input, days):
# Lanternfish with internal timer t are the number of lanternfish with timer t+1 after a day
for day in range(days):
aux = input[0]
input[0] = input[1]
input[1] = input[2]
input[2] = input[3]
input[3] = input[4]
input[4] = input[5]
input[5] = input[6]
# Lantern fish with interal timer 0 replicate, but they have to be added to those lanternfish that have
# a timer equal to 7
input[6] = input[7] + aux
input[7] = input[8]
input[8] = aux
return sum([input[key] for key in input])
# Get input and transform to my chosen data structure
with open('Day6_input.txt','r') as inputfile:
input = inputfile.read().split(",")
input = [int(element) for element in input]
# Lanterfish dictionary where the key represents their internal timer, and the value how many lanternfish
# with that internal timer are alive right now
input = {
0: input.count(0),
1: input.count(1),
2: input.count(2),
3: input.count(3),
4: input.count(4),
5: input.count(5),
6: input.count(6),
7: input.count(7),
8: input.count(8)
}
part1_sol = solve(input,80)
print("Part 1 solution: ",part1_sol)
# 80 days have already been calculated, we take advantage of it
part2_sol = solve(input,256 - 80)
print("Part 2 solution: ",part2_sol) | def solve(input, days):
for day in range(days):
aux = input[0]
input[0] = input[1]
input[1] = input[2]
input[2] = input[3]
input[3] = input[4]
input[4] = input[5]
input[5] = input[6]
input[6] = input[7] + aux
input[7] = input[8]
input[8] = aux
return sum([input[key] for key in input])
with open('Day6_input.txt', 'r') as inputfile:
input = inputfile.read().split(',')
input = [int(element) for element in input]
input = {0: input.count(0), 1: input.count(1), 2: input.count(2), 3: input.count(3), 4: input.count(4), 5: input.count(5), 6: input.count(6), 7: input.count(7), 8: input.count(8)}
part1_sol = solve(input, 80)
print('Part 1 solution: ', part1_sol)
part2_sol = solve(input, 256 - 80)
print('Part 2 solution: ', part2_sol) |
def funcao1(funcao, *args, **kwargs):
return funcao(*args, **kwargs)
def funcao2(nome):
return f'Oi {nome}'
def funcao3(nome, saudacao):
return f'{saudacao} {nome}'
executando = funcao1(funcao2, 'Luiz')
print(executando)
executando = funcao1(funcao3, 'Luiz', saudacao='Bom dia')
print(executando)
| def funcao1(funcao, *args, **kwargs):
return funcao(*args, **kwargs)
def funcao2(nome):
return f'Oi {nome}'
def funcao3(nome, saudacao):
return f'{saudacao} {nome}'
executando = funcao1(funcao2, 'Luiz')
print(executando)
executando = funcao1(funcao3, 'Luiz', saudacao='Bom dia')
print(executando) |
true = True;
false = False;
true1 = "True";
false1 = "False";
true2 = true; ''' I was trying to check if keyword is case sensitive which it is not but here the above defined variable value is taken which is bool
This technique can be used to define case insensitive keywords at start to py program.'''
false2 = false;
print(true,type(true));
print(false,type(false));
print(true1,type(true1));
print(false1,type(false1));
print(true2,type(true2));
print(false2,type(false2));
| true = True
false = False
true1 = 'True'
false1 = 'False'
true2 = true
' I was trying to check if keyword is case sensitive which it is not but here the above defined variable value is taken which is bool\nThis technique can be used to define case insensitive keywords at start to py program.'
false2 = false
print(true, type(true))
print(false, type(false))
print(true1, type(true1))
print(false1, type(false1))
print(true2, type(true2))
print(false2, type(false2)) |
## input = 1,2,3,4
## output = ['1','2','3','4'], ('1','2','3','4')
def abc():
values = input()
print("----")
print(values)
print("----")
x = values.split(",")
print(x)
y = tuple(x)
print("===")
print(y)
if __name__ == "__main__":
abc()
| def abc():
values = input()
print('----')
print(values)
print('----')
x = values.split(',')
print(x)
y = tuple(x)
print('===')
print(y)
if __name__ == '__main__':
abc() |
#!/usr/bin/env python3
FILENAME = "/tmp/passed"
bmks = []
with open(FILENAME, "r") as f:
for l in f:
[m, a] = l.split(" ")
t = (m, a.strip())
bmks.append(t)
def quote(s):
return '"{}"'.format(s)
indent = " "
output = '{}[ {}\n{}]'.format(indent, f'\n{indent}, '.join(f'("{m}", "{a}")' for m, a in bmks), indent)
print("passedTests :: [(String, String)]")
print("passedTests =")
print(output)
| filename = '/tmp/passed'
bmks = []
with open(FILENAME, 'r') as f:
for l in f:
[m, a] = l.split(' ')
t = (m, a.strip())
bmks.append(t)
def quote(s):
return '"{}"'.format(s)
indent = ' '
output = '{}[ {}\n{}]'.format(indent, f'\n{indent}, '.join((f'("{m}", "{a}")' for (m, a) in bmks)), indent)
print('passedTests :: [(String, String)]')
print('passedTests =')
print(output) |
{
"includes": [
"../common.gypi"
],
"targets": [
{
"target_name": "libgdal_ogr_vrt_frmt",
"type": "static_library",
"sources": [
"../gdal/ogr/ogrsf_frmts/vrt/ogrvrtlayer.cpp",
"../gdal/ogr/ogrsf_frmts/vrt/ogrvrtdriver.cpp",
"../gdal/ogr/ogrsf_frmts/vrt/ogrvrtdatasource.cpp"
],
"include_dirs": [
"../gdal/ogr/ogrsf_frmts/vrt"
]
}
]
}
| {'includes': ['../common.gypi'], 'targets': [{'target_name': 'libgdal_ogr_vrt_frmt', 'type': 'static_library', 'sources': ['../gdal/ogr/ogrsf_frmts/vrt/ogrvrtlayer.cpp', '../gdal/ogr/ogrsf_frmts/vrt/ogrvrtdriver.cpp', '../gdal/ogr/ogrsf_frmts/vrt/ogrvrtdatasource.cpp'], 'include_dirs': ['../gdal/ogr/ogrsf_frmts/vrt']}]} |
def subarraysCountBySum(a, k, s):
ans=0
n=len(a)
t=0
ii=1
while(k+t<=n):
tmp=[]
for i in range(t,ii+t):
tmp.append(a[i])
print(tmp)
ii+=1
if len(tmp)<=k and sum(tmp)==s:
ans+=1
t+=1
else:
break
return ans
a=list(map(int,input().split()))
k,s=map(int,input().split())
print(subarraysCountBySum(a, k, s))
| def subarrays_count_by_sum(a, k, s):
ans = 0
n = len(a)
t = 0
ii = 1
while k + t <= n:
tmp = []
for i in range(t, ii + t):
tmp.append(a[i])
print(tmp)
ii += 1
if len(tmp) <= k and sum(tmp) == s:
ans += 1
t += 1
else:
break
return ans
a = list(map(int, input().split()))
(k, s) = map(int, input().split())
print(subarrays_count_by_sum(a, k, s)) |
def main(request, response):
response.headers.set(b"Content-Type", b"text/plain")
response.status = 200
response.content = request.headers.get(b"Content-Type")
response.close_connection = True
| def main(request, response):
response.headers.set(b'Content-Type', b'text/plain')
response.status = 200
response.content = request.headers.get(b'Content-Type')
response.close_connection = True |
fruits = ['banana', 'orange', 'mango', 'lemon']
fruit = str(input('Enter a fruit: ')).strip().lower()
if fruit not in fruits:
fruits.append(fruit)
print(fruits)
else:
print(f'{fruit} already in the list')
| fruits = ['banana', 'orange', 'mango', 'lemon']
fruit = str(input('Enter a fruit: ')).strip().lower()
if fruit not in fruits:
fruits.append(fruit)
print(fruits)
else:
print(f'{fruit} already in the list') |
amount = 20
num=1
def setup():
size(640, 640)
stroke(0, 150, 255, 100)
def draw():
global num, amount
fill(0, 40)
rect(-1, -1, width+1, height+1)
maxX = map(mouseX, 0, width, 1, 250)
translate(width/2, height/2)
for i in range(0,360,amount):
x = sin(radians(i+num)) * maxX
y = cos(radians(i+num)) * maxX
x2 = sin(radians(i+amount-num)) * maxX
y2 = cos(radians(i+amount-num)) * maxX
noFill()
bezier(x, y, x-x2, y-y2, x2-x, y2-y, x2, y2)
bezier(x, y, x+x2, y+y2, x2+x, y2+y, x2, y2)
fill(0, 150, 255)
ellipse(x, y, 5, 5)
ellipse(x2, y2, 5, 5)
num += 0.5;
| amount = 20
num = 1
def setup():
size(640, 640)
stroke(0, 150, 255, 100)
def draw():
global num, amount
fill(0, 40)
rect(-1, -1, width + 1, height + 1)
max_x = map(mouseX, 0, width, 1, 250)
translate(width / 2, height / 2)
for i in range(0, 360, amount):
x = sin(radians(i + num)) * maxX
y = cos(radians(i + num)) * maxX
x2 = sin(radians(i + amount - num)) * maxX
y2 = cos(radians(i + amount - num)) * maxX
no_fill()
bezier(x, y, x - x2, y - y2, x2 - x, y2 - y, x2, y2)
bezier(x, y, x + x2, y + y2, x2 + x, y2 + y, x2, y2)
fill(0, 150, 255)
ellipse(x, y, 5, 5)
ellipse(x2, y2, 5, 5)
num += 0.5 |
# Copyright (c) Microsoft Corporation.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
async def test_listeners(page, server):
log = []
def print_response(response):
log.append(response)
page.on("response", print_response)
await page.goto(f"{server.PREFIX}/input/textarea.html")
assert len(log) > 0
page.remove_listener("response", print_response)
log = []
await page.goto(f"{server.PREFIX}/input/textarea.html")
assert len(log) == 0
| async def test_listeners(page, server):
log = []
def print_response(response):
log.append(response)
page.on('response', print_response)
await page.goto(f'{server.PREFIX}/input/textarea.html')
assert len(log) > 0
page.remove_listener('response', print_response)
log = []
await page.goto(f'{server.PREFIX}/input/textarea.html')
assert len(log) == 0 |
class Backend(object):
# should be implemented all methods
def set(self, name, value):
raise NotImplementedError()
def get(self, name):
raise NotImplementedError()
def delete(self, name):
raise NotImplementedError()
def set_fields(self):
raise NotImplementedError()
def fields(self):
raise NotImplementedError()
def values(self):
raise NotImplementedError()
class AbstractBackend(Backend):
bucket_prefix = 'ONTHEFLY'
def __init__(self, options, original=None):
self.options = options
self.original = original
self.field_registry = None
self.value_registry = {}
def get_value_from_original_settings(self, name):
return getattr(self.original, name)
def get_fields(self):
if self.field_registry is None:
self.field_registry = self.fields()
return self.field_registry
def add_field(self, name):
if name not in self.get_fields():
self.field_registry.append(name)
self.set_fields()
def delete_field(self, name):
if name in self.field_registry:
self.field_registry.remove(name)
self.set_fields()
def set_value(self, name, value):
if name in self.value_registry:
del self.value_registry[name]
return self.set(name, value)
def get_value(self, name):
if name in self.value_registry:
value = self.value_registry[name]
else:
value = self.get(name)
self.value_registry[name] = value
return value
def delete_value(self, name):
if name in self.value_registry:
del self.value_registry[name]
return self.delete(name)
| class Backend(object):
def set(self, name, value):
raise not_implemented_error()
def get(self, name):
raise not_implemented_error()
def delete(self, name):
raise not_implemented_error()
def set_fields(self):
raise not_implemented_error()
def fields(self):
raise not_implemented_error()
def values(self):
raise not_implemented_error()
class Abstractbackend(Backend):
bucket_prefix = 'ONTHEFLY'
def __init__(self, options, original=None):
self.options = options
self.original = original
self.field_registry = None
self.value_registry = {}
def get_value_from_original_settings(self, name):
return getattr(self.original, name)
def get_fields(self):
if self.field_registry is None:
self.field_registry = self.fields()
return self.field_registry
def add_field(self, name):
if name not in self.get_fields():
self.field_registry.append(name)
self.set_fields()
def delete_field(self, name):
if name in self.field_registry:
self.field_registry.remove(name)
self.set_fields()
def set_value(self, name, value):
if name in self.value_registry:
del self.value_registry[name]
return self.set(name, value)
def get_value(self, name):
if name in self.value_registry:
value = self.value_registry[name]
else:
value = self.get(name)
self.value_registry[name] = value
return value
def delete_value(self, name):
if name in self.value_registry:
del self.value_registry[name]
return self.delete(name) |
number_of_days = int(input())
type_of_room = str(input())
rating = str(input())
room_for_one_person = 18.00
apartment = 25.00
president_apartment = 35.00
apartment_discount = 0
president_apartment_discount = 0
total_price_for_a_room = 0
total_price_for_apartment = 0
total_price_for_presidential_apartment = 0
additional_discount = 0
additional_pay = 0
room_with_discounts = 0
apartment_with_discounts = 0
president_apartment_with_discounts = 0
apartment1 = 0
president_apartment1 = 0
if type_of_room == 'room for one person' or type_of_room == 'apartment' or \
type_of_room == 'president apartment':
nights = number_of_days - 1
if type_of_room == 'room for one person':
total_price_for_a_room = room_for_one_person * nights
if rating == 'positive':
additional_pay = total_price_for_a_room * 0.25
room_with_discounts = total_price_for_a_room + additional_pay
elif rating == 'negative':
additional_discount = total_price_for_a_room * 0.10
room_with_discounts = total_price_for_a_room - additional_discount
print(f'{room_with_discounts:.2f}')
elif type_of_room == 'apartment':
total_price_for_apartment = apartment * nights
if number_of_days < 10:
apartment_discount = total_price_for_apartment * 0.30
elif 10 <= number_of_days <= 15:
apartment_discount = total_price_for_apartment * 0.35
elif number_of_days > 15:
apartment_discount = total_price_for_apartment * 0.50
apartment1 = total_price_for_apartment - apartment_discount
if rating == 'positive':
additional_pay = apartment1 * 0.25
apartment_with_discounts = apartment1 + additional_pay
elif rating == 'negative':
additional_discount = apartment1 * 0.10
apartment_with_discounts = apartment1 - additional_discount
print(f'{apartment_with_discounts:.2f}')
elif type_of_room == 'president apartment':
total_price_for_presidential_apartment = president_apartment * nights
if number_of_days < 10:
president_apartment_discount = total_price_for_presidential_apartment * 0.10
elif 10 <= number_of_days <= 15:
president_apartment_discount = total_price_for_presidential_apartment * 0.15
elif number_of_days > 15:
president_apartment_discount = total_price_for_presidential_apartment * 0.20
president_apartment1 = total_price_for_presidential_apartment - president_apartment_discount
if rating == 'positive':
additional_pay = president_apartment1 * 0.25
president_apartment_with_discounts = president_apartment1 + additional_pay
elif rating == 'negative':
additional_discount = president_apartment1 * 0.10
president_apartment_with_discounts = president_apartment1 - additional_discount
print(f'{president_apartment_with_discounts:.2f}')
| number_of_days = int(input())
type_of_room = str(input())
rating = str(input())
room_for_one_person = 18.0
apartment = 25.0
president_apartment = 35.0
apartment_discount = 0
president_apartment_discount = 0
total_price_for_a_room = 0
total_price_for_apartment = 0
total_price_for_presidential_apartment = 0
additional_discount = 0
additional_pay = 0
room_with_discounts = 0
apartment_with_discounts = 0
president_apartment_with_discounts = 0
apartment1 = 0
president_apartment1 = 0
if type_of_room == 'room for one person' or type_of_room == 'apartment' or type_of_room == 'president apartment':
nights = number_of_days - 1
if type_of_room == 'room for one person':
total_price_for_a_room = room_for_one_person * nights
if rating == 'positive':
additional_pay = total_price_for_a_room * 0.25
room_with_discounts = total_price_for_a_room + additional_pay
elif rating == 'negative':
additional_discount = total_price_for_a_room * 0.1
room_with_discounts = total_price_for_a_room - additional_discount
print(f'{room_with_discounts:.2f}')
elif type_of_room == 'apartment':
total_price_for_apartment = apartment * nights
if number_of_days < 10:
apartment_discount = total_price_for_apartment * 0.3
elif 10 <= number_of_days <= 15:
apartment_discount = total_price_for_apartment * 0.35
elif number_of_days > 15:
apartment_discount = total_price_for_apartment * 0.5
apartment1 = total_price_for_apartment - apartment_discount
if rating == 'positive':
additional_pay = apartment1 * 0.25
apartment_with_discounts = apartment1 + additional_pay
elif rating == 'negative':
additional_discount = apartment1 * 0.1
apartment_with_discounts = apartment1 - additional_discount
print(f'{apartment_with_discounts:.2f}')
elif type_of_room == 'president apartment':
total_price_for_presidential_apartment = president_apartment * nights
if number_of_days < 10:
president_apartment_discount = total_price_for_presidential_apartment * 0.1
elif 10 <= number_of_days <= 15:
president_apartment_discount = total_price_for_presidential_apartment * 0.15
elif number_of_days > 15:
president_apartment_discount = total_price_for_presidential_apartment * 0.2
president_apartment1 = total_price_for_presidential_apartment - president_apartment_discount
if rating == 'positive':
additional_pay = president_apartment1 * 0.25
president_apartment_with_discounts = president_apartment1 + additional_pay
elif rating == 'negative':
additional_discount = president_apartment1 * 0.1
president_apartment_with_discounts = president_apartment1 - additional_discount
print(f'{president_apartment_with_discounts:.2f}') |
LIST_WORKFLOWS_GQL = '''
query workflowList {
workflowList {
edges{
node {
id
name
objectType
initialPrefetch
initialState {
id
name
}
initialTransition {
id
name
}
}
}
}
}
'''
LIST_STATES_GQL = '''
query stateList {
stateList {
edges{
node {
id
name
active
initial
workflow {
id
name
}
}
}
}
}
'''
MUTATE_WORKFLOW_GRAPH_GQL = '''
mutation workflowMutation($param: WorkflowMutationInput!) {
workflowMutation(input:$param) {
id
name
initialPrefetch
objectType
errors {
messages
}
}
}
'''
MUTATE_STATE_GRAPH_GQL = '''
mutation stateMutation($param: StateMutationInput!) {
stateMutation(input:$param) {
id
name
initial
active
workflow
errors {
messages
}
}
}
'''
LIST_TRANSITIONS_GQL = '''
query transitionList($param: ID) {
transitionList(workflow_Id:$param) {
edges{
node {
id
name
initialState {
id
name
active
initial
variableDefinitions {
edges {
node {
id
name
}
}
}
}
finalState {
id
name
active
initial
variableDefinitions {
edges {
node {
id
name
}
}
}
}
conditionSet {
edges {
node {
id
conditionType
functionSet {
edges {
node {
id
functionModule
functionName
parameters{
edges {
node {
id
name
value
}
}
}
}
}
}
}
}
}
}
}
}
}
'''
LIST_WORKFLOW_STATES_GQL = '''
query stateList($param: ID) {
stateList(workflow_Id:$param) {
edges{
node {
id
name
active
initial
workflow {
id
name
}
}
}
}
}
'''
LIST_WORKFLOW_GRAPH_GQL = '''
query workflowList($param: String) {
workflowList(name:$param) {
edges{
node {
id
name
graph
}
}
}
}
''' | list_workflows_gql = '\nquery workflowList {\n workflowList {\n edges{\n node {\n id\n name\n objectType\n initialPrefetch\n initialState {\n id\n name\n }\n initialTransition {\n id\n name\n }\n }\n }\n }\n}\n'
list_states_gql = '\nquery stateList {\n stateList {\n edges{\n node {\n id\n name\n active\n initial\n workflow {\n id\n name\n }\n }\n }\n }\n}\n'
mutate_workflow_graph_gql = '\nmutation workflowMutation($param: WorkflowMutationInput!) {\n workflowMutation(input:$param) {\n id\n name\n initialPrefetch\n objectType \n errors {\n messages\n }\n }\n}\n'
mutate_state_graph_gql = '\nmutation stateMutation($param: StateMutationInput!) {\n stateMutation(input:$param) {\n id\n name\n initial\n active\n workflow\n errors {\n messages\n }\n }\n}\n'
list_transitions_gql = '\nquery transitionList($param: ID) {\n transitionList(workflow_Id:$param) {\n edges{\n node {\n id\n name\n initialState {\n id\n name\n active\n initial\n variableDefinitions {\n edges {\n node {\n id\n name\n }\n }\n }\n }\n finalState {\n id\n name\n active\n initial\n variableDefinitions {\n edges {\n node {\n id\n name\n }\n }\n }\n }\n conditionSet {\n edges {\n node {\n id\n conditionType\n functionSet {\n edges {\n node {\n id\n functionModule\n functionName\n parameters{\n edges {\n node {\n id\n name\n value\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n}\n'
list_workflow_states_gql = '\nquery stateList($param: ID) {\n stateList(workflow_Id:$param) {\n edges{\n node {\n id\n name\n active\n initial\n workflow {\n id\n name\n }\n \n }\n }\n }\n}\n'
list_workflow_graph_gql = '\nquery workflowList($param: String) {\n workflowList(name:$param) {\n edges{\n node {\n id\n name\n graph\n }\n }\n }\n}\n' |
with open("text.txt", "w") as my_file:
my_file.write("Tretas dos Bronzetas")
if my_file.closed == False:
my_file.close()
print(my_file.closed)
| with open('text.txt', 'w') as my_file:
my_file.write('Tretas dos Bronzetas')
if my_file.closed == False:
my_file.close()
print(my_file.closed) |
DESCRIBE_VMS = [
{
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM",
"type": "Microsoft.Compute/virtualMachines",
"location": "West US",
"resource_group": "TestRG",
"name": "TestVM",
"plan": {
"product": "Standard",
},
"handware_profile": {
"vm_size": "Standard_D2s_v3",
},
"license_type": "Windows_Client ",
"os_profile": {
"computer_name": "TestVM",
},
"identity": {
"type": "SystemAssigned",
},
"zones": [
"West US 2",
],
"additional_capabilities": {
"ultra_ssd_enabled": True,
},
"priority": "Low",
"eviction_policy": "Deallocate",
},
{
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM1",
"type": "Microsoft.Compute/virtualMachines",
"location": "West US",
"resource_group": "TestRG",
"name": "TestVM1",
"plan": {
"product": "Standard",
},
"handware_profile": {
"vm_size": "Standard_D2s_v3",
},
"license_type": "Windows_Client ",
"os_profile": {
"computer_name": "TestVM1",
},
"identity": {
"type": "SystemAssigned",
},
"zones": [
"West US 2",
],
"additional_capabilities": {
"ultra_ssd_enabled": True,
},
"priority": "Low",
"eviction_policy": "Deallocate",
},
]
DESCRIBE_VM_DATA_DISKS = [
{
"lun": 0,
"name": "dd0",
"create_option": "Empty",
"caching": "ReadWrite",
"managed_disk": {
"storage_account_type": "Premium_LRS",
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd0",
},
"disk_size_gb": 30,
},
{
"lun": 0,
"name": "dd1",
"create_option": "Empty",
"caching": "ReadWrite",
"managed_disk": {
"storage_account_type": "Premium_LRS",
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd1",
},
"disk_size_gb": 30,
},
]
DESCRIBE_DISKS = [
{
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd0",
"type": "Microsoft.Compute/disks",
"location": "West US",
"resource_group": "TestRG",
"name": "dd0",
"creation_data": {
"create_option": "Attach",
},
"disk_size_gb": 100,
"encryption_settings_collection": {
"enabled": True,
},
"max_shares": 10,
"network_access_policy": "AllowAll",
"os_type": "Windows",
"tier": "P4",
"sku": {
"name": "Standard_LRS",
},
"zones": [
"West US 2",
],
},
{
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd1",
"type": "Microsoft.Compute/disks",
"location": "West US",
"resource_group": "TestRG",
"name": "dd1",
"creation_data": {
"create_option": "Attach",
},
"disk_size_gb": 100,
"encryption_settings_collection": {
"enabled": True,
},
"max_shares": 10,
"network_access_policy": "AllowAll",
"os_type": "Windows",
"tier": "P4",
"sku": {
"name": "Standard_LRS",
},
"zones": [
"West US 2",
],
},
]
DESCRIBE_SNAPSHOTS = [
{
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/snapshots/ss0",
"type": "Microsoft.Compute/snapshots",
"location": "West US",
"resource_group": "TestRG",
"name": "ss0",
"creation_data": {
"create_option": "Attach",
},
"disk_size_gb": 100,
"encryption_settings_collection": {
"enabled": True,
},
"incremental": True,
"network_access_policy": "AllowAll",
"os_type": "Windows",
"tier": "P4",
"sku": {
"name": "Standard_LRS",
},
},
{
"id": "/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/snapshots/ss1",
"type": "Microsoft.Compute/snapshots",
"location": "West US",
"resource_group": "TestRG",
"name": "ss1",
"creation_data": {
"create_option": "Attach",
},
"disk_size_gb": 100,
"encryption_settings_collection": {
"enabled": True,
},
"incremental": True,
"network_access_policy": "AllowAll",
"os_type": "Windows",
"tier": "P4",
"sku": {
"name": "Standard_LRS",
},
},
]
DESCRIBE_VMEXTENSIONS = [
{
"id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachines/TestVM/extensions/extensions1",
"type":
"Microsoft.Compute/virtualMachines/extensions",
"resource_group":
"TestRG",
"name":
"extensions1",
"location": "West US",
"vm_id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM",
},
{
"id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachines/TestVM1/extensions/extensions2",
"type":
"Microsoft.Compute/virtualMachines/extensions",
"resource_group":
"TestRG",
"name":
"extensions2",
"location": "West US",
"vm_id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM1",
},
]
DESCRIBE_VMAVAILABLESIZES = [
{
"numberOfCores":
2,
"type":
"Microsoft.Compute/virtualMachines/availablesizes",
"osDiskSizeInMB":
1234,
"name":
"size1",
"resourceDiskSizeInMB":
2312,
"memoryInMB":
4352,
"maxDataDiskCount":
3214,
"vm_id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM",
},
{
"numberOfCores":
2,
"type":
"Microsoft.Compute/virtualMachines/availablesizes",
"osDiskSizeInMB":
1234,
"name":
"size2",
"resourceDiskSizeInMB":
2312,
"memoryInMB":
4352,
"maxDataDiskCount":
3214,
"vm_id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM1",
},
]
DESCRIBE_VMSCALESETS = [
{
"id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachineScaleSets/set1",
"type":
"Microsoft.Compute/virtualMachineScaleSets",
"resource_group":
"TestRG",
"name":
"set1",
"location": "West US",
},
{
"id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachineScaleSets/set2",
"type":
"Microsoft.Compute/virtualMachineScaleSets",
"resource_group":
"TestRG",
"name":
"set2",
"location": "West US",
},
]
DESCRIBE_VMSCALESETEXTENSIONS = [
{
"id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachineScaleSets/set1/extensions/extension1",
"type":
"Microsoft.Compute/virtualMachineScaleSets/extensions",
"resource_group":
"TestRG",
"name":
"extension1",
"set_id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachineScaleSets/set1",
},
{
"id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachineScaleSets/set2/extensions/extension2",
"type":
"Microsoft.Compute/virtualMachineScaleSets/extensions",
"resource_group":
"TestRG",
"name":
"extension2",
"set_id":
"/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/\
virtualMachineScaleSets/set2",
},
]
| describe_vms = [{'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM', 'type': 'Microsoft.Compute/virtualMachines', 'location': 'West US', 'resource_group': 'TestRG', 'name': 'TestVM', 'plan': {'product': 'Standard'}, 'handware_profile': {'vm_size': 'Standard_D2s_v3'}, 'license_type': 'Windows_Client ', 'os_profile': {'computer_name': 'TestVM'}, 'identity': {'type': 'SystemAssigned'}, 'zones': ['West US 2'], 'additional_capabilities': {'ultra_ssd_enabled': True}, 'priority': 'Low', 'eviction_policy': 'Deallocate'}, {'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM1', 'type': 'Microsoft.Compute/virtualMachines', 'location': 'West US', 'resource_group': 'TestRG', 'name': 'TestVM1', 'plan': {'product': 'Standard'}, 'handware_profile': {'vm_size': 'Standard_D2s_v3'}, 'license_type': 'Windows_Client ', 'os_profile': {'computer_name': 'TestVM1'}, 'identity': {'type': 'SystemAssigned'}, 'zones': ['West US 2'], 'additional_capabilities': {'ultra_ssd_enabled': True}, 'priority': 'Low', 'eviction_policy': 'Deallocate'}]
describe_vm_data_disks = [{'lun': 0, 'name': 'dd0', 'create_option': 'Empty', 'caching': 'ReadWrite', 'managed_disk': {'storage_account_type': 'Premium_LRS', 'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd0'}, 'disk_size_gb': 30}, {'lun': 0, 'name': 'dd1', 'create_option': 'Empty', 'caching': 'ReadWrite', 'managed_disk': {'storage_account_type': 'Premium_LRS', 'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd1'}, 'disk_size_gb': 30}]
describe_disks = [{'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd0', 'type': 'Microsoft.Compute/disks', 'location': 'West US', 'resource_group': 'TestRG', 'name': 'dd0', 'creation_data': {'create_option': 'Attach'}, 'disk_size_gb': 100, 'encryption_settings_collection': {'enabled': True}, 'max_shares': 10, 'network_access_policy': 'AllowAll', 'os_type': 'Windows', 'tier': 'P4', 'sku': {'name': 'Standard_LRS'}, 'zones': ['West US 2']}, {'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/disks/dd1', 'type': 'Microsoft.Compute/disks', 'location': 'West US', 'resource_group': 'TestRG', 'name': 'dd1', 'creation_data': {'create_option': 'Attach'}, 'disk_size_gb': 100, 'encryption_settings_collection': {'enabled': True}, 'max_shares': 10, 'network_access_policy': 'AllowAll', 'os_type': 'Windows', 'tier': 'P4', 'sku': {'name': 'Standard_LRS'}, 'zones': ['West US 2']}]
describe_snapshots = [{'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/snapshots/ss0', 'type': 'Microsoft.Compute/snapshots', 'location': 'West US', 'resource_group': 'TestRG', 'name': 'ss0', 'creation_data': {'create_option': 'Attach'}, 'disk_size_gb': 100, 'encryption_settings_collection': {'enabled': True}, 'incremental': True, 'network_access_policy': 'AllowAll', 'os_type': 'Windows', 'tier': 'P4', 'sku': {'name': 'Standard_LRS'}}, {'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/snapshots/ss1', 'type': 'Microsoft.Compute/snapshots', 'location': 'West US', 'resource_group': 'TestRG', 'name': 'ss1', 'creation_data': {'create_option': 'Attach'}, 'disk_size_gb': 100, 'encryption_settings_collection': {'enabled': True}, 'incremental': True, 'network_access_policy': 'AllowAll', 'os_type': 'Windows', 'tier': 'P4', 'sku': {'name': 'Standard_LRS'}}]
describe_vmextensions = [{'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachines/TestVM/extensions/extensions1', 'type': 'Microsoft.Compute/virtualMachines/extensions', 'resource_group': 'TestRG', 'name': 'extensions1', 'location': 'West US', 'vm_id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM'}, {'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachines/TestVM1/extensions/extensions2', 'type': 'Microsoft.Compute/virtualMachines/extensions', 'resource_group': 'TestRG', 'name': 'extensions2', 'location': 'West US', 'vm_id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM1'}]
describe_vmavailablesizes = [{'numberOfCores': 2, 'type': 'Microsoft.Compute/virtualMachines/availablesizes', 'osDiskSizeInMB': 1234, 'name': 'size1', 'resourceDiskSizeInMB': 2312, 'memoryInMB': 4352, 'maxDataDiskCount': 3214, 'vm_id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM'}, {'numberOfCores': 2, 'type': 'Microsoft.Compute/virtualMachines/availablesizes', 'osDiskSizeInMB': 1234, 'name': 'size2', 'resourceDiskSizeInMB': 2312, 'memoryInMB': 4352, 'maxDataDiskCount': 3214, 'vm_id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/virtualMachines/TestVM1'}]
describe_vmscalesets = [{'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachineScaleSets/set1', 'type': 'Microsoft.Compute/virtualMachineScaleSets', 'resource_group': 'TestRG', 'name': 'set1', 'location': 'West US'}, {'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachineScaleSets/set2', 'type': 'Microsoft.Compute/virtualMachineScaleSets', 'resource_group': 'TestRG', 'name': 'set2', 'location': 'West US'}]
describe_vmscalesetextensions = [{'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachineScaleSets/set1/extensions/extension1', 'type': 'Microsoft.Compute/virtualMachineScaleSets/extensions', 'resource_group': 'TestRG', 'name': 'extension1', 'set_id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachineScaleSets/set1'}, {'id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachineScaleSets/set2/extensions/extension2', 'type': 'Microsoft.Compute/virtualMachineScaleSets/extensions', 'resource_group': 'TestRG', 'name': 'extension2', 'set_id': '/subscriptions/00-00-00-00/resourceGroups/TestRG/providers/Microsoft.Compute/ virtualMachineScaleSets/set2'}] |
'''
Pattern
Enter number of rows: 5
1
21
321
4321
54321
'''
print('Number Pattern:')
number_rows=int(input('Enter number of rows: '))
for row in range(1,number_rows+1):
for column in range(row,0,-1):
if column < 10:
print(f'0{column}',end=' ')
else:
print(column,end=' ')
print() | """
Pattern
Enter number of rows: 5
1
21
321
4321
54321
"""
print('Number Pattern:')
number_rows = int(input('Enter number of rows: '))
for row in range(1, number_rows + 1):
for column in range(row, 0, -1):
if column < 10:
print(f'0{column}', end=' ')
else:
print(column, end=' ')
print() |
class Solution:
def isStrobogrammatic(self, num: str) -> bool:
dic = {'1': '1', '6': '9', '8': '8', '9': '6', '0': '0'}
l, r = 0, len(num)-1
while l <= r:
if num[l] not in dic or dic[num[l]] != num[r]:
return False
l += 1
r -= 1
return True
| class Solution:
def is_strobogrammatic(self, num: str) -> bool:
dic = {'1': '1', '6': '9', '8': '8', '9': '6', '0': '0'}
(l, r) = (0, len(num) - 1)
while l <= r:
if num[l] not in dic or dic[num[l]] != num[r]:
return False
l += 1
r -= 1
return True |
# -*- coding: utf-8 -*-
name = 'usd'
version = '20.02'
requires = [
'alembic-1.5',
'boost-1.55',
'tbb-4.4.6',
'opensubdiv-3.2',
'ilmbase-2.2',
'jinja-2',
'jemalloc-4',
'openexr-2.2',
'pyilmbase-2.2',
'materialx',
'oiio-1.8',
'ptex-2.0',
'PyOpenGL',
'embree_lib',
'glew',
'renderman-22.6',
'ocio-1.0.9'
]
build_requires = [
'pyside-1.2'
]
private_build_requires = [
'cmake-3.2'
]
variants = [['platform-linux', 'arch-x86_64']]
def commands():
env.PYTHONPATH.append('{root}/lib/python')
env.LD_LIBRARY_PATH.append('{root}/lib/')
appendenv('PATH', '{root}/bin/')
| name = 'usd'
version = '20.02'
requires = ['alembic-1.5', 'boost-1.55', 'tbb-4.4.6', 'opensubdiv-3.2', 'ilmbase-2.2', 'jinja-2', 'jemalloc-4', 'openexr-2.2', 'pyilmbase-2.2', 'materialx', 'oiio-1.8', 'ptex-2.0', 'PyOpenGL', 'embree_lib', 'glew', 'renderman-22.6', 'ocio-1.0.9']
build_requires = ['pyside-1.2']
private_build_requires = ['cmake-3.2']
variants = [['platform-linux', 'arch-x86_64']]
def commands():
env.PYTHONPATH.append('{root}/lib/python')
env.LD_LIBRARY_PATH.append('{root}/lib/')
appendenv('PATH', '{root}/bin/') |
contador = 1
while contador <= 9:
for contador2 in range(7, 4, -1):
print(f'I={contador} J={contador2}')
contador += 2 | contador = 1
while contador <= 9:
for contador2 in range(7, 4, -1):
print(f'I={contador} J={contador2}')
contador += 2 |
# Advent of Code - Day 4
valid_passport_data = {
'ecl', 'pid', 'eyr', 'hcl',
'byr', 'iyr', 'hgt',
}
count_required_data = len(valid_passport_data)
def ecl_rule(value):
return value in {'amb', 'blu', 'brn', 'gry', 'grn', 'hzl', 'oth'}
def pid_rule(value):
try:
int(value)
isnumber = True
except:
isnumber = False
return (len(value) == 9) and isnumber
def eyr_rule(value):
try:
year = int(value)
except:
return False
return year >= 2020 and year <= 2030
def hcl_rule(value):
try:
int(value[1:], 16)
except:
return False
return value[0] == '#' and len(value) == 7
def byr_rule(value):
try:
year = int(value)
except:
return False
return year >= 1920 and year <= 2002
def iyr_rule(value):
try:
year = int(value)
except:
return False
return year >= 2010 and year <= 2020
def hgt_rule(value):
units = value[-2:]
try:
height = float(value[:-2])
except:
return False
if units == 'cm':
return height >= 150.00 and height <= 193.00
if units == 'in':
return height >= 59.00 and height <= 76.00
return False
validation_rules = {
'ecl': ecl_rule,
'pid': pid_rule,
'eyr': eyr_rule,
'hcl': hcl_rule,
'byr': byr_rule,
'hgt': hgt_rule,
'iyr': iyr_rule
}
def load_passports(path):
with open(path, 'r') as file:
lines = file.readlines()
passports = []
passport_data = {}
for line in lines:
if ':' in line:
key_value_list = line.split()
for key_value in key_value_list:
key, value = key_value.split(':')
passport_data[key] = value
else:
passports.append(passport_data)
passport_data = {}
passports.append(passport_data)
return passports
def validate_passport(passport):
keys = set(passport)
common_data = valid_passport_data.intersection(keys)
if len(common_data) == count_required_data:
is_valid = True
for key in keys:
if key == 'cid':
continue
try:
value = passport[key]
is_valid = (is_valid and validation_rules[key](value))
except Exception as e:
print(f'ValidationError: {e}')
return int(is_valid)
return 0
# === MAIN ===
valid_passports_count = 0
passports = load_passports('day4.txt')
for p in passports:
valid_passports_count += validate_passport(p)
print(valid_passports_count)
| valid_passport_data = {'ecl', 'pid', 'eyr', 'hcl', 'byr', 'iyr', 'hgt'}
count_required_data = len(valid_passport_data)
def ecl_rule(value):
return value in {'amb', 'blu', 'brn', 'gry', 'grn', 'hzl', 'oth'}
def pid_rule(value):
try:
int(value)
isnumber = True
except:
isnumber = False
return len(value) == 9 and isnumber
def eyr_rule(value):
try:
year = int(value)
except:
return False
return year >= 2020 and year <= 2030
def hcl_rule(value):
try:
int(value[1:], 16)
except:
return False
return value[0] == '#' and len(value) == 7
def byr_rule(value):
try:
year = int(value)
except:
return False
return year >= 1920 and year <= 2002
def iyr_rule(value):
try:
year = int(value)
except:
return False
return year >= 2010 and year <= 2020
def hgt_rule(value):
units = value[-2:]
try:
height = float(value[:-2])
except:
return False
if units == 'cm':
return height >= 150.0 and height <= 193.0
if units == 'in':
return height >= 59.0 and height <= 76.0
return False
validation_rules = {'ecl': ecl_rule, 'pid': pid_rule, 'eyr': eyr_rule, 'hcl': hcl_rule, 'byr': byr_rule, 'hgt': hgt_rule, 'iyr': iyr_rule}
def load_passports(path):
with open(path, 'r') as file:
lines = file.readlines()
passports = []
passport_data = {}
for line in lines:
if ':' in line:
key_value_list = line.split()
for key_value in key_value_list:
(key, value) = key_value.split(':')
passport_data[key] = value
else:
passports.append(passport_data)
passport_data = {}
passports.append(passport_data)
return passports
def validate_passport(passport):
keys = set(passport)
common_data = valid_passport_data.intersection(keys)
if len(common_data) == count_required_data:
is_valid = True
for key in keys:
if key == 'cid':
continue
try:
value = passport[key]
is_valid = is_valid and validation_rules[key](value)
except Exception as e:
print(f'ValidationError: {e}')
return int(is_valid)
return 0
valid_passports_count = 0
passports = load_passports('day4.txt')
for p in passports:
valid_passports_count += validate_passport(p)
print(valid_passports_count) |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#-----------------------------------
# AutoNaptPython
#
# Copyright (c) 2018 RainForest
#
# This software is released under the MIT License.
# http://opensource.org/licenses/mit-license.php
#-----------------------------------
class Event2(object):
def __init__(self, doc = None):
self.handlers = []
self.__doc__ = doc
def __str__(self):
return 'Event<%s>' % str(self.__doc__)
def add(self, handler):
self.handlers.append(handler)
return self
def remove(self, handler):
self.handlers.remove(handler)
return self
def __call__(self, sender, e):
for handler in self.handlers:
handler(sender, e)
__iadd__ = add
__isub__ = remove
| class Event2(object):
def __init__(self, doc=None):
self.handlers = []
self.__doc__ = doc
def __str__(self):
return 'Event<%s>' % str(self.__doc__)
def add(self, handler):
self.handlers.append(handler)
return self
def remove(self, handler):
self.handlers.remove(handler)
return self
def __call__(self, sender, e):
for handler in self.handlers:
handler(sender, e)
__iadd__ = add
__isub__ = remove |
class Parser:
def __init__(self, directory, rel_path):
pass
def parse(self):
return {}, []
def get_parser(): return 5
| class Parser:
def __init__(self, directory, rel_path):
pass
def parse(self):
return ({}, [])
def get_parser():
return 5 |
# Set up constants
WIDTH = 25
HEIGHT = 6
LAYER_SIZE = WIDTH * HEIGHT
# Read in the input file and convert to a list
pixel_string = ""
with open("./input.txt") as f:
pixel_string = f.readline()
unlayered_pixel_values = list(pixel_string.strip())
# Make into a list of layers
idx = 0
layers = []
while idx < len(unlayered_pixel_values):
layers.append(unlayered_pixel_values[idx:(idx + LAYER_SIZE)])
idx += LAYER_SIZE
# Find the layer with the fewest zeroes
fewest_zeroes = LAYER_SIZE + 1
layer_with_fewest_zeroes = None
for i, layer in enumerate(layers):
zeroes = 0
for pixel in layer:
if pixel == "0":
zeroes += 1
if zeroes < fewest_zeroes:
fewest_zeroes = zeroes
layer_with_fewest_zeroes = i
# For the layer with the fewest zeroes, count the ones and twos
# and then print the product of the ones and the twos
layer_of_interest = layers[layer_with_fewest_zeroes]
ones = 0
twos = 0
for pixel in layer_of_interest:
if pixel == "1":
ones += 1
if pixel == "2":
twos += 1
product = ones * twos
print(product)
| width = 25
height = 6
layer_size = WIDTH * HEIGHT
pixel_string = ''
with open('./input.txt') as f:
pixel_string = f.readline()
unlayered_pixel_values = list(pixel_string.strip())
idx = 0
layers = []
while idx < len(unlayered_pixel_values):
layers.append(unlayered_pixel_values[idx:idx + LAYER_SIZE])
idx += LAYER_SIZE
fewest_zeroes = LAYER_SIZE + 1
layer_with_fewest_zeroes = None
for (i, layer) in enumerate(layers):
zeroes = 0
for pixel in layer:
if pixel == '0':
zeroes += 1
if zeroes < fewest_zeroes:
fewest_zeroes = zeroes
layer_with_fewest_zeroes = i
layer_of_interest = layers[layer_with_fewest_zeroes]
ones = 0
twos = 0
for pixel in layer_of_interest:
if pixel == '1':
ones += 1
if pixel == '2':
twos += 1
product = ones * twos
print(product) |
class CommandBuilder():
def __init__(self, cindex):
self.cindex = cindex
class CodeBuilder(CommandBuilder):
def __init__(self, cindex, cmd):
super().__init__(cindex)
self.cmd = cmd
def __str__(self):
return self.cmd
class SlugBuilder(CommandBuilder):
def __init__(self, cindex, time, location, transition):
super().__init__(cindex)
self.time = time
self.location = location
self.transition = transition
def __str__(self):
return F" scene bg {self.location}" + (F"\n with {self.transition}" if self.transition else "")
class ActorBuilder(CommandBuilder):
def __init__(self, cindex, alias, actor):
super().__init__(cindex)
self.alias = alias
self.actor = actor
def __str__(self):
return F"define {self.alias} = Character(\"{self.actor.upper()}\", color=\"#fff\")"
class LineBuilder(CommandBuilder):
def __init__(self, cindex, actor, blocking, line):
super().__init__(cindex)
self.actor = actor
self.blocking = blocking
self.line = line
def __str__(self):
return F" {self.actor} \"{self.line}\"" | class Commandbuilder:
def __init__(self, cindex):
self.cindex = cindex
class Codebuilder(CommandBuilder):
def __init__(self, cindex, cmd):
super().__init__(cindex)
self.cmd = cmd
def __str__(self):
return self.cmd
class Slugbuilder(CommandBuilder):
def __init__(self, cindex, time, location, transition):
super().__init__(cindex)
self.time = time
self.location = location
self.transition = transition
def __str__(self):
return f' scene bg {self.location}' + (f'\n with {self.transition}' if self.transition else '')
class Actorbuilder(CommandBuilder):
def __init__(self, cindex, alias, actor):
super().__init__(cindex)
self.alias = alias
self.actor = actor
def __str__(self):
return f'define {self.alias} = Character("{self.actor.upper()}", color="#fff")'
class Linebuilder(CommandBuilder):
def __init__(self, cindex, actor, blocking, line):
super().__init__(cindex)
self.actor = actor
self.blocking = blocking
self.line = line
def __str__(self):
return f' {self.actor} "{self.line}"' |
model_filename = "cifar10.model"
data_filename = "cifar10.npz"
model_url = "#"
data_url = "https://github.com/danielwilczak101/EasyNN/raw/datasets/cifar/cifar10.npz"
labels = {
0: "airplane",
1: "automobile",
2: "bird",
3: "cat",
4: "deer",
5: "dog",
6: "frog",
7: "horse",
8: "ship",
9: "truck"
} | model_filename = 'cifar10.model'
data_filename = 'cifar10.npz'
model_url = '#'
data_url = 'https://github.com/danielwilczak101/EasyNN/raw/datasets/cifar/cifar10.npz'
labels = {0: 'airplane', 1: 'automobile', 2: 'bird', 3: 'cat', 4: 'deer', 5: 'dog', 6: 'frog', 7: 'horse', 8: 'ship', 9: 'truck'} |
#Normalmenet se declara asi
#numero = 9
#La variable que se relaciona con la instancia de una clase
class Persona:
edad=18#Clase Persona con variable de clase que es edad
def __init__(self,nombre,nacionalidad):
self.nombre=nombre#variables de instancia
self.nacionalidad=nacionalidad
persona1= Persona("Jose","Mexicano")
#Acceder a una variable de clase
print(Persona.edad)# esta imprime (Variable de clase)
#Creando objeto para imprimir print(Persona.nombre) para el objeto persona2
persona2=Persona("Franklin","Colombo-Argentino")
print(persona2.nombre)# esta no imprime porque hay que crear el objeto (Variable de instancia)
| class Persona:
edad = 18
def __init__(self, nombre, nacionalidad):
self.nombre = nombre
self.nacionalidad = nacionalidad
persona1 = persona('Jose', 'Mexicano')
print(Persona.edad)
persona2 = persona('Franklin', 'Colombo-Argentino')
print(persona2.nombre) |
#
# PySNMP MIB module SIAE-IFEXT-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file://./sm_ifext.mib
# Produced by pysmi-0.3.2 at Fri Jul 19 08:18:02 2019
# On host 0e190c6811ee platform Linux version 4.9.125-linuxkit by user root
# Using Python version 3.7.3 (default, Apr 3 2019, 05:39:12)
#
Integer, OctetString, ObjectIdentifier = mibBuilder.importSymbols("ASN1", "Integer", "OctetString", "ObjectIdentifier")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ValueSizeConstraint, ConstraintsIntersection, ConstraintsUnion, SingleValueConstraint, ValueRangeConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueSizeConstraint", "ConstraintsIntersection", "ConstraintsUnion", "SingleValueConstraint", "ValueRangeConstraint")
InterfaceIndex, = mibBuilder.importSymbols("IF-MIB", "InterfaceIndex")
AlarmSeverityCode, AlarmStatus = mibBuilder.importSymbols("SIAE-ALARM-MIB", "AlarmSeverityCode", "AlarmStatus")
siaeMib, = mibBuilder.importSymbols("SIAE-TREE-MIB", "siaeMib")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
ObjectIdentity, Counter64, Bits, Gauge32, MibIdentifier, iso, NotificationType, Counter32, MibScalar, MibTable, MibTableRow, MibTableColumn, TimeTicks, Unsigned32, IpAddress, Integer32, ModuleIdentity = mibBuilder.importSymbols("SNMPv2-SMI", "ObjectIdentity", "Counter64", "Bits", "Gauge32", "MibIdentifier", "iso", "NotificationType", "Counter32", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "TimeTicks", "Unsigned32", "IpAddress", "Integer32", "ModuleIdentity")
DisplayString, RowStatus, TextualConvention = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "RowStatus", "TextualConvention")
ifext = ModuleIdentity((1, 3, 6, 1, 4, 1, 3373, 1103, 73))
ifext.setRevisions(('2015-07-21 00:00', '2014-12-02 00:00', '2014-09-26 00:00', '2014-06-05 00:00', '2014-02-21 00:00', '2013-10-28 00:00',))
if mibBuilder.loadTexts: ifext.setLastUpdated('201507210000Z')
if mibBuilder.loadTexts: ifext.setOrganization('SIAE MICROELETTRONICA spa')
ifextMibVersion = MibScalar((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 1), Integer32().clone(1)).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextMibVersion.setStatus('current')
ifextTable = MibTable((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2), )
if mibBuilder.loadTexts: ifextTable.setStatus('current')
ifextTableEntry = MibTableRow((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1), ).setIndexNames((0, "SIAE-IFEXT-MIB", "ifextIfIndex"))
if mibBuilder.loadTexts: ifextTableEntry.setStatus('current')
ifextIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 1), InterfaceIndex())
if mibBuilder.loadTexts: ifextIfIndex.setStatus('current')
ifextLabel = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 2), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 31))).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextLabel.setStatus('current')
ifextAdminStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("up", 1), ("down", 2), ("testing", 3), ("loopback", 4))).clone('down')).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextAdminStatus.setStatus('current')
ifextPortUsage = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 4), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2, 3, 4, 5, 6))).clone(namedValues=NamedValues(("unused", 0), ("lan", 1), ("radio", 2), ("mgmt", 3), ("stack", 4), ("aux", 5), ("pwe3", 6)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextPortUsage.setStatus('current')
ifextMediumType = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("copper", 1), ("fiber", 2), ("combo", 3), ("other", 4)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextMediumType.setStatus('current')
ifextMediumSelection = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 6), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2))).clone(namedValues=NamedValues(("none", 0), ("copper", 1), ("fiber", 2))).clone('none')).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextMediumSelection.setStatus('current')
ifextAlarmReportEnable = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 7), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("disable", 1), ("enable", 2))).clone('enable')).setMaxAccess("readcreate")
if mibBuilder.loadTexts: ifextAlarmReportEnable.setStatus('current')
ifextSfpId = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 8), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextSfpId.setStatus('current')
ifextCapabilities = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 9), Bits().clone(namedValues=NamedValues(("ifextCapabilityLoop", 0), ("ifextCapability2g5Bps", 1), ("ifextCapabilityMabSensor", 2), ("ifextCapabilityEncrypt", 3)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextCapabilities.setStatus('current')
ifextLosAlarm = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 10), AlarmStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextLosAlarm.setStatus('current')
ifextRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 11), RowStatus()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: ifextRowStatus.setStatus('current')
ifextMaintTable = MibTable((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 3), )
if mibBuilder.loadTexts: ifextMaintTable.setStatus('current')
ifextMaintTableEntry = MibTableRow((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 3, 1), ).setIndexNames((0, "SIAE-IFEXT-MIB", "ifextIfIndex"))
if mibBuilder.loadTexts: ifextMaintTableEntry.setStatus('current')
ifextLineLoop = MibTableColumn((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 3, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("disable", 1), ("enable", 2)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifextLineLoop.setStatus('current')
ifextLosAlarmSeverityCode = MibScalar((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 5), AlarmSeverityCode().clone('majorTrapEnable')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ifextLosAlarmSeverityCode.setStatus('current')
mibBuilder.exportSymbols("SIAE-IFEXT-MIB", ifextLabel=ifextLabel, ifextAlarmReportEnable=ifextAlarmReportEnable, ifextMaintTable=ifextMaintTable, ifextMediumType=ifextMediumType, ifextMaintTableEntry=ifextMaintTableEntry, ifextPortUsage=ifextPortUsage, ifextRowStatus=ifextRowStatus, ifextLineLoop=ifextLineLoop, ifextLosAlarm=ifextLosAlarm, ifextCapabilities=ifextCapabilities, ifextIfIndex=ifextIfIndex, ifextTableEntry=ifextTableEntry, ifextMibVersion=ifextMibVersion, PYSNMP_MODULE_ID=ifext, ifextSfpId=ifextSfpId, ifextTable=ifextTable, ifextLosAlarmSeverityCode=ifextLosAlarmSeverityCode, ifext=ifext, ifextMediumSelection=ifextMediumSelection, ifextAdminStatus=ifextAdminStatus)
| (integer, octet_string, object_identifier) = mibBuilder.importSymbols('ASN1', 'Integer', 'OctetString', 'ObjectIdentifier')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(value_size_constraint, constraints_intersection, constraints_union, single_value_constraint, value_range_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ValueSizeConstraint', 'ConstraintsIntersection', 'ConstraintsUnion', 'SingleValueConstraint', 'ValueRangeConstraint')
(interface_index,) = mibBuilder.importSymbols('IF-MIB', 'InterfaceIndex')
(alarm_severity_code, alarm_status) = mibBuilder.importSymbols('SIAE-ALARM-MIB', 'AlarmSeverityCode', 'AlarmStatus')
(siae_mib,) = mibBuilder.importSymbols('SIAE-TREE-MIB', 'siaeMib')
(notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance')
(object_identity, counter64, bits, gauge32, mib_identifier, iso, notification_type, counter32, mib_scalar, mib_table, mib_table_row, mib_table_column, time_ticks, unsigned32, ip_address, integer32, module_identity) = mibBuilder.importSymbols('SNMPv2-SMI', 'ObjectIdentity', 'Counter64', 'Bits', 'Gauge32', 'MibIdentifier', 'iso', 'NotificationType', 'Counter32', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'TimeTicks', 'Unsigned32', 'IpAddress', 'Integer32', 'ModuleIdentity')
(display_string, row_status, textual_convention) = mibBuilder.importSymbols('SNMPv2-TC', 'DisplayString', 'RowStatus', 'TextualConvention')
ifext = module_identity((1, 3, 6, 1, 4, 1, 3373, 1103, 73))
ifext.setRevisions(('2015-07-21 00:00', '2014-12-02 00:00', '2014-09-26 00:00', '2014-06-05 00:00', '2014-02-21 00:00', '2013-10-28 00:00'))
if mibBuilder.loadTexts:
ifext.setLastUpdated('201507210000Z')
if mibBuilder.loadTexts:
ifext.setOrganization('SIAE MICROELETTRONICA spa')
ifext_mib_version = mib_scalar((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 1), integer32().clone(1)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextMibVersion.setStatus('current')
ifext_table = mib_table((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2))
if mibBuilder.loadTexts:
ifextTable.setStatus('current')
ifext_table_entry = mib_table_row((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1)).setIndexNames((0, 'SIAE-IFEXT-MIB', 'ifextIfIndex'))
if mibBuilder.loadTexts:
ifextTableEntry.setStatus('current')
ifext_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 1), interface_index())
if mibBuilder.loadTexts:
ifextIfIndex.setStatus('current')
ifext_label = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 2), display_string().subtype(subtypeSpec=value_size_constraint(0, 31))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextLabel.setStatus('current')
ifext_admin_status = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 3), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4))).clone(namedValues=named_values(('up', 1), ('down', 2), ('testing', 3), ('loopback', 4))).clone('down')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextAdminStatus.setStatus('current')
ifext_port_usage = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 4), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1, 2, 3, 4, 5, 6))).clone(namedValues=named_values(('unused', 0), ('lan', 1), ('radio', 2), ('mgmt', 3), ('stack', 4), ('aux', 5), ('pwe3', 6)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextPortUsage.setStatus('current')
ifext_medium_type = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 5), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4))).clone(namedValues=named_values(('copper', 1), ('fiber', 2), ('combo', 3), ('other', 4)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextMediumType.setStatus('current')
ifext_medium_selection = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 6), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1, 2))).clone(namedValues=named_values(('none', 0), ('copper', 1), ('fiber', 2))).clone('none')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextMediumSelection.setStatus('current')
ifext_alarm_report_enable = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 7), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('disable', 1), ('enable', 2))).clone('enable')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
ifextAlarmReportEnable.setStatus('current')
ifext_sfp_id = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 8), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextSfpId.setStatus('current')
ifext_capabilities = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 9), bits().clone(namedValues=named_values(('ifextCapabilityLoop', 0), ('ifextCapability2g5Bps', 1), ('ifextCapabilityMabSensor', 2), ('ifextCapabilityEncrypt', 3)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextCapabilities.setStatus('current')
ifext_los_alarm = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 10), alarm_status()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextLosAlarm.setStatus('current')
ifext_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 2, 1, 11), row_status()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
ifextRowStatus.setStatus('current')
ifext_maint_table = mib_table((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 3))
if mibBuilder.loadTexts:
ifextMaintTable.setStatus('current')
ifext_maint_table_entry = mib_table_row((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 3, 1)).setIndexNames((0, 'SIAE-IFEXT-MIB', 'ifextIfIndex'))
if mibBuilder.loadTexts:
ifextMaintTableEntry.setStatus('current')
ifext_line_loop = mib_table_column((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 3, 1, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('disable', 1), ('enable', 2)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifextLineLoop.setStatus('current')
ifext_los_alarm_severity_code = mib_scalar((1, 3, 6, 1, 4, 1, 3373, 1103, 73, 5), alarm_severity_code().clone('majorTrapEnable')).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ifextLosAlarmSeverityCode.setStatus('current')
mibBuilder.exportSymbols('SIAE-IFEXT-MIB', ifextLabel=ifextLabel, ifextAlarmReportEnable=ifextAlarmReportEnable, ifextMaintTable=ifextMaintTable, ifextMediumType=ifextMediumType, ifextMaintTableEntry=ifextMaintTableEntry, ifextPortUsage=ifextPortUsage, ifextRowStatus=ifextRowStatus, ifextLineLoop=ifextLineLoop, ifextLosAlarm=ifextLosAlarm, ifextCapabilities=ifextCapabilities, ifextIfIndex=ifextIfIndex, ifextTableEntry=ifextTableEntry, ifextMibVersion=ifextMibVersion, PYSNMP_MODULE_ID=ifext, ifextSfpId=ifextSfpId, ifextTable=ifextTable, ifextLosAlarmSeverityCode=ifextLosAlarmSeverityCode, ifext=ifext, ifextMediumSelection=ifextMediumSelection, ifextAdminStatus=ifextAdminStatus) |
a = float(input("a = "))
b = float(input("b = "))
c = float(input("c = "))
if a==b==c:
print('nothing')
elif a==c:
print(2)
elif b==a:
print(3)
elif b==c:
print(1)
else:
print('nothing')
| a = float(input('a = '))
b = float(input('b = '))
c = float(input('c = '))
if a == b == c:
print('nothing')
elif a == c:
print(2)
elif b == a:
print(3)
elif b == c:
print(1)
else:
print('nothing') |
def fib(n):
'''
uses generater to return fibonacci sequence
up to given # n dynamically
'''
a,b = 1,1
for _ in range(0,n):
yield a
a,b = b,a+b
return a
| def fib(n):
"""
uses generater to return fibonacci sequence
up to given # n dynamically
"""
(a, b) = (1, 1)
for _ in range(0, n):
yield a
(a, b) = (b, a + b)
return a |
config = {
"qqGroup": "",
"pro_ids": ['11111', '22222'],
"daily": {
"pro_ids": ['11111']
},
# "pk": {
# "me": "22222",
# "vs": ['33333']
# }
"dailyInterval": 25,
"pkInterval": 30
}
| config = {'qqGroup': '', 'pro_ids': ['11111', '22222'], 'daily': {'pro_ids': ['11111']}, 'dailyInterval': 25, 'pkInterval': 30} |
class ListNode:
def __init__(self, x):
self.val = x
self.next = None
class Solution:
def swapPairs(self, head):
if not head:
return None
if not head.next:
return head
curr = head
after = head.next
pre = None
head = after
while after:
curr.next = after.next
after.next = curr
if pre:
pre.next = after
tmp = curr
curr = after
after = tmp
if not after.next:
break
pre = curr.next
curr = curr.next.next
after = after.next.next
print(pre.val)
return head
solution = Solution()
a = ListNode(0)
b = ListNode(1)
c = ListNode(2)
d = ListNode(3)
a.next = b
b.next = c
x = solution.swapPairs(a)
while x:
print(x.val)
x = x.next | class Listnode:
def __init__(self, x):
self.val = x
self.next = None
class Solution:
def swap_pairs(self, head):
if not head:
return None
if not head.next:
return head
curr = head
after = head.next
pre = None
head = after
while after:
curr.next = after.next
after.next = curr
if pre:
pre.next = after
tmp = curr
curr = after
after = tmp
if not after.next:
break
pre = curr.next
curr = curr.next.next
after = after.next.next
print(pre.val)
return head
solution = solution()
a = list_node(0)
b = list_node(1)
c = list_node(2)
d = list_node(3)
a.next = b
b.next = c
x = solution.swapPairs(a)
while x:
print(x.val)
x = x.next |
{
'targets': [
{
'target_name': 'brotli',
'type': 'static_library',
'include_dirs': ['c/include'],
'conditions': [
['OS=="linux"', {
'defines': [
'OS_LINUX'
]
}],
['OS=="freebsd"', {
'defines': [
'OS_FREEBSD'
]
}],
['OS=="mac"', {
'defines': [
'OS_MACOSX'
]
}],
],
'direct_dependent_settings': {
'include_dirs': [ 'c/include' ]
},
'libraries': [
'-lm',
],
'sources': [
# Common
'c/common/dictionary.c',
'c/common/transform.c',
# Decoder
'c/dec/bit_reader.c',
'c/dec/decode.c',
'c/dec/huffman.c',
'c/dec/state.c',
# Encoder
'c/enc/backward_references.c',
'c/enc/backward_references_hq.c',
'c/enc/bit_cost.c',
'c/enc/block_splitter.c',
'c/enc/brotli_bit_stream.c',
'c/enc/cluster.c',
'c/enc/compress_fragment.c',
'c/enc/compress_fragment_two_pass.c',
'c/enc/dictionary_hash.c',
'c/enc/encode.c',
'c/enc/encoder_dict.c',
'c/enc/entropy_encode.c',
'c/enc/histogram.c',
'c/enc/literal_cost.c',
'c/enc/memory.c',
'c/enc/metablock.c',
'c/enc/static_dict.c',
'c/enc/utf8_util.c'
]
}
]
}
| {'targets': [{'target_name': 'brotli', 'type': 'static_library', 'include_dirs': ['c/include'], 'conditions': [['OS=="linux"', {'defines': ['OS_LINUX']}], ['OS=="freebsd"', {'defines': ['OS_FREEBSD']}], ['OS=="mac"', {'defines': ['OS_MACOSX']}]], 'direct_dependent_settings': {'include_dirs': ['c/include']}, 'libraries': ['-lm'], 'sources': ['c/common/dictionary.c', 'c/common/transform.c', 'c/dec/bit_reader.c', 'c/dec/decode.c', 'c/dec/huffman.c', 'c/dec/state.c', 'c/enc/backward_references.c', 'c/enc/backward_references_hq.c', 'c/enc/bit_cost.c', 'c/enc/block_splitter.c', 'c/enc/brotli_bit_stream.c', 'c/enc/cluster.c', 'c/enc/compress_fragment.c', 'c/enc/compress_fragment_two_pass.c', 'c/enc/dictionary_hash.c', 'c/enc/encode.c', 'c/enc/encoder_dict.c', 'c/enc/entropy_encode.c', 'c/enc/histogram.c', 'c/enc/literal_cost.c', 'c/enc/memory.c', 'c/enc/metablock.c', 'c/enc/static_dict.c', 'c/enc/utf8_util.c']}]} |
{
'variables': {
'base_cflags': [
'-Wall',
'-Wextra',
'-Wno-unused-parameter',
'-std=c++11',
],
'debug_cflags': ['-g', '-O0'],
'release_cflags': ['-O3'],
},
'targets': [
{
'target_name': 'tonclient',
'sources': ['binding.cc'],
'conditions': [
['OS == "win"', {
'libraries': [
'../tonclient.lib',
'advapi32.lib',
'ws2_32.lib',
'userenv.lib',
'shell32.lib',
'Secur32.lib',
'Crypt32.lib',
],
}, {
'libraries': [
'../libtonclient.a',
'-Wl,-rpath,./addon/'
],
}],
],
'configurations': {
'Debug': {
'cflags': ['<@(debug_cflags)'],
'xcode_settings': {
'OTHER_CFLAGS': ['<@(debug_cflags)'],
},
},
'Release': {
'cflags': ['<@(release_cflags)'],
'xcode_settings': {
'OTHER_CFLAGS': ['<@(release_cflags)'],
},
},
},
'cflags': ['<@(base_cflags)'],
'xcode_settings': {
'OTHER_CFLAGS': ['<@(base_cflags)'],
},
},
],
}
| {'variables': {'base_cflags': ['-Wall', '-Wextra', '-Wno-unused-parameter', '-std=c++11'], 'debug_cflags': ['-g', '-O0'], 'release_cflags': ['-O3']}, 'targets': [{'target_name': 'tonclient', 'sources': ['binding.cc'], 'conditions': [['OS == "win"', {'libraries': ['../tonclient.lib', 'advapi32.lib', 'ws2_32.lib', 'userenv.lib', 'shell32.lib', 'Secur32.lib', 'Crypt32.lib']}, {'libraries': ['../libtonclient.a', '-Wl,-rpath,./addon/']}]], 'configurations': {'Debug': {'cflags': ['<@(debug_cflags)'], 'xcode_settings': {'OTHER_CFLAGS': ['<@(debug_cflags)']}}, 'Release': {'cflags': ['<@(release_cflags)'], 'xcode_settings': {'OTHER_CFLAGS': ['<@(release_cflags)']}}}, 'cflags': ['<@(base_cflags)'], 'xcode_settings': {'OTHER_CFLAGS': ['<@(base_cflags)']}}]} |
int1 = input("Enter first integer: ")
int2 = input("Enter second integer: ")
sum = int(int1) + int(int2)
if sum in range(105, 201):
print(200)
| int1 = input('Enter first integer: ')
int2 = input('Enter second integer: ')
sum = int(int1) + int(int2)
if sum in range(105, 201):
print(200) |
# Create Plotter
acc_plotter = skdiscovery.data_structure.series.accumulators.Plotter('Plotter')
# Create stage containter for Plotter
sc_plotter = StageContainer(acc_plotter)
| acc_plotter = skdiscovery.data_structure.series.accumulators.Plotter('Plotter')
sc_plotter = stage_container(acc_plotter) |
# ----------------------------------------------------------------------
# ctokens.py
#
# Token specifications for symbols in ANSI C and C++. This file is
# meant to be used as a library in other tokenizers.
# ----------------------------------------------------------------------
# Reserved words
tokens = [
# Literals (identifier, integer constant, float constant, string constant, char const)
'ID', 'TYPEID', 'INTEGER', 'FLOAT', 'STRING', 'CHARACTER',
# Operators (+,-,*,/,%,|,&,~,^,<<,>>, ||, &&, !, <, <=, >, >=, ==, !=)
'PLUS', 'MINUS', 'TIMES', 'DIVIDE', 'MODULO',
'OR', 'AND', 'NOT', 'XOR', 'LSHIFT', 'RSHIFT',
'LOR', 'LAND', 'LNOT',
'LT', 'LE', 'GT', 'GE', 'EQ', 'NE',
# Assignment (=, *=, /=, %=, +=, -=, <<=, >>=, &=, ^=, |=)
'EQUALS', 'TIMESEQUAL', 'DIVEQUAL', 'MODEQUAL', 'PLUSEQUAL', 'MINUSEQUAL',
'LSHIFTEQUAL','RSHIFTEQUAL', 'ANDEQUAL', 'XOREQUAL', 'OREQUAL',
# Increment/decrement (++,--)
'INCREMENT', 'DECREMENT',
# Structure dereference (->)
'ARROW',
# Ternary operator (?)
'TERNARY',
# Delimeters ( ) [ ] { } , . ; :
'LPAREN', 'RPAREN',
'LBRACKET', 'RBRACKET',
'LBRACE', 'RBRACE',
'COMMA', 'PERIOD', 'SEMI', 'COLON',
# Ellipsis (...)
'ELLIPSIS',
]
# Operators
t_PLUS = r'\+'
t_MINUS = r'-'
t_TIMES = r'\*'
t_DIVIDE = r'/'
t_MODULO = r'%'
t_OR = r'\|'
t_AND = r'&'
t_NOT = r'~'
t_XOR = r'\^'
t_LSHIFT = r'<<'
t_RSHIFT = r'>>'
t_LOR = r'\|\|'
t_LAND = r'&&'
t_LNOT = r'!'
t_LT = r'<'
t_GT = r'>'
t_LE = r'<='
t_GE = r'>='
t_EQ = r'=='
t_NE = r'!='
# Assignment operators
t_EQUALS = r'='
t_TIMESEQUAL = r'\*='
t_DIVEQUAL = r'/='
t_MODEQUAL = r'%='
t_PLUSEQUAL = r'\+='
t_MINUSEQUAL = r'-='
t_LSHIFTEQUAL = r'<<='
t_RSHIFTEQUAL = r'>>='
t_ANDEQUAL = r'&='
t_OREQUAL = r'\|='
t_XOREQUAL = r'\^='
# Increment/decrement
t_INCREMENT = r'\+\+'
t_DECREMENT = r'--'
# ->
t_ARROW = r'->'
# ?
t_TERNARY = r'\?'
# Delimeters
t_LPAREN = r'\('
t_RPAREN = r'\)'
t_LBRACKET = r'\['
t_RBRACKET = r'\]'
t_LBRACE = r'\{'
t_RBRACE = r'\}'
t_COMMA = r','
t_PERIOD = r'\.'
t_SEMI = r';'
t_COLON = r':'
t_ELLIPSIS = r'\.\.\.'
# Identifiers
t_ID = r'[A-Za-z_][A-Za-z0-9_]*'
# Integer literal
t_INTEGER = r'\d+([uU]|[lL]|[uU][lL]|[lL][uU])?'
# Floating literal
t_FLOAT = r'((\d+)(\.\d+)(e(\+|-)?(\d+))? | (\d+)e(\+|-)?(\d+))([lL]|[fF])?'
# String literal
t_STRING = r'\"([^\\\n]|(\\.))*?\"'
# Character constant 'c' or L'c'
t_CHARACTER = r'(L)?\'([^\\\n]|(\\.))*?\''
# Comment (C-Style)
def t_COMMENT(t):
r'/\*(.|\n)*?\*/'
t.lexer.lineno += t.value.count('\n')
return t
# Comment (C++-Style)
def t_CPPCOMMENT(t):
r'//.*\n'
t.lexer.lineno += 1
return t
| tokens = ['ID', 'TYPEID', 'INTEGER', 'FLOAT', 'STRING', 'CHARACTER', 'PLUS', 'MINUS', 'TIMES', 'DIVIDE', 'MODULO', 'OR', 'AND', 'NOT', 'XOR', 'LSHIFT', 'RSHIFT', 'LOR', 'LAND', 'LNOT', 'LT', 'LE', 'GT', 'GE', 'EQ', 'NE', 'EQUALS', 'TIMESEQUAL', 'DIVEQUAL', 'MODEQUAL', 'PLUSEQUAL', 'MINUSEQUAL', 'LSHIFTEQUAL', 'RSHIFTEQUAL', 'ANDEQUAL', 'XOREQUAL', 'OREQUAL', 'INCREMENT', 'DECREMENT', 'ARROW', 'TERNARY', 'LPAREN', 'RPAREN', 'LBRACKET', 'RBRACKET', 'LBRACE', 'RBRACE', 'COMMA', 'PERIOD', 'SEMI', 'COLON', 'ELLIPSIS']
t_plus = '\\+'
t_minus = '-'
t_times = '\\*'
t_divide = '/'
t_modulo = '%'
t_or = '\\|'
t_and = '&'
t_not = '~'
t_xor = '\\^'
t_lshift = '<<'
t_rshift = '>>'
t_lor = '\\|\\|'
t_land = '&&'
t_lnot = '!'
t_lt = '<'
t_gt = '>'
t_le = '<='
t_ge = '>='
t_eq = '=='
t_ne = '!='
t_equals = '='
t_timesequal = '\\*='
t_divequal = '/='
t_modequal = '%='
t_plusequal = '\\+='
t_minusequal = '-='
t_lshiftequal = '<<='
t_rshiftequal = '>>='
t_andequal = '&='
t_orequal = '\\|='
t_xorequal = '\\^='
t_increment = '\\+\\+'
t_decrement = '--'
t_arrow = '->'
t_ternary = '\\?'
t_lparen = '\\('
t_rparen = '\\)'
t_lbracket = '\\['
t_rbracket = '\\]'
t_lbrace = '\\{'
t_rbrace = '\\}'
t_comma = ','
t_period = '\\.'
t_semi = ';'
t_colon = ':'
t_ellipsis = '\\.\\.\\.'
t_id = '[A-Za-z_][A-Za-z0-9_]*'
t_integer = '\\d+([uU]|[lL]|[uU][lL]|[lL][uU])?'
t_float = '((\\d+)(\\.\\d+)(e(\\+|-)?(\\d+))? | (\\d+)e(\\+|-)?(\\d+))([lL]|[fF])?'
t_string = '\\"([^\\\\\\n]|(\\\\.))*?\\"'
t_character = "(L)?\\'([^\\\\\\n]|(\\\\.))*?\\'"
def t_comment(t):
"""/\\*(.|\\n)*?\\*/"""
t.lexer.lineno += t.value.count('\n')
return t
def t_cppcomment(t):
"""//.*\\n"""
t.lexer.lineno += 1
return t |
twitch_icon = "<:twitch:404633403603025921> "
cmd_fail = "<:tickNo:342738745092734976> "
cmd_success = "<:tickYes:342738345673228290> "
loading = "<a:loading:515632705262583819> "
bullet = "<:bullet:516382013779869726> "
right_arrow_alt = "<:arrow:343407434746036224>"
left_arrow = "<a:a_left_arrow:527634992415899650>"
right_arrow = "<a:a_right_arrow:527634993015685130>"
| twitch_icon = '<:twitch:404633403603025921> '
cmd_fail = '<:tickNo:342738745092734976> '
cmd_success = '<:tickYes:342738345673228290> '
loading = '<a:loading:515632705262583819> '
bullet = '<:bullet:516382013779869726> '
right_arrow_alt = '<:arrow:343407434746036224>'
left_arrow = '<a:a_left_arrow:527634992415899650>'
right_arrow = '<a:a_right_arrow:527634993015685130>' |
list_a = [10, 20, 30]
list_b = ["Jan", "Peter", "Max"]
list_c = [True, False, True]
for val_a, val_b, val_c in zip(list_a, list_b, list_c):
print(val_a, val_b, val_c)
print("\n")
for i in range(len(list_a)):
print(i, list_a[i])
print("\n")
for i, val in enumerate(list_a):
print(i, val)
| list_a = [10, 20, 30]
list_b = ['Jan', 'Peter', 'Max']
list_c = [True, False, True]
for (val_a, val_b, val_c) in zip(list_a, list_b, list_c):
print(val_a, val_b, val_c)
print('\n')
for i in range(len(list_a)):
print(i, list_a[i])
print('\n')
for (i, val) in enumerate(list_a):
print(i, val) |
PATH_DATA = "../train_data/pan20-author-profiling-training-2020-02-23"
PATH_DATA_EN = "../train_data/pan20-author-profiling-training-2020-02-23/en"
PATH_DATA_ES = "../train_data/pan20-author-profiling-training-2020-02-23/es"
PATH_DATA_EN_TRUTH = "../train_data/pan20-author-profiling-training-2020-02-23/en/truth.txt"
PATH_DATA_ES_TRUTH = "../train_data/pan20-author-profiling-training-2020-02-23/es/truth.txt"
PATH_EXPR = "../expr"
PATH_MODELS = "../models"
PATH_OUT = "../out"
PATH_IMGS = "../imgs"
#D2V
D2V_EPOCHS = 50
D2V_LR = 0.01
D2V_VS = 100
#TPOT
TPOT_OUT = 2
#EXTENDED_TFIDF
parametersWide = {"loss":["hinge","log","modified_huber"], \
"penalty":["elasticnet"],"alpha":[0.01,0.001,0.0001,0.0005],\
"l1_ratio":[0.05,0.25,0.3,0.6,0.8,0.95], \
"power_t":[0.5,0.1,0.9]}
#TIRA_ONE_PARAMTERES
parametersTIRA_DIMS = [256,512,768]
parametersTIRA_FEATURES = [2500,5000,10000,15000]
parametersTIRA_GS1 = {"loss":["hinge","log"],\
"penalty":["elasticnet"],\
"alpha":[0.01,0.001,0.0001,0.0005],\
"l1_ratio":[0.05,0.25,0.3,0.6,0.8,0.95],\
"power_t":[0.5,0.1,0.9]}
parametersTIRA_GS2 = {"C":[0.1,1,10,25,50,100,500],"penalty":["l2"]}
| path_data = '../train_data/pan20-author-profiling-training-2020-02-23'
path_data_en = '../train_data/pan20-author-profiling-training-2020-02-23/en'
path_data_es = '../train_data/pan20-author-profiling-training-2020-02-23/es'
path_data_en_truth = '../train_data/pan20-author-profiling-training-2020-02-23/en/truth.txt'
path_data_es_truth = '../train_data/pan20-author-profiling-training-2020-02-23/es/truth.txt'
path_expr = '../expr'
path_models = '../models'
path_out = '../out'
path_imgs = '../imgs'
d2_v_epochs = 50
d2_v_lr = 0.01
d2_v_vs = 100
tpot_out = 2
parameters_wide = {'loss': ['hinge', 'log', 'modified_huber'], 'penalty': ['elasticnet'], 'alpha': [0.01, 0.001, 0.0001, 0.0005], 'l1_ratio': [0.05, 0.25, 0.3, 0.6, 0.8, 0.95], 'power_t': [0.5, 0.1, 0.9]}
parameters_tira_dims = [256, 512, 768]
parameters_tira_features = [2500, 5000, 10000, 15000]
parameters_tira_gs1 = {'loss': ['hinge', 'log'], 'penalty': ['elasticnet'], 'alpha': [0.01, 0.001, 0.0001, 0.0005], 'l1_ratio': [0.05, 0.25, 0.3, 0.6, 0.8, 0.95], 'power_t': [0.5, 0.1, 0.9]}
parameters_tira_gs2 = {'C': [0.1, 1, 10, 25, 50, 100, 500], 'penalty': ['l2']} |
__all__ = ['Meta']
class Meta:
pass
| __all__ = ['Meta']
class Meta:
pass |
def good():
return ['Harry', 'Ron', 'Hermione']
# expected output:
'''
['Harry', 'Ron', 'Hermione']
'''
print( good() ) | def good():
return ['Harry', 'Ron', 'Hermione']
"\n['Harry', 'Ron', 'Hermione'] \n"
print(good()) |
glosario = {'listas' : "Se pueden identificar con []", 'tuplas' : "Se identifican con *()",
'glosario' : "Se identifican con {}", 'if' : "Condicional", 'for' : "Ciclo", '#' : "Para crear un comentario",
'str' : "Abreviacion de String", '==' : "usado para comparar elementos", "=!" : "Usado para verificar que dos elementos son diferentes",
'and' : "Usado en condicionales para comprar mas formas a los elementos"}
for clave in glosario.values():
print(clave.title()) | glosario = {'listas': 'Se pueden identificar con []', 'tuplas': 'Se identifican con *()', 'glosario': 'Se identifican con {}', 'if': 'Condicional', 'for': 'Ciclo', '#': 'Para crear un comentario', 'str': 'Abreviacion de String', '==': 'usado para comparar elementos', '=!': 'Usado para verificar que dos elementos son diferentes', 'and': 'Usado en condicionales para comprar mas formas a los elementos'}
for clave in glosario.values():
print(clave.title()) |
n = 8
fib0 = 0
fib1 = 1
if n > 0:
temp = fib0
fib0 = fib1
fib1 = fib1 + temp
n = n - 1
else:
print(f'Resultado {fib0}') | n = 8
fib0 = 0
fib1 = 1
if n > 0:
temp = fib0
fib0 = fib1
fib1 = fib1 + temp
n = n - 1
else:
print(f'Resultado {fib0}') |
class ShellGame(object):
def __init__(self, start, swaps):
self.start = start
self.swaps = swaps
def find_the_ball(self):
if len(self.swaps) == 0:
return self.start
else:
for pos in self.swaps:
for x in pos:
self.start = x
return self.start
| class Shellgame(object):
def __init__(self, start, swaps):
self.start = start
self.swaps = swaps
def find_the_ball(self):
if len(self.swaps) == 0:
return self.start
else:
for pos in self.swaps:
for x in pos:
self.start = x
return self.start |
ROP_POPJUMPLR_STACK12 = 0x0101CD24;
ROP_POPJUMPLR_STACK20 = 0x01024D88;
ROP_CALLFUNC = 0x01080274;
ROP_CALLR28_POP_R28_TO_R31 = 0x0107DD70;
ROP_POP_R28R29R30R31 = 0x0101D8D4;
ROP_POP_R27 = 0x0101CB00;
ROP_POP_R24_TO_R31 = 0x010204C8;
ROP_CALLFUNCPTR_WITHARGS_FROM_R3MEM = 0x010253C0;
ROP_SETR3TOR31_POP_R31 = 0x0101CC10;
ROP_Register = 0x010277B8;
ROP_Deregister = 0x010277C4;
ROP_CopyToSaveArea = 0x010277DC;
ROP_CopyFromSaveArea = 0x010277D0;
ROP_CreateThreadInternal = 0x01041BA8;
ROP_LR_TO_0XC_R1 = 0x0101CD24;
ROP_lwz_r3_0_r3__lwz_r0_0xc_r1__mtlr_r0__addi_r1_r1_8__blr = 0x01040C58;
ROP_memcpy = 0x01035FC8;
ROP_DCFlushRange = 0x01023F88;
ROP_ICInvalidateRange = 0x010240B0;
ROP_OSSwitchSecCodeGenMode = 0x010376C0;
ROP_OSCodegenCopy = 0x010376D8;
ROP_OSGetCodegenVirtAddrRange = 0x010375C0;
ROP_OSGetCoreId = 0x01024E8C;
ROP_OSGetCurrentThread = 0x01043150;
ROP_OSSetThreadAffinity = 0x010429DC;
ROP_OSYieldThread = 0x010418E4;
ROP_OSFatal = 0x01031618;
ROP_Exit = 0x0101CD80;
ROP_OSScreenFlipBuffersEx = 0x0103AFD0;
ROP_OSScreenClearBufferEx = 0x0103B090;
ROP_OSDynLoad_Acquire = 0x0102A3B4;
ROP_OSDynLoad_FindExport = 0x0102B828;
ROP_os_snprintf = 0x0102F160;
ROP_OSSendAppSwitchRequest = 0x01039C30;
ROP_OSExitThread = 0x01041D6C;
ROP_OSSleepTicks = 0x0104274C;
ROP_OSTestAndSetAtomic64 = 0x010229BC;
ROP_OSDisableInterrupts = 0x01033250;
ROP_OSForceFullRelaunch = 0x01035FA8;
ROP_OSRestoreInterrupts = 0x01033368;
ROP__Exit = 0x0101CD80;
ROP_OSCreateThread = 0x01041B64;
ROP_OSResumeThread = 0x01042108;
ROP_IM_Open = 0x010821F0;
ROP_IM_SetDeviceState = 0x01082598;
ROP_IM_Close = 0x01082200;
ROP___PPCExit = 0x0101C580;
ROP_OSRequestFastExit = 0x01039630;
ROP_OSRestartCrashedApp = 0x010302DC;
ROP_OSShutdown = 0x0101FD0C;
ROP_OSSuspendThread = 0x01042C60;
ROP_OSRunThreadsOnExit = 0x01047644;
ROP_OSBlockThreadsOnExit = 0x01047628;
ROP_GX2SetSemaphore_2C = 0x01157F18;
ROP_GX2_r3r4load = 0x0114EF74;
ROP_GX2_r30r31load = 0x011519EC;
ROP_GX2_do_flush = 0x0114F394;
ROP_GX2_call_r12 = 0x01189DDC;
ROP_GX2Init = 0x01156B78;
ROP_GX2Shutdown = 0x0115733C;
ROP_GX2Flush = 0x011575AC;
ROP_GX2DrawDone = 0x01157560;
ROP_GX2WaitForVsync = 0x01151964;
ROP_GX2DirectCallDisplayList = 0x01152BF0;
ROP_socket = 0x010C21C8;
ROP_connect = 0x010C0828;
ROP_recv = 0x010C0AEC;
ROP_R3_TO_R11 = 0x0DA6364C;
ROP_R11_TO_R1 = 0x0C009578;
ROP_R3_TO_R7 = 0x0D37A6F4;
ROP_R3_TO_R4 = 0x0DA6364C;
ROP_POP_R12 = 0x0C8F991C;
ROP_R3_TO_R6 = 0x0DFA353C;
ROP_R3_TO_R5_POP_R29_R30_R31 = 0x0DA21BC4;
| rop_popjumplr_stack12 = 16895268
rop_popjumplr_stack20 = 16928136
rop_callfunc = 17302132
rop_callr28_pop_r28_to_r31 = 17292656
rop_pop_r28_r29_r30_r31 = 16898260
rop_pop_r27 = 16894720
rop_pop_r24_to_r31 = 16909512
rop_callfuncptr_withargs_from_r3_mem = 16929728
rop_setr3_tor31_pop_r31 = 16894992
rop__register = 16938936
rop__deregister = 16938948
rop__copy_to_save_area = 16938972
rop__copy_from_save_area = 16938960
rop__create_thread_internal = 17046440
rop_lr_to_0_xc_r1 = 16895268
rop_lwz_r3_0_r3__lwz_r0_0xc_r1__mtlr_r0__addi_r1_r1_8__blr = 17042520
rop_memcpy = 16998344
rop_dc_flush_range = 16924552
rop_ic_invalidate_range = 16924848
rop_os_switch_sec_code_gen_mode = 17004224
rop_os_codegen_copy = 17004248
rop_os_get_codegen_virt_addr_range = 17003968
rop_os_get_core_id = 16928396
rop_os_get_current_thread = 17051984
rop_os_set_thread_affinity = 17050076
rop_os_yield_thread = 17045732
rop_os_fatal = 16979480
rop__exit = 16895360
rop_os_screen_flip_buffers_ex = 17018832
rop_os_screen_clear_buffer_ex = 17019024
rop_os_dyn_load__acquire = 16950196
rop_os_dyn_load__find_export = 16955432
rop_os_snprintf = 16970080
rop_os_send_app_switch_request = 17013808
rop_os_exit_thread = 17046892
rop_os_sleep_ticks = 17049420
rop_os_test_and_set_atomic64 = 16918972
rop_os_disable_interrupts = 16986704
rop_os_force_full_relaunch = 16998312
rop_os_restore_interrupts = 16986984
rop___exit = 16895360
rop_os_create_thread = 17046372
rop_os_resume_thread = 17047816
rop_im__open = 17310192
rop_im__set_device_state = 17311128
rop_im__close = 17310208
rop___ppc_exit = 16893312
rop_os_request_fast_exit = 17012272
rop_os_restart_crashed_app = 16974556
rop_os_shutdown = 16907532
rop_os_suspend_thread = 17050720
rop_os_run_threads_on_exit = 17069636
rop_os_block_threads_on_exit = 17069608
rop_gx2_set_semaphore_2_c = 18186008
rop_gx2_r3r4load = 18149236
rop_gx2_r30r31load = 18160108
rop_gx2_do_flush = 18150292
rop_gx2_call_r12 = 18390492
rop_gx2_init = 18180984
rop_gx2_shutdown = 18182972
rop_gx2_flush = 18183596
rop_gx2_draw_done = 18183520
rop_gx2_wait_for_vsync = 18159972
rop_gx2_direct_call_display_list = 18164720
rop_socket = 17572296
rop_connect = 17565736
rop_recv = 17566444
rop_r3_to_r11 = 228996684
rop_r11_to_r1 = 201364856
rop_r3_to_r7 = 221751028
rop_r3_to_r4 = 228996684
rop_pop_r12 = 210737436
rop_r3_to_r6 = 234501436
rop_r3_to_r5_pop_r29_r30_r31 = 228727748 |
#
# PySNMP MIB module CISCO-VPN-LIC-USAGE-MONITOR-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/CISCO-VPN-LIC-USAGE-MONITOR-MIB
# Produced by pysmi-0.3.4 at Mon Apr 29 18:03:26 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, ObjectIdentifier, Integer = mibBuilder.importSymbols("ASN1", "OctetString", "ObjectIdentifier", "Integer")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ValueSizeConstraint, ConstraintsIntersection, SingleValueConstraint, ValueRangeConstraint, ConstraintsUnion = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueSizeConstraint", "ConstraintsIntersection", "SingleValueConstraint", "ValueRangeConstraint", "ConstraintsUnion")
ciscoMgmt, = mibBuilder.importSymbols("CISCO-SMI", "ciscoMgmt")
InetAddressType, InetAddress = mibBuilder.importSymbols("INET-ADDRESS-MIB", "InetAddressType", "InetAddress")
SnmpAdminString, = mibBuilder.importSymbols("SNMP-FRAMEWORK-MIB", "SnmpAdminString")
ModuleCompliance, ObjectGroup, NotificationGroup = mibBuilder.importSymbols("SNMPv2-CONF", "ModuleCompliance", "ObjectGroup", "NotificationGroup")
MibIdentifier, ObjectIdentity, Counter64, TimeTicks, IpAddress, ModuleIdentity, Bits, Unsigned32, Counter32, NotificationType, iso, Gauge32, Integer32, MibScalar, MibTable, MibTableRow, MibTableColumn = mibBuilder.importSymbols("SNMPv2-SMI", "MibIdentifier", "ObjectIdentity", "Counter64", "TimeTicks", "IpAddress", "ModuleIdentity", "Bits", "Unsigned32", "Counter32", "NotificationType", "iso", "Gauge32", "Integer32", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn")
DisplayString, TextualConvention = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "TextualConvention")
ciscoVpnLicUsageMonitorMIB = ModuleIdentity((1, 3, 6, 1, 4, 1, 9, 9, 816))
ciscoVpnLicUsageMonitorMIB.setRevisions(('2013-09-13 00:00',))
if mibBuilder.loadTexts: ciscoVpnLicUsageMonitorMIB.setLastUpdated('201309130000Z')
if mibBuilder.loadTexts: ciscoVpnLicUsageMonitorMIB.setOrganization('Cisco Systems, Inc.')
class VPNLicType(TextualConvention, Integer32):
status = 'current'
subtypeSpec = Integer32.subtypeSpec + ConstraintsUnion(SingleValueConstraint(1, 2))
namedValues = NamedValues(("other", 1), ("anyconnectpremium", 2))
class VPNLicDeviceRole(TextualConvention, Integer32):
status = 'current'
subtypeSpec = Integer32.subtypeSpec + ConstraintsUnion(SingleValueConstraint(1, 2, 3))
namedValues = NamedValues(("server", 1), ("bkpserver", 2), ("client", 3))
class LicServerStatus(TextualConvention, Integer32):
status = 'current'
subtypeSpec = Integer32.subtypeSpec + ConstraintsUnion(SingleValueConstraint(1, 2, 3))
namedValues = NamedValues(("active", 1), ("inactive", 2), ("expired", 3))
class LicServerRegistered(TextualConvention, Integer32):
status = 'current'
subtypeSpec = Integer32.subtypeSpec + ConstraintsUnion(SingleValueConstraint(1, 2, 3))
namedValues = NamedValues(("no", 1), ("yes", 2), ("invalid", 3))
ciscoVpnLicUsageMonitorMIBObjects = MibIdentifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0))
ciscoVpnLicUsageMonitorMIBConform = MibIdentifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 1))
ciscoVpnLicUsageMonitorMIBCompliances = MibIdentifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 1))
cvpnLicDeviceRole = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 1), VPNLicDeviceRole()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicDeviceRole.setStatus('current')
cvpnLicServer = MibIdentifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2))
cvpnLicBkpServer = MibIdentifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3))
cvpnLicClient = MibIdentifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4))
cvpnLicServerAddrType = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 1), InetAddressType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerAddrType.setStatus('current')
cvpnLicServerAddr = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 2), InetAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerAddr.setStatus('current')
cvpnLicBkpSerAddrType = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 3), InetAddressType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpSerAddrType.setStatus('current')
cvpnLicBkpSerAddr = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 4), InetAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpSerAddr.setStatus('current')
cvpnLicServerVer = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerVer.setStatus('current')
cvpnLicServerStatus = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 6), LicServerStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerStatus.setStatus('current')
cvpnLicServerTable = MibTable((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7), )
if mibBuilder.loadTexts: cvpnLicServerTable.setStatus('current')
cvpnLicServerEntry = MibTableRow((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1), ).setIndexNames((0, "CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerVPNLicType"))
if mibBuilder.loadTexts: cvpnLicServerEntry.setStatus('current')
cvpnLicServerVPNLicType = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 1), VPNLicType())
if mibBuilder.loadTexts: cvpnLicServerVPNLicType.setStatus('current')
cvpnLicServerNumLicCapacity = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 2), Unsigned32()).setUnits('license').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerNumLicCapacity.setStatus('current')
cvpnLicServerNumLicAvail = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 3), Unsigned32()).setUnits('license').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerNumLicAvail.setStatus('current')
cvpnLicServerUtilized = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 4), Unsigned32()).setUnits('license').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerUtilized.setStatus('current')
cvpnLicBkpServerAddrType = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 1), InetAddressType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerAddrType.setStatus('current')
cvpnLicBkpServerAddr = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 2), InetAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerAddr.setStatus('current')
cvpnLicBkpServerDevID = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 3), SnmpAdminString().subtype(subtypeSpec=ValueSizeConstraint(0, 64))).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerDevID.setStatus('current')
cvpnLicBkpServerVer = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 4), Unsigned32()).setUnits('license').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerVer.setStatus('current')
cvpnLicBkpServerRegd = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 5), LicServerRegistered()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerRegd.setStatus('current')
cvpnLicBkpServerHAPeerDevID = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 6), SnmpAdminString().subtype(subtypeSpec=ValueSizeConstraint(0, 64))).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerHAPeerDevID.setStatus('current')
cvpnLicBkpServerHAPeerRegd = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 7), LicServerRegistered()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerHAPeerRegd.setStatus('current')
cvpnLicBkpServerStatus = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 8), LicServerStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicBkpServerStatus.setStatus('current')
cvpnLicServerHelloTx = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 9), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerHelloTx.setStatus('current')
cvpnLicServerHelloRx = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 10), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerHelloRx.setStatus('current')
cvpnLicServerHelloError = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 11), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerHelloError.setStatus('current')
cvpnLicServerSyncTx = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 12), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerSyncTx.setStatus('current')
cvpnLicServerSyncRx = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 13), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerSyncRx.setStatus('current')
cvpnLicServerSyncError = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 14), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerSyncError.setStatus('current')
cvpnLicServerUpdateTx = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 15), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerUpdateTx.setStatus('current')
cvpnLicServerUpdateRx = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 16), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerUpdateRx.setStatus('current')
cvpnLicServerUpdateError = MibScalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 17), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicServerUpdateError.setStatus('current')
cvpnLicClntInfoTable = MibTable((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1), )
if mibBuilder.loadTexts: cvpnLicClntInfoTable.setStatus('current')
cvpnLicClntInfoEntry = MibTableRow((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1), ).setIndexNames((0, "CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntVPNLicType"), (0, "CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoDeviceID"))
if mibBuilder.loadTexts: cvpnLicClntInfoEntry.setStatus('current')
cvpnLicClntVPNLicType = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 1), VPNLicType())
if mibBuilder.loadTexts: cvpnLicClntVPNLicType.setStatus('current')
cvpnLicClntInfoDeviceID = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 2), SnmpAdminString().subtype(subtypeSpec=ValueSizeConstraint(1, 64)))
if mibBuilder.loadTexts: cvpnLicClntInfoDeviceID.setStatus('current')
cvpnLicClntInfoHostName = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 3), SnmpAdminString().subtype(subtypeSpec=ValueSizeConstraint(0, 64))).setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoHostName.setStatus('current')
cvpnLicClntInfoPlatLmt = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 4), Unsigned32()).setUnits('license').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoPlatLmt.setStatus('current')
cvpnLicClntInfoCurUsage = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 5), Unsigned32()).setUnits('license').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoCurUsage.setStatus('current')
cvpnLicClntInfoHigh = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 6), Unsigned32()).setUnits('license').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoHigh.setStatus('current')
cvpnLicClntInfoRegReqTx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 7), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoRegReqTx.setStatus('current')
cvpnLicClntInfoRegReqRx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 8), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoRegReqRx.setStatus('current')
cvpnLicClntInfoRegReqError = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 9), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoRegReqError.setStatus('current')
cvpnLicClntInfoGetReqTx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 10), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoGetReqTx.setStatus('current')
cvpnLicClntInfoGetReqRx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 11), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoGetReqRx.setStatus('current')
cvpnLicClntInfoGetReqError = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 12), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoGetReqError.setStatus('current')
cvpnLicClntInfoRelReqTx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 13), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoRelReqTx.setStatus('current')
cvpnLicClntInfoRelReqRx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 14), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoRelReqRx.setStatus('current')
cvpnLicClntInfoRelReqError = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 15), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoRelReqError.setStatus('current')
cvpnLicClntInfoTransferReqTx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 16), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoTransferReqTx.setStatus('current')
cvpnLicClntInfoTransferReqRx = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 17), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoTransferReqRx.setStatus('current')
cvpnLicClntInfoTransferReqError = MibTableColumn((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 18), Counter32()).setUnits('packets').setMaxAccess("readonly")
if mibBuilder.loadTexts: cvpnLicClntInfoTransferReqError.setStatus('current')
ciscoVpnLicUsageMonitorMIBGroups = MibIdentifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 2))
ciscoVpnLicUsageMonitorMIBCompliance = ModuleCompliance((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 1, 1)).setObjects(("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "ciscoVPNSharedLicUsageMandatoryGroup"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "ciscoVPNSharedLicOptUsageGroup"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
ciscoVpnLicUsageMonitorMIBCompliance = ciscoVpnLicUsageMonitorMIBCompliance.setStatus('current')
ciscoVPNSharedLicUsageMandatoryGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 2, 1)).setObjects(("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicDeviceRole"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerAddrType"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerAddr"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpSerAddrType"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpSerAddr"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerVer"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerStatus"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerNumLicCapacity"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerNumLicAvail"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerUtilized"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoHostName"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoPlatLmt"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoCurUsage"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoHigh"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
ciscoVPNSharedLicUsageMandatoryGroup = ciscoVPNSharedLicUsageMandatoryGroup.setStatus('current')
ciscoVPNSharedLicOptUsageGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 2, 2)).setObjects(("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerAddrType"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerAddr"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerDevID"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerVer"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerRegd"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerHAPeerDevID"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerHAPeerRegd"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicBkpServerStatus"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerHelloTx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerHelloRx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerHelloError"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerSyncTx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerSyncRx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerSyncError"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerUpdateTx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerUpdateRx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicServerUpdateError"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoRegReqTx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoRegReqRx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoRegReqError"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoGetReqTx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoGetReqRx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoGetReqError"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoRelReqTx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoRelReqRx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoRelReqError"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoTransferReqTx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoTransferReqRx"), ("CISCO-VPN-LIC-USAGE-MONITOR-MIB", "cvpnLicClntInfoTransferReqError"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
ciscoVPNSharedLicOptUsageGroup = ciscoVPNSharedLicOptUsageGroup.setStatus('current')
mibBuilder.exportSymbols("CISCO-VPN-LIC-USAGE-MONITOR-MIB", cvpnLicClient=cvpnLicClient, cvpnLicServerVer=cvpnLicServerVer, cvpnLicClntInfoEntry=cvpnLicClntInfoEntry, cvpnLicBkpServerHAPeerDevID=cvpnLicBkpServerHAPeerDevID, cvpnLicBkpServerHAPeerRegd=cvpnLicBkpServerHAPeerRegd, cvpnLicServerHelloTx=cvpnLicServerHelloTx, LicServerStatus=LicServerStatus, cvpnLicClntInfoHostName=cvpnLicClntInfoHostName, cvpnLicClntInfoRelReqRx=cvpnLicClntInfoRelReqRx, ciscoVpnLicUsageMonitorMIBCompliance=ciscoVpnLicUsageMonitorMIBCompliance, cvpnLicServerUpdateRx=cvpnLicServerUpdateRx, ciscoVpnLicUsageMonitorMIBGroups=ciscoVpnLicUsageMonitorMIBGroups, cvpnLicClntInfoTransferReqTx=cvpnLicClntInfoTransferReqTx, cvpnLicServerUpdateError=cvpnLicServerUpdateError, cvpnLicServerSyncTx=cvpnLicServerSyncTx, cvpnLicClntInfoTransferReqError=cvpnLicClntInfoTransferReqError, ciscoVpnLicUsageMonitorMIBCompliances=ciscoVpnLicUsageMonitorMIBCompliances, cvpnLicServerVPNLicType=cvpnLicServerVPNLicType, ciscoVPNSharedLicOptUsageGroup=ciscoVPNSharedLicOptUsageGroup, cvpnLicServerStatus=cvpnLicServerStatus, VPNLicDeviceRole=VPNLicDeviceRole, cvpnLicServerUpdateTx=cvpnLicServerUpdateTx, ciscoVPNSharedLicUsageMandatoryGroup=ciscoVPNSharedLicUsageMandatoryGroup, cvpnLicBkpSerAddr=cvpnLicBkpSerAddr, cvpnLicBkpServerRegd=cvpnLicBkpServerRegd, cvpnLicClntVPNLicType=cvpnLicClntVPNLicType, cvpnLicClntInfoPlatLmt=cvpnLicClntInfoPlatLmt, cvpnLicClntInfoRelReqTx=cvpnLicClntInfoRelReqTx, cvpnLicClntInfoRegReqTx=cvpnLicClntInfoRegReqTx, ciscoVpnLicUsageMonitorMIB=ciscoVpnLicUsageMonitorMIB, cvpnLicBkpServerAddrType=cvpnLicBkpServerAddrType, cvpnLicClntInfoGetReqRx=cvpnLicClntInfoGetReqRx, cvpnLicServerUtilized=cvpnLicServerUtilized, cvpnLicBkpServerStatus=cvpnLicBkpServerStatus, cvpnLicServerSyncRx=cvpnLicServerSyncRx, cvpnLicClntInfoTable=cvpnLicClntInfoTable, cvpnLicClntInfoRegReqRx=cvpnLicClntInfoRegReqRx, cvpnLicClntInfoCurUsage=cvpnLicClntInfoCurUsage, cvpnLicServerTable=cvpnLicServerTable, cvpnLicServerNumLicAvail=cvpnLicServerNumLicAvail, PYSNMP_MODULE_ID=ciscoVpnLicUsageMonitorMIB, ciscoVpnLicUsageMonitorMIBConform=ciscoVpnLicUsageMonitorMIBConform, cvpnLicClntInfoRegReqError=cvpnLicClntInfoRegReqError, cvpnLicClntInfoGetReqTx=cvpnLicClntInfoGetReqTx, cvpnLicClntInfoRelReqError=cvpnLicClntInfoRelReqError, LicServerRegistered=LicServerRegistered, cvpnLicBkpServerAddr=cvpnLicBkpServerAddr, cvpnLicClntInfoTransferReqRx=cvpnLicClntInfoTransferReqRx, cvpnLicBkpServerVer=cvpnLicBkpServerVer, cvpnLicClntInfoGetReqError=cvpnLicClntInfoGetReqError, VPNLicType=VPNLicType, cvpnLicServerHelloRx=cvpnLicServerHelloRx, cvpnLicDeviceRole=cvpnLicDeviceRole, cvpnLicServerHelloError=cvpnLicServerHelloError, cvpnLicServerAddrType=cvpnLicServerAddrType, cvpnLicServer=cvpnLicServer, ciscoVpnLicUsageMonitorMIBObjects=ciscoVpnLicUsageMonitorMIBObjects, cvpnLicServerEntry=cvpnLicServerEntry, cvpnLicServerSyncError=cvpnLicServerSyncError, cvpnLicClntInfoHigh=cvpnLicClntInfoHigh, cvpnLicServerAddr=cvpnLicServerAddr, cvpnLicClntInfoDeviceID=cvpnLicClntInfoDeviceID, cvpnLicBkpSerAddrType=cvpnLicBkpSerAddrType, cvpnLicBkpServer=cvpnLicBkpServer, cvpnLicBkpServerDevID=cvpnLicBkpServerDevID, cvpnLicServerNumLicCapacity=cvpnLicServerNumLicCapacity)
| (octet_string, object_identifier, integer) = mibBuilder.importSymbols('ASN1', 'OctetString', 'ObjectIdentifier', 'Integer')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(value_size_constraint, constraints_intersection, single_value_constraint, value_range_constraint, constraints_union) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ValueSizeConstraint', 'ConstraintsIntersection', 'SingleValueConstraint', 'ValueRangeConstraint', 'ConstraintsUnion')
(cisco_mgmt,) = mibBuilder.importSymbols('CISCO-SMI', 'ciscoMgmt')
(inet_address_type, inet_address) = mibBuilder.importSymbols('INET-ADDRESS-MIB', 'InetAddressType', 'InetAddress')
(snmp_admin_string,) = mibBuilder.importSymbols('SNMP-FRAMEWORK-MIB', 'SnmpAdminString')
(module_compliance, object_group, notification_group) = mibBuilder.importSymbols('SNMPv2-CONF', 'ModuleCompliance', 'ObjectGroup', 'NotificationGroup')
(mib_identifier, object_identity, counter64, time_ticks, ip_address, module_identity, bits, unsigned32, counter32, notification_type, iso, gauge32, integer32, mib_scalar, mib_table, mib_table_row, mib_table_column) = mibBuilder.importSymbols('SNMPv2-SMI', 'MibIdentifier', 'ObjectIdentity', 'Counter64', 'TimeTicks', 'IpAddress', 'ModuleIdentity', 'Bits', 'Unsigned32', 'Counter32', 'NotificationType', 'iso', 'Gauge32', 'Integer32', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn')
(display_string, textual_convention) = mibBuilder.importSymbols('SNMPv2-TC', 'DisplayString', 'TextualConvention')
cisco_vpn_lic_usage_monitor_mib = module_identity((1, 3, 6, 1, 4, 1, 9, 9, 816))
ciscoVpnLicUsageMonitorMIB.setRevisions(('2013-09-13 00:00',))
if mibBuilder.loadTexts:
ciscoVpnLicUsageMonitorMIB.setLastUpdated('201309130000Z')
if mibBuilder.loadTexts:
ciscoVpnLicUsageMonitorMIB.setOrganization('Cisco Systems, Inc.')
class Vpnlictype(TextualConvention, Integer32):
status = 'current'
subtype_spec = Integer32.subtypeSpec + constraints_union(single_value_constraint(1, 2))
named_values = named_values(('other', 1), ('anyconnectpremium', 2))
class Vpnlicdevicerole(TextualConvention, Integer32):
status = 'current'
subtype_spec = Integer32.subtypeSpec + constraints_union(single_value_constraint(1, 2, 3))
named_values = named_values(('server', 1), ('bkpserver', 2), ('client', 3))
class Licserverstatus(TextualConvention, Integer32):
status = 'current'
subtype_spec = Integer32.subtypeSpec + constraints_union(single_value_constraint(1, 2, 3))
named_values = named_values(('active', 1), ('inactive', 2), ('expired', 3))
class Licserverregistered(TextualConvention, Integer32):
status = 'current'
subtype_spec = Integer32.subtypeSpec + constraints_union(single_value_constraint(1, 2, 3))
named_values = named_values(('no', 1), ('yes', 2), ('invalid', 3))
cisco_vpn_lic_usage_monitor_mib_objects = mib_identifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0))
cisco_vpn_lic_usage_monitor_mib_conform = mib_identifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 1))
cisco_vpn_lic_usage_monitor_mib_compliances = mib_identifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 1))
cvpn_lic_device_role = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 1), vpn_lic_device_role()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicDeviceRole.setStatus('current')
cvpn_lic_server = mib_identifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2))
cvpn_lic_bkp_server = mib_identifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3))
cvpn_lic_client = mib_identifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4))
cvpn_lic_server_addr_type = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 1), inet_address_type()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerAddrType.setStatus('current')
cvpn_lic_server_addr = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 2), inet_address()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerAddr.setStatus('current')
cvpn_lic_bkp_ser_addr_type = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 3), inet_address_type()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpSerAddrType.setStatus('current')
cvpn_lic_bkp_ser_addr = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 4), inet_address()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpSerAddr.setStatus('current')
cvpn_lic_server_ver = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 5), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerVer.setStatus('current')
cvpn_lic_server_status = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 6), lic_server_status()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerStatus.setStatus('current')
cvpn_lic_server_table = mib_table((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7))
if mibBuilder.loadTexts:
cvpnLicServerTable.setStatus('current')
cvpn_lic_server_entry = mib_table_row((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1)).setIndexNames((0, 'CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerVPNLicType'))
if mibBuilder.loadTexts:
cvpnLicServerEntry.setStatus('current')
cvpn_lic_server_vpn_lic_type = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 1), vpn_lic_type())
if mibBuilder.loadTexts:
cvpnLicServerVPNLicType.setStatus('current')
cvpn_lic_server_num_lic_capacity = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 2), unsigned32()).setUnits('license').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerNumLicCapacity.setStatus('current')
cvpn_lic_server_num_lic_avail = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 3), unsigned32()).setUnits('license').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerNumLicAvail.setStatus('current')
cvpn_lic_server_utilized = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 2, 7, 1, 4), unsigned32()).setUnits('license').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerUtilized.setStatus('current')
cvpn_lic_bkp_server_addr_type = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 1), inet_address_type()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerAddrType.setStatus('current')
cvpn_lic_bkp_server_addr = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 2), inet_address()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerAddr.setStatus('current')
cvpn_lic_bkp_server_dev_id = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 3), snmp_admin_string().subtype(subtypeSpec=value_size_constraint(0, 64))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerDevID.setStatus('current')
cvpn_lic_bkp_server_ver = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 4), unsigned32()).setUnits('license').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerVer.setStatus('current')
cvpn_lic_bkp_server_regd = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 5), lic_server_registered()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerRegd.setStatus('current')
cvpn_lic_bkp_server_ha_peer_dev_id = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 6), snmp_admin_string().subtype(subtypeSpec=value_size_constraint(0, 64))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerHAPeerDevID.setStatus('current')
cvpn_lic_bkp_server_ha_peer_regd = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 7), lic_server_registered()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerHAPeerRegd.setStatus('current')
cvpn_lic_bkp_server_status = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 8), lic_server_status()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicBkpServerStatus.setStatus('current')
cvpn_lic_server_hello_tx = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 9), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerHelloTx.setStatus('current')
cvpn_lic_server_hello_rx = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 10), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerHelloRx.setStatus('current')
cvpn_lic_server_hello_error = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 11), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerHelloError.setStatus('current')
cvpn_lic_server_sync_tx = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 12), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerSyncTx.setStatus('current')
cvpn_lic_server_sync_rx = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 13), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerSyncRx.setStatus('current')
cvpn_lic_server_sync_error = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 14), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerSyncError.setStatus('current')
cvpn_lic_server_update_tx = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 15), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerUpdateTx.setStatus('current')
cvpn_lic_server_update_rx = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 16), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerUpdateRx.setStatus('current')
cvpn_lic_server_update_error = mib_scalar((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 3, 17), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicServerUpdateError.setStatus('current')
cvpn_lic_clnt_info_table = mib_table((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1))
if mibBuilder.loadTexts:
cvpnLicClntInfoTable.setStatus('current')
cvpn_lic_clnt_info_entry = mib_table_row((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1)).setIndexNames((0, 'CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntVPNLicType'), (0, 'CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoDeviceID'))
if mibBuilder.loadTexts:
cvpnLicClntInfoEntry.setStatus('current')
cvpn_lic_clnt_vpn_lic_type = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 1), vpn_lic_type())
if mibBuilder.loadTexts:
cvpnLicClntVPNLicType.setStatus('current')
cvpn_lic_clnt_info_device_id = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 2), snmp_admin_string().subtype(subtypeSpec=value_size_constraint(1, 64)))
if mibBuilder.loadTexts:
cvpnLicClntInfoDeviceID.setStatus('current')
cvpn_lic_clnt_info_host_name = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 3), snmp_admin_string().subtype(subtypeSpec=value_size_constraint(0, 64))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoHostName.setStatus('current')
cvpn_lic_clnt_info_plat_lmt = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 4), unsigned32()).setUnits('license').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoPlatLmt.setStatus('current')
cvpn_lic_clnt_info_cur_usage = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 5), unsigned32()).setUnits('license').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoCurUsage.setStatus('current')
cvpn_lic_clnt_info_high = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 6), unsigned32()).setUnits('license').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoHigh.setStatus('current')
cvpn_lic_clnt_info_reg_req_tx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 7), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoRegReqTx.setStatus('current')
cvpn_lic_clnt_info_reg_req_rx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 8), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoRegReqRx.setStatus('current')
cvpn_lic_clnt_info_reg_req_error = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 9), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoRegReqError.setStatus('current')
cvpn_lic_clnt_info_get_req_tx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 10), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoGetReqTx.setStatus('current')
cvpn_lic_clnt_info_get_req_rx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 11), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoGetReqRx.setStatus('current')
cvpn_lic_clnt_info_get_req_error = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 12), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoGetReqError.setStatus('current')
cvpn_lic_clnt_info_rel_req_tx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 13), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoRelReqTx.setStatus('current')
cvpn_lic_clnt_info_rel_req_rx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 14), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoRelReqRx.setStatus('current')
cvpn_lic_clnt_info_rel_req_error = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 15), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoRelReqError.setStatus('current')
cvpn_lic_clnt_info_transfer_req_tx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 16), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoTransferReqTx.setStatus('current')
cvpn_lic_clnt_info_transfer_req_rx = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 17), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoTransferReqRx.setStatus('current')
cvpn_lic_clnt_info_transfer_req_error = mib_table_column((1, 3, 6, 1, 4, 1, 9, 9, 816, 0, 4, 1, 1, 18), counter32()).setUnits('packets').setMaxAccess('readonly')
if mibBuilder.loadTexts:
cvpnLicClntInfoTransferReqError.setStatus('current')
cisco_vpn_lic_usage_monitor_mib_groups = mib_identifier((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 2))
cisco_vpn_lic_usage_monitor_mib_compliance = module_compliance((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 1, 1)).setObjects(('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'ciscoVPNSharedLicUsageMandatoryGroup'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'ciscoVPNSharedLicOptUsageGroup'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cisco_vpn_lic_usage_monitor_mib_compliance = ciscoVpnLicUsageMonitorMIBCompliance.setStatus('current')
cisco_vpn_shared_lic_usage_mandatory_group = object_group((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 2, 1)).setObjects(('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicDeviceRole'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerAddrType'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerAddr'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpSerAddrType'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpSerAddr'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerVer'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerStatus'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerNumLicCapacity'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerNumLicAvail'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerUtilized'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoHostName'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoPlatLmt'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoCurUsage'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoHigh'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cisco_vpn_shared_lic_usage_mandatory_group = ciscoVPNSharedLicUsageMandatoryGroup.setStatus('current')
cisco_vpn_shared_lic_opt_usage_group = object_group((1, 3, 6, 1, 4, 1, 9, 9, 816, 1, 2, 2)).setObjects(('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerAddrType'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerAddr'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerDevID'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerVer'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerRegd'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerHAPeerDevID'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerHAPeerRegd'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicBkpServerStatus'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerHelloTx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerHelloRx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerHelloError'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerSyncTx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerSyncRx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerSyncError'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerUpdateTx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerUpdateRx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicServerUpdateError'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoRegReqTx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoRegReqRx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoRegReqError'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoGetReqTx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoGetReqRx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoGetReqError'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoRelReqTx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoRelReqRx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoRelReqError'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoTransferReqTx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoTransferReqRx'), ('CISCO-VPN-LIC-USAGE-MONITOR-MIB', 'cvpnLicClntInfoTransferReqError'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cisco_vpn_shared_lic_opt_usage_group = ciscoVPNSharedLicOptUsageGroup.setStatus('current')
mibBuilder.exportSymbols('CISCO-VPN-LIC-USAGE-MONITOR-MIB', cvpnLicClient=cvpnLicClient, cvpnLicServerVer=cvpnLicServerVer, cvpnLicClntInfoEntry=cvpnLicClntInfoEntry, cvpnLicBkpServerHAPeerDevID=cvpnLicBkpServerHAPeerDevID, cvpnLicBkpServerHAPeerRegd=cvpnLicBkpServerHAPeerRegd, cvpnLicServerHelloTx=cvpnLicServerHelloTx, LicServerStatus=LicServerStatus, cvpnLicClntInfoHostName=cvpnLicClntInfoHostName, cvpnLicClntInfoRelReqRx=cvpnLicClntInfoRelReqRx, ciscoVpnLicUsageMonitorMIBCompliance=ciscoVpnLicUsageMonitorMIBCompliance, cvpnLicServerUpdateRx=cvpnLicServerUpdateRx, ciscoVpnLicUsageMonitorMIBGroups=ciscoVpnLicUsageMonitorMIBGroups, cvpnLicClntInfoTransferReqTx=cvpnLicClntInfoTransferReqTx, cvpnLicServerUpdateError=cvpnLicServerUpdateError, cvpnLicServerSyncTx=cvpnLicServerSyncTx, cvpnLicClntInfoTransferReqError=cvpnLicClntInfoTransferReqError, ciscoVpnLicUsageMonitorMIBCompliances=ciscoVpnLicUsageMonitorMIBCompliances, cvpnLicServerVPNLicType=cvpnLicServerVPNLicType, ciscoVPNSharedLicOptUsageGroup=ciscoVPNSharedLicOptUsageGroup, cvpnLicServerStatus=cvpnLicServerStatus, VPNLicDeviceRole=VPNLicDeviceRole, cvpnLicServerUpdateTx=cvpnLicServerUpdateTx, ciscoVPNSharedLicUsageMandatoryGroup=ciscoVPNSharedLicUsageMandatoryGroup, cvpnLicBkpSerAddr=cvpnLicBkpSerAddr, cvpnLicBkpServerRegd=cvpnLicBkpServerRegd, cvpnLicClntVPNLicType=cvpnLicClntVPNLicType, cvpnLicClntInfoPlatLmt=cvpnLicClntInfoPlatLmt, cvpnLicClntInfoRelReqTx=cvpnLicClntInfoRelReqTx, cvpnLicClntInfoRegReqTx=cvpnLicClntInfoRegReqTx, ciscoVpnLicUsageMonitorMIB=ciscoVpnLicUsageMonitorMIB, cvpnLicBkpServerAddrType=cvpnLicBkpServerAddrType, cvpnLicClntInfoGetReqRx=cvpnLicClntInfoGetReqRx, cvpnLicServerUtilized=cvpnLicServerUtilized, cvpnLicBkpServerStatus=cvpnLicBkpServerStatus, cvpnLicServerSyncRx=cvpnLicServerSyncRx, cvpnLicClntInfoTable=cvpnLicClntInfoTable, cvpnLicClntInfoRegReqRx=cvpnLicClntInfoRegReqRx, cvpnLicClntInfoCurUsage=cvpnLicClntInfoCurUsage, cvpnLicServerTable=cvpnLicServerTable, cvpnLicServerNumLicAvail=cvpnLicServerNumLicAvail, PYSNMP_MODULE_ID=ciscoVpnLicUsageMonitorMIB, ciscoVpnLicUsageMonitorMIBConform=ciscoVpnLicUsageMonitorMIBConform, cvpnLicClntInfoRegReqError=cvpnLicClntInfoRegReqError, cvpnLicClntInfoGetReqTx=cvpnLicClntInfoGetReqTx, cvpnLicClntInfoRelReqError=cvpnLicClntInfoRelReqError, LicServerRegistered=LicServerRegistered, cvpnLicBkpServerAddr=cvpnLicBkpServerAddr, cvpnLicClntInfoTransferReqRx=cvpnLicClntInfoTransferReqRx, cvpnLicBkpServerVer=cvpnLicBkpServerVer, cvpnLicClntInfoGetReqError=cvpnLicClntInfoGetReqError, VPNLicType=VPNLicType, cvpnLicServerHelloRx=cvpnLicServerHelloRx, cvpnLicDeviceRole=cvpnLicDeviceRole, cvpnLicServerHelloError=cvpnLicServerHelloError, cvpnLicServerAddrType=cvpnLicServerAddrType, cvpnLicServer=cvpnLicServer, ciscoVpnLicUsageMonitorMIBObjects=ciscoVpnLicUsageMonitorMIBObjects, cvpnLicServerEntry=cvpnLicServerEntry, cvpnLicServerSyncError=cvpnLicServerSyncError, cvpnLicClntInfoHigh=cvpnLicClntInfoHigh, cvpnLicServerAddr=cvpnLicServerAddr, cvpnLicClntInfoDeviceID=cvpnLicClntInfoDeviceID, cvpnLicBkpSerAddrType=cvpnLicBkpSerAddrType, cvpnLicBkpServer=cvpnLicBkpServer, cvpnLicBkpServerDevID=cvpnLicBkpServerDevID, cvpnLicServerNumLicCapacity=cvpnLicServerNumLicCapacity) |
# Copyright(c) 2017, Intel Corporation
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# * Redistributions of source code must retain the above copyright notice,
# this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
# * Neither the name of Intel Corporation nor the names of its contributors
# may be used to endorse or promote products derived from this software
# without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
# GUID value: "58656F6E-4650-4741-B747-425376303031"
# The string below will be converted to hex format
# before being written into the bitstream file
METADATA_GUID = b'XeonFPGA\xb7GBSv001'
# Metadata length field is a unsigned 32 bit int
SIZEOF_LEN_FIELD = 4
# Length of GUID string
GUID_LEN = len(METADATA_GUID)
| metadata_guid = b'XeonFPGA\xb7GBSv001'
sizeof_len_field = 4
guid_len = len(METADATA_GUID) |
{
"targets": [
{
"target_name": "lmdb-queue",
"include_dirs" : [
"<!(node -e \"require('nan')\")",
"<!(node -e \"require('nnu')\")",
"deps"
],
"dependencies": [
"<(module_root_dir)/deps/lmdb.gyp:lmdb"
],
"sources": [
"src/module.cc",
"src/env.h",
"src/env.cc",
"src/topic.h",
"src/topic.cc",
"src/consumer.h",
"src/consumer.cc",
"src/producer.h",
"src/producer.cc",
"src/wrapper.h"
],
"conditions": [
[
"OS == 'win'", {
'msvs_settings': {
'VCCLCompilerTool': {
'RuntimeTypeInfo': 'false',
'EnableFunctionLevelLinking': 'true',
'DisableSpecificWarnings': [ '4267' ],
'AdditionalOptions': ['/EHsc']
}
}
}
],
[
"OS=='linux'", {
"cflags_cc": [ "-std=c++11" ]
}
],
[
'OS == "mac"', {
'xcode_settings': {
'MACOSX_DEPLOYMENT_TARGET': '10.7',
'OTHER_CPLUSPLUSFLAGS': [
'-std=c++11' ,
'-stdlib=libc++'
]
}
}
]
]
}
]
} | {'targets': [{'target_name': 'lmdb-queue', 'include_dirs': ['<!(node -e "require(\'nan\')")', '<!(node -e "require(\'nnu\')")', 'deps'], 'dependencies': ['<(module_root_dir)/deps/lmdb.gyp:lmdb'], 'sources': ['src/module.cc', 'src/env.h', 'src/env.cc', 'src/topic.h', 'src/topic.cc', 'src/consumer.h', 'src/consumer.cc', 'src/producer.h', 'src/producer.cc', 'src/wrapper.h'], 'conditions': [["OS == 'win'", {'msvs_settings': {'VCCLCompilerTool': {'RuntimeTypeInfo': 'false', 'EnableFunctionLevelLinking': 'true', 'DisableSpecificWarnings': ['4267'], 'AdditionalOptions': ['/EHsc']}}}], ["OS=='linux'", {'cflags_cc': ['-std=c++11']}], ['OS == "mac"', {'xcode_settings': {'MACOSX_DEPLOYMENT_TARGET': '10.7', 'OTHER_CPLUSPLUSFLAGS': ['-std=c++11', '-stdlib=libc++']}}]]}]} |
# the key is the name of the class of the workload and the value is the program argument string
def get_workloads(checkpoint, analytics_data_paths: list, lda_data_paths: list, gbt_data_path: str,
pagerank_data_path: str, k: int, iterations: int, checkpoint_interval: int,
sampling_fraction: float = 0.01, analytics_only: bool = False) -> dict:
if analytics_only:
# for a faster run
workloads = {
"Analytics": f"--sampling-fraction {sampling_fraction} --checkpoint-rdd {checkpoint} {analytics_data_paths[0]} {analytics_data_paths[1]}"
}
else:
workloads = {
"Analytics": f"--sampling-fraction {sampling_fraction} --checkpoint-rdd {checkpoint} {analytics_data_paths[0]} {analytics_data_paths[1]}",
"LDAWorkload": f"--k {k} --iterations {iterations} --checkpoint {checkpoint} --checkpoint-interval {checkpoint_interval} {lda_data_paths[0]} {lda_data_paths[1]}",
"GradientBoostedTrees": f"--iterations {iterations} --checkpoint {checkpoint} --checkpoint-interval {checkpoint_interval} {gbt_data_path}",
"PageRank": f"--save-path output/ --iterations {iterations} --checkpoint {checkpoint} {pagerank_data_path}"
}
return workloads
| def get_workloads(checkpoint, analytics_data_paths: list, lda_data_paths: list, gbt_data_path: str, pagerank_data_path: str, k: int, iterations: int, checkpoint_interval: int, sampling_fraction: float=0.01, analytics_only: bool=False) -> dict:
if analytics_only:
workloads = {'Analytics': f'--sampling-fraction {sampling_fraction} --checkpoint-rdd {checkpoint} {analytics_data_paths[0]} {analytics_data_paths[1]}'}
else:
workloads = {'Analytics': f'--sampling-fraction {sampling_fraction} --checkpoint-rdd {checkpoint} {analytics_data_paths[0]} {analytics_data_paths[1]}', 'LDAWorkload': f'--k {k} --iterations {iterations} --checkpoint {checkpoint} --checkpoint-interval {checkpoint_interval} {lda_data_paths[0]} {lda_data_paths[1]}', 'GradientBoostedTrees': f'--iterations {iterations} --checkpoint {checkpoint} --checkpoint-interval {checkpoint_interval} {gbt_data_path}', 'PageRank': f'--save-path output/ --iterations {iterations} --checkpoint {checkpoint} {pagerank_data_path}'}
return workloads |
__author__ = 'Cib'
class interface():
pass
| __author__ = 'Cib'
class Interface:
pass |
class MyStack:
def __init__(self):
self.q = deque()
def push(self, x: int) -> None:
self.q.append(x)
def pop(self) -> int:
for i in range(len(self.q)-1):
self.q.append(self.q.popleft())
return self.q.popleft()
def top(self) -> int:
temp = self.pop()
self.q.append(temp)
return temp
def empty(self) -> bool:
return len(self.q) == 0
# Your MyStack object will be instantiated and called as such:
# obj = MyStack()
# obj.push(x)
# param_2 = obj.pop()
# param_3 = obj.top()
# param_4 = obj.empty() | class Mystack:
def __init__(self):
self.q = deque()
def push(self, x: int) -> None:
self.q.append(x)
def pop(self) -> int:
for i in range(len(self.q) - 1):
self.q.append(self.q.popleft())
return self.q.popleft()
def top(self) -> int:
temp = self.pop()
self.q.append(temp)
return temp
def empty(self) -> bool:
return len(self.q) == 0 |
N = int(input())
A = list(map(int, input().split()))
ans = 0
max_tall = 0
for i in range(0, N):
if max_tall > A[i]:
ans += max_tall - A[i]
if A[i] > max_tall:
max_tall = A[i]
print(ans) | n = int(input())
a = list(map(int, input().split()))
ans = 0
max_tall = 0
for i in range(0, N):
if max_tall > A[i]:
ans += max_tall - A[i]
if A[i] > max_tall:
max_tall = A[i]
print(ans) |
#
# PySNMP MIB module A3COM0027-RMON-EXTENSIONS (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/A3COM0027-RMON-EXTENSIONS
# Produced by pysmi-0.3.4 at Wed May 1 11:08:40 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)
#
rmonExtensions, = mibBuilder.importSymbols("A3COM0004-GENERIC", "rmonExtensions")
ObjectIdentifier, Integer, OctetString = mibBuilder.importSymbols("ASN1", "ObjectIdentifier", "Integer", "OctetString")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ConstraintsUnion, ValueRangeConstraint, ConstraintsIntersection, ValueSizeConstraint, SingleValueConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ConstraintsUnion", "ValueRangeConstraint", "ConstraintsIntersection", "ValueSizeConstraint", "SingleValueConstraint")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
Integer32, NotificationType, MibScalar, MibTable, MibTableRow, MibTableColumn, Gauge32, Bits, ObjectIdentity, Unsigned32, MibIdentifier, NotificationType, ModuleIdentity, Counter64, iso, Counter32, TimeTicks, IpAddress = mibBuilder.importSymbols("SNMPv2-SMI", "Integer32", "NotificationType", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "Gauge32", "Bits", "ObjectIdentity", "Unsigned32", "MibIdentifier", "NotificationType", "ModuleIdentity", "Counter64", "iso", "Counter32", "TimeTicks", "IpAddress")
DisplayString, TextualConvention = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "TextualConvention")
remotePoll = MibIdentifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 1))
hostExtensions = MibIdentifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 2))
alarmExtensions = MibIdentifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 3))
eventExtensions = MibIdentifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 4))
command = MibIdentifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 5))
probeConfigNetExtensions = MibIdentifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 6))
mibBuilder.exportSymbols("A3COM0027-RMON-EXTENSIONS", remotePoll=remotePoll, probeConfigNetExtensions=probeConfigNetExtensions, hostExtensions=hostExtensions, eventExtensions=eventExtensions, command=command, alarmExtensions=alarmExtensions)
| (rmon_extensions,) = mibBuilder.importSymbols('A3COM0004-GENERIC', 'rmonExtensions')
(object_identifier, integer, octet_string) = mibBuilder.importSymbols('ASN1', 'ObjectIdentifier', 'Integer', 'OctetString')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(constraints_union, value_range_constraint, constraints_intersection, value_size_constraint, single_value_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ConstraintsUnion', 'ValueRangeConstraint', 'ConstraintsIntersection', 'ValueSizeConstraint', 'SingleValueConstraint')
(notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance')
(integer32, notification_type, mib_scalar, mib_table, mib_table_row, mib_table_column, gauge32, bits, object_identity, unsigned32, mib_identifier, notification_type, module_identity, counter64, iso, counter32, time_ticks, ip_address) = mibBuilder.importSymbols('SNMPv2-SMI', 'Integer32', 'NotificationType', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'Gauge32', 'Bits', 'ObjectIdentity', 'Unsigned32', 'MibIdentifier', 'NotificationType', 'ModuleIdentity', 'Counter64', 'iso', 'Counter32', 'TimeTicks', 'IpAddress')
(display_string, textual_convention) = mibBuilder.importSymbols('SNMPv2-TC', 'DisplayString', 'TextualConvention')
remote_poll = mib_identifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 1))
host_extensions = mib_identifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 2))
alarm_extensions = mib_identifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 3))
event_extensions = mib_identifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 4))
command = mib_identifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 5))
probe_config_net_extensions = mib_identifier((1, 3, 6, 1, 4, 1, 43, 10, 25, 6))
mibBuilder.exportSymbols('A3COM0027-RMON-EXTENSIONS', remotePoll=remotePoll, probeConfigNetExtensions=probeConfigNetExtensions, hostExtensions=hostExtensions, eventExtensions=eventExtensions, command=command, alarmExtensions=alarmExtensions) |
class ps_data:
@property
def train_data(self):
return self._train_data
@property
def indexs(self):
return self._indexs
@train_data.setter
def train_data(self, val):
self._train_data=val
@indexs.setter
def indexs(self, val):
self._indexs=val
| class Ps_Data:
@property
def train_data(self):
return self._train_data
@property
def indexs(self):
return self._indexs
@train_data.setter
def train_data(self, val):
self._train_data = val
@indexs.setter
def indexs(self, val):
self._indexs = val |
class Advice:
def __init__(self):
self.clothes = []
self.weather = None
def add_cloth(self, cloth):
self.clothes.append(cloth)
def add_message(self, message):
self.clothes.append(message)
def add_weather(self, weather):
self.weather = weather
| class Advice:
def __init__(self):
self.clothes = []
self.weather = None
def add_cloth(self, cloth):
self.clothes.append(cloth)
def add_message(self, message):
self.clothes.append(message)
def add_weather(self, weather):
self.weather = weather |
__all__= [
'table',
'projects',
'annotations',
'converters',
'metrics'
]
__version__ = '0.0.3'
| __all__ = ['table', 'projects', 'annotations', 'converters', 'metrics']
__version__ = '0.0.3' |
'''
lab2
'''
#3.1
my_name = "Tom"
print(my_name.upper())
#3.2
my_id = 123
print(my_id)
#3.3
# 123=my_id
my_id=your_id=123
print(my_id)
print(your_id)
#3.4
my_id_str= "123"
print(my_id_str)
#3.5
#print(my_name+my_id)
#3.6
print(my_name+my_id_str)
#3.7
print(my_name*3)
#3.8
print('hello, world. This is my first python string'.split('.'))
#3.9
#message = 'Tom's id is 123'
#print('Tom's id is 123')
message = "Tom's id is 123"
print(message)
| """
lab2
"""
my_name = 'Tom'
print(my_name.upper())
my_id = 123
print(my_id)
my_id = your_id = 123
print(my_id)
print(your_id)
my_id_str = '123'
print(my_id_str)
print(my_name + my_id_str)
print(my_name * 3)
print('hello, world. This is my first python string'.split('.'))
message = "Tom's id is 123"
print(message) |
#/usr/bin/env python
def my_func1(callback):
def func_wrapper(x):
print("my_func1: {0} ".format(callback(x)))
return func_wrapper
@my_func1
def my_func2(x):
return x
# Actuall call sequence is similar to:
# deco = my_func1(my_func2)
# deco("test") => func_wrapper("test")
my_func2("test")
#-------------------------------------------
# Test decorator with parameter
def dec_param(param):
def my_func3(callback):
def func_wrapper(x):
print("my_func3: {0} {1} ".format(param, callback(x)))
return func_wrapper
return my_func3
@dec_param("tag")
def my_func4(x):
return x
# Actuall call sequence is similar to:
# deco = dec_pram("tag", my_func3(my_func4))
# deco("test") => func_wrapper("test")
my_func4("test")
| def my_func1(callback):
def func_wrapper(x):
print('my_func1: {0} '.format(callback(x)))
return func_wrapper
@my_func1
def my_func2(x):
return x
my_func2('test')
def dec_param(param):
def my_func3(callback):
def func_wrapper(x):
print('my_func3: {0} {1} '.format(param, callback(x)))
return func_wrapper
return my_func3
@dec_param('tag')
def my_func4(x):
return x
my_func4('test') |
# HARD
# Rolling Hash Method
# abc ==> a *26^2, b * 26^1, c * 26^0.
# ex: 123 ==> 1*10^2, 2 * 10^1, 3 * 10^0
# we find every possible substring to find if exist a duplicated one
# start with mid, if possible ==> find longer one else find shorter one
# Time O(NlogN) Space: O(N)
class Solution:
def longestDupSubstring(self, S: str) -> str:
n = len(S)
nums = [ord(S[i])- ord('a') for i in range(n)]
a = 26
mod = 2**32
#print(nums)
left,right = 1,n
while left <=right:
mid = left +(right-left >>1)
if self.match(mid,a,mod,n,nums) != -1:
left = mid +1
else:
right = mid -1
start = self.match(mid-1,a,mod,n,nums)
return S[start:start+left -1]
def match(self,mid,a,mod,n,nums):
h = 0
print('mid',mid)
for i in range(mid):
h = (h*a + nums[i])% mod
print(i,nums[i],h)
seen = set([h])
aMid = pow(a,mid,mod)
for i in range(1,n-mid+1):
h = (h*a - nums[i-1] *aMid + nums[i+mid-1]) % mod
if h in seen:
return i
seen.add(h)
return -1
| class Solution:
def longest_dup_substring(self, S: str) -> str:
n = len(S)
nums = [ord(S[i]) - ord('a') for i in range(n)]
a = 26
mod = 2 ** 32
(left, right) = (1, n)
while left <= right:
mid = left + (right - left >> 1)
if self.match(mid, a, mod, n, nums) != -1:
left = mid + 1
else:
right = mid - 1
start = self.match(mid - 1, a, mod, n, nums)
return S[start:start + left - 1]
def match(self, mid, a, mod, n, nums):
h = 0
print('mid', mid)
for i in range(mid):
h = (h * a + nums[i]) % mod
print(i, nums[i], h)
seen = set([h])
a_mid = pow(a, mid, mod)
for i in range(1, n - mid + 1):
h = (h * a - nums[i - 1] * aMid + nums[i + mid - 1]) % mod
if h in seen:
return i
seen.add(h)
return -1 |
def squareme(x):
return(x**2)
myvar = input("Give me a number to square: ")
myvar = float(myvar)
print("The square of %f is %f." % (myvar, squareme(myvar)) )
| def squareme(x):
return x ** 2
myvar = input('Give me a number to square: ')
myvar = float(myvar)
print('The square of %f is %f.' % (myvar, squareme(myvar))) |
class Solution:
def rotate(self, N, D):
D = D%16
val1 = ((N << D) % (2 ** 16)) ^ int(N // (2 ** (16 - D)))
#val1 = (N << D) | (N >> (16 - D))
val2 = (N >> D) ^ int((2 ** (16 - D)) * (N % (2 ** D)))
return [val1, val2]
if __name__ == '__main__':
t = int(input())
for _ in range(t):
n, d = input().strip().split(" ")
n, d = int(n), int(d)
ob = Solution()
ans = ob.rotate(n, d)
print(ans[0])
print(ans[1])
| class Solution:
def rotate(self, N, D):
d = D % 16
val1 = (N << D) % 2 ** 16 ^ int(N // 2 ** (16 - D))
val2 = N >> D ^ int(2 ** (16 - D) * (N % 2 ** D))
return [val1, val2]
if __name__ == '__main__':
t = int(input())
for _ in range(t):
(n, d) = input().strip().split(' ')
(n, d) = (int(n), int(d))
ob = solution()
ans = ob.rotate(n, d)
print(ans[0])
print(ans[1]) |
#
# PySNMP MIB module HUAWEI-PPP-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/HUAWEI-PPP-MIB
# Produced by pysmi-0.3.4 at Mon Apr 29 19:36:10 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)
#
ObjectIdentifier, OctetString, Integer = mibBuilder.importSymbols("ASN1", "ObjectIdentifier", "OctetString", "Integer")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ConstraintsUnion, ConstraintsIntersection, ValueRangeConstraint, SingleValueConstraint, ValueSizeConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ConstraintsUnion", "ConstraintsIntersection", "ValueRangeConstraint", "SingleValueConstraint", "ValueSizeConstraint")
hwDatacomm, = mibBuilder.importSymbols("HUAWEI-MIB", "hwDatacomm")
InterfaceIndex, = mibBuilder.importSymbols("IF-MIB", "InterfaceIndex")
NotificationGroup, ObjectGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ObjectGroup", "ModuleCompliance")
ModuleIdentity, MibIdentifier, Gauge32, ObjectIdentity, Integer32, Counter32, Counter64, NotificationType, Unsigned32, iso, Bits, TimeTicks, IpAddress, MibScalar, MibTable, MibTableRow, MibTableColumn = mibBuilder.importSymbols("SNMPv2-SMI", "ModuleIdentity", "MibIdentifier", "Gauge32", "ObjectIdentity", "Integer32", "Counter32", "Counter64", "NotificationType", "Unsigned32", "iso", "Bits", "TimeTicks", "IpAddress", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn")
TruthValue, DisplayString, RowStatus, TextualConvention = mibBuilder.importSymbols("SNMPv2-TC", "TruthValue", "DisplayString", "RowStatus", "TextualConvention")
hwPppMIB = ModuleIdentity((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169))
if mibBuilder.loadTexts: hwPppMIB.setLastUpdated('200710172230Z')
if mibBuilder.loadTexts: hwPppMIB.setOrganization('Huawei Technologies co.,Ltd.')
hwPppObjects = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1))
hwPppConfigTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1), )
if mibBuilder.loadTexts: hwPppConfigTable.setStatus('current')
hwPppConfigEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1), ).setIndexNames((0, "HUAWEI-PPP-MIB", "hwPppIfIndex"))
if mibBuilder.loadTexts: hwPppConfigEntry.setStatus('current')
hwPppIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1, 1), InterfaceIndex())
if mibBuilder.loadTexts: hwPppIfIndex.setStatus('current')
hwPppMruNegType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1, 11), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("ipv4", 1), ("ipv6", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppMruNegType.setStatus('current')
hwPppMpIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1, 12), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppMpIfIndex.setStatus('current')
hwPppAuthenticateTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2), )
if mibBuilder.loadTexts: hwPppAuthenticateTable.setStatus('current')
hwPppAuthenticateEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1), ).setIndexNames((0, "HUAWEI-PPP-MIB", "hwPppIfIndex"))
if mibBuilder.loadTexts: hwPppAuthenticateEntry.setStatus('current')
hwPppAuthenticateMode = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 11), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("chap", 1), ("pap", 2), ("chappap", 3)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppAuthenticateMode.setStatus('current')
hwPppAuthenticateChapUserName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 12), OctetString().subtype(subtypeSpec=ValueSizeConstraint(1, 64))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppAuthenticateChapUserName.setStatus('current')
hwPppAuthenticateChapPwType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 13), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("cipher", 1), ("simple", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppAuthenticateChapPwType.setStatus('current')
hwPppAuthenticateChapPw = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 14), OctetString().subtype(subtypeSpec=ConstraintsUnion(ValueSizeConstraint(1, 16), ValueSizeConstraint(24, 24), ))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppAuthenticateChapPw.setStatus('current')
hwPppAuthenticatePapUserName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 15), OctetString().subtype(subtypeSpec=ValueSizeConstraint(1, 64))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppAuthenticatePapUserName.setStatus('current')
hwPppAuthenticatePapPwType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 16), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("cipher", 1), ("simple", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppAuthenticatePapPwType.setStatus('current')
hwPppAuthenticatePapPw = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 17), OctetString().subtype(subtypeSpec=ConstraintsUnion(ValueSizeConstraint(1, 16), ValueSizeConstraint(24, 24), ))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwPppAuthenticatePapPw.setStatus('current')
hwPppConformance = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11))
hwPppCompliances = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 1))
hwPppCompliance = ModuleCompliance((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 1, 1)).setObjects(("HUAWEI-PPP-MIB", "hwPppConfigObjectGroup"), ("HUAWEI-PPP-MIB", "hwPppAuthenticateObjectGroup"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwPppCompliance = hwPppCompliance.setStatus('current')
hwPppGroups = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 2))
hwPppConfigObjectGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 2, 1)).setObjects(("HUAWEI-PPP-MIB", "hwPppMruNegType"), ("HUAWEI-PPP-MIB", "hwPppMpIfIndex"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwPppConfigObjectGroup = hwPppConfigObjectGroup.setStatus('current')
hwPppAuthenticateObjectGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 2, 2)).setObjects(("HUAWEI-PPP-MIB", "hwPppAuthenticateMode"), ("HUAWEI-PPP-MIB", "hwPppAuthenticateChapUserName"), ("HUAWEI-PPP-MIB", "hwPppAuthenticateChapPwType"), ("HUAWEI-PPP-MIB", "hwPppAuthenticateChapPw"), ("HUAWEI-PPP-MIB", "hwPppAuthenticatePapUserName"), ("HUAWEI-PPP-MIB", "hwPppAuthenticatePapPwType"), ("HUAWEI-PPP-MIB", "hwPppAuthenticatePapPw"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwPppAuthenticateObjectGroup = hwPppAuthenticateObjectGroup.setStatus('current')
mibBuilder.exportSymbols("HUAWEI-PPP-MIB", hwPppAuthenticateMode=hwPppAuthenticateMode, hwPppAuthenticateChapUserName=hwPppAuthenticateChapUserName, hwPppConformance=hwPppConformance, hwPppIfIndex=hwPppIfIndex, hwPppAuthenticatePapPw=hwPppAuthenticatePapPw, hwPppConfigObjectGroup=hwPppConfigObjectGroup, hwPppMruNegType=hwPppMruNegType, hwPppCompliances=hwPppCompliances, PYSNMP_MODULE_ID=hwPppMIB, hwPppGroups=hwPppGroups, hwPppAuthenticateEntry=hwPppAuthenticateEntry, hwPppObjects=hwPppObjects, hwPppConfigEntry=hwPppConfigEntry, hwPppAuthenticateTable=hwPppAuthenticateTable, hwPppAuthenticateChapPw=hwPppAuthenticateChapPw, hwPppAuthenticateChapPwType=hwPppAuthenticateChapPwType, hwPppAuthenticatePapUserName=hwPppAuthenticatePapUserName, hwPppCompliance=hwPppCompliance, hwPppConfigTable=hwPppConfigTable, hwPppAuthenticateObjectGroup=hwPppAuthenticateObjectGroup, hwPppAuthenticatePapPwType=hwPppAuthenticatePapPwType, hwPppMIB=hwPppMIB, hwPppMpIfIndex=hwPppMpIfIndex)
| (object_identifier, octet_string, integer) = mibBuilder.importSymbols('ASN1', 'ObjectIdentifier', 'OctetString', 'Integer')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(constraints_union, constraints_intersection, value_range_constraint, single_value_constraint, value_size_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ConstraintsUnion', 'ConstraintsIntersection', 'ValueRangeConstraint', 'SingleValueConstraint', 'ValueSizeConstraint')
(hw_datacomm,) = mibBuilder.importSymbols('HUAWEI-MIB', 'hwDatacomm')
(interface_index,) = mibBuilder.importSymbols('IF-MIB', 'InterfaceIndex')
(notification_group, object_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ObjectGroup', 'ModuleCompliance')
(module_identity, mib_identifier, gauge32, object_identity, integer32, counter32, counter64, notification_type, unsigned32, iso, bits, time_ticks, ip_address, mib_scalar, mib_table, mib_table_row, mib_table_column) = mibBuilder.importSymbols('SNMPv2-SMI', 'ModuleIdentity', 'MibIdentifier', 'Gauge32', 'ObjectIdentity', 'Integer32', 'Counter32', 'Counter64', 'NotificationType', 'Unsigned32', 'iso', 'Bits', 'TimeTicks', 'IpAddress', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn')
(truth_value, display_string, row_status, textual_convention) = mibBuilder.importSymbols('SNMPv2-TC', 'TruthValue', 'DisplayString', 'RowStatus', 'TextualConvention')
hw_ppp_mib = module_identity((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169))
if mibBuilder.loadTexts:
hwPppMIB.setLastUpdated('200710172230Z')
if mibBuilder.loadTexts:
hwPppMIB.setOrganization('Huawei Technologies co.,Ltd.')
hw_ppp_objects = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1))
hw_ppp_config_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1))
if mibBuilder.loadTexts:
hwPppConfigTable.setStatus('current')
hw_ppp_config_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1)).setIndexNames((0, 'HUAWEI-PPP-MIB', 'hwPppIfIndex'))
if mibBuilder.loadTexts:
hwPppConfigEntry.setStatus('current')
hw_ppp_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1, 1), interface_index())
if mibBuilder.loadTexts:
hwPppIfIndex.setStatus('current')
hw_ppp_mru_neg_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1, 11), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('ipv4', 1), ('ipv6', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppMruNegType.setStatus('current')
hw_ppp_mp_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 1, 1, 12), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppMpIfIndex.setStatus('current')
hw_ppp_authenticate_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2))
if mibBuilder.loadTexts:
hwPppAuthenticateTable.setStatus('current')
hw_ppp_authenticate_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1)).setIndexNames((0, 'HUAWEI-PPP-MIB', 'hwPppIfIndex'))
if mibBuilder.loadTexts:
hwPppAuthenticateEntry.setStatus('current')
hw_ppp_authenticate_mode = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 11), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('chap', 1), ('pap', 2), ('chappap', 3)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppAuthenticateMode.setStatus('current')
hw_ppp_authenticate_chap_user_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 12), octet_string().subtype(subtypeSpec=value_size_constraint(1, 64))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppAuthenticateChapUserName.setStatus('current')
hw_ppp_authenticate_chap_pw_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 13), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('cipher', 1), ('simple', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppAuthenticateChapPwType.setStatus('current')
hw_ppp_authenticate_chap_pw = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 14), octet_string().subtype(subtypeSpec=constraints_union(value_size_constraint(1, 16), value_size_constraint(24, 24)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppAuthenticateChapPw.setStatus('current')
hw_ppp_authenticate_pap_user_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 15), octet_string().subtype(subtypeSpec=value_size_constraint(1, 64))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppAuthenticatePapUserName.setStatus('current')
hw_ppp_authenticate_pap_pw_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 16), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('cipher', 1), ('simple', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppAuthenticatePapPwType.setStatus('current')
hw_ppp_authenticate_pap_pw = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 1, 2, 1, 17), octet_string().subtype(subtypeSpec=constraints_union(value_size_constraint(1, 16), value_size_constraint(24, 24)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwPppAuthenticatePapPw.setStatus('current')
hw_ppp_conformance = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11))
hw_ppp_compliances = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 1))
hw_ppp_compliance = module_compliance((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 1, 1)).setObjects(('HUAWEI-PPP-MIB', 'hwPppConfigObjectGroup'), ('HUAWEI-PPP-MIB', 'hwPppAuthenticateObjectGroup'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_ppp_compliance = hwPppCompliance.setStatus('current')
hw_ppp_groups = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 2))
hw_ppp_config_object_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 2, 1)).setObjects(('HUAWEI-PPP-MIB', 'hwPppMruNegType'), ('HUAWEI-PPP-MIB', 'hwPppMpIfIndex'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_ppp_config_object_group = hwPppConfigObjectGroup.setStatus('current')
hw_ppp_authenticate_object_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 169, 11, 2, 2)).setObjects(('HUAWEI-PPP-MIB', 'hwPppAuthenticateMode'), ('HUAWEI-PPP-MIB', 'hwPppAuthenticateChapUserName'), ('HUAWEI-PPP-MIB', 'hwPppAuthenticateChapPwType'), ('HUAWEI-PPP-MIB', 'hwPppAuthenticateChapPw'), ('HUAWEI-PPP-MIB', 'hwPppAuthenticatePapUserName'), ('HUAWEI-PPP-MIB', 'hwPppAuthenticatePapPwType'), ('HUAWEI-PPP-MIB', 'hwPppAuthenticatePapPw'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_ppp_authenticate_object_group = hwPppAuthenticateObjectGroup.setStatus('current')
mibBuilder.exportSymbols('HUAWEI-PPP-MIB', hwPppAuthenticateMode=hwPppAuthenticateMode, hwPppAuthenticateChapUserName=hwPppAuthenticateChapUserName, hwPppConformance=hwPppConformance, hwPppIfIndex=hwPppIfIndex, hwPppAuthenticatePapPw=hwPppAuthenticatePapPw, hwPppConfigObjectGroup=hwPppConfigObjectGroup, hwPppMruNegType=hwPppMruNegType, hwPppCompliances=hwPppCompliances, PYSNMP_MODULE_ID=hwPppMIB, hwPppGroups=hwPppGroups, hwPppAuthenticateEntry=hwPppAuthenticateEntry, hwPppObjects=hwPppObjects, hwPppConfigEntry=hwPppConfigEntry, hwPppAuthenticateTable=hwPppAuthenticateTable, hwPppAuthenticateChapPw=hwPppAuthenticateChapPw, hwPppAuthenticateChapPwType=hwPppAuthenticateChapPwType, hwPppAuthenticatePapUserName=hwPppAuthenticatePapUserName, hwPppCompliance=hwPppCompliance, hwPppConfigTable=hwPppConfigTable, hwPppAuthenticateObjectGroup=hwPppAuthenticateObjectGroup, hwPppAuthenticatePapPwType=hwPppAuthenticatePapPwType, hwPppMIB=hwPppMIB, hwPppMpIfIndex=hwPppMpIfIndex) |
class ColorLanguageTranslator:
START = "CRYCYMCRW"
END = "CMW"
@staticmethod
def base7(num):
if num == 0:
return '0'
new_num_string = ''
current = num
while current != 0:
remainder = current % 7
remainder_string = str(remainder)
new_num_string = remainder_string + new_num_string
current //= 7
return new_num_string
# Function for converting a base-7 number(given as a string) to a 3 digit color code:
@staticmethod
def base7_to_color_code(num):
colorDict = {
'0': 'K',
'1': 'R',
'2': 'G',
'3': 'Y',
'4': 'B',
'5': 'M',
'6': 'C',
}
if len(num) == 1:
num = "00" + num
elif len(num) == 2:
num = "0" + num
chars = list(num)
return colorDict[chars[0]] + colorDict[chars[1]] + colorDict[chars[2]]
@staticmethod
def translate(byte_array):
color_sequence = "".join([ColorLanguageTranslator.base7_to_color_code(ColorLanguageTranslator.base7(x)) for x in byte_array])
sequence_with_repetition = ColorLanguageTranslator.START + color_sequence + ColorLanguageTranslator.END
end_sequence = ""
for i, c in enumerate(sequence_with_repetition):
if i == 0 or sequence_with_repetition[i - 1] != c or end_sequence[i - 1] == 'W':
end_sequence += c
else:
end_sequence += 'W'
return end_sequence | class Colorlanguagetranslator:
start = 'CRYCYMCRW'
end = 'CMW'
@staticmethod
def base7(num):
if num == 0:
return '0'
new_num_string = ''
current = num
while current != 0:
remainder = current % 7
remainder_string = str(remainder)
new_num_string = remainder_string + new_num_string
current //= 7
return new_num_string
@staticmethod
def base7_to_color_code(num):
color_dict = {'0': 'K', '1': 'R', '2': 'G', '3': 'Y', '4': 'B', '5': 'M', '6': 'C'}
if len(num) == 1:
num = '00' + num
elif len(num) == 2:
num = '0' + num
chars = list(num)
return colorDict[chars[0]] + colorDict[chars[1]] + colorDict[chars[2]]
@staticmethod
def translate(byte_array):
color_sequence = ''.join([ColorLanguageTranslator.base7_to_color_code(ColorLanguageTranslator.base7(x)) for x in byte_array])
sequence_with_repetition = ColorLanguageTranslator.START + color_sequence + ColorLanguageTranslator.END
end_sequence = ''
for (i, c) in enumerate(sequence_with_repetition):
if i == 0 or sequence_with_repetition[i - 1] != c or end_sequence[i - 1] == 'W':
end_sequence += c
else:
end_sequence += 'W'
return end_sequence |
#https://codeforces.com/problemset/problem/734/A
input()
string = input()
a = string.count('A')
d = string.count('D')
if(a>d):
print('Anton')
elif d>a:
print('Danik')
else:
print('Friendship') | input()
string = input()
a = string.count('A')
d = string.count('D')
if a > d:
print('Anton')
elif d > a:
print('Danik')
else:
print('Friendship') |
# Round the number from input to the required number of
# decimals.
# The input format:
# Two lines: the first with a floating-point number, the second
# with an integer representing the decimal count.
# The output format:
# A formatted string containing the rounded number.
# Do NOT forget to convert the input numbers and to enclose
# each value in {} in a formatted string
# Sample Input 1:
# 2.71828
# 3
# Sample Output 1:
# 2.718
# first solution
decimal = float(input())
nth_place = int(input())
print(f'%.{nth_place}f' % decimal)
#second sol
print(f'{decimal:.{nth_place}f}')
#one line code
print(f"{float(input()):.{int(input())}f}")
| decimal = float(input())
nth_place = int(input())
print(f'%.{nth_place}f' % decimal)
print(f'{decimal:.{nth_place}f}')
print(f'{float(input()):.{int(input())}f}') |
'''
This is the position of all the pieces, in a dictionary. This data is essential for the gameplay to work
'''
position_dic = { 'a1': "Left White Rook", 'b1': "Left White Knight", 'c1': "Left White Bishop", 'd1': "White Queen", 'e1': "White King", 'f1': "Right White Bishop", 'g1': "Right White Knight", 'h1': "Right White Rook",
'a2': "White Pawn1", 'b2': "White Pawn2", 'c2': "White Pawn3", 'd2': "White Pawn4", 'e2': "White Pawn5", 'f2': "White Pawn6", 'g2': "White Pawn7", 'h2': "White Pawn8",
'a3': "None", 'b3': "None", 'c3': "None", 'd3': "None", 'e3': "None", 'f3': "None", 'g3': "None", 'h3': "None",
'a4': "None", 'b4': "None", 'c4': "None", 'd4': "None", 'e4': "None", 'f4': "None", 'g4': "None", 'h4': "None",
'a5': "None", 'b5': "None", 'c5': "None", 'd5': "None", 'e5': "None", 'f5': "None", 'g5': "None", 'h5': "None",
'a6': "None", 'b6': "None", 'c6': "None", 'd6': "None", 'e6': "None", 'f6': "None", 'g6': "None", 'h6': "None",
'a8': "Left Black Rook", 'b8': "Left Black Knight", 'c8': "Left Black Bishop", 'd8': "Black Queen", 'e8': "Black King", 'f8': "Right Black Bishop", 'g8': "Right Black Knight", 'h8': "Right Black Rook",
'a7': "Black Pawn1", 'b7': "Black Pawn2", 'c7': "Black Pawn3", 'd7': "Black Pawn4", 'e7': "Black Pawn5", 'f7': "Black Pawn6", 'g7': "Black Pawn7", 'h7': "Black Pawn8"
}
'''
Decalres what team is allowed to move their pieces
'''
conversion_to_number = {'a1': 1, 'b1': 2, 'c1': 3, 'd1':4, 'e1':5, 'f1':6, 'g1':7, 'h1':8,
'a2': 9, 'b2': 10, 'c2': 11, 'd2':12, 'e2':13, 'f2':14, 'g2':15, 'h2':16,
'a3': 17, 'b3': 18, 'c3': 19, 'd3':20, 'e3':21, 'f3':22, 'g3':23, 'h3':24,
'a4': 25, 'b4': 26, 'c4': 27, 'd4':28, 'e4':29, 'f4':30, 'g4':31, 'h4':32,
'a5': 33, 'b5': 34, 'c5': 35, 'd5':36, 'e5':37, 'f5':38, 'g5':39, 'h5':40,
'a6': 41, 'b6': 42, 'c6': 43, 'd6':44, 'e6':45, 'f6':46, 'g6':47, 'h6':48,
'a7': 49, 'b7': 50, 'c7':51, 'd7':52, 'e7':53, 'f7':54, 'g7':55, 'h7':56,
'a8': 57, 'b8': 58, 'c8': 59, 'd8':60, 'e8':61, 'f8':62, 'g8':63, 'h8':64}
team_turn = 1
| """
This is the position of all the pieces, in a dictionary. This data is essential for the gameplay to work
"""
position_dic = {'a1': 'Left White Rook', 'b1': 'Left White Knight', 'c1': 'Left White Bishop', 'd1': 'White Queen', 'e1': 'White King', 'f1': 'Right White Bishop', 'g1': 'Right White Knight', 'h1': 'Right White Rook', 'a2': 'White Pawn1', 'b2': 'White Pawn2', 'c2': 'White Pawn3', 'd2': 'White Pawn4', 'e2': 'White Pawn5', 'f2': 'White Pawn6', 'g2': 'White Pawn7', 'h2': 'White Pawn8', 'a3': 'None', 'b3': 'None', 'c3': 'None', 'd3': 'None', 'e3': 'None', 'f3': 'None', 'g3': 'None', 'h3': 'None', 'a4': 'None', 'b4': 'None', 'c4': 'None', 'd4': 'None', 'e4': 'None', 'f4': 'None', 'g4': 'None', 'h4': 'None', 'a5': 'None', 'b5': 'None', 'c5': 'None', 'd5': 'None', 'e5': 'None', 'f5': 'None', 'g5': 'None', 'h5': 'None', 'a6': 'None', 'b6': 'None', 'c6': 'None', 'd6': 'None', 'e6': 'None', 'f6': 'None', 'g6': 'None', 'h6': 'None', 'a8': 'Left Black Rook', 'b8': 'Left Black Knight', 'c8': 'Left Black Bishop', 'd8': 'Black Queen', 'e8': 'Black King', 'f8': 'Right Black Bishop', 'g8': 'Right Black Knight', 'h8': 'Right Black Rook', 'a7': 'Black Pawn1', 'b7': 'Black Pawn2', 'c7': 'Black Pawn3', 'd7': 'Black Pawn4', 'e7': 'Black Pawn5', 'f7': 'Black Pawn6', 'g7': 'Black Pawn7', 'h7': 'Black Pawn8'}
'\nDecalres what team is allowed to move their pieces\n'
conversion_to_number = {'a1': 1, 'b1': 2, 'c1': 3, 'd1': 4, 'e1': 5, 'f1': 6, 'g1': 7, 'h1': 8, 'a2': 9, 'b2': 10, 'c2': 11, 'd2': 12, 'e2': 13, 'f2': 14, 'g2': 15, 'h2': 16, 'a3': 17, 'b3': 18, 'c3': 19, 'd3': 20, 'e3': 21, 'f3': 22, 'g3': 23, 'h3': 24, 'a4': 25, 'b4': 26, 'c4': 27, 'd4': 28, 'e4': 29, 'f4': 30, 'g4': 31, 'h4': 32, 'a5': 33, 'b5': 34, 'c5': 35, 'd5': 36, 'e5': 37, 'f5': 38, 'g5': 39, 'h5': 40, 'a6': 41, 'b6': 42, 'c6': 43, 'd6': 44, 'e6': 45, 'f6': 46, 'g6': 47, 'h6': 48, 'a7': 49, 'b7': 50, 'c7': 51, 'd7': 52, 'e7': 53, 'f7': 54, 'g7': 55, 'h7': 56, 'a8': 57, 'b8': 58, 'c8': 59, 'd8': 60, 'e8': 61, 'f8': 62, 'g8': 63, 'h8': 64}
team_turn = 1 |
count = 0
def max_ind_set(nodes, edges):
global count
if len(nodes) <= 1: return len(nodes)
node = nodes[0] # pick a node
# case 1: node lies in independent set => remove neighbours as well
nodes1 = [ n for n in nodes if n != node and (node, n) not in edges ]
size1 = 1 + max_ind_set(nodes1, edges)
count += 1
# case 2: node does not lie in independent set
nodes2 = [ n for n in nodes if n != node ]
size2 = max_ind_set(nodes2, edges)
count += 1
return max(size1, size2)
def max_ind_set_improved(nodes, edges):
if len(nodes) <= 1: return len(nodes)
node = nodes[0] # pick a node
# case 1: node lies in independent set => remove neighbours as well
nodes1 = [ n for n in nodes if n != node and (node, n) not in edges ]
size1 = 1 + max_ind_set_improved(nodes1, edges)
if len([ n for n in nodes if (node, n) in edges ]) <= 1:
return size1
# case 2: node does not lie in independent set
nodes2 = [ n for n in nodes if n != node ]
size2 = max_ind_set_improved(nodes2, edges)
return max(size1, size2)
if __name__ == '__main__':
nodes = [1,2,3,4,5,6,7,8]
edges = [(1,2),(1,3),(2,3),(2,4),(3,5),(4,5),(4,6),(5,7),(6,7),(6,8),(7,8)]
# undirected graph => edges go in both directions (simplifies algorithms)
edges += [ (b,a) for (a,b) in edges ]
print("max_ind_set = {}".format(max_ind_set(nodes,edges)))
print("max_ind_set_improved = {}".format(max_ind_set_improved(nodes,edges)))
print(count)
| count = 0
def max_ind_set(nodes, edges):
global count
if len(nodes) <= 1:
return len(nodes)
node = nodes[0]
nodes1 = [n for n in nodes if n != node and (node, n) not in edges]
size1 = 1 + max_ind_set(nodes1, edges)
count += 1
nodes2 = [n for n in nodes if n != node]
size2 = max_ind_set(nodes2, edges)
count += 1
return max(size1, size2)
def max_ind_set_improved(nodes, edges):
if len(nodes) <= 1:
return len(nodes)
node = nodes[0]
nodes1 = [n for n in nodes if n != node and (node, n) not in edges]
size1 = 1 + max_ind_set_improved(nodes1, edges)
if len([n for n in nodes if (node, n) in edges]) <= 1:
return size1
nodes2 = [n for n in nodes if n != node]
size2 = max_ind_set_improved(nodes2, edges)
return max(size1, size2)
if __name__ == '__main__':
nodes = [1, 2, 3, 4, 5, 6, 7, 8]
edges = [(1, 2), (1, 3), (2, 3), (2, 4), (3, 5), (4, 5), (4, 6), (5, 7), (6, 7), (6, 8), (7, 8)]
edges += [(b, a) for (a, b) in edges]
print('max_ind_set = {}'.format(max_ind_set(nodes, edges)))
print('max_ind_set_improved = {}'.format(max_ind_set_improved(nodes, edges)))
print(count) |
ENCRYPTED_MESSAGE = 'IQ PQTVJ CV PQQP'
DECRYPTED_MESSAGE = 'GO NORTH AT NOON'
CIPHER_OPTIONS = ['null','caesar','atbash']
cipher_used_in_this_example = CIPHER_OPTIONS[1] # replace with the index of the cipher used in this encryption
| encrypted_message = 'IQ PQTVJ CV PQQP'
decrypted_message = 'GO NORTH AT NOON'
cipher_options = ['null', 'caesar', 'atbash']
cipher_used_in_this_example = CIPHER_OPTIONS[1] |
# AUTOGENERATED BY NBDEV! DO NOT EDIT!
__all__ = ["index", "modules", "custom_doc_links", "git_url"]
index = {"img_resize": "00_clipmodel.ipynb",
"imgs_resize": "00_clipmodel.ipynb",
"dict_to_device": "00_clipmodel.ipynb",
"norm": "00_clipmodel.ipynb",
"detach_norm": "00_clipmodel.ipynb",
"text2clip_en": "00_clipmodel.ipynb",
"images2clip_en": "00_clipmodel.ipynb",
"image2clip": "00_clipmodel.ipynb",
"en_model_name": "00_clipmodel.ipynb",
"tokenizer": "00_clipmodel.ipynb",
"en_processor": "00_clipmodel.ipynb",
"en_size": "00_clipmodel.ipynb",
"en_dim": "00_clipmodel.ipynb",
"images2clip": "00_clipmodel.ipynb",
"text2clip": "00_clipmodel.ipynb",
"read_sql_query": "00_custom_pandas.ipynb",
"Path.ls": "00_tools.ipynb",
"mapbox_access_token": "00_paths.ipynb",
"main_path": "00_paths.ipynb",
"data_path": "00_paths.ipynb",
"reference_images_path": "00_paths.ipynb",
"testset_path": "00_paths.ipynb",
"engine": "00_psql.ipynb",
"Session": "00_psql.ipynb",
"session": "00_psql.ipynb",
"Base": "00_psql.ipynb",
"du": "00_psql.ipynb",
"query": "00_psql.ipynb",
"current": "00_psql.ipynb",
"kill": "00_tools.ipynb",
"schema": "00_psql.ipynb",
"LocalBase": "00_psql.ipynb",
"insert_on_conflict": "00_psql.ipynb",
"read_sql": "00_psql.ipynb",
"Foods": "00_psql.ipynb",
"Users": "00_psql.ipynb",
"Dishes": "00_psql.ipynb",
"User_properties": "00_psql.ipynb",
"FoodsP": "00_psql.ipynb",
"FoodsPI": "00_psql.ipynb",
"FFoods": "00_psql.ipynb",
"Food_reference_images": "00_psql.ipynb",
"Portions": "00_psql.ipynb",
"Indexed": "00_psql.ipynb",
"collection_name": "01_search.ipynb",
"dim": "00_qdrant.ipynb",
"QdrantClient.get_collections": "00_qdrant.ipynb",
"QdrantClient.collection_len": "00_qdrant.ipynb",
"prod_client": "00_qdrant.ipynb",
"dev_client": "00_qdrant.ipynb",
"get_image_from_url": "00_tools.ipynb",
"get_hash_folder": "00_tools.ipynb",
"save_selected_cities": "00_tools.ipynb",
"save_location_dicts": "00_tools.ipynb",
"get_top_n_countries": "00_tools.ipynb",
"path_info": "00_tools.ipynb",
"rm_r": "00_tools.ipynb",
"search_notebooks": "00_tools.ipynb",
"df_chunk_generator": "00_tools.ipynb",
"docker_container": "00_tools.ipynb",
"LogDBHandler": "00_tools.ipynb",
"get_logger": "00_tools.ipynb",
"read_image_from_url": "01_search.ipynb",
"compound_return": "00_tools.ipynb",
"copy_func": "00_tools.ipynb",
"patch_to": "00_tools.ipynb",
"patch": "00_tools.ipynb",
"to_pickle": "00_tools.ipynb",
"from_pickle": "00_tools.ipynb",
"telegram": "00_tools.ipynb",
"pdrows": "00_tools.ipynb",
"pd_highlight": "00_tools.ipynb",
"inline": "00_tools.ipynb",
"plot_map": "00_tools.ipynb",
"htop": "00_tools.ipynb",
"get_proxies": "00_tools.ipynb",
"append_csv": "00_tools.ipynb",
"repeat_df": "00_tools.ipynb",
"to_sql": "00_tools.ipynb",
"timestamp2int": "00_tools.ipynb",
"pd_timestamp": "00_tools.ipynb",
"startEndTimestamp": "00_tools.ipynb",
"pd_set_float": "00_tools.ipynb",
"plot_multiple_y": "00_tools.ipynb",
"sql_head": "00_tools.ipynb",
"make_clickable": "00_tools.ipynb",
"selected_countries": "00_tools.ipynb",
"foods": "01_search.ipynb",
"search_image": "01_search.ipynb",
"cos": "01_search.ipynb",
"table": "01_search.ipynb",
"search_image_": "01_search.ipynb",
"series2tensor": "01_search.ipynb",
"multiply_vector": "01_search.ipynb",
"drop_vector": "01_search.ipynb",
"multiple_foods": "01_search.ipynb"}
modules = ["clipmodel.py",
"custom_pandas.py",
"paths.py",
"psql.py",
"qdrant.py",
"tools.py",
"classify_image.py",
"search.py"]
doc_url = "https://{user}.github.io/food/"
git_url = "https://github.com/{user}/food/tree/{branch}/"
def custom_doc_links(name): return None
| __all__ = ['index', 'modules', 'custom_doc_links', 'git_url']
index = {'img_resize': '00_clipmodel.ipynb', 'imgs_resize': '00_clipmodel.ipynb', 'dict_to_device': '00_clipmodel.ipynb', 'norm': '00_clipmodel.ipynb', 'detach_norm': '00_clipmodel.ipynb', 'text2clip_en': '00_clipmodel.ipynb', 'images2clip_en': '00_clipmodel.ipynb', 'image2clip': '00_clipmodel.ipynb', 'en_model_name': '00_clipmodel.ipynb', 'tokenizer': '00_clipmodel.ipynb', 'en_processor': '00_clipmodel.ipynb', 'en_size': '00_clipmodel.ipynb', 'en_dim': '00_clipmodel.ipynb', 'images2clip': '00_clipmodel.ipynb', 'text2clip': '00_clipmodel.ipynb', 'read_sql_query': '00_custom_pandas.ipynb', 'Path.ls': '00_tools.ipynb', 'mapbox_access_token': '00_paths.ipynb', 'main_path': '00_paths.ipynb', 'data_path': '00_paths.ipynb', 'reference_images_path': '00_paths.ipynb', 'testset_path': '00_paths.ipynb', 'engine': '00_psql.ipynb', 'Session': '00_psql.ipynb', 'session': '00_psql.ipynb', 'Base': '00_psql.ipynb', 'du': '00_psql.ipynb', 'query': '00_psql.ipynb', 'current': '00_psql.ipynb', 'kill': '00_tools.ipynb', 'schema': '00_psql.ipynb', 'LocalBase': '00_psql.ipynb', 'insert_on_conflict': '00_psql.ipynb', 'read_sql': '00_psql.ipynb', 'Foods': '00_psql.ipynb', 'Users': '00_psql.ipynb', 'Dishes': '00_psql.ipynb', 'User_properties': '00_psql.ipynb', 'FoodsP': '00_psql.ipynb', 'FoodsPI': '00_psql.ipynb', 'FFoods': '00_psql.ipynb', 'Food_reference_images': '00_psql.ipynb', 'Portions': '00_psql.ipynb', 'Indexed': '00_psql.ipynb', 'collection_name': '01_search.ipynb', 'dim': '00_qdrant.ipynb', 'QdrantClient.get_collections': '00_qdrant.ipynb', 'QdrantClient.collection_len': '00_qdrant.ipynb', 'prod_client': '00_qdrant.ipynb', 'dev_client': '00_qdrant.ipynb', 'get_image_from_url': '00_tools.ipynb', 'get_hash_folder': '00_tools.ipynb', 'save_selected_cities': '00_tools.ipynb', 'save_location_dicts': '00_tools.ipynb', 'get_top_n_countries': '00_tools.ipynb', 'path_info': '00_tools.ipynb', 'rm_r': '00_tools.ipynb', 'search_notebooks': '00_tools.ipynb', 'df_chunk_generator': '00_tools.ipynb', 'docker_container': '00_tools.ipynb', 'LogDBHandler': '00_tools.ipynb', 'get_logger': '00_tools.ipynb', 'read_image_from_url': '01_search.ipynb', 'compound_return': '00_tools.ipynb', 'copy_func': '00_tools.ipynb', 'patch_to': '00_tools.ipynb', 'patch': '00_tools.ipynb', 'to_pickle': '00_tools.ipynb', 'from_pickle': '00_tools.ipynb', 'telegram': '00_tools.ipynb', 'pdrows': '00_tools.ipynb', 'pd_highlight': '00_tools.ipynb', 'inline': '00_tools.ipynb', 'plot_map': '00_tools.ipynb', 'htop': '00_tools.ipynb', 'get_proxies': '00_tools.ipynb', 'append_csv': '00_tools.ipynb', 'repeat_df': '00_tools.ipynb', 'to_sql': '00_tools.ipynb', 'timestamp2int': '00_tools.ipynb', 'pd_timestamp': '00_tools.ipynb', 'startEndTimestamp': '00_tools.ipynb', 'pd_set_float': '00_tools.ipynb', 'plot_multiple_y': '00_tools.ipynb', 'sql_head': '00_tools.ipynb', 'make_clickable': '00_tools.ipynb', 'selected_countries': '00_tools.ipynb', 'foods': '01_search.ipynb', 'search_image': '01_search.ipynb', 'cos': '01_search.ipynb', 'table': '01_search.ipynb', 'search_image_': '01_search.ipynb', 'series2tensor': '01_search.ipynb', 'multiply_vector': '01_search.ipynb', 'drop_vector': '01_search.ipynb', 'multiple_foods': '01_search.ipynb'}
modules = ['clipmodel.py', 'custom_pandas.py', 'paths.py', 'psql.py', 'qdrant.py', 'tools.py', 'classify_image.py', 'search.py']
doc_url = 'https://{user}.github.io/food/'
git_url = 'https://github.com/{user}/food/tree/{branch}/'
def custom_doc_links(name):
return None |
# -*- coding: utf-8 -*-
__author__ = 'Russell Davies'
__copyright__ = 'Copyright (c) 2019-present - Russell Davies'
__description__ = 'The blakemere package provides a collection of python libraries created by Russell Davies.'
__email__ = 'russell@blakemere.ca'
__license__ = 'MIT'
__title__ = 'blakemere'
__version__ = '0.1.0' | __author__ = 'Russell Davies'
__copyright__ = 'Copyright (c) 2019-present - Russell Davies'
__description__ = 'The blakemere package provides a collection of python libraries created by Russell Davies.'
__email__ = 'russell@blakemere.ca'
__license__ = 'MIT'
__title__ = 'blakemere'
__version__ = '0.1.0' |
def mergeList(lis1, list2):
print("list1 =", list1)
print("list2 =", list2)
list3 = []
for i in list1:
if(i % 2 == 1):
list3.append(i)
for i in list2:
if(i % 2 == 0):
list3.append(i)
return list3
list1 = [10, 20, 23, 11, 17]
list2 = [13, 43, 24, 36, 12]
print("Result List is", mergeList(list1, list2)) | def merge_list(lis1, list2):
print('list1 =', list1)
print('list2 =', list2)
list3 = []
for i in list1:
if i % 2 == 1:
list3.append(i)
for i in list2:
if i % 2 == 0:
list3.append(i)
return list3
list1 = [10, 20, 23, 11, 17]
list2 = [13, 43, 24, 36, 12]
print('Result List is', merge_list(list1, list2)) |
#daemon = True
# 1 core should equal 2*1+1=3 workers
workers = 3
# we want to use threads for concurrency. we estimate that a maximum of 3*7=21 users will use the application simultaneously
worker_class = "gthread"
threads = 7
#accesslog = "logs/access.log"
#errorlog = "logs/error.log"
| workers = 3
worker_class = 'gthread'
threads = 7 |
#! /usr/bin/env python
# Copyright Lajos Katona
#
# 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.
def search_linear(mylist, t):
for i, l in enumerate(mylist):
if l == t:
return i
return -1
def search_logarithm(mylist, t):
lower_b = 0
upper_b = len(mylist)
while True:
if lower_b == upper_b:
return -1
mid = (lower_b + upper_b) // 2
mid_item = mylist[mid]
if mid_item == t:
return mid
if mid_item < t:
lower_b = mid + 1
else:
upper_b = mid
if __name__ == '__main__':
mylist = [1, 2, 3, 4, 5]
print(search_linear(mylist, 4))
print(search_logarithm(mylist, 4))
| def search_linear(mylist, t):
for (i, l) in enumerate(mylist):
if l == t:
return i
return -1
def search_logarithm(mylist, t):
lower_b = 0
upper_b = len(mylist)
while True:
if lower_b == upper_b:
return -1
mid = (lower_b + upper_b) // 2
mid_item = mylist[mid]
if mid_item == t:
return mid
if mid_item < t:
lower_b = mid + 1
else:
upper_b = mid
if __name__ == '__main__':
mylist = [1, 2, 3, 4, 5]
print(search_linear(mylist, 4))
print(search_logarithm(mylist, 4)) |
# Customer class
class Customer:
def __init__(self, name, address, phone):
self.__name = name
self.__address = address
self.__phone = phone
def set_name(self, name):
self.__name = name
def set_address(self, address):
self.__address = address
def set_phone(self, phone):
self.__phone = phone
def get_name(self):
return self.__name
def get_address(self):
return self.__address
def get_phone(self):
return self.__phone
| class Customer:
def __init__(self, name, address, phone):
self.__name = name
self.__address = address
self.__phone = phone
def set_name(self, name):
self.__name = name
def set_address(self, address):
self.__address = address
def set_phone(self, phone):
self.__phone = phone
def get_name(self):
return self.__name
def get_address(self):
return self.__address
def get_phone(self):
return self.__phone |
# %% [695. Max Area of Island](https://leetcode.com/problems/max-area-of-island/)
class Solution:
def maxAreaOfIsland(self, grid: List[List[int]]) -> int:
n, m = len(grid), len(grid[0])
u = unionfind(n, m)
for i in range(n):
for j in range(m):
if j + 1 < m and grid[i][j] == grid[i][j + 1] == 1:
u.unite((i, j), (i, j + 1))
if i + 1 < n and grid[i][j] == grid[i + 1][j] == 1:
u.unite((i, j), (i + 1, j))
u = collections.Counter(
u.find(i, j) for i in range(n) for j in range(m) if grid[i][j] == 1
).most_common(1)
return u[0][1] if u else 0
class unionfind:
def __init__(self, n, m):
self.m = m
self.parent = list(range(n * m))
def find(self, i, j):
k = i * self.m + j
while self.parent[k] != k:
k = self.parent[k]
return k
def unite(self, p, q):
self.parent[self.find(*q)] = self.find(*p)
| class Solution:
def max_area_of_island(self, grid: List[List[int]]) -> int:
(n, m) = (len(grid), len(grid[0]))
u = unionfind(n, m)
for i in range(n):
for j in range(m):
if j + 1 < m and grid[i][j] == grid[i][j + 1] == 1:
u.unite((i, j), (i, j + 1))
if i + 1 < n and grid[i][j] == grid[i + 1][j] == 1:
u.unite((i, j), (i + 1, j))
u = collections.Counter((u.find(i, j) for i in range(n) for j in range(m) if grid[i][j] == 1)).most_common(1)
return u[0][1] if u else 0
class Unionfind:
def __init__(self, n, m):
self.m = m
self.parent = list(range(n * m))
def find(self, i, j):
k = i * self.m + j
while self.parent[k] != k:
k = self.parent[k]
return k
def unite(self, p, q):
self.parent[self.find(*q)] = self.find(*p) |
# Copyright (c) 2013 The WebRTC project authors. All Rights Reserved.
#
# Use of this source code is governed by a BSD-style license
# that can be found in the LICENSE file in the root of the source
# tree. An additional intellectual property rights grant can be found
# in the file PATENTS. All contributing project authors may
# be found in the AUTHORS file in the root of the source tree.
{
'includes': [
'../build/common.gypi',
],
'targets': [
{
'target_name': 'webrtc_test_common',
'type': 'static_library',
'sources': [
'configurable_frame_size_encoder.cc',
'configurable_frame_size_encoder.h',
'direct_transport.cc',
'direct_transport.h',
'encoder_settings.cc',
'encoder_settings.h',
'fake_audio_device.cc',
'fake_audio_device.h',
'fake_decoder.cc',
'fake_decoder.h',
'fake_encoder.cc',
'fake_encoder.h',
'fake_network_pipe.cc',
'fake_network_pipe.h',
'flags.cc',
'flags.h',
'frame_generator_capturer.cc',
'frame_generator_capturer.h',
'mock_transport.h',
'null_platform_renderer.cc',
'null_transport.cc',
'null_transport.h',
'rtp_rtcp_observer.h',
'run_tests.cc',
'run_tests.h',
'run_loop.cc',
'run_loop.h',
'statistics.cc',
'statistics.h',
'vcm_capturer.cc',
'vcm_capturer.h',
'video_capturer.cc',
'video_capturer.h',
'video_renderer.cc',
'video_renderer.h',
],
# TODO(pbos): As far as I can tell these are dependencies from
# video_render and they should really not be here. This target provides
# no platform-specific rendering.
'direct_dependent_settings': {
'conditions': [
['OS=="linux"', {
'libraries': [
'-lXext',
'-lX11',
'-lGL',
],
}],
['OS=="android"', {
'libraries' : [
'-lGLESv2', '-llog',
],
}],
['OS=="mac"', {
'xcode_settings' : {
'OTHER_LDFLAGS' : [
'-framework Foundation',
'-framework AppKit',
'-framework Cocoa',
'-framework OpenGL',
'-framework CoreVideo',
'-framework CoreAudio',
'-framework AudioToolbox',
],
},
}],
],
},
'dependencies': [
'<(DEPTH)/testing/gtest.gyp:gtest',
'<(DEPTH)/third_party/gflags/gflags.gyp:gflags',
'<(webrtc_root)/modules/modules.gyp:video_capture_module',
'<(webrtc_root)/modules/modules.gyp:media_file',
'<(webrtc_root)/test/test.gyp:frame_generator',
'<(webrtc_root)/test/test.gyp:test_support',
],
},
],
'conditions': [
['include_tests==1', {
'targets': [
{
'target_name': 'webrtc_test_common_unittests',
'type': '<(gtest_target_type)',
'dependencies': [
'webrtc_test_common',
'<(DEPTH)/testing/gtest.gyp:gtest',
'<(DEPTH)/testing/gmock.gyp:gmock',
'<(webrtc_root)/test/test.gyp:test_support_main',
],
'sources': [
'fake_network_pipe_unittest.cc',
],
},
], #targets
}], # include_tests
], # conditions
}
| {'includes': ['../build/common.gypi'], 'targets': [{'target_name': 'webrtc_test_common', 'type': 'static_library', 'sources': ['configurable_frame_size_encoder.cc', 'configurable_frame_size_encoder.h', 'direct_transport.cc', 'direct_transport.h', 'encoder_settings.cc', 'encoder_settings.h', 'fake_audio_device.cc', 'fake_audio_device.h', 'fake_decoder.cc', 'fake_decoder.h', 'fake_encoder.cc', 'fake_encoder.h', 'fake_network_pipe.cc', 'fake_network_pipe.h', 'flags.cc', 'flags.h', 'frame_generator_capturer.cc', 'frame_generator_capturer.h', 'mock_transport.h', 'null_platform_renderer.cc', 'null_transport.cc', 'null_transport.h', 'rtp_rtcp_observer.h', 'run_tests.cc', 'run_tests.h', 'run_loop.cc', 'run_loop.h', 'statistics.cc', 'statistics.h', 'vcm_capturer.cc', 'vcm_capturer.h', 'video_capturer.cc', 'video_capturer.h', 'video_renderer.cc', 'video_renderer.h'], 'direct_dependent_settings': {'conditions': [['OS=="linux"', {'libraries': ['-lXext', '-lX11', '-lGL']}], ['OS=="android"', {'libraries': ['-lGLESv2', '-llog']}], ['OS=="mac"', {'xcode_settings': {'OTHER_LDFLAGS': ['-framework Foundation', '-framework AppKit', '-framework Cocoa', '-framework OpenGL', '-framework CoreVideo', '-framework CoreAudio', '-framework AudioToolbox']}}]]}, 'dependencies': ['<(DEPTH)/testing/gtest.gyp:gtest', '<(DEPTH)/third_party/gflags/gflags.gyp:gflags', '<(webrtc_root)/modules/modules.gyp:video_capture_module', '<(webrtc_root)/modules/modules.gyp:media_file', '<(webrtc_root)/test/test.gyp:frame_generator', '<(webrtc_root)/test/test.gyp:test_support']}], 'conditions': [['include_tests==1', {'targets': [{'target_name': 'webrtc_test_common_unittests', 'type': '<(gtest_target_type)', 'dependencies': ['webrtc_test_common', '<(DEPTH)/testing/gtest.gyp:gtest', '<(DEPTH)/testing/gmock.gyp:gmock', '<(webrtc_root)/test/test.gyp:test_support_main'], 'sources': ['fake_network_pipe_unittest.cc']}]}]]} |
#!/usr/bin/python3
'''This module contains the add_integer function
'''
def add_integer(a, b=98):
'''add_integer adds two integers and/or floats together
and returns an integer of their sum
'''
if not isinstance(a, (int, float)):
raise TypeError("a must be an integer")
if not isinstance(b, (int, float)):
raise TypeError("b must be an integer")
return int(a) + int(b)
| """This module contains the add_integer function
"""
def add_integer(a, b=98):
"""add_integer adds two integers and/or floats together
and returns an integer of their sum
"""
if not isinstance(a, (int, float)):
raise type_error('a must be an integer')
if not isinstance(b, (int, float)):
raise type_error('b must be an integer')
return int(a) + int(b) |
class Config(object):
def __init__(self, stellar_sed, laser_sed,
filt, nsamples, sample_rate, pulse_duration):
self.stellar_sed = stellar_sed
self.laser_sed = laser_sed
self.filt = filt
self.nsamples = nsamples # in ns
self.sample_rate = sample_rate # in ns
self.pulse_duration = pulse_duration
| class Config(object):
def __init__(self, stellar_sed, laser_sed, filt, nsamples, sample_rate, pulse_duration):
self.stellar_sed = stellar_sed
self.laser_sed = laser_sed
self.filt = filt
self.nsamples = nsamples
self.sample_rate = sample_rate
self.pulse_duration = pulse_duration |
# This is a util to create the advancement files
# Advancement list from https://github.com/jan00bl/mcfunction-novum/blob/master/lib/1.16/id/advancement.json
advancements = [
"minecraft:adventure/adventuring_time",
"minecraft:adventure/arbalistic",
"minecraft:adventure/bullseye",
"minecraft:adventure/hero_of_the_village",
"minecraft:adventure/honey_block_slide",
"minecraft:adventure/kill_all_mobs",
"minecraft:adventure/kill_a_mob",
"minecraft:adventure/ol_betsy",
"minecraft:adventure/root",
"minecraft:adventure/shoot_arrow",
"minecraft:adventure/sleep_in_bed",
"minecraft:adventure/sniper_duel",
"minecraft:adventure/summon_iron_golem",
"minecraft:adventure/throw_trident",
"minecraft:adventure/totem_of_undying",
"minecraft:adventure/trade",
"minecraft:adventure/two_birds_one_arrow",
"minecraft:adventure/very_very_frightening",
"minecraft:adventure/voluntary_exile",
"minecraft:adventure/whos_the_pillager_now",
"minecraft:end/dragon_breath",
"minecraft:end/dragon_egg",
"minecraft:end/elytra",
"minecraft:end/enter_end_gateway",
"minecraft:end/find_end_city",
"minecraft:end/kill_dragon",
"minecraft:end/levitate",
"minecraft:end/respawn_dragon",
"minecraft:end/root",
"minecraft:husbandry/balanced_diet",
"minecraft:husbandry/bred_all_animals",
"minecraft:husbandry/breed_an_animal",
"minecraft:husbandry/complete_catalogue",
"minecraft:husbandry/fishy_business",
"minecraft:husbandry/obtain_netherite_hoe",
"minecraft:husbandry/plant_seed",
"minecraft:husbandry/root",
"minecraft:husbandry/safely_harvest_honey",
"minecraft:husbandry/silk_touch_nest",
"minecraft:husbandry/tactical_fishing",
"minecraft:husbandry/tame_an_animal",
"minecraft:nether/all_effects",
"minecraft:nether/all_potions",
"minecraft:nether/brew_potion",
"minecraft:nether/charge_respawn_anchor",
"minecraft:nether/create_beacon",
"minecraft:nether/create_full_beacon",
"minecraft:nether/distract_piglin",
"minecraft:nether/explore_nether",
"minecraft:nether/fast_travel",
"minecraft:nether/find_bastion",
"minecraft:nether/find_fortress",
"minecraft:nether/get_wither_skull",
"minecraft:nether/loot_bastion",
"minecraft:nether/netherite_armor",
"minecraft:nether/obtain_ancient_debris",
"minecraft:nether/obtain_blaze_rod",
"minecraft:nether/obtain_crying_obsidian",
"minecraft:nether/return_to_sender",
"minecraft:nether/ride_strider",
"minecraft:nether/root",
"minecraft:nether/summon_wither",
"minecraft:nether/uneasy_alliance",
"minecraft:nether/use_lodestone",
"minecraft:story/cure_zombie_villager",
"minecraft:story/deflect_arrow",
"minecraft:story/enchant_item",
"minecraft:story/enter_the_end",
"minecraft:story/enter_the_nether",
"minecraft:story/follow_ender_eye",
"minecraft:story/form_obsidian",
"minecraft:story/iron_tools",
"minecraft:story/lava_bucket",
"minecraft:story/mine_diamond",
"minecraft:story/mine_stone",
"minecraft:story/obtain_armor",
"minecraft:story/root",
"minecraft:story/shiny_gear",
"minecraft:story/smelt_iron",
"minecraft:story/upgrade_tools"
]
for i, a in enumerate(advancements):
print("execute if entity @a[advancements={" + a + "=true}] run scoreboard players set #adv" + str(
i) + " globaladvance 1")
print("\n\n\n")
for i, a in enumerate(advancements):
print("execute if score #adv" + str(i) +
" globaladvance matches 1 run advancement grant @a only " + a)
| advancements = ['minecraft:adventure/adventuring_time', 'minecraft:adventure/arbalistic', 'minecraft:adventure/bullseye', 'minecraft:adventure/hero_of_the_village', 'minecraft:adventure/honey_block_slide', 'minecraft:adventure/kill_all_mobs', 'minecraft:adventure/kill_a_mob', 'minecraft:adventure/ol_betsy', 'minecraft:adventure/root', 'minecraft:adventure/shoot_arrow', 'minecraft:adventure/sleep_in_bed', 'minecraft:adventure/sniper_duel', 'minecraft:adventure/summon_iron_golem', 'minecraft:adventure/throw_trident', 'minecraft:adventure/totem_of_undying', 'minecraft:adventure/trade', 'minecraft:adventure/two_birds_one_arrow', 'minecraft:adventure/very_very_frightening', 'minecraft:adventure/voluntary_exile', 'minecraft:adventure/whos_the_pillager_now', 'minecraft:end/dragon_breath', 'minecraft:end/dragon_egg', 'minecraft:end/elytra', 'minecraft:end/enter_end_gateway', 'minecraft:end/find_end_city', 'minecraft:end/kill_dragon', 'minecraft:end/levitate', 'minecraft:end/respawn_dragon', 'minecraft:end/root', 'minecraft:husbandry/balanced_diet', 'minecraft:husbandry/bred_all_animals', 'minecraft:husbandry/breed_an_animal', 'minecraft:husbandry/complete_catalogue', 'minecraft:husbandry/fishy_business', 'minecraft:husbandry/obtain_netherite_hoe', 'minecraft:husbandry/plant_seed', 'minecraft:husbandry/root', 'minecraft:husbandry/safely_harvest_honey', 'minecraft:husbandry/silk_touch_nest', 'minecraft:husbandry/tactical_fishing', 'minecraft:husbandry/tame_an_animal', 'minecraft:nether/all_effects', 'minecraft:nether/all_potions', 'minecraft:nether/brew_potion', 'minecraft:nether/charge_respawn_anchor', 'minecraft:nether/create_beacon', 'minecraft:nether/create_full_beacon', 'minecraft:nether/distract_piglin', 'minecraft:nether/explore_nether', 'minecraft:nether/fast_travel', 'minecraft:nether/find_bastion', 'minecraft:nether/find_fortress', 'minecraft:nether/get_wither_skull', 'minecraft:nether/loot_bastion', 'minecraft:nether/netherite_armor', 'minecraft:nether/obtain_ancient_debris', 'minecraft:nether/obtain_blaze_rod', 'minecraft:nether/obtain_crying_obsidian', 'minecraft:nether/return_to_sender', 'minecraft:nether/ride_strider', 'minecraft:nether/root', 'minecraft:nether/summon_wither', 'minecraft:nether/uneasy_alliance', 'minecraft:nether/use_lodestone', 'minecraft:story/cure_zombie_villager', 'minecraft:story/deflect_arrow', 'minecraft:story/enchant_item', 'minecraft:story/enter_the_end', 'minecraft:story/enter_the_nether', 'minecraft:story/follow_ender_eye', 'minecraft:story/form_obsidian', 'minecraft:story/iron_tools', 'minecraft:story/lava_bucket', 'minecraft:story/mine_diamond', 'minecraft:story/mine_stone', 'minecraft:story/obtain_armor', 'minecraft:story/root', 'minecraft:story/shiny_gear', 'minecraft:story/smelt_iron', 'minecraft:story/upgrade_tools']
for (i, a) in enumerate(advancements):
print('execute if entity @a[advancements={' + a + '=true}] run scoreboard players set #adv' + str(i) + ' globaladvance 1')
print('\n\n\n')
for (i, a) in enumerate(advancements):
print('execute if score #adv' + str(i) + ' globaladvance matches 1 run advancement grant @a only ' + a) |
#
# PySNMP MIB module HOTWIRE-MSDSL-INTERFACE-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/HOTWIRE-MSDSL-INTERFACE-MIB
# Produced by pysmi-0.3.4 at Mon Apr 29 19:20:19 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)
#
ObjectIdentifier, Integer, OctetString = mibBuilder.importSymbols("ASN1", "ObjectIdentifier", "Integer", "OctetString")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
SingleValueConstraint, ConstraintsIntersection, ConstraintsUnion, ValueSizeConstraint, ValueRangeConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "SingleValueConstraint", "ConstraintsIntersection", "ConstraintsUnion", "ValueSizeConstraint", "ValueRangeConstraint")
ifIndex, = mibBuilder.importSymbols("IF-MIB", "ifIndex")
pdnmsdsl, = mibBuilder.importSymbols("PDN-HEADER-MIB", "pdnmsdsl")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
Gauge32, IpAddress, ObjectIdentity, NotificationType, NotificationType, Integer32, TimeTicks, iso, enterprises, Bits, Unsigned32, MibIdentifier, Counter32, MibScalar, MibTable, MibTableRow, MibTableColumn, Counter64, ModuleIdentity = mibBuilder.importSymbols("SNMPv2-SMI", "Gauge32", "IpAddress", "ObjectIdentity", "NotificationType", "NotificationType", "Integer32", "TimeTicks", "iso", "enterprises", "Bits", "Unsigned32", "MibIdentifier", "Counter32", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "Counter64", "ModuleIdentity")
TextualConvention, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TextualConvention", "DisplayString")
msdslDevice = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1))
msdslCurrent = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1))
msdslInterval = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2))
msdslWorstInterval = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3))
msdslTotal = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4))
msdslFarEndCurrent = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5))
msdslFarEndInterval = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6))
msdslFarEndWorstInterval = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7))
msdslFarEndTotal = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8))
msdslCurrentPerf = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9))
msdslIntervalPerf = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10))
msdslFarEndCurrentPerf = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11))
msdslFarEndIntervalPerf = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12))
msdsldsx1WorstInterval = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13))
msdslG703WorstInterval = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14))
msdslConfiguration = MibIdentifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15))
msdslCurrentTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1), )
if mibBuilder.loadTexts: msdslCurrentTable.setStatus('mandatory')
msdslCurrentEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslCurrentIfIndex"))
if mibBuilder.loadTexts: msdslCurrentEntry.setStatus('mandatory')
msdslCurrentIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentIfIndex.setStatus('mandatory')
msdslCurrentESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 2), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentESs.setStatus('mandatory')
msdslCurrentSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentSESs.setStatus('mandatory')
msdslCurrentFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentFEBEs.setStatus('mandatory')
msdslErrEventsCounter = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslErrEventsCounter.setStatus('mandatory')
msdslErrTimeElapsed = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 899))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslErrTimeElapsed.setStatus('mandatory')
msdslErrValidIntervals = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslErrValidIntervals.setStatus('mandatory')
msdslIntervalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2), )
if mibBuilder.loadTexts: msdslIntervalTable.setStatus('mandatory')
msdslIntervalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslIntervalIfIndex"), (0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslIntervalNumber"))
if mibBuilder.loadTexts: msdslIntervalEntry.setStatus('mandatory')
msdslIntervalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalIfIndex.setStatus('mandatory')
msdslIntervalNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalNumber.setStatus('mandatory')
msdslIntervalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalESs.setStatus('mandatory')
msdslIntervalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalSESs.setStatus('mandatory')
msdslIntervalFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 5), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalFEBEs.setStatus('mandatory')
msdslWorstIntervalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3), )
if mibBuilder.loadTexts: msdslWorstIntervalTable.setStatus('mandatory')
msdslWorstIntervalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslWorstIntervalIfIndex"))
if mibBuilder.loadTexts: msdslWorstIntervalEntry.setStatus('mandatory')
msdslWorstIntervalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslWorstIntervalIfIndex.setStatus('mandatory')
msdslWorstIntervalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslWorstIntervalESs.setStatus('mandatory')
msdslWorstIntervalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslWorstIntervalSESs.setStatus('mandatory')
msdslWorstIntervalFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslWorstIntervalFEBEs.setStatus('mandatory')
msdslTotalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4), )
if mibBuilder.loadTexts: msdslTotalTable.setStatus('mandatory')
msdslTotalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslTotalIfIndex"))
if mibBuilder.loadTexts: msdslTotalEntry.setStatus('mandatory')
msdslTotalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslTotalIfIndex.setStatus('mandatory')
msdslTotalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 2), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslTotalESs.setStatus('mandatory')
msdslTotalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslTotalSESs.setStatus('mandatory')
msdslTotalFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslTotalFEBEs.setStatus('mandatory')
msdslFarEndCurrentTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5), )
if mibBuilder.loadTexts: msdslFarEndCurrentTable.setStatus('mandatory')
msdslFarEndCurrentEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFarEndCurrentIfIndex"))
if mibBuilder.loadTexts: msdslFarEndCurrentEntry.setStatus('mandatory')
msdslFarEndCurrentIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentIfIndex.setStatus('mandatory')
msdslFarEndCurrentESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 2), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentESs.setStatus('mandatory')
msdslFarEndCurrentSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentSESs.setStatus('mandatory')
msdslFarEndCurrentFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentFEBEs.setStatus('mandatory')
msdslFarEndIntervalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6), )
if mibBuilder.loadTexts: msdslFarEndIntervalTable.setStatus('mandatory')
msdslFarEndIntervalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFarEndIntervalIfIndex"), (0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFarEndIntervalNumber"))
if mibBuilder.loadTexts: msdslFarEndIntervalEntry.setStatus('mandatory')
msdslFarEndIntervalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalIfIndex.setStatus('mandatory')
msdslFarEndIntervalNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalNumber.setStatus('mandatory')
msdslFarEndIntervalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalESs.setStatus('mandatory')
msdslFarEndIntervalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalSESs.setStatus('mandatory')
msdslFarEndIntervalFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 5), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalFEBEs.setStatus('mandatory')
msdslFarEndWorstIntervalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7), )
if mibBuilder.loadTexts: msdslFarEndWorstIntervalTable.setStatus('mandatory')
msdslFarEndWorstIntervalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFarEndWorstIntervalIfIndex"))
if mibBuilder.loadTexts: msdslFarEndWorstIntervalEntry.setStatus('mandatory')
msdslFarEndWorstIntervalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndWorstIntervalIfIndex.setStatus('mandatory')
msdslFarEndWorstIntervalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndWorstIntervalESs.setStatus('mandatory')
msdslFarEndWorstIntervalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndWorstIntervalSESs.setStatus('mandatory')
msdslFarEndWorstIntervalFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndWorstIntervalFEBEs.setStatus('mandatory')
msdslFarEndTotalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8), )
if mibBuilder.loadTexts: msdslFarEndTotalTable.setStatus('mandatory')
msdslFarEndTotalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslTotalIfIndex"))
if mibBuilder.loadTexts: msdslFarEndTotalEntry.setStatus('mandatory')
msdslFarEndTotalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndTotalIfIndex.setStatus('mandatory')
msdslFarEndTotalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 2), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndTotalESs.setStatus('mandatory')
msdslFarEndTotalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndTotalSESs.setStatus('mandatory')
msdslFarEndTotalFEBEs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndTotalFEBEs.setStatus('mandatory')
msdslCurrentPerfTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9), )
if mibBuilder.loadTexts: msdslCurrentPerfTable.setStatus('mandatory')
msdslCurrentPerfEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslCurrentPerfIfIndex"))
if mibBuilder.loadTexts: msdslCurrentPerfEntry.setStatus('mandatory')
msdslCurrentPerfIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentPerfIfIndex.setStatus('mandatory')
msdslCurrentPerfMargin = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 2), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentPerfMargin.setStatus('mandatory')
msdslCurrentPerfTxPwr = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentPerfTxPwr.setStatus('mandatory')
msdslCurrentPerfRxGain = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslCurrentPerfRxGain.setStatus('mandatory')
msdslPerfPayloadRate = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 5), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslPerfPayloadRate.setStatus('mandatory')
msdslTimeElapsed = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 899))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslTimeElapsed.setStatus('mandatory')
msdslValidIntervals = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslValidIntervals.setStatus('mandatory')
msdslIntervalPerfTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10), )
if mibBuilder.loadTexts: msdslIntervalPerfTable.setStatus('mandatory')
msdslIntervalPerfEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslIntervalPerfIfIndex"), (0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslIntervalPerfNumber"))
if mibBuilder.loadTexts: msdslIntervalPerfEntry.setStatus('mandatory')
msdslIntervalPerfIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalPerfIfIndex.setStatus('mandatory')
msdslIntervalPerfNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalPerfNumber.setStatus('mandatory')
msdslIntervalPerfMargin = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalPerfMargin.setStatus('mandatory')
msdslIntervalPerfTxPwr = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalPerfTxPwr.setStatus('mandatory')
msdslIntervalPerfRxGain = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 5), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslIntervalPerfRxGain.setStatus('mandatory')
msdslFarEndCurrentPerfTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11), )
if mibBuilder.loadTexts: msdslFarEndCurrentPerfTable.setStatus('mandatory')
msdslFarEndCurrentPerfEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFarEndCurrentPerfIfIndex"))
if mibBuilder.loadTexts: msdslFarEndCurrentPerfEntry.setStatus('mandatory')
msdslFarEndCurrentPerfIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentPerfIfIndex.setStatus('mandatory')
msdslFarEndCurrentPerfMargin = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 2), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentPerfMargin.setStatus('mandatory')
msdslFarEndCurrentPerfTxPwr = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentPerfTxPwr.setStatus('mandatory')
msdslFarEndCurrentPerfRxGain = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndCurrentPerfRxGain.setStatus('mandatory')
msdslFarEndIntervalPerfTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12), )
if mibBuilder.loadTexts: msdslFarEndIntervalPerfTable.setStatus('mandatory')
msdslFarEndIntervalPerfEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFarEndIntervalPerfIfIndex"), (0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFarEndIntervalPerfNumber"))
if mibBuilder.loadTexts: msdslFarEndIntervalPerfEntry.setStatus('mandatory')
msdslFarEndIntervalPerfIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalPerfIfIndex.setStatus('mandatory')
msdslFarEndIntervalPerfNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 96))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalPerfNumber.setStatus('mandatory')
msdslFarEndIntervalPerfMargin = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 3), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalPerfMargin.setStatus('mandatory')
msdslFarEndIntervalPerfTxPwr = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 4), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalPerfTxPwr.setStatus('mandatory')
msdslFarEndIntervalPerfRxGain = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 5), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFarEndIntervalPerfRxGain.setStatus('mandatory')
msdsldsx1WorstIntervalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13), )
if mibBuilder.loadTexts: msdsldsx1WorstIntervalTable.setStatus('mandatory')
msdsldsx1WorstIntervalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdsldsx1WorstIntervalIfIndex"))
if mibBuilder.loadTexts: msdsldsx1WorstIntervalEntry.setStatus('mandatory')
msdsldsx1WorstIntervalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdsldsx1WorstIntervalIfIndex.setStatus('mandatory')
msdsldsx1WorstIntervalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdsldsx1WorstIntervalESs.setStatus('mandatory')
msdsldsx1WorstIntervalUASs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdsldsx1WorstIntervalUASs.setStatus('mandatory')
msdsldsx1WorstIntervalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdsldsx1WorstIntervalSESs.setStatus('mandatory')
msdsldsx1WorstIntervalBESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdsldsx1WorstIntervalBESs.setStatus('mandatory')
msdsldsx1WorstIntervalCSSs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdsldsx1WorstIntervalCSSs.setStatus('mandatory')
msdsldsx1WorstIntervalLOFC = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 7), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdsldsx1WorstIntervalLOFC.setStatus('mandatory')
msdslG703WorstIntervalTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14), )
if mibBuilder.loadTexts: msdslG703WorstIntervalTable.setStatus('mandatory')
msdslG703WorstIntervalEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslG703WorstIntervalIfIndex"))
if mibBuilder.loadTexts: msdslG703WorstIntervalEntry.setStatus('mandatory')
msdslG703WorstIntervalIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslG703WorstIntervalIfIndex.setStatus('mandatory')
msdslG703WorstIntervalESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslG703WorstIntervalESs.setStatus('mandatory')
msdslG703WorstIntervalUASs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslG703WorstIntervalUASs.setStatus('mandatory')
msdslG703WorstIntervalSESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslG703WorstIntervalSESs.setStatus('mandatory')
msdslG703WorstIntervalBESs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslG703WorstIntervalBESs.setStatus('mandatory')
msdslG703WorstIntervalCSSs = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslG703WorstIntervalCSSs.setStatus('mandatory')
msdslG703WorstIntervalLOFC = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 7), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslG703WorstIntervalLOFC.setStatus('mandatory')
msdslFracTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28), )
if mibBuilder.loadTexts: msdslFracTable.setStatus('mandatory')
msdslFracEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFracPortIndex"), (0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslFracPortTS"))
if mibBuilder.loadTexts: msdslFracEntry.setStatus('mandatory')
msdslFracPortIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslFracPortIndex.setStatus('mandatory')
msdslFracPortTS = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 31))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: msdslFracPortTS.setStatus('mandatory')
msdslFracPortIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 3), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: msdslFracPortIfIndex.setStatus('mandatory')
msdslFracPortIfTS = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 32))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: msdslFracPortIfTS.setStatus('mandatory')
msdslFracPortVoiceData = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("voice", 1), ("data", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: msdslFracPortVoiceData.setStatus('mandatory')
msdslPortConfigAllocMethodTable = MibTable((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29), )
if mibBuilder.loadTexts: msdslPortConfigAllocMethodTable.setStatus('mandatory')
msdslPortConfigAllocMethodEntry = MibTableRow((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29, 1), ).setIndexNames((0, "HOTWIRE-MSDSL-INTERFACE-MIB", "msdslPortConfigAllocMethodIfIndex"))
if mibBuilder.loadTexts: msdslPortConfigAllocMethodEntry.setStatus('mandatory')
msdslPortConfigAllocMethodIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: msdslPortConfigAllocMethodIfIndex.setStatus('mandatory')
msdslPortConfigAllocMethod = MibTableColumn((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5))).clone(namedValues=NamedValues(("ds1ByPass", 1), ("ds1CrossConn", 2), ("ds0CrossConn", 3), ("notAssigned", 4), ("disabled", 5)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: msdslPortConfigAllocMethod.setStatus('mandatory')
msdslMarginLow = NotificationType((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0,3)).setObjects(("IF-MIB", "ifIndex"))
msdslMarginNormal = NotificationType((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0,103)).setObjects(("IF-MIB", "ifIndex"))
msdslErrorRateHigh = NotificationType((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0,4)).setObjects(("IF-MIB", "ifIndex"))
msdslErrorRateNormal = NotificationType((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0,104)).setObjects(("IF-MIB", "ifIndex"))
msdslTestOver = NotificationType((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0,106)).setObjects(("IF-MIB", "ifIndex"))
msdslNTUTypeMismatch = NotificationType((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0,7)).setObjects(("IF-MIB", "ifIndex"))
mibBuilder.exportSymbols("HOTWIRE-MSDSL-INTERFACE-MIB", msdsldsx1WorstIntervalUASs=msdsldsx1WorstIntervalUASs, msdslFarEndTotalFEBEs=msdslFarEndTotalFEBEs, msdslFarEndCurrentPerfTxPwr=msdslFarEndCurrentPerfTxPwr, msdslFarEndWorstIntervalEntry=msdslFarEndWorstIntervalEntry, msdslPortConfigAllocMethodIfIndex=msdslPortConfigAllocMethodIfIndex, msdslNTUTypeMismatch=msdslNTUTypeMismatch, msdslPortConfigAllocMethod=msdslPortConfigAllocMethod, msdslWorstIntervalEntry=msdslWorstIntervalEntry, msdslFarEndIntervalPerfNumber=msdslFarEndIntervalPerfNumber, msdslFarEndCurrentPerfEntry=msdslFarEndCurrentPerfEntry, msdslFarEndWorstIntervalSESs=msdslFarEndWorstIntervalSESs, msdslPortConfigAllocMethodEntry=msdslPortConfigAllocMethodEntry, msdslG703WorstIntervalCSSs=msdslG703WorstIntervalCSSs, msdslFarEndIntervalEntry=msdslFarEndIntervalEntry, msdslIntervalPerfRxGain=msdslIntervalPerfRxGain, msdslFarEndCurrentSESs=msdslFarEndCurrentSESs, msdslMarginNormal=msdslMarginNormal, msdslFarEndIntervalPerf=msdslFarEndIntervalPerf, msdslIntervalPerfTxPwr=msdslIntervalPerfTxPwr, msdslFarEndCurrentEntry=msdslFarEndCurrentEntry, msdslG703WorstIntervalIfIndex=msdslG703WorstIntervalIfIndex, msdslFarEndCurrent=msdslFarEndCurrent, msdslTotal=msdslTotal, msdslFarEndIntervalPerfTxPwr=msdslFarEndIntervalPerfTxPwr, msdsldsx1WorstIntervalCSSs=msdsldsx1WorstIntervalCSSs, msdslG703WorstIntervalTable=msdslG703WorstIntervalTable, msdslFarEndTotalSESs=msdslFarEndTotalSESs, msdslTotalESs=msdslTotalESs, msdslWorstIntervalSESs=msdslWorstIntervalSESs, msdslIntervalSESs=msdslIntervalSESs, msdslFarEndWorstInterval=msdslFarEndWorstInterval, msdslFarEndTotalTable=msdslFarEndTotalTable, msdslG703WorstIntervalBESs=msdslG703WorstIntervalBESs, msdslFarEndCurrentPerfIfIndex=msdslFarEndCurrentPerfIfIndex, msdslCurrentPerf=msdslCurrentPerf, msdslCurrentPerfTxPwr=msdslCurrentPerfTxPwr, msdsldsx1WorstIntervalLOFC=msdsldsx1WorstIntervalLOFC, msdslConfiguration=msdslConfiguration, msdslFarEndTotal=msdslFarEndTotal, msdslFarEndCurrentFEBEs=msdslFarEndCurrentFEBEs, msdslTimeElapsed=msdslTimeElapsed, msdslFarEndInterval=msdslFarEndInterval, msdslIntervalPerfEntry=msdslIntervalPerfEntry, msdslCurrentPerfMargin=msdslCurrentPerfMargin, msdslG703WorstIntervalUASs=msdslG703WorstIntervalUASs, msdslCurrentPerfRxGain=msdslCurrentPerfRxGain, msdslFarEndIntervalPerfMargin=msdslFarEndIntervalPerfMargin, msdslFarEndIntervalNumber=msdslFarEndIntervalNumber, msdslIntervalEntry=msdslIntervalEntry, msdslFarEndTotalESs=msdslFarEndTotalESs, msdslFarEndWorstIntervalFEBEs=msdslFarEndWorstIntervalFEBEs, msdslFarEndIntervalTable=msdslFarEndIntervalTable, msdslIntervalPerf=msdslIntervalPerf, msdslFracPortIndex=msdslFracPortIndex, msdslTestOver=msdslTestOver, msdslFracPortVoiceData=msdslFracPortVoiceData, msdslFarEndCurrentPerfMargin=msdslFarEndCurrentPerfMargin, msdslFarEndIntervalPerfIfIndex=msdslFarEndIntervalPerfIfIndex, msdslFarEndIntervalPerfTable=msdslFarEndIntervalPerfTable, msdslFracTable=msdslFracTable, msdslIntervalFEBEs=msdslIntervalFEBEs, msdsldsx1WorstIntervalEntry=msdsldsx1WorstIntervalEntry, msdslCurrentTable=msdslCurrentTable, msdsldsx1WorstIntervalESs=msdsldsx1WorstIntervalESs, msdslFarEndCurrentPerf=msdslFarEndCurrentPerf, msdsldsx1WorstIntervalIfIndex=msdsldsx1WorstIntervalIfIndex, msdslWorstInterval=msdslWorstInterval, msdslFarEndIntervalPerfRxGain=msdslFarEndIntervalPerfRxGain, msdslTotalEntry=msdslTotalEntry, msdslFarEndWorstIntervalTable=msdslFarEndWorstIntervalTable, msdslFarEndWorstIntervalESs=msdslFarEndWorstIntervalESs, msdslG703WorstIntervalLOFC=msdslG703WorstIntervalLOFC, msdslCurrentESs=msdslCurrentESs, msdslFarEndTotalIfIndex=msdslFarEndTotalIfIndex, msdslFracPortTS=msdslFracPortTS, msdslFarEndIntervalPerfEntry=msdslFarEndIntervalPerfEntry, msdslFarEndCurrentIfIndex=msdslFarEndCurrentIfIndex, msdslErrEventsCounter=msdslErrEventsCounter, msdslFarEndTotalEntry=msdslFarEndTotalEntry, msdslTotalTable=msdslTotalTable, msdslErrValidIntervals=msdslErrValidIntervals, msdslFracPortIfTS=msdslFracPortIfTS, msdslCurrentPerfIfIndex=msdslCurrentPerfIfIndex, msdslTotalFEBEs=msdslTotalFEBEs, msdslDevice=msdslDevice, msdslFarEndIntervalESs=msdslFarEndIntervalESs, msdslIntervalPerfTable=msdslIntervalPerfTable, msdslG703WorstInterval=msdslG703WorstInterval, msdslFarEndCurrentPerfTable=msdslFarEndCurrentPerfTable, msdslMarginLow=msdslMarginLow, msdslIntervalPerfIfIndex=msdslIntervalPerfIfIndex, msdslIntervalIfIndex=msdslIntervalIfIndex, msdslIntervalESs=msdslIntervalESs, msdslFarEndCurrentPerfRxGain=msdslFarEndCurrentPerfRxGain, msdslErrorRateNormal=msdslErrorRateNormal, msdslIntervalNumber=msdslIntervalNumber, msdslIntervalPerfMargin=msdslIntervalPerfMargin, msdslIntervalTable=msdslIntervalTable, msdslFracEntry=msdslFracEntry, msdslPerfPayloadRate=msdslPerfPayloadRate, msdslFarEndIntervalIfIndex=msdslFarEndIntervalIfIndex, msdslFarEndWorstIntervalIfIndex=msdslFarEndWorstIntervalIfIndex, msdslFarEndCurrentTable=msdslFarEndCurrentTable, msdslWorstIntervalESs=msdslWorstIntervalESs, msdslCurrentSESs=msdslCurrentSESs, msdsldsx1WorstIntervalBESs=msdsldsx1WorstIntervalBESs, msdslErrorRateHigh=msdslErrorRateHigh, msdslWorstIntervalTable=msdslWorstIntervalTable, msdslTotalSESs=msdslTotalSESs, msdslCurrentPerfEntry=msdslCurrentPerfEntry, msdslG703WorstIntervalSESs=msdslG703WorstIntervalSESs, msdslFarEndIntervalSESs=msdslFarEndIntervalSESs, msdslInterval=msdslInterval, msdslCurrentFEBEs=msdslCurrentFEBEs, msdslG703WorstIntervalEntry=msdslG703WorstIntervalEntry, msdslCurrent=msdslCurrent, msdslTotalIfIndex=msdslTotalIfIndex, msdslIntervalPerfNumber=msdslIntervalPerfNumber, msdslG703WorstIntervalESs=msdslG703WorstIntervalESs, msdsldsx1WorstIntervalSESs=msdsldsx1WorstIntervalSESs, msdslCurrentIfIndex=msdslCurrentIfIndex, msdslErrTimeElapsed=msdslErrTimeElapsed, msdsldsx1WorstInterval=msdsldsx1WorstInterval, msdsldsx1WorstIntervalTable=msdsldsx1WorstIntervalTable, msdslPortConfigAllocMethodTable=msdslPortConfigAllocMethodTable, msdslFarEndIntervalFEBEs=msdslFarEndIntervalFEBEs, msdslCurrentEntry=msdslCurrentEntry, msdslWorstIntervalIfIndex=msdslWorstIntervalIfIndex, msdslValidIntervals=msdslValidIntervals, msdslCurrentPerfTable=msdslCurrentPerfTable, msdslFarEndCurrentESs=msdslFarEndCurrentESs, msdslWorstIntervalFEBEs=msdslWorstIntervalFEBEs, msdslFracPortIfIndex=msdslFracPortIfIndex)
| (object_identifier, integer, octet_string) = mibBuilder.importSymbols('ASN1', 'ObjectIdentifier', 'Integer', 'OctetString')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(single_value_constraint, constraints_intersection, constraints_union, value_size_constraint, value_range_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'SingleValueConstraint', 'ConstraintsIntersection', 'ConstraintsUnion', 'ValueSizeConstraint', 'ValueRangeConstraint')
(if_index,) = mibBuilder.importSymbols('IF-MIB', 'ifIndex')
(pdnmsdsl,) = mibBuilder.importSymbols('PDN-HEADER-MIB', 'pdnmsdsl')
(notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance')
(gauge32, ip_address, object_identity, notification_type, notification_type, integer32, time_ticks, iso, enterprises, bits, unsigned32, mib_identifier, counter32, mib_scalar, mib_table, mib_table_row, mib_table_column, counter64, module_identity) = mibBuilder.importSymbols('SNMPv2-SMI', 'Gauge32', 'IpAddress', 'ObjectIdentity', 'NotificationType', 'NotificationType', 'Integer32', 'TimeTicks', 'iso', 'enterprises', 'Bits', 'Unsigned32', 'MibIdentifier', 'Counter32', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'Counter64', 'ModuleIdentity')
(textual_convention, display_string) = mibBuilder.importSymbols('SNMPv2-TC', 'TextualConvention', 'DisplayString')
msdsl_device = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1))
msdsl_current = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1))
msdsl_interval = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2))
msdsl_worst_interval = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3))
msdsl_total = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4))
msdsl_far_end_current = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5))
msdsl_far_end_interval = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6))
msdsl_far_end_worst_interval = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7))
msdsl_far_end_total = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8))
msdsl_current_perf = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9))
msdsl_interval_perf = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10))
msdsl_far_end_current_perf = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11))
msdsl_far_end_interval_perf = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12))
msdsldsx1_worst_interval = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13))
msdsl_g703_worst_interval = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14))
msdsl_configuration = mib_identifier((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15))
msdsl_current_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1))
if mibBuilder.loadTexts:
msdslCurrentTable.setStatus('mandatory')
msdsl_current_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslCurrentIfIndex'))
if mibBuilder.loadTexts:
msdslCurrentEntry.setStatus('mandatory')
msdsl_current_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentIfIndex.setStatus('mandatory')
msdsl_current_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 2), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentESs.setStatus('mandatory')
msdsl_current_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentSESs.setStatus('mandatory')
msdsl_current_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentFEBEs.setStatus('mandatory')
msdsl_err_events_counter = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(0, 65535))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslErrEventsCounter.setStatus('mandatory')
msdsl_err_time_elapsed = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(0, 899))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslErrTimeElapsed.setStatus('mandatory')
msdsl_err_valid_intervals = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 1, 1, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslErrValidIntervals.setStatus('mandatory')
msdsl_interval_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2))
if mibBuilder.loadTexts:
msdslIntervalTable.setStatus('mandatory')
msdsl_interval_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslIntervalIfIndex'), (0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslIntervalNumber'))
if mibBuilder.loadTexts:
msdslIntervalEntry.setStatus('mandatory')
msdsl_interval_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalIfIndex.setStatus('mandatory')
msdsl_interval_number = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalNumber.setStatus('mandatory')
msdsl_interval_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalESs.setStatus('mandatory')
msdsl_interval_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalSESs.setStatus('mandatory')
msdsl_interval_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 2, 2, 1, 5), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalFEBEs.setStatus('mandatory')
msdsl_worst_interval_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3))
if mibBuilder.loadTexts:
msdslWorstIntervalTable.setStatus('mandatory')
msdsl_worst_interval_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslWorstIntervalIfIndex'))
if mibBuilder.loadTexts:
msdslWorstIntervalEntry.setStatus('mandatory')
msdsl_worst_interval_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslWorstIntervalIfIndex.setStatus('mandatory')
msdsl_worst_interval_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslWorstIntervalESs.setStatus('mandatory')
msdsl_worst_interval_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslWorstIntervalSESs.setStatus('mandatory')
msdsl_worst_interval_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 3, 3, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslWorstIntervalFEBEs.setStatus('mandatory')
msdsl_total_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4))
if mibBuilder.loadTexts:
msdslTotalTable.setStatus('mandatory')
msdsl_total_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslTotalIfIndex'))
if mibBuilder.loadTexts:
msdslTotalEntry.setStatus('mandatory')
msdsl_total_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslTotalIfIndex.setStatus('mandatory')
msdsl_total_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 2), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslTotalESs.setStatus('mandatory')
msdsl_total_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslTotalSESs.setStatus('mandatory')
msdsl_total_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 4, 4, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslTotalFEBEs.setStatus('mandatory')
msdsl_far_end_current_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5))
if mibBuilder.loadTexts:
msdslFarEndCurrentTable.setStatus('mandatory')
msdsl_far_end_current_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFarEndCurrentIfIndex'))
if mibBuilder.loadTexts:
msdslFarEndCurrentEntry.setStatus('mandatory')
msdsl_far_end_current_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentIfIndex.setStatus('mandatory')
msdsl_far_end_current_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 2), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentESs.setStatus('mandatory')
msdsl_far_end_current_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentSESs.setStatus('mandatory')
msdsl_far_end_current_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 5, 5, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentFEBEs.setStatus('mandatory')
msdsl_far_end_interval_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6))
if mibBuilder.loadTexts:
msdslFarEndIntervalTable.setStatus('mandatory')
msdsl_far_end_interval_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFarEndIntervalIfIndex'), (0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFarEndIntervalNumber'))
if mibBuilder.loadTexts:
msdslFarEndIntervalEntry.setStatus('mandatory')
msdsl_far_end_interval_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalIfIndex.setStatus('mandatory')
msdsl_far_end_interval_number = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalNumber.setStatus('mandatory')
msdsl_far_end_interval_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalESs.setStatus('mandatory')
msdsl_far_end_interval_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalSESs.setStatus('mandatory')
msdsl_far_end_interval_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 6, 6, 1, 5), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalFEBEs.setStatus('mandatory')
msdsl_far_end_worst_interval_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7))
if mibBuilder.loadTexts:
msdslFarEndWorstIntervalTable.setStatus('mandatory')
msdsl_far_end_worst_interval_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFarEndWorstIntervalIfIndex'))
if mibBuilder.loadTexts:
msdslFarEndWorstIntervalEntry.setStatus('mandatory')
msdsl_far_end_worst_interval_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndWorstIntervalIfIndex.setStatus('mandatory')
msdsl_far_end_worst_interval_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndWorstIntervalESs.setStatus('mandatory')
msdsl_far_end_worst_interval_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndWorstIntervalSESs.setStatus('mandatory')
msdsl_far_end_worst_interval_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 7, 7, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndWorstIntervalFEBEs.setStatus('mandatory')
msdsl_far_end_total_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8))
if mibBuilder.loadTexts:
msdslFarEndTotalTable.setStatus('mandatory')
msdsl_far_end_total_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslTotalIfIndex'))
if mibBuilder.loadTexts:
msdslFarEndTotalEntry.setStatus('mandatory')
msdsl_far_end_total_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndTotalIfIndex.setStatus('mandatory')
msdsl_far_end_total_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 2), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndTotalESs.setStatus('mandatory')
msdsl_far_end_total_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndTotalSESs.setStatus('mandatory')
msdsl_far_end_total_feb_es = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 8, 8, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndTotalFEBEs.setStatus('mandatory')
msdsl_current_perf_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9))
if mibBuilder.loadTexts:
msdslCurrentPerfTable.setStatus('mandatory')
msdsl_current_perf_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslCurrentPerfIfIndex'))
if mibBuilder.loadTexts:
msdslCurrentPerfEntry.setStatus('mandatory')
msdsl_current_perf_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentPerfIfIndex.setStatus('mandatory')
msdsl_current_perf_margin = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 2), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentPerfMargin.setStatus('mandatory')
msdsl_current_perf_tx_pwr = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentPerfTxPwr.setStatus('mandatory')
msdsl_current_perf_rx_gain = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslCurrentPerfRxGain.setStatus('mandatory')
msdsl_perf_payload_rate = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 5), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslPerfPayloadRate.setStatus('mandatory')
msdsl_time_elapsed = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(0, 899))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslTimeElapsed.setStatus('mandatory')
msdsl_valid_intervals = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 9, 9, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslValidIntervals.setStatus('mandatory')
msdsl_interval_perf_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10))
if mibBuilder.loadTexts:
msdslIntervalPerfTable.setStatus('mandatory')
msdsl_interval_perf_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslIntervalPerfIfIndex'), (0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslIntervalPerfNumber'))
if mibBuilder.loadTexts:
msdslIntervalPerfEntry.setStatus('mandatory')
msdsl_interval_perf_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalPerfIfIndex.setStatus('mandatory')
msdsl_interval_perf_number = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalPerfNumber.setStatus('mandatory')
msdsl_interval_perf_margin = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalPerfMargin.setStatus('mandatory')
msdsl_interval_perf_tx_pwr = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalPerfTxPwr.setStatus('mandatory')
msdsl_interval_perf_rx_gain = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 10, 10, 1, 5), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslIntervalPerfRxGain.setStatus('mandatory')
msdsl_far_end_current_perf_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11))
if mibBuilder.loadTexts:
msdslFarEndCurrentPerfTable.setStatus('mandatory')
msdsl_far_end_current_perf_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFarEndCurrentPerfIfIndex'))
if mibBuilder.loadTexts:
msdslFarEndCurrentPerfEntry.setStatus('mandatory')
msdsl_far_end_current_perf_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentPerfIfIndex.setStatus('mandatory')
msdsl_far_end_current_perf_margin = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 2), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentPerfMargin.setStatus('mandatory')
msdsl_far_end_current_perf_tx_pwr = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentPerfTxPwr.setStatus('mandatory')
msdsl_far_end_current_perf_rx_gain = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 11, 11, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndCurrentPerfRxGain.setStatus('mandatory')
msdsl_far_end_interval_perf_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12))
if mibBuilder.loadTexts:
msdslFarEndIntervalPerfTable.setStatus('mandatory')
msdsl_far_end_interval_perf_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFarEndIntervalPerfIfIndex'), (0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFarEndIntervalPerfNumber'))
if mibBuilder.loadTexts:
msdslFarEndIntervalPerfEntry.setStatus('mandatory')
msdsl_far_end_interval_perf_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalPerfIfIndex.setStatus('mandatory')
msdsl_far_end_interval_perf_number = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 96))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalPerfNumber.setStatus('mandatory')
msdsl_far_end_interval_perf_margin = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 3), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalPerfMargin.setStatus('mandatory')
msdsl_far_end_interval_perf_tx_pwr = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 4), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalPerfTxPwr.setStatus('mandatory')
msdsl_far_end_interval_perf_rx_gain = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 12, 12, 1, 5), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFarEndIntervalPerfRxGain.setStatus('mandatory')
msdsldsx1_worst_interval_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13))
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalTable.setStatus('mandatory')
msdsldsx1_worst_interval_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdsldsx1WorstIntervalIfIndex'))
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalEntry.setStatus('mandatory')
msdsldsx1_worst_interval_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalIfIndex.setStatus('mandatory')
msdsldsx1_worst_interval_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalESs.setStatus('mandatory')
msdsldsx1_worst_interval_ua_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalUASs.setStatus('mandatory')
msdsldsx1_worst_interval_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalSESs.setStatus('mandatory')
msdsldsx1_worst_interval_be_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalBESs.setStatus('mandatory')
msdsldsx1_worst_interval_cs_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 6), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalCSSs.setStatus('mandatory')
msdsldsx1_worst_interval_lofc = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 13, 13, 1, 7), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdsldsx1WorstIntervalLOFC.setStatus('mandatory')
msdsl_g703_worst_interval_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14))
if mibBuilder.loadTexts:
msdslG703WorstIntervalTable.setStatus('mandatory')
msdsl_g703_worst_interval_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslG703WorstIntervalIfIndex'))
if mibBuilder.loadTexts:
msdslG703WorstIntervalEntry.setStatus('mandatory')
msdsl_g703_worst_interval_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslG703WorstIntervalIfIndex.setStatus('mandatory')
msdsl_g703_worst_interval_e_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslG703WorstIntervalESs.setStatus('mandatory')
msdsl_g703_worst_interval_ua_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslG703WorstIntervalUASs.setStatus('mandatory')
msdsl_g703_worst_interval_se_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslG703WorstIntervalSESs.setStatus('mandatory')
msdsl_g703_worst_interval_be_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslG703WorstIntervalBESs.setStatus('mandatory')
msdsl_g703_worst_interval_cs_ss = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 6), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslG703WorstIntervalCSSs.setStatus('mandatory')
msdsl_g703_worst_interval_lofc = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 14, 14, 1, 7), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslG703WorstIntervalLOFC.setStatus('mandatory')
msdsl_frac_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28))
if mibBuilder.loadTexts:
msdslFracTable.setStatus('mandatory')
msdsl_frac_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFracPortIndex'), (0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslFracPortTS'))
if mibBuilder.loadTexts:
msdslFracEntry.setStatus('mandatory')
msdsl_frac_port_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslFracPortIndex.setStatus('mandatory')
msdsl_frac_port_ts = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 31))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
msdslFracPortTS.setStatus('mandatory')
msdsl_frac_port_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 3), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
msdslFracPortIfIndex.setStatus('mandatory')
msdsl_frac_port_if_ts = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(1, 32))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
msdslFracPortIfTS.setStatus('mandatory')
msdsl_frac_port_voice_data = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 28, 1, 5), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('voice', 1), ('data', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
msdslFracPortVoiceData.setStatus('mandatory')
msdsl_port_config_alloc_method_table = mib_table((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29))
if mibBuilder.loadTexts:
msdslPortConfigAllocMethodTable.setStatus('mandatory')
msdsl_port_config_alloc_method_entry = mib_table_row((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29, 1)).setIndexNames((0, 'HOTWIRE-MSDSL-INTERFACE-MIB', 'msdslPortConfigAllocMethodIfIndex'))
if mibBuilder.loadTexts:
msdslPortConfigAllocMethodEntry.setStatus('mandatory')
msdsl_port_config_alloc_method_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
msdslPortConfigAllocMethodIfIndex.setStatus('mandatory')
msdsl_port_config_alloc_method = mib_table_column((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1, 15, 29, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5))).clone(namedValues=named_values(('ds1ByPass', 1), ('ds1CrossConn', 2), ('ds0CrossConn', 3), ('notAssigned', 4), ('disabled', 5)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
msdslPortConfigAllocMethod.setStatus('mandatory')
msdsl_margin_low = notification_type((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0, 3)).setObjects(('IF-MIB', 'ifIndex'))
msdsl_margin_normal = notification_type((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0, 103)).setObjects(('IF-MIB', 'ifIndex'))
msdsl_error_rate_high = notification_type((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0, 4)).setObjects(('IF-MIB', 'ifIndex'))
msdsl_error_rate_normal = notification_type((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0, 104)).setObjects(('IF-MIB', 'ifIndex'))
msdsl_test_over = notification_type((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0, 106)).setObjects(('IF-MIB', 'ifIndex'))
msdsl_ntu_type_mismatch = notification_type((1, 3, 6, 1, 4, 1, 1795, 2, 24, 2, 6, 15, 1) + (0, 7)).setObjects(('IF-MIB', 'ifIndex'))
mibBuilder.exportSymbols('HOTWIRE-MSDSL-INTERFACE-MIB', msdsldsx1WorstIntervalUASs=msdsldsx1WorstIntervalUASs, msdslFarEndTotalFEBEs=msdslFarEndTotalFEBEs, msdslFarEndCurrentPerfTxPwr=msdslFarEndCurrentPerfTxPwr, msdslFarEndWorstIntervalEntry=msdslFarEndWorstIntervalEntry, msdslPortConfigAllocMethodIfIndex=msdslPortConfigAllocMethodIfIndex, msdslNTUTypeMismatch=msdslNTUTypeMismatch, msdslPortConfigAllocMethod=msdslPortConfigAllocMethod, msdslWorstIntervalEntry=msdslWorstIntervalEntry, msdslFarEndIntervalPerfNumber=msdslFarEndIntervalPerfNumber, msdslFarEndCurrentPerfEntry=msdslFarEndCurrentPerfEntry, msdslFarEndWorstIntervalSESs=msdslFarEndWorstIntervalSESs, msdslPortConfigAllocMethodEntry=msdslPortConfigAllocMethodEntry, msdslG703WorstIntervalCSSs=msdslG703WorstIntervalCSSs, msdslFarEndIntervalEntry=msdslFarEndIntervalEntry, msdslIntervalPerfRxGain=msdslIntervalPerfRxGain, msdslFarEndCurrentSESs=msdslFarEndCurrentSESs, msdslMarginNormal=msdslMarginNormal, msdslFarEndIntervalPerf=msdslFarEndIntervalPerf, msdslIntervalPerfTxPwr=msdslIntervalPerfTxPwr, msdslFarEndCurrentEntry=msdslFarEndCurrentEntry, msdslG703WorstIntervalIfIndex=msdslG703WorstIntervalIfIndex, msdslFarEndCurrent=msdslFarEndCurrent, msdslTotal=msdslTotal, msdslFarEndIntervalPerfTxPwr=msdslFarEndIntervalPerfTxPwr, msdsldsx1WorstIntervalCSSs=msdsldsx1WorstIntervalCSSs, msdslG703WorstIntervalTable=msdslG703WorstIntervalTable, msdslFarEndTotalSESs=msdslFarEndTotalSESs, msdslTotalESs=msdslTotalESs, msdslWorstIntervalSESs=msdslWorstIntervalSESs, msdslIntervalSESs=msdslIntervalSESs, msdslFarEndWorstInterval=msdslFarEndWorstInterval, msdslFarEndTotalTable=msdslFarEndTotalTable, msdslG703WorstIntervalBESs=msdslG703WorstIntervalBESs, msdslFarEndCurrentPerfIfIndex=msdslFarEndCurrentPerfIfIndex, msdslCurrentPerf=msdslCurrentPerf, msdslCurrentPerfTxPwr=msdslCurrentPerfTxPwr, msdsldsx1WorstIntervalLOFC=msdsldsx1WorstIntervalLOFC, msdslConfiguration=msdslConfiguration, msdslFarEndTotal=msdslFarEndTotal, msdslFarEndCurrentFEBEs=msdslFarEndCurrentFEBEs, msdslTimeElapsed=msdslTimeElapsed, msdslFarEndInterval=msdslFarEndInterval, msdslIntervalPerfEntry=msdslIntervalPerfEntry, msdslCurrentPerfMargin=msdslCurrentPerfMargin, msdslG703WorstIntervalUASs=msdslG703WorstIntervalUASs, msdslCurrentPerfRxGain=msdslCurrentPerfRxGain, msdslFarEndIntervalPerfMargin=msdslFarEndIntervalPerfMargin, msdslFarEndIntervalNumber=msdslFarEndIntervalNumber, msdslIntervalEntry=msdslIntervalEntry, msdslFarEndTotalESs=msdslFarEndTotalESs, msdslFarEndWorstIntervalFEBEs=msdslFarEndWorstIntervalFEBEs, msdslFarEndIntervalTable=msdslFarEndIntervalTable, msdslIntervalPerf=msdslIntervalPerf, msdslFracPortIndex=msdslFracPortIndex, msdslTestOver=msdslTestOver, msdslFracPortVoiceData=msdslFracPortVoiceData, msdslFarEndCurrentPerfMargin=msdslFarEndCurrentPerfMargin, msdslFarEndIntervalPerfIfIndex=msdslFarEndIntervalPerfIfIndex, msdslFarEndIntervalPerfTable=msdslFarEndIntervalPerfTable, msdslFracTable=msdslFracTable, msdslIntervalFEBEs=msdslIntervalFEBEs, msdsldsx1WorstIntervalEntry=msdsldsx1WorstIntervalEntry, msdslCurrentTable=msdslCurrentTable, msdsldsx1WorstIntervalESs=msdsldsx1WorstIntervalESs, msdslFarEndCurrentPerf=msdslFarEndCurrentPerf, msdsldsx1WorstIntervalIfIndex=msdsldsx1WorstIntervalIfIndex, msdslWorstInterval=msdslWorstInterval, msdslFarEndIntervalPerfRxGain=msdslFarEndIntervalPerfRxGain, msdslTotalEntry=msdslTotalEntry, msdslFarEndWorstIntervalTable=msdslFarEndWorstIntervalTable, msdslFarEndWorstIntervalESs=msdslFarEndWorstIntervalESs, msdslG703WorstIntervalLOFC=msdslG703WorstIntervalLOFC, msdslCurrentESs=msdslCurrentESs, msdslFarEndTotalIfIndex=msdslFarEndTotalIfIndex, msdslFracPortTS=msdslFracPortTS, msdslFarEndIntervalPerfEntry=msdslFarEndIntervalPerfEntry, msdslFarEndCurrentIfIndex=msdslFarEndCurrentIfIndex, msdslErrEventsCounter=msdslErrEventsCounter, msdslFarEndTotalEntry=msdslFarEndTotalEntry, msdslTotalTable=msdslTotalTable, msdslErrValidIntervals=msdslErrValidIntervals, msdslFracPortIfTS=msdslFracPortIfTS, msdslCurrentPerfIfIndex=msdslCurrentPerfIfIndex, msdslTotalFEBEs=msdslTotalFEBEs, msdslDevice=msdslDevice, msdslFarEndIntervalESs=msdslFarEndIntervalESs, msdslIntervalPerfTable=msdslIntervalPerfTable, msdslG703WorstInterval=msdslG703WorstInterval, msdslFarEndCurrentPerfTable=msdslFarEndCurrentPerfTable, msdslMarginLow=msdslMarginLow, msdslIntervalPerfIfIndex=msdslIntervalPerfIfIndex, msdslIntervalIfIndex=msdslIntervalIfIndex, msdslIntervalESs=msdslIntervalESs, msdslFarEndCurrentPerfRxGain=msdslFarEndCurrentPerfRxGain, msdslErrorRateNormal=msdslErrorRateNormal, msdslIntervalNumber=msdslIntervalNumber, msdslIntervalPerfMargin=msdslIntervalPerfMargin, msdslIntervalTable=msdslIntervalTable, msdslFracEntry=msdslFracEntry, msdslPerfPayloadRate=msdslPerfPayloadRate, msdslFarEndIntervalIfIndex=msdslFarEndIntervalIfIndex, msdslFarEndWorstIntervalIfIndex=msdslFarEndWorstIntervalIfIndex, msdslFarEndCurrentTable=msdslFarEndCurrentTable, msdslWorstIntervalESs=msdslWorstIntervalESs, msdslCurrentSESs=msdslCurrentSESs, msdsldsx1WorstIntervalBESs=msdsldsx1WorstIntervalBESs, msdslErrorRateHigh=msdslErrorRateHigh, msdslWorstIntervalTable=msdslWorstIntervalTable, msdslTotalSESs=msdslTotalSESs, msdslCurrentPerfEntry=msdslCurrentPerfEntry, msdslG703WorstIntervalSESs=msdslG703WorstIntervalSESs, msdslFarEndIntervalSESs=msdslFarEndIntervalSESs, msdslInterval=msdslInterval, msdslCurrentFEBEs=msdslCurrentFEBEs, msdslG703WorstIntervalEntry=msdslG703WorstIntervalEntry, msdslCurrent=msdslCurrent, msdslTotalIfIndex=msdslTotalIfIndex, msdslIntervalPerfNumber=msdslIntervalPerfNumber, msdslG703WorstIntervalESs=msdslG703WorstIntervalESs, msdsldsx1WorstIntervalSESs=msdsldsx1WorstIntervalSESs, msdslCurrentIfIndex=msdslCurrentIfIndex, msdslErrTimeElapsed=msdslErrTimeElapsed, msdsldsx1WorstInterval=msdsldsx1WorstInterval, msdsldsx1WorstIntervalTable=msdsldsx1WorstIntervalTable, msdslPortConfigAllocMethodTable=msdslPortConfigAllocMethodTable, msdslFarEndIntervalFEBEs=msdslFarEndIntervalFEBEs, msdslCurrentEntry=msdslCurrentEntry, msdslWorstIntervalIfIndex=msdslWorstIntervalIfIndex, msdslValidIntervals=msdslValidIntervals, msdslCurrentPerfTable=msdslCurrentPerfTable, msdslFarEndCurrentESs=msdslFarEndCurrentESs, msdslWorstIntervalFEBEs=msdslWorstIntervalFEBEs, msdslFracPortIfIndex=msdslFracPortIfIndex) |
sql_user = "lopez"
# for obvious reasons this should be changed
sql_pass = "johny johny telling lies"
sql_db = "lopez"
sql_host = "localhost"
sql_port = 5432
# changing the below line will void the non-existent warranty Lopez came with
# so please don't
postgresql = "postgresql://{0}:{1}@{2}:{3}/{4}".format(
sql_user, sql_pass, sql_host, sql_port, sql_db
)
| sql_user = 'lopez'
sql_pass = 'johny johny telling lies'
sql_db = 'lopez'
sql_host = 'localhost'
sql_port = 5432
postgresql = 'postgresql://{0}:{1}@{2}:{3}/{4}'.format(sql_user, sql_pass, sql_host, sql_port, sql_db) |
DEPS = [
'chromium',
'file',
'gsutil',
'recipe_engine/json',
'math_utils',
'recipe_engine/path',
'recipe_engine/platform',
'recipe_engine/properties',
'recipe_engine/python',
'recipe_engine/raw_io',
'recipe_engine/step',
]
| deps = ['chromium', 'file', 'gsutil', 'recipe_engine/json', 'math_utils', 'recipe_engine/path', 'recipe_engine/platform', 'recipe_engine/properties', 'recipe_engine/python', 'recipe_engine/raw_io', 'recipe_engine/step'] |
class Solution:
def XXX(self, root: TreeNode) -> List[List[int]]:
ans, d = [], [root] if root else []
while d:
ans.append([t.val for t in d])
d = [r for t in d for r in (t.left, t.right) if r]
return ans
| class Solution:
def xxx(self, root: TreeNode) -> List[List[int]]:
(ans, d) = ([], [root] if root else [])
while d:
ans.append([t.val for t in d])
d = [r for t in d for r in (t.left, t.right) if r]
return ans |
# Range -> range instance that holds all nums counting by one between 0 and first input
# List -> lists numbers from the inputted tuple
numberedContestants = range(30)
print(list(numberedContestants))
for c in list(numberedContestants):
print(f"Contestant {c} is here.")
lucky_winners = range(7, 30, 5)
print(list(lucky_winners)) | numbered_contestants = range(30)
print(list(numberedContestants))
for c in list(numberedContestants):
print(f'Contestant {c} is here.')
lucky_winners = range(7, 30, 5)
print(list(lucky_winners)) |
class Thing:
def __init__(self, x, y, name):
self.x = x
self.y = y
self.name = name
t = Thing(12, 34, "dave")
print(vars(t)) # {'x': 12, 'y': 34, 'name': 'dave'}
| class Thing:
def __init__(self, x, y, name):
self.x = x
self.y = y
self.name = name
t = thing(12, 34, 'dave')
print(vars(t)) |
#!/usr/bin/python
class FilterModule(object):
def filters(self):
return {
'amend_list_items': self.amend_list_items
}
def amend_list_items(self, orig_list, prefix="", postfix=""):
return list(map(lambda listelement: prefix +
str(listelement) + postfix, orig_list))
| class Filtermodule(object):
def filters(self):
return {'amend_list_items': self.amend_list_items}
def amend_list_items(self, orig_list, prefix='', postfix=''):
return list(map(lambda listelement: prefix + str(listelement) + postfix, orig_list)) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.