text
stringlengths
25
2.19k
embedding
listlengths
768
768
def count _ pol _ coverage ( pol _ name _ str ) : article _ search = nytapi. article _ search _ api ( ) ; # always first set api key article _ search. set _ api _ key ('6d35e713a27934716115205ee8ae733b : 6 : 69503175') ; # set other parameters article _ search. set _ search _ term ( pol _ name _ str ) ; # article _ sea...
[ -0.003588220803067088, -0.22758157551288605, 0.9096393585205078, -0.6124196648597717, 0.12594404816627502, 0.3476106524467468, 0.35060879588127136, 0.08070521801710129, -0.1929537057876587, 0.24272072315216064, -0.470111221075058, -0.15088053047657013, -0.32040902972221375, -0.358273893594...
def bounding _ box ( point _ list ) : xmin = xmax = point _ list [ 0 ]. x ymin = ymax = point _ list [ 0 ]. y for point in point _ list : # single loop over points xmin = min ( point. x, xmin ) xmax = max ( point. x, xmax ) ymin = min ( point. y, ymin ) ymax = max ( point. y, ymax ) # one can use a divide - and - conqu...
[ -0.339991956949234, -0.004288428463041782, 0.7459268569946289, 1.249280333518982, 0.12735097110271454, -0.37939009070396423, -0.24310298264026642, 0.1402045637369156, 0.8355519771575928, -0.14872564375400543, -0.6742051243782043, -0.29603078961372375, -0.05087318271398544, 0.55250316858291...
def verts _ to _ mids ( self, sv, gtype ='tri') : if gtype = ='tri': assert ( len ( sv ) = = self. n _ tverts ), " length of array passed to grad is not tri _ verts length " mm = np. abs ( self. delta _ tri _ 0 ) * ( 1 / 2 ) sm = np. dot ( mm, sv ) elif gtype = ='vor': assert ( self. make _ all _ operators ), " this me...
[ -0.16874617338180542, -0.31383994221687317, 0.6446555852890015, -0.018059998750686646, -0.7655187249183655, 0.24340085685253143, 0.10677046328783035, -0.9263488054275513, 1.0276875495910645, 0.8236368894577026, -0.048941221088171005, 0.5427327156066895, -0.917752742767334, 0.71981590986251...
def rollback ( self ) - > none : self. _ _ conn. rollback ( )
[ 0.6990826725959778, 0.17879155278205872, 0.5413986444473267, -0.23620258271694183, 1.346954584121704, 0.35198941826820374, 0.5611664652824402, 1.4013090133666992, -1.0956913232803345, -0.13156816363334656, 0.5308165550231934, 0.8744243383407593, -0.9629242420196533, -0.8769035339355469, ...
def test _ replace _ agent _ requirements ( self ) : pass
[ -0.18538342416286469, -0.7138770222663879, 0.3272096812725067, 0.29659220576286316, -0.14848731458187103, 0.04391497001051903, 0.6623960733413696, 0.8692403435707092, 1.0578449964523315, -0.512843906879425, -0.9717952013015747, 0.07675550878047943, -0.4658535420894623, 0.4918355345726013, ...
def highpassfilter ( stack, size = 11 ) : from scipy import ndimage # copy image stack : imfilt = stack. copy ( ) # for each image : for i in range ( imfilt. shape [ 0 ] ) : # make hpf filter : imhpf = ndimage. median _ filter ( stack [ i, :, : ], size ) # subtract hpf from image : im = stack [ i ] - imhpf # place filt...
[ -0.20414018630981445, 0.4423416256904602, 0.7606849670410156, 0.573837399482727, 0.14125853776931763, -0.5204408168792725, 0.4522134065628052, -0.26627060770988464, -0.29231420159339905, 0.23837706446647644, 0.22482822835445404, -0.3103247582912445, -0.21583029627799988, -0.278296142816543...
def fruit _ directory ( ) : fruits = produce. query. filter _ by ( prod _ type = 2 ). all ( ) return render _ template ('/ fruits. html ', fruits = fruits )
[ -0.5161237120628357, 0.7014520168304443, 0.40387657284736633, 0.8581689596176147, -0.19041910767555237, -0.036284103989601135, 0.6911869645118713, 0.3925713300704956, 0.01208871603012085, -0.547404408454895, 0.3311251103878021, 0.6236956119537354, 1.1552029848098755, 0.09930747002363205, ...
def test _ start _ stop _ resume ( self ) : log. info ( " = = = = = start integ test stop start resume = = = = = " ) self. clear _ async _ data ( ) self. create _ sample _ data _ set _ dir ('tel _ vel3d _ l _ 1. dat ', dir _ tel, file _ tel ) self. create _ sample _ data _ set _ dir ('rec _ vel3d _ l _ 1. dat ', dir _ ...
[ 1.034551739692688, -0.5179731845855713, 0.8212586641311646, -0.627852737903595, 0.3985596299171448, 0.10333938896656036, 0.19893689453601837, 0.17995238304138184, -0.5710179805755615, 0.017672160640358925, -0.2594905197620392, 0.15546812117099762, -0.46302059292793274, -0.8024595379829407,...
def find _ vm _ names ( pids ) : result = { } for pid in pids : name = none name _ arg _ values = _ get _ kvm _ process _ arguments ( pid, " name " ) if name _ arg _ values : name _ arg _ value = name _ arg _ values [ 0 ] if ", " in name _ arg _ value : # the modern parameter format may look like this : # guest = foo, ...
[ -0.7573401927947998, -0.695516049861908, 0.8110397458076477, -0.5803090929985046, -0.5624959468841553, -0.5731433629989624, -0.9498336911201477, -0.6866536140441895, -0.7179796099662781, 1.2702256441116333, -0.3815546929836273, -0.33285006880760193, 0.22600382566452026, 0.6817248463630676,...
def gethandle ( self ) : return _ topods. topods _ tcompsolid _ gethandle ( self )
[ 0.3899085521697998, 0.14688174426555634, 0.2271878570318222, -0.09810864180326462, 1.3095934391021729, 1.8560110330581665, 1.4483418464660645, -0.3707413971424103, -0.06426554173231125, -1.5818099975585938, -0.010967709124088287, -1.5065832138061523, -1.0056806802749634, -0.534026384353637...
def get _ matchups ( self, team _ id ) : return self. get _ team _ with _ matchups ( team _ id ) \. find ('yahoo : matchups ', self. _ ns )
[ 0.24281181395053864, 0.1871245950460434, 0.7078620195388794, 0.47194361686706543, 0.7384158372879028, -1.207301139831543, -0.24888519942760468, 0.022687671706080437, 0.7650991678237915, 0.24852119386196136, -0.6443281173706055, -0.5618244409561157, 0.28675979375839233, 0.1562768518924713, ...
def add _ faiss _ index ( self, column : str, index _ name : optional [ str ] = none, device : optional [ int ] = none, string _ factory : optional [ str ] = none, metric _ type : optional [ int ] = none, custom _ index : optional [ " faiss. index " ] = none, # noqa : f821 train _ size : optional [ int ] = none, faiss ...
[ -0.17768771946430206, 0.682273805141449, 0.5806447267532349, -0.006636134814471006, 0.2986089885234833, -0.6457581520080566, 0.20423196256160736, -0.4347755014896393, 0.24795232713222504, -0.48979413509368896, -0.28516077995300293, 0.8090965151786804, 1.137961745262146, -0.3090470731258392...
def frequency _ of _ band ( n, order = 1, ref = reference ) : return ref * 10. 0 * * ( 3. 0 / order / 10. 0 ) * 2. 0 * * ( n / order )
[ 0.3009202182292938, 0.8923792243003845, 0.19569861888885498, 0.39847955107688904, 0.34196963906288147, -0.3768085539340973, 0.17451125383377075, -1.1533091068267822, 0.3486423194408417, -0.20280487835407257, 0.1799195408821106, 0.35628512501716614, -0.0822642520070076, 0.6537992358207703, ...
def bump _ delta _ central ( x, function, epsilon = 1e - 5 ) : return ( function ( x + epsilon ) - function ( x - epsilon ) ) / ( 2. * epsilon )
[ 0.8443213105201721, 0.015440182760357857, 0.6210492253303528, 0.3781650960445404, -0.6168496012687683, 1.4024884700775146, -0.529523491859436, 0.2424989491701126, -0.2974948287010193, 0.3257593512535095, 0.28226616978645325, 0.4305363595485687, 0.17617473006248474, -1.0076181888580322, 0...
def verts _ in ( f, voxel, surf, g ) : verts = get _ verts ( voxel, g ) ins = 0 distlist = [ ] for ( x, y, z ) in verts : if ( g [ " xlo " ] < = x < = g [ " xhi " ] and g [ " ylo " ] < = y < = g [ " yhi " ] and g [ " zlo " ] < = z < = g [ " zhi " ] ) : dist = f. distance ( x, y, z ) else : dist = float ( " inf " ) dist...
[ 0.5954938530921936, 0.3767966330051422, 0.8678309917449951, 0.2591598331928253, -0.5603495836257935, 0.0799822136759758, 0.8391135334968567, -0.1611037403345108, -0.3502449095249176, 0.38765203952789307, -0.7961491942405701, -0.4583663046360016, -0.6667300462722778, 0.03166281804442406, ...
def printd ( info, highlight = false ) : if _ _ debug _ _ : if support _ color : prefix ='\ 033 [ 1m'if highlight else'\ 033 [ 2m'info = prefix + str ( info ) +'\ 033 [ 0m'sys. stdout. write ( info )
[ 0.5356320142745972, 0.0037130832206457853, 0.774679958820343, 0.30292466282844543, 0.2409142553806305, 0.6361249685287476, -0.7921131253242493, 0.12894652783870697, 0.09615868330001831, -1.1470835208892822, 0.3011225759983063, 0.17642708122730255, 0.10612718015909195, 0.3831798732280731, ...
def setuptestdata ( cls ) : cls. client = apiclient ( ) cls. group _ admin = group. objects. create ( name = " admin " ) cls. group _ admin. permissions. add ( permission. objects. get ( name = " can add alumno " ) ) cls. group _ admin. permissions. add ( permission. objects. get ( name = " can change alumno " ) ) cls....
[ -0.4974837899208069, 0.5671535134315491, 0.8374885320663452, 0.5243249535560608, 0.5036929249763489, 0.658621072769165, 0.3889770209789276, -0.3333961069583893, -0.5058417916297913, 0.023975830525159836, -0.25903961062431335, 0.31931498646736145, 0.21907109022140503, -0.3819020092487335, ...
def increment _ support _ skillbook _ used ( self ) : self. support _ skillbook + = 1
[ -0.8573880195617676, -0.3189806044101715, 0.3707543909549713, 0.8965551257133484, -0.04988819360733032, 0.6369240880012512, 0.49139347672462463, 0.42921146750450134, 0.08766482025384903, -0.46589335799217224, -1.1721709966659546, -0.17979443073272705, -0.3327024281024933, 0.252839833498001...
def from _ json ( path _ or _ paths : union [ pathlike, list [ pathlike ] ], split : optional [ namedsplit ] = none, features : optional [ features ] = none, cache _ dir : str = none, keep _ in _ memory : bool = false, field : optional [ str ] = none, * * kwargs, ) : # dynamic import to avoid circular dependency from. ...
[ -0.8628416657447815, -0.05346554517745972, 0.5928856730461121, -0.2805369794368744, -1.0577622652053833, -0.48025113344192505, -0.3858729600906372, 0.25922104716300964, 0.2580627501010895, -0.3825188875198364, -0.0800199806690216, -0.04762066528201103, 0.6499261856079102, -0.43834942579269...
def copy _ poly _ minimal ( poly _ in, scale = 1 ) : wdo _ in = dsa. wrapdataobject ( poly _ in ) wdo _ out = dsa. wrapdataobject ( vtk. vtkpolydata ( ) ) # we need a new poly, because updating values through dsa api not possible wdo _ out. points = wdo _ in. points * scale wdo _ out. getattributes ( vtk. vtkdataobject...
[ 0.28701913356781006, -1.274713397026062, 0.8910700082778931, -0.5827116370201111, -1.8187201023101807, 0.5460171699523926, -0.10408160835504532, -0.5418088436126709, 0.5102065205574036, 0.6215202808380127, -0.3429170548915863, 0.24028652906417847, 1.2029024362564087, -0.19776825606822968, ...
def get _ window _ stats ( self, item, * identifiers ) : window _ start, window _ items = self. storage ( ). get _ moving _ window ( item. key _ for ( * identifiers ), item. amount, item. get _ expiry ( ) ) reset = window _ start + item. get _ expiry ( ) return ( reset, item. amount - window _ items )
[ -0.3453841209411621, -0.4725625216960907, 0.4721581041812897, 0.5499765276908875, -0.34448787569999695, 0.04462067410349846, 0.10229480266571045, -0.5270611047744751, 0.015504169277846813, 1.0212610960006714, -0.7597420811653137, 0.7849885821342468, -0.42318785190582275, -0.244680970907211...
def get _ uid ( current _ dirs ) : # current _ uid = 1 if len ( current _ dirs )! = 0 : max _ dir _ num = max ( [ int ( d ) for d in current _ dirs ] ) empty _ dirs _ idx = 0 used _ dirs _ idx = 0 for d in current _ dirs : if len ( os. listdir ( path. join ( photo _ dir, d ) ) ) = = 0 : empty _ dir _ idx = int ( d ) el...
[ -1.7903109788894653, -0.5795395970344543, 0.7481213212013245, 0.16512051224708557, -0.031285449862480164, -0.21324893832206726, 2.0555362701416016, 0.7658742070198059, 1.1002235412597656, -0.9573906064033508, 0.4572235941886902, 0.7508232593536377, -0.6736778020858765, 0.6369659304618835, ...
def predict _ proba ( self, x : np. ndarray ) - > np. ndarray : if self. order = = 0 : x = np. zeros ( ( x. shape [ 0 ], 1 ), dtype = int ) idx = [ self. _ n _ dimensions * * i for i in range ( x. shape [ 1 ] ) ] idx = np. array ( idx [ : : - 1 ] ) indexes = np. dot ( x, idx ) return self. transition _ matrix [ indexes...
[ -0.8273435235023499, 0.19971086084842682, 0.9630954265594482, 0.7567342519760132, -0.49376508593559265, -0.08558046072721481, -0.08657437562942505, -0.19250541925430298, 0.16142797470092773, 0.8591820597648621, 0.10963339358568192, 0.46136924624443054, 0.004204003140330315, 0.0397886298596...
def testupdatevaluesforquerieswithfloatvalue ( self ) : securetagapi ( self. user ). create ( [ ( u'username / bar ', u'description') ] ) objectid = uuid4 ( ) # fixme replace this with securetagvalueapi once the index is # integrated values = { objectid : { u'username / bar': 42 } } valuesapi = securetagvalueapi ( self...
[ 0.07189975678920746, 0.46809571981430054, 0.38916754722595215, 0.04812914878129959, 0.3407823443412781, 0.7190046310424805, 0.18013280630111694, -0.4584999680519104, -0.5760913491249084, -0.733011782169342, -0.31154975295066833, -0.5017432570457458, -0.16799986362457275, 0.2793704569339752...
def integrate ( self, f, measure ) : raise exception ( " this is the base region class! use a subclass " )
[ 0.4067438244819641, 0.48072198033332825, 0.40212884545326233, 0.6666210293769836, -0.216605544090271, 0.5449590086936951, -0.023266412317752838, -0.16063374280929565, -0.7854611873626709, -1.1272944211959839, -0.34093374013900757, -0.4322988986968994, -0.6115403175354004, 1.078774452209472...
def _ assign _ to _ class ( fields _ dict, mass _ centers, var _ names = ('dbz ','zdr ','kdp ','rhohv ','h _ iso0'), weights = np. array ( [ 1., 1., 1., 0. 75, 0. 5 ] ), t _ vals = none ) : # prepare data nrays = fields _ dict [ var _ names [ 0 ] ]. shape [ 0 ] nbins = fields _ dict [ var _ names [ 0 ] ]. shape [ 1 ] n...
[ -0.6092403531074524, -0.6237636208534241, 0.7863428592681885, -0.5857877135276794, 0.2416635900735855, 0.4173472821712494, 0.20474889874458313, 0.25676828622817993, -0.6267039775848389, 0.9203377366065979, -0.018894392997026443, 0.15540005266666412, 0.5488206148147583, 1.0968706607818604, ...
def _ _ init _ _ ( self, noofedges, noselfloops, startvertx, endvertx, startverty, endverty, proba, probb, probc, probd ) : threading. thread. _ _ init _ _ ( self ) # # @ see randomgraphs : : directedpowerlawrandomgraph self. startvertx = startvertx # # @ see randomgraphs : : directedpowerlawrandomgraph self. endvertx ...
[ 0.694217324256897, 0.061494700610637665, 0.8151317834854126, 0.7832498550415039, 0.2359156310558319, 0.7066314220428467, 0.3515530228614807, -0.5614641904830933, 0.41730278730392456, -0.35968053340911865, -0.3440804183483124, 0.34068843722343445, -0.8477240800857544, 0.15227246284484863, ...
def synchronize ( ) - > none : return torch. _ c. _ mps _ devicesynchronize ( )
[ 0.002526378259062767, 0.7983719110488892, 0.32602837681770325, 1.0703086853027344, 0.08157478272914886, -0.7205204367637634, 0.6906428933143616, -0.5897806882858276, -0.06165030598640442, -0.5431880354881287, -0.2828463912010193, -0.1778745949268341, -0.2785697877407074, -1.092631459236145...
def _ recursive _ folderstats ( root _ entry, items = none, hash _ name = none, ignore _ hidden = false, exclude = none, filter _ extension = none, follow _ links = false, depth = 0, idx = 1, parent _ idx = 0 ) : items = items if items is not none else [ ] foldersize, num _ files = 0, 0 current _ idx = idx if isinstanc...
[ 0.2759075164794922, 0.3774658739566803, 0.8002578020095825, 0.0730544775724411, -0.41803276538848877, -0.6105260252952576, 0.747775137424469, -0.2968716323375702, 0.5587638020515442, -0.7147563695907593, 0.3219626545906067, 0.30748221278190613, 0.2042158544063568, 0.5436500906944275, 0.2...
def generate _ transaction _ id ( self ) : transaction _ id = random. randint ( 0, 100000 ) while transaction _ id in self. delegations : transaction _ id = random. randint ( 0, 100000 ) return transaction _ id
[ 0.6651545166969299, 0.460342139005661, 0.6133010387420654, -1.2330371141433716, 0.4972856938838959, 0.06522203981876373, -0.4462701380252838, 0.7298873662948608, 1.143962025642395, 0.3099602460861206, -0.07596784085035324, 0.09739106148481369, -0.6046939492225647, 0.482444167137146, -0.3...
def execute ( self ) - > none : print ( " complexcommand : complex stuff should be done by a receiver object ", end = " " ) self. _ receiver. do _ something ( self. _ a ) self. _ receiver. do _ something _ else ( self. _ b )
[ -1.0422413349151611, -1.0112450122833252, 0.6287731528282166, 0.28911086916923523, 1.3474684953689575, 0.05135561525821686, 0.49249809980392456, 0.6760144829750061, 0.26369771361351013, -0.9993129968643188, -0.4502467215061188, 0.06158096715807915, -0.05893296003341675, -0.1225796192884445...
def build _ nn _ model ( height, width, num _ channels, num _ res _ blocks ) : input _ tensor = input ( shape = ( height, width, 1 ) ) output _ block = conv2d ( num _ channels, ( 3, 3 ), padding = " same " ) ( input _ tensor ) output _ block = activation ('relu') ( output _ block ) for i in range ( num _ res _ blocks )...
[ 0.039025820791721344, -0.5737423896789551, 0.5756860375404358, 0.03325369209051132, -0.1294817179441452, -0.49184948205947876, -0.15012091398239136, -0.445324182510376, -0.008326681330800056, -0.15919780731201172, -0.8313983082771301, -0.7757606506347656, 0.18331961333751678, -1.3666554689...
def pop ( self, key, default = none ) : raise typeerror ( self. _ _ msg )
[ -0.2881114184856415, 0.8380434513092041, 0.2582848072052002, 0.202012300491333, 0.6289138197898865, 0.08809874206781387, -0.14183735847473145, -0.20452404022216797, -0.7011563181877136, 1.3332343101501465, 0.2772798240184784, 0.1264905482530594, -1.6705613136291504, 0.15079449117183685, ...
def welcome ( ) : # print ( " enter your name " ) fn = input ( " enter your name : " ) # print ( " \ nwelcome { } ". format ( fn ) ) return fn
[ 0.6455851197242737, -0.7061907649040222, 0.5429348349571228, 0.37197768688201904, -1.1220427751541138, 0.2757929861545563, 0.08765973895788193, -0.1270245909690857, 0.2844650149345398, -0.8809731602668762, -0.7035784125328064, 0.675229012966156, -0.14228107035160065, -0.2489776611328125, ...
def login _ user ( self, user ) : self. user = user message _ hub. send _ message ( " identity : loginsuccessful : { } ". format ( user [ " _ id " ] ), { " user _ id " : str ( user [ " _ id " ] ), " username " : user [ " username " ], } ) self. emit ( " loginsuccessful ", { " token " : user _ manager. create _ identity...
[ -0.8330651521682739, 0.6268872618675232, 0.30095699429512024, 0.7755597829818726, -0.036501653492450714, 0.10485529899597168, -0.3790285885334015, 0.25011393427848816, 0.1649056375026703, -0.22783862054347992, -1.8986351490020752, 0.594880223274231, 0.07060392200946808, 0.12285169214010239...
def show _ card ( ) : get _ id = request. args. get ('id') conn = get _ db ( ) conn. row _ factory = sqlite3. row cursor = conn. execute ('select * from foundations where id =? ', ( get _ id, ) ) item = cursor. fetchone ( ) display = make _ nice _ display ( [ item ] ) return render _ template ('single _ result. html ',...
[ -0.32434070110321045, 0.9170919060707092, 0.4571928083896637, -0.47465649247169495, 0.015783589333295822, -0.5564641356468201, -0.0878562331199646, 0.824430525302887, -0.1143917366862297, 0.3611030876636505, 0.6499462723731995, -0.6204206347465515, 0.36333975195884705, 0.5134329199790955, ...
def click _ close _ warning ( self ) : self. click ( self. pop _ public _ waring _ close )
[ 0.03363708034157753, 0.6532720923423767, 0.33863335847854614, 0.5466755032539368, -0.10656809061765671, 1.2610805034637451, -0.13294070959091187, -0.4595176577568054, -0.9591296315193176, 0.8550646901130676, 0.9143251776695251, 0.5376495122909546, -0.4336933195590973, 0.06735816597938538, ...
def loginout _ required ( function = none, redirect _ field _ name ='index ', login _ url = none ) : actual _ decorator = user _ passes _ test ( lambda u : anonymoususer. _ _ instancecheck _ _ ( u ), login _ url ='index ', redirect _ field _ name ='index ', ) if function : return actual _ decorator ( function ) return ...
[ -1.5762253999710083, 0.05952974408864975, 0.4101012349128723, 0.35169944167137146, -0.7851523160934448, 0.817851722240448, 0.3384568989276886, 0.5975022912025452, 0.8428836464881897, 0.20472179353237152, 0.2673913538455963, 0.4841417372226715, 0.17185954749584198, -0.4064619541168213, 0....
def lastlogbookentrybyuser ( self, username ) : all _ entries = self. alllogbookentriesbyuser ( username ) if all _ entries = = [ ] : return none else : return all _ entries [ - 1 ]
[ -0.31243255734443665, -1.0057008266448975, 0.5538133382797241, 0.7925665378570557, 0.0717969760298729, 0.2837906777858734, 0.01229618676006794, -0.49558186531066895, -0.5505505204200745, 0.08387476205825806, 0.09196849912405014, 0.1800549477338791, -1.0938981771469116, 0.3468532860279083, ...
def test _ i161 ( ) : # table i - 15 — the data bits after scrambling ( and resetting tail bits ) input = bits ('0110110000011001100010011000111101101000001000011111010010100101011000010100111111010111101011100'' 0100100000011001111001100111010111001001011110001010011100110001100000000011110001101011011001111'' 1000111...
[ 1.1392927169799805, 0.29057952761650085, 1.0748449563980103, -0.3881112337112427, 0.1314200609922409, 0.11882683634757996, 1.6349880695343018, -0.8063157200813293, -0.3101383447647095, -0.11067937314510345, -0.5087465047836304, 1.0074491500854492, -0.5438803434371948, -0.05594827979803085,...
def read _ token _ from _ stdin ( ) : print ('enter the raw token json ( press ctrl + d on a blank line to submit ) ', file = sys. stderr ) token _ json = sys. stdin. read ( ) return token _ json
[ -0.6061636805534363, -0.9196652173995972, 0.4826188087463379, -0.5334145426750183, -1.1584643125534058, 0.3141208291053772, -0.12748143076896667, -0.13419020175933838, -0.6650420427322388, -0.26717472076416016, -0.34791699051856995, 1.4100680351257324, 0.2638198137283325, -0.63410210609436...
def _ _ init _ _ ( self, params = { }, constants = { }, verbose = true ) : self. params = params self. constants = constants cases = [ constants ] for k, v in params. items ( ) : cc = [ ] for vv in v : for c in cases : a = deepcopy ( c ) a [ k ] = vv cc. append ( a ) cases = cc self. models = [ population ( * * c ) for...
[ -0.5752810835838318, 0.012511085718870163, 0.6784150004386902, 1.0608328580856323, 0.553252637386322, 0.8591828942298889, -0.3051811158657074, 0.16955414414405823, -0.4246702194213867, 0.8905946016311646, 0.05600370839238167, -0.6900649070739746, 0.18624699115753174, 0.37494561076164246, ...
def test _ idtoken _ token _ response ( self ) : data = {'client _ id': self. client. client _ id,'redirect _ uri': self. client. default _ redirect _ uri,'response _ type': next ( self. client. response _ type _ values ( ) ),'scope':'openid email ','state': self. state,'nonce': self. nonce,'allow':'accept ', } respons...
[ -0.344195157289505, -0.5977878570556641, 0.5176612734794617, -0.6107646226882935, 0.41353434324264526, 0.40155029296875, 0.09912368655204773, -0.49686214327812195, 0.438616007566452, -0.9789771437644958, -0.9950547814369202, 0.1881992220878601, -0.1009836196899414, -0.7648120522499084, 0...
def print _ type _ format ( trigger, content = none, description = none ) : return ( " % s \ t % s " % ( trigger, description ), " % s " % ( content or trigger ) )
[ 0.5494068264961243, -0.7812325954437256, 0.24575316905975342, -0.7621465921401978, 0.4508010149002075, -0.7772833704948425, -1.186926007270813, -0.5645530819892883, -0.9045704007148743, -0.15214678645133972, 0.4123975932598114, 0.7107770442962646, -0.19195444881916046, -0.08938919007778168...
def _ get _ tile _ neighbor ( self, tile, neighbor _ position ) : relationship _ index = none if neighbor _ position. capitalize ( ) = = " north " : relationship _ index = 0 elif neighbor _ position. capitalize ( ) = = " east " : relationship _ index = 1 elif neighbor _ position. capitalize ( ) = = " south " : relation...
[ 0.21808069944381714, 0.023724254220724106, 0.6025951504707336, -0.6873924136161804, -0.6746506690979004, 0.5656665563583374, -0.35354170203208923, -1.0370819568634033, -0.7320080995559692, 0.0258945282548666, 0.6709175109863281, 0.2411114126443863, -0.5128165483474731, -0.51803058385849, ...
def endworld ( self, days, destination ) : try : days = int ( days ) destination = int ( destination ) except valueerror : print ( " bad # of days or destination population provided. worldend skipped. " ) return if destination > self. _ max _ solvers : destination = self. _ max _ solvers m = ( self. _ max _ solvers - d...
[ -1.4450515508651733, 1.3908870220184326, 0.5142229199409485, 0.1832924783229828, -0.5024000406265259, 0.24368885159492493, 0.22967670857906342, -0.36643433570861816, -0.3970251977443695, 0.4569690525531769, 0.27152112126350403, 0.1288730651140213, 0.1531553864479065, 0.43991339206695557, ...
def test _ auto _ cancel _ open _ orders _ without _ symbol ( ) : client = client ( key, secret ) client. auto _ cancel _ all. when. called _ with ( symbol = " ", count _ down _ time = 2000 ). should. throw ( parameterrequirederror )
[ 0.44470489025115967, 0.4276423454284668, 0.36056917905807495, 0.7207071185112, 0.005373068153858185, -0.02749684453010559, 0.7792068123817444, -0.3059394955635071, -0.12388347834348679, 0.0020433515310287476, -0.7057405710220337, 0.21811196208000183, 0.08057692646980286, 0.7943069934844971...
def connectcouchdb ( ) : global client # set this as env variable as well if too sensitive username ='ttermserseentsmistellacq'password ='fad461f53aec6a2faaf7b21eb402c4684b6723b1'# username = os. environ. get ('cloud _ un') # password = os. environ. get ('cloud _ pw') account ='https : / / dhurng. cloudant. com'client ...
[ -0.14040279388427734, -0.6378974318504333, 0.609829843044281, -0.05133891850709915, 0.32221993803977966, 0.8617243766784668, -0.0532546304166317, -0.11553222686052322, -0.675347089767456, -0.1879407912492752, -0.42743349075317383, -0.2560574412345886, -0.270401269197464, 0.0539495162665843...
def run _ heartbeat ( self ) : self. bind _ heatbeat = self. heatbeat _ connect ( ) heartbeat _ at = self. get _ heartbeat heartbeat _ misses = 0 while true : self. log. debug ( " heartbeat misses [ % s ] ", heartbeat _ misses ) socks = dict ( self. poller. poll ( self. heartbeat _ interval * 1000 ) ) if socks. get ( s...
[ -0.6362359523773193, -0.18326015770435333, 1.0820565223693848, 0.6964595317840576, 0.04122411087155342, 0.3702859878540039, -0.12462686747312546, -0.5444297790527344, -0.32062622904777527, -0.0366450734436512, -0.25183814764022827, 0.9474036693572998, -0.43160054087638855, 0.74712121486663...
def service _ url ( self ) : return " http : / / % s " % utils. join _ host _ port ('localhost ', self. port )
[ 0.3122120797634125, -0.5047473907470703, 0.3309747874736786, -0.4405955672264099, 0.4495639204978943, 0.8380717039108276, -0.1924750953912735, 0.2379504293203354, -1.0737656354904175, -0.048087071627378464, 0.31939661502838135, 0.8510985970497131, -0.2703501284122467, 0.4206712543964386, ...
def make _ count _ heatmap ( count _ file, gffhash ) : df = pd. read _ table ( count _ file, index _ col ='transcript') out = open ( count _ file + '. circos ','w') for i, genome in enumerate ( gffhash ) : for gene in gffhash [ genome ] ['genes'] : g = gffhash [ genome ] ['genes'] [ gene ] tpm = df. loc [ gene,'count']...
[ 1.05328369140625, -0.7130635976791382, 0.7134212851524353, -0.21504874527454376, 0.42962968349456787, 0.5784692168235779, -0.045275378972291946, 1.1895225048065186, -1.6070282459259033, 0.5447051525115967, -0.04557349905371666, 0.0652386024594307, 0.41888877749443054, 0.16915550827980042, ...
def plot _ obs _ prop _ vs _ prop ( xprops, yprops, snaps, pixel _ res = 2, bin _ nums = 10, labels = none, foutname ='obs _ dz _ vs _ param. png ', \ std _ bars = true, style ='color - linestyle ', include _ obs = true, aggregate _ obs = false, mask _ prop = none, show _ raw _ data = true, r _ max = 10 ) : # get plot ...
[ 0.18784251809120178, 0.6362546682357788, 1.08724844455719, 0.758588969707489, -0.11563239991664886, 0.8752673864364624, 0.7542765140533447, -0.5130927562713623, 0.3796458840370178, -0.09930863976478577, 0.8374582529067993, 0.22240948677062988, 0.7959038615226746, -0.1749487817287445, -0....
def float32 _ variable _ storage _ getter ( getter, name, shape = none, dtype = none, initializer = none, regularizer = none, trainable = true, * args, * * kwargs ) : norm = " norm " in name. lower ( ) or " bn " in name. lower ( ) storage _ dtype = tf. float32 if trainable else dtype variable = getter ( name, shape, dt...
[ -0.1080392450094223, 0.031500380486249924, 0.6098698973655701, 0.007999064400792122, -0.678331732749939, -0.36118119955062866, 0.40074947476387024, -1.0142335891723633, -0.10463622957468033, 0.165011465549469, -0.018499324098229408, 0.3790024518966675, -0.10620935261249542, 0.2712383568286...
def xtec _ map ( ) : from matplotlib import colormaps from matplotlib. colors import listedcolormap cm _ data = list ( colormaps ['tab10']. colors ) cm _ data. insert ( 0, [ 1. 0, 1. 0, 1. 0 ] ) return listedcolormap ( cm _ data, name ='xtec')
[ 0.8424206972122192, -0.6577703952789307, 0.3782022297382355, -1.2781713008880615, 0.40559840202331543, -0.27015334367752075, -0.507474422454834, 0.01207116898149252, 0.5761728286743164, 0.15898247063159943, -0.3553735911846161, -0.14100515842437744, 0.7598211765289307, -0.6620983481407166,...
def bot _ send ( msg, bot _ id, broadcast ) : if broadcast = = true : bot = telegram. bot ( token = config [ bot _ id ] [ " bot _ api _ token " ] ) bot. sendmessage ( chat _ id = config [ bot _ id ] [ " group _ chat _ id " ], text = msg ) else : print ( msg ) return none
[ 0.3269746005535126, 0.0715329721570015, 0.5256405472755432, 0.7077836394309998, 0.27840912342071533, 0.5969909429550171, -0.8496673703193665, 0.03723110631108284, -0.4810822904109955, 0.47453561425209045, 0.14175723493099213, 1.0745316743850708, -0.9703670740127563, 0.8035318851470947, -...
def signedon ( self ) : if not is _ testing _ mode : if self. npasswd : self. msg ( " nickserv ", " id " + self. npasswd ) self. msg ( " chanserv ", " identify " + self. channel + " " + self. npasswd ) self. msg ( " chanserv ", " op " + self. channel ) self. join ( self. factory. channel )
[ -0.25886842608451843, -0.7896366715431213, 0.3001842498779297, 0.04963652789592743, 0.5600256323814392, 0.501426100730896, 0.3183513581752777, -0.033134669065475464, 0.9874776601791382, -0.25721606612205505, -0.8271238803863525, 0.7100601196289062, -1.3807427883148193, 0.23325693607330322,...
def ca _ host _ verify ( self ) : return self. _ data. get ('inputs ', { } ). get ('hashi _ vault _ pre _ python _ 279 _ cahostverify')
[ 0.26095137000083923, 0.2551173269748688, 0.19281180202960968, 1.352997899055481, -0.168720543384552, 0.7894480228424072, 0.2858455777168274, -0.17844516038894653, -0.11391376703977585, -0.4876622259616852, -1.0691264867782593, 0.32420438528060913, 0.05397053807973862, 0.4547664523124695, ...
def connect ( self ) : return psycopg2. connect ( dbname = self. dbname, host = self. host, port = self. port, user = self. user, password = self. password )
[ -0.49565985798835754, -0.7945809960365295, 0.5670008659362793, 0.5009419322013855, -0.5066176652908325, -0.08856410533189774, -0.9833555817604065, 0.36756300926208496, -1.9403637647628784, -0.4576217532157898, -0.005871133413165808, -0.07608600705862045, -1.162211298942566, -0.242854177951...
def temp ( self, new _ temp ) : if not self. valid _ temp ( new _ temp ) : raise valueerror # else self. _ temp = new _ temp
[ 0.2727963626384735, -0.5094922780990601, 0.05730089917778969, 0.008996861055493355, 0.3619358539581299, 0.07089816778898239, 0.4143237769603729, 0.5223497748374939, -0.7107558250427246, 0.40648505091667175, -0.5747395157814026, 0.23662300407886505, -0.2574230134487152, 0.2372453361749649, ...
def get _ recommendation _ group _ with _ http _ info ( self, start, end, logged _ in _ user _ id, access _ token, client _ token, * * kwargs ) : all _ params = ['start ','end ','logged _ in _ user _ id ','access _ token ','client _ token ','fields'] all _ params. append ('callback') all _ params. append ('_ return _ h...
[ -0.2113134264945984, 0.9679476618766785, 0.8619429469108582, 0.07798395305871964, -0.33899226784706116, -0.12674623727798462, -0.5257649421691895, -1.0750850439071655, -1.5337518453598022, 0.18146425485610962, 0.5655481815338135, 1.764958143234253, -0.8390167355537415, 0.26278355717658997,...
def update _ dataset _ vars ( conn, dataset, n _ vars ) : try : sql = " update beacon _ dataset _ table set size = % s where id = % s ; " result = conn. execute ( sql, n _ vars, dataset ) return result. rowcount except : log. error ('unexpected error : % s ', sys. exc _ info ( ) [ 0 ] ) return
[ -1.1195653676986694, 0.8867022395133972, 0.49649176001548767, -0.14983423054218292, -0.9753486514091492, -0.8370604515075684, -0.3804238736629486, -0.21530403196811676, -0.371905654668808, 0.640579342842102, -0.21802431344985962, -0.23448145389556885, -0.7209836840629578, 0.575474262237548...
def test _ get _ metric _ name ( self ) : self. assertequal ('ib _ message _ flow _ status ', get _ metric _ name ( metric _ label ='status') )
[ 0.8436088562011719, 0.3610614538192749, 0.15633311867713928, 1.0434465408325195, 0.6207349896430969, 1.0685882568359375, -0.032467830926179886, -0.20338080823421478, -0.379091739654541, 0.5298603773117065, 0.10285045951604843, 0.22978806495666504, -0.27060362696647644, -0.5233184695243835,...
def execute _ rows ( self, sql : str, * params ) - > list [ dict [ str, any ] ] : cursor = self. _ _ conn. cursor ( as _ dict = true ) cursor. execute ( sql, * params ) rows = cursor. fetchall ( ) cursor. close ( ) return rows
[ -0.2643935978412628, 0.6180567145347595, 0.49024343490600586, 0.48950737714767456, 0.3432752192020416, -0.5455020666122437, -1.8643860816955566, 0.7088499665260315, -0.26027199625968933, 0.7254107594490051, 0.6188380122184753, -0.4164717197418213, 0.4528796672821045, 1.0291537046432495, ...
def helloworld ( * args ) : # write'hello world'in a1 active _ sheet. getcellrangebyname ( " a1 " ). string = " hello world! "
[ 0.18190434575080872, -0.4734472632408142, 0.5118602514266968, 0.7937520742416382, 0.6530284881591797, 1.304456114768982, 0.40488409996032715, 0.3776927590370178, -0.3916280269622803, 1.0475800037384033, -0.15919581055641174, 0.10809279978275299, -0.008853253908455372, 0.13331691920757294, ...
def update _ progress ( done _ ratio, time _ passed = none, time _ left = none ) : bar ='#'* int ( done _ ratio * 20 ) string = " \ r [ { 0 : 20s } ] { 1 :. 1 % } ". \ format ( bar, done _ ratio ) if time _ passed is not none : time _ str = str ( timedelta ( seconds = time _ passed ) ) string + = " time elapsed : { } "...
[ 0.055060841143131256, 0.05048530548810959, 1.0060186386108398, -0.04045489430427551, 0.14985568821430206, 0.744376540184021, 0.16076965630054474, -0.4583340287208557, -1.0202231407165527, 0.5928565859794617, 0.26964545249938965, -0.3425608277320862, -0.5222622752189636, 1.0455924272537231,...
def _ formatdatetime ( self, output _ mediator, event, event _ data ) : # pylint : disable = missing - return - type - doc try : datetime _ object = datetime. datetime ( 1970, 1, 1, 0, 0, 0, 0, tzinfo = pytz. utc ) datetime _ object + = datetime. timedelta ( microseconds = event. timestamp ) datetime _ object. astimezo...
[ 0.40799403190612793, -0.7876734733581543, 0.5520728826522827, -0.0023848882410675287, -0.8856728076934814, -0.21786849200725555, -0.05508629232645035, 0.19175641238689423, 0.6232891082763672, 0.8351566791534424, 0.8606138229370117, -0.06851562112569809, 0.576473593711853, 0.116193220019340...
def index ( ) : return render _ template ( " index. htm ", hotels = hotels )
[ -0.1923021525144577, 0.7331094145774841, 0.03121841326355934, 0.3609100878238678, -0.24549949169158936, 0.7425755858421326, 0.6165585517883301, 1.7964692115783691, -0.9366113543510437, 0.5796343684196472, -0.21274107694625854, -0.20589594542980194, 0.10110462456941605, -0.08431002497673035...
def compute _ minimax _ star _ top ( u _ star, g, use _ movement _ constraints = true, * * solver _ args ) : x _ list = [ ] for u in u _ star : x, _, _ = compute _ two _ player _ minimax ( u, g, * * solver _ args, use _ movement _ constraints = use _ movement _ constraints ) x _ list. append ( x ) _, y _ list, p = comp...
[ -2.061898708343506, -0.0270234402269125, 0.6386198401451111, 1.0171905755996704, -0.46841806173324585, -0.23826183378696442, -0.15923668444156647, 0.6967913508415222, -0.1664857268333435, 1.016240119934082, -0.6935165524482727, 0.029455536976456642, 0.10503990948200226, -0.0682227313518524...
def mark _ sequence ( self, seq, color = default _ mark _ color ) : node = self. current marked [ id ( node. original ) ] = interpret _ color ( color ) for key in seq : marked [ id ( node [ key ]. original ) ] = interpret _ color ( color ) node = node [ key ]
[ -1.3135453462600708, -0.2662021815776825, 0.39041683077812195, -0.8634352087974548, 0.6256664395332336, -0.3616366386413574, 0.003809826448559761, 1.4906940460205078, -0.19373761117458344, 1.083958625793457, -0.7848390936851501, 0.7862297296524048, 0.4244917333126068, 0.4909752905368805, ...
def changeleftlimit ( self ) : self. leftlimit = true self. cleanspikelist ( )
[ 0.6371384263038635, 0.4997374713420868, 0.22921521961688995, -0.033028505742549896, -0.6837801933288574, 0.5714462995529175, -0.37237128615379333, 1.3891433477401733, 0.6852775812149048, 1.0546153783798218, -1.3743197917938232, 1.359468698501587, -0.5244801044464111, 1.2266916036605835, ...
def day ( self ) - > int : return self. _ day
[ -0.5931700468063354, 0.392280250787735, 0.44636550545692444, 0.5957993268966675, 0.4535066485404968, 1.0816344022750854, 1.21640944480896, -0.4533575475215912, -0.5966166257858276, -1.6954668760299683, -0.47039395570755005, -0.007301722187548876, 0.42402520775794983, 0.5288708806037903, ...
def cross ( boat ) : try : x = boat. contents. index ('p') if ( boat. side = = 0 ) : boat. side = 1 else : boat. side = 0 return 1 except valueerror : # no people in the boat return 0
[ -0.6466227173805237, 0.42727088928222656, 0.6737664341926575, -0.33328619599342346, 0.3815404772758484, 0.4942087233066559, 0.23834571242332458, 0.7412000894546509, -0.01675543747842312, 0.3661767244338989, 0.47160565853118896, -0.4621034264564514, -1.3449338674545288, 0.042154960334300995...
def do _ delete ( self, node _ id ) : _ error _ code, _ msg = ramstkdatamodel. do _ delete ( self, node _ id ) # pylint : disable = attribute - defined - outside - init # it is defined in ramstkdatamodel. _ _ init _ _ if _ error _ code! = 0 : _ error _ code = 2005 _ msg = _ msg +'ramstk error : attempted to delete non ...
[ 0.49301302433013916, 0.23141756653785706, 0.822455108165741, -0.7726694941520691, 1.3100006580352783, -0.5586357712745667, 0.12569142878055573, 0.7194064855575562, -0.22085162997245789, 1.0022194385528564, 0.11795477569103241, 0.3875637948513031, -0.42465120553970337, 0.3278917670249939, ...
def semester ( today = date. today ( ) ) : if today. month > 8 : return " fall { } ". format ( today. year ) elif today. month < 5 or today. month = = 5 and today. day < 16 : return " spring { } ". format ( today. year ) else : return " summer { } ". format ( today. year )
[ -0.16793981194496155, -1.2527517080307007, 1.0592224597930908, -0.13168270885944366, -0.9526177048683167, 0.3688696622848511, -0.24631589651107788, -1.1685757637023926, 0.7433376312255859, -0.5682560205459595, 0.4571218490600586, 0.6818628907203674, 0.31338199973106384, 0.48411059379577637...
def _ _ init _ _ ( self, * args ) : _ stepap209. stepap209 _ construct _ swiginit ( self, _ stepap209. new _ stepap209 _ construct ( * args ) )
[ -0.23819699883460999, -0.9152042269706726, 0.35467925667762756, 0.4524289667606354, -0.4174988567829132, -0.011489237658679485, 1.0311658382415771, 1.2251847982406616, -0.08597163110971451, -1.1214351654052734, -0.6642511487007141, -0.8638710975646973, 0.4695701003074646, 0.799858093261718...
def chaffling ( self ) : chaff _ txt = const. tls _ uni _ chaff _ url _ path chaff _ msg = ccpmessage. chaff _ msg ( len ( chaff _ txt ), buf = chaff _ txt ) msg _ buf = chaff _ msg. pack ( ) cnt = 4 if ( self. num _ chaff _ received < 5 ) or ( self. num _ data _ received > 0 ) : cnt + = 20 if self. num _ data _ receiv...
[ 0.11968418210744858, 0.9821145534515381, 0.594649612903595, -1.2794194221496582, 0.3688114285469055, 0.6905345916748047, 0.7102826833724976, -0.2919180691242218, -0.3244799077510834, -0.6026280522346497, -0.7746574282646179, 0.30205264687538147, -0.8908893465995789, 0.533575713634491, 0....
def test _ sequential _ work ( self ) : task1 = startupandwaittask ( ) task2 = startupandwaittask ( ) ctask = taskcontainer ('tester') ctask. parent = workerproxy ( ) ctask. add _ task ( task1 ) ctask. add _ task ( task2 ) return threads. defertothread ( self. verify _ sequential _ work, task = ctask )
[ 0.6386252641677856, 0.9912950396537781, 0.6554672122001648, 1.120755672454834, 0.6207669377326965, 0.14626969397068024, 1.1819554567337036, -0.35228240489959717, 0.03003115952014923, -1.2253234386444092, -0.8556994795799255, -0.326627641916275, -0.5830001831054688, 0.5810506939888, -1.07...
def network _ service _ to _ internal ( nsd ) : service = { } service [ " service _ name " ] = nsd [ " id " ] # see what to do w. service name if " max _ latency " in nsd : service [ " max _ latency " ] = nsd [ " max _ latency " ] if " target _ availability " in nsd : service [ " target _ availability " ] = nsd [ " tar...
[ -0.5247299671173096, -0.280840665102005, 0.4747289717197418, -1.0024991035461426, -1.1235452890396118, -0.3870850205421448, -0.41124609112739563, -0.6528617739677429, -0.22803504765033722, 0.3762880861759186, 0.057158563286066055, 0.4281982481479645, -0.0378313809633255, 0.7822413444519043...
def test _ adding _ unknown _ device _ to _ config ( self ) : scanner = get _ component ('device _ tracker. test'). scanner scanner. reset ( ) scanner. come _ home ('dev1') with assert _ setup _ component ( 1, device _ tracker. domain ) : assert setup _ component ( self. hass, device _ tracker. domain, { device _ track...
[ -0.33824798464775085, 0.6831691861152649, 0.43594294786453247, 0.5362725853919983, 0.6817703247070312, 0.4586077630519867, 0.2208346426486969, 0.39826855063438416, -0.00012967322254553437, -0.2836621105670929, -0.641357421875, -0.1868816763162613, 0.4041685163974762, 0.9962368607521057, ...
def cover ( self, other ) : x1 = min ( self. pt1. x, other. pt1. x ) y1 = min ( self. pt1. y, other. pt1. y ) x2 = max ( self. pt2. x, other. pt2. x ) y2 = max ( self. pt2. y, other. pt2. y ) return rectangle ( x1, y1, x2, y2 )
[ 0.4570314884185791, -0.5557776093482971, 1.154212236404419, 0.7900583148002625, -1.036502718925476, 0.4598405063152313, -0.12740933895111084, -0.6629266142845154, 0.09628734737634659, -0.11518198251724243, 0.15023168921470642, -0.18849748373031616, -0.3797908127307892, -0.25402727723121643...
def step ( self, action ) : obs = self. gym. get _ observations ( ) all _ actions = self. gym. act ( obs ) all _ actions. insert ( self. gym. training _ agent, action ) state, reward, terminal, info = self. gym. step ( all _ actions ) action = all _ actions [ self. gym. training _ agent ] # agent _ state = self. featur...
[ -0.295863538980484, -0.37800124287605286, 0.4764372706413269, -0.31299102306365967, 0.31734874844551086, -0.2941395342350006, -0.16568298637866974, 0.01461415458470583, -0.06978805363178253, -0.2513306736946106, -0.7579742670059204, 0.3014753758907318, 0.9234638214111328, 0.031664211302995...
def createaddingentities ( self, * args ) : return _ stepap209. stepap209 _ construct _ createaddingentities ( self, * args )
[ -0.8688390851020813, -0.6736963391304016, 0.4773114323616028, 0.07619354873895645, 0.45091238617897034, 0.9345412254333496, 0.4465603828430176, 0.02446546033024788, -0.42165231704711914, -0.7975074648857117, -0.5188713073730469, -0.8448441624641418, -0.21611055731773376, 1.0474547147750854...
def _ _ init _ _ ( self, w, d, pub, eps = 0, dlt = 0 ) : if _ _ debug _ _ : assert isinstance ( w, int ) and w > 0 assert isinstance ( d, int ) and d > 0 self. pub = pub self. d, self. w = d, w self. epsilon = eps self. delta = dlt self. packed = [ ] for i in range ( d ) : self. packed. append ( pack ( " i ", i ) ) # n...
[ 0.12290584295988083, 0.6692399382591248, 0.4789513051509857, 0.06802402436733246, -0.40263494849205017, 0.28992757201194763, 0.2345750778913498, -0.15716837346553802, 0.7174351811408997, -0.4578787386417389, -0.2191663384437561, -0.34258905053138733, -0.2991125285625458, 0.5034884810447693...
def make _ jtsk ( df ) : to _ jtsk = pyproj. proj ( init ='epsg : 5514') if'jtsk _ x'not in df. columns : jtsk _ coords = [ to _ jtsk ( lo, la ) for lo, la in zip ( np. array ( df. long ), np. array ( df. lat ) ) ] x, y = zip ( * jtsk _ coords ) df ['jtsk _ x'] = x df ['jtsk _ y'] = y if'lat'not in df. columns : ll = [...
[ -0.3175886273384094, 0.6864482760429382, 0.6250514388084412, -0.43514591455459595, -0.6015317440032959, -0.4797073006629944, -0.08685716986656189, 0.0324830524623394, -0.16542266309261322, 0.2911819517612457, -0.3651596009731293, -0.2907751798629761, 1.1072614192962646, 0.1525636613368988,...
def get _ next _ top _ k ( self, tokens : list [ str ], top _ k : int ) - > list [ tuple [ float, str ] ] : next _ log _ probs = self. get _ log _ probs ( tokens ) [ - 1 ] next _ k _ log _ probs = torch. topk ( next _ log _ probs, k = top _ k ) return next _ k _ log _ probs
[ -0.3287302255630493, -0.49345898628234863, 0.5854794383049011, 0.37020838260650635, -0.9814039468765259, -0.13152176141738892, -0.9718890190124512, -0.11077885329723358, -0.3792894184589386, 0.8889378905296326, -0.36310431361198425, 0.4523977041244507, 0.32645267248153687, -0.4993319213390...
def _ _ repr _ _ ( self ) : return self. name + ", " + str ( self. student _ num ) + ", " + str ( self. courses )
[ -0.5023341178894043, -1.5099269151687622, 0.811308741569519, -1.5747954845428467, -0.8056542277336121, 1.036346197128296, -0.5427621006965637, -0.14381009340286255, 0.014939750544726849, 0.3329682946205139, -0.4876144528388977, 0.3549574017524719, 0.5400009751319885, -0.7181942462921143, ...
def add _ mc _ sg ( self, ns _ key, g _ vec, s _ vec ) : return self. _ mc _ sg _ gen ( ns _ key, g _ vec, s _ vec,'igmp _ ns _ sg _ add')
[ -0.9506499171257019, 0.3109838366508484, 0.49369022250175476, 0.4718858599662781, -0.7142682671546936, -0.07866422086954117, 0.0068337866105139256, -0.9569860100746155, -0.2495690882205963, 0.9308080077171326, 0.10154762864112854, 0.4456898272037506, -0.6242836713790894, 0.3846014440059662...
def store ( self, context, key _ value, * * kwargs ) : key _ id = uuid. uuid4 ( ). hex return self. _ store _ key _ value ( key _ id, key _ value )
[ -0.8978738784790039, 0.06520931422710419, 0.1666027307510376, -0.13759064674377441, -0.37575531005859375, 0.29372820258140564, -0.8787453770637512, 0.015143560245633125, 0.3207392692565918, 0.04410560429096222, -0.9097031354904175, -0.44167134165763855, -0.5913981199264526, -0.257572472095...
def write _ build _ json ( self ) : # json output file json _ file = os. path. join ( self. _ target _ dir, self. _ prev _ build _ json ) # get current json content try : current _ json _ contents = json. load ( open ( json _ file,'r') ) except filenotfounderror : current _ json _ contents = { } # add this processor to...
[ -0.8517391085624695, -1.5897676944732666, 0.773841917514801, -0.6487748026847839, 0.2499513328075409, -0.13543857634067535, 1.113938570022583, 0.24477088451385498, -0.591330349445343, 0.43478748202323914, -0.8439490795135498, 0.7638989686965942, -0.09131696820259094, 0.022942017763853073, ...
def _ display _ extra _ task _ details ( self ) : # list all applications that appear up - to - date. for task in self. evolver. tasks : if ( isinstance ( task, evolveapptask ) and not task. evolution _ required ) : self. stdout. write ( _ ('application " % s " is up - to - date \ n') % task. app _ label ) if self. pur...
[ 0.20896536111831665, -0.28761643171310425, 0.8248320817947388, -0.05492549017071724, -0.14944863319396973, 0.5946152806282043, 0.2445288747549057, 0.016305115073919296, -0.18684884905815125, 0.9691475629806519, -0.06960175186395645, 0.6126783490180969, 1.2361234426498413, 0.920320093631744...
def go _ home ( self ) : xpath _ go _ home = self. util. read _ xpath _ list _ from _ xml ( self. object _ repo, " gohome ", self. my _ object ) for loop _ index in range ( 0, len ( xpath _ go _ home ) ) : print loop _ index self. object. click ( self. util. client, xpath _ go _ home [ loop _ index ] ['zone'], xpath _ ...
[ -0.6516130566596985, 0.24011124670505524, 0.646278440952301, 0.6309317946434021, 1.2734496593475342, 0.20402522385120392, 0.6436910033226013, -0.3907999098300934, 0.07803083211183548, 1.202326774597168, -0.40070652961730957, 0.8134403824806213, -0.9932408332824707, -0.006428597029298544, ...
def _ filterdefinition ( definition, enabled _ features ) : if isinstance ( definition, ast. enum ) : _ filterdisabledfromnodelist ( definition. enum _ value _ list, enabled _ features ) elif isinstance ( definition, ast. interface ) : _ filterdisabledfromnodelist ( definition. body, enabled _ features ) elif isinstanc...
[ -0.394329309463501, 0.1470234990119934, 0.49576959013938904, 0.38893184065818787, -0.9065521359443665, -0.33140867948532104, -0.07327835261821747, 0.8263982534408569, 0.4200023412704468, 0.6008986234664917, -0.36100274324417114, 0.6730450987815857, 0.0631800964474678, 0.8656834959983826, ...
def storage _ limit ( self ) - > int : return int ( self. limits [ " storage _ size _ limit " ] )
[ 0.29485586285591125, 0.5493560433387756, 0.4937412738800049, 0.6412890553474426, 0.42869123816490173, 0.5027819275856018, 0.24864549934864044, -0.07057265937328339, 0.4214017987251282, -0.1816389113664627, -0.07856046408414841, 0.3038847744464874, 0.05252524092793465, -0.9048025608062744, ...
def set _ speed _ cmd ( self, cmd ) : self. speed _ cmd = cmd
[ 0.4279804527759552, -0.6216848492622375, 0.49660322070121765, 0.37989434599876404, 1.018566608428955, 0.8851505517959595, 0.689785361289978, -0.20799922943115234, -0.23465687036514282, -0.7591204643249512, -0.34753715991973877, 0.6838148832321167, 0.06905722618103027, 1.787824034690857, ...
def _ _ repr _ _ ( self ) : return f'< { self. _ _ class _ _. _ _ name _ _ } { self. type. name } user = { self. user. full _ name! r } > '
[ -0.442282497882843, -1.1837782859802246, 0.6375406980514526, -0.47086042165756226, -0.5404586791992188, 0.6781390309333801, 0.03302197903394699, -0.8141429424285889, 0.508151650428772, -0.1083235815167427, -0.16132189333438873, 0.9052627086639404, 0.44919636845588684, 0.11772790551185608, ...
def joinmeeting ( self, params ) : join _ result = false params ['redirect'] ='true'meeting _ info = self. getbbbmeetinginfo ( params ['meetingid'] ) if meeting _ info = = false : join _ result = false elif meeting _ info ['returncode'] = = self. test _ success : join _ result = self. _ _ getnewrequesturl ( self. actio...
[ -0.9897956848144531, 0.12375067919492722, 0.8887506127357483, 0.8405428528785706, 0.2155996710062027, 0.715879499912262, -0.024137863889336586, 0.04955805465579033, -0.5850640535354614, 0.2555912733078003, 0.899638831615448, -0.5467026829719543, -1.8471933603286743, 0.33920153975486755, ...
def set _ backlight ( self, state ) : return self. set _ option ( 1, 0x01 if state else 0 )
[ 0.05272413045167923, 0.43195071816444397, 0.5287806391716003, 0.637690544128418, 0.6112877130508423, -0.31652384996414185, 0.7858393788337708, -0.0432867668569088, 0.8697962760925293, 0.43138864636421204, -0.15880298614501953, 0.5274519324302673, -0.9564361572265625, -0.4489929974079132, ...
def get _ budget ( self, rung = none ) : if rung is not none : return self. budgets [ rung ] return self. budgets [ self. current _ rung ]
[ -0.9362276792526245, -0.38483768701553345, 0.22711463272571564, 0.9449504613876343, -0.13381263613700867, -0.37840431928634644, 0.3919737935066223, -0.44580498337745667, 0.2286999672651291, -0.5948549509048462, 0.2333349734544754, 1.7475426197052002, -1.2936115264892578, 0.7511707544326782...
async def async _ step _ reauth ( self, entry _ data : mapping [ str, any ] ) - > flowresult : self. _ reauth _ entry = self. hass. config _ entries. async _ get _ entry ( self. context [ " entry _ id " ] ) return await self. async _ step _ reauth _ validate ( )
[ -0.493042916059494, -0.11714589595794678, 0.3756621181964874, 0.8613203167915344, 0.688868522644043, -0.9933868050575256, 0.01994498260319233, 0.9304267764091492, 0.786134660243988, 0.10054769366979599, -0.1360740065574646, 1.5849206447601318, 0.16768217086791992, -0.7678026556968689, 0....
def add _ system ( self, system _ instance, priority = 0 ) : if [ true for s in self. _ systems if type ( s ) is type ( system _ instance ) ] : raise duplicatesystemtypeexception ( ) system _ instance. priority = priority system _ instance. sys _ man = self self. _ systems. append ( system _ instance ) self. _ systems....
[ -1.4435049295425415, 0.17210139334201813, 0.4881596565246582, -0.15496639907360077, 0.3668580651283264, 0.9410479664802551, -0.6328575015068054, -0.22448991239070892, 1.350229024887085, -1.0592596530914307, -0.40804338455200195, 0.14187496900558472, -0.07628621906042099, 1.515644907951355,...