content
stringlengths
7
1.05M
fixed_cases
stringlengths
1
1.28M
_base_ = [ '../../_base_/models/detr.py', '../../_base_/datasets/mot15.py', '../../_base_/default_runtime.py' #'../../_base_/datasets/mot_challenge.py', ] custom_imports = dict(imports=['mmtrack.models.mot.kf'], allow_failed_imports=False) link = 'https://download.openmmlab.com/mmdetection/v2.0/detr/detr_r50_8x2_150e_coco/detr_r50_8x2_150e_coco_20201130_194835-2c4b8974.pth' model = dict(type='KFSORT', detector=dict( init_cfg=dict(type='Pretrained',checkpoint=link), ), score_thres=0.9, iou_thres=0.3, ) dataset_type = 'MOTChallengeDataset' data_root = 'data/MOT15/' # data = dict( # samples_per_gpu=2, # workers_per_gpu=2, # train=dict( # type=dataset_type, # visibility_thr=-1, # ann_file=data_root + 'annotations/half-train_cocoformat.json', # img_prefix=data_root + 'train', # ref_img_sampler=dict( # num_ref_imgs=1, # frame_range=10, # filter_key_img=True, # method='uniform'), # pipeline=train_pipeline), # val=dict( # type=dataset_type, # ann_file=data_root + 'annotations/half-val_cocoformat.json', # img_prefix=data_root + 'train', # ref_img_sampler=None, # pipeline=test_pipeline), # test=dict( # type=dataset_type, # ann_file=data_root + 'annotations/half-val_cocoformat.json', # img_prefix=data_root + 'train', # ref_img_sampler=None, # pipeline=test_pipeline)) # learning policy lr_config = dict( policy='step', warmup='linear', warmup_iters=100, warmup_ratio=1.0 / 100, step=[3]) # runtime settings total_epochs = 4 evaluation = dict(metric=['bbox', 'track'], interval=1) search_metrics = ['MOTA', 'IDF1', 'FN', 'FP', 'IDs', 'MT', 'ML']
_base_ = ['../../_base_/models/detr.py', '../../_base_/datasets/mot15.py', '../../_base_/default_runtime.py'] custom_imports = dict(imports=['mmtrack.models.mot.kf'], allow_failed_imports=False) link = 'https://download.openmmlab.com/mmdetection/v2.0/detr/detr_r50_8x2_150e_coco/detr_r50_8x2_150e_coco_20201130_194835-2c4b8974.pth' model = dict(type='KFSORT', detector=dict(init_cfg=dict(type='Pretrained', checkpoint=link)), score_thres=0.9, iou_thres=0.3) dataset_type = 'MOTChallengeDataset' data_root = 'data/MOT15/' lr_config = dict(policy='step', warmup='linear', warmup_iters=100, warmup_ratio=1.0 / 100, step=[3]) total_epochs = 4 evaluation = dict(metric=['bbox', 'track'], interval=1) search_metrics = ['MOTA', 'IDF1', 'FN', 'FP', 'IDs', 'MT', 'ML']
_base_ = [ '../_base_/default_runtime.py' ] model = dict( type='opera.InsPose', backbone=dict( type='mmdet.ResNet', depth=50, num_stages=4, out_indices=(0, 1, 2, 3), frozen_stages=1, norm_eval=False, style='pytorch', init_cfg=dict(type='Pretrained', checkpoint='torchvision://resnet50')), neck=dict( type='mmdet.FPN', in_channels=[256, 512, 1024, 2048], out_channels=256, start_level=1, add_extra_convs='on_output', num_outs=5, relu_before_extra_convs=True), bbox_head=dict( type='opera.InsPoseHead', num_classes=1, # (only person) in_channels=256, stacked_convs=4, feat_channels=256, stacked_convs_kpt=4, feat_channels_kpt=512, stacked_convs_hm=3, feat_channels_hm=512, strides=[8, 16, 32, 64, 128], center_sampling=True, center_sample_radius=1.5, centerness_on_reg=True, regression_normalize=True, with_hm_loss=True, min_overlap_hm=0.9, min_hm_radius=0, max_hm_radius=3, min_overlap_kp=0.9, min_offset_radius=0, max_offset_radius=3, loss_cls=dict( type='mmdet.VarifocalLoss', use_sigmoid=True, gamma=2.0, alpha=0.75, iou_weighted=True, loss_weight=1.0), loss_bbox=dict(type='mmdet.GIoULoss', loss_weight=1.0), loss_centerness=dict( type='mmdet.CrossEntropyLoss', use_sigmoid=True, loss_weight=1.0), loss_hm=dict( type='mmdet.FocalLoss', use_sigmoid=True, gamma=2.0, alpha=0.25, loss_weight=1.0), loss_weight_offset=1.0, unvisible_weight=0.1), test_cfg = dict( nms_pre=1000, score_thr=0.05, nms=dict(type='soft_nms', iou_threshold=0.3), mask_thresh=0.5, max_per_img=100)) # dataset settings dataset_type = 'opera.CocoPoseDataset' data_root = '/dataset/public/coco/' img_norm_cfg = dict( mean=[123.675, 116.28, 103.53], std=[58.395, 57.12, 57.375], to_rgb=True) train_pipeline = [ dict(type='mmdet.LoadImageFromFile', to_float32=True), dict(type='opera.LoadAnnotations', with_bbox=True, with_mask=True, with_keypoint=True), dict(type='opera.Resize', img_scale=[(1333, 800), (1333, 768), (1333, 736), (1333, 704), (1333, 672), (1333, 640)], multiscale_mode='value', keep_ratio=True), dict(type='opera.RandomFlip', flip_ratio=0.5), dict(type='mmdet.Normalize', **img_norm_cfg), dict(type='mmdet.Pad', size_divisor=32), dict(type='opera.DefaultFormatBundle'), dict(type='mmdet.Collect', keys=['img', 'gt_bboxes', 'gt_labels', 'gt_masks', 'gt_keypoints']), ] test_pipeline = [ dict(type='mmdet.LoadImageFromFile'), dict( type='mmdet.MultiScaleFlipAug', img_scale=(1333, 800), flip=False, transforms=[ dict(type='mmdet.Resize', keep_ratio=True), dict(type='mmdet.RandomFlip'), dict(type='mmdet.Normalize', **img_norm_cfg), dict(type='mmdet.Pad', size_divisor=32), dict(type='mmdet.ImageToTensor', keys=['img']), dict(type='mmdet.Collect', keys=['img']), ]) ] data = dict( samples_per_gpu=4, workers_per_gpu=2, train=dict( type=dataset_type, ann_file='/data/configs/inspose/person_keypoints_train2017_pesudobox.json', img_prefix=data_root + 'images/train2017/', pipeline=train_pipeline, skip_invaild_pose=False), val=dict( type=dataset_type, ann_file=data_root + 'annotations/person_keypoints_val2017.json', img_prefix=data_root + 'images/val2017/', pipeline=test_pipeline), test=dict( type=dataset_type, ann_file=data_root + 'annotations/person_keypoints_val2017.json', img_prefix=data_root + 'images/val2017/', pipeline=test_pipeline)) evaluation = dict(interval=1, metric='keypoints') # optimizer optimizer = dict(type='SGD', lr=0.02, momentum=0.9, weight_decay=0.0001) optimizer_config = dict(grad_clip=dict(max_norm=35, norm_type=2)) # learning policy lr_config = dict( policy='step', warmup='linear', warmup_iters=2000, warmup_ratio=0.001, step=[27, 33]) runner = dict(type='EpochBasedRunner', max_epochs=36) checkpoint_config = dict(interval=1, max_keep_ckpts=3)
_base_ = ['../_base_/default_runtime.py'] model = dict(type='opera.InsPose', backbone=dict(type='mmdet.ResNet', depth=50, num_stages=4, out_indices=(0, 1, 2, 3), frozen_stages=1, norm_eval=False, style='pytorch', init_cfg=dict(type='Pretrained', checkpoint='torchvision://resnet50')), neck=dict(type='mmdet.FPN', in_channels=[256, 512, 1024, 2048], out_channels=256, start_level=1, add_extra_convs='on_output', num_outs=5, relu_before_extra_convs=True), bbox_head=dict(type='opera.InsPoseHead', num_classes=1, in_channels=256, stacked_convs=4, feat_channels=256, stacked_convs_kpt=4, feat_channels_kpt=512, stacked_convs_hm=3, feat_channels_hm=512, strides=[8, 16, 32, 64, 128], center_sampling=True, center_sample_radius=1.5, centerness_on_reg=True, regression_normalize=True, with_hm_loss=True, min_overlap_hm=0.9, min_hm_radius=0, max_hm_radius=3, min_overlap_kp=0.9, min_offset_radius=0, max_offset_radius=3, loss_cls=dict(type='mmdet.VarifocalLoss', use_sigmoid=True, gamma=2.0, alpha=0.75, iou_weighted=True, loss_weight=1.0), loss_bbox=dict(type='mmdet.GIoULoss', loss_weight=1.0), loss_centerness=dict(type='mmdet.CrossEntropyLoss', use_sigmoid=True, loss_weight=1.0), loss_hm=dict(type='mmdet.FocalLoss', use_sigmoid=True, gamma=2.0, alpha=0.25, loss_weight=1.0), loss_weight_offset=1.0, unvisible_weight=0.1), test_cfg=dict(nms_pre=1000, score_thr=0.05, nms=dict(type='soft_nms', iou_threshold=0.3), mask_thresh=0.5, max_per_img=100)) dataset_type = 'opera.CocoPoseDataset' data_root = '/dataset/public/coco/' img_norm_cfg = dict(mean=[123.675, 116.28, 103.53], std=[58.395, 57.12, 57.375], to_rgb=True) train_pipeline = [dict(type='mmdet.LoadImageFromFile', to_float32=True), dict(type='opera.LoadAnnotations', with_bbox=True, with_mask=True, with_keypoint=True), dict(type='opera.Resize', img_scale=[(1333, 800), (1333, 768), (1333, 736), (1333, 704), (1333, 672), (1333, 640)], multiscale_mode='value', keep_ratio=True), dict(type='opera.RandomFlip', flip_ratio=0.5), dict(type='mmdet.Normalize', **img_norm_cfg), dict(type='mmdet.Pad', size_divisor=32), dict(type='opera.DefaultFormatBundle'), dict(type='mmdet.Collect', keys=['img', 'gt_bboxes', 'gt_labels', 'gt_masks', 'gt_keypoints'])] test_pipeline = [dict(type='mmdet.LoadImageFromFile'), dict(type='mmdet.MultiScaleFlipAug', img_scale=(1333, 800), flip=False, transforms=[dict(type='mmdet.Resize', keep_ratio=True), dict(type='mmdet.RandomFlip'), dict(type='mmdet.Normalize', **img_norm_cfg), dict(type='mmdet.Pad', size_divisor=32), dict(type='mmdet.ImageToTensor', keys=['img']), dict(type='mmdet.Collect', keys=['img'])])] data = dict(samples_per_gpu=4, workers_per_gpu=2, train=dict(type=dataset_type, ann_file='/data/configs/inspose/person_keypoints_train2017_pesudobox.json', img_prefix=data_root + 'images/train2017/', pipeline=train_pipeline, skip_invaild_pose=False), val=dict(type=dataset_type, ann_file=data_root + 'annotations/person_keypoints_val2017.json', img_prefix=data_root + 'images/val2017/', pipeline=test_pipeline), test=dict(type=dataset_type, ann_file=data_root + 'annotations/person_keypoints_val2017.json', img_prefix=data_root + 'images/val2017/', pipeline=test_pipeline)) evaluation = dict(interval=1, metric='keypoints') optimizer = dict(type='SGD', lr=0.02, momentum=0.9, weight_decay=0.0001) optimizer_config = dict(grad_clip=dict(max_norm=35, norm_type=2)) lr_config = dict(policy='step', warmup='linear', warmup_iters=2000, warmup_ratio=0.001, step=[27, 33]) runner = dict(type='EpochBasedRunner', max_epochs=36) checkpoint_config = dict(interval=1, max_keep_ckpts=3)
class Employee(): def __init__(self, first_name, last_name, money): self.first_name = first_name self.last_name = last_name self.money = money def give_raise(self, add_money=5000): self.money += add_money return self.money
class Employee: def __init__(self, first_name, last_name, money): self.first_name = first_name self.last_name = last_name self.money = money def give_raise(self, add_money=5000): self.money += add_money return self.money
def add(x,y): return x + y def multiply(x,y): return x * y def subtract(x,y): return x - y def divide(x,y): return y/x def power(x,y): return x**y
def add(x, y): return x + y def multiply(x, y): return x * y def subtract(x, y): return x - y def divide(x, y): return y / x def power(x, y): return x ** y
# EclipseCon Europe Che Challenge # # This program prints the numbers from 1 to 100, with every multiple of 3 # replaced by "Fizz", and every multiple of 5 replaced by "Buzz". Numbers # divisible by both are replaced by "FizzBuzz". Otherwise, the program # prints the number. # # Your mission, if you choose to accept it, is to change this program so that, # in addition to the above, it prints "Fizz" for any number which includes a 3, # and prints "Buzz" for any number including a 5. After modification, for # example, the number 53 should be replaced by "FizzBuzz". # # Once you have completed the challenge, you will be entered into a draw for # one of the ChromeBooks at the Eclipse Che booth. for i in range(1, 101): num = "%s" % i; if (i % 3 == 0): num = "Fizz" if (i % 5 == 0): num = "Buzz" print (f"{num}");
for i in range(1, 101): num = '%s' % i if i % 3 == 0: num = 'Fizz' if i % 5 == 0: num = 'Buzz' print(f'{num}')
class DataPacker: #list data type will only write out the values without the key @staticmethod def dataTypeList(): return "list" @staticmethod def dataTypeObject(): return "object" def __init__(self, type): self.type = type self.data = [] def add_pair(self, key, value): self.data.append([key, value]) def add_value(self, key, value): self.data.append(key, value) def to_string(self, coding): if self.type == self.dataTypeObject(): if coding == 'json': s = "{" for item in self.data: s += ' "' + item[0] + '": ' s += '"' + item[1] + '"\n' s += "}" else: for item in self.data: s += item[0].replace('=', '\\=') + '=' s += item[1] + '\n' if self.type == self.dataTypeList(): if coding == 'json': s = "[" for item in self.data: s += '"' + item[1] + '"\n' s += "]" else: for item in self.data: s += item[1] + '\n' return s
class Datapacker: @staticmethod def data_type_list(): return 'list' @staticmethod def data_type_object(): return 'object' def __init__(self, type): self.type = type self.data = [] def add_pair(self, key, value): self.data.append([key, value]) def add_value(self, key, value): self.data.append(key, value) def to_string(self, coding): if self.type == self.dataTypeObject(): if coding == 'json': s = '{' for item in self.data: s += ' "' + item[0] + '": ' s += '"' + item[1] + '"\n' s += '}' else: for item in self.data: s += item[0].replace('=', '\\=') + '=' s += item[1] + '\n' if self.type == self.dataTypeList(): if coding == 'json': s = '[' for item in self.data: s += '"' + item[1] + '"\n' s += ']' else: for item in self.data: s += item[1] + '\n' return s
#! /usr/bin/python # Filename: object_init # Description: the constructor in python class Persion: def __init__(self, name): self.name = name def sayHi(self): print(self.name) test = Persion("Hello,world") test.sayHi()
class Persion: def __init__(self, name): self.name = name def say_hi(self): print(self.name) test = persion('Hello,world') test.sayHi()
arr = [-3, 4, 8, -2, -1, 5, 4, 8] for i in range(0, len(arr)-1): if(arr[i] > 0): #num is positive temp = arr[i] arr[i] = arr[i+1] arr[i+1] = temp print(arr)
arr = [-3, 4, 8, -2, -1, 5, 4, 8] for i in range(0, len(arr) - 1): if arr[i] > 0: temp = arr[i] arr[i] = arr[i + 1] arr[i + 1] = temp print(arr)
class Rememberer: def __init__(self): self.funcs = [] def register(self, fn): self.funcs.append(fn) fn.__conform__ = lambda new: self.recode(fn, new) return self def recode(self, fn, new): if new is None: self.funcs.remove(fn) else: fn.__code__ = new.__code__ def __call__(self, *args): return [fn(*args) for fn in self.funcs] activities = Rememberer() @activities.register def do(x): return f"Paint {x} canvasses" @activities.register def do(x): return f"Sing {x} songs" @activities.register def do(x): return f"Worship the {x} suns" @activities.register def do(x): return f"Dance for {x} hours" @activities.register def do(x): return f"Do {x} push-ups"
class Rememberer: def __init__(self): self.funcs = [] def register(self, fn): self.funcs.append(fn) fn.__conform__ = lambda new: self.recode(fn, new) return self def recode(self, fn, new): if new is None: self.funcs.remove(fn) else: fn.__code__ = new.__code__ def __call__(self, *args): return [fn(*args) for fn in self.funcs] activities = rememberer() @activities.register def do(x): return f'Paint {x} canvasses' @activities.register def do(x): return f'Sing {x} songs' @activities.register def do(x): return f'Worship the {x} suns' @activities.register def do(x): return f'Dance for {x} hours' @activities.register def do(x): return f'Do {x} push-ups'
# Create a program that reads an integer and shows on the screen whether it is even or odd n = int(input('Type a integer: ')) if n % 2 == 0: print('The number {} is {} EVEN {}'.format(n, '\033[1;31;40m', '\033[m')) else: print('The number {} is {} ODD {}'.format(n, '\033[7;30m', '\033[m'))
n = int(input('Type a integer: ')) if n % 2 == 0: print('The number {} is {} EVEN {}'.format(n, '\x1b[1;31;40m', '\x1b[m')) else: print('The number {} is {} ODD {}'.format(n, '\x1b[7;30m', '\x1b[m'))
# Handshake # Count the number of Handshakes in a board meeting. # # https://www.hackerrank.com/challenges/handshake/problem # T = int(input()) for a0 in range(T): N = int(input()) print(N * (N - 1) // 2)
t = int(input()) for a0 in range(T): n = int(input()) print(N * (N - 1) // 2)
inicial = int(input('Qual o numero inicial?')) final = int(input('Qual o numero final?')) x = inicial while( x <= final): if(x % 2 == 0): print(x) x = x + 1
inicial = int(input('Qual o numero inicial?')) final = int(input('Qual o numero final?')) x = inicial while x <= final: if x % 2 == 0: print(x) x = x + 1
def main_screen(calendar): while True: print("What would you like to do? ") print("\ta) Add event") print("\tb) Delete event") print("\tc) Print events") print("\td) Exit") answer = input(" $ ") if "a" in answer: add_event(calendar) elif "b" in answer: delete_event(calendar) elif "c" in answer: print_events(calendar) elif "d" in answer: break else: pass def add_event(calendar): print("What is the name of the event that you would like to add?") name = input(" $ ") print("When does your event start? FORMAT: dd/mm/yyyy hh:mm:ss") start_time = input(" $ ") print("When does your event end? FORMAT: dd/mm/yyyy hh:mm:ss") end_time = input(" $ ") try: calendar.add_event(name, start_time, end_time) except ValueError: print("Check your inputs, they don't seem to be in the right format.") def delete_event(calendar): calendar.print_events() print("What is the ID of the event(s) you would like to delete? Separate ids with ,.") event_ids = input(" $ ") event_ids = event_ids.split(",") calendar.delete_event(event_ids) def print_events(calendar): calendar.print_events()
def main_screen(calendar): while True: print('What would you like to do? ') print('\ta) Add event') print('\tb) Delete event') print('\tc) Print events') print('\td) Exit') answer = input(' $ ') if 'a' in answer: add_event(calendar) elif 'b' in answer: delete_event(calendar) elif 'c' in answer: print_events(calendar) elif 'd' in answer: break else: pass def add_event(calendar): print('What is the name of the event that you would like to add?') name = input(' $ ') print('When does your event start? FORMAT: dd/mm/yyyy hh:mm:ss') start_time = input(' $ ') print('When does your event end? FORMAT: dd/mm/yyyy hh:mm:ss') end_time = input(' $ ') try: calendar.add_event(name, start_time, end_time) except ValueError: print("Check your inputs, they don't seem to be in the right format.") def delete_event(calendar): calendar.print_events() print('What is the ID of the event(s) you would like to delete? Separate ids with ,.') event_ids = input(' $ ') event_ids = event_ids.split(',') calendar.delete_event(event_ids) def print_events(calendar): calendar.print_events()
def levenshtein_Distance(word1,word2): word1="#"+word1 wordTmp="#"+word2 letters1 = list(word1) letters2 = list(wordTmp) # Initializing table table = [ [0 for i in range(len(word1))] for j in range(len(wordTmp))] for i in range (len(word1)): table[0][i] = i for j in range (len(wordTmp)): table[j][0] = j for i in range (1,len(word1)): for j in range (1,len(wordTmp)): tmpList=[] x = table[j][i-1]+1 tmpList.append(x) y = table[j-1][i]+1 tmpList.append(y) if letters1[i] == letters2[j]: z = table[j-1][i-1] else: z = table[j-1][i-1]+2 tmpList.append(z) table[j][i] =min(tmpList) return table[-1][-1],word2
def levenshtein__distance(word1, word2): word1 = '#' + word1 word_tmp = '#' + word2 letters1 = list(word1) letters2 = list(wordTmp) table = [[0 for i in range(len(word1))] for j in range(len(wordTmp))] for i in range(len(word1)): table[0][i] = i for j in range(len(wordTmp)): table[j][0] = j for i in range(1, len(word1)): for j in range(1, len(wordTmp)): tmp_list = [] x = table[j][i - 1] + 1 tmpList.append(x) y = table[j - 1][i] + 1 tmpList.append(y) if letters1[i] == letters2[j]: z = table[j - 1][i - 1] else: z = table[j - 1][i - 1] + 2 tmpList.append(z) table[j][i] = min(tmpList) return (table[-1][-1], word2)
# # PySNMP MIB module ACMEPACKET-PRODUCTS (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/ACMEPACKET-PRODUCTS # Produced by pysmi-0.3.4 at Mon Apr 29 16:57:56 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) # acmepacket, = mibBuilder.importSymbols("ACMEPACKET-SMI", "acmepacket") Integer, ObjectIdentifier, OctetString = mibBuilder.importSymbols("ASN1", "Integer", "ObjectIdentifier", "OctetString") NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues") ValueRangeConstraint, ConstraintsUnion, SingleValueConstraint, ValueSizeConstraint, ConstraintsIntersection = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueRangeConstraint", "ConstraintsUnion", "SingleValueConstraint", "ValueSizeConstraint", "ConstraintsIntersection") NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance") Counter32, Gauge32, iso, Integer32, Counter64, Unsigned32, ObjectIdentity, IpAddress, TimeTicks, MibIdentifier, MibScalar, MibTable, MibTableRow, MibTableColumn, NotificationType, ModuleIdentity, Bits = mibBuilder.importSymbols("SNMPv2-SMI", "Counter32", "Gauge32", "iso", "Integer32", "Counter64", "Unsigned32", "ObjectIdentity", "IpAddress", "TimeTicks", "MibIdentifier", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "NotificationType", "ModuleIdentity", "Bits") TextualConvention, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TextualConvention", "DisplayString") acmepacketProducts = ModuleIdentity((1, 3, 6, 1, 4, 1, 9148, 1)) acmepacketProducts.setRevisions(('2012-07-16 00:00', '2007-04-03 15:00',)) if mibBuilder.loadTexts: acmepacketProducts.setLastUpdated('201207160000Z') if mibBuilder.loadTexts: acmepacketProducts.setOrganization('Acme Packet, Inc.') apNetNet4000Series = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 1)) if mibBuilder.loadTexts: apNetNet4000Series.setStatus('current') apNetNet4250 = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 1, 1)) if mibBuilder.loadTexts: apNetNet4250.setStatus('current') apNetNet4500 = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 1, 2)) if mibBuilder.loadTexts: apNetNet4500.setStatus('current') apNetNet9000Series = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 2)) if mibBuilder.loadTexts: apNetNet9000Series.setStatus('current') apNetNet9200 = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 2, 1)) if mibBuilder.loadTexts: apNetNet9200.setStatus('current') apNetNet3000Series = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 3)) if mibBuilder.loadTexts: apNetNet3000Series.setStatus('current') apNetNet3800 = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 3, 1)) if mibBuilder.loadTexts: apNetNet3800.setStatus('current') apNetNet3820 = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 3, 2)) if mibBuilder.loadTexts: apNetNet3820.setStatus('current') apNetNetOSSeries = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 4)) if mibBuilder.loadTexts: apNetNetOSSeries.setStatus('current') apNetNetOS = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 4, 1)) if mibBuilder.loadTexts: apNetNetOS.setStatus('current') apNetNetOSVM = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 4, 2)) if mibBuilder.loadTexts: apNetNetOSVM.setStatus('current') apNetNet6000Series = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 5)) if mibBuilder.loadTexts: apNetNet6000Series.setStatus('current') apNetNet6300 = ObjectIdentity((1, 3, 6, 1, 4, 1, 9148, 1, 5, 1)) if mibBuilder.loadTexts: apNetNet6300.setStatus('current') mibBuilder.exportSymbols("ACMEPACKET-PRODUCTS", apNetNet9000Series=apNetNet9000Series, apNetNet3820=apNetNet3820, apNetNet4500=apNetNet4500, apNetNet3000Series=apNetNet3000Series, apNetNet4250=apNetNet4250, apNetNetOSVM=apNetNetOSVM, PYSNMP_MODULE_ID=acmepacketProducts, apNetNet4000Series=apNetNet4000Series, apNetNet6000Series=apNetNet6000Series, apNetNet9200=apNetNet9200, acmepacketProducts=acmepacketProducts, apNetNetOS=apNetNetOS, apNetNet6300=apNetNet6300, apNetNet3800=apNetNet3800, apNetNetOSSeries=apNetNetOSSeries)
(acmepacket,) = mibBuilder.importSymbols('ACMEPACKET-SMI', 'acmepacket') (integer, object_identifier, octet_string) = mibBuilder.importSymbols('ASN1', 'Integer', 'ObjectIdentifier', 'OctetString') (named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues') (value_range_constraint, constraints_union, single_value_constraint, value_size_constraint, constraints_intersection) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ValueRangeConstraint', 'ConstraintsUnion', 'SingleValueConstraint', 'ValueSizeConstraint', 'ConstraintsIntersection') (notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance') (counter32, gauge32, iso, integer32, counter64, unsigned32, object_identity, ip_address, time_ticks, mib_identifier, mib_scalar, mib_table, mib_table_row, mib_table_column, notification_type, module_identity, bits) = mibBuilder.importSymbols('SNMPv2-SMI', 'Counter32', 'Gauge32', 'iso', 'Integer32', 'Counter64', 'Unsigned32', 'ObjectIdentity', 'IpAddress', 'TimeTicks', 'MibIdentifier', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'NotificationType', 'ModuleIdentity', 'Bits') (textual_convention, display_string) = mibBuilder.importSymbols('SNMPv2-TC', 'TextualConvention', 'DisplayString') acmepacket_products = module_identity((1, 3, 6, 1, 4, 1, 9148, 1)) acmepacketProducts.setRevisions(('2012-07-16 00:00', '2007-04-03 15:00')) if mibBuilder.loadTexts: acmepacketProducts.setLastUpdated('201207160000Z') if mibBuilder.loadTexts: acmepacketProducts.setOrganization('Acme Packet, Inc.') ap_net_net4000_series = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 1)) if mibBuilder.loadTexts: apNetNet4000Series.setStatus('current') ap_net_net4250 = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 1, 1)) if mibBuilder.loadTexts: apNetNet4250.setStatus('current') ap_net_net4500 = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 1, 2)) if mibBuilder.loadTexts: apNetNet4500.setStatus('current') ap_net_net9000_series = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 2)) if mibBuilder.loadTexts: apNetNet9000Series.setStatus('current') ap_net_net9200 = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 2, 1)) if mibBuilder.loadTexts: apNetNet9200.setStatus('current') ap_net_net3000_series = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 3)) if mibBuilder.loadTexts: apNetNet3000Series.setStatus('current') ap_net_net3800 = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 3, 1)) if mibBuilder.loadTexts: apNetNet3800.setStatus('current') ap_net_net3820 = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 3, 2)) if mibBuilder.loadTexts: apNetNet3820.setStatus('current') ap_net_net_os_series = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 4)) if mibBuilder.loadTexts: apNetNetOSSeries.setStatus('current') ap_net_net_os = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 4, 1)) if mibBuilder.loadTexts: apNetNetOS.setStatus('current') ap_net_net_osvm = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 4, 2)) if mibBuilder.loadTexts: apNetNetOSVM.setStatus('current') ap_net_net6000_series = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 5)) if mibBuilder.loadTexts: apNetNet6000Series.setStatus('current') ap_net_net6300 = object_identity((1, 3, 6, 1, 4, 1, 9148, 1, 5, 1)) if mibBuilder.loadTexts: apNetNet6300.setStatus('current') mibBuilder.exportSymbols('ACMEPACKET-PRODUCTS', apNetNet9000Series=apNetNet9000Series, apNetNet3820=apNetNet3820, apNetNet4500=apNetNet4500, apNetNet3000Series=apNetNet3000Series, apNetNet4250=apNetNet4250, apNetNetOSVM=apNetNetOSVM, PYSNMP_MODULE_ID=acmepacketProducts, apNetNet4000Series=apNetNet4000Series, apNetNet6000Series=apNetNet6000Series, apNetNet9200=apNetNet9200, acmepacketProducts=acmepacketProducts, apNetNetOS=apNetNetOS, apNetNet6300=apNetNet6300, apNetNet3800=apNetNet3800, apNetNetOSSeries=apNetNetOSSeries)
# Feature flag to raise an exception in case of a non existing device feature. # The flag should be fully removed in a later release. # It allows dependend libraries to gracefully migrate to the new behaviour raise_exception_on_not_supported_device_feature = True # Feature flag to raise exception if rate limit of the API is hit raise_exception_on_rate_limit = True # Feature flag to raise exception on command calls if the API does not return (2xx or 3xx) responses. raise_exception_on_command_failure = True
raise_exception_on_not_supported_device_feature = True raise_exception_on_rate_limit = True raise_exception_on_command_failure = True
class Solution: def countOdds(self, low: int, high: int) -> int: c = high - low + 1 if c % 2 == 1 and low % 2 == 1: r = 1 else: r = 0 return r + c // 2
class Solution: def count_odds(self, low: int, high: int) -> int: c = high - low + 1 if c % 2 == 1 and low % 2 == 1: r = 1 else: r = 0 return r + c // 2
class Solution: def reverseWords(self, s: str) -> str: res, blank = '', False for _ in s[::-1]: res += _ return ' '.join(res.split()[::-1])
class Solution: def reverse_words(self, s: str) -> str: (res, blank) = ('', False) for _ in s[::-1]: res += _ return ' '.join(res.split()[::-1])
# ----------------------------------------------------------------------------- # Copyright * 2014, United States Government, as represented by the # Administrator of the National Aeronautics and Space Administration. All # rights reserved. # # The Crisis Mapping Toolkit (CMT) v1 platform is licensed under the Apache # License, Version 2.0 (the "License"); you may not use this file except in # compliance with the License. You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0. # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations under # the License. # ----------------------------------------------------------------------------- # this file stores variously previously learned Adaboost classifiers modis_classifiers = dict() radar_classifiers = dict() # default classifier, learned from ['unflooded_mississippi_2010.xml', 'unflooded_new_orleans_2004.xml', 'sf_bay_area_2011_4.xml', 'unflooded_bosnia_2013.xml'] modis_classifiers['default'] = [(u'dartmouth', 0.30887438055782945, 1.4558371112080295), (u'b2', 2020.1975382568198, 0.9880130793929531), (u'MNDWI', 0.3677501330908955, 0.5140443440746121), (u'b2', 1430.1463073852296, 0.15367606716883875), (u'b1', 1108.5241042345276, 0.13193086117959033), (u'dartmouth', 0.7819758531686796, -0.13210548296374583), (u'dartmouth', 0.604427824270283, 0.12627962195951867), (u'b2', 1725.1719228210247, -0.07293616881105353), (u'b2', 1872.6847305389224, -0.09329031467870501), (u'b2', 1577.659115103127, 0.1182474134065663), (u'b2', 1946.441134397871, -0.13595282841411163), (u'b2', 2610.24876912841, 0.10010381165310277), (u'b2', 1983.3193363273454, -0.0934455057392682), (u'b2', 1503.9027112441784, 0.13483194249576771), (u'b2', 2001.7584372920826, -0.10099203054937314), (u'b2', 2905.2743845642053, 0.1135686859467779), (u'dartmouth', 0.5156538098210846, 0.07527677772747364), (u'b2', 2010.9779877744513, -0.09535260187161688), (u'b2', 1798.9283266799735, 0.07889358547222977), (u'dartmouth', 0.36787708796485785, -0.07370319016383906), (u'MNDWI', -0.6422574132273133, 0.06922934793487515), (u'dartmouth', 0.33837573426134365, -0.10266747186797487), (u'dartmouth', 0.4712668025964854, 0.09612545197834421), (u'dartmouth', 0.3236250574095866, -0.10754218805531587), (u'MNDWI', -0.48248013602276113, 0.111365639029263), (u'dartmouth', 0.316249718983708, -0.10620217821842894), (u'dartmouth', 0.4490732989841858, 0.09743861137429623), (u'dartmouth', 0.31256204977076874, -0.08121162639185005), (u'MNDWI', -0.5623687746250372, 0.10344420165347998), (u'dartmouth', 0.3107182151642991, -0.08899821447581886), (u'LSWI', -0.29661326544921773, 0.08652882218688322), (u'dartmouth', 0.3097962978610643, -0.07503568257204306), (u'MNDWI', 0.022523637136343283, 0.08765150582301148), (u'b2', 2015.5877630156356, -0.06978548014829108), (u'b2', 3052.7871922821028, 0.08567389991115743), (u'LSWI', -0.19275063787434812, 0.08357667312445341), (u'dartmouth', 0.3093353392094469, -0.08053950648462435), (u'LSWI', -0.14081932408691333, 0.07186342090261867), (u'dartmouth', 0.30910485988363817, -0.05720223719278896), (u'MNDWI', 0.19513688511361937, 0.07282637257701345), (u'NDWI', -0.361068160450533, 0.06565995208358431), (u'NDWI', -0.2074005503754442, -0.0522715989389411), (u'b1', 775.4361563517915, 0.05066415016422507), (u'b2', 2017.8926506362277, -0.0596357907686033), (u'b2', 1762.050124750499, 0.06600172638129476), (u'b2', 2019.0450944465238, -0.05498763067596745), (u'b1', 941.9801302931596, 0.06500771792028737), (u'dartmouth', 0.24987167315080105, 0.06409775979747406), (u'b2', 2979.0307884231543, 0.06178896578945445), (u'dartmouth', 0.22037031944728686, 0.04708770942378687), (u'dartmouth', 0.30898962022073384, -0.06357932266591948), (u'EVI', -0.13991172174597732, 0.061167901067941045), (u'dartmouth', 0.30893200038928165, -0.047538992866687814), (u'dartmouth', 0.23512099629904396, 0.055800430467148325), (u'dartmouth', 0.3089031904735555, -0.04993911823852714), (u'dartmouth', 0.22774565787316542, 0.045917043382747345), (u'b1', 232.32231270358304, -0.04624672841408699), (u'LSWIminusEVI', -1.3902019910129537, 0.044122210356250594), (u'fai', 914.8719936250361, 0.04696283008449494), (u'b2', 2019.6213163516718, -0.051114386132496435), (u'b2', 2315.2231536926147, 0.048898662215419296), (u'fai', 1434.706585047812, -0.05352547959475242), (u'diff', -544.4250000000001, -0.04459039609050114), (u'dartmouth', 0.39737844166837205, 0.045452678171318414), (u'dartmouth', 0.3088887855156925, -0.03891014191130265), (u'dartmouth', 0.22405798866022614, 0.042128457713671935), (u'diff', -777.2958333333333, -0.03902784979889064), (u'dartmouth', 0.2222141540537565, 0.03788131334473313), (u'dartmouth', 0.30888158303676094, -0.037208213701295255), (u'dartmouth', 0.3531264111131007, 0.0375648736301961), (u'dartmouth', 0.3088779817972952, -0.03427856593613819), (u'LSWI', -0.16678498098063071, 0.03430983541990538), (u'fai', -425.5957838307736, -0.03348006551810443), (u'NDWI', -0.13056674533789978, -0.03552899660957818), (u'b2', 2019.3332053990978, -0.0344936369203531), (u'b2', 1835.806528609448, 0.03856210900250611), (u'b2', 1467.0245093147041, -0.0345449746977328), (u'fai', 395.0374022022602, 0.031130251540884356), (u'fai', 654.9546979136481, 0.04214466417320743), (u'b2', 1448.5854083499669, -0.05667775728680656), (u'fai', 135.12010649087222, 0.03948338203848539), (u'dartmouth', 0.493460306208785, -0.045802615250103394), (u'fai', 784.9133457693422, 0.03128133499873274), (u'fai', 1174.7892893364242, -0.04413487095880613), (u'b2', 3015.9089903526283, 0.04133685218791008), (u'fai', 1304.7479371921181, -0.04107557606064173), (u'b2', 2462.7359614105126, 0.03777625735990945), (u'fai', 1369.727261119965, -0.03524600268462714), (u'b2', 2997.4698893878913, 0.03864830537283341), (u'dartmouth', 0.22313607135699132, 0.0348041704038284), (u'fai', -575.9950811359025, -0.036345846940478974), (u'fai', 1402.2169230838886, -0.03481517966048645), (u'fai', 719.9340218414952, 0.032833655233338276), (u'b2', 2019.1891499228109, -0.03272953788499046), (u'b2', 2388.9795575515636, 0.03713369823962704), (u'b2', 2019.1171221846673, -0.027949075715791222), (u'b2', 1743.611023785762, 0.03310357200312585), (u'LSWIminusNDVI', -0.3990346417915731, 0.029045726328998267), (u'NDWI', -0.16898364785667197, -0.025735337614573982), (u'dartmouth', 0.3088761811775623, -0.02973898070330325)] ## Trained only on Mississippi MODIS x 30 #classifier = [(u'dartmouth', 0.4601187028446295, 1.3933244326017509), (u'b2', 2354.099683544304, 0.8009263433881945), (u'LSWIminusNDVI', -0.37403464179157314, -0.19660698864485893), (u'b2', 997.0490506329114, -0.22609471240379023), (u'LSWI', 0.7307270024497643, -0.19371590131103372), (u'b2', 2862.799841772152, 0.1958087739665682), (u'LSWI', 0.6519079187081369, -0.10411467161095657), (u'b2', 827.2238924050632, -0.1627002183497957), (u'LSWI', 0.6124983768373232, -0.1164763151056205), (u'b2', 3117.149920886076, 0.14045495336435712), (u'dartmouth', 0.8979830751809463, -0.12738474810727388), (u'b2', 1845.3995253164558, 0.09053474497663075), (u'LSWIminusNDVI', -0.4337695820901687, 0.0857764518831651), (u'dartmouth', 1.4135180226982098, 0.07075600803587892), (u'LSWIminusNDVI', 0.7774358230593219, -0.11418946709797562), (u'dartmouth', 1.3146504355818416, 0.10739211371940653), (u'dartmouth', 1.0568829618232098, -0.11015352163127118), (u'b2', 2989.974881329114, 0.08685181198332771), (u'LSWI', 0.8095460861913917, -0.08786494584616246), (u'b2', 912.1364715189873, -0.10303455995441295), (u'MNDWI', -0.29396969047077653, 0.07596098140939918), (u'dartmouth', 1.3640842291400257, 0.09266573131480345), (u'LSWI', 0.8489556280622054, -0.0783584759736119), (u'NDVI', 0.7748969641121193, 0.07406876644625034), (u'dartmouth', 0.9774330185020781, -0.08325113592851094), (u'dartmouth', 0.739083188538683, 0.07799308375292567), (u'dartmouth', 0.9377080468415122, -0.07468962616015257), (u'b2', 3053.562401107595, 0.08334191996627335), (u'LSWI', 0.8686603989976123, -0.05795058684040472), (u'b2', 954.5927610759493, -0.0764128019856413)] # Trained only on Bosnia data set # 30 #classifier = [(u'fai', -105.57184246833049, 2.011175093865707), (u'diff', 1251.7560240963855, 0.8824534628772853), (u'LSWI', -0.1950396228838406, -0.34104836216017687), (u'MNDWI', 0.3156758628856189, 0.3971974262249763), (u'diff', 1652.1280120481929, 0.2301851751240506), (u'fai', 21.356797943057927, -0.25320140980424466), (u'ratio', 8.124320652173912, -0.27487135740578195), (u'MNDWI', 0.4338371139090058, 0.23183008491145138), (u'fai', -42.10752226263628, -0.2838952387654039), (u'ratio', 9.051290760869565, -0.18060837756218376), (u'MNDWI', 0.4929177394206993, 0.26151319350647706), (u'dartmouth', 0.7715202347815262, -0.19603377110432904), (u'MNDWI', 0.46337742666485254, 0.16945766306122212), (u'ratio', 9.51477581521739, -0.19326781484568353), (u'fai', -73.83968236548338, -0.1914520350524376), (u'dartmouth', 0.8985318397001062, 0.1320588534810869), (u'ratio', 9.746518342391305, -0.19297983361086213), (u'dartmouth', 0.9620376421593961, 0.138279854734148), (u'dartmouth', 0.8350260372408163, -0.11171574068467803), (u'fai', 84.82111814875213, 0.10168445603729025), (u'fai', -89.70576241690694, -0.14899335489218352), (u'NDVI', 0.7246944616336632, -0.12905505976725612), (u'MNDWI', 0.5224580521765461, 0.13393714338762214), (u'MNDWI', -0.09581370874173237, 0.0971904083985509), (u'fai', -97.63880244261871, -0.12420188150947246), (u'fai', 116.55327825159924, 0.1379596068377162), (u'fai', -101.6053224554746, -0.13973920004492527), (u'ratio', 9.862389605978262, -0.13788473854143857), (u'dartmouth', 0.9302847409297512, 0.12752031805931177), (u'dartmouth', 0.8032731360111712, -0.12615703892605462)] # 100 #classifier = [(u'fai', -105.57184246833049, 2.011175093865707), (u'diff', 1251.7560240963855, 0.8824534628772853), (u'LSWI', -0.1950396228838406, -0.34104836216017687), (u'MNDWI', 0.3156758628856189, 0.3971974262249763), (u'diff', 1652.1280120481929, 0.2301851751240506), (u'fai', 21.356797943057927, -0.25320140980424466), (u'ratio', 8.124320652173912, -0.27487135740578195), (u'MNDWI', 0.4338371139090058, 0.23183008491145138), (u'fai', -42.10752226263628, -0.2838952387654039), (u'ratio', 9.051290760869565, -0.18060837756218376), (u'MNDWI', 0.4929177394206993, 0.26151319350647706), (u'dartmouth', 0.7715202347815262, -0.19603377110432904), (u'MNDWI', 0.46337742666485254, 0.16945766306122212), (u'ratio', 9.51477581521739, -0.19326781484568353), (u'fai', -73.83968236548338, -0.1914520350524376), (u'dartmouth', 0.8985318397001062, 0.1320588534810869), (u'ratio', 9.746518342391305, -0.19297983361086213), (u'dartmouth', 0.9620376421593961, 0.138279854734148), (u'dartmouth', 0.8350260372408163, -0.11171574068467803), (u'fai', 84.82111814875213, 0.10168445603729025), (u'fai', -89.70576241690694, -0.14899335489218352), (u'NDVI', 0.7246944616336632, -0.12905505976725612), (u'MNDWI', 0.5224580521765461, 0.13393714338762214), (u'MNDWI', -0.09581370874173237, 0.0971904083985509), (u'fai', -97.63880244261871, -0.12420188150947246), (u'fai', 116.55327825159924, 0.1379596068377162), (u'fai', -101.6053224554746, -0.13973920004492527), (u'ratio', 9.862389605978262, -0.13788473854143857), (u'dartmouth', 0.9302847409297512, 0.12752031805931177), (u'dartmouth', 0.8032731360111712, -0.12615703892605462), (u'fai', 53.08895804590503, 0.11280108368230035), (u'fai', -103.58858246190255, -0.1323621639708806), (u'fai', 68.95503809732858, 0.11111732544776452), (u'fai', -104.58021246511652, -0.09561460982792948), (u'ratio', 9.920325237771738, -0.11350588718525503), (u'MNDWI', 0.5372282085544694, 0.12457806680434337), (u'ratio', 9.949293053668477, -0.10142947278348549), (u'b1', 1024.4102564102564, 0.12769119462941034), (u'LSWIminusEVI', 1.2275397718573775, -0.10736324339508174), (u'b2', 3027.5, 0.11335627686056896), (u'LSWIminusEVI', 0.9969081432144813, -0.09855102339735189), (u'b2', 2856.25, 0.12341099685812779), (u'LSWIminusEVI', 1.1122239575359294, -0.09888830150850089), (u'fai', -105.0760274667235, -0.10867185036244718), (u'LSWI', -0.22884831003114736, 0.09390617010433257), (u'b1', 855.3653846153845, 0.09224267581066231), (u'dartmouth', 0.7873966853963488, -0.08654968485638263), (u'MNDWI', 0.5076878957986226, 0.08281065550953068), (u'LSWIminusEVI', 1.0545660503752052, -0.10070544168373859), (u'b1', 939.8878205128204, 0.09546509230524551), (u'LSWIminusEVI', 1.0257370967948432, -0.07512157753132792), (u'dartmouth', 0.9144082903149287, 0.08334614008782373), (u'MNDWI', 0.37475648839731235, -0.09347621062767539), (u'EVI', -0.5354007283235324, 0.07174011237019035), (u'MNDWI', 0.5298431303655078, 0.09325407788460913), (u'LSWIminusEVI', 1.011322620004662, -0.07094468512780058), (u'fai', -105.323934967527, -0.08699012823035202), (u'fai', 37.22287799448148, 0.0825373235212839), (u'dartmouth', 0.7794584600889375, -0.07138166975482693), (u'dartmouth', 0.8667789384704612, 0.07712045798967725), (u'dartmouth', 0.7754893474352318, -0.06762386155357324), (u'dartmouth', 0.6445086298629463, 0.07866161620559303), (u'fai', -105.44788871792875, -0.06872185637143167), (u'LSWI', -0.21194396645749397, 0.07899481836422567), (u'b1', 982.1490384615383, 0.067325499150263), (u'dartmouth', 0.773504791108379, -0.06463211254050916), (u'dartmouth', 0.5810028274036563, 0.07334871420010625), (u'b1', 770.8429487179487, -0.059061001597415036), (u'fai', -105.50986559312962, -0.0589202777929247), (u'EVI', -0.7131758497107877, 0.07543805485058235), (u'b2', 2941.875, 0.0769994468975548), (u'ratio', 9.934809145720108, -0.06559718164524614), (u'MNDWI', 0.5150729739875843, 0.0716339467915095), (u'dartmouth', 0.7725125129449526, -0.051293672818369905), (u'LSWI', -0.2034917946706673, 0.05938789552971963), (u'b1', 961.0184294871794, 0.07318340098162476), (u'b1', 813.1041666666666, -0.06572293073399683), (u'fai', 735.022130941929, 0.060554277275912824), (u'fai', 1028.3904772356705, -0.05029509963366562), (u'dartmouth', 0.9223465156223399, 0.0603999613021688), (u'ratio', 9.927567191745922, -0.059891901340974205), (u'fai', -105.54085403073006, -0.07731554985749788), (u'EVI', -0.62428828901716, 0.06719923296302845), (u'b1', 950.453125, 0.07579445528659902), (u'LSWIminusEVI', 1.0041153816095716, -0.056489892194208524), (u'MNDWI', 0.5113804348931035, 0.05913619958443161), (u'MNDWI', 0.4042968011531591, -0.05075066212771365), (u'diff', 44.518072289156635, 0.04720084087401721), (u'fai', -105.55634824953027, -0.05663241244401389), (u'diff', 247.76506024096386, 0.0590397873216613), (u'b2', 2899.0625, 0.05140907548559329), (u'NDVI', 0.678130801361386, -0.05420275867925114), (u'fai', -105.56409535893039, -0.0578072448545363), (u'NDVI', 0.6548489712252474, -0.07016682881460558), (u'dartmouth', 0.9183774029686342, 0.07612486244144435), (u'NDVI', 0.6664898862933167, -0.06024946186606819), (u'MNDWI', 0.544613286743431, 0.07203803995934993), (u'NDVI', 0.660669428759282, -0.055733385225458454), (u'b2', 2877.65625, 0.05993217671898275), (u'b1', 834.2347756410256, -0.05155918752640494)] # New Orleans 30 #classifier = [(u'b2', 396.6109850939728, 1.4807909625958868), (u'b2', 1768.9536616979908, 0.8924003455619385), (u'b1', 854.8195364238411, 0.40691523803721014), (u'MNDWI', 0.3892345080908955, 0.36259940088550857), (u'dartmouth', 0.30135484930782946, -0.14337027100064728), (u'NDWI', -0.08016322692474476, -0.15831813233382272), (u'b2', 2281.2268308489956, 0.1353187435748396), (u'dartmouth', 0.7479193288987777, -0.16003727715630708), (u'b2', 2537.363415424498, 0.14061137727842032), (u'ratio', 6.880495612552257, -0.1166499595177218), (u'dartmouth', 0.3565977910898579, -0.11078288758401122), (u'NDWI', -0.2159195980788689, -0.10724023529180131), (u'dartmouth', 0.3289763201988437, -0.10755196279513543), (u'LSWI', -0.0569956547430914, 0.13659163207872768), (u'ratio', 3.9894934188283853, -0.10611849585590673), (u'b2', 2665.4317077122487, 0.14308264148123284), (u'ratio', 5.434994515690321, -0.0863607116606289), (u'b2', 2729.4658538561243, 0.08311291715506125), (u'fai', 902.9220972795897, -0.09359740396097607), (u'NDWI', -0.14804141250180683, -0.0705379771355723), (u'dartmouth', 0.31516558475333656, -0.08259143592340348), (u'LSWI', -0.14982826386693998, 0.08733446419322317), (u'ratio', 9.771497806276129, 0.08172740412577022), (u'MNDWI', -0.6315152257273133, 0.09657359625983933), (u'ratio', 11.216998903138064, 0.08246857226665376), (u'MNDWI', -0.7966635966818656, 0.07605162061421399), (u'dartmouth', 0.32207095247609013, -0.08295128868296117), (u'MNDWI', -0.7140894112045895, 0.0793663117501679), (u'ratio', 10.494248354707096, 0.08231229722793916), (u'LSWIminusEVI', -0.08557300521224676, -0.07043790156684442)] # 87 on a full set including a dozen lakes modis_classifiers['lakes'] = [(u'dartmouth', 0.3191065854189406, 1.557305460141852), (u'MNDWI', 0.36596171757859164, 0.6348226054395288), (u'fai', 1076.7198220279101, 0.30760696551024047), (u'b1', 2490.1666666666665, 0.15428815637057783), (u'b1', 1382.4166666666665, 0.23468676605683622), (u'MNDWI', 0.016043270812331922, 0.2328762729873063), (u'diff', 1348.2627965043696, 0.0893530403812219), (u'EVI', -0.936229495395644, -0.0634313110230615), (u'EVI', 0.15713514272585227, -0.1369834357186273), (u'MNDWI', 0.19100249419546178, 0.1396065269707512), (u'EVI', -0.3895471763348959, -0.0699137042914175), (u'fai', -167.53021645595163, 0.09996436618217863), (u'diff', 3321.3055555555557, 0.09048885842380311), (u'fai', -39.46036556514488, 0.10447135022949844), (u'LSWIminusEVI', -1.8703796507388168, -0.08555612086933119), (u'fai', 24.57455988025849, 0.06788717248868892), (u'EVI', -0.1162060168045218, -0.07076437875624517), (u'EVI', 0.020464562960665234, -0.06640347420417587), (u'MNDWI', 0.2784821058870267, 0.0724098935614613), (u'LSWIminusEVI', -1.4401890608008658, -0.07070792766742959), (u'fai', -7.442902842443196, 0.07045138322018761), (u'EVI', -0.047870726921928286, -0.07285420746159146), (u'LSWIminusEVI', -1.2250937658318906, -0.055977386707896926), (u'b2', 3161.583333333333, -0.06589191057236488), (u'b2', 4305.708333333333, 0.04837026087353021), (u'dartmouth', 0.38322539525652455, 0.06306567258296356), (u'b2', 3733.645833333333, 0.054927931406532564), (u'dartmouth', 0.41528480017531655, 0.06032232647772757), (u'b2', 4019.677083333333, 0.0519316593408497), (u'dartmouth', 0.43131450263471255, 0.04868064475460096), (u'EVI', -0.013703081980631526, -0.052847995106752886), (u'b1', 828.5416666666666, -0.045046979840081554), (u'dartmouth', 0.4393293538644105, 0.03393621379393856), (u'b2', 436.6666666666667, -0.058719990230070525), (u'dartmouth', 0.44333677947925954, 0.055475163457599744), (u'dartmouth', 0.35116599033773255, -0.04464212550237975), (u'diff', 1956.9369538077403, -0.044786403818468996), (u'fai', 582.664653676786, 0.034362389553391215), (u'dartmouth', 0.3351362878783366, -0.03792028656513705), (u'dartmouth', 0.44534049228668404, 0.05187952065328861), (u'dartmouth', 0.3271214366486386, -0.05470657728868695), (u'MNDWI', -0.6666113750420029, 0.05405507219193603), (u'dartmouth', 0.32311401103378956, -0.05376528359478583), (u'dartmouth', 0.4463423486903963, 0.05449932480484019), (u'dartmouth', 0.32111029822636505, -0.0508089033370553), (u'MNDWI', -0.5002432754979653, 0.05120260867296932), (u'dartmouth', 0.32010844182265286, -0.0486732927468307), (u'dartmouth', 0.44684327689225245, 0.04692181887347917), (u'dartmouth', 0.31960751362079676, -0.04268244773234967), (u'MNDWI', -0.5834273252699841, 0.04712231236239887), (u'dartmouth', 0.31935704951986865, -0.04401637387406991), (u'MNDWI', -0.6250193501559935, 0.040914589219895145), (u'dartmouth', 0.31923181746940466, -0.038101469357921955), (u'dartmouth', 0.4470937409931805, 0.03911555294126862), (u'fai', 335.6370695012239, -0.0367701043425464), (u'fai', 212.12327741344288, -0.029512647597407196), (u'diff', 739.5886392009988, 0.04428176152799306), (u'diff', 1043.925717852684, 0.03722820575844798), (u'fai', 273.8801734573334, -0.04948130454705945), (u'dartmouth', 0.2549877755813566, 0.03377180068269043), (u'MNDWI', 0.3222219117328092, -0.04255121251198512), (u'diff', 1196.0942571785267, 0.045470427081376316), (u'MNDWI', 0.3440918146557004, -0.047085347000781985), (u'MNDWI', 0.23474230004124425, 0.04054075125347783), (u'MNDWI', 0.355026766117146, -0.046736584848805475), (u'MNDWI', 0.30035200880991797, 0.04078965556380944), (u'MNDWI', 0.3604942418478688, -0.04776704868198665), (u'LSWIminusNDVI', -0.5568084053554159, -0.04437083563150389), (u'MNDWI', 0.3112869602713636, 0.036248827530157374), (u'MNDWI', 0.36322797971323023, -0.04875479813967596), (u'MNDWI', 0.3167544360020864, 0.04123070622165848), (u'MNDWI', 0.36459484864591096, -0.03810930893128258), (u'diff', 1120.0099875156054, 0.035777913949894054), (u'fai', 829.6922378523481, -0.047446531409649384), (u'diff', 1081.9678526841449, 0.03507927976215228), (u'fai', 953.2060299401292, -0.04108410252021359), (u'b2', 4162.692708333333, 0.04836338373525389), (u'dartmouth', 0.44721897304364455, 0.03740129289331726), (u'dartmouth', 0.3191692014441726, -0.03601093736536919), (u'fai', 1014.9629259840196, -0.03601118264855319), (u'diff', 1158.052122347066, 0.04506611179539899), (u'fai', 1045.841374005965, -0.03593891978458228), (u'diff', 1652.599875156055, 0.03514766129091426), (u'fai', 1061.2805980169376, -0.034972506816040166), (u'fai', 1570.7749903790343, 0.03247104395760117), (u'MNDWI', -0.6042233377129889, 0.03328561186493601), (u'b2', 4091.184895833333, 0.03369074877033)] # Gloucester #classifier = [(u'Red', 106.25, 2.6908694873435546), (u'EVI', 1.8180788840643158, -1.6880493518661959), (u'MNDWI', 0.46606862179569125, 0.6759920285041151), (u'b1', 304.25, 0.6781297845583472), (u'Red', 145.5, -0.9332055109286996)] # New Bedford # Sumatra # BAD!!! #classifier = [(u'MNDWI', 0.4333154844558887, 1.493003861830998), (u'LSWI', 0.37775474450370045, -1.8148849780535137), (u'MNDWI', 0.44980066412990727, -0.7511626994787829), (u'NDWI', -0.6339380319013941, -0.8071101617753624), (u'LSWI', 0.39116467763045004, -0.6801609455151723), (u'Red_idm', 0.13091442790613322, -0.5990066511447246), (u'MNDWI', 0.5321794476425439, 1.0282918260098124), (u'b1', 534.25, 0.8524646445337082), (u'b2', 3215.75, 1.039598641718185), (u'LSWIminusEVI', -1.34846955925935, 0.5222328913364728), (u'MNDWI', 0.4168303047818701, 0.7765206583109537), (u'b1', 523.375, 0.8634569486904281), (u'NDVI', 0.7289698882981454, 1.2326959603643795), (u'b1', 366.25, 0.8382830454882036), (u'EVI', 1.422945109473755, 1.1928188689191888), (u'b1', 349.125, 0.7785531677333495), (u'LSWIminusEVI', -1.3167488924224617, 1.0260639426964406), (u'MNDWI', 0.40858771494486085, 1.4027451684417347), (u'LSWIminusEVI', -1.332609225840906, 1.9664195043168113), (u'MNDWI', 0.40446642002635624, 2.492961637332882), (u'EVI', 1.50922532584799, 3.6046473932813488), (u'LSWIminusEVI', -1.4332960268996904, 1.6903927811081079), (u'b1', 340.5625, 2.3605074347987642), (u'NDVI', 0.7122812759311696, 3.37782938914105), (u'b1', 517.9375, 1.6428199426052579), (u'MNDWI', 0.5321873001187866, 2.1599753462719047), (u'LSWIminusEVI', -1.340539392550128, 1.4453448840683698), (u'b1', 336.28125, 2.3208302513464885), (u'NDVI', 0.7039369697476817, 3.2525521714322845), (u'b1', 515.21875, 1.314512950758647), (u'MNDWI', 0.532191226356908, 1.617127359609984), (u'b2', 3156.375, 1.8784471643971616), (u'b1', 334.140625, 1.0400732285323449), (u'NDVI', 0.7959284553377698, 1.193027997994037), (u'b1', 333.0703125, 1.0099517832242602), (u'MNDWI', 0.5321931894759686, 1.0361885558471728), (u'EVI', 1.3797149514279692, 1.2523657802915276), (u'LSWIminusEVI', -1.344504475904739, 0.8719989740804845), (u'b1', 332.53515625, 1.0839084753587287), (u'NDVI', 0.6997648166559378, 1.7315726665929243), (u'b1', 332.267578125, 0.996052880739089), (u'NDVI', 0.7791377841849334, 1.0759593744171274), (u'b1', 332.1337890625, 0.9513482878953953), (u'MNDWI', 0.4024057725671039, 0.9086363886393817), (u'LSWIminusEVI', -1.3464870175820445, 1.8026760313828059), (u'Red', 86.875, 2.427801754929139), (u'b1', 513.859375, 1.058023863094511), (u'NDVI', 0.7875331197613515, 1.483041632820267), (u'b1', 332.06689453125, 1.052590647877841), (u'diff', 2716.75, 1.0137422040649617)] # Malawi #classifier = [(u'Red', 211.375, -1.4978661367770034), (u'NIR', 171.875, 1.5677471079645802), (u'Red', 208.6875, -0.7549541585435253), (u'b1', 1460.25, 0.6831800731095334), (u'EVI', 0.29952058003806714, 0.5210102026304385)] # trained on Landsat and MODIS # trained on Landsat multiple floods and MODIS (doesn't work well) #classifier = [(u'dartmouth', 0.31990953680782946, 1.3532525832292066), (u'LSWIminusNDVI', -0.41260886054157314, -2.2975599250672945), (u'LSWIminusNDVI', -0.3721610296179776, 0.8951755042386669), (u'LSWIminusNDVI', -0.4530566914651687, 0.6168756052926035), (u'b2', 2031.3975382568196, 0.4928850390139595), (u'B5', 59.35646171559858, 0.396967826941809), (u'B3', 115.2403564453125, -0.5827723329456356), (u'NDVI', -0.499185231572826, -0.8206139450883484), (u'NDVI', 15.27728981864239, -0.9612414977608352), (u'b1', 164.72231270358304, -1.1021978514482116), (u'ratio', 20.830495612552255, -0.8400239901683402), (u'B1', 14.01019038342401, -1.179673542586125), (u'B5', 7.458179092108224, 0.6191675239346668), (u'B5', 37.11245136246036, 0.45205356755293613), (u'LSWIminusNDVI', -0.4328327760033709, 0.2929427581041321), (u'LSWIminusNDVI', -0.35193711415617984, -0.3282316089074475), (u'MNDWI', -0.6320035069773133, -0.5077801803359128), (u'NDVI', 7.549723790463586, -0.7433972707850641), (u'MNDWI', -0.7969077373068656, -0.9734434265642887), (u'NDVI', 3.6859407763741845, -1.1185334743968922), (u'MNDWI', -0.8793598524716417, -1.2191574474417988), (u'dartmouth', 0.25538925127580103, 0.68557400171212), (u'b1', 93.5093648208469, -0.3183118201605347), (u'NDVI', 1.7540492693294836, -0.47533945354750357), (u'b1', 57.902890879478825, -0.5350006454963759), (u'NDVI', 0.7881035158071331, -0.488488980846825), (u'B1', 7.068814236390512, -0.43090497876107114), (u'B5', 11.163310050715186, 0.49166007962734726), (u'LSWIminusNDVI', -0.422720818272472, 0.24376142023795544), (u'LSWIminusEVI', -1.467155116012954, -0.2949111121125788), (u'NDVI', 1.2710763925683084, -0.3532787638045371), (u'b1', 40.099653908794785, -0.35440607970179305), (u'NDVI', 1.0295899541877207, -0.31164486232315497), (u'B1', 3.5981261628737626, -0.3626550539485778), (u'B5', 13.015875530018668, 0.21001981049372742), (u'LSWIminusNDVI', -0.4176648394070226, 0.22155949367640532), (u'LSWIminusNDVI', -0.47328060692696644, -0.25778054247623255), (u'LSWIminusNDVI', -0.4151368499742979, 0.22653206426504116), (u'LSWIminusNDVI', -0.3620490718870787, -0.22717813859342045), (u'LSWIminusNDVI', -0.4138728552579355, 0.22124896614628006), (u'LSWIminusNDVI', -0.4631686491960676, -0.22046149882433666), (u'LSWIminusNDVI', -0.4132408578997543, 0.20278657322608665), (u'B1', 74.36108315515176, -0.19698717197097967), (u'LSWIminusNDVI', -0.36710505075252814, -0.16603353237141502), (u'diff', -3.4819277108433653, -0.2138109964074318), (u'NDVI', 1.1503331733780144, -0.20132627230609748), (u'diff', -182.7289156626506, -0.29647898630599173), (u'LSWI', 22.59461849485026, -0.27478785278729473), (u'b1', 31.198035423452765, -0.3858949394312004), (u'LSWI', 11.28157617977539, -0.35278992723251107)] # trained on default, plus training data #classifier = [(u'diff', 7.851405622489949, 1.1499210570729492), (u'dartmouth', 0.8282223665130863, 0.8336847949898812), (u'LSWIminusNDVI', -0.4029517424860176, -0.4969022650114408), (u'B5', 67.74833454545968, 0.3966703235020681), (u'NDVI', 15.214214631938633, -0.34964556047496637), (u'B6', 83.3055415045817, -0.48622666016349725), (u'B5', 42.37932419232148, 0.3589512700830869), (u'diff', 1463.1726907630523, -0.33190674445403395), (u'dartmouth', 0.6501106091055225, 0.2663771427981788), (u'B1', 13.950356873100874, -0.21287499601676665), (u'NDVI', 7.477843215269061, -0.1659665288248955), (u'diff', -177.06224899598394, -0.23543668173775398), (u'NDVI', 3.6096575069342753, -0.23525924970683706), (u'diff', -84.605421686747, -0.23398869224812702), (u'NDVI', 1.6755646527668824, -0.21432187901910843), (u'MNDWI', -0.6460009028106466, -0.21133622170592178), (u'NDVI', 2.642611079850579, -0.19832033019573156), (u'MNDWI', -0.8039064352235321, -0.21902250388685324), (u'NDVI', 2.159087866308731, -0.21759471721995757), (u'MNDWI', -0.882859201429975, -0.22462325352727264), (u'NDVI', 1.9173262595378067, -0.22133287794719197), (u'MNDWI', -0.9223355845331964, -0.21912707745520124), (u'NDVI', 1.7964454561523446, -0.212352900657123)] # trained on unflooded_mississippi with landsat modis_classifiers['mississippi_5'] = [(u'B5', 22.5, 1.424016860332339)]#, (u'NDWI', -0.3488199979104613, -1.1643319348488192)]#, (u'MNDWI', 0.2060761675061745, -0.8190562053615513), (u'NDWI', 0.12342893439063468, -0.5539167295936754), (u'B6', 128.5625, -0.676969969487169)]#, (u'NDWI', -0.050652615441503096, -0.6038609463852692), (u'MNDWI', 0.0688502702628284, -0.5667166676298596), (u'NDWI', 0.6956693010823654, -0.5326141290666078), (u'MNDWI', -0.29396969047077653, -0.4977145365280558), (u'NDWI', -0.137693390357572, -0.5296068483657974), (u'MNDWI', 0.00023732164115535664, -0.40996366647279703), (u'NDWI', 0.2975104842227725, -0.45039955994958353)] modis_classifiers['mississippi'] = [(u'B5', 20.25, 1.4064982148857947), (u'NDWI', -0.3488199979104613, -1.1281588137098968), (u'MNDWI', 0.2060761675061745, -0.6204705541547991), (u'NDWI', 0.12342893439063468, -0.43739127359050894), (u'B6', 130.03125, -0.7385587172087229), (u'NDWI', -0.050652615441503096, -0.6351588979749766), (u'MNDWI', 0.0688502702628284, -0.7096006602751659), (u'NDWI', -0.137693390357572, -0.6767143211075154), (u'MNDWI', 0.00023732164115535664, -0.4784325526693348), (u'NDWI', 0.6956693010823654, -0.5175430073894397), (u'B6', 129.515625, -0.7658727652948186), (u'NDWI', 0.5836306675686378, -0.8230539867550758)]#, (u'MNDWI', -0.29396969047077653, -1.010378000263949), (u'NDWI', 0.2975104842227725, -1.3470307294716275), (u'MNDWI', -0.40676672221590593, -2.2975599250672945), (u'LSWIminusNDVI', 0.7774358230593219, -2.2975599250672945), (u'b1', 462.17105263157896, -2.2975599250672945), (u'ratio', 1.4121003963517729, -2.2975599250672945), (u'b2', 997.0490506329114, 1.708867948280161), (u'NDWI', -0.41086291422887156, -1.42020845722415), (u'b1', 519.8092105263158, 1.5190611577702313), (u'NDWI', -0.37984145606966646, 0.6952464401700104), (u'NDWI', 0.03638815947456579, -0.7169989507219887), (u'b2', 2354.099683544304, 0.3890029333764627), (u'MNDWI', 0.3433020647495206, -0.41277191754557085), (u'B5', 72.5, 0.3363970042121114), (u'NDWI', 0.38455125913884136, -0.3114385403162398), (u'B5', 15.125, -0.42367907943593436), (u'ratio', 1.7288336636264774, 0.29873586627097254), (u'b2', 827.2238924050632, -0.3807266400174877), (u'b1', 490.9901315789474, 0.35653058641342855), (u'ratio', 1.5704670299891252, 0.4029986460707291), (u'b2', 912.1364715189873, -0.2884661529282731), (u'NDWI', -0.395352185149269, 0.28270986674046317), (u'B1', 79.0625, -0.33478669976778425), (u'NDWI', 0.4280716465968758, -0.27808569593125426), (u'MNDWI', -0.1811726587256471, -0.4277643212788643), (u'NDWI', 0.21046970930670358, -0.47535345223600173), (u'MNDWI', -0.1247741428530824, -0.4532532405442839), (u'NDWI', 0.25399009676473805, -0.3579646150883709), (u'B6', 136.8125, 0.433260616467046), (u'b1', 476.5805921052632, 0.3387323994289085), (u'B3', 29.625, -0.2228446437747992), (u'b1', 469.37582236842104, 0.17408297061563255), (u'ratio', 1.491283713170449, 0.1900202691541482), (u'b2', 954.5927610759493, -0.28090682024123353), (u'ratio', 1.451692054761111, 0.2696401463438538), (u'NDVI', 0.4442480887479201, -0.26025283609038974), (u'LSWIminusEVI', -1.269889491012954, -0.2179140715466851), (u'b1', 465.7734375, 0.2120846094538366)] # trained on unflooded_new_orleans with landsat modis_classifiers['new_orleans'] = [(u'B4', 13.375, 1.4669571862477135), (u'b2', 1768.9536616979908, 0.7191964118271637), (u'B3', 18.3125, -0.4070155359645522), (u'LSWIminusEVI', -0.08557300521224676, -0.5810809746072104), (u'B4', 10.6875, -0.5291029708890636), (u'NDWI', 0.6135381706131, -0.42333042815387417), (u'MNDWI', -0.6315152257273133, -0.4508129543642559), (u'NDWI', 0.40244384299830177, -0.4529011567813934), (u'MNDWI', -0.7966635966818656, -0.4229803773880765), (u'NDWI', 0.8246324982278983, -0.4069177636794863), (u'MNDWI', -0.8792377821591417, -0.4443473879013045), (u'NDWI', 0.7190853344204992, -0.4883209250265058), (u'MNDWI', -0.9205248748977797, -0.49636567364951045), (u'NDWI', 0.7718589163241987, -0.47532398301078105), (u'MNDWI', -0.9411684212670988, -0.46105794712582865), (u'NDWI', 0.9301796620352974, -0.44708336474163696), (u'MNDWI', -0.9514901944517582, -0.4449868419505934), (u'NDWI', 0.8774060801315979, -0.4471999560229246), (u'MNDWI', -0.956651081044088, -0.44724569495404887), (u'NDWI', 0.8510192891797481, -0.4452132576283198), (u'MNDWI', -0.9592315243402529, -0.4429423461902555), (u'NDWI', 0.8378258937038232, -0.4412914152487152), (u'MNDWI', -0.46636685477276113, -0.44065814160370703), (u'NDWI', 0.7454721253723489, -0.42970202497381904), (u'MNDWI', -0.9605217459883353, -0.48957048644758405), (u'NDWI', 0.8312291959658608, -0.5099369404270232), (u'MNDWI', -0.9611668568123766, -0.5177206937846746), (u'NDWI', 0.8279308470968796, -0.5208055090499037), (u'MNDWI', -0.9614894122243971, -0.5218294172269368), (u'NDWI', 0.8262816726623889, -0.5221839375535151), (u'MNDWI', -0.9616506899304074, -0.5222930845903063), (u'NDWI', 0.8254570854451436, -0.5222798634644608), (u'MNDWI', -0.9617313287834126, -0.5221948879561688), (u'NDWI', 0.8250447918365209, -0.5221108271103068), (u'MNDWI', -0.9617716482099152, -0.5220471206666469), (u'NDWI', 0.8248386450322096, -0.5220049728945718), (u'MNDWI', -0.9617918079231664, -0.5219766049261293), (u'NDWI', 0.824735571630054, -0.5219580845269158), (u'MNDWI', -0.961801887779792, -0.5219465310519422), (u'NDWI', 0.8246840349289761, -0.5219393305356076), (u'MNDWI', -0.9618069277081049, -0.5219349735701074), (u'NDWI', 0.8246582665784372, -0.521932312793635), (u'MNDWI', -0.9618094476722614, -0.5219307253356017)] # radar classifiers # Rome TODO radar_classifiers['rome'] = [(u'diff', 178.90461847389557, 2.46177797269142), (u'dartmouth', 0.695180948525906, 0.5636808582048225), (u'b2', 3259.75, 0.40623813335255893), (u'vh', 60.0, 0.512954469752306), (u'b1', 600.7550251256282, 0.2801037593761655), (u'diff', 2154.25, 0.22719741605005747), (u'vh', 48.375, 0.1929392221948245), (u'EVI', -0.39797892895956055, -0.26067596700783746), (u'vh', 42.5625, 0.20882052714352622), (u'diff', 263.7538487282463, -0.211052953848031), (u'LSWI', 0.5436867478118161, -0.16553174402115256), (u'diff', 221.32923360107094, -0.15858370383683376), (u'LSWI', 0.45046812317651347, -0.19487772605927273), (u'EVI', -0.40180875045282066, -0.18574586377612953), (u'LSWI', 0.4038588108588621, -0.1607083937449329), (u'dartmouth', 1.0862723406778199, 0.14520750017543604), (u'b1', 365.38253768844226, 0.13710337373549727), (u'diff', 200.11692603748327, -0.12794110582183135), (u'LSWI', 0.38055415470003645, -0.14473310752902216), (u'b1', 1459.25, 0.13486298225301327), (u'MNDWI', 0.45613992940110276, 0.13252409515935595), (u'b1', 483.0687814070352, 0.1234375368417903), (u'vh', 39.65625, 0.10828147089675809), (u'b1', 1653.125, 0.14309662904293483), (u'vh', 30.875, 0.12050226416705825), (u'diff', 189.5107722556894, -0.13029115438110866), (u'dartmouth', 0.567399392562919, 0.12046203774769106), (u'diff', 184.20769536479247, -0.11034439591730216), (u'vh', 33.8125, 0.12078156192671918), (u'EVI', -0.4037236611994507, -0.11025517176478977), (u'LSWIminusEVI', -1.0112946701259427, -0.11523798706849528), (u'diff', 1909.875, -0.10464945907884636), (u'diff', 2032.0625, 0.07976450393456289), (u'dartmouth', 1.15403648079079, -0.1117066685929633), (u'diff', 2093.15625, 0.0968477259918149), (u'b1', 541.9119032663317, 0.07969028249670798), (u'b1', 836.1275125628141, -0.08405908949318663), (u'diff', 181.556156919344, -0.09346085859259494), (u'LSWI', 0.49707743549416483, -0.1085325347020279), (u'EVI', -0.40468111657276573, -0.09747783097236294), (u'vh', 32.34375, 0.09782288286234157), (u'b1', 1750.0625, 0.10205751464991006), (u'b1', 718.4412688442212, -0.09593339090882935), (u'b1', 424.2256595477387, 0.10473543924639585), (u'MNDWI', 0.5560647563672181, 0.06538569127220625), (u'MNDWI', 0.5061023428841604, 0.12118441764008514), (u'vh', 31.609375, 0.1342091965527664), (u'diff', 1787.6875, -0.10241482447678286), (u'MNDWI', 0.5310835496256893, 0.09017490496680071), (u'dartmouth', 1.187918550847275, -0.07281106494462425)] # Malawi radar_classifiers['malawi'] = [(u'b1', 1206.75, -1.4978661367770034), (u'vv', 92.25, 1.7076910083270624), (u'vv', 155.625, 0.7927423357058031), (u'LSWI', 0.17814903701073945, -0.5656867478534681), (u'b2', 2386.5, 0.39133434117158), (u'vv', 101.625, 0.494237798312077), (u'EVI', 0.29952058003806714, 0.4815500071179563), (u'vv', 106.3125, 0.3791369535317837), (u'LSWIminusNDVI', -0.16354986340261995, -0.3392309042314572), (u'vv', 108.65625, 0.2514716832021546), (u'b2', 2386.75, 0.3450772215737547), (u'vv', 107.484375, 0.2546137126854733), (u'LSWIminusNDVI', -0.16492926771972327, -0.2120703141095119), (u'vv', 106.8984375, 0.1745865336139307), (u'b2', 2386.875, 0.20753425729944486), (u'vv', 106.60546875, 0.17151475757505275), (u'LSWIminusNDVI', -0.16561896987827493, -0.15231935160185775), (u'vv', 106.458984375, 0.13206764439243204), (u'b2', 2386.9375, 0.14843573703920598), (u'vv', 106.3857421875, 0.1291434356120595), (u'LSWIminusNDVI', -0.16596382095755075, -0.11830301992251846), (u'b2', 2242.25, -0.11673694258002199), (u'vv', 154.4375, 0.14908876959293232), (u'LSWI', 0.1611832167953936, -0.13132406390088658), (u'vv', 153.84375, 0.11576377977859459), (u'vv', 106.34912109375, 0.10789584424489668), (u'b2', 2386.96875, 0.09128013378839395), (u'LSWI', 0.1527003066877207, -0.10621539361861156), (u'vv', 153.546875, 0.09035974506503541), (u'LSWI', 0.14845885163388423, -0.08265186904318825), (u'vv', 153.3984375, 0.07612663467721505), (u'vv', 106.330810546875, 0.08087104691133243), (u'EVI', 0.29940517086505597, 0.08383365337627942), (u'vv', 106.3216552734375, 0.0773362495526882), (u'LSWIminusNDVI', -0.16613624649718867, -0.07278061333579333), (u'vv', 106.31707763671875, 0.06783538228239976), (u'b2', 2386.984375, 0.07162768046483561), (u'LSWI', 0.146338124106966, -0.06916246665080311), (u'vv', 153.32421875, 0.06162461812861291), (u'vv', 106.31478881835938, 0.06613725906318095), (u'EVI', 0.29934746627855036, 0.06260671123906972), (u'vv', 106.31364440917969, 0.05891377646208847), (u'b2', 2386.9921875, 0.06026476394466554), (u'LSWI', 0.1452777603435069, -0.05929864988094706), (u'vv', 153.287109375, 0.053562732376205416), (u'vv', 106.31307220458984, 0.05635435997933675), (u'LSWIminusNDVI', -0.16622245926700763, -0.05460616467334437), (u'vv', 106.31278610229492, 0.051776199455337915), (u'b2', 2386.99609375, 0.053322901499510564), (u'LSWI', 0.14580794222523646, -0.05070452620576959)] # Mississippi radar_classifiers['mississippi'] = [(u'NDWI', -0.11622393735660222, -0.8115012757343506), (u'b2', 2985.5263157894738, 0.702679351118156), (u'vv', 5217.619047619048, 0.32062701131953586), (u'MNDWI', 0.26416074525030153, 0.3471969659874681), (u'b1', 1168.775, 0.23958804098018174), (u'b2', 3260.7631578947367, 0.1757460665061179), (u'MNDWI', 0.23640999604191795, 0.16849237965344419), (u'MNDWI', -0.051449424342105275, 0.21073597217765677), (u'LSWIminusNDVI', -0.15381863239050603, 0.261929215268214), (u'MNDWI', 0.10345585696939877, 0.17522339053409086), (u'NDVI', 0.37550520655709846, -0.11678248102474162), (u'ratio', 1.5808138542284427, 0.1307997498783867), (u'MNDWI', 0.22253462143772618, 0.15496439880003274), (u'vv', 23686.289682539682, 0.12065151422211098), (u'LSWIminusNDVI', -0.16578319612225706, 0.10079262433049868), (u'NDWI', 0.01798571473181413, -0.11427381786395764), (u'MNDWI', 0.15605755190146658, 0.12846750517442398), (u'LSWIminusNDVI', -0.15980091425638154, 0.12183307890098613), (u'b2', 3398.3815789473683, 0.0966718411565018), (u'NDWI', -0.035607830086293674, -0.1132584559163686), (u'hv', 4575.416666666667, -0.10741868882123311), (u'NDWI', 0.07157925954992193, -0.10737359754159287), (u'b2', 3467.190789473684, 0.13415083578467207), (u'b1', 1191.3125, -0.11146696782543182), (u'LSWIminusEVI', -2.5247238686545077, 0.11340603990862676), (u'vv', 31272.89484126984, 0.08425074607028928), (u'NDWI', 0.044782487140868035, -0.08653314042576717), (u'b2', 3792.0, 0.1044832325795063), (u'NDVI', 0.43088596754931874, -0.08847969070316128), (u'MNDWI', 0.18235839936750048, 0.07058671161786771), (u'NDWI', 0.058180873345394984, -0.08947323800356782), (u'b2', 3664.0, 0.08796628891143386), (u'NDWI', 0.06488006644765845, -0.07018091636763152), (u'b1', 1180.04375, -0.08727299235554262), (u'LSWIminusNDVI', -0.15680977332344379, 0.08425838412482411), (u'MNDWI', 0.19550882310051743, 0.0619919718523082), (u'NDWI', 0.09837603195897585, -0.08165793068280822), (u'b2', 3600.0, 0.08026689946353305), (u'NDWI', -0.008811057677239772, -0.059679375901025386), (u'hv', 5903.513888888889, -0.06982902975780846), (u'vv', 27479.592261904763, 0.06622628594867959), (u'hv', 51808.0, -0.06271609598725954), (u'vv', 16099.684523809523, -0.06691035524355445), (u'vv', 29376.2435515873, 0.06455229511493261), (u'vv', 19892.9871031746, -0.05233305018274409), (u'b2', 2710.289473684211, 0.05121585389944283), (u'b2', 2847.9078947368425, -0.06272919860762075), (u'b2', 2572.671052631579, 0.083277023990062), (u'b2', 2916.7171052631584, -0.11017977593192452), (u'b2', 2503.8618421052633, 0.08271694814319466)]
modis_classifiers = dict() radar_classifiers = dict() modis_classifiers['default'] = [(u'dartmouth', 0.30887438055782945, 1.4558371112080295), (u'b2', 2020.1975382568198, 0.9880130793929531), (u'MNDWI', 0.3677501330908955, 0.5140443440746121), (u'b2', 1430.1463073852296, 0.15367606716883875), (u'b1', 1108.5241042345276, 0.13193086117959033), (u'dartmouth', 0.7819758531686796, -0.13210548296374583), (u'dartmouth', 0.604427824270283, 0.12627962195951867), (u'b2', 1725.1719228210247, -0.07293616881105353), (u'b2', 1872.6847305389224, -0.09329031467870501), (u'b2', 1577.659115103127, 0.1182474134065663), (u'b2', 1946.441134397871, -0.13595282841411163), (u'b2', 2610.24876912841, 0.10010381165310277), (u'b2', 1983.3193363273454, -0.0934455057392682), (u'b2', 1503.9027112441784, 0.13483194249576771), (u'b2', 2001.7584372920826, -0.10099203054937314), (u'b2', 2905.2743845642053, 0.1135686859467779), (u'dartmouth', 0.5156538098210846, 0.07527677772747364), (u'b2', 2010.9779877744513, -0.09535260187161688), (u'b2', 1798.9283266799735, 0.07889358547222977), (u'dartmouth', 0.36787708796485785, -0.07370319016383906), (u'MNDWI', -0.6422574132273133, 0.06922934793487515), (u'dartmouth', 0.33837573426134365, -0.10266747186797487), (u'dartmouth', 0.4712668025964854, 0.09612545197834421), (u'dartmouth', 0.3236250574095866, -0.10754218805531587), (u'MNDWI', -0.48248013602276113, 0.111365639029263), (u'dartmouth', 0.316249718983708, -0.10620217821842894), (u'dartmouth', 0.4490732989841858, 0.09743861137429623), (u'dartmouth', 0.31256204977076874, -0.08121162639185005), (u'MNDWI', -0.5623687746250372, 0.10344420165347998), (u'dartmouth', 0.3107182151642991, -0.08899821447581886), (u'LSWI', -0.29661326544921773, 0.08652882218688322), (u'dartmouth', 0.3097962978610643, -0.07503568257204306), (u'MNDWI', 0.022523637136343283, 0.08765150582301148), (u'b2', 2015.5877630156356, -0.06978548014829108), (u'b2', 3052.7871922821028, 0.08567389991115743), (u'LSWI', -0.19275063787434812, 0.08357667312445341), (u'dartmouth', 0.3093353392094469, -0.08053950648462435), (u'LSWI', -0.14081932408691333, 0.07186342090261867), (u'dartmouth', 0.30910485988363817, -0.05720223719278896), (u'MNDWI', 0.19513688511361937, 0.07282637257701345), (u'NDWI', -0.361068160450533, 0.06565995208358431), (u'NDWI', -0.2074005503754442, -0.0522715989389411), (u'b1', 775.4361563517915, 0.05066415016422507), (u'b2', 2017.8926506362277, -0.0596357907686033), (u'b2', 1762.050124750499, 0.06600172638129476), (u'b2', 2019.0450944465238, -0.05498763067596745), (u'b1', 941.9801302931596, 0.06500771792028737), (u'dartmouth', 0.24987167315080105, 0.06409775979747406), (u'b2', 2979.0307884231543, 0.06178896578945445), (u'dartmouth', 0.22037031944728686, 0.04708770942378687), (u'dartmouth', 0.30898962022073384, -0.06357932266591948), (u'EVI', -0.13991172174597732, 0.061167901067941045), (u'dartmouth', 0.30893200038928165, -0.047538992866687814), (u'dartmouth', 0.23512099629904396, 0.055800430467148325), (u'dartmouth', 0.3089031904735555, -0.04993911823852714), (u'dartmouth', 0.22774565787316542, 0.045917043382747345), (u'b1', 232.32231270358304, -0.04624672841408699), (u'LSWIminusEVI', -1.3902019910129537, 0.044122210356250594), (u'fai', 914.8719936250361, 0.04696283008449494), (u'b2', 2019.6213163516718, -0.051114386132496435), (u'b2', 2315.2231536926147, 0.048898662215419296), (u'fai', 1434.706585047812, -0.05352547959475242), (u'diff', -544.4250000000001, -0.04459039609050114), (u'dartmouth', 0.39737844166837205, 0.045452678171318414), (u'dartmouth', 0.3088887855156925, -0.03891014191130265), (u'dartmouth', 0.22405798866022614, 0.042128457713671935), (u'diff', -777.2958333333333, -0.03902784979889064), (u'dartmouth', 0.2222141540537565, 0.03788131334473313), (u'dartmouth', 0.30888158303676094, -0.037208213701295255), (u'dartmouth', 0.3531264111131007, 0.0375648736301961), (u'dartmouth', 0.3088779817972952, -0.03427856593613819), (u'LSWI', -0.16678498098063071, 0.03430983541990538), (u'fai', -425.5957838307736, -0.03348006551810443), (u'NDWI', -0.13056674533789978, -0.03552899660957818), (u'b2', 2019.3332053990978, -0.0344936369203531), (u'b2', 1835.806528609448, 0.03856210900250611), (u'b2', 1467.0245093147041, -0.0345449746977328), (u'fai', 395.0374022022602, 0.031130251540884356), (u'fai', 654.9546979136481, 0.04214466417320743), (u'b2', 1448.5854083499669, -0.05667775728680656), (u'fai', 135.12010649087222, 0.03948338203848539), (u'dartmouth', 0.493460306208785, -0.045802615250103394), (u'fai', 784.9133457693422, 0.03128133499873274), (u'fai', 1174.7892893364242, -0.04413487095880613), (u'b2', 3015.9089903526283, 0.04133685218791008), (u'fai', 1304.7479371921181, -0.04107557606064173), (u'b2', 2462.7359614105126, 0.03777625735990945), (u'fai', 1369.727261119965, -0.03524600268462714), (u'b2', 2997.4698893878913, 0.03864830537283341), (u'dartmouth', 0.22313607135699132, 0.0348041704038284), (u'fai', -575.9950811359025, -0.036345846940478974), (u'fai', 1402.2169230838886, -0.03481517966048645), (u'fai', 719.9340218414952, 0.032833655233338276), (u'b2', 2019.1891499228109, -0.03272953788499046), (u'b2', 2388.9795575515636, 0.03713369823962704), (u'b2', 2019.1171221846673, -0.027949075715791222), (u'b2', 1743.611023785762, 0.03310357200312585), (u'LSWIminusNDVI', -0.3990346417915731, 0.029045726328998267), (u'NDWI', -0.16898364785667197, -0.025735337614573982), (u'dartmouth', 0.3088761811775623, -0.02973898070330325)] modis_classifiers['lakes'] = [(u'dartmouth', 0.3191065854189406, 1.557305460141852), (u'MNDWI', 0.36596171757859164, 0.6348226054395288), (u'fai', 1076.7198220279101, 0.30760696551024047), (u'b1', 2490.1666666666665, 0.15428815637057783), (u'b1', 1382.4166666666665, 0.23468676605683622), (u'MNDWI', 0.016043270812331922, 0.2328762729873063), (u'diff', 1348.2627965043696, 0.0893530403812219), (u'EVI', -0.936229495395644, -0.0634313110230615), (u'EVI', 0.15713514272585227, -0.1369834357186273), (u'MNDWI', 0.19100249419546178, 0.1396065269707512), (u'EVI', -0.3895471763348959, -0.0699137042914175), (u'fai', -167.53021645595163, 0.09996436618217863), (u'diff', 3321.3055555555557, 0.09048885842380311), (u'fai', -39.46036556514488, 0.10447135022949844), (u'LSWIminusEVI', -1.8703796507388168, -0.08555612086933119), (u'fai', 24.57455988025849, 0.06788717248868892), (u'EVI', -0.1162060168045218, -0.07076437875624517), (u'EVI', 0.020464562960665234, -0.06640347420417587), (u'MNDWI', 0.2784821058870267, 0.0724098935614613), (u'LSWIminusEVI', -1.4401890608008658, -0.07070792766742959), (u'fai', -7.442902842443196, 0.07045138322018761), (u'EVI', -0.047870726921928286, -0.07285420746159146), (u'LSWIminusEVI', -1.2250937658318906, -0.055977386707896926), (u'b2', 3161.583333333333, -0.06589191057236488), (u'b2', 4305.708333333333, 0.04837026087353021), (u'dartmouth', 0.38322539525652455, 0.06306567258296356), (u'b2', 3733.645833333333, 0.054927931406532564), (u'dartmouth', 0.41528480017531655, 0.06032232647772757), (u'b2', 4019.677083333333, 0.0519316593408497), (u'dartmouth', 0.43131450263471255, 0.04868064475460096), (u'EVI', -0.013703081980631526, -0.052847995106752886), (u'b1', 828.5416666666666, -0.045046979840081554), (u'dartmouth', 0.4393293538644105, 0.03393621379393856), (u'b2', 436.6666666666667, -0.058719990230070525), (u'dartmouth', 0.44333677947925954, 0.055475163457599744), (u'dartmouth', 0.35116599033773255, -0.04464212550237975), (u'diff', 1956.9369538077403, -0.044786403818468996), (u'fai', 582.664653676786, 0.034362389553391215), (u'dartmouth', 0.3351362878783366, -0.03792028656513705), (u'dartmouth', 0.44534049228668404, 0.05187952065328861), (u'dartmouth', 0.3271214366486386, -0.05470657728868695), (u'MNDWI', -0.6666113750420029, 0.05405507219193603), (u'dartmouth', 0.32311401103378956, -0.05376528359478583), (u'dartmouth', 0.4463423486903963, 0.05449932480484019), (u'dartmouth', 0.32111029822636505, -0.0508089033370553), (u'MNDWI', -0.5002432754979653, 0.05120260867296932), (u'dartmouth', 0.32010844182265286, -0.0486732927468307), (u'dartmouth', 0.44684327689225245, 0.04692181887347917), (u'dartmouth', 0.31960751362079676, -0.04268244773234967), (u'MNDWI', -0.5834273252699841, 0.04712231236239887), (u'dartmouth', 0.31935704951986865, -0.04401637387406991), (u'MNDWI', -0.6250193501559935, 0.040914589219895145), (u'dartmouth', 0.31923181746940466, -0.038101469357921955), (u'dartmouth', 0.4470937409931805, 0.03911555294126862), (u'fai', 335.6370695012239, -0.0367701043425464), (u'fai', 212.12327741344288, -0.029512647597407196), (u'diff', 739.5886392009988, 0.04428176152799306), (u'diff', 1043.925717852684, 0.03722820575844798), (u'fai', 273.8801734573334, -0.04948130454705945), (u'dartmouth', 0.2549877755813566, 0.03377180068269043), (u'MNDWI', 0.3222219117328092, -0.04255121251198512), (u'diff', 1196.0942571785267, 0.045470427081376316), (u'MNDWI', 0.3440918146557004, -0.047085347000781985), (u'MNDWI', 0.23474230004124425, 0.04054075125347783), (u'MNDWI', 0.355026766117146, -0.046736584848805475), (u'MNDWI', 0.30035200880991797, 0.04078965556380944), (u'MNDWI', 0.3604942418478688, -0.04776704868198665), (u'LSWIminusNDVI', -0.5568084053554159, -0.04437083563150389), (u'MNDWI', 0.3112869602713636, 0.036248827530157374), (u'MNDWI', 0.36322797971323023, -0.04875479813967596), (u'MNDWI', 0.3167544360020864, 0.04123070622165848), (u'MNDWI', 0.36459484864591096, -0.03810930893128258), (u'diff', 1120.0099875156054, 0.035777913949894054), (u'fai', 829.6922378523481, -0.047446531409649384), (u'diff', 1081.9678526841449, 0.03507927976215228), (u'fai', 953.2060299401292, -0.04108410252021359), (u'b2', 4162.692708333333, 0.04836338373525389), (u'dartmouth', 0.44721897304364455, 0.03740129289331726), (u'dartmouth', 0.3191692014441726, -0.03601093736536919), (u'fai', 1014.9629259840196, -0.03601118264855319), (u'diff', 1158.052122347066, 0.04506611179539899), (u'fai', 1045.841374005965, -0.03593891978458228), (u'diff', 1652.599875156055, 0.03514766129091426), (u'fai', 1061.2805980169376, -0.034972506816040166), (u'fai', 1570.7749903790343, 0.03247104395760117), (u'MNDWI', -0.6042233377129889, 0.03328561186493601), (u'b2', 4091.184895833333, 0.03369074877033)] modis_classifiers['mississippi_5'] = [(u'B5', 22.5, 1.424016860332339)] modis_classifiers['mississippi'] = [(u'B5', 20.25, 1.4064982148857947), (u'NDWI', -0.3488199979104613, -1.1281588137098968), (u'MNDWI', 0.2060761675061745, -0.6204705541547991), (u'NDWI', 0.12342893439063468, -0.43739127359050894), (u'B6', 130.03125, -0.7385587172087229), (u'NDWI', -0.050652615441503096, -0.6351588979749766), (u'MNDWI', 0.0688502702628284, -0.7096006602751659), (u'NDWI', -0.137693390357572, -0.6767143211075154), (u'MNDWI', 0.00023732164115535664, -0.4784325526693348), (u'NDWI', 0.6956693010823654, -0.5175430073894397), (u'B6', 129.515625, -0.7658727652948186), (u'NDWI', 0.5836306675686378, -0.8230539867550758)] modis_classifiers['new_orleans'] = [(u'B4', 13.375, 1.4669571862477135), (u'b2', 1768.9536616979908, 0.7191964118271637), (u'B3', 18.3125, -0.4070155359645522), (u'LSWIminusEVI', -0.08557300521224676, -0.5810809746072104), (u'B4', 10.6875, -0.5291029708890636), (u'NDWI', 0.6135381706131, -0.42333042815387417), (u'MNDWI', -0.6315152257273133, -0.4508129543642559), (u'NDWI', 0.40244384299830177, -0.4529011567813934), (u'MNDWI', -0.7966635966818656, -0.4229803773880765), (u'NDWI', 0.8246324982278983, -0.4069177636794863), (u'MNDWI', -0.8792377821591417, -0.4443473879013045), (u'NDWI', 0.7190853344204992, -0.4883209250265058), (u'MNDWI', -0.9205248748977797, -0.49636567364951045), (u'NDWI', 0.7718589163241987, -0.47532398301078105), (u'MNDWI', -0.9411684212670988, -0.46105794712582865), (u'NDWI', 0.9301796620352974, -0.44708336474163696), (u'MNDWI', -0.9514901944517582, -0.4449868419505934), (u'NDWI', 0.8774060801315979, -0.4471999560229246), (u'MNDWI', -0.956651081044088, -0.44724569495404887), (u'NDWI', 0.8510192891797481, -0.4452132576283198), (u'MNDWI', -0.9592315243402529, -0.4429423461902555), (u'NDWI', 0.8378258937038232, -0.4412914152487152), (u'MNDWI', -0.46636685477276113, -0.44065814160370703), (u'NDWI', 0.7454721253723489, -0.42970202497381904), (u'MNDWI', -0.9605217459883353, -0.48957048644758405), (u'NDWI', 0.8312291959658608, -0.5099369404270232), (u'MNDWI', -0.9611668568123766, -0.5177206937846746), (u'NDWI', 0.8279308470968796, -0.5208055090499037), (u'MNDWI', -0.9614894122243971, -0.5218294172269368), (u'NDWI', 0.8262816726623889, -0.5221839375535151), (u'MNDWI', -0.9616506899304074, -0.5222930845903063), (u'NDWI', 0.8254570854451436, -0.5222798634644608), (u'MNDWI', -0.9617313287834126, -0.5221948879561688), (u'NDWI', 0.8250447918365209, -0.5221108271103068), (u'MNDWI', -0.9617716482099152, -0.5220471206666469), (u'NDWI', 0.8248386450322096, -0.5220049728945718), (u'MNDWI', -0.9617918079231664, -0.5219766049261293), (u'NDWI', 0.824735571630054, -0.5219580845269158), (u'MNDWI', -0.961801887779792, -0.5219465310519422), (u'NDWI', 0.8246840349289761, -0.5219393305356076), (u'MNDWI', -0.9618069277081049, -0.5219349735701074), (u'NDWI', 0.8246582665784372, -0.521932312793635), (u'MNDWI', -0.9618094476722614, -0.5219307253356017)] radar_classifiers['rome'] = [(u'diff', 178.90461847389557, 2.46177797269142), (u'dartmouth', 0.695180948525906, 0.5636808582048225), (u'b2', 3259.75, 0.40623813335255893), (u'vh', 60.0, 0.512954469752306), (u'b1', 600.7550251256282, 0.2801037593761655), (u'diff', 2154.25, 0.22719741605005747), (u'vh', 48.375, 0.1929392221948245), (u'EVI', -0.39797892895956055, -0.26067596700783746), (u'vh', 42.5625, 0.20882052714352622), (u'diff', 263.7538487282463, -0.211052953848031), (u'LSWI', 0.5436867478118161, -0.16553174402115256), (u'diff', 221.32923360107094, -0.15858370383683376), (u'LSWI', 0.45046812317651347, -0.19487772605927273), (u'EVI', -0.40180875045282066, -0.18574586377612953), (u'LSWI', 0.4038588108588621, -0.1607083937449329), (u'dartmouth', 1.0862723406778199, 0.14520750017543604), (u'b1', 365.38253768844226, 0.13710337373549727), (u'diff', 200.11692603748327, -0.12794110582183135), (u'LSWI', 0.38055415470003645, -0.14473310752902216), (u'b1', 1459.25, 0.13486298225301327), (u'MNDWI', 0.45613992940110276, 0.13252409515935595), (u'b1', 483.0687814070352, 0.1234375368417903), (u'vh', 39.65625, 0.10828147089675809), (u'b1', 1653.125, 0.14309662904293483), (u'vh', 30.875, 0.12050226416705825), (u'diff', 189.5107722556894, -0.13029115438110866), (u'dartmouth', 0.567399392562919, 0.12046203774769106), (u'diff', 184.20769536479247, -0.11034439591730216), (u'vh', 33.8125, 0.12078156192671918), (u'EVI', -0.4037236611994507, -0.11025517176478977), (u'LSWIminusEVI', -1.0112946701259427, -0.11523798706849528), (u'diff', 1909.875, -0.10464945907884636), (u'diff', 2032.0625, 0.07976450393456289), (u'dartmouth', 1.15403648079079, -0.1117066685929633), (u'diff', 2093.15625, 0.0968477259918149), (u'b1', 541.9119032663317, 0.07969028249670798), (u'b1', 836.1275125628141, -0.08405908949318663), (u'diff', 181.556156919344, -0.09346085859259494), (u'LSWI', 0.49707743549416483, -0.1085325347020279), (u'EVI', -0.40468111657276573, -0.09747783097236294), (u'vh', 32.34375, 0.09782288286234157), (u'b1', 1750.0625, 0.10205751464991006), (u'b1', 718.4412688442212, -0.09593339090882935), (u'b1', 424.2256595477387, 0.10473543924639585), (u'MNDWI', 0.5560647563672181, 0.06538569127220625), (u'MNDWI', 0.5061023428841604, 0.12118441764008514), (u'vh', 31.609375, 0.1342091965527664), (u'diff', 1787.6875, -0.10241482447678286), (u'MNDWI', 0.5310835496256893, 0.09017490496680071), (u'dartmouth', 1.187918550847275, -0.07281106494462425)] radar_classifiers['malawi'] = [(u'b1', 1206.75, -1.4978661367770034), (u'vv', 92.25, 1.7076910083270624), (u'vv', 155.625, 0.7927423357058031), (u'LSWI', 0.17814903701073945, -0.5656867478534681), (u'b2', 2386.5, 0.39133434117158), (u'vv', 101.625, 0.494237798312077), (u'EVI', 0.29952058003806714, 0.4815500071179563), (u'vv', 106.3125, 0.3791369535317837), (u'LSWIminusNDVI', -0.16354986340261995, -0.3392309042314572), (u'vv', 108.65625, 0.2514716832021546), (u'b2', 2386.75, 0.3450772215737547), (u'vv', 107.484375, 0.2546137126854733), (u'LSWIminusNDVI', -0.16492926771972327, -0.2120703141095119), (u'vv', 106.8984375, 0.1745865336139307), (u'b2', 2386.875, 0.20753425729944486), (u'vv', 106.60546875, 0.17151475757505275), (u'LSWIminusNDVI', -0.16561896987827493, -0.15231935160185775), (u'vv', 106.458984375, 0.13206764439243204), (u'b2', 2386.9375, 0.14843573703920598), (u'vv', 106.3857421875, 0.1291434356120595), (u'LSWIminusNDVI', -0.16596382095755075, -0.11830301992251846), (u'b2', 2242.25, -0.11673694258002199), (u'vv', 154.4375, 0.14908876959293232), (u'LSWI', 0.1611832167953936, -0.13132406390088658), (u'vv', 153.84375, 0.11576377977859459), (u'vv', 106.34912109375, 0.10789584424489668), (u'b2', 2386.96875, 0.09128013378839395), (u'LSWI', 0.1527003066877207, -0.10621539361861156), (u'vv', 153.546875, 0.09035974506503541), (u'LSWI', 0.14845885163388423, -0.08265186904318825), (u'vv', 153.3984375, 0.07612663467721505), (u'vv', 106.330810546875, 0.08087104691133243), (u'EVI', 0.29940517086505597, 0.08383365337627942), (u'vv', 106.3216552734375, 0.0773362495526882), (u'LSWIminusNDVI', -0.16613624649718867, -0.07278061333579333), (u'vv', 106.31707763671875, 0.06783538228239976), (u'b2', 2386.984375, 0.07162768046483561), (u'LSWI', 0.146338124106966, -0.06916246665080311), (u'vv', 153.32421875, 0.06162461812861291), (u'vv', 106.31478881835938, 0.06613725906318095), (u'EVI', 0.29934746627855036, 0.06260671123906972), (u'vv', 106.31364440917969, 0.05891377646208847), (u'b2', 2386.9921875, 0.06026476394466554), (u'LSWI', 0.1452777603435069, -0.05929864988094706), (u'vv', 153.287109375, 0.053562732376205416), (u'vv', 106.31307220458984, 0.05635435997933675), (u'LSWIminusNDVI', -0.16622245926700763, -0.05460616467334437), (u'vv', 106.31278610229492, 0.051776199455337915), (u'b2', 2386.99609375, 0.053322901499510564), (u'LSWI', 0.14580794222523646, -0.05070452620576959)] radar_classifiers['mississippi'] = [(u'NDWI', -0.11622393735660222, -0.8115012757343506), (u'b2', 2985.5263157894738, 0.702679351118156), (u'vv', 5217.619047619048, 0.32062701131953586), (u'MNDWI', 0.26416074525030153, 0.3471969659874681), (u'b1', 1168.775, 0.23958804098018174), (u'b2', 3260.7631578947367, 0.1757460665061179), (u'MNDWI', 0.23640999604191795, 0.16849237965344419), (u'MNDWI', -0.051449424342105275, 0.21073597217765677), (u'LSWIminusNDVI', -0.15381863239050603, 0.261929215268214), (u'MNDWI', 0.10345585696939877, 0.17522339053409086), (u'NDVI', 0.37550520655709846, -0.11678248102474162), (u'ratio', 1.5808138542284427, 0.1307997498783867), (u'MNDWI', 0.22253462143772618, 0.15496439880003274), (u'vv', 23686.289682539682, 0.12065151422211098), (u'LSWIminusNDVI', -0.16578319612225706, 0.10079262433049868), (u'NDWI', 0.01798571473181413, -0.11427381786395764), (u'MNDWI', 0.15605755190146658, 0.12846750517442398), (u'LSWIminusNDVI', -0.15980091425638154, 0.12183307890098613), (u'b2', 3398.3815789473683, 0.0966718411565018), (u'NDWI', -0.035607830086293674, -0.1132584559163686), (u'hv', 4575.416666666667, -0.10741868882123311), (u'NDWI', 0.07157925954992193, -0.10737359754159287), (u'b2', 3467.190789473684, 0.13415083578467207), (u'b1', 1191.3125, -0.11146696782543182), (u'LSWIminusEVI', -2.5247238686545077, 0.11340603990862676), (u'vv', 31272.89484126984, 0.08425074607028928), (u'NDWI', 0.044782487140868035, -0.08653314042576717), (u'b2', 3792.0, 0.1044832325795063), (u'NDVI', 0.43088596754931874, -0.08847969070316128), (u'MNDWI', 0.18235839936750048, 0.07058671161786771), (u'NDWI', 0.058180873345394984, -0.08947323800356782), (u'b2', 3664.0, 0.08796628891143386), (u'NDWI', 0.06488006644765845, -0.07018091636763152), (u'b1', 1180.04375, -0.08727299235554262), (u'LSWIminusNDVI', -0.15680977332344379, 0.08425838412482411), (u'MNDWI', 0.19550882310051743, 0.0619919718523082), (u'NDWI', 0.09837603195897585, -0.08165793068280822), (u'b2', 3600.0, 0.08026689946353305), (u'NDWI', -0.008811057677239772, -0.059679375901025386), (u'hv', 5903.513888888889, -0.06982902975780846), (u'vv', 27479.592261904763, 0.06622628594867959), (u'hv', 51808.0, -0.06271609598725954), (u'vv', 16099.684523809523, -0.06691035524355445), (u'vv', 29376.2435515873, 0.06455229511493261), (u'vv', 19892.9871031746, -0.05233305018274409), (u'b2', 2710.289473684211, 0.05121585389944283), (u'b2', 2847.9078947368425, -0.06272919860762075), (u'b2', 2572.671052631579, 0.083277023990062), (u'b2', 2916.7171052631584, -0.11017977593192452), (u'b2', 2503.8618421052633, 0.08271694814319466)]
def N(): for row in range(7): for col in range(7): if (col==0 or col==6) or row-col==0: print("*",end=" ") else: print(end=" ") print()
def n(): for row in range(7): for col in range(7): if (col == 0 or col == 6) or row - col == 0: print('*', end=' ') else: print(end=' ') print()
a=list(map(int,input().split(',')))[:4] x,y,p,q=a[0],a[1],a[2],a[3] b1,b2,b3=1,1,1 print(b1,'C',x,b2,'H',y,',',b3,',C',p,'H',q) print((b1*x+b2*y),(b3*(p*q))) while (b1*x+b2*y)!=(b3*(p*q)): while b1*x!=b3*p: print('l1') if b1*x!=p: b1+=1 elif x!=b3*p: b3+=1 else: b1+=1 b3+=1 while b2*y!=b3*q: print('l2') if b2*y!=q: b2+=1 elif y!=b3*q: b3+=1 else: b2+=1 b3+=1 print(b1,'C',x,b2,'H',y,',',b3,',C',p,'H',q)
a = list(map(int, input().split(',')))[:4] (x, y, p, q) = (a[0], a[1], a[2], a[3]) (b1, b2, b3) = (1, 1, 1) print(b1, 'C', x, b2, 'H', y, ',', b3, ',C', p, 'H', q) print(b1 * x + b2 * y, b3 * (p * q)) while b1 * x + b2 * y != b3 * (p * q): while b1 * x != b3 * p: print('l1') if b1 * x != p: b1 += 1 elif x != b3 * p: b3 += 1 else: b1 += 1 b3 += 1 while b2 * y != b3 * q: print('l2') if b2 * y != q: b2 += 1 elif y != b3 * q: b3 += 1 else: b2 += 1 b3 += 1 print(b1, 'C', x, b2, 'H', y, ',', b3, ',C', p, 'H', q)
league_schema_name = None def tn(tablename: str) -> str: if league_schema_name is not None: return '`{0}`.`{1}`'.format(league_schema_name, tablename) else: return '`{0}`'.format(tablename)
league_schema_name = None def tn(tablename: str) -> str: if league_schema_name is not None: return '`{0}`.`{1}`'.format(league_schema_name, tablename) else: return '`{0}`'.format(tablename)
A = [1, 2, 3] for i, x in enumerate(A): A[i] += x B = A[0] C = A[0] D: int = 3 while C < A[2]: C += 1 if C == A[2]: print('True') def main(): print("Main started") print(A) print(B) print(C) print(D) if __name__ == '__main__': main()
a = [1, 2, 3] for (i, x) in enumerate(A): A[i] += x b = A[0] c = A[0] d: int = 3 while C < A[2]: c += 1 if C == A[2]: print('True') def main(): print('Main started') print(A) print(B) print(C) print(D) if __name__ == '__main__': main()
# Folders FOLDER_SCHEMA = "graphql" # Packages PACKAGE_RESOLVERS = "resolvers" # Modules MODULE_MODELS = "models" MODULE_DIRECTIVES = "directives" MODULE_SETTINGS = "settings" MODULE_PYDANTIC = "pyd_models"
folder_schema = 'graphql' package_resolvers = 'resolvers' module_models = 'models' module_directives = 'directives' module_settings = 'settings' module_pydantic = 'pyd_models'
# 2. Matching Parentheses # You are given an algebraic expression with parentheses. Scan through the string and extract each set of parentheses. # Print the result back on the console. string = list(input()) stack_index = [] for index in range(len(string)): if string[index] == "(": stack_index.append(index) elif string[index] == ")": start_index = stack_index.pop() end_index = index parentheses_set = string[start_index:end_index+1] print(''.join(parentheses_set))
string = list(input()) stack_index = [] for index in range(len(string)): if string[index] == '(': stack_index.append(index) elif string[index] == ')': start_index = stack_index.pop() end_index = index parentheses_set = string[start_index:end_index + 1] print(''.join(parentheses_set))
# # PySNMP MIB module JUNIPER-FABRIC-CHASSIS (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/JUNIPER-FABRIC-CHASSIS # Produced by pysmi-0.3.4 at Wed May 1 13:59: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) # OctetString, ObjectIdentifier, Integer = mibBuilder.importSymbols("ASN1", "OctetString", "ObjectIdentifier", "Integer") NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues") ConstraintsIntersection, ValueSizeConstraint, ConstraintsUnion, ValueRangeConstraint, SingleValueConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ConstraintsIntersection", "ValueSizeConstraint", "ConstraintsUnion", "ValueRangeConstraint", "SingleValueConstraint") JnxChassisId, = mibBuilder.importSymbols("JUNIPER-MIB", "JnxChassisId") jnxDcfMibRoot, jnxFabricChassisTraps, jnxFabricChassisOKTraps = mibBuilder.importSymbols("JUNIPER-SMI", "jnxDcfMibRoot", "jnxFabricChassisTraps", "jnxFabricChassisOKTraps") NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance") MibIdentifier, ObjectIdentity, ModuleIdentity, Counter32, Integer32, IpAddress, Bits, iso, Counter64, TimeTicks, Gauge32, NotificationType, MibScalar, MibTable, MibTableRow, MibTableColumn, Unsigned32 = mibBuilder.importSymbols("SNMPv2-SMI", "MibIdentifier", "ObjectIdentity", "ModuleIdentity", "Counter32", "Integer32", "IpAddress", "Bits", "iso", "Counter64", "TimeTicks", "Gauge32", "NotificationType", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "Unsigned32") DisplayString, TextualConvention, DateAndTime = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "TextualConvention", "DateAndTime") jnxFabricAnatomy = ModuleIdentity((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2)) jnxFabricAnatomy.setRevisions(('2012-09-13 00:00', '2012-07-26 00:00',)) if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0): if mibBuilder.loadTexts: jnxFabricAnatomy.setRevisionsDescriptions(('Added director group device (DG) enum to JnxFabricContainersFamily.', 'Modified the description for JnxFabricDeviceId. Added ufabric as part of JnxFabricContainersFamily.',)) if mibBuilder.loadTexts: jnxFabricAnatomy.setLastUpdated('201209130000Z') if mibBuilder.loadTexts: jnxFabricAnatomy.setOrganization('Juniper Networks, Inc.') if mibBuilder.loadTexts: jnxFabricAnatomy.setContactInfo(' Juniper Technical Assistance Center Juniper Networks, Inc. 1194 N. Mathilda Avenue Sunnyvale, CA 94089 E-mail: [email protected]') if mibBuilder.loadTexts: jnxFabricAnatomy.setDescription("The MIB modules representing Juniper Networks' Quantum Fabric hardware components.") jnxFabricAnatomyScalars = MibIdentifier((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1)) jnxFabricAnatomyTables = MibIdentifier((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2)) class JnxFabricDeviceId(TextualConvention, Integer32): description = 'The device identifier assigned to the individual devices across the fabric by SFC. This shall be a unique index for each of the devices constituting the fabric.' status = 'current' subtypeSpec = Integer32.subtypeSpec + ValueRangeConstraint(1, 2147483647) class JnxFabricContainersFamily(TextualConvention, Integer32): description = 'The family of container that defines the device.' status = 'current' subtypeSpec = Integer32.subtypeSpec + ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4)) namedValues = NamedValues(("fabricChassis", 1), ("fabricNode", 2), ("ufabric", 3), ("directorGroupDevice", 4)) jnxFabricClass = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 1), ObjectIdentifier()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricClass.setStatus('current') if mibBuilder.loadTexts: jnxFabricClass.setDescription('The product line of the fabric switch.') jnxFabricDescr = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 2), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricDescr.setDescription('The name, model, or detailed description of the fabric, indicating which product the fabric is about.') jnxFabricSerialNo = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 3), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricSerialNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricSerialNo.setDescription('The serial number of this subject, blank if unknown or unavailable.') jnxFabricRevision = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 4), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricRevision.setDescription('The revision of this subject, blank if unknown or unavailable.') jnxFabricFirmwareRevision = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 5), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFirmwareRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricFirmwareRevision.setDescription('The firmware (u-boot) revision of this subject, blank if unknown or unavailable.') jnxFabricLastInstalled = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 6), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricLastInstalled.setStatus('current') if mibBuilder.loadTexts: jnxFabricLastInstalled.setDescription('The value of sysUpTime when the subject was last installed, up-and-running. Zero if unknown or already up-and-running when the agent was up.') jnxFabricContentsLastChange = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 7), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsLastChange.setDescription('The value of sysUpTime when the fabric contents table last changed. Zero if unknown or already existing when the agent was up.') jnxFabricFilledLastChange = MibScalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 8), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledLastChange.setDescription('The value of sysUpTime when the fabric filled status table last changed. Zero if unknown or already at that state when the agent was up.') jnxFabricDeviceTable = MibTable((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1), ) if mibBuilder.loadTexts: jnxFabricDeviceTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceTable.setDescription('A list of fabric device entries.') jnxFabricDeviceEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1), ).setIndexNames((0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex")) if mibBuilder.loadTexts: jnxFabricDeviceEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntry.setDescription('An entry of fabric device table.') jnxFabricDeviceIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 1), JnxFabricDeviceId()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceIndex.setDescription('Identifies the device on which the contents of this row exists.') jnxFabricDeviceEntryContainersFamily = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 2), JnxFabricContainersFamily()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryContainersFamily.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryContainersFamily.setDescription('The family of container that defines this device.') jnxFabricDeviceEntryClass = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 3), ObjectIdentifier()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryClass.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryClass.setDescription('The productline of the device entry.') jnxFabricDeviceEntryModel = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 4), ObjectIdentifier()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryModel.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryModel.setDescription('The model object identifier of the device entry.') jnxFabricDeviceEntryDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 5), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryDescr.setDescription('The name or detailed description of the device entry.') jnxFabricDeviceEntrySerialNo = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 6), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntrySerialNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntrySerialNo.setDescription('The serial number of this subject, blank if unknown or unavailable.') jnxFabricDeviceEntryName = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 7), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryName.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryName.setDescription('The name of this subject which is same as the serial number unless a device alias has been configured.') jnxFabricDeviceEntryRevision = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 8), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryRevision.setDescription('The revision of this subject, blank if unknown or unavailable.') jnxFabricDeviceEntryFirmwareRevision = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 9), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryFirmwareRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryFirmwareRevision.setDescription('The firmware (u-boot) revision of this subject, blank if unknown or unavailable.') jnxFabricDeviceEntryInstalled = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 10), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryInstalled.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryInstalled.setDescription('The value of sysUpTime when the subject was last installed, up-and-running. Zero if unknown or already up-and-running when the agent was up.') jnxFabricDeviceEntryContentsLastChange = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 11), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryContentsLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryContentsLastChange.setDescription('The value of sysUpTime when the contents table last changed. Zero if unknown or already existing when the agent was up.') jnxFabricDeviceEntryFilledLastChange = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 12), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryFilledLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryFilledLastChange.setDescription('The value of sysUpTime when the filled status table last changed. Zero if unknown or already at that state when the agent was up.') jnxFabricDeviceEntryKernelMemoryUsedPercent = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 13), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricDeviceEntryKernelMemoryUsedPercent.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryKernelMemoryUsedPercent.setDescription('The percentage of kernel memory used of this subject. 0 if unavailable or inapplicable.') jnxFabricContainersTable = MibTable((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2), ) if mibBuilder.loadTexts: jnxFabricContainersTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersTable.setDescription('A list of containers entries.') jnxFabricContainersEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1), ).setIndexNames((0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricContainersFamily"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricContainersIndex")) if mibBuilder.loadTexts: jnxFabricContainersEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersEntry.setDescription('An entry of containers table. Each entry is indexed by the container table type and the container index.') jnxFabricContainersFamily = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 1), JnxFabricContainersFamily()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersFamily.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersFamily.setDescription('The family of container.') jnxFabricContainersIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersIndex.setDescription('The index for this entry.') jnxFabricContainersView = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 3), Bits().clone(namedValues=NamedValues(("viewFront", 0), ("viewRear", 1), ("viewTop", 2), ("viewBottom", 3), ("viewLeftHandSide", 4), ("viewRightHandSide", 5)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersView.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersView.setDescription('The view(s) from which the specific container appears. This variable indicates that the specific container is embedded and accessible from the corresponding view(s). The value is a bit map represented as a sum. If multiple bits are set, the specified container(s) are located and accessible from that set of views. The various values representing the bit positions and its corresponding views are: 1 front 2 rear 4 top 8 bottom 16 leftHandSide 32 rightHandSide Note 1: LefHandSide and rightHandSide are referred to based on the view from the front. Note 2: If the specified containers are scattered around various views, the numbering is according to the following sequence: front -> rear -> top -> bottom -> leftHandSide -> rightHandSide For each view plane, the numbering sequence is first from left to right, and then from up to down. Note 3: Even though the value in chassis hardware (e.g. slot number) may be labelled from 0, 1, 2, and up, all the indices in MIB start with 1 (not 0) according to network management convention.') jnxFabricContainersLevel = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 4), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2, 3))).clone(namedValues=NamedValues(("level0", 0), ("level1", 1), ("level2", 2), ("level3", 3)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersLevel.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersLevel.setDescription('The abstraction level of the chassis or device. It is enumerated from the outside to the inside, from the outer layer to the inner layer. For example, top level (i.e. level 0) refers to chassis frame, level 1 FPC slot within chassis frame, level 2 PIC space within FPC slot.') jnxFabricContainersWithin = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 5), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersWithin.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersWithin.setDescription('The index of its next higher level container housing this entry. The associated jnxFabricContainersIndex in the jnxFabricContainersTable represents its next higher level container.') jnxFabricContainersType = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 6), ObjectIdentifier()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersType.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersType.setDescription('The type of this container.') jnxFabricContainersDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 7), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersDescr.setDescription('The name or detailed description of this subject.') jnxFabricContainersCount = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 8), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContainersCount.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersCount.setDescription('The maximum number of containers of this level per container of the next higher level. e.g. if there are six level 2 containers in level 1 container, then jnxFabricContainersCount for level 2 is six.') jnxFabricContentsTable = MibTable((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3), ) if mibBuilder.loadTexts: jnxFabricContentsTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsTable.setDescription('A list of contents entries.') jnxFabricContentsEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1), ).setIndexNames((0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsContainerIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL1Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL2Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL3Index")) if mibBuilder.loadTexts: jnxFabricContentsEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsEntry.setDescription('An entry of contents table.') jnxFabricContentsContainerIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsContainerIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsContainerIndex.setDescription('The associated jnxFabricContainersIndex in the jnxFabricContainersTable.') jnxFabricContentsL1Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsL1Index.setDescription('The level one index of the container housing this subject. Zero if unavailable or inapplicable.') jnxFabricContentsL2Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsL2Index.setDescription('The level two index of the container housing this subject. Zero if unavailable or inapplicable.') jnxFabricContentsL3Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsL3Index.setDescription('The level three index of the container housing this subject. Zero if unavailable or inapplicable.') jnxFabricContentsType = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 5), ObjectIdentifier()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsType.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsType.setDescription('The type of this subject. zeroDotZero if unknown.') jnxFabricContentsDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 6), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsDescr.setDescription('The name or detailed description of this subject.') jnxFabricContentsSerialNo = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 7), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsSerialNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsSerialNo.setDescription('The serial number of this subject, blank if unknown or unavailable.') jnxFabricContentsRevision = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 8), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsRevision.setDescription('The revision of this subject, blank if unknown or unavailable.') jnxFabricContentsInstalled = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 9), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsInstalled.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsInstalled.setDescription('The value of sysUpTime when the subject was last installed, up-and-running. Zero if unknown or already up-and-running when the agent was up.') jnxFabricContentsPartNo = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 10), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsPartNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsPartNo.setDescription('The part number of this subject, blank if unknown or unavailable.') jnxFabricContentsChassisId = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 11), JnxChassisId()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnxFabricContentsChassisDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 12), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnxFabricContentsChassisCleiCode = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 13), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricContentsChassisCleiCode.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsChassisCleiCode.setDescription('The clei code of this subject, blank if unknown or unavailable. A CLEI code is an intelligent code that consists of 10 alphanumeric characters with 4 data elements. The first data element is considered the basic code with the first 2 characters indicating the technology or equipment type, and the third and fourth characters denoting the functional sub-category. The second data element represents the features, and its three characters denote functional capabilities or changes. The third data element has one character and denotes a reference to a manufacturer, system ID, specification, or drawing. The fourth data element consists of two characters and contains complementary data. These two characters provide a means of differentiating or providing uniqueness between the eight character CLEI codes by identifying the manufacturing vintage of the product. Names are assigned via procedures defined in [GR485]. The assigned maintenance agent for the CLEI code, Telcordia Technologies, is responsible for assigning certain equipment and other identifiers (e.g., location, manufacturer/supplier) for the telecommunications industry.') jnxFabricFilledTable = MibTable((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4), ) if mibBuilder.loadTexts: jnxFabricFilledTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledTable.setDescription('A list of filled status entries.') jnxFabricFilledEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1), ).setIndexNames((0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFilledContainerIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFilledL1Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFilledL2Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFilledL3Index")) if mibBuilder.loadTexts: jnxFabricFilledEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledEntry.setDescription('An entry of filled status table.') jnxFabricFilledContainerIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledContainerIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledContainerIndex.setDescription('The associated jnxFabricContainersIndex in the jnxFabricContainersTable.') jnxFabricFilledL1Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledL1Index.setDescription('The level one index of the container housing this subject. Zero if unavailable or inapplicable.') jnxFabricFilledL2Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledL2Index.setDescription('The level two index of the container housing this subject. Zero if unavailable or inapplicable.') jnxFabricFilledL3Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledL3Index.setDescription('The level three index of the container housing this subject. Zero if unavailable or inapplicable.') jnxFabricFilledDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 5), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledDescr.setDescription('The name or detailed description of this subject.') jnxFabricFilledState = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 6), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("unknown", 1), ("empty", 2), ("filled", 3)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledState.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledState.setDescription('The filled state of this subject.') jnxFabricFilledChassisId = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 7), JnxChassisId()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnxFabricFilledChassisDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 8), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFilledChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnxFabricOperatingTable = MibTable((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5), ) if mibBuilder.loadTexts: jnxFabricOperatingTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingTable.setDescription('A list of operating status entries.') jnxFabricOperatingEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1), ).setIndexNames((0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingContentsIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingL1Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingL2Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingL3Index")) if mibBuilder.loadTexts: jnxFabricOperatingEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingEntry.setDescription('An entry of operating status table.') jnxFabricOperatingContentsIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingContentsIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingContentsIndex.setDescription('The associated jnxFabricContentsContainerIndex in the jnxFabricContentsTable.') jnxFabricOperatingL1Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingL1Index.setDescription('The level one index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingL2Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingL2Index.setDescription('The level two index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingL3Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingL3Index.setDescription('The level three index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 5), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingDescr.setDescription('The name or detailed description of this subject.') jnxFabricOperatingState = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 6), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7))).clone(namedValues=NamedValues(("unknown", 1), ("running", 2), ("ready", 3), ("reset", 4), ("runningAtFullSpeed", 5), ("down", 6), ("standby", 7)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingState.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingState.setDescription('The operating state of this subject.') jnxFabricOperatingTemp = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 7), Integer32()).setUnits('Celsius (degrees C)').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingTemp.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingTemp.setDescription('The temperature in Celsius (degrees C) of this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingCPU = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 8), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingCPU.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingCPU.setDescription('The CPU utilization in percentage of this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingISR = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 9), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingISR.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingISR.setDescription('The CPU utilization in percentage of this subject spending in interrupt service routine (ISR). Zero if unavailable or inapplicable.') jnxFabricOperatingDRAMSize = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 10), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingDRAMSize.setStatus('deprecated') if mibBuilder.loadTexts: jnxFabricOperatingDRAMSize.setDescription('The DRAM size in bytes of this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingBuffer = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 11), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingBuffer.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingBuffer.setDescription('The buffer pool utilization in percentage of this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingHeap = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 12), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingHeap.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingHeap.setDescription('The heap utilization in percentage of this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingUpTime = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 13), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingUpTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingUpTime.setDescription('The time interval in 10-millisecond period that this subject has been up and running. Zero if unavailable or inapplicable.') jnxFabricOperatingLastRestart = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 14), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingLastRestart.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingLastRestart.setDescription('The value of sysUpTime when this subject last restarted. Zero if unavailable or inapplicable.') jnxFabricOperatingMemory = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 15), Integer32()).setUnits('Megabytes').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingMemory.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingMemory.setDescription('The installed memory size in Megabytes of this subject. Zero if unavailable or inapplicable.') jnxFabricOperatingStateOrdered = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 16), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7))).clone(namedValues=NamedValues(("running", 1), ("standby", 2), ("ready", 3), ("runningAtFullSpeed", 4), ("reset", 5), ("down", 6), ("unknown", 7)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingStateOrdered.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingStateOrdered.setDescription("The operating state of this subject. Identical to jnxFabricOperatingState, but with enums ordered from 'most operational' to 'least operational' states.") jnxFabricOperatingChassisId = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 17), JnxChassisId()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnxFabricOperatingChassisDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 18), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnxFabricOperatingRestartTime = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 19), DateAndTime()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperatingRestartTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingRestartTime.setDescription('The time at which this entity last restarted.') jnxFabricOperating1MinLoadAvg = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 20), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperating1MinLoadAvg.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperating1MinLoadAvg.setDescription('The CPU Load Average over the last 1 minutes Here it will be shown as percentage value Zero if unavailable or inapplicable.') jnxFabricOperating5MinLoadAvg = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 21), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperating5MinLoadAvg.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperating5MinLoadAvg.setDescription('The CPU Load Average over the last 5 minutes Here it will be shown as percentage value Zero if unavailable or inapplicable.') jnxFabricOperating15MinLoadAvg = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 22), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricOperating15MinLoadAvg.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperating15MinLoadAvg.setDescription('The CPU Load Average over the last 15 minutes Here it will be shown as percentage value Zero if unavailable or inapplicable.') jnxFabricRedundancyTable = MibTable((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6), ) if mibBuilder.loadTexts: jnxFabricRedundancyTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyTable.setDescription('A list of redundancy information entries.') jnxFabricRedundancyEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1), ).setIndexNames((0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyContentsIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyL1Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyL2Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyL3Index")) if mibBuilder.loadTexts: jnxFabricRedundancyEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyEntry.setDescription('An entry in the redundancy information table.') jnxFabricRedundancyContentsIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyContentsIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyContentsIndex.setDescription('The associated jnxFabricContentsContainerIndex in the jnxFabricContentsTable.') jnxFabricRedundancyL1Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyL1Index.setDescription('The level one index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricRedundancyL2Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyL2Index.setDescription('The level two index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricRedundancyL3Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyL3Index.setDescription('The level three index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricRedundancyDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 5), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyDescr.setDescription('The name or detailed description of this subject.') jnxFabricRedundancyConfig = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 6), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5))).clone(namedValues=NamedValues(("unknown", 1), ("master", 2), ("backup", 3), ("disabled", 4), ("notApplicable", 5)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyConfig.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyConfig.setDescription("The election priority of redundancy configuration for this subject. The value 'notApplicable' means no specific instance is configured to be master or backup; whichever component boots up first becomes a master.") jnxFabricRedundancyState = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 7), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("unknown", 1), ("master", 2), ("backup", 3), ("disabled", 4)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyState.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyState.setDescription('The current running state for this subject.') jnxFabricRedundancySwitchoverCount = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 8), Counter32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverCount.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverCount.setDescription('The total number of switchover as perceived by this subject since routing engine is up and running. The switchover is defined as a change in state of jnxFabricRedundancyState from master to backup or vice versa. Its value is reset when the routing engine is reset or rebooted.') jnxFabricRedundancySwitchoverTime = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 9), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverTime.setDescription('The value of sysUpTime when the jnxFabricRedundancyState of this subject was last switched over from master to backup or vice versa. Zero if unknown or never switched over since the routing engine is up and running.') jnxFabricRedundancySwitchoverReason = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 10), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("other", 1), ("neverSwitched", 2), ("userSwitched", 3), ("autoSwitched", 4)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverReason.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverReason.setDescription('The reason of the last switchover for this subject.') jnxFabricRedundancyKeepaliveHeartbeat = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 11), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveHeartbeat.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveHeartbeat.setDescription('The period of sending keepalive messages between the master and backup subsystems. It is a system-wide preset value in seconds used by internal mastership resolution. Zero if unavailable or inapplicable.') jnxFabricRedundancyKeepaliveTimeout = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 12), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveTimeout.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveTimeout.setDescription('The timeout period in seconds, by the keepalive watchdog timer, before initiating a switch over to the backup subsystem. Zero if unavailable or inapplicable.') jnxFabricRedundancyKeepaliveElapsed = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 13), Integer32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveElapsed.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveElapsed.setDescription('The elapsed time in seconds by this subject since receiving the last keepalive message from the other subsystems. Zero if unavailable or inapplicable.') jnxFabricRedundancyKeepaliveLoss = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 14), Counter32()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveLoss.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveLoss.setDescription('The total number of losses on keepalive messages between the master and backup subsystems as perceived by this subject since the system is up and running. Zero if unavailable or inapplicable.') jnxFabricRedundancyChassisId = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 15), JnxChassisId()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnxFabricRedundancyChassisDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 16), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricRedundancyChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnxFabricFruTable = MibTable((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7), ) if mibBuilder.loadTexts: jnxFabricFruTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruTable.setDescription('A list of FRU status entries.') jnxFabricFruEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1), ).setIndexNames((0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), (0, "JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index")) if mibBuilder.loadTexts: jnxFabricFruEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruEntry.setDescription('An entry in the FRU status table.') jnxFabricFruContentsIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruContentsIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruContentsIndex.setDescription('The associated jnxFabricContentsContainerIndex in the jnxFabricContentsTable.') jnxFabricFruL1Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruL1Index.setDescription('The level one index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricFruL2Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruL2Index.setDescription('The level two index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricFruL3Index = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruL3Index.setDescription('The level three index associated with this subject. Zero if unavailable or inapplicable.') jnxFabricFruName = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 5), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruName.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruName.setDescription('The name or detailed description of this subject.') jnxFabricFruType = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 6), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16))).clone(namedValues=NamedValues(("other", 1), ("clockGenerator", 2), ("flexiblePicConcentrator", 3), ("switchingAndForwardingModule", 4), ("controlBoard", 5), ("routingEngine", 6), ("powerEntryModule", 7), ("frontPanelModule", 8), ("switchInterfaceBoard", 9), ("processorMezzanineBoardForSIB", 10), ("portInterfaceCard", 11), ("craftInterfacePanel", 12), ("fan", 13), ("lineCardChassis", 14), ("forwardingEngineBoard", 15), ("protectedSystemDomain", 16)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruType.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruType.setDescription('The FRU type for this subject.') jnxFabricFruSlot = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 2147483647))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruSlot.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruSlot.setDescription('The slot number of this subject. This is equivalent to jnxFabricFruL1Index in meaning. Zero if unavailable or inapplicable.') jnxFabricFruState = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 8), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10))).clone(namedValues=NamedValues(("unknown", 1), ("empty", 2), ("present", 3), ("ready", 4), ("announceOnline", 5), ("online", 6), ("anounceOffline", 7), ("offline", 8), ("diagnostic", 9), ("standby", 10)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruState.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruState.setDescription('The current state for this subject.') jnxFabricFruTemp = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 9), Integer32()).setUnits('Celsius (degrees C)').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruTemp.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruTemp.setDescription('The temperature in Celsius (degrees C) of this subject. Zero if unavailable or inapplicable.') jnxFabricFruOfflineReason = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 10), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75))).clone(namedValues=NamedValues(("unknown", 1), ("none", 2), ("error", 3), ("noPower", 4), ("configPowerOff", 5), ("configHoldInReset", 6), ("cliCommand", 7), ("buttonPress", 8), ("cliRestart", 9), ("overtempShutdown", 10), ("masterClockDown", 11), ("singleSfmModeChange", 12), ("packetSchedulingModeChange", 13), ("physicalRemoval", 14), ("unresponsiveRestart", 15), ("sonetClockAbsent", 16), ("rddPowerOff", 17), ("majorErrors", 18), ("minorErrors", 19), ("lccHardRestart", 20), ("lccVersionMismatch", 21), ("powerCycle", 22), ("reconnect", 23), ("overvoltage", 24), ("pfeVersionMismatch", 25), ("febRddCfgChange", 26), ("fpcMisconfig", 27), ("fruReconnectFail", 28), ("fruFwddReset", 29), ("fruFebSwitch", 30), ("fruFebOffline", 31), ("fruInServSoftUpgradeError", 32), ("fruChasdPowerRatingExceed", 33), ("fruConfigOffline", 34), ("fruServiceRestartRequest", 35), ("spuResetRequest", 36), ("spuFlowdDown", 37), ("spuSpi4Down", 38), ("spuWatchdogTimeout", 39), ("spuCoreDump", 40), ("fpgaSpi4LinkDown", 41), ("i3Spi4LinkDown", 42), ("cppDisconnect", 43), ("cpuNotBoot", 44), ("spuCoreDumpComplete", 45), ("rstOnSpcSpuFailure", 46), ("softRstOnSpcSpuFailure", 47), ("hwAuthenticationFailure", 48), ("reconnectFpcFail", 49), ("fpcAppFailed", 50), ("fpcKernelCrash", 51), ("spuFlowdDownNoCore", 52), ("spuFlowdCoreDumpIncomplete", 53), ("spuFlowdCoreDumpComplete", 54), ("spuIdpdDownNoCore", 55), ("spuIdpdCoreDumpIncomplete", 56), ("spuIdpdCoreDumpComplete", 57), ("spuCoreDumpIncomplete", 58), ("spuIdpdDown", 59), ("fruPfeReset", 60), ("fruReconnectNotReady", 61), ("fruSfLinkDown", 62), ("fruFabricDown", 63), ("fruAntiCounterfeitRetry", 64), ("fruFPCChassisClusterDisable", 65), ("spuFipsError", 66), ("fruFPCFabricDownOffline", 67), ("febCfgChange", 68), ("routeLocalizationRoleChange", 69), ("fruFpcUnsupported", 70), ("psdVersionMismatch", 71), ("fruResetThresholdExceeded", 72), ("picBounce", 73), ("badVoltage", 74), ("fruFPCReducedFabricBW", 75)))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruOfflineReason.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOfflineReason.setDescription('The offline reason of this subject.') jnxFabricFruLastPowerOff = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 11), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruLastPowerOff.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruLastPowerOff.setDescription('The value of sysUpTime when this subject was last powered off. Zero if unavailable or inapplicable.') jnxFabricFruLastPowerOn = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 12), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruLastPowerOn.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruLastPowerOn.setDescription('The value of sysUpTime when this subject was last powered on. Zero if unavailable or inapplicable.') jnxFabricFruPowerUpTime = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 13), TimeTicks()).setUnits('centi-seconds').setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruPowerUpTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPowerUpTime.setDescription('The time interval in 10-millisecond period that this subject has been up and running since the last power on time. Zero if unavailable or inapplicable.') jnxFabricFruChassisId = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 14), JnxChassisId()).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnxFabricFruChassisDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 15), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 255))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnxFabricFruPsdAssignment = MibTableColumn((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 16), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 31))).setMaxAccess("readonly") if mibBuilder.loadTexts: jnxFabricFruPsdAssignment.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPsdAssignment.setDescription('The PSD assignment of this subject. Zero if unavailable or not applicable.') jnxFabricPowerSupplyFailure = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 1)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsContainerIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsDescr"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingState")) if mibBuilder.loadTexts: jnxFabricPowerSupplyFailure.setStatus('current') if mibBuilder.loadTexts: jnxFabricPowerSupplyFailure.setDescription('A jnxFabricPowerSupplyFailure trap signifies that the SNMP entity, acting in an agent role, has detected that the specified power supply in the chassis has been in the failure (bad DC output) condition.') jnxFabricFanFailure = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 2)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsContainerIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsDescr"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingState")) if mibBuilder.loadTexts: jnxFabricFanFailure.setStatus('current') if mibBuilder.loadTexts: jnxFabricFanFailure.setDescription('A jnxFabricFanFailure trap signifies that the SNMP entity, acting in an agent role, has detected that the specified cooling fan or impeller in the chassis has been in the failure (not spinning) condition.') jnxFabricOverTemperature = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 3)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsContainerIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsDescr"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingTemp")) if mibBuilder.loadTexts: jnxFabricOverTemperature.setStatus('current') if mibBuilder.loadTexts: jnxFabricOverTemperature.setDescription('A jnxFabricOverTemperature trap signifies that the SNMP entity, acting in an agent role, has detected that the specified hardware component in the chassis has experienced over temperature condition.') jnxFabricRedundancySwitchover = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 4)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyDescr"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyConfig"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancyState"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancySwitchoverCount"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancySwitchoverTime"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricRedundancySwitchoverReason")) if mibBuilder.loadTexts: jnxFabricRedundancySwitchover.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchover.setDescription('A jnxFabricRedundancySwitchover trap signifies that the SNMP entity, acting in an agent role, has detected that the specified hardware component in the chassis has experienced a redundancy switchover event defined as a change in state of jnxFabricRedundancyState from master to backup or vice versa.') jnxFabricFruRemoval = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 5)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricFruRemoval.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruRemoval.setDescription('A jnxFabricFruRemoval trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been removed from the chassis.') jnxFabricFruInsertion = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 6)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricFruInsertion.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruInsertion.setDescription('A jnxFabricFruInsertion trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been inserted into the chassis.') jnxFabricFruPowerOff = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 7)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruOfflineReason"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruLastPowerOff"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruLastPowerOn")) if mibBuilder.loadTexts: jnxFabricFruPowerOff.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPowerOff.setDescription('A jnxFabricFruPowerOff trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been powered off in the chassis.') jnxFabricFruPowerOn = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 8)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruOfflineReason"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruLastPowerOff"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruLastPowerOn")) if mibBuilder.loadTexts: jnxFabricFruPowerOn.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPowerOn.setDescription('A jnxFabricFruPowerOn trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been powered on in the chassis.') jnxFabricFruFailed = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 9)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricFruFailed.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruFailed.setDescription('This indicates the specified FRU (Field Replaceable Unit) has failed in the chassis. Most probably this is due toi some hard error such as fru is not powering up or not able to load ukernel. In these cases, fru is replaced.') jnxFabricFruOffline = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 10)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruOfflineReason"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruLastPowerOff"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruLastPowerOn")) if mibBuilder.loadTexts: jnxFabricFruOffline.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOffline.setDescription('A jnxFabricFruOffline trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has gone offline in the chassis.') jnxFabricFruOnline = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 11)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricFruOnline.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOnline.setDescription('A jnxFabricFruOnline trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has gone online in the chassis.') jnxFabricFruCheck = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 12)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricFruCheck.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruCheck.setDescription('A jnxFabricFruCheck trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has encountered some operational errors and gone into check state in the chassis.') jnxFabricFEBSwitchover = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 13)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricFEBSwitchover.setStatus('current') if mibBuilder.loadTexts: jnxFabricFEBSwitchover.setDescription('A jnxFabricFEBSwitchover trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FEB (Forwarding Engine Board) has switched over.') jnxFabricHardDiskFailed = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 14)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricHardDiskFailed.setStatus('current') if mibBuilder.loadTexts: jnxFabricHardDiskFailed.setDescription('A jnxHardDiskFailed trap signifies that the SNMP entity, acting in an agent role, has detected that the Disk in the specified Routing Engine has encountered some operational errors and gone into failed state in the chassis.') jnxFabricHardDiskMissing = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 15)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricHardDiskMissing.setStatus('current') if mibBuilder.loadTexts: jnxFabricHardDiskMissing.setDescription('A DiskMissing trap signifies that the SNMP entity, acting in an agent role, has detected that hard disk in the specified outing Engine is missing from boot device list.') jnxFabricBootFromBackup = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 19, 16)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricBootFromBackup.setStatus('current') if mibBuilder.loadTexts: jnxFabricBootFromBackup.setDescription('A jnxBootFromBackup trap signifies that the SNMP entity, acting in an agent role, has detected that the specified routing-engine/member has booted from the back up root partition') jnxFabricPowerSupplyOK = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 20, 1)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsContainerIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsDescr"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingState")) if mibBuilder.loadTexts: jnxFabricPowerSupplyOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricPowerSupplyOK.setDescription('A jnxFabricPowerSupplyOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified power supply in the chassis has recovered from the failure (bad DC output) condition.') jnxFabricFanOK = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 20, 2)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsContainerIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsDescr"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingState")) if mibBuilder.loadTexts: jnxFabricFanOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricFanOK.setDescription('A jnxFabricFanOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified cooling fan or impeller in the chassis has recovered from the failure (not spinning) condition.') jnxFabricTemperatureOK = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 20, 3)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsContainerIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricContentsDescr"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricOperatingTemp")) if mibBuilder.loadTexts: jnxFabricTemperatureOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricTemperatureOK.setDescription('A jnxFabricTemperatureOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified hardware component in the chassis has recovered from over temperature condition.') jnxFabricFruOK = NotificationType((1, 3, 6, 1, 4, 1, 2636, 4, 20, 4)).setObjects(("JUNIPER-FABRIC-CHASSIS", "jnxFabricDeviceIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruContentsIndex"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL1Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL2Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruL3Index"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruName"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruType"), ("JUNIPER-FABRIC-CHASSIS", "jnxFabricFruSlot")) if mibBuilder.loadTexts: jnxFabricFruOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOK.setDescription('A jnxFabricFabricFruOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has recovered from previous operational errors and it is in ok state in the chassis.') mibBuilder.exportSymbols("JUNIPER-FABRIC-CHASSIS", jnxFabricFruL3Index=jnxFabricFruL3Index, jnxFabricDeviceEntryDescr=jnxFabricDeviceEntryDescr, jnxFabricOverTemperature=jnxFabricOverTemperature, jnxFabricDeviceEntrySerialNo=jnxFabricDeviceEntrySerialNo, jnxFabricRedundancyChassisId=jnxFabricRedundancyChassisId, jnxFabricContentsRevision=jnxFabricContentsRevision, jnxFabricOperatingDRAMSize=jnxFabricOperatingDRAMSize, jnxFabricContentsContainerIndex=jnxFabricContentsContainerIndex, jnxFabricOperatingDescr=jnxFabricOperatingDescr, jnxFabricRedundancyKeepaliveElapsed=jnxFabricRedundancyKeepaliveElapsed, jnxFabricFruL1Index=jnxFabricFruL1Index, jnxFabricFruPowerOff=jnxFabricFruPowerOff, jnxFabricRevision=jnxFabricRevision, jnxFabricFilledL1Index=jnxFabricFilledL1Index, jnxFabricRedundancySwitchoverTime=jnxFabricRedundancySwitchoverTime, jnxFabricContainersLevel=jnxFabricContainersLevel, jnxFabricFruCheck=jnxFabricFruCheck, jnxFabricContainersTable=jnxFabricContainersTable, jnxFabricFilledDescr=jnxFabricFilledDescr, jnxFabricContainersFamily=jnxFabricContainersFamily, jnxFabricFilledContainerIndex=jnxFabricFilledContainerIndex, jnxFabricOperating1MinLoadAvg=jnxFabricOperating1MinLoadAvg, jnxFabricContentsL1Index=jnxFabricContentsL1Index, jnxFabricDeviceTable=jnxFabricDeviceTable, jnxFabricDeviceEntryClass=jnxFabricDeviceEntryClass, jnxFabricContainersWithin=jnxFabricContainersWithin, jnxFabricFilledChassisId=jnxFabricFilledChassisId, jnxFabricRedundancyTable=jnxFabricRedundancyTable, jnxFabricOperatingCPU=jnxFabricOperatingCPU, jnxFabricOperatingTable=jnxFabricOperatingTable, jnxFabricRedundancyL3Index=jnxFabricRedundancyL3Index, jnxFabricFanFailure=jnxFabricFanFailure, jnxFabricRedundancyEntry=jnxFabricRedundancyEntry, jnxFabricClass=jnxFabricClass, jnxFabricContentsL3Index=jnxFabricContentsL3Index, jnxFabricDeviceEntryRevision=jnxFabricDeviceEntryRevision, jnxFabricContentsChassisId=jnxFabricContentsChassisId, jnxFabricFruType=jnxFabricFruType, jnxFabricContentsLastChange=jnxFabricContentsLastChange, jnxFabricContentsChassisDescr=jnxFabricContentsChassisDescr, jnxFabricFruRemoval=jnxFabricFruRemoval, jnxFabricDeviceEntryFirmwareRevision=jnxFabricDeviceEntryFirmwareRevision, jnxFabricRedundancyKeepaliveLoss=jnxFabricRedundancyKeepaliveLoss, jnxFabricFruTemp=jnxFabricFruTemp, jnxFabricDescr=jnxFabricDescr, jnxFabricFanOK=jnxFabricFanOK, PYSNMP_MODULE_ID=jnxFabricAnatomy, jnxFabricFruOfflineReason=jnxFabricFruOfflineReason, jnxFabricContainersEntry=jnxFabricContainersEntry, jnxFabricRedundancyState=jnxFabricRedundancyState, jnxFabricOperatingLastRestart=jnxFabricOperatingLastRestart, jnxFabricContentsDescr=jnxFabricContentsDescr, jnxFabricFirmwareRevision=jnxFabricFirmwareRevision, jnxFabricContentsEntry=jnxFabricContentsEntry, jnxFabricRedundancyDescr=jnxFabricRedundancyDescr, jnxFabricDeviceEntryName=jnxFabricDeviceEntryName, jnxFabricOperating15MinLoadAvg=jnxFabricOperating15MinLoadAvg, jnxFabricFilledTable=jnxFabricFilledTable, jnxFabricRedundancySwitchover=jnxFabricRedundancySwitchover, jnxFabricTemperatureOK=jnxFabricTemperatureOK, jnxFabricBootFromBackup=jnxFabricBootFromBackup, jnxFabricAnatomyScalars=jnxFabricAnatomyScalars, jnxFabricDeviceIndex=jnxFabricDeviceIndex, jnxFabricContainersIndex=jnxFabricContainersIndex, jnxFabricFruPsdAssignment=jnxFabricFruPsdAssignment, jnxFabricDeviceEntryKernelMemoryUsedPercent=jnxFabricDeviceEntryKernelMemoryUsedPercent, jnxFabricOperatingChassisDescr=jnxFabricOperatingChassisDescr, jnxFabricFruLastPowerOn=jnxFabricFruLastPowerOn, jnxFabricDeviceEntryModel=jnxFabricDeviceEntryModel, jnxFabricFruSlot=jnxFabricFruSlot, jnxFabricOperatingHeap=jnxFabricOperatingHeap, jnxFabricOperatingL2Index=jnxFabricOperatingL2Index, jnxFabricFilledChassisDescr=jnxFabricFilledChassisDescr, jnxFabricOperatingRestartTime=jnxFabricOperatingRestartTime, jnxFabricFruContentsIndex=jnxFabricFruContentsIndex, jnxFabricOperatingStateOrdered=jnxFabricOperatingStateOrdered, jnxFabricContentsChassisCleiCode=jnxFabricContentsChassisCleiCode, jnxFabricFruInsertion=jnxFabricFruInsertion, jnxFabricRedundancyContentsIndex=jnxFabricRedundancyContentsIndex, jnxFabricFEBSwitchover=jnxFabricFEBSwitchover, jnxFabricFruPowerOn=jnxFabricFruPowerOn, jnxFabricFilledLastChange=jnxFabricFilledLastChange, jnxFabricContainersDescr=jnxFabricContainersDescr, jnxFabricFilledState=jnxFabricFilledState, jnxFabricFruEntry=jnxFabricFruEntry, jnxFabricOperatingState=jnxFabricOperatingState, jnxFabricHardDiskFailed=jnxFabricHardDiskFailed, jnxFabricDeviceEntry=jnxFabricDeviceEntry, jnxFabricFruPowerUpTime=jnxFabricFruPowerUpTime, jnxFabricContentsType=jnxFabricContentsType, jnxFabricContainersCount=jnxFabricContainersCount, jnxFabricOperatingL3Index=jnxFabricOperatingL3Index, jnxFabricRedundancyKeepaliveTimeout=jnxFabricRedundancyKeepaliveTimeout, jnxFabricOperatingUpTime=jnxFabricOperatingUpTime, jnxFabricOperatingISR=jnxFabricOperatingISR, jnxFabricOperatingTemp=jnxFabricOperatingTemp, jnxFabricFruOffline=jnxFabricFruOffline, jnxFabricLastInstalled=jnxFabricLastInstalled, jnxFabricAnatomyTables=jnxFabricAnatomyTables, jnxFabricContentsPartNo=jnxFabricContentsPartNo, jnxFabricRedundancySwitchoverReason=jnxFabricRedundancySwitchoverReason, jnxFabricAnatomy=jnxFabricAnatomy, jnxFabricContentsSerialNo=jnxFabricContentsSerialNo, jnxFabricContentsInstalled=jnxFabricContentsInstalled, jnxFabricFruChassisId=jnxFabricFruChassisId, jnxFabricFruState=jnxFabricFruState, jnxFabricOperatingL1Index=jnxFabricOperatingL1Index, jnxFabricRedundancySwitchoverCount=jnxFabricRedundancySwitchoverCount, jnxFabricFilledEntry=jnxFabricFilledEntry, jnxFabricOperatingEntry=jnxFabricOperatingEntry, jnxFabricRedundancyKeepaliveHeartbeat=jnxFabricRedundancyKeepaliveHeartbeat, jnxFabricFruOnline=jnxFabricFruOnline, jnxFabricDeviceEntryFilledLastChange=jnxFabricDeviceEntryFilledLastChange, jnxFabricDeviceEntryContentsLastChange=jnxFabricDeviceEntryContentsLastChange, jnxFabricOperatingContentsIndex=jnxFabricOperatingContentsIndex, jnxFabricHardDiskMissing=jnxFabricHardDiskMissing, jnxFabricFruL2Index=jnxFabricFruL2Index, jnxFabricContainersView=jnxFabricContainersView, jnxFabricOperatingChassisId=jnxFabricOperatingChassisId, jnxFabricRedundancyChassisDescr=jnxFabricRedundancyChassisDescr, jnxFabricFruFailed=jnxFabricFruFailed, jnxFabricRedundancyConfig=jnxFabricRedundancyConfig, jnxFabricPowerSupplyOK=jnxFabricPowerSupplyOK, jnxFabricOperatingBuffer=jnxFabricOperatingBuffer, jnxFabricSerialNo=jnxFabricSerialNo, jnxFabricDeviceEntryContainersFamily=jnxFabricDeviceEntryContainersFamily, JnxFabricContainersFamily=JnxFabricContainersFamily, jnxFabricOperatingMemory=jnxFabricOperatingMemory, jnxFabricFruChassisDescr=jnxFabricFruChassisDescr, jnxFabricContentsL2Index=jnxFabricContentsL2Index, jnxFabricOperating5MinLoadAvg=jnxFabricOperating5MinLoadAvg, jnxFabricContainersType=jnxFabricContainersType, jnxFabricRedundancyL2Index=jnxFabricRedundancyL2Index, jnxFabricFruLastPowerOff=jnxFabricFruLastPowerOff, jnxFabricDeviceEntryInstalled=jnxFabricDeviceEntryInstalled, jnxFabricFilledL2Index=jnxFabricFilledL2Index, jnxFabricFruTable=jnxFabricFruTable, jnxFabricPowerSupplyFailure=jnxFabricPowerSupplyFailure, JnxFabricDeviceId=JnxFabricDeviceId, jnxFabricRedundancyL1Index=jnxFabricRedundancyL1Index, jnxFabricContentsTable=jnxFabricContentsTable, jnxFabricFruName=jnxFabricFruName, jnxFabricFruOK=jnxFabricFruOK, jnxFabricFilledL3Index=jnxFabricFilledL3Index)
(octet_string, object_identifier, integer) = mibBuilder.importSymbols('ASN1', 'OctetString', 'ObjectIdentifier', 'Integer') (named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues') (constraints_intersection, value_size_constraint, constraints_union, value_range_constraint, single_value_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ConstraintsIntersection', 'ValueSizeConstraint', 'ConstraintsUnion', 'ValueRangeConstraint', 'SingleValueConstraint') (jnx_chassis_id,) = mibBuilder.importSymbols('JUNIPER-MIB', 'JnxChassisId') (jnx_dcf_mib_root, jnx_fabric_chassis_traps, jnx_fabric_chassis_ok_traps) = mibBuilder.importSymbols('JUNIPER-SMI', 'jnxDcfMibRoot', 'jnxFabricChassisTraps', 'jnxFabricChassisOKTraps') (notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance') (mib_identifier, object_identity, module_identity, counter32, integer32, ip_address, bits, iso, counter64, time_ticks, gauge32, notification_type, mib_scalar, mib_table, mib_table_row, mib_table_column, unsigned32) = mibBuilder.importSymbols('SNMPv2-SMI', 'MibIdentifier', 'ObjectIdentity', 'ModuleIdentity', 'Counter32', 'Integer32', 'IpAddress', 'Bits', 'iso', 'Counter64', 'TimeTicks', 'Gauge32', 'NotificationType', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'Unsigned32') (display_string, textual_convention, date_and_time) = mibBuilder.importSymbols('SNMPv2-TC', 'DisplayString', 'TextualConvention', 'DateAndTime') jnx_fabric_anatomy = module_identity((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2)) jnxFabricAnatomy.setRevisions(('2012-09-13 00:00', '2012-07-26 00:00')) if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0): if mibBuilder.loadTexts: jnxFabricAnatomy.setRevisionsDescriptions(('Added director group device (DG) enum to JnxFabricContainersFamily.', 'Modified the description for JnxFabricDeviceId. Added ufabric as part of JnxFabricContainersFamily.')) if mibBuilder.loadTexts: jnxFabricAnatomy.setLastUpdated('201209130000Z') if mibBuilder.loadTexts: jnxFabricAnatomy.setOrganization('Juniper Networks, Inc.') if mibBuilder.loadTexts: jnxFabricAnatomy.setContactInfo(' Juniper Technical Assistance Center Juniper Networks, Inc. 1194 N. Mathilda Avenue Sunnyvale, CA 94089 E-mail: [email protected]') if mibBuilder.loadTexts: jnxFabricAnatomy.setDescription("The MIB modules representing Juniper Networks' Quantum Fabric hardware components.") jnx_fabric_anatomy_scalars = mib_identifier((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1)) jnx_fabric_anatomy_tables = mib_identifier((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2)) class Jnxfabricdeviceid(TextualConvention, Integer32): description = 'The device identifier assigned to the individual devices across the fabric by SFC. This shall be a unique index for each of the devices constituting the fabric.' status = 'current' subtype_spec = Integer32.subtypeSpec + value_range_constraint(1, 2147483647) class Jnxfabriccontainersfamily(TextualConvention, Integer32): description = 'The family of container that defines the device.' status = 'current' subtype_spec = Integer32.subtypeSpec + constraints_union(single_value_constraint(1, 2, 3, 4)) named_values = named_values(('fabricChassis', 1), ('fabricNode', 2), ('ufabric', 3), ('directorGroupDevice', 4)) jnx_fabric_class = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 1), object_identifier()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricClass.setStatus('current') if mibBuilder.loadTexts: jnxFabricClass.setDescription('The product line of the fabric switch.') jnx_fabric_descr = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 2), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricDescr.setDescription('The name, model, or detailed description of the fabric, indicating which product the fabric is about.') jnx_fabric_serial_no = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 3), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricSerialNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricSerialNo.setDescription('The serial number of this subject, blank if unknown or unavailable.') jnx_fabric_revision = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 4), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricRevision.setDescription('The revision of this subject, blank if unknown or unavailable.') jnx_fabric_firmware_revision = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 5), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFirmwareRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricFirmwareRevision.setDescription('The firmware (u-boot) revision of this subject, blank if unknown or unavailable.') jnx_fabric_last_installed = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 6), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricLastInstalled.setStatus('current') if mibBuilder.loadTexts: jnxFabricLastInstalled.setDescription('The value of sysUpTime when the subject was last installed, up-and-running. Zero if unknown or already up-and-running when the agent was up.') jnx_fabric_contents_last_change = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 7), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsLastChange.setDescription('The value of sysUpTime when the fabric contents table last changed. Zero if unknown or already existing when the agent was up.') jnx_fabric_filled_last_change = mib_scalar((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 1, 8), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledLastChange.setDescription('The value of sysUpTime when the fabric filled status table last changed. Zero if unknown or already at that state when the agent was up.') jnx_fabric_device_table = mib_table((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1)) if mibBuilder.loadTexts: jnxFabricDeviceTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceTable.setDescription('A list of fabric device entries.') jnx_fabric_device_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1)).setIndexNames((0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex')) if mibBuilder.loadTexts: jnxFabricDeviceEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntry.setDescription('An entry of fabric device table.') jnx_fabric_device_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 1), jnx_fabric_device_id()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceIndex.setDescription('Identifies the device on which the contents of this row exists.') jnx_fabric_device_entry_containers_family = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 2), jnx_fabric_containers_family()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryContainersFamily.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryContainersFamily.setDescription('The family of container that defines this device.') jnx_fabric_device_entry_class = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 3), object_identifier()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryClass.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryClass.setDescription('The productline of the device entry.') jnx_fabric_device_entry_model = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 4), object_identifier()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryModel.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryModel.setDescription('The model object identifier of the device entry.') jnx_fabric_device_entry_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 5), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryDescr.setDescription('The name or detailed description of the device entry.') jnx_fabric_device_entry_serial_no = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 6), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntrySerialNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntrySerialNo.setDescription('The serial number of this subject, blank if unknown or unavailable.') jnx_fabric_device_entry_name = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 7), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryName.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryName.setDescription('The name of this subject which is same as the serial number unless a device alias has been configured.') jnx_fabric_device_entry_revision = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 8), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryRevision.setDescription('The revision of this subject, blank if unknown or unavailable.') jnx_fabric_device_entry_firmware_revision = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 9), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryFirmwareRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryFirmwareRevision.setDescription('The firmware (u-boot) revision of this subject, blank if unknown or unavailable.') jnx_fabric_device_entry_installed = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 10), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryInstalled.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryInstalled.setDescription('The value of sysUpTime when the subject was last installed, up-and-running. Zero if unknown or already up-and-running when the agent was up.') jnx_fabric_device_entry_contents_last_change = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 11), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryContentsLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryContentsLastChange.setDescription('The value of sysUpTime when the contents table last changed. Zero if unknown or already existing when the agent was up.') jnx_fabric_device_entry_filled_last_change = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 12), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryFilledLastChange.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryFilledLastChange.setDescription('The value of sysUpTime when the filled status table last changed. Zero if unknown or already at that state when the agent was up.') jnx_fabric_device_entry_kernel_memory_used_percent = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 1, 1, 13), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricDeviceEntryKernelMemoryUsedPercent.setStatus('current') if mibBuilder.loadTexts: jnxFabricDeviceEntryKernelMemoryUsedPercent.setDescription('The percentage of kernel memory used of this subject. 0 if unavailable or inapplicable.') jnx_fabric_containers_table = mib_table((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2)) if mibBuilder.loadTexts: jnxFabricContainersTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersTable.setDescription('A list of containers entries.') jnx_fabric_containers_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1)).setIndexNames((0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricContainersFamily'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricContainersIndex')) if mibBuilder.loadTexts: jnxFabricContainersEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersEntry.setDescription('An entry of containers table. Each entry is indexed by the container table type and the container index.') jnx_fabric_containers_family = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 1), jnx_fabric_containers_family()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersFamily.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersFamily.setDescription('The family of container.') jnx_fabric_containers_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersIndex.setDescription('The index for this entry.') jnx_fabric_containers_view = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 3), bits().clone(namedValues=named_values(('viewFront', 0), ('viewRear', 1), ('viewTop', 2), ('viewBottom', 3), ('viewLeftHandSide', 4), ('viewRightHandSide', 5)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersView.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersView.setDescription('The view(s) from which the specific container appears. This variable indicates that the specific container is embedded and accessible from the corresponding view(s). The value is a bit map represented as a sum. If multiple bits are set, the specified container(s) are located and accessible from that set of views. The various values representing the bit positions and its corresponding views are: 1 front 2 rear 4 top 8 bottom 16 leftHandSide 32 rightHandSide Note 1: LefHandSide and rightHandSide are referred to based on the view from the front. Note 2: If the specified containers are scattered around various views, the numbering is according to the following sequence: front -> rear -> top -> bottom -> leftHandSide -> rightHandSide For each view plane, the numbering sequence is first from left to right, and then from up to down. Note 3: Even though the value in chassis hardware (e.g. slot number) may be labelled from 0, 1, 2, and up, all the indices in MIB start with 1 (not 0) according to network management convention.') jnx_fabric_containers_level = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 4), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1, 2, 3))).clone(namedValues=named_values(('level0', 0), ('level1', 1), ('level2', 2), ('level3', 3)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersLevel.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersLevel.setDescription('The abstraction level of the chassis or device. It is enumerated from the outside to the inside, from the outer layer to the inner layer. For example, top level (i.e. level 0) refers to chassis frame, level 1 FPC slot within chassis frame, level 2 PIC space within FPC slot.') jnx_fabric_containers_within = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 5), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersWithin.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersWithin.setDescription('The index of its next higher level container housing this entry. The associated jnxFabricContainersIndex in the jnxFabricContainersTable represents its next higher level container.') jnx_fabric_containers_type = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 6), object_identifier()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersType.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersType.setDescription('The type of this container.') jnx_fabric_containers_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 7), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersDescr.setDescription('The name or detailed description of this subject.') jnx_fabric_containers_count = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 2, 1, 8), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContainersCount.setStatus('current') if mibBuilder.loadTexts: jnxFabricContainersCount.setDescription('The maximum number of containers of this level per container of the next higher level. e.g. if there are six level 2 containers in level 1 container, then jnxFabricContainersCount for level 2 is six.') jnx_fabric_contents_table = mib_table((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3)) if mibBuilder.loadTexts: jnxFabricContentsTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsTable.setDescription('A list of contents entries.') jnx_fabric_contents_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1)).setIndexNames((0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsContainerIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL1Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL2Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL3Index')) if mibBuilder.loadTexts: jnxFabricContentsEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsEntry.setDescription('An entry of contents table.') jnx_fabric_contents_container_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsContainerIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsContainerIndex.setDescription('The associated jnxFabricContainersIndex in the jnxFabricContainersTable.') jnx_fabric_contents_l1_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsL1Index.setDescription('The level one index of the container housing this subject. Zero if unavailable or inapplicable.') jnx_fabric_contents_l2_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsL2Index.setDescription('The level two index of the container housing this subject. Zero if unavailable or inapplicable.') jnx_fabric_contents_l3_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsL3Index.setDescription('The level three index of the container housing this subject. Zero if unavailable or inapplicable.') jnx_fabric_contents_type = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 5), object_identifier()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsType.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsType.setDescription('The type of this subject. zeroDotZero if unknown.') jnx_fabric_contents_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 6), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsDescr.setDescription('The name or detailed description of this subject.') jnx_fabric_contents_serial_no = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 7), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsSerialNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsSerialNo.setDescription('The serial number of this subject, blank if unknown or unavailable.') jnx_fabric_contents_revision = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 8), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsRevision.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsRevision.setDescription('The revision of this subject, blank if unknown or unavailable.') jnx_fabric_contents_installed = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 9), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsInstalled.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsInstalled.setDescription('The value of sysUpTime when the subject was last installed, up-and-running. Zero if unknown or already up-and-running when the agent was up.') jnx_fabric_contents_part_no = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 10), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsPartNo.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsPartNo.setDescription('The part number of this subject, blank if unknown or unavailable.') jnx_fabric_contents_chassis_id = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 11), jnx_chassis_id()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnx_fabric_contents_chassis_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 12), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnx_fabric_contents_chassis_clei_code = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 3, 1, 13), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricContentsChassisCleiCode.setStatus('current') if mibBuilder.loadTexts: jnxFabricContentsChassisCleiCode.setDescription('The clei code of this subject, blank if unknown or unavailable. A CLEI code is an intelligent code that consists of 10 alphanumeric characters with 4 data elements. The first data element is considered the basic code with the first 2 characters indicating the technology or equipment type, and the third and fourth characters denoting the functional sub-category. The second data element represents the features, and its three characters denote functional capabilities or changes. The third data element has one character and denotes a reference to a manufacturer, system ID, specification, or drawing. The fourth data element consists of two characters and contains complementary data. These two characters provide a means of differentiating or providing uniqueness between the eight character CLEI codes by identifying the manufacturing vintage of the product. Names are assigned via procedures defined in [GR485]. The assigned maintenance agent for the CLEI code, Telcordia Technologies, is responsible for assigning certain equipment and other identifiers (e.g., location, manufacturer/supplier) for the telecommunications industry.') jnx_fabric_filled_table = mib_table((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4)) if mibBuilder.loadTexts: jnxFabricFilledTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledTable.setDescription('A list of filled status entries.') jnx_fabric_filled_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1)).setIndexNames((0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFilledContainerIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFilledL1Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFilledL2Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFilledL3Index')) if mibBuilder.loadTexts: jnxFabricFilledEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledEntry.setDescription('An entry of filled status table.') jnx_fabric_filled_container_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledContainerIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledContainerIndex.setDescription('The associated jnxFabricContainersIndex in the jnxFabricContainersTable.') jnx_fabric_filled_l1_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledL1Index.setDescription('The level one index of the container housing this subject. Zero if unavailable or inapplicable.') jnx_fabric_filled_l2_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledL2Index.setDescription('The level two index of the container housing this subject. Zero if unavailable or inapplicable.') jnx_fabric_filled_l3_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledL3Index.setDescription('The level three index of the container housing this subject. Zero if unavailable or inapplicable.') jnx_fabric_filled_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 5), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledDescr.setDescription('The name or detailed description of this subject.') jnx_fabric_filled_state = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 6), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('unknown', 1), ('empty', 2), ('filled', 3)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledState.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledState.setDescription('The filled state of this subject.') jnx_fabric_filled_chassis_id = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 7), jnx_chassis_id()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnx_fabric_filled_chassis_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 4, 1, 8), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFilledChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricFilledChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnx_fabric_operating_table = mib_table((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5)) if mibBuilder.loadTexts: jnxFabricOperatingTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingTable.setDescription('A list of operating status entries.') jnx_fabric_operating_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1)).setIndexNames((0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingContentsIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingL1Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingL2Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingL3Index')) if mibBuilder.loadTexts: jnxFabricOperatingEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingEntry.setDescription('An entry of operating status table.') jnx_fabric_operating_contents_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingContentsIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingContentsIndex.setDescription('The associated jnxFabricContentsContainerIndex in the jnxFabricContentsTable.') jnx_fabric_operating_l1_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingL1Index.setDescription('The level one index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_l2_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingL2Index.setDescription('The level two index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_l3_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingL3Index.setDescription('The level three index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 5), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingDescr.setDescription('The name or detailed description of this subject.') jnx_fabric_operating_state = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 6), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7))).clone(namedValues=named_values(('unknown', 1), ('running', 2), ('ready', 3), ('reset', 4), ('runningAtFullSpeed', 5), ('down', 6), ('standby', 7)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingState.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingState.setDescription('The operating state of this subject.') jnx_fabric_operating_temp = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 7), integer32()).setUnits('Celsius (degrees C)').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingTemp.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingTemp.setDescription('The temperature in Celsius (degrees C) of this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_cpu = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 8), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingCPU.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingCPU.setDescription('The CPU utilization in percentage of this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_isr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 9), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingISR.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingISR.setDescription('The CPU utilization in percentage of this subject spending in interrupt service routine (ISR). Zero if unavailable or inapplicable.') jnx_fabric_operating_dram_size = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 10), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingDRAMSize.setStatus('deprecated') if mibBuilder.loadTexts: jnxFabricOperatingDRAMSize.setDescription('The DRAM size in bytes of this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_buffer = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 11), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingBuffer.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingBuffer.setDescription('The buffer pool utilization in percentage of this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_heap = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 12), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingHeap.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingHeap.setDescription('The heap utilization in percentage of this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_up_time = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 13), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingUpTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingUpTime.setDescription('The time interval in 10-millisecond period that this subject has been up and running. Zero if unavailable or inapplicable.') jnx_fabric_operating_last_restart = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 14), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingLastRestart.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingLastRestart.setDescription('The value of sysUpTime when this subject last restarted. Zero if unavailable or inapplicable.') jnx_fabric_operating_memory = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 15), integer32()).setUnits('Megabytes').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingMemory.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingMemory.setDescription('The installed memory size in Megabytes of this subject. Zero if unavailable or inapplicable.') jnx_fabric_operating_state_ordered = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 16), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7))).clone(namedValues=named_values(('running', 1), ('standby', 2), ('ready', 3), ('runningAtFullSpeed', 4), ('reset', 5), ('down', 6), ('unknown', 7)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingStateOrdered.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingStateOrdered.setDescription("The operating state of this subject. Identical to jnxFabricOperatingState, but with enums ordered from 'most operational' to 'least operational' states.") jnx_fabric_operating_chassis_id = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 17), jnx_chassis_id()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnx_fabric_operating_chassis_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 18), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnx_fabric_operating_restart_time = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 19), date_and_time()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperatingRestartTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperatingRestartTime.setDescription('The time at which this entity last restarted.') jnx_fabric_operating1_min_load_avg = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 20), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperating1MinLoadAvg.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperating1MinLoadAvg.setDescription('The CPU Load Average over the last 1 minutes Here it will be shown as percentage value Zero if unavailable or inapplicable.') jnx_fabric_operating5_min_load_avg = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 21), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperating5MinLoadAvg.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperating5MinLoadAvg.setDescription('The CPU Load Average over the last 5 minutes Here it will be shown as percentage value Zero if unavailable or inapplicable.') jnx_fabric_operating15_min_load_avg = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 5, 1, 22), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricOperating15MinLoadAvg.setStatus('current') if mibBuilder.loadTexts: jnxFabricOperating15MinLoadAvg.setDescription('The CPU Load Average over the last 15 minutes Here it will be shown as percentage value Zero if unavailable or inapplicable.') jnx_fabric_redundancy_table = mib_table((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6)) if mibBuilder.loadTexts: jnxFabricRedundancyTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyTable.setDescription('A list of redundancy information entries.') jnx_fabric_redundancy_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1)).setIndexNames((0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyContentsIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyL1Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyL2Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyL3Index')) if mibBuilder.loadTexts: jnxFabricRedundancyEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyEntry.setDescription('An entry in the redundancy information table.') jnx_fabric_redundancy_contents_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyContentsIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyContentsIndex.setDescription('The associated jnxFabricContentsContainerIndex in the jnxFabricContentsTable.') jnx_fabric_redundancy_l1_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyL1Index.setDescription('The level one index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_redundancy_l2_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyL2Index.setDescription('The level two index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_redundancy_l3_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyL3Index.setDescription('The level three index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_redundancy_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 5), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyDescr.setDescription('The name or detailed description of this subject.') jnx_fabric_redundancy_config = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 6), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5))).clone(namedValues=named_values(('unknown', 1), ('master', 2), ('backup', 3), ('disabled', 4), ('notApplicable', 5)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyConfig.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyConfig.setDescription("The election priority of redundancy configuration for this subject. The value 'notApplicable' means no specific instance is configured to be master or backup; whichever component boots up first becomes a master.") jnx_fabric_redundancy_state = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 7), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4))).clone(namedValues=named_values(('unknown', 1), ('master', 2), ('backup', 3), ('disabled', 4)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyState.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyState.setDescription('The current running state for this subject.') jnx_fabric_redundancy_switchover_count = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 8), counter32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverCount.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverCount.setDescription('The total number of switchover as perceived by this subject since routing engine is up and running. The switchover is defined as a change in state of jnxFabricRedundancyState from master to backup or vice versa. Its value is reset when the routing engine is reset or rebooted.') jnx_fabric_redundancy_switchover_time = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 9), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverTime.setDescription('The value of sysUpTime when the jnxFabricRedundancyState of this subject was last switched over from master to backup or vice versa. Zero if unknown or never switched over since the routing engine is up and running.') jnx_fabric_redundancy_switchover_reason = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 10), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4))).clone(namedValues=named_values(('other', 1), ('neverSwitched', 2), ('userSwitched', 3), ('autoSwitched', 4)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverReason.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchoverReason.setDescription('The reason of the last switchover for this subject.') jnx_fabric_redundancy_keepalive_heartbeat = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 11), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveHeartbeat.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveHeartbeat.setDescription('The period of sending keepalive messages between the master and backup subsystems. It is a system-wide preset value in seconds used by internal mastership resolution. Zero if unavailable or inapplicable.') jnx_fabric_redundancy_keepalive_timeout = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 12), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveTimeout.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveTimeout.setDescription('The timeout period in seconds, by the keepalive watchdog timer, before initiating a switch over to the backup subsystem. Zero if unavailable or inapplicable.') jnx_fabric_redundancy_keepalive_elapsed = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 13), integer32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveElapsed.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveElapsed.setDescription('The elapsed time in seconds by this subject since receiving the last keepalive message from the other subsystems. Zero if unavailable or inapplicable.') jnx_fabric_redundancy_keepalive_loss = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 14), counter32()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveLoss.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyKeepaliveLoss.setDescription('The total number of losses on keepalive messages between the master and backup subsystems as perceived by this subject since the system is up and running. Zero if unavailable or inapplicable.') jnx_fabric_redundancy_chassis_id = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 15), jnx_chassis_id()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnx_fabric_redundancy_chassis_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 6, 1, 16), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricRedundancyChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancyChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnx_fabric_fru_table = mib_table((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7)) if mibBuilder.loadTexts: jnxFabricFruTable.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruTable.setDescription('A list of FRU status entries.') jnx_fabric_fru_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1)).setIndexNames((0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), (0, 'JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index')) if mibBuilder.loadTexts: jnxFabricFruEntry.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruEntry.setDescription('An entry in the FRU status table.') jnx_fabric_fru_contents_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruContentsIndex.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruContentsIndex.setDescription('The associated jnxFabricContentsContainerIndex in the jnxFabricContentsTable.') jnx_fabric_fru_l1_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruL1Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruL1Index.setDescription('The level one index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_fru_l2_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruL2Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruL2Index.setDescription('The level two index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_fru_l3_index = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruL3Index.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruL3Index.setDescription('The level three index associated with this subject. Zero if unavailable or inapplicable.') jnx_fabric_fru_name = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 5), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruName.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruName.setDescription('The name or detailed description of this subject.') jnx_fabric_fru_type = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 6), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16))).clone(namedValues=named_values(('other', 1), ('clockGenerator', 2), ('flexiblePicConcentrator', 3), ('switchingAndForwardingModule', 4), ('controlBoard', 5), ('routingEngine', 6), ('powerEntryModule', 7), ('frontPanelModule', 8), ('switchInterfaceBoard', 9), ('processorMezzanineBoardForSIB', 10), ('portInterfaceCard', 11), ('craftInterfacePanel', 12), ('fan', 13), ('lineCardChassis', 14), ('forwardingEngineBoard', 15), ('protectedSystemDomain', 16)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruType.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruType.setDescription('The FRU type for this subject.') jnx_fabric_fru_slot = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 2147483647))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruSlot.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruSlot.setDescription('The slot number of this subject. This is equivalent to jnxFabricFruL1Index in meaning. Zero if unavailable or inapplicable.') jnx_fabric_fru_state = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 8), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10))).clone(namedValues=named_values(('unknown', 1), ('empty', 2), ('present', 3), ('ready', 4), ('announceOnline', 5), ('online', 6), ('anounceOffline', 7), ('offline', 8), ('diagnostic', 9), ('standby', 10)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruState.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruState.setDescription('The current state for this subject.') jnx_fabric_fru_temp = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 9), integer32()).setUnits('Celsius (degrees C)').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruTemp.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruTemp.setDescription('The temperature in Celsius (degrees C) of this subject. Zero if unavailable or inapplicable.') jnx_fabric_fru_offline_reason = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 10), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75))).clone(namedValues=named_values(('unknown', 1), ('none', 2), ('error', 3), ('noPower', 4), ('configPowerOff', 5), ('configHoldInReset', 6), ('cliCommand', 7), ('buttonPress', 8), ('cliRestart', 9), ('overtempShutdown', 10), ('masterClockDown', 11), ('singleSfmModeChange', 12), ('packetSchedulingModeChange', 13), ('physicalRemoval', 14), ('unresponsiveRestart', 15), ('sonetClockAbsent', 16), ('rddPowerOff', 17), ('majorErrors', 18), ('minorErrors', 19), ('lccHardRestart', 20), ('lccVersionMismatch', 21), ('powerCycle', 22), ('reconnect', 23), ('overvoltage', 24), ('pfeVersionMismatch', 25), ('febRddCfgChange', 26), ('fpcMisconfig', 27), ('fruReconnectFail', 28), ('fruFwddReset', 29), ('fruFebSwitch', 30), ('fruFebOffline', 31), ('fruInServSoftUpgradeError', 32), ('fruChasdPowerRatingExceed', 33), ('fruConfigOffline', 34), ('fruServiceRestartRequest', 35), ('spuResetRequest', 36), ('spuFlowdDown', 37), ('spuSpi4Down', 38), ('spuWatchdogTimeout', 39), ('spuCoreDump', 40), ('fpgaSpi4LinkDown', 41), ('i3Spi4LinkDown', 42), ('cppDisconnect', 43), ('cpuNotBoot', 44), ('spuCoreDumpComplete', 45), ('rstOnSpcSpuFailure', 46), ('softRstOnSpcSpuFailure', 47), ('hwAuthenticationFailure', 48), ('reconnectFpcFail', 49), ('fpcAppFailed', 50), ('fpcKernelCrash', 51), ('spuFlowdDownNoCore', 52), ('spuFlowdCoreDumpIncomplete', 53), ('spuFlowdCoreDumpComplete', 54), ('spuIdpdDownNoCore', 55), ('spuIdpdCoreDumpIncomplete', 56), ('spuIdpdCoreDumpComplete', 57), ('spuCoreDumpIncomplete', 58), ('spuIdpdDown', 59), ('fruPfeReset', 60), ('fruReconnectNotReady', 61), ('fruSfLinkDown', 62), ('fruFabricDown', 63), ('fruAntiCounterfeitRetry', 64), ('fruFPCChassisClusterDisable', 65), ('spuFipsError', 66), ('fruFPCFabricDownOffline', 67), ('febCfgChange', 68), ('routeLocalizationRoleChange', 69), ('fruFpcUnsupported', 70), ('psdVersionMismatch', 71), ('fruResetThresholdExceeded', 72), ('picBounce', 73), ('badVoltage', 74), ('fruFPCReducedFabricBW', 75)))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruOfflineReason.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOfflineReason.setDescription('The offline reason of this subject.') jnx_fabric_fru_last_power_off = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 11), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruLastPowerOff.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruLastPowerOff.setDescription('The value of sysUpTime when this subject was last powered off. Zero if unavailable or inapplicable.') jnx_fabric_fru_last_power_on = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 12), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruLastPowerOn.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruLastPowerOn.setDescription('The value of sysUpTime when this subject was last powered on. Zero if unavailable or inapplicable.') jnx_fabric_fru_power_up_time = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 13), time_ticks()).setUnits('centi-seconds').setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruPowerUpTime.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPowerUpTime.setDescription('The time interval in 10-millisecond period that this subject has been up and running since the last power on time. Zero if unavailable or inapplicable.') jnx_fabric_fru_chassis_id = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 14), jnx_chassis_id()).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruChassisId.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruChassisId.setDescription('Identifies the chassis on which the contents of this row exists.') jnx_fabric_fru_chassis_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 15), display_string().subtype(subtypeSpec=value_size_constraint(0, 255))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruChassisDescr.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruChassisDescr.setDescription('A textual description of the chassis on which the contents of this row exists.') jnx_fabric_fru_psd_assignment = mib_table_column((1, 3, 6, 1, 4, 1, 2636, 3, 42, 2, 2, 7, 1, 16), integer32().subtype(subtypeSpec=value_range_constraint(0, 31))).setMaxAccess('readonly') if mibBuilder.loadTexts: jnxFabricFruPsdAssignment.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPsdAssignment.setDescription('The PSD assignment of this subject. Zero if unavailable or not applicable.') jnx_fabric_power_supply_failure = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 1)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsContainerIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsDescr'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingState')) if mibBuilder.loadTexts: jnxFabricPowerSupplyFailure.setStatus('current') if mibBuilder.loadTexts: jnxFabricPowerSupplyFailure.setDescription('A jnxFabricPowerSupplyFailure trap signifies that the SNMP entity, acting in an agent role, has detected that the specified power supply in the chassis has been in the failure (bad DC output) condition.') jnx_fabric_fan_failure = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 2)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsContainerIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsDescr'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingState')) if mibBuilder.loadTexts: jnxFabricFanFailure.setStatus('current') if mibBuilder.loadTexts: jnxFabricFanFailure.setDescription('A jnxFabricFanFailure trap signifies that the SNMP entity, acting in an agent role, has detected that the specified cooling fan or impeller in the chassis has been in the failure (not spinning) condition.') jnx_fabric_over_temperature = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 3)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsContainerIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsDescr'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingTemp')) if mibBuilder.loadTexts: jnxFabricOverTemperature.setStatus('current') if mibBuilder.loadTexts: jnxFabricOverTemperature.setDescription('A jnxFabricOverTemperature trap signifies that the SNMP entity, acting in an agent role, has detected that the specified hardware component in the chassis has experienced over temperature condition.') jnx_fabric_redundancy_switchover = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 4)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyDescr'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyConfig'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancyState'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancySwitchoverCount'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancySwitchoverTime'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricRedundancySwitchoverReason')) if mibBuilder.loadTexts: jnxFabricRedundancySwitchover.setStatus('current') if mibBuilder.loadTexts: jnxFabricRedundancySwitchover.setDescription('A jnxFabricRedundancySwitchover trap signifies that the SNMP entity, acting in an agent role, has detected that the specified hardware component in the chassis has experienced a redundancy switchover event defined as a change in state of jnxFabricRedundancyState from master to backup or vice versa.') jnx_fabric_fru_removal = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 5)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricFruRemoval.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruRemoval.setDescription('A jnxFabricFruRemoval trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been removed from the chassis.') jnx_fabric_fru_insertion = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 6)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricFruInsertion.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruInsertion.setDescription('A jnxFabricFruInsertion trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been inserted into the chassis.') jnx_fabric_fru_power_off = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 7)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruOfflineReason'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruLastPowerOff'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruLastPowerOn')) if mibBuilder.loadTexts: jnxFabricFruPowerOff.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPowerOff.setDescription('A jnxFabricFruPowerOff trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been powered off in the chassis.') jnx_fabric_fru_power_on = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 8)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruOfflineReason'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruLastPowerOff'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruLastPowerOn')) if mibBuilder.loadTexts: jnxFabricFruPowerOn.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruPowerOn.setDescription('A jnxFabricFruPowerOn trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has been powered on in the chassis.') jnx_fabric_fru_failed = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 9)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricFruFailed.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruFailed.setDescription('This indicates the specified FRU (Field Replaceable Unit) has failed in the chassis. Most probably this is due toi some hard error such as fru is not powering up or not able to load ukernel. In these cases, fru is replaced.') jnx_fabric_fru_offline = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 10)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruOfflineReason'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruLastPowerOff'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruLastPowerOn')) if mibBuilder.loadTexts: jnxFabricFruOffline.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOffline.setDescription('A jnxFabricFruOffline trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has gone offline in the chassis.') jnx_fabric_fru_online = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 11)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricFruOnline.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOnline.setDescription('A jnxFabricFruOnline trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has gone online in the chassis.') jnx_fabric_fru_check = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 12)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricFruCheck.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruCheck.setDescription('A jnxFabricFruCheck trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has encountered some operational errors and gone into check state in the chassis.') jnx_fabric_feb_switchover = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 13)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricFEBSwitchover.setStatus('current') if mibBuilder.loadTexts: jnxFabricFEBSwitchover.setDescription('A jnxFabricFEBSwitchover trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FEB (Forwarding Engine Board) has switched over.') jnx_fabric_hard_disk_failed = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 14)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricHardDiskFailed.setStatus('current') if mibBuilder.loadTexts: jnxFabricHardDiskFailed.setDescription('A jnxHardDiskFailed trap signifies that the SNMP entity, acting in an agent role, has detected that the Disk in the specified Routing Engine has encountered some operational errors and gone into failed state in the chassis.') jnx_fabric_hard_disk_missing = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 15)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricHardDiskMissing.setStatus('current') if mibBuilder.loadTexts: jnxFabricHardDiskMissing.setDescription('A DiskMissing trap signifies that the SNMP entity, acting in an agent role, has detected that hard disk in the specified outing Engine is missing from boot device list.') jnx_fabric_boot_from_backup = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 19, 16)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricBootFromBackup.setStatus('current') if mibBuilder.loadTexts: jnxFabricBootFromBackup.setDescription('A jnxBootFromBackup trap signifies that the SNMP entity, acting in an agent role, has detected that the specified routing-engine/member has booted from the back up root partition') jnx_fabric_power_supply_ok = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 20, 1)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsContainerIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsDescr'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingState')) if mibBuilder.loadTexts: jnxFabricPowerSupplyOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricPowerSupplyOK.setDescription('A jnxFabricPowerSupplyOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified power supply in the chassis has recovered from the failure (bad DC output) condition.') jnx_fabric_fan_ok = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 20, 2)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsContainerIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsDescr'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingState')) if mibBuilder.loadTexts: jnxFabricFanOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricFanOK.setDescription('A jnxFabricFanOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified cooling fan or impeller in the chassis has recovered from the failure (not spinning) condition.') jnx_fabric_temperature_ok = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 20, 3)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsContainerIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricContentsDescr'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricOperatingTemp')) if mibBuilder.loadTexts: jnxFabricTemperatureOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricTemperatureOK.setDescription('A jnxFabricTemperatureOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified hardware component in the chassis has recovered from over temperature condition.') jnx_fabric_fru_ok = notification_type((1, 3, 6, 1, 4, 1, 2636, 4, 20, 4)).setObjects(('JUNIPER-FABRIC-CHASSIS', 'jnxFabricDeviceIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruContentsIndex'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL1Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL2Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruL3Index'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruName'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruType'), ('JUNIPER-FABRIC-CHASSIS', 'jnxFabricFruSlot')) if mibBuilder.loadTexts: jnxFabricFruOK.setStatus('current') if mibBuilder.loadTexts: jnxFabricFruOK.setDescription('A jnxFabricFabricFruOK trap signifies that the SNMP entity, acting in an agent role, has detected that the specified FRU (Field Replaceable Unit) has recovered from previous operational errors and it is in ok state in the chassis.') mibBuilder.exportSymbols('JUNIPER-FABRIC-CHASSIS', jnxFabricFruL3Index=jnxFabricFruL3Index, jnxFabricDeviceEntryDescr=jnxFabricDeviceEntryDescr, jnxFabricOverTemperature=jnxFabricOverTemperature, jnxFabricDeviceEntrySerialNo=jnxFabricDeviceEntrySerialNo, jnxFabricRedundancyChassisId=jnxFabricRedundancyChassisId, jnxFabricContentsRevision=jnxFabricContentsRevision, jnxFabricOperatingDRAMSize=jnxFabricOperatingDRAMSize, jnxFabricContentsContainerIndex=jnxFabricContentsContainerIndex, jnxFabricOperatingDescr=jnxFabricOperatingDescr, jnxFabricRedundancyKeepaliveElapsed=jnxFabricRedundancyKeepaliveElapsed, jnxFabricFruL1Index=jnxFabricFruL1Index, jnxFabricFruPowerOff=jnxFabricFruPowerOff, jnxFabricRevision=jnxFabricRevision, jnxFabricFilledL1Index=jnxFabricFilledL1Index, jnxFabricRedundancySwitchoverTime=jnxFabricRedundancySwitchoverTime, jnxFabricContainersLevel=jnxFabricContainersLevel, jnxFabricFruCheck=jnxFabricFruCheck, jnxFabricContainersTable=jnxFabricContainersTable, jnxFabricFilledDescr=jnxFabricFilledDescr, jnxFabricContainersFamily=jnxFabricContainersFamily, jnxFabricFilledContainerIndex=jnxFabricFilledContainerIndex, jnxFabricOperating1MinLoadAvg=jnxFabricOperating1MinLoadAvg, jnxFabricContentsL1Index=jnxFabricContentsL1Index, jnxFabricDeviceTable=jnxFabricDeviceTable, jnxFabricDeviceEntryClass=jnxFabricDeviceEntryClass, jnxFabricContainersWithin=jnxFabricContainersWithin, jnxFabricFilledChassisId=jnxFabricFilledChassisId, jnxFabricRedundancyTable=jnxFabricRedundancyTable, jnxFabricOperatingCPU=jnxFabricOperatingCPU, jnxFabricOperatingTable=jnxFabricOperatingTable, jnxFabricRedundancyL3Index=jnxFabricRedundancyL3Index, jnxFabricFanFailure=jnxFabricFanFailure, jnxFabricRedundancyEntry=jnxFabricRedundancyEntry, jnxFabricClass=jnxFabricClass, jnxFabricContentsL3Index=jnxFabricContentsL3Index, jnxFabricDeviceEntryRevision=jnxFabricDeviceEntryRevision, jnxFabricContentsChassisId=jnxFabricContentsChassisId, jnxFabricFruType=jnxFabricFruType, jnxFabricContentsLastChange=jnxFabricContentsLastChange, jnxFabricContentsChassisDescr=jnxFabricContentsChassisDescr, jnxFabricFruRemoval=jnxFabricFruRemoval, jnxFabricDeviceEntryFirmwareRevision=jnxFabricDeviceEntryFirmwareRevision, jnxFabricRedundancyKeepaliveLoss=jnxFabricRedundancyKeepaliveLoss, jnxFabricFruTemp=jnxFabricFruTemp, jnxFabricDescr=jnxFabricDescr, jnxFabricFanOK=jnxFabricFanOK, PYSNMP_MODULE_ID=jnxFabricAnatomy, jnxFabricFruOfflineReason=jnxFabricFruOfflineReason, jnxFabricContainersEntry=jnxFabricContainersEntry, jnxFabricRedundancyState=jnxFabricRedundancyState, jnxFabricOperatingLastRestart=jnxFabricOperatingLastRestart, jnxFabricContentsDescr=jnxFabricContentsDescr, jnxFabricFirmwareRevision=jnxFabricFirmwareRevision, jnxFabricContentsEntry=jnxFabricContentsEntry, jnxFabricRedundancyDescr=jnxFabricRedundancyDescr, jnxFabricDeviceEntryName=jnxFabricDeviceEntryName, jnxFabricOperating15MinLoadAvg=jnxFabricOperating15MinLoadAvg, jnxFabricFilledTable=jnxFabricFilledTable, jnxFabricRedundancySwitchover=jnxFabricRedundancySwitchover, jnxFabricTemperatureOK=jnxFabricTemperatureOK, jnxFabricBootFromBackup=jnxFabricBootFromBackup, jnxFabricAnatomyScalars=jnxFabricAnatomyScalars, jnxFabricDeviceIndex=jnxFabricDeviceIndex, jnxFabricContainersIndex=jnxFabricContainersIndex, jnxFabricFruPsdAssignment=jnxFabricFruPsdAssignment, jnxFabricDeviceEntryKernelMemoryUsedPercent=jnxFabricDeviceEntryKernelMemoryUsedPercent, jnxFabricOperatingChassisDescr=jnxFabricOperatingChassisDescr, jnxFabricFruLastPowerOn=jnxFabricFruLastPowerOn, jnxFabricDeviceEntryModel=jnxFabricDeviceEntryModel, jnxFabricFruSlot=jnxFabricFruSlot, jnxFabricOperatingHeap=jnxFabricOperatingHeap, jnxFabricOperatingL2Index=jnxFabricOperatingL2Index, jnxFabricFilledChassisDescr=jnxFabricFilledChassisDescr, jnxFabricOperatingRestartTime=jnxFabricOperatingRestartTime, jnxFabricFruContentsIndex=jnxFabricFruContentsIndex, jnxFabricOperatingStateOrdered=jnxFabricOperatingStateOrdered, jnxFabricContentsChassisCleiCode=jnxFabricContentsChassisCleiCode, jnxFabricFruInsertion=jnxFabricFruInsertion, jnxFabricRedundancyContentsIndex=jnxFabricRedundancyContentsIndex, jnxFabricFEBSwitchover=jnxFabricFEBSwitchover, jnxFabricFruPowerOn=jnxFabricFruPowerOn, jnxFabricFilledLastChange=jnxFabricFilledLastChange, jnxFabricContainersDescr=jnxFabricContainersDescr, jnxFabricFilledState=jnxFabricFilledState, jnxFabricFruEntry=jnxFabricFruEntry, jnxFabricOperatingState=jnxFabricOperatingState, jnxFabricHardDiskFailed=jnxFabricHardDiskFailed, jnxFabricDeviceEntry=jnxFabricDeviceEntry, jnxFabricFruPowerUpTime=jnxFabricFruPowerUpTime, jnxFabricContentsType=jnxFabricContentsType, jnxFabricContainersCount=jnxFabricContainersCount, jnxFabricOperatingL3Index=jnxFabricOperatingL3Index, jnxFabricRedundancyKeepaliveTimeout=jnxFabricRedundancyKeepaliveTimeout, jnxFabricOperatingUpTime=jnxFabricOperatingUpTime, jnxFabricOperatingISR=jnxFabricOperatingISR, jnxFabricOperatingTemp=jnxFabricOperatingTemp, jnxFabricFruOffline=jnxFabricFruOffline, jnxFabricLastInstalled=jnxFabricLastInstalled, jnxFabricAnatomyTables=jnxFabricAnatomyTables, jnxFabricContentsPartNo=jnxFabricContentsPartNo, jnxFabricRedundancySwitchoverReason=jnxFabricRedundancySwitchoverReason, jnxFabricAnatomy=jnxFabricAnatomy, jnxFabricContentsSerialNo=jnxFabricContentsSerialNo, jnxFabricContentsInstalled=jnxFabricContentsInstalled, jnxFabricFruChassisId=jnxFabricFruChassisId, jnxFabricFruState=jnxFabricFruState, jnxFabricOperatingL1Index=jnxFabricOperatingL1Index, jnxFabricRedundancySwitchoverCount=jnxFabricRedundancySwitchoverCount, jnxFabricFilledEntry=jnxFabricFilledEntry, jnxFabricOperatingEntry=jnxFabricOperatingEntry, jnxFabricRedundancyKeepaliveHeartbeat=jnxFabricRedundancyKeepaliveHeartbeat, jnxFabricFruOnline=jnxFabricFruOnline, jnxFabricDeviceEntryFilledLastChange=jnxFabricDeviceEntryFilledLastChange, jnxFabricDeviceEntryContentsLastChange=jnxFabricDeviceEntryContentsLastChange, jnxFabricOperatingContentsIndex=jnxFabricOperatingContentsIndex, jnxFabricHardDiskMissing=jnxFabricHardDiskMissing, jnxFabricFruL2Index=jnxFabricFruL2Index, jnxFabricContainersView=jnxFabricContainersView, jnxFabricOperatingChassisId=jnxFabricOperatingChassisId, jnxFabricRedundancyChassisDescr=jnxFabricRedundancyChassisDescr, jnxFabricFruFailed=jnxFabricFruFailed, jnxFabricRedundancyConfig=jnxFabricRedundancyConfig, jnxFabricPowerSupplyOK=jnxFabricPowerSupplyOK, jnxFabricOperatingBuffer=jnxFabricOperatingBuffer, jnxFabricSerialNo=jnxFabricSerialNo, jnxFabricDeviceEntryContainersFamily=jnxFabricDeviceEntryContainersFamily, JnxFabricContainersFamily=JnxFabricContainersFamily, jnxFabricOperatingMemory=jnxFabricOperatingMemory, jnxFabricFruChassisDescr=jnxFabricFruChassisDescr, jnxFabricContentsL2Index=jnxFabricContentsL2Index, jnxFabricOperating5MinLoadAvg=jnxFabricOperating5MinLoadAvg, jnxFabricContainersType=jnxFabricContainersType, jnxFabricRedundancyL2Index=jnxFabricRedundancyL2Index, jnxFabricFruLastPowerOff=jnxFabricFruLastPowerOff, jnxFabricDeviceEntryInstalled=jnxFabricDeviceEntryInstalled, jnxFabricFilledL2Index=jnxFabricFilledL2Index, jnxFabricFruTable=jnxFabricFruTable, jnxFabricPowerSupplyFailure=jnxFabricPowerSupplyFailure, JnxFabricDeviceId=JnxFabricDeviceId, jnxFabricRedundancyL1Index=jnxFabricRedundancyL1Index, jnxFabricContentsTable=jnxFabricContentsTable, jnxFabricFruName=jnxFabricFruName, jnxFabricFruOK=jnxFabricFruOK, jnxFabricFilledL3Index=jnxFabricFilledL3Index)
class Solution: def minPathSum(self, grid: List[List[int]]) -> int: rows=len(grid) columns=len(grid[0]) for i in range(1,columns): grid[0][i]+=grid[0][i-1] for j in range(1,rows): grid[j][0]+=grid[j-1][0] for k in range(1,rows): for l in range(1,columns): grid[k][l]+=min(grid[k][l-1],grid[k-1][l]) return grid[-1][-1]
class Solution: def min_path_sum(self, grid: List[List[int]]) -> int: rows = len(grid) columns = len(grid[0]) for i in range(1, columns): grid[0][i] += grid[0][i - 1] for j in range(1, rows): grid[j][0] += grid[j - 1][0] for k in range(1, rows): for l in range(1, columns): grid[k][l] += min(grid[k][l - 1], grid[k - 1][l]) return grid[-1][-1]
''' Take two sorted linked lists L, R and return the merge of L and R Notes: * when declaring a python class, inherit from object if not otherwise specified * in the python class __init__ function, self is a required first argument * next is a reserved name (iterator method) in python. use the variable name next_node for the pointer field instead. * what went right * used dummy linked list head pattern * bugs * forgot to advance the merged list node pointer variable ''' class LinkedListNode(object): def __init__(self, val, next_node=None): self.val = val self.next_node = next_node def print_nodes(self): print(self.val) if self.next_node is not None: self.next_node.print_nodes() def merge_lists(l, r): dummy_head = LinkedListNode(0) node = dummy_head while True: if l is None: node.next_node = r break if r is None: node.next_node = l break if l.val < r.val: node.next_node = l l = l.next_node else: node.next_node = r r = r.next_node node = node.next_node return dummy_head.next_node def create_list_from_arr(arr): dummy_head = LinkedListNode(0) node = dummy_head for el in arr: next_node = LinkedListNode(el) node.next_node = next_node node = next_node return dummy_head.next_node if __name__ == '__main__': test_cases = [ ([1,4,6,10], [2,3,5]), ([1,4,6,10], []), ([], [2,3,5]), ([1,2,3], [4,5,6]), ] for t in test_cases: l = create_list_from_arr(t[0]) r = create_list_from_arr(t[1]) print(t) merge_lists(l,r).print_nodes()
""" Take two sorted linked lists L, R and return the merge of L and R Notes: * when declaring a python class, inherit from object if not otherwise specified * in the python class __init__ function, self is a required first argument * next is a reserved name (iterator method) in python. use the variable name next_node for the pointer field instead. * what went right * used dummy linked list head pattern * bugs * forgot to advance the merged list node pointer variable """ class Linkedlistnode(object): def __init__(self, val, next_node=None): self.val = val self.next_node = next_node def print_nodes(self): print(self.val) if self.next_node is not None: self.next_node.print_nodes() def merge_lists(l, r): dummy_head = linked_list_node(0) node = dummy_head while True: if l is None: node.next_node = r break if r is None: node.next_node = l break if l.val < r.val: node.next_node = l l = l.next_node else: node.next_node = r r = r.next_node node = node.next_node return dummy_head.next_node def create_list_from_arr(arr): dummy_head = linked_list_node(0) node = dummy_head for el in arr: next_node = linked_list_node(el) node.next_node = next_node node = next_node return dummy_head.next_node if __name__ == '__main__': test_cases = [([1, 4, 6, 10], [2, 3, 5]), ([1, 4, 6, 10], []), ([], [2, 3, 5]), ([1, 2, 3], [4, 5, 6])] for t in test_cases: l = create_list_from_arr(t[0]) r = create_list_from_arr(t[1]) print(t) merge_lists(l, r).print_nodes()
PRED_TYPE = 'Basic' TTA_PRED_TYPE = 'TTA' ENS_TYPE = 'Ens' MEGA_ENS_TYPE = 'MegaEns'
pred_type = 'Basic' tta_pred_type = 'TTA' ens_type = 'Ens' mega_ens_type = 'MegaEns'
class Application: def __init__(self, owner, raw): self.id = raw['app_id'] self.owner_id = raw['owner_id'] self._update(owner, raw) def _update(self, owner, raw): self._raw = raw self.owner = owner self.name = raw['name'] self.type = raw['type'] self.token = raw['token'] self.description = raw.get('description') @property def as_json(self): return { 'id': str(self.id), 'owner_id': str(self.owner_id), 'description': self.description, 'name': self.name, 'owner': self.owner.as_json, 'token': self.token, }
class Application: def __init__(self, owner, raw): self.id = raw['app_id'] self.owner_id = raw['owner_id'] self._update(owner, raw) def _update(self, owner, raw): self._raw = raw self.owner = owner self.name = raw['name'] self.type = raw['type'] self.token = raw['token'] self.description = raw.get('description') @property def as_json(self): return {'id': str(self.id), 'owner_id': str(self.owner_id), 'description': self.description, 'name': self.name, 'owner': self.owner.as_json, 'token': self.token}
# AUTOGENERATED! DO NOT EDIT! File to edit: 00_core.ipynb (unless otherwise specified). __all__ = ['a'] # Cell def a(b): "qgerhwtejyrkafher arerhtrw" return 10
__all__ = ['a'] def a(b): """qgerhwtejyrkafher arerhtrw""" return 10
print ("Hello there welcome to Medieval Village.") print ("You have a village that you need to take care of. Choose one of the options to keep the village in good shape 1) Plant and harvest the crops 2) Use resources from the forest near the village 3) Get your defenses up") user_choice = input() user_choice = int(user_choice) if user_choice == 1: print("You planted and harvested the crops!") print("Now choose from: 2) Use resources from the forest near the village or 3) Get your defenses up ") user_choice1 = input() user_choice1 = int(user_choice1) if user_choice1 == 2 : print("You used the resources in the forest.") print("Now 3) Get your defenses up") user_choice12 = input() user_choice12 = int(user_choice12) if user_choice12 == 3 : print("You got your defenses up! Your village holds strong agianst its invaders!") print("Your village is strong! You have nothing to worry about! Game over") elif user_choice1 == 3 : print("You got your defenses up! Your village holds strong agianst its invaders!") print("Now 2) Use resources from the forest near the village") user_choice13 = input() user_choice13 = int(user_choice13) if user_choice13 == 2: print("You used resources from the forest.") print("Your village is strong! You have nothing to worry about! Game over") elif user_choice == 2 : print("You used the resources in the forest.") print("Now choose from: 1) Plant and harvest the crops or 3) Get your defenses up") user_choice2 = input() user_choice2 = int(user_choice2) if user_choice2 == 1: print("You harvested the crops!") print("Now 3) Get your defenses up") user_choice21 = input() user_choice21 = int(user_choice21) if user_choice21 == 3: print("You got your defenses up! Your village holds strong agianst its invaders!") print("Your village is strong! You have nothing to worry about! Game over") elif user_choice2 == 3: print("You got your defenses up! Your village holds strong agianst its invaders!") print("Now 1) Plant and harvest the crops") user_choice23 = input() user_choice23 = int(user_choice23) if user_choice23 == 1: print("You harvested the crops!") print("Your village is strong! You have nothing to worry about! Game over") elif user_choice == 3: print("You got your defenses up! Your village holds strong agianst its invaders!") print("Now choose from: 1) Plant and harvest the crops or 2) Use resources from the forest near the village") user_choice3 = input() user_choice3 = int(user_choice3) if user_choice3 == 1: print("You harvested the crops!") print("Now 2) Use resources from the forest near the village") user_choice31 = input() user_choice31 = int(user_choice31) if user_choice31 == 2: print("You used resources from the forest near the village.") print("Your village is strong! You have nothing to worry about! Game over") elif user_choice3 == 2: print("You used resources from the forest near the village.") print("Now 1) Plant and harvest the crops") user_choice32 = input() user_choice32 = int(user_choice32) if user_choice32 == 1: print("You harvested the crops!") print("Your village is strong! You have nothing to worry about! Game over") else : print ("Invalid entry try again!")
print('Hello there welcome to Medieval Village.') print('You have a village that you need to take care of. Choose one of the options to keep the village in good shape 1) Plant and harvest the crops 2) Use resources from the forest near the village 3) Get your defenses up') user_choice = input() user_choice = int(user_choice) if user_choice == 1: print('You planted and harvested the crops!') print('Now choose from: 2) Use resources from the forest near the village or 3) Get your defenses up ') user_choice1 = input() user_choice1 = int(user_choice1) if user_choice1 == 2: print('You used the resources in the forest.') print('Now 3) Get your defenses up') user_choice12 = input() user_choice12 = int(user_choice12) if user_choice12 == 3: print('You got your defenses up! Your village holds strong agianst its invaders!') print('Your village is strong! You have nothing to worry about! Game over') elif user_choice1 == 3: print('You got your defenses up! Your village holds strong agianst its invaders!') print('Now 2) Use resources from the forest near the village') user_choice13 = input() user_choice13 = int(user_choice13) if user_choice13 == 2: print('You used resources from the forest.') print('Your village is strong! You have nothing to worry about! Game over') elif user_choice == 2: print('You used the resources in the forest.') print('Now choose from: 1) Plant and harvest the crops or 3) Get your defenses up') user_choice2 = input() user_choice2 = int(user_choice2) if user_choice2 == 1: print('You harvested the crops!') print('Now 3) Get your defenses up') user_choice21 = input() user_choice21 = int(user_choice21) if user_choice21 == 3: print('You got your defenses up! Your village holds strong agianst its invaders!') print('Your village is strong! You have nothing to worry about! Game over') elif user_choice2 == 3: print('You got your defenses up! Your village holds strong agianst its invaders!') print('Now 1) Plant and harvest the crops') user_choice23 = input() user_choice23 = int(user_choice23) if user_choice23 == 1: print('You harvested the crops!') print('Your village is strong! You have nothing to worry about! Game over') elif user_choice == 3: print('You got your defenses up! Your village holds strong agianst its invaders!') print('Now choose from: 1) Plant and harvest the crops or 2) Use resources from the forest near the village') user_choice3 = input() user_choice3 = int(user_choice3) if user_choice3 == 1: print('You harvested the crops!') print('Now 2) Use resources from the forest near the village') user_choice31 = input() user_choice31 = int(user_choice31) if user_choice31 == 2: print('You used resources from the forest near the village.') print('Your village is strong! You have nothing to worry about! Game over') elif user_choice3 == 2: print('You used resources from the forest near the village.') print('Now 1) Plant and harvest the crops') user_choice32 = input() user_choice32 = int(user_choice32) if user_choice32 == 1: print('You harvested the crops!') print('Your village is strong! You have nothing to worry about! Game over') else: print('Invalid entry try again!')
def solution(board, moves): # At first, make stack of each columns boardStack = [[] for _ in range(len(board[0]))] for row in board[::-1]: # Watch out, column index is subtracted by -1 for column, element in enumerate(row): if element != 0: boardStack[column].append(element) bucketStack = []; exploded = 0; for move in moves: if boardStack[(move - 1)]: pick = boardStack[(move - 1)].pop() if bucketStack: if bucketStack[-1] == pick: bucketStack.pop() exploded += 2 else: bucketStack.append(pick) else: bucketStack.append(pick) return exploded
def solution(board, moves): board_stack = [[] for _ in range(len(board[0]))] for row in board[::-1]: for (column, element) in enumerate(row): if element != 0: boardStack[column].append(element) bucket_stack = [] exploded = 0 for move in moves: if boardStack[move - 1]: pick = boardStack[move - 1].pop() if bucketStack: if bucketStack[-1] == pick: bucketStack.pop() exploded += 2 else: bucketStack.append(pick) else: bucketStack.append(pick) return exploded
repeat = int(input()) for x in range(repeat): inlist = list(map( int, input().split())) inlen = inlist.pop(0) avg = sum(inlist)//inlen inlist.sort() for i in range(inlen): if inlist[i] > avg: result = (inlen-i)/inlen *100 break result = 0 print("%.3f"%result, "%",sep="")
repeat = int(input()) for x in range(repeat): inlist = list(map(int, input().split())) inlen = inlist.pop(0) avg = sum(inlist) // inlen inlist.sort() for i in range(inlen): if inlist[i] > avg: result = (inlen - i) / inlen * 100 break result = 0 print('%.3f' % result, '%', sep='')
#!/usr/bin/env python # # Copyright 2009-2020 NTESS. Under the terms # of Contract DE-NA0003525 with NTESS, the U.S. # Government retains certain rights in this software. # # Copyright (c) 2009-2020, NTESS # All rights reserved. # # Portions are copyright of other developers: # See the file CONTRIBUTORS.TXT in the top level directory # the distribution for more information. # # This file is part of the SST software package. For license # information, see the LICENSE file in the top level directory of the # distribution. clock = "100MHz" memory_clock = "100MHz" coherence_protocol = "MSI" memory_backend = "timing" memory_controllers_per_group = 1 groups = 8 memory_capacity = 16384 * 4 # Size of memory in MBs cpu_params = { "verbose" : 0, "printStats" : 1, } l1cache_params = { "clock" : clock, "coherence_protocol": coherence_protocol, "cache_frequency": clock, "replacement_policy": "lru", "cache_size": "32KB", "maxRequestDelay" : "10000", "associativity": 8, "cache_line_size": 64, "access_latency_cycles": 1, "L1": 1, "debug": "0" } bus_params = { "bus_frequency" : memory_clock } l2cache_params = { "clock" : clock, "coherence_protocol": coherence_protocol, "cache_frequency": clock, "replacement_policy": "lru", "cache_size": "32KB", "associativity": 8, "cache_line_size": 64, "access_latency_cycles": 1, "debug": "0" } memory_params = { "coherence_protocol" : coherence_protocol, "rangeStart" : 0, "clock" : memory_clock, "addr_range_start" : 0, "addr_range_end" : (memory_capacity // (groups * memory_controllers_per_group) ) * 1024*1024, } memory_backend_params = { "id" : 0, "clock" : "1333MHz", "mem_size" : str( memory_capacity // (groups * memory_controllers_per_group)) + "MiB", "max_requests_per_cycle": "-1", "addrMapper" : "memHierarchy.roundRobinAddrMapper", "addrMapper.interleave_size" : "64B", "addrMapper.row_size" : "1KiB", "channels" : 8, "channel.transaction_Q_size" : 32, "channel.numRanks" : 8, "channel.rank.numBanks" : 16, "channel.rank.bank.CL" : 12, "channel.rank.bank.CL_WR" : 10, "channel.rank.bank.RCD" : 12, "channel.rank.bank.TRP" : 12, "channel.rank.bank.dataCycles" : 2, "channel.rank.bank.pagePolicy" : "memHierarchy.simplePagePolicy", "channel.rank.bank.transactionQ" : "memHierarchy.reorderTransactionQ", "channel.rank.bank.pagePolicy.close" : 0, "printconfig" : 1, "channel.printconfig" : 0, "channel.rank.printconfig" : 0, "channel.rank.bank.printconfig" : 0, } params = { "numThreads" : 1, "cpu_params" : cpu_params, "l1_params" : l1cache_params, "bus_params" : bus_params, "l2_params" : l2cache_params, "nic_cpu_params" : cpu_params, "nic_l1_params" : l1cache_params, "memory_params" : memory_params, "memory_backend": memory_backend, "memory_backend_params" : memory_backend_params, }
clock = '100MHz' memory_clock = '100MHz' coherence_protocol = 'MSI' memory_backend = 'timing' memory_controllers_per_group = 1 groups = 8 memory_capacity = 16384 * 4 cpu_params = {'verbose': 0, 'printStats': 1} l1cache_params = {'clock': clock, 'coherence_protocol': coherence_protocol, 'cache_frequency': clock, 'replacement_policy': 'lru', 'cache_size': '32KB', 'maxRequestDelay': '10000', 'associativity': 8, 'cache_line_size': 64, 'access_latency_cycles': 1, 'L1': 1, 'debug': '0'} bus_params = {'bus_frequency': memory_clock} l2cache_params = {'clock': clock, 'coherence_protocol': coherence_protocol, 'cache_frequency': clock, 'replacement_policy': 'lru', 'cache_size': '32KB', 'associativity': 8, 'cache_line_size': 64, 'access_latency_cycles': 1, 'debug': '0'} memory_params = {'coherence_protocol': coherence_protocol, 'rangeStart': 0, 'clock': memory_clock, 'addr_range_start': 0, 'addr_range_end': memory_capacity // (groups * memory_controllers_per_group) * 1024 * 1024} memory_backend_params = {'id': 0, 'clock': '1333MHz', 'mem_size': str(memory_capacity // (groups * memory_controllers_per_group)) + 'MiB', 'max_requests_per_cycle': '-1', 'addrMapper': 'memHierarchy.roundRobinAddrMapper', 'addrMapper.interleave_size': '64B', 'addrMapper.row_size': '1KiB', 'channels': 8, 'channel.transaction_Q_size': 32, 'channel.numRanks': 8, 'channel.rank.numBanks': 16, 'channel.rank.bank.CL': 12, 'channel.rank.bank.CL_WR': 10, 'channel.rank.bank.RCD': 12, 'channel.rank.bank.TRP': 12, 'channel.rank.bank.dataCycles': 2, 'channel.rank.bank.pagePolicy': 'memHierarchy.simplePagePolicy', 'channel.rank.bank.transactionQ': 'memHierarchy.reorderTransactionQ', 'channel.rank.bank.pagePolicy.close': 0, 'printconfig': 1, 'channel.printconfig': 0, 'channel.rank.printconfig': 0, 'channel.rank.bank.printconfig': 0} params = {'numThreads': 1, 'cpu_params': cpu_params, 'l1_params': l1cache_params, 'bus_params': bus_params, 'l2_params': l2cache_params, 'nic_cpu_params': cpu_params, 'nic_l1_params': l1cache_params, 'memory_params': memory_params, 'memory_backend': memory_backend, 'memory_backend_params': memory_backend_params}
class TBikeTruck: def __init__(self, id, capacity, init_location): self.id = id self.capacity = capacity self.location = init_location self.bikes_count = 0 self.distance = 0 def to_json(self): return { 'id': self.id, 'location_id': self.location.id, 'loaded_bikes_count': self.bikes_count } def go_up(self): loc = self.location.at_top() if loc is not None: self.location = loc self.distance += 1 def go_down(self): loc = self.location.at_bottom() if loc is not None: self.location = loc self.distance += 1 def go_left(self): loc = self.location.at_left() if loc is not None: self.location = loc self.distance += 1 def go_right(self): loc = self.location.at_right() if loc is not None: self.location = loc self.distance += 1 def load_bike(self): if self.location.bikes_count > 0 and self.bikes_count < self.capacity: self.location.bikes_count -= 1 self.bikes_count += 1 def unload_bike(self): if self.bikes_count > 0: self.location.bikes_count += 1 self.bikes_count -= 1
class Tbiketruck: def __init__(self, id, capacity, init_location): self.id = id self.capacity = capacity self.location = init_location self.bikes_count = 0 self.distance = 0 def to_json(self): return {'id': self.id, 'location_id': self.location.id, 'loaded_bikes_count': self.bikes_count} def go_up(self): loc = self.location.at_top() if loc is not None: self.location = loc self.distance += 1 def go_down(self): loc = self.location.at_bottom() if loc is not None: self.location = loc self.distance += 1 def go_left(self): loc = self.location.at_left() if loc is not None: self.location = loc self.distance += 1 def go_right(self): loc = self.location.at_right() if loc is not None: self.location = loc self.distance += 1 def load_bike(self): if self.location.bikes_count > 0 and self.bikes_count < self.capacity: self.location.bikes_count -= 1 self.bikes_count += 1 def unload_bike(self): if self.bikes_count > 0: self.location.bikes_count += 1 self.bikes_count -= 1
class Stack: topIndex = 0 items = [None] * 64 def push(self, item): self.topIndex += 1 self.items[self.topIndex] = item def pop(self): if self.topIndex == 0: return None else: itemToReturn = self.items[self.topIndex] self.topIndex -= 1 return itemToReturn def peek(self): if self.topIndex == 0: return None else: return self.items[self.topIndex]
class Stack: top_index = 0 items = [None] * 64 def push(self, item): self.topIndex += 1 self.items[self.topIndex] = item def pop(self): if self.topIndex == 0: return None else: item_to_return = self.items[self.topIndex] self.topIndex -= 1 return itemToReturn def peek(self): if self.topIndex == 0: return None else: return self.items[self.topIndex]
# Cheering Expression (6510) rinz = 2012007 scissorhands = 1162003 sweetness = 5160021 sm.setSpeakerID(rinz) sm.sendNext("Welcome! What can I do for you today? ...A gift? For me? " "Wow, a customer's never given me a gift before!") sm.giveItem(sweetness) sm.completeQuest(parentID) sm.consumeItem(scissorhands) sm.sendNext(''.join(["WOW! #t", repr(scissorhands), "#?! " "The material...the color...the sound of the blades snipping together... " "It's so beautiful! Thank you so much! You're the best, #h #! \r\n\r\n" "#fUI/UIWindow2.img/QuestIcon/4/0# \r\n" "#i", repr(sweetness), "# #t", repr(sweetness), "# x 1"])) sm.setPlayerAsSpeaker() sm.sendSay("#b(You learned the Cheering Expression from Rinz the Assistant.)")
rinz = 2012007 scissorhands = 1162003 sweetness = 5160021 sm.setSpeakerID(rinz) sm.sendNext("Welcome! What can I do for you today? ...A gift? For me? Wow, a customer's never given me a gift before!") sm.giveItem(sweetness) sm.completeQuest(parentID) sm.consumeItem(scissorhands) sm.sendNext(''.join(['WOW! #t', repr(scissorhands), "#?! The material...the color...the sound of the blades snipping together... It's so beautiful! Thank you so much! You're the best, #h #! \r\n\r\n#fUI/UIWindow2.img/QuestIcon/4/0# \r\n#i", repr(sweetness), '# #t', repr(sweetness), '# x 1'])) sm.setPlayerAsSpeaker() sm.sendSay('#b(You learned the Cheering Expression from Rinz the Assistant.)')
# Copyright 2019 The Chromium OS Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. config_type='sweetberry' inas = [ ('sweetberry', '0x40:3', 'pp1050_a', 1.05, 0.010, 'j2', True), # R462, SOC ('sweetberry', '0x40:1', 'pp1050_st', 1.05, 0.010, 'j2', True), # R665 ('sweetberry', '0x40:2', 'pp1050_stg', 1.05, 0.010, 'j2', True), # R664 ('sweetberry', '0x40:0', 'pp1200_dram_u', 1.20, 0.010, 'j2', True), # R463 ('sweetberry', '0x41:3', 'pp1800_a', 1.80, 0.010, 'j2', True), # R556, SOC + audio ('sweetberry', '0x41:1', 'pp3300_a', 3.30, 0.010, 'j2', True), # R478 ('sweetberry', '0x41:2', 'pp3300_cam_a', 3.30, 0.010, 'j2', True), # R482 ('sweetberry', '0x41:0', 'pp3300_ec', 3.30, 0.500, 'j2', True), # R474, originally 0.01 Ohm ('sweetberry', '0x42:3', 'pp3300_g', 3.30, 0.010, 'j2', True), # R458 ('sweetberry', '0x42:1', 'pp3300_h1_g', 3.30, 0.500, 'j2', True), # R473, originally 0.01 Ohm ('sweetberry', '0x42:2', 'pp3300_hp_vbat', 3.30, 0.500, 'j2', True), # R260, originally 0 Ohm ('sweetberry', '0x42:0', 'pp3300_panel_dx', 3.30, 0.010, 'j2', True), # R476 ('sweetberry', '0x43:3', 'pp3300_rtc', 3.30, 0.010, 'j2', True), # R472 ('sweetberry', '0x43:1', 'pp3300_soc_a', 3.30, 0.100, 'j2', True), # R480, originally 0.01 Ohm ('sweetberry', '0x43:2', 'pp3300_ssd_a', 3.30, 0.010, 'j2', True), # R708 ('sweetberry', '0x43:0', 'pp3300_tcpc_g', 3.30, 0.100, 'j2', True), # R475, originally 0.01 Ohm ('sweetberry', '0x44:3', 'pp3300_trackpad_a', 3.30, 0.010, 'j3', True), # R483 ('sweetberry', '0x44:1', 'pp3300_tsp_dig_dx', 3.30, 0.010, 'j3', True), # R670 ('sweetberry', '0x44:2', 'pp3300_wlan_a', 3.30, 0.010, 'j3', True), # R479 ('sweetberry', '0x44:0', 'pp5000_a', 5.00, 0.010, 'j3', True), # R459, USB ('sweetberry', '0x45:3', 'pp950_vccio', 0.95, 0.010, 'j3', True), # R461 ('sweetberry', '0x45:1', 'ppvar_bat', 7.70, 0.010, 'j3', True), # R569 ('sweetberry', '0x45:2', 'ppvar_elv_in', 7.70, 0.010, 'j3', True), # R717 ('sweetberry', '0x45:0', 'ppvar_elvdd', 4.60, 0.010, 'j3', True), # L12, originally 0 Ohm ('sweetberry', '0x46:3', 'ppvar_gt', 1.52, 0.020, 'j3', True), # U143, originally 0 Ohm ('sweetberry', '0x46:1', 'ppvar_sa', 1.52, 0.020, 'j3', True), # U144, originally 0 Ohm ('sweetberry', '0x46:2', 'ppvar_vcc', 1.52, 0.020, 'j3', True), # U141, originally 0 Ohm ('sweetberry', '0x46:0', 'ppvar_vprim_core_a', 1.05, 0.010, 'j3', True), # R460 ]
config_type = 'sweetberry' inas = [('sweetberry', '0x40:3', 'pp1050_a', 1.05, 0.01, 'j2', True), ('sweetberry', '0x40:1', 'pp1050_st', 1.05, 0.01, 'j2', True), ('sweetberry', '0x40:2', 'pp1050_stg', 1.05, 0.01, 'j2', True), ('sweetberry', '0x40:0', 'pp1200_dram_u', 1.2, 0.01, 'j2', True), ('sweetberry', '0x41:3', 'pp1800_a', 1.8, 0.01, 'j2', True), ('sweetberry', '0x41:1', 'pp3300_a', 3.3, 0.01, 'j2', True), ('sweetberry', '0x41:2', 'pp3300_cam_a', 3.3, 0.01, 'j2', True), ('sweetberry', '0x41:0', 'pp3300_ec', 3.3, 0.5, 'j2', True), ('sweetberry', '0x42:3', 'pp3300_g', 3.3, 0.01, 'j2', True), ('sweetberry', '0x42:1', 'pp3300_h1_g', 3.3, 0.5, 'j2', True), ('sweetberry', '0x42:2', 'pp3300_hp_vbat', 3.3, 0.5, 'j2', True), ('sweetberry', '0x42:0', 'pp3300_panel_dx', 3.3, 0.01, 'j2', True), ('sweetberry', '0x43:3', 'pp3300_rtc', 3.3, 0.01, 'j2', True), ('sweetberry', '0x43:1', 'pp3300_soc_a', 3.3, 0.1, 'j2', True), ('sweetberry', '0x43:2', 'pp3300_ssd_a', 3.3, 0.01, 'j2', True), ('sweetberry', '0x43:0', 'pp3300_tcpc_g', 3.3, 0.1, 'j2', True), ('sweetberry', '0x44:3', 'pp3300_trackpad_a', 3.3, 0.01, 'j3', True), ('sweetberry', '0x44:1', 'pp3300_tsp_dig_dx', 3.3, 0.01, 'j3', True), ('sweetberry', '0x44:2', 'pp3300_wlan_a', 3.3, 0.01, 'j3', True), ('sweetberry', '0x44:0', 'pp5000_a', 5.0, 0.01, 'j3', True), ('sweetberry', '0x45:3', 'pp950_vccio', 0.95, 0.01, 'j3', True), ('sweetberry', '0x45:1', 'ppvar_bat', 7.7, 0.01, 'j3', True), ('sweetberry', '0x45:2', 'ppvar_elv_in', 7.7, 0.01, 'j3', True), ('sweetberry', '0x45:0', 'ppvar_elvdd', 4.6, 0.01, 'j3', True), ('sweetberry', '0x46:3', 'ppvar_gt', 1.52, 0.02, 'j3', True), ('sweetberry', '0x46:1', 'ppvar_sa', 1.52, 0.02, 'j3', True), ('sweetberry', '0x46:2', 'ppvar_vcc', 1.52, 0.02, 'j3', True), ('sweetberry', '0x46:0', 'ppvar_vprim_core_a', 1.05, 0.01, 'j3', True)]
def selectionSort(A): for i in range(len(A) - 1): index_min = i value_min = A[i] for j in range(i + 1, len(A)): if A[j] < value_min: index_min = j value_min = A[j] A[index_min] = A[i] A[i] = value_min return A def insertionSort2(A): min_index = 0 for i in range(len(A)): if A[i] < A[min_index]: min_index = i temp = A[0] A[0] = A[min_index] A[min_index] = temp for i in range(2, len(A)): value_min = A[i] j = i - 1 while value_min < A[j]: A[j + 1] = A[j] j = j - 1 A[j + 1] = value_min return A def insertionSort1(A): for i in range(1, len(A)): value_min = A[i] j = i - 1 while (j >= 0) & (value_min < A[j]): A[j + 1] = A[j] j = j - 1 A[j + 1] = value_min return A def bubbleSort1(A): for i in range(len(A)): for j in range(1, len(A)): if (A[j - 1] > A[j]): temp = A[j - 1] A[j - 1] = A[j] A[j] = temp return A def bubbleSort2(A): for i in range(len(A)): for j in range(1, len(A) - i): if (A[j - 1] > A[j]): temp = A[j - 1] A[j - 1] = A[j] A[j] = temp return A def bubbleSort3(A): for i in range(len(A)): done = True for j in range(1, len(A) - i): if (A[j - 1] > A[j]): done = False temp = A[j - 1] A[j - 1] = A[j] A[j] = temp if done: return A return A def checkSorted(A): for i in range(1, len(A)): if A[i - 1] > A[i]: return False return True
def selection_sort(A): for i in range(len(A) - 1): index_min = i value_min = A[i] for j in range(i + 1, len(A)): if A[j] < value_min: index_min = j value_min = A[j] A[index_min] = A[i] A[i] = value_min return A def insertion_sort2(A): min_index = 0 for i in range(len(A)): if A[i] < A[min_index]: min_index = i temp = A[0] A[0] = A[min_index] A[min_index] = temp for i in range(2, len(A)): value_min = A[i] j = i - 1 while value_min < A[j]: A[j + 1] = A[j] j = j - 1 A[j + 1] = value_min return A def insertion_sort1(A): for i in range(1, len(A)): value_min = A[i] j = i - 1 while (j >= 0) & (value_min < A[j]): A[j + 1] = A[j] j = j - 1 A[j + 1] = value_min return A def bubble_sort1(A): for i in range(len(A)): for j in range(1, len(A)): if A[j - 1] > A[j]: temp = A[j - 1] A[j - 1] = A[j] A[j] = temp return A def bubble_sort2(A): for i in range(len(A)): for j in range(1, len(A) - i): if A[j - 1] > A[j]: temp = A[j - 1] A[j - 1] = A[j] A[j] = temp return A def bubble_sort3(A): for i in range(len(A)): done = True for j in range(1, len(A) - i): if A[j - 1] > A[j]: done = False temp = A[j - 1] A[j - 1] = A[j] A[j] = temp if done: return A return A def check_sorted(A): for i in range(1, len(A)): if A[i - 1] > A[i]: return False return True
# # LeetCode # # Problem - 386 # URL - https://leetcode.com/problems/lexicographical-numbers/ # class Solution: def lexicalOrder(self, n: int) -> List[int]: ans = [] for i in range(1, n+1): ans.insert(bisect.bisect_left(ans, str(i)), str(i)) return ans
class Solution: def lexical_order(self, n: int) -> List[int]: ans = [] for i in range(1, n + 1): ans.insert(bisect.bisect_left(ans, str(i)), str(i)) return ans
def _method(f): return lambda *l, **d: f(i, *l, **d) class o: def __init__(i, **d): i.__dict__.update(**d) def __repr__(i): return str( {k: (v.__name__ + "()" if callable(v) else v) for k, v in sorted(i.__dict__.items()) if k[0] != "_"}) def of(i, **methods): for k, f in methods.items(): i.__dict__[k] = _method(f) return i def Fred(a=2): def p(i): return i.a + i.c + 20 def lt(i, j): return i.a < j.a return of(o(a=a, b=2, c=3), say=p, lt=lt) f = Fred(a=-10000000000000000) print(f.say()) print(f.lt(Fred())) # f.say(100000000) # g = Fred(10) # print(g < f
def _method(f): return lambda *l, **d: f(i, *l, **d) class O: def __init__(i, **d): i.__dict__.update(**d) def __repr__(i): return str({k: v.__name__ + '()' if callable(v) else v for (k, v) in sorted(i.__dict__.items()) if k[0] != '_'}) def of(i, **methods): for (k, f) in methods.items(): i.__dict__[k] = _method(f) return i def fred(a=2): def p(i): return i.a + i.c + 20 def lt(i, j): return i.a < j.a return of(o(a=a, b=2, c=3), say=p, lt=lt) f = fred(a=-10000000000000000) print(f.say()) print(f.lt(fred()))
class Solution: def romanToInt(self, s: str) -> int: romanMap = {'I': 1, 'V': 5, 'X': 10, 'L': 50, 'C': 100, 'D': 500, 'M': 1000} result = 0 prev = 1000 for c in s: curr = romanMap[c] if curr > prev: result += curr - prev*2 else: result += curr prev = curr return result
class Solution: def roman_to_int(self, s: str) -> int: roman_map = {'I': 1, 'V': 5, 'X': 10, 'L': 50, 'C': 100, 'D': 500, 'M': 1000} result = 0 prev = 1000 for c in s: curr = romanMap[c] if curr > prev: result += curr - prev * 2 else: result += curr prev = curr return result
''' Design a calculator which will solve all the problems correctly except for 1. 45*3 = 555 2. 56+9 = 77 3. 56/6 = 4 Your program should take two numbers, operator as input and show the output. ''' def add(n1,n2): ''' To add the given numbers ''' result = n1+n2 return result def sub(n1,n2): ''' To subtract given numbers ''' result = n1-n2 return result def mul(n1,n2): ''' To multiply given numbers ''' result = n1*n2 return result def div(n1,n2): ''' To divide the given numbers ''' result = n1/n2 return result def CalculatorLogic(num1,num2,operator): # Conditions for calculation including faulty ones if(((num1 == 3 and num2 == 45) or (num1 == 45 and num2 == 3)) and operator == '*'): # Faulty condition 1 print(f"\t\n{num1} * {num2} = 555") elif(((num1 == 56 and num2 == 9) or (num1 == 9 and num2 == 56)) and operator == '+'): # Faulty condition 2 print(f"\t\n{num1} + {num2} = 77") elif(((num1 == 56 and num2 == 6) or (num1 == 6 and num2 == 56)) and operator == '/'): # Faulty condition 3 print(f"\t\n{num1} / {num2} = 4") elif(operator == '+'): # If user wants to add numbers print(f"\t\n{num1} + {num2} = {add(num1,num2)}") elif(operator == '-'): # If user wants to subtract numbers print(f"\t\n{num1} - {num2} = {sub(num1,num2)}") elif(operator == '*'): # If user wants to multiply numbers print(f"\t\n{num1} * {num2} = {mul(num1,num2)}") elif(operator == '/'): # If user wants to divide numbers print(f"\t\n{num1} / {num2} = {div(num1,num2)}") else: print("Invalid Option, please retry") def main(): # Introducing the name of app to user print("Faulty Calculator".center(40,"-")) # Creating looping conditions for using calculator as long as user wants cont = 'y' while(cont == 'y'): # Taking required inputs n1 = int(input("Enter first number: ")) n2 = int(input("Enter second number: ")) operator = input("Enter the operator you want to use:") # Calling the main logic behind the calculator CalculatorLogic(n1,n2,operator) cont = str(input("Do you want to continue? y or n? ")) cont = cont.lower() # Thanking user for using our calculator print("Thank you for using our calculator!") if __name__ == "__main__": main()
""" Design a calculator which will solve all the problems correctly except for 1. 45*3 = 555 2. 56+9 = 77 3. 56/6 = 4 Your program should take two numbers, operator as input and show the output. """ def add(n1, n2): """ To add the given numbers """ result = n1 + n2 return result def sub(n1, n2): """ To subtract given numbers """ result = n1 - n2 return result def mul(n1, n2): """ To multiply given numbers """ result = n1 * n2 return result def div(n1, n2): """ To divide the given numbers """ result = n1 / n2 return result def calculator_logic(num1, num2, operator): if (num1 == 3 and num2 == 45 or (num1 == 45 and num2 == 3)) and operator == '*': print(f'\t\n{num1} * {num2} = 555') elif (num1 == 56 and num2 == 9 or (num1 == 9 and num2 == 56)) and operator == '+': print(f'\t\n{num1} + {num2} = 77') elif (num1 == 56 and num2 == 6 or (num1 == 6 and num2 == 56)) and operator == '/': print(f'\t\n{num1} / {num2} = 4') elif operator == '+': print(f'\t\n{num1} + {num2} = {add(num1, num2)}') elif operator == '-': print(f'\t\n{num1} - {num2} = {sub(num1, num2)}') elif operator == '*': print(f'\t\n{num1} * {num2} = {mul(num1, num2)}') elif operator == '/': print(f'\t\n{num1} / {num2} = {div(num1, num2)}') else: print('Invalid Option, please retry') def main(): print('Faulty Calculator'.center(40, '-')) cont = 'y' while cont == 'y': n1 = int(input('Enter first number: ')) n2 = int(input('Enter second number: ')) operator = input('Enter the operator you want to use:') calculator_logic(n1, n2, operator) cont = str(input('Do you want to continue? y or n? ')) cont = cont.lower() print('Thank you for using our calculator!') if __name__ == '__main__': main()
''' 0: 1: 2: 3: 4: aaaa .... aaaa aaaa .... b c . c . c . c b c b c . c . c . c b c .... .... dddd dddd dddd e f . f e . . f . f e f . f e . . f . f gggg .... gggg gggg .... 5: 6: 7: 8: 9: aaaa aaaa aaaa aaaa aaaa b . b . . c b c b c b . b . . c b c b c dddd dddd .... dddd dddd . f e f . f e f . f . f e f . f e f . f gggg gggg .... gggg gggg 0 1 2 3 4 5 6 7 8 9 a x x x x x x x x b x x x x x c x x x x x x x x d x x x x x x x e x x x x x f x x x x x x x x x g x x x x x x x ''' def get_easy_seg_count(filename): easy = [2,3,4,7] easy_segs = 0 with open(filename) as f: while True: line = f.readline().strip() if not line: break else: for seg in line.split('|')[1].split(): if len(seg) in easy: easy_segs += 1 print("Number of easy signals in {} is {}".format(filename, easy_segs)) return easy_segs def decode_fives(helper_rels, fives): decoded = dict() for f in fives: if helper_rels['1'][0] in f and helper_rels['1'][1] in f: decoded[f] = '3' elif helper_rels["4-1"][0] in f and helper_rels["4-1"][1] in f: decoded[f] = '5' else: decoded[f] = '2' return decoded def decode_sixes(helper_rels, sixes): decoded = dict() for s in sixes: if not( helper_rels['1'][0] in s and helper_rels['1'][1] in s): decoded[s] = '6' elif helper_rels["4-1"][0] in s and helper_rels["4-1"][1] in s: decoded[s] = '9' else: decoded[s] = '0' return decoded def decode_line(line): decoded = dict() helper_rels = dict() ## Decode simple digits easy = { 2 : '1', 3 : '7', 4 : '4', 7 : '8'} fives = list() sixes = list() for seg in line.split('|')[0].split(): seg = ''.join(sorted(seg)) if len(seg) in easy: decoded[seg] = easy[len(seg)] helper_rels[easy[len(seg)]] = seg elif len(seg) == 5: fives.append(seg) elif len(seg) == 6: sixes.append(seg) helper_rels["7-1"] = helper_rels['7'] helper_rels["4-1"] = helper_rels['4'] for n in helper_rels['1']: helper_rels["7-1"] = helper_rels["7-1"].replace(n,'') helper_rels["4-1"] = helper_rels["4-1"].replace(n,'') decoded.update(decode_fives(helper_rels,fives)) decoded.update(decode_sixes(helper_rels,sixes)) return decoded def decoded_output(line): decoded = decode_line(line) output = "" for seg in line.split('|')[1].split(): output = output + decoded[''.join(sorted(seg))] return int(output) def sum_all_outputs(filename): all_outputs = 0 with open(filename) as f: while True: line = f.readline().strip() if not line: break else: all_outputs += decoded_output(line) print("Sum of all outputs in {} is {}".format(filename,all_outputs)) return all_outputs print("-- Part 1") assert get_easy_seg_count("sample.txt") == 26 assert get_easy_seg_count("input.txt") == 554 print("\n-- Part 2") assert sum_all_outputs("sample.txt") == 61229 assert sum_all_outputs("input.txt") == 990964
""" 0: 1: 2: 3: 4: aaaa .... aaaa aaaa .... b c . c . c . c b c b c . c . c . c b c .... .... dddd dddd dddd e f . f e . . f . f e f . f e . . f . f gggg .... gggg gggg .... 5: 6: 7: 8: 9: aaaa aaaa aaaa aaaa aaaa b . b . . c b c b c b . b . . c b c b c dddd dddd .... dddd dddd . f e f . f e f . f . f e f . f e f . f gggg gggg .... gggg gggg 0 1 2 3 4 5 6 7 8 9 a x x x x x x x x b x x x x x c x x x x x x x x d x x x x x x x e x x x x x f x x x x x x x x x g x x x x x x x """ def get_easy_seg_count(filename): easy = [2, 3, 4, 7] easy_segs = 0 with open(filename) as f: while True: line = f.readline().strip() if not line: break else: for seg in line.split('|')[1].split(): if len(seg) in easy: easy_segs += 1 print('Number of easy signals in {} is {}'.format(filename, easy_segs)) return easy_segs def decode_fives(helper_rels, fives): decoded = dict() for f in fives: if helper_rels['1'][0] in f and helper_rels['1'][1] in f: decoded[f] = '3' elif helper_rels['4-1'][0] in f and helper_rels['4-1'][1] in f: decoded[f] = '5' else: decoded[f] = '2' return decoded def decode_sixes(helper_rels, sixes): decoded = dict() for s in sixes: if not (helper_rels['1'][0] in s and helper_rels['1'][1] in s): decoded[s] = '6' elif helper_rels['4-1'][0] in s and helper_rels['4-1'][1] in s: decoded[s] = '9' else: decoded[s] = '0' return decoded def decode_line(line): decoded = dict() helper_rels = dict() easy = {2: '1', 3: '7', 4: '4', 7: '8'} fives = list() sixes = list() for seg in line.split('|')[0].split(): seg = ''.join(sorted(seg)) if len(seg) in easy: decoded[seg] = easy[len(seg)] helper_rels[easy[len(seg)]] = seg elif len(seg) == 5: fives.append(seg) elif len(seg) == 6: sixes.append(seg) helper_rels['7-1'] = helper_rels['7'] helper_rels['4-1'] = helper_rels['4'] for n in helper_rels['1']: helper_rels['7-1'] = helper_rels['7-1'].replace(n, '') helper_rels['4-1'] = helper_rels['4-1'].replace(n, '') decoded.update(decode_fives(helper_rels, fives)) decoded.update(decode_sixes(helper_rels, sixes)) return decoded def decoded_output(line): decoded = decode_line(line) output = '' for seg in line.split('|')[1].split(): output = output + decoded[''.join(sorted(seg))] return int(output) def sum_all_outputs(filename): all_outputs = 0 with open(filename) as f: while True: line = f.readline().strip() if not line: break else: all_outputs += decoded_output(line) print('Sum of all outputs in {} is {}'.format(filename, all_outputs)) return all_outputs print('-- Part 1') assert get_easy_seg_count('sample.txt') == 26 assert get_easy_seg_count('input.txt') == 554 print('\n-- Part 2') assert sum_all_outputs('sample.txt') == 61229 assert sum_all_outputs('input.txt') == 990964
# Convert to str number = 18 number_string = str(number) print(type(number_string)) # 'str'
number = 18 number_string = str(number) print(type(number_string))
n = int(input("Informe a quantidade de caracteres: ")) caracteres = [] consoantes = 0 i = 1 while i <= n: c = input("Informe o %d caracter: " %i) caracteres.append(c) i += 1 i = 0 while i < n: if caracteres[i] not in "aeiou": consoantes += 1 i += 1 print("O total de consoantes eh: ", consoantes)
n = int(input('Informe a quantidade de caracteres: ')) caracteres = [] consoantes = 0 i = 1 while i <= n: c = input('Informe o %d caracter: ' % i) caracteres.append(c) i += 1 i = 0 while i < n: if caracteres[i] not in 'aeiou': consoantes += 1 i += 1 print('O total de consoantes eh: ', consoantes)
# Advent of Code 2019 Solutions: Day 2, Puzzle 1 # https://github.com/emddudley/advent-of-code-solutions with open('input', 'r') as f: program = [int(x) for x in f.read().strip().split(',')] program[1] = 12 program[2] = 2 for opcode_index in range(0, len(program), 4): opcode = program[opcode_index] if opcode == 99: break addr_a = program[opcode_index + 1] addr_b = program[opcode_index + 2] dest = program[opcode_index + 3] if opcode == 1: program[dest] = program[addr_a] + program[addr_b] elif opcode == 2: program[dest] = program[addr_a] * program[addr_b] print(program[0])
with open('input', 'r') as f: program = [int(x) for x in f.read().strip().split(',')] program[1] = 12 program[2] = 2 for opcode_index in range(0, len(program), 4): opcode = program[opcode_index] if opcode == 99: break addr_a = program[opcode_index + 1] addr_b = program[opcode_index + 2] dest = program[opcode_index + 3] if opcode == 1: program[dest] = program[addr_a] + program[addr_b] elif opcode == 2: program[dest] = program[addr_a] * program[addr_b] print(program[0])
class Solution: def minDeletionSize(self, A: List[str]) -> int: minDel = m = len(A[0]) dp = [1] * m for j in range(m): for i in range(j): if all(A[k][i] <= A[k][j] for k in range(len(A))): dp[j] = max(dp[j], dp[i] + 1) minDel = min(minDel, m - dp[j]) return minDel
class Solution: def min_deletion_size(self, A: List[str]) -> int: min_del = m = len(A[0]) dp = [1] * m for j in range(m): for i in range(j): if all((A[k][i] <= A[k][j] for k in range(len(A)))): dp[j] = max(dp[j], dp[i] + 1) min_del = min(minDel, m - dp[j]) return minDel
key = int(input()) n = int(input()) message = "" for x in range(n): letters = input() message += chr(ord(letters) + key) print(message)
key = int(input()) n = int(input()) message = '' for x in range(n): letters = input() message += chr(ord(letters) + key) print(message)
def action_sanitize(): '''Make action suitable for use as a Pose Library ''' pass def apply_pose(pose_index=-1): '''Apply specified Pose Library pose to the rig :param pose_index: Pose, Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose) :type pose_index: int in [-2, inf], (optional) ''' pass def browse_interactive(pose_index=-1): '''Interactively browse poses in 3D-View :param pose_index: Pose, Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose) :type pose_index: int in [-2, inf], (optional) ''' pass def new(): '''Add New Pose Library to active Object ''' pass def pose_add(frame=1, name="Pose"): '''Add the current Pose to the active Pose Library :param frame: Frame, Frame to store pose on :type frame: int in [0, inf], (optional) :param name: Pose Name, Name of newly added Pose :type name: string, (optional, never None) ''' pass def pose_move(pose='', direction='UP'): '''Move the pose up or down in the active Pose Library :param pose: Pose, The pose to move :type pose: enum in [], (optional) :param direction: Direction, Direction to move the chosen pose towards :type direction: enum in ['UP', 'DOWN'], (optional) ''' pass def pose_remove(pose=''): '''Remove nth pose from the active Pose Library :param pose: Pose, The pose to remove :type pose: enum in [], (optional) ''' pass def pose_rename(name="RenamedPose", pose=''): '''Rename specified pose from the active Pose Library :param name: New Pose Name, New name for pose :type name: string, (optional, never None) :param pose: Pose, The pose to rename :type pose: enum in [], (optional) ''' pass def unlink(): '''Remove Pose Library from active Object ''' pass
def action_sanitize(): """Make action suitable for use as a Pose Library """ pass def apply_pose(pose_index=-1): """Apply specified Pose Library pose to the rig :param pose_index: Pose, Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose) :type pose_index: int in [-2, inf], (optional) """ pass def browse_interactive(pose_index=-1): """Interactively browse poses in 3D-View :param pose_index: Pose, Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose) :type pose_index: int in [-2, inf], (optional) """ pass def new(): """Add New Pose Library to active Object """ pass def pose_add(frame=1, name='Pose'): """Add the current Pose to the active Pose Library :param frame: Frame, Frame to store pose on :type frame: int in [0, inf], (optional) :param name: Pose Name, Name of newly added Pose :type name: string, (optional, never None) """ pass def pose_move(pose='', direction='UP'): """Move the pose up or down in the active Pose Library :param pose: Pose, The pose to move :type pose: enum in [], (optional) :param direction: Direction, Direction to move the chosen pose towards :type direction: enum in ['UP', 'DOWN'], (optional) """ pass def pose_remove(pose=''): """Remove nth pose from the active Pose Library :param pose: Pose, The pose to remove :type pose: enum in [], (optional) """ pass def pose_rename(name='RenamedPose', pose=''): """Rename specified pose from the active Pose Library :param name: New Pose Name, New name for pose :type name: string, (optional, never None) :param pose: Pose, The pose to rename :type pose: enum in [], (optional) """ pass def unlink(): """Remove Pose Library from active Object """ pass
class TreeNode: def __init__(self, val): self.val = val self.left = None self.right = None class Solution(object): def is_same_tree(self, p, q): if p is None or q is None: if p != q: return False return True if p.val != q.val: return False if not self.is_same_tree(p.left, q.left): return False return self.is_same_tree(p.right, q.right)
class Treenode: def __init__(self, val): self.val = val self.left = None self.right = None class Solution(object): def is_same_tree(self, p, q): if p is None or q is None: if p != q: return False return True if p.val != q.val: return False if not self.is_same_tree(p.left, q.left): return False return self.is_same_tree(p.right, q.right)
#!/usr/bin/env python3 n = int(input()) i = 1 while i < n + 1: if i % 3 == 0 and i % 5 != 0: print("fizz") elif i % 5 == 0 and i % 3 != 0: print("buzz") elif i % 5 == 0 and i % 3 == 0: print("fizz-buzz") else: print(i) i = i + 1
n = int(input()) i = 1 while i < n + 1: if i % 3 == 0 and i % 5 != 0: print('fizz') elif i % 5 == 0 and i % 3 != 0: print('buzz') elif i % 5 == 0 and i % 3 == 0: print('fizz-buzz') else: print(i) i = i + 1
region = 'us-west-2' vpc = dict( source='./vpc' ) inst = dict( source='./inst', vpc_id='${module.vpc.vpc_id}' ) config = dict( provider=dict( aws=dict(region=region) ), module=dict( vpc=vpc, inst=inst ) )
region = 'us-west-2' vpc = dict(source='./vpc') inst = dict(source='./inst', vpc_id='${module.vpc.vpc_id}') config = dict(provider=dict(aws=dict(region=region)), module=dict(vpc=vpc, inst=inst))
{ "targets": [ { "target_name": "userid", "sources": [ '<!@(ls -1 src/*.cc)' ], "include_dirs": ["<!@(node -p \"require('node-addon-api').include\")"], "dependencies": ["<!(node -p \"require('node-addon-api').gyp\")"], "cflags!": [ "-fno-exceptions" ], "cflags_cc!": [ "-fno-exceptions" ], "xcode_settings": { "GCC_ENABLE_CPP_EXCEPTIONS": "YES", "CLANG_CXX_LIBRARY": "libc++", "MACOSX_DEPLOYMENT_TARGET": "10.7", }, "msvs_settings": { "VCCLCompilerTool": { "ExceptionHandling": 1 }, }, "variables" : { "generate_coverage": "<!(echo $GENERATE_COVERAGE)", }, "conditions": [ ['OS=="mac"', { "cflags+": ["-fvisibility=hidden"], "xcode_settings": { "GCC_SYMBOLS_PRIVATE_EXTERN": "YES", # -fvisibility=hidden }, }], ['generate_coverage=="yes"', { "cflags+": ["--coverage"], "cflags_cc+": ["--coverage"], "link_settings": { "libraries+": ["-lgcov"], }, }], ], }, ], }
{'targets': [{'target_name': 'userid', 'sources': ['<!@(ls -1 src/*.cc)'], 'include_dirs': ['<!@(node -p "require(\'node-addon-api\').include")'], 'dependencies': ['<!(node -p "require(\'node-addon-api\').gyp")'], 'cflags!': ['-fno-exceptions'], 'cflags_cc!': ['-fno-exceptions'], 'xcode_settings': {'GCC_ENABLE_CPP_EXCEPTIONS': 'YES', 'CLANG_CXX_LIBRARY': 'libc++', 'MACOSX_DEPLOYMENT_TARGET': '10.7'}, 'msvs_settings': {'VCCLCompilerTool': {'ExceptionHandling': 1}}, 'variables': {'generate_coverage': '<!(echo $GENERATE_COVERAGE)'}, 'conditions': [['OS=="mac"', {'cflags+': ['-fvisibility=hidden'], 'xcode_settings': {'GCC_SYMBOLS_PRIVATE_EXTERN': 'YES'}}], ['generate_coverage=="yes"', {'cflags+': ['--coverage'], 'cflags_cc+': ['--coverage'], 'link_settings': {'libraries+': ['-lgcov']}}]]}]}
algorithm_defaults = { 'ERM': { 'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'randaugment_n': 2, # When running ERM + data augmentation }, 'groupDRO': { 'train_loader': 'standard', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'group_dro_step_size': 0.01, }, 'deepCORAL': { 'train_loader': 'group', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'coral_penalty_weight': 1., 'randaugment_n': 2, 'additional_train_transform': 'randaugment', # Apply strong augmentation to labeled & unlabeled examples }, 'IRM': { 'train_loader': 'group', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'irm_lambda': 100., 'irm_penalty_anneal_iters': 500, }, 'DANN': { 'train_loader': 'group', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'randaugment_n': 2, 'additional_train_transform': 'randaugment', # Apply strong augmentation to labeled & unlabeled examples }, 'AFN': { 'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'use_hafn': False, 'afn_penalty_weight': 0.01, 'safn_delta_r': 1.0, 'hafn_r': 1.0, 'additional_train_transform': 'randaugment', # Apply strong augmentation to labeled & unlabeled examples 'randaugment_n': 2, }, 'FixMatch': { 'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'self_training_lambda': 1, 'self_training_threshold': 0.7, 'scheduler': 'FixMatchLR', 'randaugment_n': 2, 'additional_train_transform': 'randaugment', # Apply strong augmentation to labeled examples }, 'PseudoLabel': { 'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'self_training_lambda': 1, 'self_training_threshold': 0.7, 'pseudolabel_T2': 0.4, 'scheduler': 'FixMatchLR', 'randaugment_n': 2, 'additional_train_transform': 'randaugment', # Apply strong augmentation to labeled & unlabeled examples }, 'NoisyStudent': { 'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'noisystudent_add_dropout': True, 'noisystudent_dropout_rate': 0.5, 'scheduler': 'FixMatchLR', 'randaugment_n': 2, 'additional_train_transform': 'randaugment', # Apply strong augmentation to labeled & unlabeled examples } }
algorithm_defaults = {'ERM': {'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'randaugment_n': 2}, 'groupDRO': {'train_loader': 'standard', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'group_dro_step_size': 0.01}, 'deepCORAL': {'train_loader': 'group', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'coral_penalty_weight': 1.0, 'randaugment_n': 2, 'additional_train_transform': 'randaugment'}, 'IRM': {'train_loader': 'group', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'irm_lambda': 100.0, 'irm_penalty_anneal_iters': 500}, 'DANN': {'train_loader': 'group', 'uniform_over_groups': True, 'distinct_groups': True, 'eval_loader': 'standard', 'randaugment_n': 2, 'additional_train_transform': 'randaugment'}, 'AFN': {'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'use_hafn': False, 'afn_penalty_weight': 0.01, 'safn_delta_r': 1.0, 'hafn_r': 1.0, 'additional_train_transform': 'randaugment', 'randaugment_n': 2}, 'FixMatch': {'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'self_training_lambda': 1, 'self_training_threshold': 0.7, 'scheduler': 'FixMatchLR', 'randaugment_n': 2, 'additional_train_transform': 'randaugment'}, 'PseudoLabel': {'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'self_training_lambda': 1, 'self_training_threshold': 0.7, 'pseudolabel_T2': 0.4, 'scheduler': 'FixMatchLR', 'randaugment_n': 2, 'additional_train_transform': 'randaugment'}, 'NoisyStudent': {'train_loader': 'standard', 'uniform_over_groups': False, 'eval_loader': 'standard', 'noisystudent_add_dropout': True, 'noisystudent_dropout_rate': 0.5, 'scheduler': 'FixMatchLR', 'randaugment_n': 2, 'additional_train_transform': 'randaugment'}}
def isinteger(s): return s.isdigit() or s[0] == '-' and s[1:].isdigit() def isfloat(x): s = x.partition(".") if s[1]=='.': if s[0]=='' or s[0]=='-': if s[2]=='' or s[2][0]=='-': return False else: return isinteger(s[2]) elif isinteger(s[0]): if s[2]!='' and s[2][0]=='-': return False return s[2]=='' or isinteger(s[2]) else: return False else: return False print(isfloat(".112")) print(isfloat("-.112")) print(isfloat("3.14")) print(isfloat("-3.14")) print(isfloat("-3.14")) print(isfloat("5.0")) print(isfloat("-777.0")) print(isfloat("-777.")) print(isfloat(".")) print(isfloat("..")) print(isfloat("-21.-1")) print(isfloat("-.-1"))
def isinteger(s): return s.isdigit() or (s[0] == '-' and s[1:].isdigit()) def isfloat(x): s = x.partition('.') if s[1] == '.': if s[0] == '' or s[0] == '-': if s[2] == '' or s[2][0] == '-': return False else: return isinteger(s[2]) elif isinteger(s[0]): if s[2] != '' and s[2][0] == '-': return False return s[2] == '' or isinteger(s[2]) else: return False else: return False print(isfloat('.112')) print(isfloat('-.112')) print(isfloat('3.14')) print(isfloat('-3.14')) print(isfloat('-3.14')) print(isfloat('5.0')) print(isfloat('-777.0')) print(isfloat('-777.')) print(isfloat('.')) print(isfloat('..')) print(isfloat('-21.-1')) print(isfloat('-.-1'))
class Solution: def diameterOfBinaryTree(self, root: TreeNode) -> int: if not root: return 0 elif not root.right and not root.left: return 0 elif not root.right: return max(self.diameterOfBinaryTree(root.left), 1 + self.height(root.left)) elif not root.left: return max(self.diameterOfBinaryTree(root.right), 1 + self.height(root.right)) else: return max(self.diameterOfBinaryTree(root.right), self.diameterOfBinaryTree(root.left), self.height(root.left) + self.height(root.right) + 2) def height(self, root): if not root: return 0 if not root.right and not root.left: return 0 return 1 + max(self.height(root.left), self.height(root.right)) class Solution: def diameterOfBinaryTree(self, root): self.ans = 0 def depth(node): if not node: return 0 r = depth(node.right) l = depth(node.left) self.ans = max(self.ans, r+l) return 1 + max(r, l) depth(root) return self.ans
class Solution: def diameter_of_binary_tree(self, root: TreeNode) -> int: if not root: return 0 elif not root.right and (not root.left): return 0 elif not root.right: return max(self.diameterOfBinaryTree(root.left), 1 + self.height(root.left)) elif not root.left: return max(self.diameterOfBinaryTree(root.right), 1 + self.height(root.right)) else: return max(self.diameterOfBinaryTree(root.right), self.diameterOfBinaryTree(root.left), self.height(root.left) + self.height(root.right) + 2) def height(self, root): if not root: return 0 if not root.right and (not root.left): return 0 return 1 + max(self.height(root.left), self.height(root.right)) class Solution: def diameter_of_binary_tree(self, root): self.ans = 0 def depth(node): if not node: return 0 r = depth(node.right) l = depth(node.left) self.ans = max(self.ans, r + l) return 1 + max(r, l) depth(root) return self.ans
arima = { 'order':[(2,1,0),(0,1,2),(1,1,1)], 'seasonal_order':[(0,0,0,0),(0,1,1,12)], 'trend':['n','c','t','ct'] } elasticnet = { 'alpha':[i/10 for i in range(1,101)], 'l1_ratio':[0,0.25,0.5,0.75,1], 'normalizer':['scale','minmax',None] } gbt = { 'max_depth':[2,3], 'n_estimators':[100,500] } hwes = { 'trend':[None,'add','mul'], 'seasonal':[None,'add','mul'], 'damped_trend':[True,False] } knn = { 'n_neighbors':range(2,20), 'weights':['uniform','distance'] } lightgbm = { 'max_depth':[i for i in range(5)] + [-1] } mlp = { 'activation':['relu','tanh'], 'hidden_layer_sizes':[(25,),(25,25,)], 'solver':['lbfgs','adam'], 'normalizer':['scale','minmax',None], 'random_state':[20] } mlr = { 'normalizer':['scale','minmax',None] } prophet = { 'n_changepoints':range(5) } rf = { 'max_depth':[5,10,None], 'n_estimators':[100,500,1000] } silverkite = { 'changepoints':range(5) } svr={ 'kernel':['linear'], 'C':[.5,1,2,3], 'epsilon':[0.01,0.1,0.5] } xgboost = { 'max_depth':[2,3,4,5,6] }
arima = {'order': [(2, 1, 0), (0, 1, 2), (1, 1, 1)], 'seasonal_order': [(0, 0, 0, 0), (0, 1, 1, 12)], 'trend': ['n', 'c', 't', 'ct']} elasticnet = {'alpha': [i / 10 for i in range(1, 101)], 'l1_ratio': [0, 0.25, 0.5, 0.75, 1], 'normalizer': ['scale', 'minmax', None]} gbt = {'max_depth': [2, 3], 'n_estimators': [100, 500]} hwes = {'trend': [None, 'add', 'mul'], 'seasonal': [None, 'add', 'mul'], 'damped_trend': [True, False]} knn = {'n_neighbors': range(2, 20), 'weights': ['uniform', 'distance']} lightgbm = {'max_depth': [i for i in range(5)] + [-1]} mlp = {'activation': ['relu', 'tanh'], 'hidden_layer_sizes': [(25,), (25, 25)], 'solver': ['lbfgs', 'adam'], 'normalizer': ['scale', 'minmax', None], 'random_state': [20]} mlr = {'normalizer': ['scale', 'minmax', None]} prophet = {'n_changepoints': range(5)} rf = {'max_depth': [5, 10, None], 'n_estimators': [100, 500, 1000]} silverkite = {'changepoints': range(5)} svr = {'kernel': ['linear'], 'C': [0.5, 1, 2, 3], 'epsilon': [0.01, 0.1, 0.5]} xgboost = {'max_depth': [2, 3, 4, 5, 6]}
# This is a pytest config file # https://docs.pytest.org/en/2.7.3/plugins.html # It allows us to tell nbval (the py.text plugin we use to run # notebooks and check their output is unchanged) to skip comparing # notebook outputs for particular mimetypes. def pytest_collectstart(collector): if ( collector.fspath and collector.fspath.ext == ".ipynb" and hasattr(collector, "skip_compare") ): # Skip plotly comparison, because something to do with # responsive plot sizing makes output different in test # environment collector.skip_compare += ("application/vnd.plotly.v1+json",)
def pytest_collectstart(collector): if collector.fspath and collector.fspath.ext == '.ipynb' and hasattr(collector, 'skip_compare'): collector.skip_compare += ('application/vnd.plotly.v1+json',)
# model model = Model() i1 = Input("op1", "TENSOR_FLOAT32", "{2, 2, 2, 2}") i3 = Output("op3", "TENSOR_FLOAT32", "{2, 2, 2, 2}") model = model.Operation("RSQRT", i1).To(i3) # Example 1. Input in operand 0, input0 = {i1: # input 0 [1.0, 36.0, 2.0, 90, 4.0, 16.0, 25.0, 100.0, 23.0, 19.0, 40.0, 256.0, 4.0, 43.0, 8.0, 36.0]} output0 = {i3: # output 0 [1.0, 0.166667, 0.70710678118, 0.105409, 0.5, 0.25, 0.2, 0.1, 0.208514, 0.229416, 0.158114, 0.0625, 0.5, 0.152499, 0.35355339059, 0.166667]} # Instantiate an example Example((input0, output0))
model = model() i1 = input('op1', 'TENSOR_FLOAT32', '{2, 2, 2, 2}') i3 = output('op3', 'TENSOR_FLOAT32', '{2, 2, 2, 2}') model = model.Operation('RSQRT', i1).To(i3) input0 = {i1: [1.0, 36.0, 2.0, 90, 4.0, 16.0, 25.0, 100.0, 23.0, 19.0, 40.0, 256.0, 4.0, 43.0, 8.0, 36.0]} output0 = {i3: [1.0, 0.166667, 0.70710678118, 0.105409, 0.5, 0.25, 0.2, 0.1, 0.208514, 0.229416, 0.158114, 0.0625, 0.5, 0.152499, 0.35355339059, 0.166667]} example((input0, output0))
#It's a simple calculator for doing Addition, Subtraction, Multiplication, Division and Percentage. first_number = int(input("Enter your first number: ")) operators = input("Enter what you wanna do +,-,*,/,%: ") second_number = int(input("Enter your second Number: ")) if operators == "+" : first_number += second_number print(f"Your Addition result is: {first_number}") elif operators == "-" : first_number -= second_number print(f"Your Subtraction result is: {first_number}") elif operators == "*" : first_number *= second_number print(f"Your Multiplication result is: {first_number}") elif operators == "/" : first_number /= second_number print(f"Your Division result is: {first_number}") elif operators == "%" : first_number %= second_number print(f"Your Modulus result is: {first_number}") else : print("You have chosen a wrong operator")
first_number = int(input('Enter your first number: ')) operators = input('Enter what you wanna do +,-,*,/,%: ') second_number = int(input('Enter your second Number: ')) if operators == '+': first_number += second_number print(f'Your Addition result is: {first_number}') elif operators == '-': first_number -= second_number print(f'Your Subtraction result is: {first_number}') elif operators == '*': first_number *= second_number print(f'Your Multiplication result is: {first_number}') elif operators == '/': first_number /= second_number print(f'Your Division result is: {first_number}') elif operators == '%': first_number %= second_number print(f'Your Modulus result is: {first_number}') else: print('You have chosen a wrong operator')
description = 'system setup' group = 'lowlevel' sysconfig = dict( cache='localhost', instrument='Fluco', experiment='Exp', datasinks=['conssink', 'filesink', 'daemonsink',], ) modules = ['nicos.commands.standard', 'nicos_ess.commands.epics'] devices = dict( Fluco=device('nicos.devices.instrument.Instrument', description='instrument object', instrument='Fluco', responsible='S. Body <[email protected]>', ), Sample=device('nicos.devices.sample.Sample', description='The currently used sample', ), Exp=device('nicos.devices.experiment.Experiment', description='experiment object', dataroot='/opt/nicos-data', sendmail=True, serviceexp='p0', sample='Sample', ), filesink=device('nicos.devices.datasinks.AsciiScanfileSink', ), conssink=device('nicos.devices.datasinks.ConsoleScanSink', ), daemonsink=device('nicos.devices.datasinks.DaemonSink', ), Space=device('nicos.devices.generic.FreeSpace', description='The amount of free space for storing data', path=None, minfree=5, ), )
description = 'system setup' group = 'lowlevel' sysconfig = dict(cache='localhost', instrument='Fluco', experiment='Exp', datasinks=['conssink', 'filesink', 'daemonsink']) modules = ['nicos.commands.standard', 'nicos_ess.commands.epics'] devices = dict(Fluco=device('nicos.devices.instrument.Instrument', description='instrument object', instrument='Fluco', responsible='S. Body <[email protected]>'), Sample=device('nicos.devices.sample.Sample', description='The currently used sample'), Exp=device('nicos.devices.experiment.Experiment', description='experiment object', dataroot='/opt/nicos-data', sendmail=True, serviceexp='p0', sample='Sample'), filesink=device('nicos.devices.datasinks.AsciiScanfileSink'), conssink=device('nicos.devices.datasinks.ConsoleScanSink'), daemonsink=device('nicos.devices.datasinks.DaemonSink'), Space=device('nicos.devices.generic.FreeSpace', description='The amount of free space for storing data', path=None, minfree=5))
i=2 while i < 10: j=1 while j < 10: print(i,"*",j,"=",i*j) j += 1 i += 1
i = 2 while i < 10: j = 1 while j < 10: print(i, '*', j, '=', i * j) j += 1 i += 1
# Program that asks the user to input any positive integer and # outputs the successive value of the following calculation. # It should at each step calculate the next value by taking the current value # if the it is even, divide it by two, if it is odd, multiply # it by three and add one # the program ends if the current value is one. # first number and then check if it has a positive value n = int(input("please enter a number: " )) while n != 1: # eliminating 0 and negative numbers if n <= 0: print("Please enter a positive number.") break # for even numbers: elif n % 2== 0: n=int(n/2) print(n) # for other integers (odd numbers) else: n=int(n*3+1) print(n)
n = int(input('please enter a number: ')) while n != 1: if n <= 0: print('Please enter a positive number.') break elif n % 2 == 0: n = int(n / 2) print(n) else: n = int(n * 3 + 1) print(n)
df =[['4', '1', '2', '7', '2', '5', '1'], ['9', '9', '8', '0', '2', '0', '8', '5', '0', '1', '3']] str='' dcf = ''.join(df) print(dcf) print()
df = [['4', '1', '2', '7', '2', '5', '1'], ['9', '9', '8', '0', '2', '0', '8', '5', '0', '1', '3']] str = '' dcf = ''.join(df) print(dcf) print()
parameters = { "results": [ { "type": "max", "identifier": { "symbol": "S22", "elset": "ALL_ELEMS", "position": "Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)" }, "referenceValue": 62.3, # YT "tolerance": 0.05 }, { "type": "disp_at_zero_y", "step": "Step-1", "identifier": [ { # x "symbol": "U2", "nset": "Y+", "position": "Node 3" }, { # y "symbol": "S22", "elset": "ALL_ELEMS", "position": "Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)" } ], "zeroTol": 0.00623, # Defines how close to zero the y value needs to be "referenceValue": 0.00889, # u_f = 2*GYT/YT "tolerance": 1e-5 }, { "type": "max", "identifier": { "symbol": "SDV_CDM_d2", "elset": "ALL_ELEMS", "position": "Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)" }, "referenceValue": 1.0, "tolerance": 0.0 }, { "type": "max", "identifier": { "symbol": "SDV_CDM_d1T", "elset": "ALL_ELEMS", "position": "Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)" }, "referenceValue": 0.0, "tolerance": 0.0 }, { "type": "max", "identifier": { "symbol": "SDV_CDM_d1C", "elset": "ALL_ELEMS", "position": "Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)" }, "referenceValue": 0.0, "tolerance": 0.0 }, { "type": "continuous", "identifier": { "symbol": "S22", "elset": "ALL_ELEMS", "position": "Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)" }, "referenceValue": 0.0, "tolerance": 0.1 } ] }
parameters = {'results': [{'type': 'max', 'identifier': {'symbol': 'S22', 'elset': 'ALL_ELEMS', 'position': 'Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)'}, 'referenceValue': 62.3, 'tolerance': 0.05}, {'type': 'disp_at_zero_y', 'step': 'Step-1', 'identifier': [{'symbol': 'U2', 'nset': 'Y+', 'position': 'Node 3'}, {'symbol': 'S22', 'elset': 'ALL_ELEMS', 'position': 'Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)'}], 'zeroTol': 0.00623, 'referenceValue': 0.00889, 'tolerance': 1e-05}, {'type': 'max', 'identifier': {'symbol': 'SDV_CDM_d2', 'elset': 'ALL_ELEMS', 'position': 'Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)'}, 'referenceValue': 1.0, 'tolerance': 0.0}, {'type': 'max', 'identifier': {'symbol': 'SDV_CDM_d1T', 'elset': 'ALL_ELEMS', 'position': 'Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)'}, 'referenceValue': 0.0, 'tolerance': 0.0}, {'type': 'max', 'identifier': {'symbol': 'SDV_CDM_d1C', 'elset': 'ALL_ELEMS', 'position': 'Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)'}, 'referenceValue': 0.0, 'tolerance': 0.0}, {'type': 'continuous', 'identifier': {'symbol': 'S22', 'elset': 'ALL_ELEMS', 'position': 'Element 1 Int Point 1 Sec Pt SPOS, (fraction = 1:0)'}, 'referenceValue': 0.0, 'tolerance': 0.1}]}
class Solution: def wordBreak(self, s: str, wordDict: List[str]) -> bool: def check(t, a, dp): n=len(t) for k in range(1, n): if dp[a+0][a+k-1] and dp[a+k][a+n-1]: return 1 return 0 n=len(s) dp=[[0 for j in range(n)] for i in range(n)] for i in range(n): for j in range(n-i): t=s[j:j+i+1] if t in wordDict: dp[j][j+i]=1 else: dp[j][j+i]=check(t, j, dp) return dp[0][n-1]==1
class Solution: def word_break(self, s: str, wordDict: List[str]) -> bool: def check(t, a, dp): n = len(t) for k in range(1, n): if dp[a + 0][a + k - 1] and dp[a + k][a + n - 1]: return 1 return 0 n = len(s) dp = [[0 for j in range(n)] for i in range(n)] for i in range(n): for j in range(n - i): t = s[j:j + i + 1] if t in wordDict: dp[j][j + i] = 1 else: dp[j][j + i] = check(t, j, dp) return dp[0][n - 1] == 1
expected_output = { "clock_state": { "system_status": { "associations_address": "10.16.2.2", "associations_local_mode": "client", "clock_offset": 27.027, "clock_refid": "127.127.1.1", "clock_state": "synchronized", "clock_stratum": 3, "root_delay": 5.61, } }, "peer": { "10.16.2.2": { "local_mode": { "client": { "delay": 5.61, "jitter": 3.342, "mode": "synchronized", "offset": 27.027, "poll": 64, "reach": 7, "receive_time": 25, "refid": "127.127.1.1", "remote": "10.16.2.2", "stratum": 3, "configured": True, "local_mode": "client", } } }, "10.36.3.3": { "local_mode": { "client": { "delay": 0.0, "jitter": 15937.0, "mode": "unsynchronized", "offset": 0.0, "poll": 512, "reach": 0, "receive_time": "-", "refid": ".STEP.", "remote": "10.36.3.3", "stratum": 16, "configured": True, "local_mode": "client", } } }, }, }
expected_output = {'clock_state': {'system_status': {'associations_address': '10.16.2.2', 'associations_local_mode': 'client', 'clock_offset': 27.027, 'clock_refid': '127.127.1.1', 'clock_state': 'synchronized', 'clock_stratum': 3, 'root_delay': 5.61}}, 'peer': {'10.16.2.2': {'local_mode': {'client': {'delay': 5.61, 'jitter': 3.342, 'mode': 'synchronized', 'offset': 27.027, 'poll': 64, 'reach': 7, 'receive_time': 25, 'refid': '127.127.1.1', 'remote': '10.16.2.2', 'stratum': 3, 'configured': True, 'local_mode': 'client'}}}, '10.36.3.3': {'local_mode': {'client': {'delay': 0.0, 'jitter': 15937.0, 'mode': 'unsynchronized', 'offset': 0.0, 'poll': 512, 'reach': 0, 'receive_time': '-', 'refid': '.STEP.', 'remote': '10.36.3.3', 'stratum': 16, 'configured': True, 'local_mode': 'client'}}}}}
#!/usr/python3.5 #-*- coding: utf-8 -*- for row in range(10): for j in range(row): print (" ",end=" ") for i in range(10-row): print (i,end=" ") print ()
for row in range(10): for j in range(row): print(' ', end=' ') for i in range(10 - row): print(i, end=' ') print()
__author__ = 'Aaron Yang' __email__ = '[email protected]' __date__ = '1/10/2021 10:53 PM' class Solution: def smallestStringWithSwaps(self, s: str, pairs) -> str: chars = list(s) pairs.sort(key=lambda item: (item[0], item[1])) for pair in pairs: a, b = pair[0], pair[1] chars[a], chars[b] = chars[b], chars[a] return ''.join(chars) Solution().smallestStringWithSwaps("dcab", [[0, 3], [1, 2], [0, 2]])
__author__ = 'Aaron Yang' __email__ = '[email protected]' __date__ = '1/10/2021 10:53 PM' class Solution: def smallest_string_with_swaps(self, s: str, pairs) -> str: chars = list(s) pairs.sort(key=lambda item: (item[0], item[1])) for pair in pairs: (a, b) = (pair[0], pair[1]) (chars[a], chars[b]) = (chars[b], chars[a]) return ''.join(chars) solution().smallestStringWithSwaps('dcab', [[0, 3], [1, 2], [0, 2]])
# test bignum unary operations i = 1 << 65 print(bool(i)) print(+i) print(-i) print(~i)
i = 1 << 65 print(bool(i)) print(+i) print(-i) print(~i)
def zeroes(n, cnt): if n == 0: return cnt elif n % 10 == 0: return zeroes(n//10, cnt+1) else: return zeroes(n//10, cnt) n = int(input()) print(zeroes(n, 0))
def zeroes(n, cnt): if n == 0: return cnt elif n % 10 == 0: return zeroes(n // 10, cnt + 1) else: return zeroes(n // 10, cnt) n = int(input()) print(zeroes(n, 0))
req = { "userId": "admin", "metadata": { "@context": [ "https://w3id.org/ro/crate/1.0/context", { "@vocab": "https://schema.org/", "osfcategory": "https://www.research-data-services.org/jsonld/osfcategory", "zenodocategory": "https://www.research-data-services.org/jsonld/zenodocategory", }, ], "@graph": [ { "@id": "ro-crate-metadata.json", "@type": "CreativeWork", "about": {"@id": "./"}, "identifier": "ro-crate-metadata.json", "conformsTo": {"@id": "https://w3id.org/ro/crate/1.0"}, "license": {"@id": "https://creativecommons.org/licenses/by-sa/3.0"}, "description": "Made with Describo: https://uts-eresearch.github.io/describo/", }, { "@type": "Dataset", "datePublished": "2020-09-29T22:00:00.000Z", "name": ["testtitle"], "description": ["Beispieltest. Ganz viel\n\nasd mit umbruch"], "creator": [ {"@id": "#edf6055e-9985-4dfe-9759-8f1aa640d396"}, {"@id": "#ac356e5f-fb71-400e-904e-a473c4fc890d"}, ], "zenodocategory": "publication/thesis", "osfcategory": "analysis", "@id": "./", }, { "@type": "Person", "@reverse": {"creator": [{"@id": "./"}]}, "name": "Peter Heiss", "familyName": "Heiss", "givenName": "Peter", "affiliation": [{"@id": "#4bafacfd-e123-44dc-90b9-63f974f85694"}], "@id": "#edf6055e-9985-4dfe-9759-8f1aa640d396", }, { "@type": "Organization", "name": "WWU", "@reverse": { "affiliation": [{"@id": "#edf6055e-9985-4dfe-9759-8f1aa640d396"}] }, "@id": "#4bafacfd-e123-44dc-90b9-63f974f85694", }, { "@type": "Person", "name": "Jens Stegmann", "familyName": "Stegmann", "givenName": "Jens", "email": "", "@reverse": {"creator": [{"@id": "./"}]}, "@id": "#ac356e5f-fb71-400e-904e-a473c4fc890d", }, ], }, } result = { "data": { "type": "nodes", "attributes": { "description": "Beispieltest. Ganz viel asd mit umbruch", "category": "analysis", "title": "testtitle", }, } }
req = {'userId': 'admin', 'metadata': {'@context': ['https://w3id.org/ro/crate/1.0/context', {'@vocab': 'https://schema.org/', 'osfcategory': 'https://www.research-data-services.org/jsonld/osfcategory', 'zenodocategory': 'https://www.research-data-services.org/jsonld/zenodocategory'}], '@graph': [{'@id': 'ro-crate-metadata.json', '@type': 'CreativeWork', 'about': {'@id': './'}, 'identifier': 'ro-crate-metadata.json', 'conformsTo': {'@id': 'https://w3id.org/ro/crate/1.0'}, 'license': {'@id': 'https://creativecommons.org/licenses/by-sa/3.0'}, 'description': 'Made with Describo: https://uts-eresearch.github.io/describo/'}, {'@type': 'Dataset', 'datePublished': '2020-09-29T22:00:00.000Z', 'name': ['testtitle'], 'description': ['Beispieltest. Ganz viel\n\nasd mit umbruch'], 'creator': [{'@id': '#edf6055e-9985-4dfe-9759-8f1aa640d396'}, {'@id': '#ac356e5f-fb71-400e-904e-a473c4fc890d'}], 'zenodocategory': 'publication/thesis', 'osfcategory': 'analysis', '@id': './'}, {'@type': 'Person', '@reverse': {'creator': [{'@id': './'}]}, 'name': 'Peter Heiss', 'familyName': 'Heiss', 'givenName': 'Peter', 'affiliation': [{'@id': '#4bafacfd-e123-44dc-90b9-63f974f85694'}], '@id': '#edf6055e-9985-4dfe-9759-8f1aa640d396'}, {'@type': 'Organization', 'name': 'WWU', '@reverse': {'affiliation': [{'@id': '#edf6055e-9985-4dfe-9759-8f1aa640d396'}]}, '@id': '#4bafacfd-e123-44dc-90b9-63f974f85694'}, {'@type': 'Person', 'name': 'Jens Stegmann', 'familyName': 'Stegmann', 'givenName': 'Jens', 'email': '', '@reverse': {'creator': [{'@id': './'}]}, '@id': '#ac356e5f-fb71-400e-904e-a473c4fc890d'}]}} result = {'data': {'type': 'nodes', 'attributes': {'description': 'Beispieltest. Ganz viel asd mit umbruch', 'category': 'analysis', 'title': 'testtitle'}}}
class GoogleException(Exception): def __init__(self, code, message, response): self.status_code = code self.error_type = message self.message = message self.response = response self.get_error_type() def get_error_type(self): json_response = self.response.json() if 'error' in json_response and 'errors' in json_response['error']: self.error_type = json_response['error']['errors'][0]['reason']
class Googleexception(Exception): def __init__(self, code, message, response): self.status_code = code self.error_type = message self.message = message self.response = response self.get_error_type() def get_error_type(self): json_response = self.response.json() if 'error' in json_response and 'errors' in json_response['error']: self.error_type = json_response['error']['errors'][0]['reason']
command = input().lower() in_progress = True car_stopped = True while in_progress: if command == 'help': print("start - to start the car") print("stop - to stop the car") print("quit - to ext") elif command == 'start': if car_stopped: print("You started the car") car_stopped = False else: print("The car has already been started") elif command == 'stop': if not car_stopped: print("You stopped the car") car_stopped = True else: print("The car is already stopped") elif command == 'quit': print("Exiting the program now") in_progress = False break else: print("That was not a valid command, try again. Enter 'help' for a list of valid commands") command = input().lower()
command = input().lower() in_progress = True car_stopped = True while in_progress: if command == 'help': print('start - to start the car') print('stop - to stop the car') print('quit - to ext') elif command == 'start': if car_stopped: print('You started the car') car_stopped = False else: print('The car has already been started') elif command == 'stop': if not car_stopped: print('You stopped the car') car_stopped = True else: print('The car is already stopped') elif command == 'quit': print('Exiting the program now') in_progress = False break else: print("That was not a valid command, try again. Enter 'help' for a list of valid commands") command = input().lower()
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2014, Chris Hoffman <[email protected]> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) DOCUMENTATION = r''' --- module: win_service short_description: Manage and query Windows services description: - Manage and query Windows services. - For non-Windows targets, use the M(ansible.builtin.service) module instead. options: dependencies: description: - A list of service dependencies to set for this particular service. - This should be a list of service names and not the display name of the service. - This works by C(dependency_action) to either add/remove or set the services in this list. type: list elements: str dependency_action: description: - Used in conjunction with C(dependency) to either add the dependencies to the existing service dependencies. - Remove the dependencies to the existing dependencies. - Set the dependencies to only the values in the list replacing the existing dependencies. type: str choices: [ add, remove, set ] default: set desktop_interact: description: - Whether to allow the service user to interact with the desktop. - This can only be set to C(yes) when using the C(LocalSystem) username. - This can only be set to C(yes) when the I(service_type) is C(win32_own_process) or C(win32_share_process). type: bool default: no description: description: - The description to set for the service. type: str display_name: description: - The display name to set for the service. type: str error_control: description: - The severity of the error and action token if the service fails to start. - A new service defaults to C(normal). - C(critical) will log the error and restart the system with the last-known good configuration. If the startup fails on reboot then the system will fail to operate. - C(ignore) ignores the error. - C(normal) logs the error in the event log but continues. - C(severe) is like C(critical) but a failure on the last-known good configuration reboot startup will be ignored. choices: - critical - ignore - normal - severe type: str failure_actions: description: - A list of failure actions the service controller should take on each failure of a service. - The service manager will run the actions from first to last defined until the service starts. If I(failure_reset_period_sec) has been exceeded then the failure actions will restart from the beginning. - If all actions have been performed the the service manager will repeat the last service defined. - The existing actions will be replaced with the list defined in the task if there is a mismatch with any of them. - Set to an empty list to delete all failure actions on a service otherwise an omitted or null value preserves the existing actions on the service. type: list elements: dict suboptions: delay_ms: description: - The time to wait, in milliseconds, before performing the specified action. default: 0 type: raw aliases: - delay type: description: - The action to be performed. - C(none) will perform no action, when used this should only be set as the last action. - C(reboot) will reboot the host, when used this should only be set as the last action as the reboot will reset the action list back to the beginning. - C(restart) will restart the service. - C(run_command) will run the command specified by I(failure_command). required: yes type: str choices: - none - reboot - restart - run_command failure_actions_on_non_crash_failure: description: - Controls whether failure actions will be performed on non crash failures or not. type: bool failure_command: description: - The command to run for a C(run_command) failure action. - Set to an empty string to remove the command. type: str failure_reboot_msg: description: - The message to be broadcast to users logged on the host for a C(reboot) failure action. - Set to an empty string to remove the message. type: str failure_reset_period_sec: description: - The time in seconds after which the failure action list begings from the start if there are no failures. - To set this value, I(failure_actions) must have at least 1 action present. - Specify C('0xFFFFFFFF') to set an infinite reset period. type: raw aliases: - failure_reset_period force_dependent_services: description: - If C(yes), stopping or restarting a service with dependent services will force the dependent services to stop or restart also. - If C(no), stopping or restarting a service with dependent services may fail. type: bool default: no load_order_group: description: - The name of the load ordering group of which this service is a member. - Specify an empty string to remove the existing load order group of a service. type: str name: description: - Name of the service. - If only the name parameter is specified, the module will report on whether the service exists or not without making any changes. required: yes type: str path: description: - The path to the executable to set for the service. type: str password: description: - The password to set the service to start as. - This and the C(username) argument should be supplied together when using a local or domain account. - If omitted then the password will continue to use the existing value password set. - If specifying C(LocalSystem), C(NetworkService), C(LocalService), the C(NT SERVICE), or a gMSA this field can be omitted as those accounts have no password. type: str pre_shutdown_timeout_ms: description: - The time in which the service manager waits after sending a preshutdown notification to the service until it proceeds to continue with the other shutdown actions. aliases: - pre_shutdown_timeout type: raw required_privileges: description: - A list of privileges the service must have when starting up. - When set the service will only have the privileges specified on its access token. - The I(username) of the service must already have the privileges assigned. - The existing privileges will be replace with the list defined in the task if there is a mismatch with any of them. - Set to an empty list to remove all required privileges, otherwise an omitted or null value will keep the existing privileges. - See L(privilege text constants,https://docs.microsoft.com/en-us/windows/win32/secauthz/privilege-constants) for a list of privilege constants that can be used. type: list elements: str service_type: description: - The type of service. - The default type of a new service is C(win32_own_process). - I(desktop_interact) can only be set if the service type is C(win32_own_process) or C(win32_share_process). choices: - user_own_process - user_share_process - win32_own_process - win32_share_process type: str sid_info: description: - Used to define the behaviour of the service's access token groups. - C(none) will not add any groups to the token. - C(restricted) will add the C(NT SERVICE\<service name>) SID to the access token's groups and restricted groups. - C(unrestricted) will add the C(NT SERVICE\<service name>) SID to the access token's groups. choices: - none - restricted - unrestricted type: str start_mode: description: - Set the startup type for the service. - A newly created service will default to C(auto). type: str choices: [ auto, delayed, disabled, manual ] state: description: - The desired state of the service. - C(started)/C(stopped)/C(absent)/C(paused) are idempotent actions that will not run commands unless necessary. - C(restarted) will always bounce the service. - Only services that support the paused state can be paused, you can check the return value C(can_pause_and_continue). - You can only pause a service that is already started. - A newly created service will default to C(stopped). type: str choices: [ absent, paused, started, stopped, restarted ] update_password: description: - When set to C(always) and I(password) is set, the module will always report a change and set the password. - Set to C(on_create) to only set the password if the module needs to create the service. - If I(username) was specified and the service changed to that username then I(password) will also be changed if specified. - The current default is C(on_create) but this behaviour may change in the future, it is best to be explicit here. choices: - always - on_create type: str username: description: - The username to set the service to start as. - Can also be set to C(LocalSystem) or C(SYSTEM) to use the SYSTEM account. - A newly created service will default to C(LocalSystem). - If using a custom user account, it must have the C(SeServiceLogonRight) granted to be able to start up. You can use the M(ansible.windows.win_user_right) module to grant this user right for you. - Set to C(NT SERVICE\service name) to run as the NT SERVICE account for that service. - This can also be a gMSA in the form C(DOMAIN\gMSA$). type: str notes: - This module historically returning information about the service in its return values. These should be avoided in favour of the M(ansible.windows.win_service_info) module. - Most of the options in this module are non-driver services that you can view in SCManager. While you can edit driver services, not all functionality may be available. - The user running the module must have the following access rights on the service to be able to use it with this module - C(SERVICE_CHANGE_CONFIG), C(SERVICE_ENUMERATE_DEPENDENTS), C(SERVICE_QUERY_CONFIG), C(SERVICE_QUERY_STATUS). - Changing the state or removing the service will also require futher rights depending on what needs to be done. seealso: - module: ansible.builtin.service - module: community.windows.win_nssm - module: ansible.windows.win_service_info - module: ansible.windows.win_user_right author: - Chris Hoffman (@chrishoffman) ''' EXAMPLES = r''' - name: Restart a service ansible.windows.win_service: name: spooler state: restarted - name: Set service startup mode to auto and ensure it is started ansible.windows.win_service: name: spooler start_mode: auto state: started - name: Pause a service ansible.windows.win_service: name: Netlogon state: paused - name: Ensure that WinRM is started when the system has settled ansible.windows.win_service: name: WinRM start_mode: delayed # A new service will also default to the following values: # - username: LocalSystem # - state: stopped # - start_mode: auto - name: Create a new service ansible.windows.win_service: name: service name path: C:\temp\test.exe - name: Create a new service with extra details ansible.windows.win_service: name: service name path: C:\temp\test.exe display_name: Service Name description: A test service description - name: Remove a service ansible.windows.win_service: name: service name state: absent # This is required to be set for non-service accounts that need to run as a service - name: Grant domain account the SeServiceLogonRight user right ansible.windows.win_user_right: name: SeServiceLogonRight users: - DOMAIN\User action: add - name: Set the log on user to a domain account ansible.windows.win_service: name: service name state: restarted username: DOMAIN\User password: Password - name: Set the log on user to a local account ansible.windows.win_service: name: service name state: restarted username: .\Administrator password: Password - name: Set the log on user to Local System ansible.windows.win_service: name: service name state: restarted username: SYSTEM - name: Set the log on user to Local System and allow it to interact with the desktop ansible.windows.win_service: name: service name state: restarted username: SYSTEM desktop_interact: yes - name: Set the log on user to Network Service ansible.windows.win_service: name: service name state: restarted username: NT AUTHORITY\NetworkService - name: Set the log on user to Local Service ansible.windows.win_service: name: service name state: restarted username: NT AUTHORITY\LocalService - name: Set the log on user as the services' virtual account ansible.windows.win_service: name: service name username: NT SERVICE\service name - name: Set the log on user as a gMSA ansible.windows.win_service: name: service name username: DOMAIN\gMSA$ # The end $ is important and should be set for all gMSA - name: Set dependencies to ones only in the list ansible.windows.win_service: name: service name dependencies: [ service1, service2 ] - name: Add dependencies to existing dependencies ansible.windows.win_service: name: service name dependencies: [ service1, service2 ] dependency_action: add - name: Remove dependencies from existing dependencies ansible.windows.win_service: name: service name dependencies: - service1 - service2 dependency_action: remove - name: Set required privileges for a service ansible.windows.win_service: name: service name username: NT SERVICE\LocalService required_privileges: - SeBackupPrivilege - SeRestorePrivilege - name: Remove all required privileges for a service ansible.windows.win_service: name: service name username: NT SERVICE\LocalService required_privileges: [] - name: Set failure actions for a service with no reset period ansible.windows.win_service: name: service name failure_actions: - type: restart - type: run_command delay_ms: 1000 - type: restart delay_ms: 5000 - type: reboot failure_command: C:\Windows\System32\cmd.exe /c mkdir C:\temp failure_reboot_msg: Restarting host because service name has failed failure_reset_period_sec: '0xFFFFFFFF' - name: Set only 1 failure action without a repeat of the last action ansible.windows.win_service: name: service name failure_actions: - type: restart delay_ms: 5000 - type: none - name: Remove failure action information ansible.windows.win_service: name: service name failure_actions: [] failure_command: '' # removes the existing command failure_reboot_msg: '' # removes the existing reboot msg ''' RETURN = r''' exists: description: Whether the service exists or not. returned: success type: bool sample: true name: description: The service name or id of the service. returned: success and service exists type: str sample: CoreMessagingRegistrar display_name: description: The display name of the installed service. returned: success and service exists type: str sample: CoreMessaging state: description: The current running status of the service. returned: success and service exists type: str sample: stopped start_mode: description: The startup type of the service. returned: success and service exists type: str sample: manual path: description: The path to the service executable. returned: success and service exists type: str sample: C:\Windows\system32\svchost.exe -k LocalServiceNoNetwork can_pause_and_continue: description: Whether the service can be paused and unpaused. returned: success and service exists type: bool sample: true description: description: The description of the service. returned: success and service exists type: str sample: Manages communication between system components. username: description: The username that runs the service. returned: success and service exists type: str sample: LocalSystem desktop_interact: description: Whether the current user is allowed to interact with the desktop. returned: success and service exists type: bool sample: false dependencies: description: A list of services that is depended by this service. returned: success and service exists type: list sample: false depended_by: description: A list of services that depend on this service. returned: success and service exists type: list sample: false '''
documentation = "\n---\nmodule: win_service\nshort_description: Manage and query Windows services\ndescription:\n- Manage and query Windows services.\n- For non-Windows targets, use the M(ansible.builtin.service) module instead.\noptions:\n dependencies:\n description:\n - A list of service dependencies to set for this particular service.\n - This should be a list of service names and not the display name of the\n service.\n - This works by C(dependency_action) to either add/remove or set the\n services in this list.\n type: list\n elements: str\n dependency_action:\n description:\n - Used in conjunction with C(dependency) to either add the dependencies to\n the existing service dependencies.\n - Remove the dependencies to the existing dependencies.\n - Set the dependencies to only the values in the list replacing the\n existing dependencies.\n type: str\n choices: [ add, remove, set ]\n default: set\n desktop_interact:\n description:\n - Whether to allow the service user to interact with the desktop.\n - This can only be set to C(yes) when using the C(LocalSystem) username.\n - This can only be set to C(yes) when the I(service_type) is\n C(win32_own_process) or C(win32_share_process).\n type: bool\n default: no\n description:\n description:\n - The description to set for the service.\n type: str\n display_name:\n description:\n - The display name to set for the service.\n type: str\n error_control:\n description:\n - The severity of the error and action token if the service fails to start.\n - A new service defaults to C(normal).\n - C(critical) will log the error and restart the system with the last-known\n good configuration. If the startup fails on reboot then the system will\n fail to operate.\n - C(ignore) ignores the error.\n - C(normal) logs the error in the event log but continues.\n - C(severe) is like C(critical) but a failure on the last-known good\n configuration reboot startup will be ignored.\n choices:\n - critical\n - ignore\n - normal\n - severe\n type: str\n failure_actions:\n description:\n - A list of failure actions the service controller should take on each\n failure of a service.\n - The service manager will run the actions from first to last defined until\n the service starts. If I(failure_reset_period_sec) has been exceeded then\n the failure actions will restart from the beginning.\n - If all actions have been performed the the service manager will repeat\n the last service defined.\n - The existing actions will be replaced with the list defined in the task\n if there is a mismatch with any of them.\n - Set to an empty list to delete all failure actions on a service\n otherwise an omitted or null value preserves the existing actions on the\n service.\n type: list\n elements: dict\n suboptions:\n delay_ms:\n description:\n - The time to wait, in milliseconds, before performing the specified action.\n default: 0\n type: raw\n aliases:\n - delay\n type:\n description:\n - The action to be performed.\n - C(none) will perform no action, when used this should only be set as\n the last action.\n - C(reboot) will reboot the host, when used this should only be set as\n the last action as the reboot will reset the action list back to the\n beginning.\n - C(restart) will restart the service.\n - C(run_command) will run the command specified by I(failure_command).\n required: yes\n type: str\n choices:\n - none\n - reboot\n - restart\n - run_command\n failure_actions_on_non_crash_failure:\n description:\n - Controls whether failure actions will be performed on non crash failures\n or not.\n type: bool\n failure_command:\n description:\n - The command to run for a C(run_command) failure action.\n - Set to an empty string to remove the command.\n type: str\n failure_reboot_msg:\n description:\n - The message to be broadcast to users logged on the host for a C(reboot)\n failure action.\n - Set to an empty string to remove the message.\n type: str\n failure_reset_period_sec:\n description:\n - The time in seconds after which the failure action list begings from the\n start if there are no failures.\n - To set this value, I(failure_actions) must have at least 1 action\n present.\n - Specify C('0xFFFFFFFF') to set an infinite reset period.\n type: raw\n aliases:\n - failure_reset_period\n force_dependent_services:\n description:\n - If C(yes), stopping or restarting a service with dependent services will\n force the dependent services to stop or restart also.\n - If C(no), stopping or restarting a service with dependent services may\n fail.\n type: bool\n default: no\n load_order_group:\n description:\n - The name of the load ordering group of which this service is a member.\n - Specify an empty string to remove the existing load order group of a\n service.\n type: str\n name:\n description:\n - Name of the service.\n - If only the name parameter is specified, the module will report\n on whether the service exists or not without making any changes.\n required: yes\n type: str\n path:\n description:\n - The path to the executable to set for the service.\n type: str\n password:\n description:\n - The password to set the service to start as.\n - This and the C(username) argument should be supplied together when using a local or domain account.\n - If omitted then the password will continue to use the existing value password set.\n - If specifying C(LocalSystem), C(NetworkService), C(LocalService), the C(NT SERVICE), or a gMSA this field can be\n omitted as those accounts have no password.\n type: str\n pre_shutdown_timeout_ms:\n description:\n - The time in which the service manager waits after sending a preshutdown\n notification to the service until it proceeds to continue with the other\n shutdown actions.\n aliases:\n - pre_shutdown_timeout\n type: raw\n required_privileges:\n description:\n - A list of privileges the service must have when starting up.\n - When set the service will only have the privileges specified on its\n access token.\n - The I(username) of the service must already have the privileges assigned.\n - The existing privileges will be replace with the list defined in the task\n if there is a mismatch with any of them.\n - Set to an empty list to remove all required privileges, otherwise an\n omitted or null value will keep the existing privileges.\n - See L(privilege text constants,https://docs.microsoft.com/en-us/windows/win32/secauthz/privilege-constants)\n for a list of privilege constants that can be used.\n type: list\n elements: str\n service_type:\n description:\n - The type of service.\n - The default type of a new service is C(win32_own_process).\n - I(desktop_interact) can only be set if the service type is\n C(win32_own_process) or C(win32_share_process).\n choices:\n - user_own_process\n - user_share_process\n - win32_own_process\n - win32_share_process\n type: str\n sid_info:\n description:\n - Used to define the behaviour of the service's access token groups.\n - C(none) will not add any groups to the token.\n - C(restricted) will add the C(NT SERVICE\\<service name>) SID to the access\n token's groups and restricted groups.\n - C(unrestricted) will add the C(NT SERVICE\\<service name>) SID to the\n access token's groups.\n choices:\n - none\n - restricted\n - unrestricted\n type: str\n start_mode:\n description:\n - Set the startup type for the service.\n - A newly created service will default to C(auto).\n type: str\n choices: [ auto, delayed, disabled, manual ]\n state:\n description:\n - The desired state of the service.\n - C(started)/C(stopped)/C(absent)/C(paused) are idempotent actions that will not run\n commands unless necessary.\n - C(restarted) will always bounce the service.\n - Only services that support the paused state can be paused, you can\n check the return value C(can_pause_and_continue).\n - You can only pause a service that is already started.\n - A newly created service will default to C(stopped).\n type: str\n choices: [ absent, paused, started, stopped, restarted ]\n update_password:\n description:\n - When set to C(always) and I(password) is set, the module will always report a change and set the password.\n - Set to C(on_create) to only set the password if the module needs to create the service.\n - If I(username) was specified and the service changed to that username then I(password) will also be changed if\n specified.\n - The current default is C(on_create) but this behaviour may change in the future, it is best to be explicit here.\n choices:\n - always\n - on_create\n type: str\n username:\n description:\n - The username to set the service to start as.\n - Can also be set to C(LocalSystem) or C(SYSTEM) to use the SYSTEM account.\n - A newly created service will default to C(LocalSystem).\n - If using a custom user account, it must have the C(SeServiceLogonRight)\n granted to be able to start up. You can use the M(ansible.windows.win_user_right) module\n to grant this user right for you.\n - Set to C(NT SERVICE\\service name) to run as the NT SERVICE account for that service.\n - This can also be a gMSA in the form C(DOMAIN\\gMSA$).\n type: str\nnotes:\n- This module historically returning information about the service in its return values. These should be avoided in\n favour of the M(ansible.windows.win_service_info) module.\n- Most of the options in this module are non-driver services that you can view in SCManager. While you can edit driver\n services, not all functionality may be available.\n- The user running the module must have the following access rights on the service to be able to use it with this\n module - C(SERVICE_CHANGE_CONFIG), C(SERVICE_ENUMERATE_DEPENDENTS), C(SERVICE_QUERY_CONFIG), C(SERVICE_QUERY_STATUS).\n- Changing the state or removing the service will also require futher rights depending on what needs to be done.\nseealso:\n- module: ansible.builtin.service\n- module: community.windows.win_nssm\n- module: ansible.windows.win_service_info\n- module: ansible.windows.win_user_right\nauthor:\n- Chris Hoffman (@chrishoffman)\n" examples = "\n- name: Restart a service\n ansible.windows.win_service:\n name: spooler\n state: restarted\n\n- name: Set service startup mode to auto and ensure it is started\n ansible.windows.win_service:\n name: spooler\n start_mode: auto\n state: started\n\n- name: Pause a service\n ansible.windows.win_service:\n name: Netlogon\n state: paused\n\n- name: Ensure that WinRM is started when the system has settled\n ansible.windows.win_service:\n name: WinRM\n start_mode: delayed\n\n# A new service will also default to the following values:\n# - username: LocalSystem\n# - state: stopped\n# - start_mode: auto\n- name: Create a new service\n ansible.windows.win_service:\n name: service name\n path: C:\\temp\\test.exe\n\n- name: Create a new service with extra details\n ansible.windows.win_service:\n name: service name\n path: C:\\temp\\test.exe\n display_name: Service Name\n description: A test service description\n\n- name: Remove a service\n ansible.windows.win_service:\n name: service name\n state: absent\n\n# This is required to be set for non-service accounts that need to run as a service\n- name: Grant domain account the SeServiceLogonRight user right\n ansible.windows.win_user_right:\n name: SeServiceLogonRight\n users:\n - DOMAIN\\User\n action: add\n\n- name: Set the log on user to a domain account\n ansible.windows.win_service:\n name: service name\n state: restarted\n username: DOMAIN\\User\n password: Password\n\n- name: Set the log on user to a local account\n ansible.windows.win_service:\n name: service name\n state: restarted\n username: .\\Administrator\n password: Password\n\n- name: Set the log on user to Local System\n ansible.windows.win_service:\n name: service name\n state: restarted\n username: SYSTEM\n\n- name: Set the log on user to Local System and allow it to interact with the desktop\n ansible.windows.win_service:\n name: service name\n state: restarted\n username: SYSTEM\n desktop_interact: yes\n\n- name: Set the log on user to Network Service\n ansible.windows.win_service:\n name: service name\n state: restarted\n username: NT AUTHORITY\\NetworkService\n\n- name: Set the log on user to Local Service\n ansible.windows.win_service:\n name: service name\n state: restarted\n username: NT AUTHORITY\\LocalService\n\n- name: Set the log on user as the services' virtual account\n ansible.windows.win_service:\n name: service name\n username: NT SERVICE\\service name\n\n- name: Set the log on user as a gMSA\n ansible.windows.win_service:\n name: service name\n username: DOMAIN\\gMSA$ # The end $ is important and should be set for all gMSA\n\n- name: Set dependencies to ones only in the list\n ansible.windows.win_service:\n name: service name\n dependencies: [ service1, service2 ]\n\n- name: Add dependencies to existing dependencies\n ansible.windows.win_service:\n name: service name\n dependencies: [ service1, service2 ]\n dependency_action: add\n\n- name: Remove dependencies from existing dependencies\n ansible.windows.win_service:\n name: service name\n dependencies:\n - service1\n - service2\n dependency_action: remove\n\n- name: Set required privileges for a service\n ansible.windows.win_service:\n name: service name\n username: NT SERVICE\\LocalService\n required_privileges:\n - SeBackupPrivilege\n - SeRestorePrivilege\n\n- name: Remove all required privileges for a service\n ansible.windows.win_service:\n name: service name\n username: NT SERVICE\\LocalService\n required_privileges: []\n\n- name: Set failure actions for a service with no reset period\n ansible.windows.win_service:\n name: service name\n failure_actions:\n - type: restart\n - type: run_command\n delay_ms: 1000\n - type: restart\n delay_ms: 5000\n - type: reboot\n failure_command: C:\\Windows\\System32\\cmd.exe /c mkdir C:\\temp\n failure_reboot_msg: Restarting host because service name has failed\n failure_reset_period_sec: '0xFFFFFFFF'\n\n- name: Set only 1 failure action without a repeat of the last action\n ansible.windows.win_service:\n name: service name\n failure_actions:\n - type: restart\n delay_ms: 5000\n - type: none\n\n- name: Remove failure action information\n ansible.windows.win_service:\n name: service name\n failure_actions: []\n failure_command: '' # removes the existing command\n failure_reboot_msg: '' # removes the existing reboot msg\n" return = '\nexists:\n description: Whether the service exists or not.\n returned: success\n type: bool\n sample: true\nname:\n description: The service name or id of the service.\n returned: success and service exists\n type: str\n sample: CoreMessagingRegistrar\ndisplay_name:\n description: The display name of the installed service.\n returned: success and service exists\n type: str\n sample: CoreMessaging\nstate:\n description: The current running status of the service.\n returned: success and service exists\n type: str\n sample: stopped\nstart_mode:\n description: The startup type of the service.\n returned: success and service exists\n type: str\n sample: manual\npath:\n description: The path to the service executable.\n returned: success and service exists\n type: str\n sample: C:\\Windows\\system32\\svchost.exe -k LocalServiceNoNetwork\ncan_pause_and_continue:\n description: Whether the service can be paused and unpaused.\n returned: success and service exists\n type: bool\n sample: true\ndescription:\n description: The description of the service.\n returned: success and service exists\n type: str\n sample: Manages communication between system components.\nusername:\n description: The username that runs the service.\n returned: success and service exists\n type: str\n sample: LocalSystem\ndesktop_interact:\n description: Whether the current user is allowed to interact with the desktop.\n returned: success and service exists\n type: bool\n sample: false\ndependencies:\n description: A list of services that is depended by this service.\n returned: success and service exists\n type: list\n sample: false\ndepended_by:\n description: A list of services that depend on this service.\n returned: success and service exists\n type: list\n sample: false\n'
# test exception matching against a tuple try: fail except (Exception,): print('except 1') try: fail except (Exception, Exception): print('except 2') try: fail except (TypeError, NameError): print('except 3') try: fail except (TypeError, ValueError, Exception): print('except 4')
try: fail except (Exception,): print('except 1') try: fail except (Exception, Exception): print('except 2') try: fail except (TypeError, NameError): print('except 3') try: fail except (TypeError, ValueError, Exception): print('except 4')
def printMaximum(num): d = {} for i in range(10): d[i] = 0 for i in str(num): d[int(i)] += 1 res = 0 m = 1 for i in list(d.keys()): while d[i] > 0: res = res + i*m d[i] -= 1 m *= 10 return res # Driver code num = 38293367 print(printMaximum(num))
def print_maximum(num): d = {} for i in range(10): d[i] = 0 for i in str(num): d[int(i)] += 1 res = 0 m = 1 for i in list(d.keys()): while d[i] > 0: res = res + i * m d[i] -= 1 m *= 10 return res num = 38293367 print(print_maximum(num))
NUMERIC = "numeric" CATEGORICAL = "categorical" TEST_MODEL = "test" SINGLE_MODEL = "single" MODEL_SEARCH = "search" SHUTDOWN = "shutdown" DEFAULT_PORT = 8042 DEFAULT_MAX_JOBS = 4 ERROR = "error" QUEUED = "queued" STARTED = "started" IN_PROGRESS = "in-progress" FINISHED = "finished" # This can be any x where np.exp(x) + 1 == np.exp(x) Going up to 512 # isn't strictly necessary, but hey, why not? LARGE_EXP = 512 EPSILON = 1e-4 # Parameters that can appear in the layers of models MATRIX_PARAMS = [ 'weights' ] VEC_PARAMS = [ 'mean', 'variance', 'offset', 'scale', 'stdev' ] # Model search parameters VALIDATION_FRAC = 0.15 MAX_VALIDATION_ROWS = 4096 LEARN_INCREMENT = 8 MAX_QUEUE = LEARN_INCREMENT * 4 N_CANDIDATES = MAX_QUEUE * 64
numeric = 'numeric' categorical = 'categorical' test_model = 'test' single_model = 'single' model_search = 'search' shutdown = 'shutdown' default_port = 8042 default_max_jobs = 4 error = 'error' queued = 'queued' started = 'started' in_progress = 'in-progress' finished = 'finished' large_exp = 512 epsilon = 0.0001 matrix_params = ['weights'] vec_params = ['mean', 'variance', 'offset', 'scale', 'stdev'] validation_frac = 0.15 max_validation_rows = 4096 learn_increment = 8 max_queue = LEARN_INCREMENT * 4 n_candidates = MAX_QUEUE * 64
class TopTen: def __init__(self): self.num = 1 def __iter__(self): return self def __next__(self): if self.num <= 10: val = self.num self.num += 1 return val else: raise StopIteration values = TopTen() print(next(values)) for i in values: print(i)
class Topten: def __init__(self): self.num = 1 def __iter__(self): return self def __next__(self): if self.num <= 10: val = self.num self.num += 1 return val else: raise StopIteration values = top_ten() print(next(values)) for i in values: print(i)
class cached_property: def __init__(self, func): self.__doc__ = getattr(func, "__doc__") self.func = func def __get__(self, obj, cls): if obj is None: return self value = obj.__dict__[self.func.__name__] = self.func(obj) return value
class Cached_Property: def __init__(self, func): self.__doc__ = getattr(func, '__doc__') self.func = func def __get__(self, obj, cls): if obj is None: return self value = obj.__dict__[self.func.__name__] = self.func(obj) return value
# Copyright (C) 2018-2021 Intel Corporation # SPDX-License-Identifier: Apache-2.0 def tf_pack_ext(pb): assert (pb.attr["N"].i == len(pb.input)) return { 'axis': pb.attr["axis"].i, 'N': pb.attr["N"].i, 'infer': None }
def tf_pack_ext(pb): assert pb.attr['N'].i == len(pb.input) return {'axis': pb.attr['axis'].i, 'N': pb.attr['N'].i, 'infer': None}
#!/usr/bin/python3 ls = [l.strip().split(" ") for l in open("inputs/08.in", "r").readlines()] def run(sw): acc,p,ps = 0,0,[] while p < len(ls): if p in ps: return acc if sw == -1 else -1 ps.append(p) acc += int(ls[p][1]) if ls[p][0] == "acc" else 0 p += int(ls[p][1]) if (ls[p][0]=="jmp" and sw!=p) or (ls[p][0]=="nop" and sw==p) else 1 return acc def brute(): for i,l in enumerate(ls): if l[0] == "acc": continue ans = run(i) if ans != -1: return ans print("Part 1:", run(-1)) print("Part 2:", brute())
ls = [l.strip().split(' ') for l in open('inputs/08.in', 'r').readlines()] def run(sw): (acc, p, ps) = (0, 0, []) while p < len(ls): if p in ps: return acc if sw == -1 else -1 ps.append(p) acc += int(ls[p][1]) if ls[p][0] == 'acc' else 0 p += int(ls[p][1]) if ls[p][0] == 'jmp' and sw != p or (ls[p][0] == 'nop' and sw == p) else 1 return acc def brute(): for (i, l) in enumerate(ls): if l[0] == 'acc': continue ans = run(i) if ans != -1: return ans print('Part 1:', run(-1)) print('Part 2:', brute())
counter = 0 def merge(array, left, right): i = j = k = 0 global counter while i < len(left) and j < len(right): if left[i] <= right[j]: array[k] = left[i] k += 1 i += 1 else: array[k] = right[j] counter += len(left) - i k += 1 j += 1 if len(left) > i: array[k:] = left[i:] elif len(right) > j: array[k:] = right[j:] def mergesort(array): if len(array) > 1: mid = len(array) // 2 left = array[:mid] right = array[mid:] mergesort(left) mergesort(right) merge(array, left, right) return array fin = open("inversions.in") fout = open("inversions.out", "w") n = int(fin.readline()) array = list(map(int, fin.readline().split())) mergesort(array) print(counter, file=fout) fin.close() fout.close()
counter = 0 def merge(array, left, right): i = j = k = 0 global counter while i < len(left) and j < len(right): if left[i] <= right[j]: array[k] = left[i] k += 1 i += 1 else: array[k] = right[j] counter += len(left) - i k += 1 j += 1 if len(left) > i: array[k:] = left[i:] elif len(right) > j: array[k:] = right[j:] def mergesort(array): if len(array) > 1: mid = len(array) // 2 left = array[:mid] right = array[mid:] mergesort(left) mergesort(right) merge(array, left, right) return array fin = open('inversions.in') fout = open('inversions.out', 'w') n = int(fin.readline()) array = list(map(int, fin.readline().split())) mergesort(array) print(counter, file=fout) fin.close() fout.close()
def fib(n: int) -> int: if n < 2: # base case return n return fib(n - 2) + fib(n - 1) if __name__ == "__main__": print(fib(2)) print(fib(10))
def fib(n: int) -> int: if n < 2: return n return fib(n - 2) + fib(n - 1) if __name__ == '__main__': print(fib(2)) print(fib(10))
#!/usr/bin/env python3 class ApiDefaults: url_verify = "/api/verify_api_key" url_refresh = "/api/import/refresh" url_add = "/api/import/add"
class Apidefaults: url_verify = '/api/verify_api_key' url_refresh = '/api/import/refresh' url_add = '/api/import/add'
words = "sort the inner content in descending order" result = [] for w in words.split(): if len(w)>3: result.append(w[0]+''.join(sorted(w[1:-1], reverse=True))+w[-1]) else: result.append(w)
words = 'sort the inner content in descending order' result = [] for w in words.split(): if len(w) > 3: result.append(w[0] + ''.join(sorted(w[1:-1], reverse=True)) + w[-1]) else: result.append(w)
# Definition for a binary tree node. class TreeNode: def __init__(self, x): self.val = x self.left = None self.right = None class Solution: def __init__(self): self.total = 0 def sumOfLeftLeaves(self, root: TreeNode) -> int: if not root: return 0 def dfs(node, type): if node is None: return if node.left is None and node.right is None and type == 1: self.total += node.val dfs(node.left, 1) dfs(node.right, 2) dfs(root.left, 1) dfs(root.right, 2) return self.total t1 = TreeNode(2) t1.left = TreeNode(3) slu = Solution() print(slu.sumOfLeftLeaves(t1))
class Treenode: def __init__(self, x): self.val = x self.left = None self.right = None class Solution: def __init__(self): self.total = 0 def sum_of_left_leaves(self, root: TreeNode) -> int: if not root: return 0 def dfs(node, type): if node is None: return if node.left is None and node.right is None and (type == 1): self.total += node.val dfs(node.left, 1) dfs(node.right, 2) dfs(root.left, 1) dfs(root.right, 2) return self.total t1 = tree_node(2) t1.left = tree_node(3) slu = solution() print(slu.sumOfLeftLeaves(t1))
language_map = { 'ko': 'ko_KR', 'ja': 'ja_JP', 'zh': 'zh_CN' }
language_map = {'ko': 'ko_KR', 'ja': 'ja_JP', 'zh': 'zh_CN'}
global numbering numbering = [0,1,2,3] num = 0 filterbegin = '''res(); for (i=0, o=0; i<115; i++){''' o = ['MSI', 'APPV', 'Citrix MSI', 'Normal','Express','Super Express (BOPO)', 'Simple', 'Medium', 'Complex', 'May', 'June', 'July', 'August'] filterending = '''if (val1 == eq1){ if (val2 == eq2){ if (val3 == eq3){ if (val4 == eq4){ if (val5 == eq5){ if (val6 == eq6){ if (val7 == eq7){ if (val8 == eq8){ op() }}}}}}}}}''' l = [0, 1, 2] m = [3, 4, 5] n = [6, 7, 8] p = [9, 10, 11, 12] filtnum = 0 filtername = f'''\nfunction quadfilter{filtnum}()''' with open("quadfilterfile.txt", 'a') as f: f.write(''' function op(){ z = o + 1.1 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = snum[i] z = o + 1.2 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = tnum[i] z = o + 1.3 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = pname[i] z = o + 1.4 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = bau[i] z = o + 1.5 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = ptype[i] z = o + 1.6 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = rtype[i] z = o + 1.7 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = bopo[i] z = o + 1.8 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = comp[i] z = o + 1.9 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = sdate[i] z = o + 1.16 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = edate[i] z = o + 1.17 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = month[i] z = o + 1.27 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = ssla[i] z = o + 1.26 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = slame[i] z = o + 1.21 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = slam[i] z = o + 1.15 document.getElementById(z).style.display = "" document.getElementById(z).innerHTML = remark[i] o++; document.getElementById("mainsum").innerHTML = "Found "+o+" Results For Your Search" } ''') for a1 in range(0, 3): a2 = o[a1] if a1 in l: a1a = "ptype[i]" elif a1 in m: a1a = "rtype[i]" elif a1 in n: a1a = "comp[i]" elif a1 in p: a1a = "month[i]" for b1 in range(0, 3): b2 = o[b1] if b1 != a1: if b1 in l: b1b = "ptype[i]" elif b1 in m: b1b = "rtype[i]" elif b1 in n: b1b = "comp[i]" elif b1 in p: b1b = "month[i]" for c1 in range(3, 6): c2 = o[c1] if c1 != a1: if c1 != b1: if c1 in l: c1c = "ptype[i]" elif c1 in m: c1c = "rtype[i]" elif c1 in n: c1c = "comp[i]" elif c1 in p: c1c = "month[i]" for d1 in range(3, 6): d2 = o[d1] if d1 != a1: if d1 != b1: if d1 != c1: if d1 in l: d1d = "ptype[i]" elif d1 in m: d1d = "rtype[i]" elif d1 in n: d1d = "comp[i]" elif d1 in p: d1d = "month[i]" for e1 in range(6, 9): e2 = o[e1] if e1 != a1: if e1 != b1: if e1 != c1: if e1 != d1: if e1 in l: e1e = "ptype[i]" elif e1 in m: e1e = "rtype[i]" elif e1 in n: e1e = "comp[i]" elif e1 in p: e1e = "month[i]" for f1 in range(6, 9): f2 = o[f1] if f1 != a1: if f1 != b1: if f1 != c1: if f1 != d1: if f1 != e1: if f1 in l: f1f = "ptype[i]" elif f1 in m: f1f = "rtype[i]" elif f1 in n: f1f = "comp[i]" elif f1 in p: f1f = "month[i]" for g1 in range(9, 13): g2 = o[g1] if g1 != a1: if g1 != b1: if g1 != c1: if g1 != d1: if g1 != e1: if g1 != f1: if g1 in l: g1g = "ptype[i]" elif g1 in m: g1g = "rtype[i]" elif g1 in n: g1g = "comp[i]" elif g1 in p: g1g = "month[i]" for x in range(9, 13): if x != a1: if x != b1: if x != c1: if x != d1: if x != e1: if x != f1: if x != g1: if x in l: x1 = "ptype[i]" elif x in m: x1 = "rtype[i]" elif x in n: x1 = "comp[i]" elif x in p: x1 = "month[i]" filtnum = filtnum + 1 with open("quadfilterfile.txt", 'a') as f: f.write(f'''function quadfilter{filtnum}()'''+"{"+f'''{filterbegin} val1 = "{a2}"; eq1 = "{a1a}"; val2 = "{b2}"; eq2 = "{b1b}"; val3 = "{c2}"; eq3 = "{c1c}"; val4 = "{d2}"; eq4 = "{d1d}"; val5 = "{e2}"; eq5 = "{e1e}"; val6 = "{f2}"; eq6 = "{f1f}"; val7 = "{g2}"; eq7 = "{g1g}"; val8 = "{o[x]}"; eq8 = "{x1}" {filterending}\n''') m1 = ['a1', 'a2', 'a3', 'a4','a5','a6', 'a7', 'a8', 'a9', 'a10', 'a11', 'a12', 'a13'] filtnum = 0 for z1 in range(0, 3): for z2 in range(0, 3): if z2 != z1: for z3 in range(3, 6): if z2 != z1: if z3 != z2: for z4 in range(3, 6): if z2 != z1: if z3 != z2: if z4 != z3: for z5 in range(6, 9): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: for z6 in range(6, 9): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: if z6 != z5: for z7 in range(9, 13): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: if z6 != z5: if z7 != z6: for z8 in range(9, 13): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: if z6 != z5: if z7 != z6: if z8 != z7: filtnum = filtnum + 1 with open("b13wala.txt", 'a') as f: f.write(f'''if (document.getElementById("{m1[z1]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z2]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z3]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z4]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z5]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z6]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z7]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z8]}").style.backgroundColor == "rgb(66, 153, 225)"'''+"{\n"+f'''triplefilter{filtnum}\n'''+"}")
global numbering numbering = [0, 1, 2, 3] num = 0 filterbegin = 'res(); for (i=0, o=0; i<115; i++){' o = ['MSI', 'APPV', 'Citrix MSI', 'Normal', 'Express', 'Super Express (BOPO)', 'Simple', 'Medium', 'Complex', 'May', 'June', 'July', 'August'] filterending = 'if (val1 == eq1){ if (val2 == eq2){ if (val3 == eq3){ if (val4 == eq4){ if (val5 == eq5){ if (val6 == eq6){ if (val7 == eq7){ if (val8 == eq8){ op() }}}}}}}}}' l = [0, 1, 2] m = [3, 4, 5] n = [6, 7, 8] p = [9, 10, 11, 12] filtnum = 0 filtername = f'\nfunction quadfilter{filtnum}()' with open('quadfilterfile.txt', 'a') as f: f.write(' \n function op(){\n \n z = o + 1.1\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = snum[i]\n \n z = o + 1.2\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = tnum[i]\n z = o + 1.3\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = pname[i]\n z = o + 1.4\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = bau[i]\n z = o + 1.5\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = ptype[i]\n z = o + 1.6\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = rtype[i]\n \n z = o + 1.7\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = bopo[i]\n z = o + 1.8\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = comp[i]\n z = o + 1.9\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = sdate[i]\n z = o + 1.16\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = edate[i]\n z = o + 1.17\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = month[i]\n \n z = o + 1.27\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = ssla[i]\n z = o + 1.26\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = slame[i]\n z = o + 1.21\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = slam[i]\n z = o + 1.15\n document.getElementById(z).style.display = ""\n document.getElementById(z).innerHTML = remark[i]\n o++; document.getElementById("mainsum").innerHTML = "Found "+o+" Results For Your Search"\n }\n ') for a1 in range(0, 3): a2 = o[a1] if a1 in l: a1a = 'ptype[i]' elif a1 in m: a1a = 'rtype[i]' elif a1 in n: a1a = 'comp[i]' elif a1 in p: a1a = 'month[i]' for b1 in range(0, 3): b2 = o[b1] if b1 != a1: if b1 in l: b1b = 'ptype[i]' elif b1 in m: b1b = 'rtype[i]' elif b1 in n: b1b = 'comp[i]' elif b1 in p: b1b = 'month[i]' for c1 in range(3, 6): c2 = o[c1] if c1 != a1: if c1 != b1: if c1 in l: c1c = 'ptype[i]' elif c1 in m: c1c = 'rtype[i]' elif c1 in n: c1c = 'comp[i]' elif c1 in p: c1c = 'month[i]' for d1 in range(3, 6): d2 = o[d1] if d1 != a1: if d1 != b1: if d1 != c1: if d1 in l: d1d = 'ptype[i]' elif d1 in m: d1d = 'rtype[i]' elif d1 in n: d1d = 'comp[i]' elif d1 in p: d1d = 'month[i]' for e1 in range(6, 9): e2 = o[e1] if e1 != a1: if e1 != b1: if e1 != c1: if e1 != d1: if e1 in l: e1e = 'ptype[i]' elif e1 in m: e1e = 'rtype[i]' elif e1 in n: e1e = 'comp[i]' elif e1 in p: e1e = 'month[i]' for f1 in range(6, 9): f2 = o[f1] if f1 != a1: if f1 != b1: if f1 != c1: if f1 != d1: if f1 != e1: if f1 in l: f1f = 'ptype[i]' elif f1 in m: f1f = 'rtype[i]' elif f1 in n: f1f = 'comp[i]' elif f1 in p: f1f = 'month[i]' for g1 in range(9, 13): g2 = o[g1] if g1 != a1: if g1 != b1: if g1 != c1: if g1 != d1: if g1 != e1: if g1 != f1: if g1 in l: g1g = 'ptype[i]' elif g1 in m: g1g = 'rtype[i]' elif g1 in n: g1g = 'comp[i]' elif g1 in p: g1g = 'month[i]' for x in range(9, 13): if x != a1: if x != b1: if x != c1: if x != d1: if x != e1: if x != f1: if x != g1: if x in l: x1 = 'ptype[i]' elif x in m: x1 = 'rtype[i]' elif x in n: x1 = 'comp[i]' elif x in p: x1 = 'month[i]' filtnum = filtnum + 1 with open('quadfilterfile.txt', 'a') as f: f.write(f'function quadfilter{filtnum}()' + '{' + f'{filterbegin}\nval1 = "{a2}"; eq1 = "{a1a}"; val2 = "{b2}"; eq2 = "{b1b}"; val3 = "{c2}"; eq3 = "{c1c}"; val4 = "{d2}"; eq4 = "{d1d}"; val5 = "{e2}"; eq5 = "{e1e}"; val6 = "{f2}"; eq6 = "{f1f}"; val7 = "{g2}"; eq7 = "{g1g}"; val8 = "{o[x]}"; eq8 = "{x1}"\n{filterending}\n') m1 = ['a1', 'a2', 'a3', 'a4', 'a5', 'a6', 'a7', 'a8', 'a9', 'a10', 'a11', 'a12', 'a13'] filtnum = 0 for z1 in range(0, 3): for z2 in range(0, 3): if z2 != z1: for z3 in range(3, 6): if z2 != z1: if z3 != z2: for z4 in range(3, 6): if z2 != z1: if z3 != z2: if z4 != z3: for z5 in range(6, 9): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: for z6 in range(6, 9): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: if z6 != z5: for z7 in range(9, 13): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: if z6 != z5: if z7 != z6: for z8 in range(9, 13): if z2 != z1: if z3 != z2: if z4 != z3: if z5 != z4: if z6 != z5: if z7 != z6: if z8 != z7: filtnum = filtnum + 1 with open('b13wala.txt', 'a') as f: f.write(f'if (document.getElementById("{m1[z1]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z2]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z3]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z4]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z5]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z6]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z7]}").style.backgroundColor == "rgb(66, 153, 225)" && if (document.getElementById("{m1[z8]}").style.backgroundColor == "rgb(66, 153, 225)"' + '{\n' + f'triplefilter{filtnum}\n' + '}')
# Definition for a binary tree node. # class TreeNode: # def __init__(self, val=0, left=None, right=None): # self.val = val # self.left = left # self.right = right class Solution: def countUnivalSubtrees(self, root: TreeNode) -> int: self.count = 0 self.is_uni(root) return self.count # Check whether subtree is uni-value def is_uni(self, node): if not node: return True # Node has no children if node.left is None and node.right is None: self.count += 1 return True # Check if all chidren are univalue subtrees is_uni = True if node.left: is_uni = self.is_uni(node.left) and is_uni and node.val == node.left.val if node.right: is_uni = self.is_uni(node.right) and is_uni and node.val == node.right.val # If all children are univalue subtrees, increment count if is_uni: self.count += 1 return is_uni
class Solution: def count_unival_subtrees(self, root: TreeNode) -> int: self.count = 0 self.is_uni(root) return self.count def is_uni(self, node): if not node: return True if node.left is None and node.right is None: self.count += 1 return True is_uni = True if node.left: is_uni = self.is_uni(node.left) and is_uni and (node.val == node.left.val) if node.right: is_uni = self.is_uni(node.right) and is_uni and (node.val == node.right.val) if is_uni: self.count += 1 return is_uni
#!/usr/bin/env python3 # Label key for repair state # (IN_SERVICE, OUT_OF_POOL, READY_FOR_REPAIR, IN_REPAIR, AFTER_REPAIR) REPAIR_STATE = "REPAIR_STATE" # Annotation key for the last update time of the repair state REPAIR_STATE_LAST_UPDATE_TIME = "REPAIR_STATE_LAST_UPDATE_TIME" # Annotation key for the last email time for jobs on node in repair REPAIR_STATE_LAST_EMAIL_TIME = "REPAIR_STATE_LAST_EMAIL_TIME" # Annotation key for unhealthy rules REPAIR_UNHEALTHY_RULES = "REPAIR_UNHEALTHY_RULES" # Annotation key for whether the node is in repair cycle. # An unschedulable node that is not in repair cycle can be manually repaired # by administrator without repair cycle interruption. REPAIR_CYCLE = "REPAIR_CYCLE" # Annotation key for repair message - what phase the node is undergoing REPAIR_MESSAGE = "REPAIR_MESSAGE"
repair_state = 'REPAIR_STATE' repair_state_last_update_time = 'REPAIR_STATE_LAST_UPDATE_TIME' repair_state_last_email_time = 'REPAIR_STATE_LAST_EMAIL_TIME' repair_unhealthy_rules = 'REPAIR_UNHEALTHY_RULES' repair_cycle = 'REPAIR_CYCLE' repair_message = 'REPAIR_MESSAGE'
###################################################################################################################### # Copyright 2016 Amazon.com, Inc. or its affiliates. All Rights Reserved. # # # # Licensed under the Amazon Software License (the "License"). You may not use this file except in compliance # # with the License. A copy of the License is located at # # # # http://aws.amazon.com/asl/ # # # # or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES # # OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions # # and limitations under the License. # ###################################################################################################################### BOOLEAN_FALSE_VALUES = [ "false", "no", "disabled", "off", "0" ] BOOLEAN_TRUE_VALUES = [ "true", "yes", "enabled", "on", "1" ] # name of environment variable that holds the name of the configuration table ENV_CONFIG_TABLE = "CONFIG_TABLE" ENV_CONFIG_BUCKET = "CONFIG_BUCKET" TASKS_OBJECTS = "TaskConfigurationObjects" # names of attributes in configuration # name of the action CONFIG_ACTION_NAME = "Action" # debug parameter CONFIG_DEBUG = "Debug" # notifications for started/ended tasks CONFIG_TASK_NOTIFICATIONS = "TaskNotifications" # list of cross account roles CONFIG_ACCOUNTS = "Accounts" # name of alternative cross account role CONFIG_TASK_CROSS_ACCOUNT_ROLE_NAME = "CrossAccountRole" # description CONFIG_DESCRIPTION = "Description" # Switch to enable/disable task CONFIG_ENABLED = "Enabled" # tag filter for tags of source resource of an event CONFIG_EVENT_SOURCE_TAG_FILTER = "SourceEventTagFilter" # cron expression interval for time/date based tasks CONFIG_INTERVAL = "Interval" # internal task CONFIG_INTERNAL = "Internal" # name of the task CONFIG_TASK_NAME = "Name" # parameters of a task CONFIG_PARAMETERS = "Parameters" # switch to indicate if resource in the account of the scheduler should be processed CONFIG_THIS_ACCOUNT = "ThisAccount" # timezone for time/date scheduled task CONFIG_TIMEZONE = "Timezone" # tag filter to select resources processed by the task CONFIG_TAG_FILTER = "TagFilter" # regions where to select/process resources CONFIG_REGIONS = "Regions" # dryrun switch, passed to the tasks action CONFIG_DRYRUN = "Dryrun" # events that trigger the task CONFIG_EVENTS = "Events" # event scopes CONFIG_EVENT_SCOPES = "EventScopes" # stack id if created from cloudformation stack CONFIG_STACK_ID = "StackId" # action timeout CONFIG_TASK_TIMEOUT = "TaskTimeout" # action select memory CONFIG_TASK_SELECT_SIZE = "SelectSize" # action select memory CONFIG_TASK_EXECUTE_SIZE = "ExecuteSize" # action completion memory CONFIG_TASK_COMPLETION_SIZE = "CompletionSize" # action completion memory when running in ECS CONFIG_ECS_COMPLETION_MEMORY = "CompletionEcsMemoryValue" # action select memory when running in ECS CONFIG_ECS_SELECT_MEMORY = "SelectEcsMemoryValueValue" # action select memory when running in ECS CONFIG_ECS_EXECUTE_MEMORY = "ExecuteEcsMemoryValue" # Task metrics CONFIG_TASK_METRICS = "TaskMetrics"
boolean_false_values = ['false', 'no', 'disabled', 'off', '0'] boolean_true_values = ['true', 'yes', 'enabled', 'on', '1'] env_config_table = 'CONFIG_TABLE' env_config_bucket = 'CONFIG_BUCKET' tasks_objects = 'TaskConfigurationObjects' config_action_name = 'Action' config_debug = 'Debug' config_task_notifications = 'TaskNotifications' config_accounts = 'Accounts' config_task_cross_account_role_name = 'CrossAccountRole' config_description = 'Description' config_enabled = 'Enabled' config_event_source_tag_filter = 'SourceEventTagFilter' config_interval = 'Interval' config_internal = 'Internal' config_task_name = 'Name' config_parameters = 'Parameters' config_this_account = 'ThisAccount' config_timezone = 'Timezone' config_tag_filter = 'TagFilter' config_regions = 'Regions' config_dryrun = 'Dryrun' config_events = 'Events' config_event_scopes = 'EventScopes' config_stack_id = 'StackId' config_task_timeout = 'TaskTimeout' config_task_select_size = 'SelectSize' config_task_execute_size = 'ExecuteSize' config_task_completion_size = 'CompletionSize' config_ecs_completion_memory = 'CompletionEcsMemoryValue' config_ecs_select_memory = 'SelectEcsMemoryValueValue' config_ecs_execute_memory = 'ExecuteEcsMemoryValue' config_task_metrics = 'TaskMetrics'
{ "targets": [ { "target_name": "ecdh", "include_dirs": ["<!(node -e \"require('nan')\")"], "cflags": ["-Wall", "-O2"], "sources": ["ecdh.cc"], "conditions": [ ["OS=='win'", { "conditions": [ [ "target_arch=='x64'", { "variables": { "openssl_root%": "C:/OpenSSL-Win64" }, }, { "variables": { "openssl_root%": "C:/OpenSSL-Win32" } } ] ], "libraries": [ "-l<(openssl_root)/lib/libeay32.lib", ], "include_dirs": [ "<(openssl_root)/include", ], }, { "conditions": [ [ "target_arch=='ia32'", { "variables": { "openssl_config_path": "<(nodedir)/deps/openssl/config/piii" } } ], [ "target_arch=='x64'", { "variables": { "openssl_config_path": "<(nodedir)/deps/openssl/config/k8" }, } ], [ "target_arch=='arm'", { "variables": { "openssl_config_path": "<(nodedir)/deps/openssl/config/arm" } } ], [ "target_arch=='arm64'", { "variables": { "openssl_config_path": "<(nodedir)/deps/openssl/config/aarch64" } } ], ], "include_dirs": [ "<(nodedir)/deps/openssl/openssl/include", "<(openssl_config_path)" ] } ]] } ] }
{'targets': [{'target_name': 'ecdh', 'include_dirs': ['<!(node -e "require(\'nan\')")'], 'cflags': ['-Wall', '-O2'], 'sources': ['ecdh.cc'], 'conditions': [["OS=='win'", {'conditions': [["target_arch=='x64'", {'variables': {'openssl_root%': 'C:/OpenSSL-Win64'}}, {'variables': {'openssl_root%': 'C:/OpenSSL-Win32'}}]], 'libraries': ['-l<(openssl_root)/lib/libeay32.lib'], 'include_dirs': ['<(openssl_root)/include']}, {'conditions': [["target_arch=='ia32'", {'variables': {'openssl_config_path': '<(nodedir)/deps/openssl/config/piii'}}], ["target_arch=='x64'", {'variables': {'openssl_config_path': '<(nodedir)/deps/openssl/config/k8'}}], ["target_arch=='arm'", {'variables': {'openssl_config_path': '<(nodedir)/deps/openssl/config/arm'}}], ["target_arch=='arm64'", {'variables': {'openssl_config_path': '<(nodedir)/deps/openssl/config/aarch64'}}]], 'include_dirs': ['<(nodedir)/deps/openssl/openssl/include', '<(openssl_config_path)']}]]}]}
class Contact: def __init__(self, name, phone, email): self.name = name self.phone = phone self.email = email
class Contact: def __init__(self, name, phone, email): self.name = name self.phone = phone self.email = email
''' This module contains some exception classes ''' class SecondryStructureError(Exception): ''' Raised when the Secondry structure is not correct ''' def __init__(self, residue, value): messgae = ''' ERROR: Secondary Structure Input is not parsed correctly. Please make sure the value after the C alpha shift is one of the following - alpha : a, alpha, h, helix - beta : b, beta, sheet, strand - coil : c, coil, r, (assumed to be 50%% alpha and 50%% beta) - A number between 0 and 1. 1 = 100%% alpha helix, 0. = 100%% beta sheet The Value given for residue %s is %s ''' % (residue, value) Exception.__init__(self, messgae) class ShiftMatrixStatesOrder(Exception): ''' Raised when the order of the states in the chemical shift file is incorrect ''' def __init__(self, file_): messgae = ''' ERROR: The order of the states in the file containing the chemical shifts is different. Please correct this. This is File: %s''' % (file_) Exception.__init__(self, messgae)
""" This module contains some exception classes """ class Secondrystructureerror(Exception): """ Raised when the Secondry structure is not correct """ def __init__(self, residue, value): messgae = '\n ERROR: Secondary Structure Input is not parsed correctly.\n Please make sure the value after the C alpha shift is\n one of the following\n\n - alpha : a, alpha, h, helix\n - beta : b, beta, sheet, strand\n - coil : c, coil, r, (assumed to be 50%% alpha and 50%% beta)\n - A number between 0 and 1. 1 = 100%% alpha helix, 0. = 100%% beta sheet\n\n The Value given for residue %s is %s ' % (residue, value) Exception.__init__(self, messgae) class Shiftmatrixstatesorder(Exception): """ Raised when the order of the states in the chemical shift file is incorrect """ def __init__(self, file_): messgae = '\n ERROR: The order of the states in the file containing the\n chemical shifts is different. Please correct this.\n This is File: %s' % file_ Exception.__init__(self, messgae)
class get_method_name_decorator: def __init__(self, fn): self.fn = fn def __set_name__(self, owner, name): owner.method_names.add(self.fn) setattr(owner, name, self.fn)
class Get_Method_Name_Decorator: def __init__(self, fn): self.fn = fn def __set_name__(self, owner, name): owner.method_names.add(self.fn) setattr(owner, name, self.fn)
# https://www.devdungeon.com/content/colorize-terminal-output-python # https://www.geeksforgeeks.org/print-colors-python-terminal/ class CONST: class print_color: class control: ''' Full name: Perfect_color_text ''' reset='\033[0m' bold='\033[01m' disable='\033[02m' underline='\033[04m' reverse='\033[07m' strikethrough='\033[09m' invisible='\033[08m' class fore: ''' Full name: Perfect_fore_color ''' black='\033[30m' red='\033[31m' green='\033[32m' orange='\033[33m' blue='\033[34m' purple='\033[35m' cyan='\033[36m' lightgrey='\033[37m' darkgrey='\033[90m' lightred='\033[91m' lightgreen='\033[92m' yellow='\033[93m' lightblue='\033[94m' pink='\033[95m' lightcyan='\033[96m' class background: ''' Full name: Perfect_background_color ''' black='\033[40m' red='\033[41m' green='\033[42m' orange='\033[43m' blue='\033[44m' purple='\033[45m' cyan='\033[46m' lightgrey='\033[47m' class cv_color: line = (0,255,0) circle = (255,255,0) if __name__ == "__main__": print (CONST.print_color.fore.yellow + 'Hello world. ' + CONST.print_color.fore.red + 'Hey!')
class Const: class Print_Color: class Control: """ Full name: Perfect_color_text """ reset = '\x1b[0m' bold = '\x1b[01m' disable = '\x1b[02m' underline = '\x1b[04m' reverse = '\x1b[07m' strikethrough = '\x1b[09m' invisible = '\x1b[08m' class Fore: """ Full name: Perfect_fore_color """ black = '\x1b[30m' red = '\x1b[31m' green = '\x1b[32m' orange = '\x1b[33m' blue = '\x1b[34m' purple = '\x1b[35m' cyan = '\x1b[36m' lightgrey = '\x1b[37m' darkgrey = '\x1b[90m' lightred = '\x1b[91m' lightgreen = '\x1b[92m' yellow = '\x1b[93m' lightblue = '\x1b[94m' pink = '\x1b[95m' lightcyan = '\x1b[96m' class Background: """ Full name: Perfect_background_color """ black = '\x1b[40m' red = '\x1b[41m' green = '\x1b[42m' orange = '\x1b[43m' blue = '\x1b[44m' purple = '\x1b[45m' cyan = '\x1b[46m' lightgrey = '\x1b[47m' class Cv_Color: line = (0, 255, 0) circle = (255, 255, 0) if __name__ == '__main__': print(CONST.print_color.fore.yellow + 'Hello world. ' + CONST.print_color.fore.red + 'Hey!')
found = False while not found: num = float(input()) if 1 <= num <= 100: print(f"The number {num} is between 1 and 100") found = True
found = False while not found: num = float(input()) if 1 <= num <= 100: print(f'The number {num} is between 1 and 100') found = True