text stringlengths 25 2.19k | embedding listlengths 768 768 |
|---|---|
def get ( self, oid ) : vars = netsnmp. varlist ( netsnmp. varbind ( oid ) ) # must be a list # res = netsnmp. snmpgetbulk ( 1, oid, version = version, desthost = dest _ host, community = community ) res = self. session. get ( vars ) if res : # print res for var in vars : print " % s. % s = % s : % s " % ( var. tag, va... | [
-0.2835869789123535,
-0.567162811756134,
0.6138448715209961,
-0.16395409405231476,
-0.19520393013954163,
-0.8754264116287231,
-1.2406439781188965,
-0.6492589116096497,
0.8202176690101624,
0.20548991858959198,
-0.9713768362998962,
0.6165304183959961,
-0.6587648987770081,
0.34693393111228943... |
def test _ against _ numpy _ stack ( self ) : stream = [ np. random. random ( ( 15, 7, 2, 1 ) ) for _ in range ( 10 ) ] with self. subtest ( " axis = - 1 " ) : dense = np. stack ( stream, axis = - 1 ) from _ stack = stack ( stream, axis = - 1 ) self. asserttrue ( np. allclose ( dense, from _ stack ) ) | [
0.31106850504875183,
0.6674948334693909,
0.7252856492996216,
0.7344197034835815,
0.8468347191810608,
0.47111937403678894,
0.7426588535308838,
-0.7072890996932983,
0.40159663558006287,
0.16406624019145966,
-0.42932650446891785,
0.5287612676620483,
-0.5534105896949768,
0.02717234566807747,
... |
def test _ get _ branches ( self ) : branches _ api _ response = json. dumps ( [ {'name':'master ','id':'c272edcac05b00e15440d6274723b639e3acbd7c ', }, {'name':'im _ a _ branch ','id':'83904e6acb60e7ec0dcaae6c09a579ab44d0cf38 ', } ] ) def _ http _ get ( self, * args, * * kwargs ) : return branches _ api _ response, non... | [
0.4479556679725647,
1.1276108026504517,
0.5763342976570129,
-0.4402618706226349,
1.1200705766677856,
-0.29873907566070557,
-0.5279916524887085,
-0.5061531066894531,
-0.2818094789981842,
-0.26313766837120056,
-0.4329266846179962,
0.4945276081562042,
-0.5619813799858093,
0.09982139617204666,... |
def labelmutation ( request, sentid = none, mutid = none ) : print str ( sentid ), str ( mutid ) if not sentid is none : sentid = int ( sentid ) if not mutid is none : mutid = int ( mutid ) interactioneffectformset = formset _ factory ( interactioneffectform, extra = 0 ) if request. method = ='post': annot _ form = ann... | [
-0.17987680435180664,
-1.164170742034912,
0.8062126040458679,
-0.06433051824569702,
0.06949987262487411,
-0.49998441338539124,
-0.5449076294898987,
0.12977775931358337,
0.7156082391738892,
0.0713886171579361,
0.5234346389770508,
0.7124812602996826,
-0.054520998150110245,
0.4545004963874817... |
def setoutputamplifier ( typ ) : return none | [
-0.707102358341217,
-1.4443163871765137,
0.43199244141578674,
-0.28347378969192505,
-0.8066177368164062,
0.4970141053199768,
1.3073229789733887,
-0.6221027970314026,
0.3336997926235199,
-0.03179650753736496,
-0.4418531656265259,
-0.05769716948270798,
-0.21211926639080048,
0.045134194195270... |
def is _ clear ( self, y _ pos, x _ pos, y _ dim, x _ dim, thorough = true ) : # y _ dim = dimension of object yrange = range ( 0, y _ dim + 1 ) xrange _ inner = list ( range ( 1, x _ dim ) ) xrange _ outer = [ 0, x _ dim ] xrange = xrange _ inner + xrange _ outer if y _ pos < = 1 or x _ pos < = 1 : return false if y _... | [
-0.3078238368034363,
-0.48705366253852844,
0.9860702157020569,
-1.061612844467163,
-1.548449158668518,
0.41831544041633606,
-0.11231027543544769,
-0.10776307433843613,
-0.30778127908706665,
0.6152633428573608,
-0.11892125755548477,
0.3961719274520874,
0.3371945917606354,
0.7188454270362854... |
def main ( ) : # track our work fp = open ( " myhucs. txt ", " w " ) # change the working directory to where we have data files os. chdir ( ".. /.. / data / % s " % ( sys. argv [ 2 ], ) ) # collect up the dbfs in that directory fns = glob. glob ( " *. dbf " ) i = 0 cursor = pgconn. cursor ( ) for fn in tqdm ( fns ) : #... | [
0.13751642405986786,
0.549056887626648,
0.9914696216583252,
-0.04177071526646614,
1.1730512380599976,
-0.7678075432777405,
0.8407745957374573,
0.45543932914733887,
-0.6417691707611084,
-0.49364665150642395,
-0.25350674986839294,
-0.11598212271928787,
-0.4935044050216675,
-0.670668601989746... |
def get _ nodes ( self, * * kwargs ) : return [ node ( self, x ) for x in self. redis. sinter ( ['{ } : i : n : { } : { } '. format ( self. name, k, kwargs [ k ] ) for k in kwargs ] ) ] | [
-1.103803277015686,
0.4114605188369751,
0.29063746333122253,
0.022156590595841408,
0.9996289014816284,
-0.30940839648246765,
-1.3678053617477417,
0.13763393461704254,
-0.31656286120414734,
0.4441961944103241,
-0.9549939036369324,
0.3259792923927307,
-0.3979322016239166,
-0.0915501713752746... |
def check ( v, typ ) : if not type ( v ) = = typ : raise boogieruntimeexc ( " expected { } not { }. ". format ( typ, v ) ) | [
0.5323626399040222,
0.041617605835199356,
0.27831313014030457,
0.5407518744468689,
0.459172785282135,
0.19504396617412567,
0.216055765748024,
-0.031190475448966026,
0.29468414187431335,
0.4336724877357483,
0.24678786098957062,
1.7805925607681274,
-1.2549612522125244,
0.1510087549686432,
... |
def inbound _ links ( self, to _ url, limit _ links = 2500, skip _ links = 0, sort _ links = " from _ pubdate _ desc, from _ rank10 _ desc " ) : data = self. _ request ('/ api / inbound ', locals ( ) ) return result ( json. loads ( data ) ) | [
-1.2156052589416504,
-0.028355255722999573,
0.4229649305343628,
-0.03570711240172386,
0.15827591717243195,
-0.14565472304821014,
-0.8823148012161255,
-0.12723074853420258,
-0.2896665632724762,
0.11489879339933395,
-0.6310214996337891,
1.6888635158538818,
-0.8156132102012634,
-0.43148276209... |
def test _ testsnotrun ( self ) : self. runner. run ( self. test ) self. assertequal ( self. log, [ ] ) | [
0.20830398797988892,
-0.003945971839129925,
0.12594886124134064,
-0.15744467079639435,
0.9927904605865479,
1.4538273811340332,
0.7613498568534851,
-0.15543974936008453,
0.013871431350708008,
-1.2218410968780518,
-0.6302556395530701,
-0.14271892607212067,
-0.9231410026550293,
0.914981484413... |
def token ( self, value ) : self. _ update _ values ('hashi _ vault _ token ', value, parent _ attribute ='inputs') | [
-0.21217456459999084,
0.25278159976005554,
0.31287166476249695,
0.4795897901058197,
0.69883131980896,
0.47915661334991455,
0.7714982032775879,
-0.2542855739593506,
0.10965999960899353,
-0.7326903343200684,
-1.0113085508346558,
-0.4272955060005188,
0.8900140523910522,
-0.263055682182312,
... |
def test _ login _ status _ code ( self ) : response = self. client. get ('/ user _ auth / login /') self. assertequal ( response. status _ code, 200 ) | [
-0.35140714049339294,
-0.6403264999389648,
0.17599520087242126,
0.6663748025894165,
0.49362319707870483,
1.2572706937789917,
-0.4457324743270874,
0.9812076687812805,
0.19080649316310883,
-0.8306505084037781,
-0.5057990550994873,
0.2556890547275543,
0.9728942513465881,
-0.6504580974578857,
... |
def online _ total ( ) : return jsonify ( httpx. get ( graphite _ host, params = { " target " : " stats. gauges. bot. guild. status. online ", " from " : time _ frames [ request. args. get ( " frame ", " day " ) ], " format " : " json ", " maxdatapoints " : " 300 ", }, ). json ( ) [ 0 ] [ " datapoints " ] ) | [
-0.30329033732414246,
0.3419332206249237,
0.6477466821670532,
-0.5882392525672913,
-0.0759609192609787,
-0.42228564620018005,
-1.3456711769104004,
-0.3247065246105194,
-0.17033754289150238,
1.027686595916748,
-0.9724547863006592,
0.38206934928894043,
0.06856312602758408,
-0.683659613132476... |
def save ( self, filename ) : if filename [ - 5 : ]! = '. hdf5': filename = filename + '. hdf5'f = h5py. file ( filename,'w') # open a file # first the necessary data : psd = f. create _ dataset ('psd ', data = self. psd ) freqs = f. create _ dataset ('freqs ', data = self. freqs ) # whack in the info structure : info ... | [
0.05081460252404213,
-0.006171621847897768,
0.6031054854393005,
-0.5053384900093079,
0.37342339754104614,
-0.3172660768032074,
0.36969736218452454,
-0.024410394951701164,
-0.4942634701728821,
-1.4285398721694946,
-0.2650550305843353,
-0.8335654139518738,
-0.4231564402580261,
0.243993818759... |
def neu2xyz ( self, corr = false, verbose = false ) : # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # check x0, y0, z0 if self. x0 is none : print ( "!!! error : x0, y0, z0 attributes required for neu2xyz method. " ) self. data _ xy... | [
-0.3948826491832733,
-0.19638317823410034,
0.7842130064964294,
-1.186892032623291,
0.646947979927063,
-0.13583289086818695,
0.6348082423210144,
0.2598784267902374,
-0.28614315390586853,
-0.33528634905815125,
-0.12627771496772766,
0.20656387507915497,
-0.1448153406381607,
0.3019546568393707... |
def encode ( self, word, use _ dropout = false ) : if word not in self. word _ to _ idx : if self. unk is none : raise keyerror ( " { } not found ". format ( word ) ) word = self. unk # if use _ dropout and word! = self. unk : # drop _ prob = self. alpha / ( self. counts [ word ] + self. alpha ) # if np. random. random... | [
-0.5858344435691833,
0.4664009213447571,
0.5984359383583069,
-0.17729730904102325,
-0.4742814898490906,
0.9350887537002563,
0.9130792021751404,
-0.37072113156318665,
0.4878538250923157,
0.42956113815307617,
0.08107205480337143,
0.5276825428009033,
-1.0804513692855835,
0.47997960448265076,
... |
def evaluate _ constant ( expr, engine, context ) : if isinstance ( expr, expressions. constant ) : return expr. value context = context. create _ child _ context ( ) trap = utils. create _ marker ('trap') context ['$'] = trap @ specs. parameter ('name ', yaqltypes. stringconstant ( ) ) @ specs. name ('# get _ context ... | [
0.0626954436302185,
-0.23175758123397827,
0.7491323947906494,
-0.7089970707893372,
-0.4427821636199951,
-0.6715785264968872,
-0.3157352805137634,
0.08746504783630371,
0.2957756519317627,
0.3658159673213959,
-0.09067002683877945,
0.34796059131622314,
0.1759675294160843,
-0.6548629999160767,... |
def on _ test _ clicked ( self ) : # todo : not implemented yet global sdp _ ip, sdp _ port sdp _ ip = self. sdp _ ip. text ( ) sdp _ port = self. port. text ( ) global qam _ name _ list, qam _ address _ list, qam _ uid _ list qam _ name _ list = list ( ) qam _ address _ list = list ( ) qam _ uid _ list = list ( ) def ... | [
-0.08707859367132187,
-0.25664541125297546,
0.5765610933303833,
-0.4966459274291992,
-0.5828514099121094,
0.17868641018867493,
0.2969677448272705,
-1.0444831848144531,
0.4751177728176117,
-0.488718718290329,
-0.06936105340719223,
0.03789351508021355,
-0.22835879027843475,
0.348989129066467... |
def graph _ binomial _ convergence ( self, binomial _ dict ) : bs _ price = binomial _ model _ price binomial _ dict = { } for n in range ( 1, 26 ) : print ( n ) self. get _ new _ binomial _ model _ class ( self. american, self. call, self. stock _ price, self. k _ strike, self. t _ time, self. vol, self. rate, n, self... | [
-0.20901210606098175,
0.008417252451181412,
0.7599619030952454,
-0.05586308240890503,
-0.10820644348859787,
0.40951794385910034,
0.15714405477046967,
-0.17468330264091492,
-0.6010168790817261,
0.9135997891426086,
0.1009519100189209,
0.6505536437034607,
0.3228992521762848,
0.320311725139617... |
def save _ dateperiod ( self, data : dict, ) - > dateperiod : period = self. _ update _ or _ create _ object ( dateperiod, data ) try : time _ span _ groups _ data = data. pop ( " time _ span _ groups " ) except keyerror : time _ span _ groups _ data = [ ] # if data didn't change, the time span groups will be in db ord... | [
-0.8452367186546326,
0.36076289415359497,
0.8646203279495239,
-0.702811062335968,
0.0490449033677578,
0.9629181623458862,
0.4560030400753021,
-0.42917636036872864,
0.6935126781463623,
0.5503435730934143,
-0.7293137311935425,
-0.4322957992553711,
-0.36124640703201294,
0.4060250520706177,
... |
def create _ options ( self, args = none ) : self. optionparser = xsseroptions ( ) self. options = self. optionparser. get _ options ( args ) if not self. options : return false return self. options | [
-0.4092314541339874,
0.239392951130867,
0.35981693863868713,
-0.3768322467803955,
1.2351775169372559,
-0.47445380687713623,
-0.8377278447151184,
-0.48439788818359375,
-0.3804458975791931,
-0.3330720365047455,
-0.5701907277107239,
-0.9331303238868713,
-1.0326259136199951,
0.3386290371417999... |
def getmax ( liste ) : try : res = liste [ 0 ] for elem in liste : if elem > res : res = elem return res except typeerror : raise typeerror ( " the argument must be a list. " ) | [
-0.09284261614084244,
0.4002382755279541,
0.282664954662323,
1.2004770040512085,
0.7938717603683472,
0.4842595160007477,
-0.7060350179672241,
0.3191157281398773,
0.20056602358818054,
-0.09640505164861679,
-0.4722868502140045,
-0.32424357533454895,
-0.261231005191803,
0.6211960911750793,
... |
def reciprocal _ rank ( predicted _ rank _ vector, original _ rank _ vector, * * kwargs ) : ties _ handling = kwargs. setdefault ('ties ','ceiling') predicted _ rank _ vector = predicted _ rank _ vector. normalize ( ties = ties _ handling ) original _ rank _ vector = original _ rank _ vector. normalize ( ties = ties _ ... | [
-0.07564961165189743,
-0.9123916029930115,
0.7122554183006287,
0.020101409405469894,
-0.1874140501022339,
-0.6490901112556458,
-0.34217026829719543,
1.0998691320419312,
-0.4794604182243347,
-0.36017629504203796,
0.4082741141319275,
1.977240800857544,
-0.13366465270519257,
0.142180994153022... |
def _ generate _ maze ( self ) : net : networkx. graph = networkx. graph ( ) # initialize a grid of nodes, each connected to four neighbors for x in range ( self. shape [ 0 ] ) : for y in range ( self. shape [ 1 ] ) : place = ( x, y ) net. add _ node ( place ) for neighbor in self. _ neighbors ( place ) : # only edges ... | [
-0.45857036113739014,
0.0936296358704567,
0.9392778277397156,
0.3958478271961212,
-0.4149947464466095,
0.09483195841312408,
-0.020258046686649323,
0.13657259941101074,
-0.02063644491136074,
-0.10350681096315384,
0.24431322515010834,
-1.0565003156661987,
0.07235841453075409,
1.1065063476562... |
def _ perform _ evolution ( self ) : evolver = self. evolver verbosity = self. verbosity if verbosity > 0 : @ receiver ( applying _ evolution, sender = evolver ) def _ on _ applying _ evolution ( task, evolutions, * * kwargs ) : if verbosity > 2 : message = ( _ ('applying database evolutions for % ( app _ label ) s'' (... | [
0.12485592067241669,
0.8181027770042419,
0.8240325450897217,
0.4079263508319855,
0.8439549207687378,
-0.2820007801055908,
0.1708134114742279,
0.3053964376449585,
-0.3116225004196167,
0.1918555647134781,
-0.41747501492500305,
-0.20943869650363922,
0.8148259520530701,
1.4281409978866577,
-... |
def get _ addition _ score ( source _ counts, prediction _ counts, target _ counts ) : added _ to _ prediction _ counts = prediction _ counts - source _ counts true _ positives = sum ( ( added _ to _ prediction _ counts & target _ counts ). values ( ) ) selected = sum ( added _ to _ prediction _ counts. values ( ) ) # ... | [
0.16842810809612274,
-0.3104071617126465,
0.48523539304733276,
-0.3631865382194519,
0.18655569851398468,
-0.7160008549690247,
0.3231255114078522,
-0.8060625791549683,
-0.624563992023468,
-0.010441603139042854,
0.9039306640625,
0.4437231719493866,
0.631775975227356,
0.14932146668434143,
0... |
def transfer _ text ( ) : text _ file = open ( text _ path, " r " ) label _ file = open ( label _ path, " r " ) out _ file = open ( out _ path,'w') for text, label in zip ( text _ file, label _ file ) : text. strip ('\ t') text = text. replace ('\ n ','' ) text = text. replace ('= ','' ) label = label. replace ('\ n ',... | [
0.3921893537044525,
-0.683009922504425,
0.9449969530105591,
-0.5593688488006592,
-0.15399767458438873,
1.1335206031799316,
-0.07642669975757599,
0.7164826393127441,
-0.6683335304260254,
0.9306954145431519,
0.28037503361701965,
-0.005983162671327591,
0.07411601394414902,
0.06264520436525345... |
def get _ children ( self, asset _ key : assetkey ) - > abstractset [ assetkey ] : return self. _ asset _ dep _ graph [ " downstream " ] [ asset _ key ] | [
-0.032967183738946915,
0.6414868831634521,
0.5384416580200195,
-0.9068883061408997,
-0.47595706582069397,
0.08995013684034348,
0.6810265779495239,
-1.046328067779541,
-0.7487320899963379,
0.1039055660367012,
-0.14348076283931732,
0.7546510696411133,
0.7199581265449524,
-0.235892191529274,
... |
def sing _ me _ a _ song ( self ) : for line in self. lyrics : print ( line ) | [
0.5956331491470337,
-1.2670642137527466,
0.37411242723464966,
0.323294460773468,
0.03007037751376629,
0.5063365697860718,
-0.7379301190376282,
0.6594598889350891,
-1.3427568674087524,
-0.5380032658576965,
0.4526236057281494,
0.6083671450614929,
-0.1536926031112671,
0.9023532271385193,
-0... |
def get _ entity _ groups ( self, uuid, * * kwargs ) : return self. request ( f'entities / { uuid } / groups ', * * kwargs ) | [
-1.6473166942596436,
0.9295639991760254,
0.11650924384593964,
-0.21779289841651917,
0.42156532406806946,
-0.6537437438964844,
-0.8488213419914246,
-0.35000601410865784,
-0.6725785136222839,
0.10943464934825897,
0.30934569239616394,
0.703944981098175,
-0.6718667149543762,
0.3866088390350342... |
def verticalintervals ( first, second ) : pairs = zip ( first, second ) return [ pair [ 0 ] - pair [ 1 ] for pair in pairs if pair [ 0 ]! = none and pair [ 1 ]! = none ] | [
0.25882700085639954,
-0.7620360851287842,
0.6196974515914917,
0.727586030960083,
0.18130053579807281,
-0.3462376892566681,
-0.8916228413581848,
-0.5386273860931396,
-0.8430773019790649,
1.0999579429626465,
-1.255850911140442,
0.5463572144508362,
-0.6438680291175842,
0.18489664793014526,
... |
def winbio _ winbiogetcredentialstate ( jitter ) : ret _ ad, args = jitter. func _ args _ stdcall ( [ " identity ", " type ", " credentialstate " ] ) raise runtimeerror ('api not implemented') jitter. func _ ret _ stdcall ( ret _ ad, ret _ value ) | [
-0.14334620535373688,
-0.5919070839881897,
0.36887165904045105,
0.9180362820625305,
-0.20236368477344513,
0.34023985266685486,
0.5505146384239197,
-0.3223269581794739,
0.13113032281398773,
0.236581951379776,
-0.33588558435440063,
0.21479210257530212,
-1.3621691465377808,
0.470724880695343,... |
def _ get _ collection _ folders ( self, page _ idx ) : return self. _ api ( " / collections / folders ", get _ data = { " username " : self. user, " offset " : page _ idx * daexplorer. max _ items _ per _ request, " limit " : daexplorer. max _ items _ per _ request, " mature _ content " : true } ) | [
-1.442541241645813,
0.455735981464386,
0.5139227509498596,
0.22370930016040802,
0.5479207038879395,
0.16702762246131897,
-0.3229891061782837,
-1.2793117761611938,
0.006159569136798382,
-0.6643585562705994,
0.19729718565940857,
-0.2529894709587097,
-0.09222991019487381,
0.042988456785678864... |
def create _ shortcut ( source, destination, workdir = none, args = none, tooltip = none, iconpath = none, iconindex = 0 ) : if not os. path. exists ( source ) : raise runtimeerror ( " missing source for shortcur link : % s " % source ) if not destination. endswith ( ". lnk " ) : raise runtimeerror ( " malformed shortc... | [
-0.5361505746841431,
0.46213123202323914,
0.5184887647628784,
0.12684950232505798,
0.17508353292942047,
-0.10137715935707092,
1.0339710712432861,
-0.11608360707759857,
0.21575739979743958,
-0.2521653473377228,
-0.028170976787805557,
-0.1293289214372635,
0.6604003310203552,
-0.3262907862663... |
def add _ edge ( self, u, v, group = none, omap = none, tmap = none, * * kwargs ) : if not hasattr ( group,'gens') : edgegroup = fpgroup ( ) # the trivial group elif group. gens = = [ ] : edgegroup = group # still the trivial group else : # if the edge group is nontrivial the inclusion maps can not be trivial edgegroup... | [
-1.6476770639419556,
0.7651365995407104,
0.8250159025192261,
0.01295254472643137,
-0.609246015548706,
-0.19187654554843903,
0.22488148510456085,
0.676741898059845,
0.17809364199638367,
0.05253598093986511,
-0.058148372918367386,
-0.03730430454015732,
-1.036693811416626,
0.6225659847259521,... |
def finish _ signature ( self ) : self. starting _ group = false self. starting _ single = false | [
-0.9243751764297485,
-0.7334960699081421,
0.2562756836414337,
0.18609589338302612,
0.2753024399280548,
0.5868176817893982,
1.4084821939468384,
0.6158546209335327,
-1.5867198705673218,
0.9593321084976196,
-1.4942233562469482,
-0.2510928213596344,
-0.6658793091773987,
0.7073588371276855,
0... |
def winbio _ winbioasyncenumbiometricunits ( jitter ) : ret _ ad, args = jitter. func _ args _ stdcall ( [ " frameworkhandle ", " factor " ] ) raise runtimeerror ('api not implemented') jitter. func _ ret _ stdcall ( ret _ ad, ret _ value ) | [
-0.2165534496307373,
0.48081666231155396,
0.24084419012069702,
0.4788133502006531,
1.0580134391784668,
0.9526848196983337,
0.9926612377166748,
-0.9393548965454102,
-0.3971673250198364,
-0.217604860663414,
0.00508486945182085,
0.22574476897716522,
-1.4899089336395264,
0.9963365793228149,
... |
def test _ cant _ update _ branch _ invalid _ requests ( self ) : res = self. client. post ('/ branch / update') self. assertequal ( res. status _ code, 405 ) res = self. client. delete ('/ branch / update') self. assertequal ( res. status _ code, 405 ) res = self. client. put ('/ branch / update') self. assertequal ( ... | [
-0.29479309916496277,
0.03947393596172333,
0.8723559975624084,
0.9816406965255737,
0.078241266310215,
1.2998161315917969,
-0.1824810653924942,
0.016919922083616257,
-0.3023929297924042,
-0.37158140540122986,
-0.1394800841808319,
-0.0654178112745285,
-0.6987172365188599,
0.4910265803337097,... |
def taf ( bot, event, * args ) : code =''. join ( args ). strip ( ) if not code : yield from bot. coro _ send _ message ( event. conv _ id, " you need to enter the icao airport code you wish the look up, https : / / en. wikipedia. org / wiki / international _ civil _ aviation _ organization _ airport _ code. " ) return... | [
0.12423216551542282,
0.44028475880622864,
0.46007928252220154,
-0.461708128452301,
0.8252989649772644,
-0.11023206263780594,
0.4892127811908722,
0.14218494296073914,
-0.15591385960578918,
0.32218137383461,
0.0973082035779953,
-0.0738309770822525,
-0.3497711718082428,
-0.624907910823822,
... |
def _ test _ neg _ metagraph _ merge ( ) : from wbia. algo. graph import demo from wbia. algo. graph. state import incmp, negtv, postv, unkwn, unrev # noqa # create a graph with 4 ccs, with 3 - pos - redun, and no negative edges infr = demo. demodata _ infr ( num _ pccs = 4, pcc _ size = 5, pos _ redun = 3, ignore _ pa... | [
-0.0985514298081398,
0.3387853801250458,
0.8367549777030945,
-0.34238672256469727,
-0.10131616145372391,
0.5743943452835083,
-0.22937346994876862,
-0.06462019681930542,
0.45038390159606934,
0.04682715982198715,
-0.03700881823897362,
-0.5321720838546753,
-0.8456525206565857,
-0.246361702680... |
def vardecdetector ( pentadlist = none, debugmode = false ) : presentchar ='a'firstchar ='a'secondchar ='a'thirdchar ='a'fourthchar ='a'variablename = " " sequencestartline = 0 state = " waiting for int " for i in range ( len ( pentadlist ) ) : pentadlist [ i ]. text = spacerforconditions ( pentadlist [ i ]. text ) pen... | [
0.34117719531059265,
-0.9045922756195068,
0.8893565535545349,
-0.2723276615142822,
-0.487083375453949,
-0.6279812455177307,
-0.1742539256811142,
-0.2175896018743515,
-0.6031254529953003,
-0.18211792409420013,
-0.5105472207069397,
0.34002241492271423,
-0.07977503538131714,
0.760961771011352... |
def unique ( array ) : # numpy. unique doesn't handle mixed - types on python3, # so we use pandas array = np. asarray ( array ) i, u = pd. factorize ( array. ravel ( ), sort = true ) return u. astype ( array. dtype ), i. reshape ( array. shape ) | [
-0.11069809645414352,
-0.03309110924601555,
0.5474552512168884,
-0.08744475245475769,
0.08637574315071106,
-0.2546907663345337,
0.6003431081771851,
0.1271737515926361,
1.2134495973587036,
0.39297714829444885,
-0.5674594640731812,
0.4852968454360962,
0.3517594635486603,
-0.3928004503250122,... |
def clear ( self ) : self. _ map. clear ( ) | [
-0.3506351113319397,
-0.7997837066650391,
0.11274407804012299,
-0.5659571886062622,
-0.4100334346294403,
1.046684980392456,
-0.10063797980546951,
-0.4055119454860687,
0.027203844860196114,
-0.5665324926376343,
0.11896523088216782,
1.20128333568573,
0.6394913792610168,
0.4752700626850128,
... |
def draw ( canvas ) : # card position pos = ( 0, 0 ) # display cards for card _ index in range ( deck _ size ) : card = deck [ card _ index ] if exposed [ card _ index ] : # exposed card canvas. draw _ text ( str ( card ), ( pos [ 0 ] + text _ displacement [ 0 ], pos [ 1 ] + text _ displacement [ 1 ] ), 40,'white') els... | [
0.40098458528518677,
-0.1759253442287445,
0.9585143327713013,
-1.7942159175872803,
-0.45143207907676697,
0.5995899438858032,
-0.6614615321159363,
-0.057044461369514465,
0.24582146108150482,
0.290612131357193,
-0.1970209777355194,
0.13463272154331207,
0.6392337679862976,
-0.2122597396373748... |
def faq ( ) : return render _ template ('faq. html ', page ='faq') | [
0.7935774326324463,
0.5319342017173767,
0.4893570840358734,
1.3046995401382446,
-0.017322726547718048,
0.2323814034461975,
0.24957175552845,
1.0003867149353027,
-0.3717343211174011,
0.010314124636352062,
0.36258819699287415,
-1.151617169380188,
-0.10153260082006454,
0.4414576590061188,
-... |
def settriggerinvert ( mode ) : return none | [
-0.8957043290138245,
0.1818591207265854,
0.4276595413684845,
0.20067816972732544,
0.680583655834198,
0.47493958473205566,
0.6112756133079529,
0.8079456686973572,
-0.6869150996208191,
-0.4334298074245453,
-1.986393928527832,
-0.6788566708564758,
-1.267993450164795,
-1.222398042678833,
-0.... |
def writetfidfresultstofile ( self, results, pathtofile ) : path = pathtofile. rsplit ('/ ', 1 ) [ 0 ] if not os. path. exists ( path ) : # check whether the directory exists or not os. makedirs ( path ) with open ( pathtofile,'w') as output : for k, v in results. items ( ) : if len ( v ) = = 0 : output. write ('{ : < ... | [
-0.1422019600868225,
-0.27420908212661743,
0.7593410611152649,
-0.43481653928756714,
1.3818206787109375,
-0.18730765581130981,
0.5378975868225098,
-0.27615517377853394,
-0.5575525760650635,
-0.1041555181145668,
-0.1745908558368683,
-0.8464072346687317,
0.010037317872047424,
0.3922996520996... |
def idtopoint ( dim, id ) : idlong = multihash. parsehash ( id ) return tuple ( [ idlong, 0 ] ) | [
-0.5821683406829834,
-0.5745211839675903,
0.14250992238521576,
-0.05487874895334244,
-0.15531711280345917,
-0.5354232788085938,
-1.2170941829681396,
0.5812684893608093,
0.31614160537719727,
1.2700923681259155,
-0.7695210576057434,
-0.5254986882209778,
-0.1029173955321312,
-0.46883851289749... |
def jinc _ goodman ( rho, normalize = true ) : ji = jinc ( 2. 0 * _ math. pi * rho, true ) if normalize : return ji else : return ji * _ math. pi | [
0.34965160489082336,
-0.16497626900672913,
0.40610378980636597,
0.311424195766449,
-1.3192099332809448,
-0.5191459655761719,
0.37604913115501404,
-0.6579890847206116,
-0.1851770579814911,
0.24724948406219482,
0.2836625874042511,
0.2697784900665283,
-0.8937931656837463,
0.38977479934692383,... |
def start ( self ) : if callable ( self. _ _ on _ start ) : return self. _ _ on _ start ( ) | [
0.5129241347312927,
-0.4569098949432373,
0.5425261855125427,
1.0722583532333374,
-0.13287706673145294,
-0.850750207901001,
-0.015895025804638863,
-0.3762836456298828,
0.49444687366485596,
-0.33060476183891296,
-0.45778509974479675,
0.25606149435043335,
-0.004860767163336277,
0.759163498878... |
def _ _ init _ _ ( self, src _ entity : mapping [ str, any ] = none, * * kwargs ) : self. recipient : optional [ str ] = none self. files : list [ entity ] = [ ] self. urls : list [ str ] = [ ] self. threats : list [ str ] = [ ] self. sender : optional [ str ] = none self. p1sender : optional [ str ] = none self. p1sen... | [
0.40570068359375,
-0.370222806930542,
0.8068331480026245,
0.043147459626197815,
-0.0703275203704834,
0.07551639527082443,
-0.6445490121841431,
0.013399193994700909,
0.4607320725917816,
0.11023260653018951,
-1.4024388790130615,
-0.18483373522758484,
-0.27852389216423035,
0.867232084274292,
... |
def from _ string ( cls : type [ this ], t : str ) - > this :... | [
-0.002984323538839817,
-1.2656000852584839,
0.2081831693649292,
-0.22086136043071747,
-0.19324596226215363,
0.2588375210762024,
-0.3069661259651184,
-0.3922753930091858,
-0.13578975200653076,
-0.024447498843073845,
-1.2733254432678223,
0.7268301248550415,
0.5933213233947754,
-1.28354263305... |
def get _ job _ id _ tuple _ from _ batchid ( batchid ) : batchid _ str _ list = str ( batchid ). split ( '.') clusterid = batchid _ str _ list [ 0 ] procid = batchid _ str _ list [ 1 ] if not procid : procid = 0 return ( clusterid, procid ) | [
-0.1354701966047287,
-0.8892180323600769,
0.5852070450782776,
-0.11745291948318481,
-0.004500871524214745,
0.15690018236637115,
-0.5815101861953735,
0.03825906664133072,
-0.5033690333366394,
0.3141327500343323,
0.0518808476626873,
0.7512219548225403,
-0.607265293598175,
-0.2024139165878296... |
def eval ( self, src, mesh, time _ mesh, f ) : # noqa : a003 if self. projfield in f. aliasfields : return super ( pointmagneticfluxtimederivative, self ). eval ( src, mesh, time _ mesh, f ) p = self. getp ( mesh, time _ mesh, f ) f _ part = mkvc ( f [ src, " b ", : ] ) return p * f _ part | [
0.6007770895957947,
0.9259981513023376,
0.40071946382522583,
0.3002960681915283,
-0.0019783820025622845,
0.601889431476593,
-0.543912410736084,
0.5182148814201355,
-0.6617817282676697,
0.24642686545848846,
0.15872637927532196,
-0.5096032619476318,
0.0024413377977907658,
0.37708917260169983... |
def new _ result ( self, job ) : configuration, budget, loss = self. extract _ configuration ( job ) self. add _ configuration ( configuration = configuration, budget = budget, loss = loss ) # if we already have a model for a higher budget we will not use information from this run # we assume that models with higher bu... | [
-0.16083276271820068,
0.11133994162082672,
0.596930742263794,
0.9928106069564819,
-0.10134273767471313,
-0.4047222435474396,
-0.30498889088630676,
-0.47540009021759033,
0.020481713116168976,
0.22769559919834137,
-0.48616132140159607,
-0.6514167189598083,
-0.0023454539477825165,
0.543831408... |
def translate _ request ( req ) : internal = { } internal [ " reqid " ] = req [ " reqid " ] internal [ " callback " ] = req [ " callback " ] # nfvi nfvi = { } nfvi [ " hosts " ] = [ ] nfvi [ " host _ edges " ] = [ ] nfvi [ " costs " ] = [ ] if " resource _ types " not in req [ " nfvi " ] : nfvi [ " resource _ types " ]... | [
-1.1633912324905396,
-0.0718112587928772,
0.6879013776779175,
-0.6178543567657471,
-0.5719538331031799,
-0.7361960411071777,
-0.447540283203125,
-0.4340232312679291,
-0.29206177592277527,
-0.1515498161315918,
0.3817861080169678,
-0.30226820707321167,
-0.15260082483291626,
0.691934108734130... |
def test _ mutual _ info _ score _ functional _ single _ cluster ( ) : tensor _ a = torch. randint ( num _ classes, ( batch _ size, ) ) tensor _ b = torch. zeros ( batch _ size, dtype = torch. int ) assert torch. allclose ( mutual _ info _ score ( tensor _ a, tensor _ b ), torch. tensor ( 0. 0 ) ) assert torch. allclos... | [
-0.2902384400367737,
-0.2833465337753296,
0.4200051426887512,
0.7665504217147827,
1.3981893062591553,
0.3146839141845703,
0.35202711820602417,
-0.1969527304172516,
-0.2302236258983612,
-0.8893842101097107,
0.17738090455532074,
0.019605673849582672,
0.2500319182872772,
-0.3689463436603546,
... |
def check _ positive ( self, curl _ handle, dest _ url, payload, attack _ vector ) : body = curl _ handle. body ( ) # should check ongoing _ attacks here # perform extra checks pass | [
-0.257663756608963,
-1.1412302255630493,
0.4014216959476471,
0.6981530785560608,
-0.05679435282945633,
0.5781773924827576,
-0.5084050297737122,
-0.2095956951379776,
-0.6861175298690796,
-0.16326308250427246,
0.5485840439796448,
-0.3142361044883728,
-0.08508393913507462,
-0.91620272397995,
... |
def _ _ init _ _ ( self, config ) : self. reset _ stats ( ) self. config = config | [
0.7654971480369568,
-0.08845444768667221,
0.2379189133644104,
0.14993655681610107,
0.06108131259679794,
0.2448541224002838,
0.6308432221412659,
0.2720191776752472,
0.5894683003425598,
0.15612497925758362,
-0.8526347875595093,
-0.138363778591156,
0.2825252413749695,
0.8389536738395691,
0.... |
def download _ document ( self, file _ id ) : self. logger. debug ( f " finding file with id { file _ id } " ) response = requests. get ( f " { self. telegram _ api } " f " / bot " f " { self. bot _ token } " f " / getfile? file _ id = " f " { file _ id } " ) url _ filepath = response. json ( ) [ " result " ] [ " file ... | [
-0.03397098183631897,
-0.7822449207305908,
0.6232728362083435,
-0.5874367356300354,
-0.1718791425228119,
0.018782896921038628,
0.29974839091300964,
-0.2338215559720993,
-0.5769926309585571,
0.2221941202878952,
-0.16549284756183624,
-0.5244094729423523,
-0.8350116610527039,
1.10988926887512... |
def index _ from _ mask ( structure, mask, amber _ index = false ) : if amber _ index : index _ offset = 1 else : index _ offset = 0 if isinstance ( structure, str ) : structure = return _ parmed _ structure ( structure ) elif isinstance ( structure, parmedstructureclass ) : pass else : raise exception ( " index _ from... | [
-0.4988947808742523,
-0.9401981830596924,
0.31882497668266296,
-0.28058093786239624,
0.07442736625671387,
-0.19149960577487946,
0.2865956127643585,
-0.2537573575973511,
0.9506446719169617,
0.3332351744174957,
0.008168589323759079,
0.5115417838096619,
-0.009464617818593979,
-0.7032994031906... |
def _ choose ( scores, scores _ se ) : # get the index of the best score if w _ pen _ is _ iterable : indx = _ which ( scores, scores _ se, choice ) return v _ pen, w _ pen [ indx ], scores [ indx ], indx if v _ pen _ is _ iterable : indx = _ which ( scores, scores _ se, choice ) return v _ pen [ indx ], w _ pen, score... | [
-0.6407110691070557,
-0.5449145436286926,
0.5683572888374329,
0.06241558492183685,
0.3821953535079956,
-0.6829079985618591,
0.7142919898033142,
-0.8756737112998962,
0.05540984869003296,
0.811260998249054,
0.3838265836238861,
0.5422951579093933,
-0.035409990698099136,
-0.8999868631362915,
... |
def get _ probs ( self ) : return self. card _ probs. values ( ) | [
0.09431026875972748,
-0.5398147106170654,
0.379990816116333,
0.501826286315918,
0.45450180768966675,
0.10234296321868896,
-1.7736097574234009,
0.18503984808921814,
-0.5274876356124878,
-0.2658691704273224,
-0.35874709486961365,
-0.013904338702559471,
-0.2296765297651291,
-0.127371937036514... |
def embedded ( self ) : return self. embedded _ groups + [ self. embedded _ overview ] | [
-0.014340827241539955,
-0.4430760443210602,
0.39428937435150146,
0.04151468351483345,
-0.17574845254421234,
1.6976878643035889,
-0.24703721702098846,
-0.3101242184638977,
0.641697883605957,
-0.3990633487701416,
0.4182012975215912,
0.3622625470161438,
-0.28276634216308594,
0.111369743943214... |
def transform _ values _ into _ list ( self ) : for key in self. data. keys ( ) : if isinstance ( self. data [ key ], list ) : continue self. data [ key ] = [ self. data [ key ] ] | [
-0.41714414954185486,
-0.013898862525820732,
0.43364742398262024,
-0.8029160499572754,
0.5274609327316284,
0.07356394827365875,
-0.9736660122871399,
1.0232521295547485,
0.4136674106121063,
0.3927196264266968,
-0.856749415397644,
0.5443902611732483,
0.0036956954281777143,
1.5122358798980713... |
def validate _ choices ( self, responses, field = none ) : if field is none : return for choice in responses : if choice not in field : raise rfx. invalidchoice ( ) | [
0.0994434580206871,
-0.37094196677207947,
0.33694741129875183,
0.5533484220504761,
0.7928876280784607,
0.6644690632820129,
-0.27621516585350037,
-0.5021631121635437,
0.5018457770347595,
-0.22230032086372375,
0.3322280943393707,
-0.6956270337104797,
-0.5427340865135193,
0.6581915020942688,
... |
def layer _ sizes ( self ) : sizes = [ ] weights = self. weights ( ) for i in range ( len ( weights ) ) : sizes. append ( weights [ i ]. shape [ 1 ] ) sizes. append ( weights [ - 1 ]. shape [ 0 ] ) return sizes | [
-0.5076729655265808,
0.18642736971378326,
0.7165320515632629,
-0.2512337565422058,
1.2098897695541382,
-0.029735645279288292,
0.23747877776622772,
-0.35444605350494385,
-0.3188840448856354,
0.5588199496269226,
-0.5736948847770691,
0.2082073837518692,
-0.710270345211029,
1.5250468254089355,... |
def constant _ ptr ( value : int ) - >'possiblevalueset': result = possiblevalueset ( ) result. _ type = registervaluetype. constantpointervalue result. _ value = value return result | [
0.02492809109389782,
0.0770396962761879,
0.38672584295272827,
-0.5441051721572876,
-0.6535225510597229,
0.10244319587945938,
0.45597460865974426,
-0.5851390361785889,
0.7471136450767517,
-0.12301132082939148,
0.6723814606666565,
0.0497291125357151,
-0.924328625202179,
0.1938161998987198,
... |
def ram _ role _ name ( self ) - > pulumi. output [ optional [ str ] ] : return pulumi. get ( self, " ram _ role _ name " ) | [
1.0604074001312256,
-0.5758944153785706,
0.3404558300971985,
0.15244923532009125,
-0.13052964210510254,
0.7010891437530518,
-0.31626251339912415,
-0.007044888101518154,
0.4672934412956238,
0.575936496257782,
-0.033491555601358414,
0.8379451632499695,
-0.18959486484527588,
-0.77674436569213... |
def callback ( _ locals, _ globals ) : global n _ steps, best _ mean _ reward # print stats every 1000 calls if ( n _ steps + 1 ) % 10 = = 0 : x, y = ts2xy ( load _ results ( log _ dir ),'timesteps') if len ( x ) > 100 : # pdb. set _ trace ( ) mean _ reward = np. mean ( y [ - 100 : ] ) print ( x [ - 1 ],'timesteps') pr... | [
-0.3570614755153656,
0.16006958484649658,
0.7072790265083313,
-0.04884611815214157,
0.9105294942855835,
0.15990428626537323,
-0.3667411804199219,
-0.19780100882053375,
0.11505214869976044,
0.3259589970111847,
-0.5931404232978821,
-0.19871558248996735,
0.6297056078910828,
0.6976462006568909... |
def split ( sig, idx ) : syl = [ ] for j, i in enumerate ( idx ) : if i = = idx [ 0 ] : this _ syl = sig [ : i ] elif i = = idx [ - 1 ] : this _ syl = sig [ i : ] else : this _ syl = sig [ i : idx [ j + 1 ] ] this _ syl [ :, 0 ] - = this _ syl [ 0, 0 ] syl. append ( this _ syl ) return syl | [
-0.7422064542770386,
0.04372337833046913,
0.4802788197994232,
-0.046462275087833405,
0.14946888387203217,
-0.6961207985877991,
0.5131779313087463,
-0.5726782083511353,
0.9719499945640564,
0.5581949353218079,
-1.4390982389450073,
-0.05918794870376587,
-0.45003175735473633,
-0.01535163447260... |
def add _ inputs _ and _ parameters ( self, arguments : list [ str ] ) : position = 0 prefix : optional [ str ] = none output _ streams = { getattr ( self, stream _ name ) for stream _ name in ( " stdout ", " stderr " ) } for index, argument in enumerate ( arguments ) : if prefix : if argument. startswith ( " - " ) : p... | [
-0.9575919508934021,
-0.6052423119544983,
0.6960565447807312,
0.32486069202423096,
1.1909866333007812,
-0.0704178512096405,
0.3886549472808838,
-0.5842681527137756,
-0.19984757900238037,
0.16584332287311554,
0.3977094292640686,
0.5511753559112549,
-0.34950029850006104,
1.394092082977295,
... |
def read _ cplx _ samples ( self ) - > tuple [ np. array, float ] : # receive all samples index = 0 wait = 10 rx _ time = 0 while index < self. _ output _ size : # readstream ( ) doesn't seem to be a blocking call read = self. _ sdr. readstream ( self. _ rx _ stream, [ self. _ tmp ], self. _ tmp _ size, timeoutus = 100... | [
-0.4313317537307739,
-0.8112918138504028,
1.0772619247436523,
-0.17112618684768677,
-0.33263564109802246,
-0.381267786026001,
0.7092583179473877,
-0.3244687616825104,
0.582544207572937,
-0.3285388648509979,
0.47128134965896606,
-0.38231298327445984,
-0.6069795489311218,
0.21245218813419342... |
def extract _ pools ( config ) : commands = parse _ f5 _ config ( config ) pools = { } for cmd in commands : if cmd [ 0 ] = ='pool': pool _ name = cmd [ 1 ] parts = cmd [ 2 ] for p in parts : if p [ 0 ] = ='members': if len ( p ) = = 2 : # a pool with a list of members pools [ pool _ name ] = [ clean ( m [ 0 ] ) for m ... | [
-0.5009325742721558,
-0.10825768113136292,
0.4606073498725891,
-0.2565193176269531,
-0.816250741481781,
-0.008019695989787579,
1.0439598560333252,
-0.18373118340969086,
-0.3630225658416748,
0.3964935541152954,
-1.3959228992462158,
-0.1831759214401245,
-0.10468346625566483,
0.56391006708145... |
def base _ pay ( self ) : return self. gross _ pay - self. bonuses - self. reimbursements - self. overtime | [
0.5158897638320923,
-0.6099662184715271,
0.3996203541755676,
-0.3462197184562683,
0.2521429657936096,
0.8260543942451477,
0.028225068002939224,
-0.3476867079734802,
-0.307044118642807,
0.3283393383026123,
0.17600885033607483,
0.13689056038856506,
-0.9818108677864075,
-0.6522777080535889,
... |
def er ( radius, length ) : ddd = 0. 75 * radius * ( 2 * radius * length + ( length + radius ) * ( length + pi * radius ) ) return 0. 5 * ( ddd ) * * ( 1. / 3. ) | [
-0.2800404131412506,
0.16620860993862152,
0.44568532705307007,
-1.0747324228286743,
-0.5332221388816833,
0.48239296674728394,
-0.4728279113769531,
0.17461882531642914,
0.004040196537971497,
0.057916007936000824,
0.027145355939865112,
0.8452736735343933,
-0.8086795806884766,
-0.373610079288... |
def solve ( query, vars ) : _ = query, vars raise notimplementederror ( ) | [
-0.8492811322212219,
0.12237443029880524,
0.2415095567703247,
-0.03970002010464668,
0.001081337919458747,
-0.05107289180159569,
-0.49927952885627747,
-0.07705234736204147,
-0.21029514074325562,
-0.42203450202941895,
-0.34711161255836487,
-0.007016339339315891,
-0.11484172195196152,
-0.0579... |
def userdata ( self ) - > pulumi. output [ str ] : warnings. warn ( " " " field'userdata'has been deprecated from provider version 1. 120. 0. new field'user _ data'instead. " " ", deprecationwarning ) pulumi. log. warn ( " " " userdata is deprecated : field'userdata'has been deprecated from provider version 1. 120. 0. ... | [
-0.25185105204582214,
0.45445308089256287,
0.5236603617668152,
-0.19728833436965942,
-0.48578956723213196,
0.33002737164497375,
-0.42853105068206787,
-0.00237325020134449,
0.24672484397888184,
0.10373660176992416,
-0.31617408990859985,
0.6927213072776794,
0.6860707998275757,
-1.01032054424... |
def min _ file _ size _ bytes ( self, min _ file _ size _ bytes ) : if ( self. _ configuration. client _ side _ validation and min _ file _ size _ bytes is not none and min _ file _ size _ bytes < 0 ) : # noqa : e501 raise valueerror ( " invalid value for ` min _ file _ size _ bytes `, must be a value greater than or e... | [
-0.009897295385599136,
-0.2840873599052429,
-0.4696594178676605,
0.3803565204143524,
0.05003885552287102,
0.6387537717819214,
-0.31682735681533813,
0.13238781690597534,
-0.4115279018878937,
-0.9267563223838806,
-0.47865554690361023,
-0.2368135154247284,
-1.162853717803955,
0.32618108391761... |
def test _ repr ( self ) : mapper = attributetypemapper ( create _ group ( ) ) mapper [ " x " ] = 1 mapper [ " y " ] = { " a " : " b " } assert repr ( mapper ) = = repr ( { " x " : datasetscalar ( 1 ), " y " : { " a " : " b " } } ) | [
-1.0633823871612549,
0.13480401039123535,
0.29899081587791443,
-1.1648778915405273,
-1.2559874057769775,
0.6459399461746216,
-0.3963050842285156,
-0.5945255160331726,
0.20987319946289062,
-0.03168082609772682,
0.08097918331623077,
0.5435440540313721,
0.8735499978065491,
-0.3812079131603241... |
def finalize ( self ) : return uri. urireference ( self. scheme, normalizers. normalize _ authority ( ( self. userinfo, self. host, self. port ) ), self. path, self. query, self. fragment, ) | [
-0.47382479906082153,
-0.1474839299917221,
0.45057475566864014,
-0.5615707635879517,
0.009263544343411922,
0.15224961936473846,
0.5672256946563721,
0.6011786460876465,
-0.3724908232688904,
-1.1158530712127686,
0.8071222901344299,
-0.013226447626948357,
-0.9263536334037781,
-0.5112262368202... |
def order _ view ( request, pk ) : customer = customer. objects. get ( id = pk ) requirement = requirement. objects. filter ( customer _ id = customer. id ). first ( ) # set context. # leads, sales _ people, roof _ types, storeys, electric _ powers, payments, installers are default options loaded in django admin # requ... | [
0.0664309710264206,
-0.004075112286955118,
1.0405197143554688,
-0.007576228119432926,
-0.4513457119464874,
-0.15284286439418793,
0.24824051558971405,
0.001995756523683667,
0.28420865535736084,
0.4138635993003845,
0.359671950340271,
-0.004847485572099686,
0.30957016348838806,
1.243769049644... |
def segment _ words ( path ) : files = [ f for f in os. listdir ( path ) if os. path. isfile ( os. path. join ( path, f ) ) ] image = cv2. imread ( os. path. join ( path, files [ 0 ] ) ) directory _ name = path + " / " + files [ 0 ] [ : - 4 ] if os. path. exists ( directory _ name ) : shutil. rmtree ( directory _ name ... | [
0.2960047721862793,
-0.09834964573383331,
1.0495593547821045,
-0.2752681374549866,
0.2635732591152191,
0.009165814146399498,
1.0927925109863281,
-0.0013268935726955533,
0.5749865770339966,
1.0526111125946045,
-0.26316943764686584,
-0.013580217957496643,
-0.4632783830165863,
0.9062100648880... |
def cpu4 _ output ( self, cpu4 _ mem ) : return sigmoid ( cpu4 _ mem, self. cpu4 _ slope, self. cpu4 _ bias ) | [
0.36221081018447876,
-0.3138536512851715,
0.14779072999954224,
0.2564915716648102,
-1.0081466436386108,
-0.23059415817260742,
0.9264304041862488,
-0.3778555989265442,
-0.3605889678001404,
0.06756216287612915,
-0.2675934433937073,
-0.07854083925485611,
-1.595874309539795,
-0.705749750137329... |
def scan _ darwin _ java ( scan, options ) : i = 0 for plist in glob ( " / library / java / javavirtualmachines / * / contents / info. plist " ) : i = i + 1 scan. add _ file ( plist, " java / java _ " + str ( i ) + ". plist " ) | [
-1.0279136896133423,
0.0070722997188568115,
0.4926317632198334,
0.3303475081920624,
0.15382346510887146,
0.45228075981140137,
0.6852234601974487,
-0.21497395634651184,
0.036603186279535294,
0.19442002475261688,
-0.7085711359977722,
-0.9105728268623352,
0.33052554726600647,
0.88792610168457... |
def is _ back _ online ( self ) : return self. _ back _ online | [
0.11035332828760147,
-1.0730563402175903,
0.7566387057304382,
1.128724455833435,
0.6740350127220154,
0.3454049527645111,
-0.497456818819046,
0.3076118230819702,
-0.34024059772491455,
0.8648812770843506,
-0.7420259118080139,
0.5564913153648376,
-1.1872111558914185,
-1.5486093759536743,
-1... |
def _ transform _ training _ data ( self, x _ raw, y _ raw, max _ len _ of _ sentence = none, max _ num _ of _ setnence = none ) : unknown _ value = self. char _ indices [ self. unknown _ label ] x = np. ones ( ( len ( x _ raw ), max _ num _ of _ setnence, max _ len _ of _ sentence ), dtype = np. int64 ) * unknown _ va... | [
-0.8430342078208923,
0.0284441951662302,
0.9295313954353333,
-0.9416741132736206,
-0.2796345353126526,
-0.7443893551826477,
0.1309676170349121,
0.5450929999351501,
-0.23299363255500793,
0.4730807840824127,
-0.2978919744491577,
0.667145848274231,
0.41510286927223206,
-0.6252782940864563,
... |
def check _ valid _ curr ( self, curr ) : try : if ( len ( curr ) = = 3 ) : return true else : return false # how to test for except? except : print ( " currency is not 3 chars long " ) | [
0.10989590734243393,
0.26731961965560913,
0.6757882833480835,
0.022374479100108147,
-1.2255408763885498,
1.558990240097046,
-0.35457172989845276,
0.41839849948883057,
0.4337073266506195,
0.533257007598877,
-0.08822806179523468,
-0.2643525302410126,
-1.2611784934997559,
-0.36435770988464355... |
def rseq ( t, y, en, veff ) : y1, y2 = y y1d = y2 # compare with eq. ( 11 ) from problem sheet 5 and eq. ( 3 ) from problem sheet 4 f = - 2 * ( en - veff ( t ) ) y2d = f * y1 return [ y1d, y2d ] | [
-0.7277447581291199,
-0.607463538646698,
0.32173848152160645,
0.022572800517082214,
0.23600828647613525,
-0.03894679993391037,
0.03906748443841934,
-0.15993735194206238,
-0.7779955863952637,
0.9914183616638184,
-1.2244197130203247,
-0.17780975997447968,
0.4546390771865845,
0.62050527334213... |
def options ( self, options ) : self. _ options = options | [
-0.3032388687133789,
0.186685249209404,
-0.10651980340480804,
0.08454568684101105,
0.8500012159347534,
0.4147810935974121,
0.23876221477985382,
-0.15480856597423553,
0.051604263484478,
-0.5607817769050598,
-0.6049898862838745,
-0.5809515118598938,
-0.2702966332435608,
0.38221630454063416,
... |
def auto _ delete _ file _ on _ delete ( sender, instance, * * kwargs ) : if instance. image : if os. path. isfile ( instance. image. path ) : os. remove ( instance. image. path ) | [
0.9824355244636536,
-1.2619723081588745,
0.6090348362922668,
0.3777913451194763,
0.3001236319541931,
0.0116224754601717,
0.9795037508010864,
0.4432738125324249,
-0.10163400322198868,
-0.25212666392326355,
0.24522994458675385,
-0.1428222358226776,
0.9084447026252747,
0.8141427636146545,
-... |
def rot6d _ to _ rotmat ( x ) : x = x. view ( - 1, 3, 2 ) a1 = x [ :, :, 0 ] a2 = x [ :, :, 1 ] b1 = f. normalize ( a1 ) b2 = f. normalize ( a2 - torch. einsum ('bi, bi - > b ', b1, a2 ). unsqueeze ( - 1 ) * b1 ) b3 = torch. cross ( b1, b2 ) return torch. stack ( ( b1, b2, b3 ), dim = - 1 ) | [
0.0550735667347908,
-0.44324439764022827,
0.6249489188194275,
0.3658328354358673,
-0.29292064905166626,
-0.5790523290634155,
0.47543808817863464,
-0.5711550712585449,
0.6385849714279175,
0.28802216053009033,
-0.4528200626373291,
-0.5772873759269714,
-0.30462756752967834,
-1.737451791763305... |
def addr2bin ( str ) : try : return struct. unpack ( "! l ", socket. inet _ aton ( str ) ) [ 0 ] except socket. error : if not socket. has _ ipv6 : raise h, l = struct. unpack ( "! qq ", socket. inet _ pton ( socket. af _ inet6, str ) ) return h < < 64 | l ; | [
-0.0038116048090159893,
-0.14392778277397156,
0.8055450320243835,
0.22910554707050323,
-1.2566252946853638,
0.0617825910449028,
0.008816223591566086,
-0.5769562721252441,
0.847032904624939,
0.20392276346683502,
0.09380350261926651,
0.40292268991470337,
-0.3419174253940582,
-0.5981058478355... |
def update _ routes ( csv _ file, year _ months ) : now = utcnow ( ) def log _ bulk ( self ) : log. info ('store external _ segment : % r ', self. nresult ) log. info ('updating db with contents of % s... ', csv _ file ) xls = pd. read _ csv ( tmp _ dir +'/'+ csv _ file, sep = ', ', skiprows = [ 0, 1, 2 ] ) new _ colum... | [
-0.4940895736217499,
-0.18369248509407043,
0.8608278632164001,
-0.1418607234954834,
-0.6480913162231445,
0.2577444016933441,
-0.44348227977752686,
0.7785521149635315,
-0.11965867131948471,
0.43279707431793213,
-0.015979740768671036,
-0.28489264845848083,
-0.13590818643569946,
0.40709349513... |
def _ show _ displays ( self ) : return list ( ) | [
-0.029543939977884293,
-0.2028590738773346,
0.5365248322486877,
0.06828344613313675,
-0.7256108522415161,
0.9004724025726318,
0.5488191843032837,
-0.5795140266418457,
1.066730260848999,
-0.7821966409683228,
0.10330945998430252,
0.13938647508621216,
0.37988075613975525,
0.892916738986969,
... |
def test _ write ( self ) : message = singlerequestmessage ( request _ id = " 0001 ", operation = " echo ", payload = " hello world " ) m _ bytes = write _ message ( message ) self. assertequal ( m _ bytes,'r0001004echo0000000bhello world') | [
-0.9255880117416382,
0.5039718747138977,
0.4163632094860077,
0.6916942596435547,
1.1401287317276,
0.7439982891082764,
0.2833160161972046,
-0.11494370549917221,
-0.00635020574554801,
-1.1229337453842163,
0.19990256428718567,
-0.45864707231521606,
-1.1448626518249512,
0.41317468881607056,
... |
def _ _ new _ _ ( cls, alphabet =..., dims =..., data =..., dtype =... ) :... | [
0.07766666263341904,
-0.5076793432235718,
0.5518730282783508,
0.4157777428627014,
-0.5276978611946106,
-0.10263079404830933,
0.3018549978733063,
0.16257712244987488,
-0.030858114361763,
-0.4227582514286041,
-1.2764854431152344,
0.6514927744865417,
0.19530971348285675,
0.3633836805820465,
... |
def norm ( x ) : return math. sqrt ( sum ( x * * 2 ) ) | [
0.09545116126537323,
-0.46756911277770996,
0.11732620000839233,
0.8087185025215149,
-0.596753716468811,
0.04162650182843208,
-0.0796516090631485,
-0.21775326132774353,
0.9078410863876343,
-0.6051959991455078,
-1.1582794189453125,
0.4484570026397705,
0.2644349932670593,
-0.5273424386978149,... |
def set ( self, x : int, y : int, z : int, x _ size : int, y _ size : int, z _ size : int, color : tuple [ int, int, int, int ] ) : assert ( x > = 0 and y > = 0 and z > = 0 and x + x _ size < = self. x _ size and y + y _ size < = self. y _ size and z + z _ size < = self. z _ size ) color _ i = self. add _ to _ palette ... | [
0.03628147393465042,
0.029985813423991203,
0.7677996158599854,
-0.7278023362159729,
0.20720134675502777,
0.44416332244873047,
0.17137643694877625,
-0.5742022395133972,
-0.01245694700628519,
0.43241947889328003,
-1.1903371810913086,
0.3973008692264557,
-0.28212106227874756,
-0.3285951614379... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.