text stringlengths 25 2.19k | embedding listlengths 768 768 |
|---|---|
def decode _ invocation _ result ( result ) : if'stack'not in result : return result result = copy. deepcopy ( result ) result ['stack'] = _ decode _ invocation _ result _ stack ( result ['stack'] ) return result | [
-0.21382920444011688,
0.11024974286556244,
0.4857550263404846,
0.2798255681991577,
-0.7516758441925049,
-1.3019280433654785,
0.2245768904685974,
-0.4515042006969452,
0.3991967439651489,
0.1328689306974411,
-0.5642062425613403,
0.5286052227020264,
-1.1516474485397339,
0.20816738903522491,
... |
def get ( org _ id ) : org = orgservice. find _ by _ org _ id ( org _ id, allowed _ roles = all _ allowed _ roles ) if org is none : response, status = {'message':'the requested organization could not be found.'}, \ http _ status. http _ 404 _ not _ found else : response, status = org. as _ dict ( ), http _ status. htt... | [
0.09892592579126358,
-0.38786581158638,
0.6238929033279419,
0.3801170289516449,
0.35260775685310364,
-0.4692334234714508,
-0.5485091805458069,
0.865513801574707,
0.20731104910373688,
0.5311276912689209,
0.14861845970153809,
0.9888885021209717,
0.057055648416280746,
0.3479134738445282,
0.... |
def findextensionbyname ( self, * args, * * kwargs ) : # real signature unknown pass | [
0.10069585591554642,
-0.27259883284568787,
0.45728424191474915,
1.0638657808303833,
-0.5030103325843811,
-0.7136423587799072,
0.11364219337701797,
-1.1836555004119873,
0.2529371380805969,
0.4849065840244293,
-1.1001996994018555,
-0.15836168825626373,
-1.0831570625305176,
0.6195569038391113... |
def smart _ bool ( s, fallback = false ) : try : s = s. lower ( ) if s in ['true ','t ','yes ','y ','1'] : return true elif s in ['false ','f ','no ','n ','0'] : return false except attributeerror : pass return fallback | [
-0.14593562483787537,
0.47574561834335327,
0.4998701214790344,
0.177071213722229,
-1.0844193696975708,
-0.3375365734100342,
-0.12527184188365936,
0.30611348152160645,
0.3055092990398407,
-0.17444677650928497,
-0.5061898827552795,
-0.6832669377326965,
-0.4984626770019531,
-0.097020074725151... |
def log ( self ) : text _ index = 0 text _ from _ xml, ids, eng _ list = self. util. get _ text _ from _ xml ( self. string _ xml, " log ", " trans - unit ", config. selected _ language. strip ( ) ) xpath _ main = self. util. read _ xpath _ list _ from _ xml ( self. object _ repo, " logmain ", self. my _ object ) xpath... | [
-0.4599805176258087,
-0.4355930984020233,
0.9342185854911804,
0.20613433420658112,
-0.030465643852949142,
0.12963804602622986,
-0.2509070336818695,
0.15563130378723145,
-0.15519024431705475,
-0.02227698639035225,
-0.24187465012073517,
0.19309158623218536,
-0.8529105186462402,
0.40807729959... |
def add _ args ( parser ) : # fmt : off parser. add _ argument ('- - lr - shrink ', default = 0. 1, type = float, metavar ='ls ', help ='shrink factor for annealing, lr _ new = ( lr * lr _ shrink )') parser. add _ argument ('- - schedule ', type = int, nargs ='+ ', default = [ 150000, ], help ='decrease learning rate a... | [
-0.049783360213041306,
0.24854886531829834,
0.7723289132118225,
-0.4960174560546875,
0.2832317054271698,
0.2806601822376251,
-0.6467794179916382,
0.13533678650856018,
-0.2628202438354492,
0.3657359778881073,
-0.2963846027851105,
0.5297406911849976,
0.2764812707901001,
0.8059831857681274,
... |
def process _ service _ delete _ data ( smodelctx, sdata, * * kwargs ) : modify = true if modify and kwargs is not none : for key, value in kwargs. iteritems ( ) : log ( " % s = = % s " % ( key, value ) ) if modify : config = kwargs ['config'] inputdict = kwargs ['inputdict'] | [
-0.5143201947212219,
-0.07053575664758682,
0.609918475151062,
-0.2896254062652588,
-0.4155227243900299,
0.5078997611999512,
-0.7556419968605042,
0.24975627660751343,
0.6570691466331482,
0.19680310785770416,
-0.020214220508933067,
0.6538614630699158,
-0.3897670805454254,
0.7946500778198242,... |
def _ auto _ run ( args ) : # tdh ( 2020 - 01 - 14 ) for developement testing the following section # replicates the functionality of " cross _ run _ id. py " so that # json _ results can be created and used to create the graph image # files. import cross _ run _ id as cri import standard _ analysis as sa import benchm... | [
0.6848427057266235,
0.2947455644607544,
0.7537586092948914,
0.44750407338142395,
1.2659322023391724,
-0.6784835457801819,
1.4919170141220093,
0.09134490042924881,
-1.1789308786392212,
-0.08601310849189758,
-0.16855837404727936,
0.2820536196231842,
-0.2696888744831085,
0.5741176009178162,
... |
def metar ( 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. " ) retu... | [
-0.04307079687714577,
0.09497494250535965,
0.7418330311775208,
-0.4921489357948303,
0.04611373692750931,
0.2879570424556732,
-0.2612469792366028,
0.3206987679004669,
0.27745842933654785,
0.3289341330528259,
0.647484302520752,
0.13507716357707977,
-0.698280930519104,
-0.29070231318473816,
... |
def test _ plan ( self ) : target = project. objects. create ( name ='test project ', slug ='test - project') items = [ ] for i in range ( 10 ) : items. append ( item. objects. create ( project = target, summary ='item % d'% i, complexity = i % 6 or 1 ) ) delta = timedelta ( 30 ) now = datetime. now ( ) target. plan ( ... | [
-0.26662182807922363,
0.7204764485359192,
0.8402482867240906,
0.10933597385883331,
0.9693326950073242,
0.7748953104019165,
0.45660462975502014,
0.2315465658903122,
0.21931570768356323,
-0.27798837423324585,
-0.7545150518417358,
-0.19488129019737244,
0.2980972230434418,
-0.14319883286952972... |
def perform _ cross _ validation ( data, labels, cnn _ model _ hyperparamters, regression = true, num _ classes = 1, binary _ multitask = false, use _ matrix _ based _ implementation = false, plot _ training _ mse = false, training _ _ num _ epochs = 100, training _ _ batchsize = 20, initial _ lr = 3e - 3, l2 _ reg = 1... | [
-0.13980628550052643,
0.41584089398384094,
0.8542081713676453,
1.2788835763931274,
0.3806518018245697,
-0.2056187093257904,
1.3859894275665283,
0.9527732729911804,
-0.11555459350347519,
0.3079223036766052,
0.11978814005851746,
-0.2687802314758301,
-0.7224149107933044,
0.14656315743923187,
... |
def display _ current _ inventory ( args ) : with open ('products. csv ', newline ='' ) as csv _ file : product _ reader = csv. dictreader ( csv _ file ) products _ in _ stock = [ product for product in product _ reader if product _ is _ in _ stock ( product ) ] if args. count : inventory _ table = table ( title ='curr... | [
-0.3958110809326172,
-0.5692139863967896,
0.7630603909492493,
0.2079029530286789,
0.3687796890735626,
0.484249472618103,
0.7552304863929749,
-0.41890236735343933,
-1.057581901550293,
0.8850092887878418,
0.28198492527008057,
0.5926370024681091,
0.7183862924575806,
0.07437797635793686,
0.0... |
def select ( self ) : best _ num _ components = self. n _ constant return self. base _ model ( best _ num _ components ) | [
-0.2576799988746643,
-0.4880373477935791,
0.30662301182746887,
0.25914067029953003,
0.8452534675598145,
0.2890768349170685,
0.237334743142128,
-0.3371754586696625,
0.013996288180351257,
-0.2817268371582031,
0.11893876641988754,
-0.22048597037792206,
-0.22956979274749756,
-0.906617164611816... |
def test _ update _ class _ booking _ to _ paid ( self ) : poleclass = baker. make _ recipe ('booking. future _ pc ', cost = 10 ) booking = baker. make _ recipe ('booking. booking ', user = self. user, event = poleclass, paid = false ) baker. make _ recipe ('booking. block ', block _ type _ _ event _ type = poleclass. ... | [
-0.2627681493759155,
0.10158684104681015,
0.5897923707962036,
1.3712702989578247,
-0.6643422245979309,
1.0653339624404907,
-0.00531018665060401,
0.649032711982727,
-0.1095731183886528,
0.3504888415336609,
-0.4617518484592438,
-0.5367243885993958,
-0.09396109730005264,
0.5094220042228699,
... |
def test _ _ pulsed _ update _ abort ( client ) : req = get _ job _ update _ request ('test _ dc _ labrat _ pulsed. yaml') res = client. start _ job _ update ( req,'start pulsed job update test / dc / labrat') assert get _ update _ status ( client, res. key ) = = \ api. jobupdatestatus. roll _ forward _ awaiting _ puls... | [
0.07825066894292831,
-0.40567120909690857,
0.6247596740722656,
-0.65840744972229,
-0.3828750252723694,
1.1821010112762451,
-0.9957354068756104,
0.06835345923900604,
0.08867929875850677,
0.1473865807056427,
0.22294089198112488,
0.23247700929641724,
-0.44439974427223206,
-0.2489561140537262,... |
def pprint _ blockers ( blockers ) : pprinted = [ ] for blocker in sorted ( blockers, key = lambda x : tuple ( reversed ( x ) ) ) : buf = [ blocker [ 0 ] ] if len ( blocker ) > 1 : buf. append ('( which is blocking') buf. append ( ', which is blocking '. join ( blocker [ 1 : ] ) ) buf. append (')') pprinted. append (''... | [
-0.4746991991996765,
-0.003942827694118023,
0.9185611605644226,
0.5139015316963196,
0.11134207993745804,
-0.22176878154277802,
-0.46411770582199097,
-1.1689379215240479,
-0.6968213319778442,
1.641459584236145,
0.20823083817958832,
0.02454325184226036,
-0.7895426154136658,
0.916095256805419... |
def _ _ host _ from _ target ( target ) : default _ hostname = app _ identity. get _ default _ version _ hostname ( ) if default _ hostname is none : return none server _ software = os. environ. get ('server _ software ','' ) if target is default _ app _ version : return default _ hostname elif server _ software. start... | [
-0.09350427985191345,
-0.6406223773956299,
0.6616587042808533,
0.7078161239624023,
-0.6588475704193115,
0.4017394781112671,
0.32990315556526184,
-0.04958105832338333,
-0.1318667232990265,
0.7822338938713074,
0.9051269292831421,
0.07408806681632996,
0.05933809652924538,
-0.49410226941108704... |
def registerchannelson ( self, ref _ channel : str ) - > none : channel _ names = tuple ( self. frames. keys ( ) ) # get channel names ref _ channel _ idx = channel _ names. index ( ref _ channel ) # get the reference channel index other _ channel _ idc = set ( range ( channel _ names. _ _ len _ _ ( ) ) ) - { ref _ cha... | [
-0.6164684891700745,
-0.07579877972602844,
1.2060436010360718,
-0.622901439666748,
1.1718577146530151,
-0.6730131506919861,
-0.13965465128421783,
-0.8807331919670105,
0.31125709414482117,
-0.12395800650119781,
-0.24502341449260712,
0.8484940528869629,
-0.8824132680892944,
0.924308240413665... |
def _ _ repr _ _ ( self ) : a = [ ] for name in self. _ arguments : val = getattr ( self, name, none ) if val : a. append ( f'{ name } = { repr ( val ) }') if a : args _ arg = f ", args = { ', '. join ( a ) } " else : args _ arg = " " return f " { self. _ _ class _ _ } ( required = { self. required } { args _ arg } ) " | [
-0.9633195996284485,
-0.9386909008026123,
0.46953335404396057,
-1.4583760499954224,
-0.0058202240616083145,
0.09272517263889313,
-0.7274842858314514,
0.1276736855506897,
-0.5141770243644714,
0.9386806488037109,
0.3566565215587616,
0.4324249029159546,
0.43942415714263916,
0.7666917443275452... |
def display _ label _ images ( images, label ) : limit = 24 # show a max of 24 images plt. figure ( figsize = ( 15, 5 ) ) i = 1 start = labels. index ( label ) end = start + labels. count ( label ) for image in images [ start : end ] [ : limit ] : plt. subplot ( 3, 8, i ) # 3 rows, 8 per row plt. axis ('off') i + = 1 p... | [
-0.24740415811538696,
0.10364219546318054,
0.5550923943519592,
-0.5342512726783752,
-0.1395142525434494,
0.5346308350563049,
0.2926124930381775,
0.7726523876190186,
0.25368911027908325,
0.6437413692474365,
0.911096453666687,
1.0575722455978394,
0.1555468887090683,
-0.5437718629837036,
0.... |
def getcameraeventstatus ( ) : andor _ solis. getcameraeventstatus. restype = ctypes. c _ uint camstatus = ctypes. c _ uint32 ( ) result = andor _ solis. getcameraeventstatus ( ctypes. byref ( camstatus ) ) check _ status ( result ) return int ( camstatus. value ) | [
0.22329415380954742,
-0.790667712688446,
0.5811103582382202,
0.5308720469474792,
-0.6127142906188965,
-0.6592006683349609,
0.19312286376953125,
0.2980637550354004,
1.128259539604187,
-0.3388896882534027,
-0.6421862840652466,
0.419185996055603,
-0.263069212436676,
0.07254020124673843,
0.8... |
def _ find _ abbrv ( list _ of _ candidate ) : # check length of both texts to classify main _ text and abbreviation if len ( list _ of _ candidate [ 0 ] ) > len ( list _ of _ candidate [ 1 ] ) : return 1 else : return 0 | [
-0.9838618636131287,
-1.0712164640426636,
0.7451049089431763,
-0.006731956731528044,
-0.5309334397315979,
0.458627849817276,
-0.3571355640888214,
1.2472339868545532,
-0.02056863158941269,
0.34690171480178833,
1.1033964157104492,
0.33052727580070496,
0.09030307829380035,
1.2703685760498047,... |
def set _ trivial ( self ) : self. _ call ('set _ trivial') | [
-0.15246443450450897,
0.599258303642273,
0.26466354727745056,
0.211147278547287,
1.1470867395401,
0.3428533375263214,
0.9008188843727112,
-0.4337765574455261,
-0.4814428985118866,
-0.43803414702415466,
-0.576936662197113,
0.7305058240890503,
-0.4864894449710846,
-0.48631468415260315,
0.3... |
def single _ node _ str ( node, parent _ edge = none, indent = 1, include _ children = true ) : if hasattr ( node, " marked " ) and node. marked : color _ fn = marked [ id ( node. original ) ] opposite _ color = color = lambda s : typ. bold ( color _ fn ( s ) ) elif isinstance ( node, vnode ) : color = typ. green oppos... | [
0.2508546710014343,
-0.05914093926548958,
1.0872806310653687,
-0.42410606145858765,
-0.4882103204727173,
0.07953003793954849,
0.3890265226364136,
0.2716831564903259,
-0.25311124324798584,
0.19492171704769135,
0.6201763153076172,
0.7512667179107666,
0.31514492630958557,
-0.09184038639068604... |
def batch ( self, size : int, default _ dtype : np. dtype = np. float32 ) - >'dataset': return minibatchdataset ( self, size, default _ dtype = default _ dtype ) | [
0.7791345119476318,
0.43284210562705994,
0.34698012471199036,
0.2985374629497528,
-0.30382153391838074,
0.06884749978780746,
-0.6030627489089966,
-0.13603942096233368,
0.6557509303092957,
-1.5524930953979492,
-0.583610475063324,
0.7827998995780945,
-1.07120943069458,
-0.4684872031211853,
... |
def trafficloadcustom ( self ) : if self. force _ auto _ sync : self. get ('trafficloadcustom') return self. _ trafficloadcustom | [
0.12825854122638702,
0.09517224133014679,
0.27124032378196716,
-0.7927243113517761,
-0.5681940913200378,
-0.10938622802495956,
0.5887976288795471,
-0.8172083497047424,
0.47526997327804565,
0.36460694670677185,
-0.9381312727928162,
0.8929036259651184,
-0.23670317232608795,
-1.01982343196868... |
def build _ double _ input _ model ( learning _ rate = 0. 005, activations = " sigmoid " ) : ps _ nodes _ input _ shape = ( field _ count * max _ field _ size, channel _ count, 1 ) # patchy - san nodes track ps _ nodes _ input = input ( shape = ps _ nodes _ input _ shape, name ='ps _ nodes _ input') psn _ conv1 = convo... | [
-0.13354922831058502,
-0.016531584784388542,
1.0277612209320068,
0.915075421333313,
-0.048186738044023514,
0.5980342030525208,
0.37247252464294434,
-0.02457117848098278,
-0.25310376286506653,
-0.32413995265960693,
-0.377475768327713,
0.11818423867225647,
0.9759100675582886,
-0.300698190927... |
def findmessagetypebyname ( self, * args, * * kwargs ) : # real signature unknown pass | [
-0.028030026704072952,
-0.33730384707450867,
0.5185031890869141,
0.2623794376850128,
0.4713570773601532,
-0.6330058574676514,
0.31884461641311646,
-1.5499696731567383,
-0.4779653251171112,
0.243490532040596,
-0.9387104511260986,
-0.15826274454593658,
-1.4538919925689697,
1.3369219303131104... |
def find _ bg ( images ) : bg = np. zeros _ like ( images [ 0 ] ) try : for image in images : bg + = image return ( bg / len ( images ) ) except : # pictures could be an empty list, we don't want an error in that case. we just don't do anything to it then return 0 | [
0.06567323952913284,
0.340168833732605,
0.635281503200531,
0.2261551022529602,
0.9222075939178467,
-0.14336419105529785,
0.8828110694885254,
0.1860792189836502,
0.3600894510746002,
1.1321837902069092,
0.5456469655036926,
-0.3746301531791687,
-1.557946801185608,
1.861122965812683,
0.15789... |
def erode ( self, kernel _ size = 5, iterations = 1 ) : return ( cv2. erode ( self. im, np. ones ( ( kernel _ size, kernel _ size ), np. uint8 ), iterations ) ) | [
-0.40006616711616516,
1.0135605335235596,
0.2960650622844696,
0.2888278663158417,
-0.09111964702606201,
-1.0380123853683472,
-0.03541329875588417,
-0.37440094351768494,
1.1107693910598755,
0.7567161321640015,
0.49381130933761597,
0.24134960770606995,
-1.0437393188476562,
0.604962944984436,... |
def _ _ init _ _ ( self, environment = " staging ", access _ token = none, timeout = 3, api _ port = 443, locale ='pt - br ', ) : super ( ). _ _ init _ _ ( environment, access _ token, timeout, api _ port = api _ port, locale = locale ) self. auction = auction ( self ) self. category = category ( self ) self. condo = c... | [
-0.23069937527179718,
0.0931006520986557,
0.5221877098083496,
0.8848195672035217,
0.49341389536857605,
-0.11930695921182632,
0.0573384091258049,
0.02271173521876335,
-0.26953423023223877,
-0.515482485294342,
-0.16465401649475098,
-0.03583709895610809,
0.5075562596321106,
0.4511294960975647... |
def difficulty ( self ) : if - 1 in [ self. preparation _ time, self. cooking _ time ] : self. preparation _ time = ( self. preparation _ time if self. preparation _ time else 0 ) self. cooking _ time = self. cooking _ time if self. cooking _ time else 0 duration = self. preparation _ time + self. cooking _ time if dur... | [
-1.2888494729995728,
0.04190322011709213,
0.6710348129272461,
0.36824941635131836,
-0.10657037049531937,
0.8636426329612732,
-0.3871285319328308,
0.549832820892334,
-0.2525964379310608,
0.026413435116410255,
-0.4138270616531372,
0.11593921482563019,
0.2992989122867584,
1.3539328575134277,
... |
def register ( ) : form = registrationform ( ) # post method : handle login form submission if form. validate _ on _ submit ( ) : try : # we create a user shopping _ list _ app. register _ user ( form. first _ name. data, form. last _ name. data, form. email. data, form. password. data ) # display success and redirect ... | [
-0.43046116828918457,
0.9607698321342468,
0.577697217464447,
1.3120330572128296,
0.40796682238578796,
0.11056824028491974,
-0.011608465574681759,
0.8575814962387085,
-0.1131025105714798,
-0.6247038245201111,
-0.1936199963092804,
-0.8698464035987854,
0.12986625730991364,
0.3973337709903717,... |
def handle _ read ( self ) : try : buf = self. sock. recv ( 4096 ) except socket. error as err : if err. args [ 0 ] not in nonblocking : self. handle _ error ( " socket error reading from { 0 } ". format ( self. sock ) ) return self. error if buf : try : self. reply = self. protocol. got _ input ( buf ) if self. reply ... | [
0.003860303433611989,
0.35294783115386963,
1.216962218284607,
-0.10042466968297958,
-0.5581052899360657,
-0.021068532019853592,
0.2833985388278961,
-1.1111663579940796,
0.09291490167379379,
-0.24151599407196045,
0.8741919994354248,
-0.5663936138153076,
-1.44204580783844,
-0.516008198261261... |
def distance _ scipy _ spatial ( z, k = 4, metric ='euclidean ', keep _ 1 = false ) : d = scipy. spatial. distance. pdist ( z, metric ) d = scipy. spatial. distance. squareform ( d ) # k - nn graph. if ( keep _ 1 ) : start = 0 ; else : start = 1 ; idx = np. argsort ( d ) [ :, start : k + 1 ] d. sort ( ) d = d [ :, star... | [
0.17370881140232086,
-0.040712662041187286,
0.45401278138160706,
1.1969115734100342,
-0.7340795993804932,
0.45567646622657776,
0.3955310583114624,
-0.39515143632888794,
0.4514504373073578,
0.6662421226501465,
0.18262061476707458,
0.34971144795417786,
0.5713624954223633,
-0.6718891859054565... |
def get _ nodes ( self ) : return self. nodes | [
-1.1847517490386963,
0.1333782821893692,
0.14156657457351685,
-0.2345595359802246,
0.9172623753547668,
-0.008561392314732075,
-0.3395722806453705,
-0.002314697951078415,
0.004816631320863962,
-0.3995584547519684,
-0.4380265772342682,
1.1913834810256958,
-0.39947304129600525,
-0.43888500332... |
def _ cached _ tests _ work _ dir ( self ) : return join _ path ( self. test _ suite. current _ test _ cache _ dir, self. extra _ install _ tests ) | [
-0.49076586961746216,
0.10263928771018982,
0.46059635281562805,
0.6759705543518066,
-0.12959273159503937,
1.0729286670684814,
1.5862661600112915,
0.4788886308670044,
0.3094191551208496,
-0.1811567097902298,
0.3062838912010193,
0.409517765045166,
-1.1102313995361328,
0.21151359379291534,
... |
def pitch _ bins _ f ( x ) : bins = [ x [ :, :, i : : octave, : 1 ]. sum ( 2 ) for i in range ( octave ) ] bins = torch. cat ( bins, dim = - 1 ) bins = bins. repeat ( num _ octaves, 1, 1 ) bins = bins. view ( x. shape [ : 2 ] + ( num _ notes, 1 ) ) return bins | [
0.0011459299130365252,
0.9706977009773254,
0.68573397397995,
0.8242960572242737,
-0.4282176196575165,
0.6116347312927246,
1.401449203491211,
-0.640181303024292,
-0.42790487408638,
0.32190725207328796,
-0.5096572041511536,
-0.29494038224220276,
0.5082271695137024,
-0.24866151809692383,
-0... |
def printtable ( args, fragdict, readdict ) : of = open ( args. table, " w " ) of. write ( " \ tfrag. sampled " ) of. write ( " \ tfrag. len. min. \ tfrag. len. 1st. qu. \ tfrag. len. mean \ tfrag. len. median \ tfrag. len. 3rd qu. \ tfrag. len. max \ tfrag. len. std. " ) of. write ( " \ tfrag. med. abs. dev. \ tfrag. ... | [
0.7713348269462585,
-0.4077620804309845,
1.1378839015960693,
-0.49842116236686707,
0.38358262181282043,
0.35073739290237427,
0.680950403213501,
-0.4964611828327179,
-0.8751513957977295,
-0.11317548155784607,
0.12155761569738388,
-0.02519294247031212,
-0.587855339050293,
-0.1376041322946548... |
def clean _ honeypot ( self ) : value = self. data [ " honeypot " ] if value : raise forms. validationerror ( u'this field must remain empty.') return value | [
0.8723061680793762,
0.30444660782814026,
0.5400580167770386,
-0.20529308915138245,
0.45315852761268616,
1.352122187614441,
0.9061256647109985,
-0.1717633754014969,
0.2230769544839859,
0.33002975583076477,
-0.12251526862382889,
-0.5658743977546692,
-0.6048334240913391,
0.05025563761591911,
... |
def center _ loss ( features, label, alfa, nrof _ classes ) : nrof _ features = features. get _ shape ( ) [ 1 ] centers = tf. get _ variable ('centers ', [ nrof _ classes, nrof _ features ], dtype = tf. float32, initializer = tf. constant _ initializer ( 0 ), trainable = false ) label = tf. reshape ( label, [ - 1 ] ) c... | [
-0.45418012142181396,
-0.6124079823493958,
0.38763904571533203,
-0.47106772661209106,
-0.2584899663925171,
0.11941678076982498,
-0.07719148695468903,
0.6630479097366333,
0.8035986423492432,
0.707533061504364,
-0.12019922584295273,
0.1813764125108719,
0.7046694159507751,
-0.0864418372511863... |
def backgroundnormalization ( self, channels, post _ processing _ fct : callable = none ) : if post _ processing _ fct is not none : for channel _ name in channels : if channel _ name! = " _ _ _ " : channel _ name = channel _ name. upper ( ) for frames _ in self. frames [ channel _ name ] : frames _. contents = post _ ... | [
-0.36778753995895386,
-0.48178404569625854,
0.7112558484077454,
-0.37258416414260864,
-0.24033872783184052,
-0.6483142375946045,
0.24836578965187073,
-0.23137205839157104,
-0.23334576189517975,
-0.13980025053024292,
-0.05535193160176277,
0.18595658242702484,
-1.1833778619766235,
0.82137203... |
def _ is _ same _ point ( point1, point2 ) : from numpy. linalg import norm if abs ( norm ( point1 - point2 ) ) < same _ point _ atol : return true return false | [
0.5201325416564941,
-0.8704391717910767,
0.3867489695549011,
1.1468966007232666,
-0.5550105571746826,
0.656089186668396,
-0.8405378460884094,
-0.7611035704612732,
0.06550579518079758,
0.9882895946502686,
0.21446001529693604,
0.9383198618888855,
-0.14404797554016113,
-1.1616331338882446,
... |
def effectisremoved ( self ) : self. trap. turns = 1 self. pkmn. secondaryeffects. append ( self. trap ) self. trap. afterturn ( self. pkmn ) assert self. trap. turns = = 0, " turns should be zero " assert not self. trap in self. pkmn. secondaryeffects | [
0.2840579152107239,
-0.21552708745002747,
0.46780937910079956,
-0.023431062698364258,
0.9030361175537109,
-0.2853202223777771,
0.35850363969802856,
0.615611732006073,
1.2315466403961182,
-0.6596658229827881,
-1.064263939857483,
-0.2813529372215271,
-0.06790973246097565,
-0.1202417388558387... |
def load _ table ( self, table _ file, name ='' ) : self. do _ load _ table ( table _ file, name = name ) | [
0.7284472584724426,
0.3180307447910309,
0.4182099997997284,
1.3793914318084717,
-0.1746952086687088,
0.2977706491947174,
0.1300046145915985,
0.16911253333091736,
-1.3838872909545898,
0.2638711631298065,
-0.5382121801376343,
0.09913402050733566,
-0.08962167799472809,
0.08225669711828232,
... |
def select ( self, indices : iterable, keep _ in _ memory : bool = false, indices _ cache _ file _ name : optional [ str ] = none, writer _ batch _ size : optional [ int ] = 1000, new _ fingerprint : optional [ str ] = none, ) - > " dataset " : assert ( not keep _ in _ memory or indices _ cache _ file _ name is none ),... | [
-1.0232489109039307,
0.25356853008270264,
0.7348253130912781,
0.23028281331062317,
-0.3412966728210449,
-0.3507586717605591,
0.933610737323761,
-0.12104888260364532,
0.7126639485359192,
-0.09032543748617172,
0.6126102209091187,
0.22576621174812317,
-0.04741350933909416,
-0.7570279836654663... |
def actions ( self, touches ) : self. _ set _ actionlist ( touches ) | [
-0.6829640865325928,
0.47574105858802795,
0.038503773510456085,
1.4255036115646362,
0.6511572003364563,
0.4178813397884369,
1.0467760562896729,
-0.15662895143032074,
1.1266462802886963,
-0.6632359623908997,
-1.0786747932434082,
-0.7685827016830444,
0.8622607588768005,
0.1612313687801361,
... |
def allow _ headers ( self ) - > sequence [ str ] : return pulumi. get ( self, " allow _ headers " ) | [
0.002761341631412506,
0.3158828616142273,
0.6420048475265503,
0.6357076168060303,
0.3374640941619873,
1.372760534286499,
-0.329507052898407,
-0.6438506245613098,
0.43764376640319824,
0.5706155896186829,
-0.32850849628448486,
0.36495232582092285,
-0.10965821892023087,
-1.0726001262664795,
... |
def get _ user _ input ( ) : foreign _ currency = int ( input ('enter 1 for euro, 2 for japanese yen, 3 for mexican peso :') ) while foreign _ currency not in ( 1, 2, 3 ) : print ( " error : invalid choice " ) foreign _ currency = int ( input ('enter 1 for euro, 2 for japanese yen, 3 for mexican peso :') ) dollar _ amo... | [
-0.22273649275302887,
0.1821303367614746,
0.6929847002029419,
0.9872154593467712,
-0.2675590515136719,
0.8745844960212708,
0.9108814597129822,
-1.0609771013259888,
-0.5682328939437866,
-0.11372040957212448,
-0.06229391321539879,
-0.4259759187698364,
-0.27169322967529297,
0.5975551605224609... |
def test _ set _ setting _ failed ( parse _ conf ) : with patch ( " salt. modules. logrotate. _ parse _ conf ", magicmock ( return _ value = parse _ conf ) ) : kwargs = { " key " : " rotate ", " value " : " / var / log / wtmp ", " setting " : " 2 " } pytest. raises ( saltinvocationerror, logrotate. set _, * * kwargs ) | [
-0.004903540015220642,
0.709514856338501,
0.43781915307044983,
-0.6126965284347534,
0.2671443223953247,
-0.10077124089002609,
-0.2784945070743561,
-1.0548994541168213,
-0.5937801003456116,
1.0930052995681763,
-0.6413177251815796,
0.36336401104927063,
-0.6748206615447998,
0.0575658343732357... |
async def remove _ payload ( self, payload : union [ payload, dict ] ) - > mythicresponse : url = " { } { } : { } / api / v { } / payloads / { } ". format ( self. _ http, self. _ server _ ip, self. _ server _ port, self. _ server _ api _ version, str ( payload. uuid if isinstance ( payload, payload ) else payload [ " u... | [
-1.353814721107483,
-0.422809362411499,
0.6767541766166687,
-0.3869444727897644,
-0.6465330719947815,
-0.903984546661377,
-0.44068658351898193,
0.3559788465499878,
0.7201532125473022,
0.6406176090240479,
-0.1885283887386322,
-0.307796448469162,
-0.6446630358695984,
-0.7890757322311401,
0... |
def test _ get _ ingredients _ required _ for _ beverage ( self, create _ beverages ) : with pytest. raises ( fetchbeveragedataerror ) : create _ beverages. get _ ingredients _ required _ for _ beverage ( 1 ) | [
-0.2608673572540283,
0.15227429568767548,
0.19567328691482544,
0.5977070331573486,
0.5023170709609985,
0.9402843117713928,
-0.8258508443832397,
0.01734466850757599,
-0.6366673707962036,
0.15668286383152008,
-0.11514391005039215,
0.629409909248352,
-0.02831040881574154,
0.07964282482862473,... |
def update _ request ( self, request : request ) - > none : self. modify _ data ('''update request set sid = % s, seen = false where req _ id = % s'' ', ( request. sid, request. req _ id ) ) | [
-1.600120186805725,
-0.49562957882881165,
0.29339224100112915,
-0.3317609131336212,
-0.262897789478302,
0.35633501410484314,
-0.29468822479248047,
-0.1344721019268036,
0.4922979474067688,
0.206198051571846,
0.09129071235656738,
1.185539960861206,
0.4106803238391876,
0.6893569827079773,
-... |
def get _ host _ id ( session, hostname ) : host _ id = db. get _ host _ id ( session, hostname ) if not host _ id : raise nameerror ( " could not find registered host with hostname = % s " % hostname ) return host _ id | [
0.43983155488967896,
0.432534784078598,
0.34245067834854126,
0.5251460075378418,
0.4254845082759857,
0.25884807109832764,
0.326990008354187,
-0.097394660115242,
0.21667087078094482,
0.35623034834861755,
0.054981425404548645,
0.3684098422527313,
-0.7774677276611328,
0.5352675914764404,
0.... |
def execute _ sum ( self, message ) : batch _ number = message. timestamp. coordinates [ 0 ] window _ data = self. windows. pop ( batch _ number, none ) # print ( " received a watermark for the timestamp : { } ". format ( batch _ number ) ) # print ( " the sum of the window { } is { } ". format ( # window _ data, sum (... | [
0.16258621215820312,
0.05632505565881729,
0.7661328315734863,
0.1325732320547104,
0.300223708152771,
-0.6203516125679016,
1.3122637271881104,
-0.2317100316286087,
-0.09787880629301071,
0.46334344148635864,
-0.40678730607032776,
1.3512636423110962,
-0.7960165143013,
0.5949110984802246,
-0... |
def test _ packages _ valid _ input ( self ) : role = role. query. filter _ by ( name = " event organizer " ). first ( ) user = testmodelfactory. create _ user ( ) user. role = role venue = testmodelfactory. create _ venue ( ) event = testmodelfactory. create _ event ( " test event ", " live " ) event. user = user even... | [
-0.15937045216560364,
0.8419986367225647,
1.0579782724380493,
0.39720383286476135,
0.36170336604118347,
0.7931899428367615,
0.047621261328458786,
0.09337777644395828,
0.4636867940425873,
-0.8630141615867615,
0.0076797110959887505,
-0.6406278610229492,
0.42090025544166565,
0.244189083576202... |
def getddgioc ( ) : andor _ solis. getddgioc. restype = ctypes. c _ uint state = ctypes. c _ int ( ) result = andor _ solis. getddgioc ( ctypes. byref ( state ) ) check _ status ( result ) return int ( state. value ) | [
-0.7066906690597534,
1.2769289016723633,
0.6062087416648865,
-0.12789693474769592,
-0.6493371725082397,
-0.8980392217636108,
1.1230127811431885,
-0.2870558798313141,
0.21561099588871002,
-0.9091054201126099,
0.3058565557003021,
0.37281012535095215,
0.5586633086204529,
-0.3177598714828491,
... |
def identity _ layer ( self, i, j = none, to _ ctrl = true ) : if to _ ctrl : self. control _ list. append ( i ( ) ) for k in range ( self. n ) : # assert len ( self. qubits [ k ] ) in ( len ( self. control _ list ), len ( self. control _ list ) - 1 ),'{ } not in { } '. format ( len ( self. qubits [ k ] ), ( len ( self... | [
-0.7677098512649536,
0.28459233045578003,
0.4708878993988037,
0.7914461493492126,
0.6550309062004089,
0.7211043834686279,
1.005625605583191,
-0.260111927986145,
0.686699390411377,
0.4504753351211548,
-0.921835720539093,
-0.35521575808525085,
-1.1829235553741455,
0.21862125396728516,
-0.0... |
async def update _ event _ message ( self, message : eventmessage ) - > mythicresponse : url = " { } { } : { } / api / v { } / event _ message / { } ". format ( self. _ http, self. server _ ip, self. _ server _ port, self. _ server _ api _ version, str ( message. id ), ) resp = await self. put _ json ( url, data = awai... | [
-1.1175718307495117,
-0.812279999256134,
0.7726296782493591,
-0.2786339521408081,
0.8265746831893921,
-0.5665481090545654,
-0.24296164512634277,
-0.10855335742235184,
0.12168386578559875,
0.49518197774887085,
-0.45383796095848083,
0.5770690441131592,
-0.7273106575012207,
-0.068794809281826... |
def getgroupdict ( self, subsystem, groupname, name = none ) : data = self. getsubsystem ( subsystem ) data = self. _ _ getgroups ( data, groupname, name ) if " groups " in data : data. pop ( " groups " ) return data | [
-0.7776685953140259,
1.25265634059906,
0.4472048580646515,
-0.16055265069007874,
-1.2928755283355713,
-0.8640199899673462,
-0.7272813320159912,
-0.7124153971672058,
-0.8600336909294128,
-0.03923523798584938,
-0.20794102549552917,
0.3709796667098999,
-0.626662015914917,
1.099165678024292,
... |
def get _ sent _ vec ( size, sent, model ) : vec = np. zeros ( size ). reshape ( 1, size ) count = 0 for word in sent : try : vec + = model [ word ]. reshape ( 1, size ) count + = 1 except : continue if count! = 0 : vec / = count return vec | [
-0.0588221475481987,
0.02494431473314762,
0.7100257873535156,
-0.5542036890983582,
0.40480926632881165,
-0.5432385802268982,
1.1036871671676636,
-0.5324179530143738,
-0.3063696324825287,
0.9280732274055481,
-0.3919297754764557,
0.028869472444057465,
-0.6666803359985352,
0.38742688298225403... |
def make _ chains ( text _ string ) : chains = defaultdict ( list ) words = text _ string. split ( ) for index in range ( len ( words ) - 2 ) : chains [ ( words [ index ], words [ index + 1 ] ) ]. append ( words [ index + 2 ] ) return chains | [
-0.12801051139831543,
0.032937731593847275,
0.31640002131462097,
-0.7759723663330078,
-0.6072400212287903,
-0.3130466043949127,
0.3534254729747772,
0.21899737417697906,
-0.651161789894104,
0.19820886850357056,
-0.7987658977508545,
0.5449789762496948,
-1.1748430728912354,
-0.436490356922149... |
def _ get _ binary _ key _ value ( key : str, value : bytes ) - > model _ pb2. keyvalue : return model _ pb2. keyvalue ( key = key, v _ binary = value, v _ type = model _ pb2. valuetype. binary ) | [
0.07557636499404907,
-0.44974493980407715,
0.4982621967792511,
0.5905790328979492,
-0.07943437993526459,
0.4921441078186035,
-1.251511812210083,
-0.8832955360412598,
-1.431443691253662,
0.7193070650100708,
-0.2890366017818451,
0.9204792976379395,
0.002533706370741129,
0.11474165320396423,
... |
def compute _ org _ mutations ( aa _ sequence, org _ found ) : import re if org _ found = ='hiv': org _ ref = b _ pol _ aa _ seq elif org _ found = ='hcv': org _ ref = h77 _ aa _ seq needle _ align ('asis : % s'% org _ ref,'asis : % s'% aa _ sequence,'sample _ vs _ wt. fasta ', go = 40., ge = 4. ) alhr = alignfile2dict... | [
-0.8735589385032654,
-0.703685462474823,
0.7391619682312012,
0.17712117731571198,
-0.008049736730754375,
-0.10783528536558151,
0.6047037839889526,
0.5549138784408569,
0.22952577471733093,
1.5144782066345215,
-0.103421650826931,
-0.11244210600852966,
0.2535720467567444,
0.4444630444049835,
... |
def modify _ hp ( entity : dict, value : int ) : hp _ before = entity ['hp'] entity ['hp'] + = value # will subtract if value is negative if entity ['hp'] < = 0 : # entity is dead entity ['hp'] = 0 if entity ['hp'] > entity ['max _ hp'] : # full health entity ['hp'] = entity ['max _ hp'] print ( ( entity ['name']. titl... | [
-0.3672964572906494,
-0.02481931820511818,
0.8262182474136353,
0.07233075052499771,
-0.09629018604755402,
0.9830577373504639,
-0.33256417512893677,
0.3647872507572174,
-0.40488365292549133,
0.6030952334403992,
1.0578218698501587,
0.29911842942237854,
0.5566863417625427,
0.39751940965652466... |
def datum _ naar _ film ( ) : import time import datetime global datum datum = input ('van welke dag wil je een film kijken? ( dd - mm - yyyy ) alleen de datums van vandaag en morgen zijn geldig :') try : valid _ date = time. strptime ( datum,'% d - % m - % y') today _ date = str ( datetime. date. today ( ). strftime (... | [
-0.9648805856704712,
0.08910958468914032,
0.5575087070465088,
-0.165336012840271,
-1.2526590824127197,
0.4172908365726471,
-0.0396684855222702,
-0.44999366998672485,
0.3355962038040161,
-0.8184967041015625,
-0.02762340009212494,
1.224617600440979,
0.5017545819282532,
1.0385231971740723,
... |
def _ run _ nanny ( self ) : try : self. logger. debug ( " running nanny " ) in _ progress = self. channel. in _ progress ( self. query _ limit ) if len ( in _ progress ) = = 0 : self. logger. debug ( " no metrics found in progress. " ) for metrics in in _ progress : if metrics. serialized _ at is not none : should _ r... | [
-0.47929835319519043,
-0.4591456651687622,
0.5931366086006165,
-0.2822122871875763,
0.45881277322769165,
-0.35093772411346436,
0.07658930122852325,
-0.18353575468063354,
-0.5457389950752258,
-0.39565393328666687,
0.2191624641418457,
0.6162237524986267,
-0.14813579618930817,
0.4857667088508... |
def test _ container ( self ) : list = [ 1, 2, 3, 4 ] iterator = iter ( list ) print ( next ( iterator ) ) | [
-0.18421730399131775,
-0.006913906894624233,
0.4513493478298187,
0.5430397391319275,
-0.2999415993690491,
0.2200716882944107,
0.6085590720176697,
-0.4237152636051178,
0.3489115536212921,
-0.7151499390602112,
0.014318342320621014,
-0.14898927509784698,
-0.22026567161083221,
1.19265770912170... |
def test _ stopservicehandlerdispatch ( self ) : events = [ ] class testhandler ( xmpphandler ) : def connectionlost ( self, reason ) : events. append ( reason ) testhandler ( ). sethandlerparent ( self. component ) self. component. startservice ( ) self. component. stopservice ( ) self. assertequals ( 1, len ( events ... | [
-0.03290068358182907,
-0.3777868449687958,
0.430841863155365,
-0.16246940195560455,
0.28837186098098755,
0.4264344871044159,
0.42281922698020935,
0.23250925540924072,
0.48369747400283813,
-1.484182357788086,
-0.5066200494766235,
-0.5488184094429016,
-0.2257963865995407,
0.33263877034187317... |
def plot _ depl _ dust _ obs ( axis, property1, property2 ) : data _ to _ use ='' log = false if axis. get _ yaxis ( ). get _ scale ( ) = ='log': log = true if property1 = ='d / z': # plot mw d / z sight line data derived from depletion measurements in jenkins09 if property2 = ='nh'or property2 = ='nh _ neutral': data ... | [
0.495403528213501,
-0.3131326138973236,
0.9014275670051575,
-0.43992698192596436,
-0.48250916600227356,
0.5161457657814026,
0.19884708523750305,
-0.6120654940605164,
-0.3250710368156433,
-0.3962439000606537,
0.37168365716934204,
1.1551764011383057,
0.26407039165496826,
0.4736185669898987,
... |
def multi _ print ( s, * params ) : print ( multi _ format ( s, * params ) ) | [
0.019601095467805862,
-1.033058524131775,
0.32716530561447144,
1.0623164176940918,
0.12585970759391785,
-1.125301718711853,
-1.1408741474151611,
-0.09965866804122925,
-0.26374661922454834,
-0.12384035438299179,
0.21425217390060425,
0.4228920042514801,
0.23294374346733093,
0.958125591278076... |
def printstate ( self, b ) : print fullstring = " " across = range ( 0, b. cols ) up = range ( b. rows - 1, - 1, - 1 ) spaces = range ( self. spacing ) for i in up : top = " + " for j in across : for k in spaces : top = top + " - " top = top + " - " for k in spaces : top = top + " - " top = top + " + " top = top + " \ ... | [
-0.2746414840221405,
-0.3390861451625824,
1.4208489656448364,
-0.32685139775276184,
-1.129631519317627,
0.5570226907730103,
0.3662746846675873,
-0.18902339041233063,
0.596937358379364,
0.5561313033103943,
0.49861401319503784,
0.10143540054559708,
-0.08333548158407211,
0.12206342816352844,
... |
def server _ name _ to _ verify ( self ) - > optional [ str ] : return pulumi. get ( self, " server _ name _ to _ verify " ) | [
0.0374503917992115,
-0.27534911036491394,
0.5774124264717102,
0.3847312331199646,
0.8438066244125366,
1.5387340784072876,
-0.21140693128108978,
-0.5426694750785828,
1.2421135902404785,
0.06687217205762863,
-0.7262358665466309,
1.4474668502807617,
-0.037168171256780624,
-0.34583282470703125... |
def drop _ all ( ) : if _ metadata : _ metadata. drop _ all ( engine ) | [
-0.060980599373579025,
0.4210733473300934,
0.41496485471725464,
0.3864603340625763,
1.2553714513778687,
0.45779114961624146,
-0.20780929923057556,
0.04815635085105896,
-0.8722143173217773,
0.6470217704772949,
0.5780339241027832,
0.6709688305854797,
0.31677478551864624,
0.7173711061477661,
... |
def getlargedependenceemphasisfeaturevalue ( self ) : pd = self. coefficients ['pd'] jvector = self. coefficients ['jvector'] nz = self. coefficients ['nz'] lre = numpy. sum ( pd * ( jvector [ none, : ] * * 2 ), 1 ) / nz return lre | [
-0.2464303821325302,
0.06069779023528099,
0.5683711171150208,
-0.883601188659668,
0.5635758638381958,
0.04674290865659714,
0.9082082509994507,
1.0043370723724365,
0.41332730650901794,
-0.2463800311088562,
-0.7184963226318359,
0.43729284405708313,
0.056850187480449677,
0.6649639010429382,
... |
def check _ in ( self, bike _ id ) : data = {'bikeid': bike _ id, } try : resp = self. _ make _ request ('checkin ', data ) except exception as e : return false if resp. code = = 200 : return true return false | [
-0.5930237174034119,
0.8302742838859558,
0.5489907264709473,
0.5640062689781189,
-0.30776721239089966,
0.708369791507721,
-0.30253109335899353,
-0.10712236166000366,
-0.69631028175354,
0.4693518280982971,
-0.1260921210050583,
0.5662850141525269,
-0.9614366292953491,
0.272256076335907,
-0... |
def test _ connection _ do _ ping _ timeout ( self, mock _ g, mock _ event _ logger, mock _ func _ timeout ) : database = get _ example _ database ( ) mock _ g. user = security _ manager. find _ user ( " admin " ) mock _ func _ timeout. side _ effect = functiontimedout ( " time out " ) db _ uri = database. sqlalchemy _... | [
0.35484108328819275,
1.1153870820999146,
0.2538769841194153,
0.22919313609600067,
0.44275930523872375,
0.6751287579536438,
0.3904746472835541,
0.11696704477071762,
-0.12976258993148804,
0.8492677807807922,
-0.5092073678970337,
-0.004055917728692293,
-0.21369679272174835,
0.3230911791324615... |
def test _ new _ demon ( ) : runs = 10 game = game ( ) og _ sprites = len ( game. all _ sprites ) for _ in range ( runs ) : game. create _ new _ demon ( ) assert len ( game. demons ) = = runs assert len ( game. all _ sprites ) = = runs + og _ sprites for demon in game. demons : pos = demon. rect. center assert ( - demo... | [
-0.5753911733627319,
-0.018390841782093048,
0.5738685727119446,
0.1872190535068512,
0.4391764998435974,
1.0163087844848633,
-0.2492314726114273,
-0.6676400303840637,
0.2898654639720917,
-0.43096065521240234,
-0.5063053965568542,
0.11117894947528839,
0.611120879650116,
0.23739084601402283,
... |
def get _ host _ info ( self ) : if not self. cache or len ( self. cache ) = = 0 : # need to load index from cache self. load _ cache _ from _ cache ( ) if not self. args. host in self. cache : # try updating the cache self. update _ cache ( ) if not self. args. host in self. cache : # host might not exist anymore retu... | [
-1.4363166093826294,
-0.22220472991466522,
0.6714895367622375,
0.002028204733505845,
-0.4041598439216614,
0.0835835188627243,
-0.4903353154659271,
-0.5456247329711914,
-0.7132503390312195,
0.7292587161064148,
-0.10946373641490936,
0.07163529098033905,
-0.3352445065975189,
0.264838457107543... |
def click _ edit _ email ( self ) : webdriverwait ( self. driver, 10 ). until ( ec. visibility _ of _ element _ located ( ( by. css _ selector, self. css _ editoptionemail ) ) ) edit = self. driver. find _ element _ by _ css _ selector ( self. css _ editoptionemail ) action = touchactions ( self. driver ) action. tap (... | [
-0.3696793019771576,
0.5344323515892029,
0.6174171566963196,
-0.2229488044977188,
0.9011270999908447,
0.022004814818501472,
1.331943392753601,
-0.12026297301054001,
0.014003423973917961,
1.0284240245819092,
-0.17296120524406433,
0.3615208864212036,
-0.4002702236175537,
-0.5020431876182556,... |
def _ _ delitem _ _ ( self, key ) : del self. _ items [ key ] # finally notify to the callback self. _ notify ( key, cataloguegroup. removed ) | [
-0.15717202425003052,
0.6498348116874695,
0.25942713022232056,
-0.9852954149246216,
-1.0635952949523926,
-0.7191812992095947,
-0.11094535887241364,
0.33504432439804077,
0.10239212960004807,
-0.22239965200424194,
-0.2868976294994354,
-0.5968628525733948,
-0.5131842494010925,
0.4580811858177... |
def test _ cancel _ task _ other _ user ( c, users : list [ user ], flights : list [ flight ] ) : def callback ( request : httprettyrequest, uri, response _ headers ) : body = request. parsed _ body assert " uuid " in body # body [ uuid ] is a list, probably to support repeated keys assert body [ " uuid " ] [ 0 ] = = s... | [
0.12422862648963928,
1.1071717739105225,
0.8641877770423889,
0.5826210975646973,
-0.16662843525409698,
0.5297703146934509,
0.28962573409080505,
-0.4329882264137268,
-0.360139399766922,
-0.11870905756950378,
-0.11674954742193222,
-0.28148916363716125,
-0.07444321364164352,
0.330338090658187... |
def test _ dup _ args _ in _ call ( x ) : return x * x | [
-0.5560501217842102,
1.180722951889038,
0.618285059928894,
-0.07953230291604996,
0.4442484378814697,
0.6938203573226929,
-0.06942572444677353,
-1.2180827856063843,
0.6960040926933289,
0.4303283095359802,
-0.9909564852714539,
0.5173458456993103,
-0.5667694807052612,
0.053488992154598236,
... |
def _ setup _ tree ( self, tree _ node, * * kwargs ) : # skip if this is not a root or if already setup if self. is _ setup ( tree _ node ) : return idtype = np. int64 fields, _ = \ self. field _ info. resolve _ field _ dependencies ( [ " uid ", " desc _ uid " ] ) halo _ id _ f, desc _ id _ f = fields dtypes = { halo _... | [
-0.5957186818122864,
0.26083990931510925,
0.4274975061416626,
-0.9703469276428223,
0.3360457718372345,
-0.03821954131126404,
-0.22761747241020203,
0.30960384011268616,
-0.2771913707256317,
-0.0951022058725357,
-0.028326546773314476,
0.5674760341644287,
0.22784851491451263,
0.65583986043930... |
def get _ next _ state ( encoding, state, transition ) : signal = transition [ : - 1 ] ind = encoding. index ( signal ) # signal index val = 1 if transition [ - 1 ] = = " + " else 0 next _ state = state [ : ind ] + ( val, ) + state [ ind + 1 : ] return next _ state | [
-0.7166513204574585,
0.4132497012615204,
0.4676566421985626,
0.3035505712032318,
-1.0153460502624512,
-0.22138166427612305,
-0.7913710474967957,
-0.07548648864030838,
0.8598574995994568,
0.15334445238113403,
-0.7463824152946472,
0.20094086229801178,
0.5034682154655457,
-0.9947450757026672,... |
def _ get _ value _ str ( self ) - > str : if self. value = = b'' : return " n / a " val = self. get _ value _ int ( ) if self. max _ width = = 0 : return bin ( val ) return f " 0b { val : 0 { self. max _ width } b } " | [
-0.40187227725982666,
-0.13755427300930023,
0.47348544001579285,
0.6695712804794312,
-0.05536952614784241,
0.5581523180007935,
0.1701720803976059,
-0.886407732963562,
-0.08789122104644775,
-0.0456949882209301,
1.5903931856155396,
-0.02758423052728176,
0.21391598880290985,
0.765836238861084... |
def test _ abslinear ( self ) : myfunc = simul. abslinear nvar = 1 vbounds = np. zeros ( ( nvar, 2 ) ) vbounds [ 0, 0 ] = - 100. vbounds [ 0, 1 ] = 100. mypb = genop. genop ( ) mypb. verbose = false self. assertequal ( mypb. popsize, 100 ) self. assertequal ( mypb. pbcross, 0. 7 ) self. assertequal ( mypb. pbmut, 0. 1 ... | [
0.21871215105056763,
0.03063959814608097,
0.7918562293052673,
0.46261200308799744,
0.1764228492975235,
1.067117691040039,
-0.5630602240562439,
-0.1309054046869278,
-0.08150414377450943,
0.06633520126342773,
-0.8146859407424927,
-0.264435738325119,
-0.7174635529518127,
0.3567104935646057,
... |
def disablebodycollisions ( self ) : pass | [
0.15904201567173004,
-0.31933513283729553,
0.43247294425964355,
0.3633160889148712,
-0.337470680475235,
1.696372628211975,
0.6990897059440613,
-0.39434704184532166,
-0.0021521151065826416,
-1.0834273099899292,
-0.6628282070159912,
-0.4818424880504608,
-1.3488410711288452,
0.245465517044067... |
def get _ admin _ user ( user _ id ) : cur. execute ( " select * from users where id = % s and role = % s ; ", ( user _ id, 1 ) ) admin = cur. fetchone ( ) return admin | [
0.3075968325138092,
0.4557618796825409,
0.2018074244260788,
0.2756511867046356,
0.07772117108106613,
-0.2465847134590149,
-0.20771244168281555,
-1.5024241209030151,
0.22536595165729523,
0.2741382122039795,
0.6640559434890747,
1.166738510131836,
-0.19857057929039001,
0.6264342665672302,
0... |
def lesser ( a, b ) : return 1 if a < b else 0 | [
0.8166654109954834,
-0.722894549369812,
0.5326646566390991,
-0.5558894276618958,
-0.05705060064792633,
-0.09760665893554688,
-0.8186017274856567,
-1.1713783740997314,
-0.4681876003742218,
-1.0013699531555176,
-0.40210574865341187,
0.1913580298423767,
-0.38775014877319336,
0.383072078227996... |
def _ _ parse _ mimetype ( self, mimetype ) : plist = mimetype. split (';') full _ type = plist. pop ( 0 ). lower ( ). strip ( ) params = { } for p in plist : kv = p. split ('=') if len ( kv )! = 2 : continue v = kv [ 1 ]. strip ( ) if v : params [ kv [ 0 ]. strip ( ) ] = v return full _ type, params | [
-0.015574069693684578,
-0.6289237141609192,
0.6373431086540222,
-0.6739360094070435,
-0.27368631958961487,
-0.5884995460510254,
-0.5673446655273438,
0.5126591920852661,
-0.3769959509372711,
1.9306120872497559,
-1.2344435453414917,
-0.054808758199214935,
-1.220062255859375,
0.42041257023811... |
def _ best _ shift _ multi _ seg ( self, lpx _ hist0, lpx _ mid0, startix = 0, endix = - 1, verbose = true, order = 2 ) : totcnt = len ( lpx _ hist0 ) if endix = = - 1 : endix = totcnt lpx _ hist = lpx _ hist0 [ startix : endix ] lpx _ mid = lpx _ mid0 [ startix : endix ] thiscnt = len ( lpx _ hist ) if verbose : print... | [
-0.21660907566547394,
-1.2220661640167236,
0.8572173118591309,
0.1156286969780922,
0.28935983777046204,
0.13583095371723175,
-0.23604387044906616,
-0.24182160198688507,
0.2193327695131302,
-0.25571581721305847,
-0.3331834077835083,
0.140651673078537,
-0.11840043216943741,
0.330015152692794... |
def submit _ job ( db _ settings, row, raw _ data, indices, threads, jobs _ folder ) : kwargs = { " pair " : ('pair'in row [ 0 ] ), " workflow " : os. path. splitext ( os. path. basename ( row [ 1 ] ) ) [ 0 ], " template " : row [ 2 ], " genome _ db " : row [ 3 ], " genome " : row [ 4 ], " uid " : row [ 6 ], " exp _ fr... | [
-0.005332275293767452,
0.41537269949913025,
0.8893697261810303,
-0.27858126163482666,
-0.17899981141090393,
-0.08877486735582352,
0.32186710834503174,
-0.06424841284751892,
-0.31157010793685913,
0.18411633372306824,
-0.018729088827967644,
0.546175479888916,
-0.6920760869979858,
0.331641912... |
def data _ trace _ enabled ( self ) - > optional [ bool ] : return pulumi. get ( self, " data _ trace _ enabled " ) | [
1.0616257190704346,
1.1052327156066895,
0.5973888039588928,
0.46496105194091797,
1.1532440185546875,
1.3933029174804688,
-0.46380531787872314,
0.4160904586315155,
0.9716925024986267,
0.19597437977790833,
-0.671268880367279,
1.0964198112487793,
-0.36120718717575073,
-0.6792254447937012,
-... |
def is _ nftfw _ path _ running ( ) : chk = subprocess. run ( ('/ bin / sh ','check _ for _ nftfw _ path. sh'), stdout = subprocess. pipe ) return chk. returncode | [
0.2458966076374054,
-0.5217038989067078,
0.5389712452888489,
0.5656742453575134,
0.05387791246175766,
-0.07605849206447601,
0.2644622027873993,
-0.23222759366035461,
-0.5835681557655334,
-0.3100355565547943,
0.576259195804596,
-0.544741690158844,
-0.29903602600097656,
1.133080244064331,
... |
def note _ list _ no _ unisons ( self ) : pure _ notes = [ ] urls _ index = 0 parts = self. score. getelementsbyclass ( stream. part ) for part in parts : notelist = part. flat. getelementsbyclass ( ['note ','rest'] ) prev _ pitch = none for note in notelist : if not note. isrest and note. namewithoctave = = prev _ pit... | [
-0.7202512621879578,
-0.628110945224762,
0.688596248626709,
0.10330220311880112,
0.5366554260253906,
0.7570604085922241,
0.6576650738716125,
-0.4467954933643341,
0.4134361445903778,
0.16216281056404114,
-0.6727186441421509,
0.03381485864520073,
-0.3239497244358063,
0.08593768626451492,
-... |
def clean _ text ( text ) : # replace newlines by space. we want only one doc vector. text = text. replace ('\ n ','' ). lower ( ) # remove urls # text = re. sub ( r " http \ s + ", " ", text ) # expand contractions : you're to you are and so on. text = contractions. fix ( text ) # remove stop words # text = preprocess... | [
0.1471419334411621,
-0.03870271146297455,
0.5601760745048523,
-0.09298893064260483,
-1.00950026512146,
-0.025583550333976746,
0.4625932574272156,
0.47007012367248535,
0.6444507837295532,
-0.4446917772293091,
0.19232474267482758,
-0.29456984996795654,
-0.04012812674045563,
0.672065258026123... |
def possibleplacemat ( self, tiles ) : for row in range ( len ( self. placements ) ) : empty = true for tile in self. placements [ row ] : if tile! = none : empty = false if empty : return true if none in self. placements [ row ] : # a tile can still be placed if self. placements [ row ] [ 0 ]. value = = tiles [ 0 ]. v... | [
-0.11646296083927155,
-0.028526319190859795,
0.4478415846824646,
-0.2485404759645462,
-0.4913707971572876,
0.5637500882148743,
0.2857694923877716,
0.3917008936405182,
0.1083061546087265,
-0.23239535093307495,
0.436688631772995,
-0.36305859684944153,
-0.8242466449737549,
0.555146336555481,
... |
def get _ spark _ needs _ auth ( self ) : return os. environ. get ('spark _ auth _ required ','false') = ='true ' | [
-1.2925344705581665,
-0.31509268283843994,
0.44085758924484253,
0.833767294883728,
-0.22308924794197083,
0.7504006624221802,
-0.2716909348964691,
0.6767086982727051,
-0.16932722926139832,
-0.19487115740776062,
-0.3797304034233093,
0.9845883250236511,
-0.6353619694709778,
0.7605804204940796... |
def test _ 02 _ 1 _ day ( self ) : self. m _ schedule _ obj. dayofweek = dayofweek _ thursday l _ days = schedtime. _ extract _ days ( self. m _ schedule _ obj, t _ wednesday ) self. assertequal ( l _ days, 1 ) self. m _ schedule _ obj. dayofweek = 127 - dayofweek _ wednesday l _ days = schedtime. _ extract _ days ( se... | [
-0.6643625497817993,
0.4607028663158417,
0.45302698016166687,
-0.8138622641563416,
0.33212727308273315,
-0.43581879138946533,
0.2518603503704071,
-0.647275984287262,
0.6369239091873169,
-0.6569845080375671,
0.226532444357872,
-0.4336594343185425,
0.1812766045331955,
0.35470229387283325,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.