text
stringlengths
25
2.19k
embedding
listlengths
768
768
def publish _ articles ( self, article _ ids ) : errors = [ ] for article in article _ ids : error = self. publish _ article ( article ) if error is not none : errors. append ( error ) if errors! = [ ] : return errors else : return none
[ -0.7453774809837341, -0.5462990403175354, 0.2227080911397934, 0.5274717807769775, 0.3874700665473938, -0.6487693190574646, -0.3136098384857178, -0.15052083134651184, -0.08858903497457504, 1.838818907737732, 0.06232399120926857, -0.06896793097257614, -0.8212217688560486, 0.6751993894577026,...
def get _ function _ value ( x, function _ number ) : if function _ number = = 1 : return x - 3 elif function _ number = = 2 : return abs ( x ) elif function _ number = = 3 : return get _ polynomial _ value ( [ 2, 1, - 3, 7 ], x ) elif function _ number = = 4 : return 4 * np. cos ( x ) + 6 * np. sin ( x ) elif function...
[ -0.25580111145973206, -0.1845124065876007, 0.7688238024711609, 0.4832404851913452, -0.23138613998889923, -0.058112747967243195, -0.04377790167927742, -0.3908931314945221, -0.33018842339515686, -0.288653165102005, -0.46128785610198975, 0.9646294116973877, 0.4282653331756592, -0.528359174728...
def get _ content ( self, webview = false ) : newsletter = self. job. newsletter context = self. get _ context ( ) context ['newsletter'] = newsletter context ['webview'] = webview request = httprequest ( ) request. content _ context = context return render _ to _ string ( newsletter. template. path, context, context _...
[ 0.0731501579284668, 0.16173459589481354, 0.5388687252998352, 0.015285796485841274, -0.6940760016441345, -0.49330076575279236, -0.530029833316803, 0.23034308850765228, 0.509477436542511, -1.1010584831237793, 0.7737917900085449, -0.23060379922389984, -0.23283977806568146, 0.39755967259407043...
def etp ( ) : print ( f " \ nemergent task planner ( etp ) form page " ) iso _ date = str ( date. today ( ) ) filename = " etp _ tasks _ " + iso _ date + ". csv " # check to see if csv file exists if os. path. exists ( filename ) : print ( f " external csv file { filename } exists. " ) today = datetime. now ( ) formatt...
[ -0.6705780625343323, -0.3613010048866272, 0.935830295085907, -0.1619141548871994, 0.26713117957115173, 1.0655320882797241, 0.12083849310874939, -0.02630416862666607, -0.4044169783592224, 1.0416525602340698, -0.25925567746162415, -0.6161064505577087, 1.1951996088027954, 0.3214585781097412, ...
def search _ stream ( self, stream _ name ) : return self. rawdata. nosql. search _ stream ( stream _ name = stream _ name )
[ -0.493002712726593, 0.28597694635391235, 0.4069521427154541, 0.14833123981952667, -0.7457730770111084, -0.7564495801925659, -0.49873101711273193, -1.0494866371154785, -0.37705981731414795, -0.4724697768688202, -0.5626741647720337, 0.763218343257904, -0.7256878614425659, 0.4633161723613739,...
def modify _ corners ( board ) : board [ 0 ] [ 0 ] ='/'board [ 0 ] [ - 1 ] ='\ \'board [ - 1 ] [ 0 ] ='\ \'board [ - 1 ] [ - 1 ] ='/'return board
[ -0.31799647212028503, -0.03787333518266678, 0.8023274540901184, -0.738836944103241, 0.9078695774078369, -0.3420087397098541, 0.4265657365322113, 0.16086022555828094, -0.6536985039710999, 0.8415306210517883, 0.44382935762405396, -0.21311712265014648, -0.23733744025230408, -0.159102603793144...
def random _ permutation ( shape : sequence [ int ], dtype : union [ tf. dtype, np. dtype ] = np. float32 ) - > np. ndarray : values = ndarange ( shape, dtype ) np. random. shuffle ( values ) return values
[ -0.5348787307739258, 0.9129317998886108, 0.44396546483039856, -0.6149924397468567, -0.17989078164100647, 0.09750760346651077, 0.34679895639419556, -1.027976632118225, 0.7418408393859863, 0.6573296189308167, 0.038932181894779205, -0.11248142272233963, -0.24124491214752197, 0.288929164409637...
def send _ email ( subject, body, recipients, file _ path ) : # if settings. email is none or settings. smtp is none : # logger. error ( " no email / smtp config, email not sent. " ) # return if not isinstance ( recipients, list ) : raise typeerror ( " { } should be a list ". format ( recipients ) ) # we only support o...
[ 0.28833362460136414, 0.694604218006134, 0.9422340989112854, 0.24304480850696564, 0.2148818075656891, 0.5626664757728577, -0.05435986444354057, 0.8233132362365723, -0.6966192722320557, 0.6876813173294067, 0.05027804896235466, 0.23390837013721466, -0.24203333258628845, -0.1774328649044037, ...
def test _ divide _ scalar ( ctx _ factory ) : context = ctx _ factory ( ) queue = cl. commandqueue ( context ) a = np. array ( [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ] ). astype ( np. float32 ) a _ gpu = cl _ array. to _ device ( queue, a ) result = ( a _ gpu / 2 ). get ( ) assert ( a / 2 = = result ). all ( ) result = ( 2 /...
[ 0.23271460831165314, 0.29998958110809326, 0.8143733739852905, 1.105701208114624, 0.7003766298294067, 0.31093811988830566, 1.0268933773040771, -1.1344740390777588, -0.03429353982210159, -0.5599004626274109, 0.2795262038707733, -0.1723395735025406, 0.1884181797504425, 0.8149518370628357, 0...
def get _ team _ stats ( ) : client = pymongo. mongoclient ( db _ url ) db = client. attempt4 ml _ stats = db. learningstats parsed _ stats = [ ] for game _ stats in ml _ stats. find ( ) : temp _ list = [ ] del game _ stats [ " _ id " ] del game _ stats [ " game _ id " ] winner = game _ stats [ " winner " ] del game _ ...
[ 0.4029558598995209, 0.013744956813752651, 0.5279446840286255, -0.3523823022842407, 0.5929616093635559, 0.355543851852417, -1.189710259437561, -0.5898510813713074, -0.831710159778595, 0.4908352196216583, -0.6337811946868896, 0.13027560710906982, 0.3271351754665375, -0.28253793716430664, 0...
def _ prod ( self, in _ vec, mode, mask = none ) : # when we have a derivative based solver at a level below the # group that owns the assembledjacobian, we need to use only # the part of the matrix that is relevant to the lower level # system. mat = self. _ matrix if mode = ='fwd': if mask is none : return mat. dot ( ...
[ -0.6666637063026428, -0.15733258426189423, 1.0111786127090454, 0.1350393295288086, -0.6575929522514343, 0.2622804641723633, 0.8811129331588745, -0.9101681113243103, -0.27217283844947815, 0.04701831191778183, 0.5609726905822754, 0.42945989966392517, 0.08337864279747009, -0.41791749000549316...
def test _ reset _ not _ allowed _ in _ setup ( self ) : for procedure in self. procedures : if procedure. get ('name'). startswith ('setup') : body = procedure [ 0 ] commands = [ cmd. strip ( ) for cmd in body. text. split ( ) ] self. assertnotin ('antennareset ', commands )
[ 0.014043627306818962, 0.34600338339805603, 0.39243176579475403, -0.2180829793214798, 0.24827538430690765, -0.12586267292499542, 0.4358954131603241, -0.6659372448921204, 0.29074278473854065, 0.986786425113678, 0.6506028175354004, 0.4953731298446655, -0.2567578852176666, 0.1340693235397339, ...
def validate ( self ) : errors = [ ] topcount = 0 for top in self. _ findtops ( ) : top _ node = self. g. node [ top ] if top _ node ['op _ type'] = ='baseselection': topcount + = 1 if topcount > 1 : errors. append ( " more than one baseselection node " ) if topcount = = 0 : errors. append ( " missing one baseselection...
[ -1.5473852157592773, 0.12256172299385071, 0.6406287550926208, 0.3758997619152069, 1.022438883781433, 0.011670880950987339, 1.098997950553894, -0.3738294541835785, -0.15563276410102844, 0.5256869196891785, 0.533810019493103, -0.3379230797290802, -0.10037726163864136, 0.6062115430831909, 0...
def load _ from _ folder ( folder _ path, label ) : matrix _ list = [ ] # get path to current file so this can be called from anywhere this _ file _ path = " / ". join ( ( os. path. abspath ( _ _ file _ _ ) ). split ( " / " ) [ : - 1 ] ) curr _ dir _ path = this _ file _ path + " / " + folder _ path # grab subdirectory...
[ -0.7463595271110535, -0.46500837802886963, 0.7227467894554138, -0.22971679270267487, -0.2682008147239685, 0.511259138584137, 0.2249659299850464, 0.32846397161483765, -0.3286270499229431, 0.7622202634811401, 0.008961058221757412, -0.13396446406841278, -0.47737279534339905, 1.024402141571045...
def test _ qlibrary _ instantiate _ short _ to _ ground ( self ) : design = designs. designplanar ( ) try : shorttoground except exception : self. fail ( " shorttoground failed " ) try : shorttoground ( design, " my _ name " ) except exception : self. fail ( " shorttoground ( design, \ " my _ name \ " ) " ) try : short...
[ 0.5377691984176636, 0.058610301464796066, 0.5359407663345337, -0.3923673927783966, 0.05733503773808479, 1.4239617586135864, 1.0191701650619507, -1.119152307510376, -0.07273256778717041, -0.39183974266052246, -0.4870166778564453, -0.013322309590876102, -0.057379599660634995, 0.5865586996078...
def return _ weights ( self ) : class _ weight = { } train, val = self. index _ folds [ 0 ] n = self. y. ix [ train ]. shape [ 0 ] + self. y. ix [ val ]. shape [ 0 ] for i in range ( self. classes ) : size _ i = ( self. y. ix [ train ] = = i ). astype ( int ). sum ( ) + ( self. y. ix [ val ] = = i ). astype ( int ). su...
[ -1.3312082290649414, 0.406820684671402, 0.7775638699531555, -0.03996767848730087, -0.3455541729927063, -0.43206796050071716, 1.4755688905715942, -0.3401521146297455, -0.35560500621795654, 0.3185524642467499, -0.4989258348941803, -0.1524553894996643, 0.24993696808815002, 0.7178931832313538,...
def binary _ var _ list ( size, name = none ) : return integer _ var _ list ( size, binary _ domain, name = name )
[ -0.4150097966194153, 0.12940043210983276, 0.41379645466804504, 0.36514124274253845, -0.45968806743621826, -0.5199690461158752, -0.31121721863746643, -0.7172995805740356, 0.2580731511116028, 0.3333398699760437, -1.9435886144638062, 0.852698028087616, -0.055189672857522964, 0.821936070919036...
def add _ loss _ op ( self, preds ) : # # # your code here ( ~ 2 - 4 lines ) loss = tf. reduce _ mean ( tf. nn. sparse _ softmax _ cross _ entropy _ with _ logits ( labels = self. labels _ placeholder, logits = preds ) ) # # # end your code return loss
[ -0.5210369229316711, 0.16490207612514496, 0.4672316610813141, 0.05820244178175926, 0.07571093738079071, 0.2628534138202667, 0.2540586590766907, 0.6596859097480774, 0.52410888671875, 0.3999556005001068, 0.334430456161499, 0.2902751564979553, -0.35835346579551697, -1.069546103477478, -0.39...
def send _ to _ hdfs ( old _ item, new _ item ) : df = createdataframe ( old _ item ) if df : saved = savedataframe ( df, new _ item ['source'] ) return saved return false
[ -1.0648919343948364, 0.6081172823905945, 0.44404137134552, 0.1972265988588333, 0.9646459221839905, -0.5178555846214294, -0.6403020024299622, -0.33168208599090576, -0.41971519589424133, 0.5011103749275208, -0.6583443880081177, 0.1256105750799179, -0.35778725147247314, -0.6658465266227722, ...
def volume _ get _ iscsi _ target _ num ( context, volume _ id ) : return impl. volume _ get _ iscsi _ target _ num ( context, volume _ id )
[ -0.8180297613143921, -0.7001667618751526, 0.6818550825119019, 0.07900268584489822, 0.9759846329689026, -1.3821375370025635, 0.05015483871102333, 0.4108780026435852, 0.28486335277557373, -0.4246162176132202, 0.14179733395576477, 0.9650096297264099, -0.30376529693603516, -1.2239539623260498,...
def test _ order ( self ) : self. failunlessequal ( self. i2, item. objects. all ( ) [ 0 ] ) self. failunlessequal ( self. i3, item. objects. all ( ) [ 1 ] ) self. failunlessequal ( self. i1, item. objects. all ( ) [ 2 ] )
[ -0.597103476524353, -0.518773078918457, 0.35606998205184937, 0.6949249505996704, 1.1682740449905396, 0.9181644320487976, 0.2546035349369049, -0.4801458716392517, -0.3718290328979492, -0.04712584614753723, -1.6251426935195923, -0.6728441119194031, -0.5467256903648376, -0.7387059926986694, ...
def _ set _ srid ( self, srid = none ) : if srid : self. srid = int ( srid ) geos. lgeos. geossetsrid ( self. _ shape. _ geom, self. srid ) else : self. srid = none
[ 0.7349715232849121, -0.4549653232097626, 0.4515502452850342, -1.5141853094100952, -0.4772757291793823, -0.12522396445274353, -0.015758058056235313, 0.19677142798900604, 0.49022287130355835, -0.1847405731678009, -0.08296503871679306, 1.1676682233810425, 0.40227895975112915, 0.77317351102828...
def test _ wait _ for _ notification _ after _ reload _ v5 ( ) : browser. open ('https : / / the - internet. herokuapp. com / notification _ message _ rendered') browser. wait. for _ ( lambda _ : ( browser. element ('[ href * = notification _ message ]'). click ( ), have. exact _ text ('action successful \ n×') ( brows...
[ 0.3231741786003113, 0.45851603150367737, 0.40639734268188477, 0.8959189057350159, 1.1407570838928223, -0.13205952942371368, 0.9321185350418091, 0.2925907373428345, -0.6531137824058533, -0.29363471269607544, -0.9372488856315613, -0.06029290333390236, 0.30770057439804077, -0.3130850791931152...
def test _ singletimetifftileprocessor _ process ( self ) : pp = self. config. path _ processor _ class pp. setup ( self. config. get _ path _ processor _ params ( ) ) tp = self. config. tile _ processor _ class tp. setup ( self. config. get _ tile _ processor _ params ( ) ) filename = pp. process ( 0, 0, 0, 0 ) handle...
[ 0.09674309194087982, 0.31077659130096436, 0.6481204628944397, -0.27308860421180725, 0.17435434460639954, 0.8689107298851013, 0.7416164875030518, 0.5177436470985413, 0.6384289860725403, 0.43330147862434387, -0.10041976720094681, 0.15708597004413605, -0.08137153834104538, 0.7851179242134094,...
def test _ blockheader _ to _ raw ( ) : for block, filename in testing _ utils. gen _ allblocks ( ) : rawblockheader = blockheader _ to _ raw ( block ) assert rawblockheader = = block ['rawblockheader'], ( f'{ filename } error in blockheader _ to _ raw')
[ 0.01983742043375969, -0.6286149621009827, 0.6550727486610413, 0.25528767704963684, -0.030395345762372017, 0.0010889434488490224, -0.12263984233140945, -0.21913984417915344, -0.28278282284736633, 0.1796804517507553, -0.7778609395027161, -0.467946320772171, 0.5109730362892151, -0.00925485230...
def contains _ semver ( iri : str ) - > bool : return _ match _ any _ part ( iri, semver _ pattern )
[ 0.1170896515250206, -0.2494155317544937, 0.37722522020339966, 0.7667427062988281, -0.7217967510223389, -0.5660420656204224, 0.3222593665122986, 0.06548847258090973, 0.7980660796165466, 0.29755204916000366, -0.4220215380191803, -0.5334030389785767, -0.8449196815490723, 0.5886116027832031, ...
def test _ udp _ reachable _ node ( raiden _ network, skip _ if _ not _ udp ) : # pylint : disable = unused - argument app0, app1 = raiden _ network ping _ message = ping ( nonce = 0, current _ protocol _ version = 0 ) app0. raiden. sign ( ping _ message ) ping _ encoded = ping _ message. encode ( ) messageid = ( " pin...
[ -0.5219719409942627, 1.1127986907958984, 0.6992828845977783, 0.07546176016330719, 0.4501071274280548, 0.642349123954773, 0.07402318716049194, 0.4688825011253357, -0.32543817162513733, 0.12344465404748917, -0.1289760172367096, -0.045816536992788315, -0.004336549434810877, -0.784500241279602...
def rarefaction _ analysis ( tbl, ns = [ ], nsample = 16, include _ all = true ) : result = [ ] if not ns : ns = range ( tbl. shape [ 0 ] ) if include _ all : ns = list ( ns ) + [ tbl. shape [ 0 ] ] for n in ns : for _ in range ( nsample ) : result. append ( ( n, single _ rarefaction ( tbl, n = n ) ) ) return pd. dataf...
[ -0.06638327240943909, 1.0980662107467651, 0.39309874176979065, 1.1603204011917114, 0.07452798634767532, -0.9519120454788208, 0.72556471824646, 0.3922477662563324, 0.5478817820549011, -0.5326699018478394, -0.49660566449165344, 0.19721658527851105, 0.2421789914369583, 0.7358935475349426, -...
def show _ all ( self ) : return self. _ get _ all _ str ( )
[ 0.07520715892314911, -0.3856642544269562, 0.5406977534294128, -0.11835046857595444, -0.6222098469734192, 0.3011312186717987, -1.1505874395370483, -0.1405305415391922, 0.39657142758369446, 0.3510209918022156, 0.4538488984107971, 1.2133756875991821, 0.35767632722854614, 0.6271401643753052, ...
def _ select _ param _ vectors ( self, x _ test, sigma, num _ parameters ) : indices = np. random. choice ( x _ test. shape [ 0 ], size = num _ parameters, replace = false ) self. _ test _ vectors = x _ test [ indices, : ]. copy ( ) self. _ phi _ fitted = true
[ -0.17519423365592957, -0.11594995111227036, 0.23164421319961548, 0.09638486802577972, 0.6511707305908203, -0.181728333234787, 1.0005788803100586, 0.18385547399520874, 1.0118143558502197, 0.6646342873573303, -0.014131836593151093, 1.2608996629714966, -0.7418193221092224, -0.3018725216388702...
def search _ molecid ( molec ) : try : hitf = molec. split ( " _ " ) molecid = int ( hitf [ 0 ] ) return molecid except : print ( " warning : define molecid by yourself. " ) return none
[ 0.22844867408275604, -0.8410208225250244, 0.5521634221076965, -0.7942662239074707, -0.24660877883434296, -0.621755838394165, 0.64698725938797, -0.4563989043235779, -0.39544248580932617, -0.4582568109035492, 0.0647478997707367, 0.20190206170082092, -0.7757647037506104, -0.35333192348480225,...
def topological _ sorting ( ) : topologicalsortedlist = [ ] def visit _ node ( n ) : " " " desde el node " n ", visita cadascun dels seus veins, i els marca com a visitats. " " " g. add _ node ( n, visited = true ) for neighbor in g [ n ] : if not'visited'in g. node [ neighbor ] : visit _ node ( neighbor ) topologicals...
[ -0.40994080901145935, 0.7012850046157837, 0.5862627029418945, -0.3702847361564636, -0.11741120368242264, 0.26286306977272034, 0.29657453298568726, -0.8885046243667603, -0.5978639125823975, 0.28157663345336914, 0.2079003006219864, 0.33631134033203125, 0.16769170761108398, 0.1551662087440490...
def get _ default _ gateway _ linux ( ) : with open ( " / proc / net / route " ) as fh : for line in fh : fields = line. strip ( ). split ( ) if fields [ 1 ]! ='00000000'or not int ( fields [ 3 ], 16 ) & 2 : continue return socket. inet _ ntoa ( struct. pack ( " < l ", int ( fields [ 2 ], 16 ) ) )
[ 0.7668222188949585, 0.06780427694320679, 0.6489397287368774, -0.02967536821961403, 0.04214970022439957, -0.3290547728538513, -0.31683534383773804, 0.5630658864974976, -0.6829773783683777, -0.4795042872428894, -0.19517241418361664, -0.021761370822787285, -1.150424838066101, 1.54644536972045...
def media ( self ) : return edition. additional _ type _ to _ medium
[ -0.2568194568157196, -1.18259596824646, 0.1434151530265808, -0.2532859742641449, -0.044921450316905975, 0.8594180941581726, -0.18742628395557404, -0.5999049544334412, 1.4093658924102783, 0.14393335580825806, 0.8760812282562256, 0.6152094006538391, -0.24256570637226105, 0.7872947454452515, ...
def fetch _ promo _ imgs ( pk, promo _ img _ url, * * kw ) : website = website. objects. get ( pk = pk ) log. info ( u'[ website : % s ] fetching promo img for website ', website. name ) try : response = _ fetch _ content ( promo _ img _ url ) except exception, e : log. error ( u'[ website : % s ] failed to fetch promo...
[ -1.1991475820541382, 0.9154532551765442, 0.5041305422782898, 0.6421654224395752, -0.75357985496521, -0.1814587116241455, -0.20177073776721954, -0.10118213295936584, 0.5816460251808167, 1.349040150642395, -0.4452459216117859, -0.6223648190498352, -0.005870883818715811, 0.29314443469047546, ...
def dist _ line _ line ( src _ arr, tgt _ arr ) : return np. array ( sp. spatial. ckdtree ( src _ arr ). query ( tgt _ arr ) )
[ 0.2787039279937744, -1.2278087139129639, 0.3851270377635956, 0.0010171032045036554, 0.17118506133556366, 0.9024298191070557, -0.9267354607582092, 0.6654086112976074, 0.37588319182395935, 0.7261433601379395, 0.6256398558616638, 0.46889251470565796, 0.3934130072593689, 0.48635876178741455, ...
def spritenamechange ( self, p ) : self. spritename = p self. framecountchange ( str ( self. framecount ) ) return true
[ -0.64468914270401, 0.37214475870132446, 0.43831899762153625, -0.44527068734169006, -0.9598200917243958, 0.31071504950523376, -0.06426481902599335, 0.10493070632219315, 0.23560704290866852, 1.1316155195236206, -1.5031096935272217, 0.1768704205751419, -0.8740867972373962, 0.20087860524654388...
def create _ user ( self, email, password = none ) : if not email : raise valueerror ('users must have an email address') user = self. model ( email = self. normalize _ email ( email ), ) user. set _ password ( password ) user. save ( using = self. _ db ) return user
[ 0.05762563645839691, 0.24096117913722992, 0.19887155294418335, 0.36371541023254395, 0.6442779898643494, 0.4178759455680847, -0.4602983295917511, 0.4920736849308014, 0.30815157294273376, 0.1883070170879364, -0.471902996301651, -0.4650532305240631, -0.3198610246181488, -0.15413898229599, -...
def disabledinit ( self ) : pass
[ 0.4923785626888275, -1.6900285482406616, 0.1450405865907669, 0.6598008275032043, 0.35546743869781494, 1.2808701992034912, 1.0664947032928467, 0.8074889779090881, -0.3381851613521576, -1.1661690473556519, -1.4483835697174072, 0.2019413858652115, -1.05660080909729, 0.38340330123901367, -0....
def get _ all _ adjacent _ positions ( dimension, positions ) : adjacent _ positions = set ( ) positions = tuple ( positions ) if positions = = ( ) : return adjacent _ positions for i in positions : set. add ( adjacent _ positions, left ( dimension, i ) ) set. add ( adjacent _ positions, right ( dimension, i ) ) set. a...
[ -0.004957589786499739, 0.5043150186538696, 0.8078327178955078, 0.3662465214729309, -0.43182602524757385, 0.02329634316265583, 0.17459945380687714, -0.3458593785762787, -0.566887378692627, 0.30640721321105957, -0.04620521143078804, -0.981447696685791, -1.0071730613708496, 0.0626618340611457...
def add _ signature ( self, signature, dependencies = none ) : node = workflownode ( signature ) dependencies = dependencies if dependencies is not none else [ ] # if signature is already added then perhaps there is some bug in code if node. id in self. nodes : raise workflowexception ( " looks like signature'{ }'is al...
[ -0.5249757170677185, -0.07832181453704834, 0.27301815152168274, 0.20882052183151245, 0.25036346912384033, -0.09937292337417603, 0.1327103227376938, 0.40378445386886597, 0.9873006343841553, 0.06476618349552155, -0.6457290053367615, -0.6960494518280029, -0.8325299024581909, 0.55145263671875,...
def _ _ init _ _ ( self, name, ssn, address = " " ) : super ( ). _ _ init _ _ ( name, ssn, address ) self. courses = [ ]
[ 0.38439321517944336, 0.30896586179733276, 0.6898679137229919, 0.3955886960029602, 0.20365744829177856, 0.11109659075737, -0.6723358035087585, 0.3942596912384033, 1.278785228729248, -0.38557034730911255, -0.5014100670814514, 0.48120471835136414, 0.5761023759841919, 0.29536938667297363, -0...
def find _ all _ row _ parsing _ errors ( self ) : errors = [ ] for ( table _ name, rows ) in self. rows. items ( ) : for row in rows : if hasattr ( row,'parsing _ errors') : errors. extend ( row. parsing _ errors ) return errors
[ 0.2598586082458496, -0.14852626621723175, 0.35656246542930603, 0.35073763132095337, 0.09348825365304947, -0.15088367462158203, -0.6010987758636475, 0.6125643253326416, -0.09579378366470337, -0.11939419060945511, -0.3374084234237671, -0.4896426498889923, 0.08515608310699463, 1.6369804143905...
def hurwitz _ zeta ( s, x, prec = none, * * kwargs ) : if prec : deprecation ( 15095,'the syntax hurwitz _ zeta ( s, x, prec ) has been'' deprecated. use hurwitz _ zeta ( s, x ). n ( digits = prec )'' instead.') return hurwitz _ zeta _ func ( s, x ). n ( digits = prec ) return hurwitz _ zeta _ func ( s, x, * * kwargs )
[ 0.037785135209560394, -0.3112335503101349, 0.28004753589630127, 0.7398867607116699, -0.5167367458343506, -1.2650948762893677, -0.6962763667106628, 0.7177640199661255, 0.4786668121814728, -0.7045109272003174, -0.12030105292797089, 0.40866726636886597, 1.056048035621643, -0.4412991404533386,...
def is _ valid _ hash ( _ hash : str ) - > bool : if isinstance ( _ hash, str ) and len ( _ hash ) = = 66 : prefix, body = _ hash [ : 2 ], _ hash [ 2 : ] return prefix = ='0x'and is _ lowercase _ hex _ string ( body ) return false
[ -0.16831518709659576, -0.3336808681488037, 0.5781265497207642, 0.33633530139923096, -0.22569376230239868, 0.7944765686988831, -1.113635778427124, 0.048863187432289124, 0.28129589557647705, -0.7486062049865723, -0.05700984224677086, 0.27279484272003174, -0.4156208634376526, 0.20273683965206...
def us2power ( us ) : transmission = 0. 157 # transmission of partial reflector slope = 0. 55 threshold = 4. 8 return transmission * slope * ( us - threshold )
[ 0.677738606929779, 0.07156121730804443, 0.63424152135849, -0.18313080072402954, -0.09848659485578537, -0.3002980649471283, 0.19320139288902283, -0.5534105896949768, 0.590425431728363, 0.4493802785873413, -0.5989343523979187, -0.31539446115493774, 0.06314540654420853, -1.0470595359802246, ...
def alpha ( self, degree, dart ) : return self. alphas [ degree ] [ dart ]
[ -1.1960322856903076, -0.6859423518180847, 0.24966812133789062, -1.013805627822876, -0.3514762818813324, 1.1449508666992188, -0.7633500099182129, 0.22955286502838135, -0.2916213870048523, 0.6603459715843201, 0.8243802189826965, 0.6903140544891357, 0.4577210247516632, 0.10830380767583847, ...
def _ prepare _ invoice _ line ( self, qty ) : res = super ( saleorderline, self ). _ prepare _ invoice _ line ( qty ) return res
[ -0.6170759201049805, -0.7805248498916626, 0.4074535369873047, 0.20766830444335938, -0.029123522341251373, -0.9575602412223816, -1.3455488681793213, -1.583067536354065, 0.9989076256752014, -0.7719078063964844, -0.6461319923400879, -0.717220664024353, 0.3221200406551361, -0.45588839054107666...
def frame ( fec, crc ) : preamble = 0xfaaaaaaa sync = 0x1234 footer = 0x110 return ( preamble < < 168 | sync < < 152 | fec < < 28 | crc < < 12 | footer )
[ 0.5734868049621582, 1.039929747581482, 0.4375298321247101, 0.14565199613571167, 0.687572181224823, -0.7149614095687866, -0.31822603940963745, -0.2596960663795471, -0.15186543762683868, -0.6200236678123474, 0.17541784048080444, 0.5648176670074463, -0.21280089020729065, 0.44046396017074585, ...
def proximityhandler ( self, proximityquery, distance, isphrase ) : termpair = proximityquery. split ( ',') term1 = termpair [ 0 ]. strip ( ) # extract term 1 term2 = termpair [ 1 ]. strip ( ) # extract term 2 dict1 = self. ii. gettermdocumentdictionary ( self. preprocessedterm ( term1 ) ) dict2 = self. ii. gettermdocu...
[ -0.15019460022449493, -0.827261745929718, 1.061848759651184, -0.3410792350769043, -0.6673721671104431, 0.5434911251068115, -0.4614453613758087, 0.19120007753372192, 0.11428719013929367, 0.3281000852584839, 0.38567614555358887, -0.5427818894386292, -1.575416088104248, 0.022773731499910355, ...
def generate _ itaac _ effort _ str ( itaac _ id, effort _ id, effort _ type, effort _ range ) : effort _ range = list ( effort _ range ) actual = random. choice ( effort _ range ) estimate = random. choice ( effort _ range ) return ( f'\ n { effort _ id } |'f'{ itaac _ id } |'f'{ effort _ type } |'f'{ actual } |'f'{ e...
[ -0.33316394686698914, -1.0276117324829102, 0.5651456117630005, -0.7176704406738281, 0.44026434421539307, 0.4018479585647583, -0.19468383491039276, -0.7623485922813416, -0.15221859514713287, 0.6311935186386108, 0.6734357476234436, 0.2316734492778778, -0.3661198019981384, -0.1069725006818771...
def _ mgui _ get _ width ( self ) - > int : return self. _ qwidget. width ( )
[ -0.1848948895931244, 0.3041541278362274, 0.3120879530906677, -0.20088854432106018, -0.24022960662841797, 0.1976325362920761, 0.20252330601215363, -0.34675562381744385, -0.06602358818054199, -1.1746195554733276, 0.07956287264823914, -0.138945072889328, -0.42272478342056274, 0.43570968508720...
def _ configlogger ( verbosity ) : levels = { 0 : logging. warning, 1 : logging. info, 2 : logging. debug } logfmt = " % ( asctime ) s [ % ( levelname ) s ] % ( name ) s : % ( message ) s " logging. basicconfig ( level = levels. get ( verbosity, logging. debug ), format = logfmt )
[ -0.1815558671951294, -0.3268429934978485, 0.6769537925720215, -0.3655416965484619, -0.22281837463378906, -0.6288737058639526, -2.091205596923828, 0.15641731023788452, -0.9862396121025085, 0.8952191472053528, -0.24965612590312958, -0.5320534706115723, 0.5958614945411682, 0.9807336926460266,...
def prep _ true ( self ) : self. obs _ seen = [ true for i in range ( self. num _ q _ functions ) ]
[ -0.3791322708129883, 0.9829069375991821, 0.5367244482040405, -0.29214754700660706, 0.09006775170564651, -0.08426645398139954, 0.1758662462234497, 0.42474889755249023, 0.11753098666667938, 0.03511054813861847, -1.2856570482254028, 0.6924355030059814, 0.49508240818977356, -0.0362218059599399...
def _ check _ arg _ boolean ( arg, name ) : assert is _ bool ( arg ), " argument'{ }'should be a boolean ". format ( name ) return arg
[ 0.009010880254209042, -0.09885173290967941, 0.31053125858306885, 0.3038954436779022, 0.19156290590763092, 0.8287582397460938, -0.2517372667789459, 0.8576834201812744, -0.32026854157447815, 1.4521865844726562, 0.025288904085755348, 0.6372730135917664, -0.4425828456878662, 0.1453627794981002...
def _ queue ( self ) - > " asyncio. queue [ tuple [ t, asyncio. future [ r ] ] ] " : return asyncio. queue ( )
[ -0.9632378816604614, -0.1825072318315506, 0.4776768088340759, -0.4405331015586853, 0.2786654829978943, -0.7744878530502319, -1.251426339149475, 0.4979515075683594, -0.534366250038147, 0.15988945960998535, 0.2516290247440338, -0.07422192394733429, 1.2929327487945557, -0.4403415620326996, ...
def findbestneighbor ( neighbors ) : startbest = neighbors [ 0 ] bestvalue = startbest. getvalue ( ) bestneighs = [ startbest ] for neigh in neighbors : value = neigh. getvalue ( ) if value > bestvalue : bestneighs = [ neigh ] bestvalue = value elif value = = bestvalue : bestneighs. append ( neigh ) bestneigh = random....
[ 0.035653479397296906, -0.6843645572662354, 0.6176998615264893, 0.8085668683052063, -0.22421008348464966, 0.5473148822784424, -0.12030882388353348, -0.4904943108558655, -0.11935819685459137, -0.1745375543832779, -0.33119720220565796, 0.9569471478462219, 0.062193311750888824, 0.3827937543392...
def volume _ min ( ) : key. volume _ set ( 0 )
[ 0.53329998254776, -1.2458053827285767, 0.2852948009967804, 0.23650380969047546, 0.49365732073783875, -0.22916866838932037, -0.7188758850097656, -0.26436647772789, -0.6291072964668274, 0.06376414000988007, 0.6127032041549683, 0.5233392119407654, -0.9352128505706787, -0.2964133322238922, 0...
def _ is _ time _ to _ send ( self ) : if not self. can _ send _ msg ( ) : return false curr _ time = time. time ( ) if not self. last _ sent _ time _ msg : self. last _ sent _ time _ msg = curr _ time return true if ( curr _ time - self. last _ sent _ time _ msg ) > self. settings. get _ sender ('telegram ','interval ...
[ -0.8383511900901794, 0.38113898038864136, 0.7207583785057068, 0.005968548823148012, 0.1037055104970932, 0.36151808500289917, 0.07694099098443985, -0.775296151638031, -0.7406745553016663, 1.4897570610046387, -0.40936243534088135, -0.2454301118850708, -0.7854224443435669, 0.9861228466033936,...
def test _ coherency _ calc _ errors ( ) : coord = skycoord ( ra = 30. 0 * units. deg, dec = 40 * units. deg, frame = " icrs " ) stokes _ radec = [ 1, - 0. 2, 0. 3, 0. 1 ] * units. jy source = skymodel ( name = " test ", ra = coord. ra, dec = coord. dec, stokes = stokes _ radec, spectral _ type = " flat ", ) with pytes...
[ 0.8892127275466919, 0.4343395233154297, 0.599209725856781, -0.38076335191726685, 0.6124141812324524, 1.026539921760559, 0.42268306016921997, -0.025204231962561607, -0.3837255835533142, -0.008193813264369965, -0.31682905554771423, -0.06183094158768654, 0.14825274050235748, 0.621170282363891...
def word _ add ( ) : if request. method = = " post " : req = json. loads ( request. data ) if int ( req ['userid'] ) : usr = user. user _ verificateion ( req ['userid'] ) if usr : dictionary = usr. user _ dict _ id _ is _ exist ( req ['dictid'] ) if dictionary : word = word. create _ or _ get _ word _ by _ value ( req ...
[ -0.442292720079422, 0.07864350825548172, 1.0552117824554443, 0.2835487425327301, 0.07098115235567093, 0.814423143863678, -0.14735698699951172, -0.35077646374702454, 0.18030454218387604, 0.7560845613479614, 0.015053455717861652, -0.27521395683288574, 0.07631076872348785, 0.9360960721969604,...
def _ _ process _ matches ( self, matches ) : # skip emty matches if not matches : return matches # sort matches according to starting position of their 1 - st # group and ending position of last group they capture matches. sort ( key = lambda match _ tuple : ( match _ tuple. gstart, match _ tuple. gend ) ) # intialize...
[ -0.5922244787216187, -0.12606513500213623, 1.011483073234558, 0.4034276008605957, -0.0134498942643404, 0.47522130608558655, 0.6905627250671387, -0.6288709044456482, -0.3103620409965515, 0.6095715165138245, 0.5089837908744812, -1.1241074800491333, -0.7313838601112366, 0.1783362478017807, ...
def _ merge _ multipart _ messages ( messages ) : all _ messages = [ ] multiparts = { } for m in messages : # if the message is a multipart message. if m ['message']. startswith ( multipart _ header ) : mes = m ['message']. strip ( multipart _ header ) # we retrieve the message id and the actual # message. id, mes = me...
[ -0.2821277678012848, -0.28452736139297485, 0.6980480551719666, -0.4294312596321106, -0.12155187129974365, -0.12433600425720215, -0.8172897100448608, -1.1104824542999268, -0.1629248708486557, 0.15870095789432526, -0.3082907199859619, -0.5713033080101013, -1.0351982116699219, 0.7754000425338...
def heapentropy ( self, pid = none ) : log. debug ( " executing volatility heapentropy plugin on " " { 0 } ". format ( self. memdump ) ) self. _ _ config ( ) results = [ ] if pid is not none : self. config. pid = pid command = self. plugins [ " heapentropy " ] ( self. config ) entropies = [ ] for proc, entropy in comma...
[ -0.46621912717819214, -0.7655032873153687, 0.4751492440700531, -0.6061558127403259, 0.7067953944206238, -0.685620129108429, -1.1199082136154175, 0.9907354712486267, 0.6344537734985352, 0.5809973478317261, -0.5801005959510803, 0.5544185042381287, -0.37060439586639404, 0.7824294567108154, ...
def prepare _ for _ submission ( self, folder ) : calcinfo = super ( ). prepare _ for _ submission ( folder ) calcinfo. codes _ run _ mode = datastructures. coderunmode. serial parent _ calc _ folder = self. inputs. parent _ folder calcinfo. remote _ copy _ list. append ( ( parent _ calc _ folder. computer. uuid, str (...
[ -0.1751696765422821, 0.04218076914548874, 0.5067958831787109, -0.37456271052360535, -0.9510902762413025, 0.8702787160873413, 0.3704456090927124, 0.12160158902406693, -0.5775063633918762, -0.5136650204658508, -0.4473796784877777, -0.3022899627685547, 0.15181154012680054, 0.5855839848518372,...
def transform ( self, x : np. ndarray ) - > np. ndarray : check _ is _ fitted ( self ) x = check _ array ( x ) self. _ check _ n _ features ( x, reset = false ) return self. _ transformation ( x )
[ -1.0634379386901855, -0.0029607287142425776, 0.36381861567497253, 0.5314576029777527, 0.16112039983272552, -0.4310159683227539, 0.004337233491241932, -0.49259307980537415, 0.9963856935501099, -0.10825268179178238, -1.238159418106079, 0.9364617466926575, -0.11613165587186813, 0.044204328209...
def ismacrotool ( self, isinput ) : return false
[ -0.7038947939872742, 0.3354056775569916, 0.46222859621047974, 1.198992371559143, -0.7380519509315491, 0.6397674679756165, 0.0868973359465599, -0.9168694615364075, 0.40939009189605713, -0.74512779712677, 0.3072141110897064, 0.3185006380081177, -0.988303005695343, 0.44884786009788513, -1.5...
def split _ relations ( df ) : def _ extract _ doi ( dl ) : dl = get _ doi ( dl ) return dl [ 0 ] if len ( dl ) > 0 else'' def _ extract _ same _ as ( dl, ignore _ url = cfg. source _ namespace, doi ='' ) : dl = get _ descriptors _ uris ( dl, prefix = " http " ) dl = list ( filter ( lambda x : ignore _ url not in x, dl...
[ -0.7155902981758118, 0.7645851969718933, 0.31371429562568665, -0.9180213212966919, 0.5494715571403503, -0.028002586215734482, 0.9793999195098877, 0.3634226620197296, 0.8907508850097656, -0.1763642132282257, 0.18411526083946228, -0.019789064303040504, -0.7673661708831787, 0.1875156313180923...
def _ _ str _ _ ( self ) : return " { } ( control = { }, treated = { } ) ". format ( self. _ _ class _ _. _ _ name _ _, self. learner _ c. _ _ class _ _. _ _ name _ _, self. learner _ t. _ _ class _ _. _ _ name _ _, )
[ 0.9212725758552551, -2.054997682571411, 0.7550839185714722, -1.734640121459961, 0.3205987513065338, 0.49022236466407776, -0.4287838339805603, -0.5312790274620056, -0.05202024430036545, -0.4254736304283142, -0.13421383500099182, 1.259039282798767, 0.3633723855018616, 0.033478934317827225, ...
def create _ all _ wing _ infos ( degen _ mgr : dg. degengeommgr, settings : charmrotorsettingscollection ) : wing _ infos = [ ] for wing _ id, degen _ component in degen _ mgr. degen _ objs. items ( ) : typ _ name = vsp. getgeomtypename ( wing _ id ) if typ _ name! = " wing " : continue wing _ infos. extend ( create _...
[ -0.25370320677757263, -0.15920494496822357, 0.22569620609283447, 0.02159503661096096, 0.8687126040458679, 1.0578300952911377, -0.6022440195083618, -0.7533114552497864, -0.7375292181968689, -0.18733511865139008, -0.34835612773895264, 0.19455531239509583, -0.10131431370973587, 2.093995094299...
def agg _ list ( self ) - > dataframe : return self. select _ all ( ). agg _ list ( )
[ -0.2697369456291199, 1.0566484928131104, 0.3429279923439026, -0.017577391117811203, 0.5376707911491394, -0.8623409271240234, -0.7332798838615417, 0.7050797343254089, -0.08984952419996262, -0.12475749105215073, 0.40498086810112, 0.7675343155860901, 0.3864821791648865, -0.07527510076761246, ...
def sample _ years ( self, n = 1 ) : return [ self. years [ i ] for i in self. sample ( n ) ]
[ -0.46435725688934326, 0.09284280240535736, 0.5689467787742615, 0.27466729283332825, -1.2128735780715942, 0.6722726225852966, -0.7021859288215637, -0.5390192270278931, 1.1927803754806519, 0.8995091915130615, -0.9002063870429993, 0.1549386978149414, -0.12637537717819214, 0.3576221168041229, ...
def ktadd ( self, principal, rekey, path _ keytab ) : opts = [ ] if not rekey : opts. append ( " - norandkey " ) return self. exec _ kadmin ( " ktadd { opts } - k { path } { principal } @ { realm } ". format ( \ opts = " ". join ( opts ), path = path _ keytab, principal = principal, realm = self. realm ) )
[ 0.09532144665718079, -0.10837498307228088, 0.6412515044212341, 0.7362972497940063, -0.011984141543507576, 0.9861010909080505, -0.3993135988712311, -0.08955561369657516, -0.01676076278090477, 0.3515418767929077, 0.7521853446960449, 0.932510495185852, -1.0953348875045776, 0.00892824586480856...
def _ _ bool _ _ ( self ) : return self. _ _ valid
[ -0.403778076171875, -1.1579046249389648, 0.6535502672195435, 0.030112827196717262, -0.44095057249069214, 1.2954005002975464, -0.3823079764842987, 0.827608585357666, 0.48738738894462585, -0.9176895022392273, -0.23309466242790222, -0.1663437783718109, -0.574026346206665, -1.176316261291504, ...
def merge ( self, child ) : for key in self. stats : self. stats [ key ] + = child. get ( key )
[ 0.20711658895015717, 0.6347491145133972, 0.6600016355514526, -0.5810139775276184, 0.2796192765235901, 0.662385106086731, -0.8902353644371033, -0.852699875831604, 0.042810555547475815, -0.8864725232124329, -1.1081432104110718, -0.553073525428772, 0.24374520778656006, 0.36550408601760864, ...
def scale _ on _ 2d ( x2d, scaler ) : return scaler. transform ( x2d )
[ -0.5578485131263733, -1.4432586431503296, 0.34767523407936096, -0.3356526494026184, -1.6040356159210205, -0.47100362181663513, -2.35837984085083, -1.3419289588928223, -1.6320526599884033, 0.7443783283233643, -0.03931008279323578, -0.023173032328486443, 0.5639806389808655, 0.896838784217834...
def _ _ init _ _ ( self ) : # cache operation to do before doing the chrome navigation. self. cache _ operation = cacheoperation. clear # the cache archive's path to save to or push from. is str or none. self. cache _ archive _ path = none # list of additional chrome command line flags. self. chrome _ args = [ ] # cont...
[ -0.5972049832344055, 0.29362985491752625, 0.5870219469070435, 0.06628234684467316, 0.9519964456558228, -0.4333797097206116, 0.85817950963974, -0.04460594803094864, -0.004923118278384209, 0.14499546587467194, -0.3861597776412964, 0.5938781499862671, -0.42699792981147766, 0.9583725333213806,...
def open ( self ) : raise notimplementederror ( " method'open ( )'not implemented. " )
[ -0.8792458176612854, -0.26408064365386963, 0.30214959383010864, 0.2608489692211151, -0.6674081087112427, 1.169836163520813, 1.0821709632873535, 0.7670646905899048, -0.10173490643501282, -0.99907386302948, 0.03236059471964836, 0.24443797767162323, 0.26413655281066895, 0.291839599609375, -...
def placewidgets ( self ) : # # # # create canvas for sprite self. pixelcanvasframe = ttk. frame ( self. root ) self. pixelcanvasframe ['padding'] = ( 10, 10 ) self. pixelcanvasframe. grid ( row = 0, column = 0, rowspan = 1, sticky = ( n, s, e, w ) ) self. pixelcanvas = canvas ( self. pixelcanvasframe, width = self. ca...
[ 0.0157525185495615, 0.1138884648680687, 1.1305580139160156, -0.8159433603286743, -0.6364730596542358, -0.12973405420780182, 1.279111623764038, 0.24895629286766052, 0.43097591400146484, 0.13093504309654236, 0.1700378656387329, 0.04655344411730766, -0.35396280884742737, 0.7737156748771667, ...
def contact _ phone ( self, contact _ phone ) : if contact _ phone is not none and len ( contact _ phone ) > 20 : raise valueerror ( " invalid value for ` contact _ phone `, length must be less than or equal to ` 20 ` " ) # noqa : e501 self. _ contact _ phone = contact _ phone
[ 0.22495496273040771, -0.21587681770324707, -0.1541992574930191, 0.19431008398532867, 0.36422228813171387, 0.9176729321479797, 0.5031498074531555, 0.2775038182735443, -0.08090312778949738, 0.5079919099807739, -0.4087187945842743, -1.702284574508667, 0.2303742617368698, 0.17729999125003815, ...
def add _ post ( heading, category, text, date = dt. datetime. now ( ), comments = [ ] ) : meta = { " heading " : heading, " url _ heading " : psblog. urlify ( heading ), " category " : category, " datetime " : date } post _ id = psblog. post _ id ( meta ) psblog. save _ text ( text, post _ id ) psblog. save _ meta ( m...
[ 0.16131938993930817, 0.5745729207992554, 0.6304460763931274, 0.6411483287811279, 0.20663957297801971, 0.8540663123130798, -1.3380104303359985, 0.7337701916694641, -0.9635376930236816, -0.049197968095541, -0.8198712468147278, -0.493448942899704, -0.3966602683067322, 0.19841347634792328, -...
def _ build _ tpf ( self, cube _ fits, img _ cube, uncert _ cube, cutout _ wcs _ dict, aperture ) : # the primary hdu is just the main header, which is the same # as the one on the cube file primary _ hdu = cube _ fits [ 0 ] self. _ update _ primary _ header ( primary _ hdu. header ) cols = list ( ) # adding the cutout...
[ -0.17027562856674194, -0.3105042576789856, 0.6775969862937927, -0.579290509223938, 0.09229979664087296, -0.48312538862228394, 0.35550662875175476, 0.3042917251586914, -0.6497290730476379, 0.1017620712518692, 0.4102005362510681, -0.16437822580337524, 0.09481947869062424, 0.3433969020843506,...
def find _ cuda _ path ( ) : if " cuda _ path " in os. environ : return os. environ [ " cuda _ path " ] cmd = [ " which ", " nvcc " ] proc = subprocess. popen ( cmd, stdout = subprocess. pipe, stderr = subprocess. stdout ) ( out, _ ) = proc. communicate ( ) out = py _ str ( out ) if proc. returncode = = 0 : return os. ...
[ 0.5605339407920837, -0.4866299331188202, 1.0455958843231201, 0.8753463625907898, -0.18331597745418549, -0.3700926601886749, 0.9397926330566406, -1.0814499855041504, -0.44191092252731323, 0.06895333528518677, 1.4101760387420654, 0.12239041179418564, -0.694643497467041, 1.147843837738037, ...
def get ( resource _ name : str, id : pulumi. input [ str ], opts : optional [ pulumi. resourceoptions ] = none ) - >'sqlresourcesqlcontainer': opts = pulumi. resourceoptions. merge ( opts, pulumi. resourceoptions ( id = id ) ) _ _ props _ _ = sqlresourcesqlcontainerargs. _ _ new _ _ ( sqlresourcesqlcontainerargs ) _ _...
[ 0.25349870324134827, -0.6164490580558777, 0.3407902717590332, -0.7060233354568481, -0.6548765301704407, 0.19254076480865479, -1.3946210145950317, -0.19796492159366608, 0.6543299555778503, -0.6661545038223267, 0.03406696766614914, 0.162995845079422, -0.03713255748152733, -0.6081113219261169...
def identify _ pareto ( scores, population _ ids ) : population _ size = scores. shape [ 0 ] # create a starting list of items on the pareto front # all items start off as being labelled as on the parteo front pareto _ front = np. ones ( population _ size, dtype = bool ) # loop through each item. this will then be comp...
[ 0.03754805773496628, -0.9788178205490112, 0.5938807129859924, 0.461246520280838, 0.17754842340946198, 0.33276990056037903, 0.27551165223121643, -0.16369087994098663, 0.1482100635766983, 1.1238019466400146, -0.0880851298570633, 0.06082848086953163, -0.055486537516117096, -0.1548153758049011...
def generate _ csv ( ) : client = storage. client. from _ service _ account _ json ( " service _ account. json " ) bucket = client. get _ bucket ( " shopify1 " ) dataset = bucket. list _ blobs ( ) data = [ ] for blob in dataset : splits = blob. name. split ( " / " ) if len ( splits )! = 4 : continue label = splits [ 2 ...
[ -0.6977059245109558, -0.1246337816119194, 0.5423458814620972, 0.7176512479782104, 0.1777857095003128, -0.21136438846588135, -0.18148121237754822, 0.1935252994298935, -0.09536921232938766, -0.16584904491901398, -0.31702834367752075, 1.0556597709655762, 0.7546860575675964, 0.2381137907505035...
def test _ offer _ worker ( self ) : person _ identifier = { " universalid " : " qq123456c ", " id " : " 123e4567 - e89b - 12d3 - a456 - 426655440000 " } headers = {'content - type':'application / json ','authorization':'bearer special - key ', } response = self. client. open ('/ vms / api / v1 / bookingrequests / { bo...
[ -0.8211036324501038, 0.3628859519958496, 1.1697564125061035, 0.4796385169029236, -0.2872893512248993, 1.590413212776184, 0.7667219042778015, 0.3011326789855957, -0.03690008446574211, 0.08763057738542557, -1.0907834768295288, 0.29482612013816833, -1.2492952346801758, 0.09817524999380112, ...
def data _ file _ uploader ( uid : str, pid : str, sheet _ name : str = none ) - > dict : response = { " error " : " " } if'file'not in request. files : response [ " error " ] ='no file part'else : file = request. files ['file'] if file. filename = ='' : response [ " error " ] ='no file selected for uploading'if file a...
[ -0.7365558743476868, -0.679068922996521, 0.9026540517807007, 0.23952412605285645, -0.19673506915569305, 0.3665534555912018, -0.7272112965583801, 0.18716898560523987, -0.7399519681930542, 0.17280803620815277, -0.10531619936227798, -0.25455060601234436, 0.07581280171871185, 0.486515343189239...
def read ( self, noret = false ) : darr = [ ] uarr = [ ] barr = [ ] earr = [ ] with open ( self. bar _ file,'rb') as f : lastpx = none while true : day, utc, bcols, ecols = self. _ read _ day ( f, lastpx = lastpx ) if day is not none : print ('read day ', day,'', len ( utc ),'bars. ','has ext : ', ecols is not none ) i...
[ -0.6190288066864014, 0.22339202463626862, 0.6145012974739075, -0.5737738013267517, 0.47010916471481323, 0.9691662192344666, 0.3156478703022003, -0.5844812393188477, -0.750673770904541, -0.035989511758089066, 0.9500818848609924, 0.01860714703798294, -0.7795695662498474, 0.2322414219379425, ...
def test _ series _ compare _ masked _ vs _ masked ( op ) : def func ( x ) : return op ( x, x ) data = cudf. series ( [ 1, cudf. na, 3 ] ) run _ masked _ udf _ series ( func, data, check _ dtype = false )
[ -0.024475153535604477, 0.7777945399284363, 0.2636123299598694, 1.22072172164917, 0.46258583664894104, 0.35284677147865295, 1.5041165351867676, -0.79459547996521, 1.0724282264709473, -0.11969561129808426, -0.6897726058959961, 0.9106364846229553, 0.7043075561523438, -0.9807982444763184, -0...
def reconfig _ dfe _ set _ tap _ 1 ( fpgaid, data, verbose = 1 ) : if ( verbose & 1 ) = = 1 : print " " " specifies the coefficient for the first post tap. the valid range is 0 - 15. " " " reconfig _ dfe _ set _ indirect _ register ( fpgaid, 1, data, verbose ) if ( verbose & 1 ) = = 1 : print " = " * 30 if ( verbose & ...
[ -0.6028000712394714, 0.47227489948272705, 0.6227906346321106, -0.010520481504499912, -0.02288210764527321, 0.143626868724823, 0.6679769158363342, -0.00493350625038147, -0.16991551220417023, 0.0752069428563118, 0.049843259155750275, 0.7867333889007568, 0.4180433452129364, 0.6960884928703308...
def set _ widget _ read _ only ( widget, read _ only = true ) : # we don't have to do anything with labels if not isinstance ( widget, qtwidgets. qlabel ) : # check if we have readonly method if hasattr ( widget,'setreadonly') : widget. setreadonly ( read _ only ) # if not, just disable else : widget. setenabled ( not ...
[ -0.19161462783813477, -0.23352505266666412, 0.5690121650695801, -1.0775539875030518, -0.2918345332145691, 0.8082075715065002, -0.8524948954582214, 1.1591876745224, 0.6767517924308777, 0.2652449309825897, 0.5906440615653992, 0.40953686833381653, 0.1366751790046692, 1.2879247665405273, -0....
def test _ claims _ expired _ unapproved _ locks ( self ) : # note this should never actually happen because we release the lock # when we approve a page mission = missionfactory ( ) pages = pagefactory. create _ batch ( 1, mission = mission ) users = userfactory. create _ batch ( 2 ) page. objects. filter ( pk = pages...
[ 0.8561305403709412, 0.08353649079799652, 0.5716127157211304, 0.01796749420464039, -0.37695905566215515, 1.0541692972183228, -1.8104294538497925, 0.0537610799074173, -0.5005485415458679, -0.010260128416121006, 0.9385315179824829, 0.6358776092529297, -0.17886701226234436, -0.2118221372365951...
def _ _ init _ _ ( self, description ='', start _ state ='q0 ', accept _ state ='q1 ', reject _ state ='q2 ', alphabet = [ symbol ('0'), symbol ('1') ], num _ tapes = 1, tape _ alphabets = none, blank _ symbol = symbol ('b'), init _ source = none ) : self. num _ tapes = num _ tapes self. alphabet = alphabet # blank for...
[ -0.06565447896718979, -0.02230626530945301, 0.7249875664710999, -0.5891011953353882, -0.48662588000297546, -0.03827320411801338, 0.6048393249511719, 0.041500985622406006, 0.19487519562244415, -0.27369043231010437, -0.7471175193786621, -0.2765599489212036, 0.2648618817329407, 0.524242520332...
def test _ allowed _ exception _ 201 ( settings, finder ) : with pytest. raises ( finderexception ) : finder. is _ allowed ( " / foo. scss ", excludes = [ ] )
[ 0.3691141605377197, 0.9581086039543152, 0.2736765146255493, 0.723756730556488, -0.9451306462287903, 0.7821868658065796, 0.10043620318174362, -0.18465323746204376, 0.4224191904067993, 0.4118427336215973, 0.43592530488967896, 0.10916328430175781, -0.06819985806941986, -0.34565988183021545, ...
def getalllogbookentriesbyuser ( self, username ) : message = dict ( ) if username! = none and not ( self. checkuserexists ( username ) ) : message [ " success " ] = false message [ " error " ] = " username doesn't exist. " return ( json. dumps ( message ) ) entries = list ( ) for entry in self. alllogbookentriesbyuser...
[ -1.1744232177734375, -0.17733390629291534, 0.6629992723464966, 0.6235716938972473, -0.641477644443512, 0.1496487855911255, 0.4152407646179199, -0.6936848163604736, -0.6083723306655884, 0.2960871458053589, -1.0121514797210693, 0.27248862385749817, -0.3872547447681427, 1.1504826545715332, ...
def set _ addresses ( self, name, ips ) : obj = self. get _ object ( name, false ) if obj is none : self. add _ object ( name ) obj = [ ] else : self. clear _ object ( name ) self. add _ address ( name, ips )
[ -1.1101865768432617, 0.2563088834285736, 0.5459880232810974, -0.3775375783443451, -0.01439103577286005, -0.9228677153587341, -0.6793941855430603, -0.1865348368883133, 1.01857590675354, 0.827110230922699, -0.9185757040977478, -0.006077988538891077, 0.2179141789674759, -0.5602836012840271, ...
def color ( self ) : return self. document. get _ style ('color')
[ 0.21911917626857758, -0.19510258734226227, 0.22412215173244476, 0.7205943465232849, 0.4923219680786133, 0.7065861225128174, 0.3129997253417969, 0.3839223086833954, 0.1181100532412529, 0.3064507842063904, 0.9345178008079529, 0.6446719765663147, -0.4717835783958435, 0.24455851316452026, -0...
def get _ r ( * args, * * kwargs ) : raise notimplementederror
[ -0.36517834663391113, 0.01082156877964735, 0.5049343109130859, 0.45817121863365173, 0.44371071457862854, -0.4707241952419281, -0.2924565374851227, -0.4915449321269989, -0.7093302607536316, -0.07201877981424332, -0.3326837718486786, 0.9304097294807434, -0.016734963282942772, -0.143456801772...
def post ( self, path, body ) : return self. request ('post ', path, body )
[ -0.5666413903236389, -0.08825109153985977, 0.4078608453273773, 0.5160261392593384, 0.635621964931488, 0.5582460165023804, -1.600560188293457, -0.6206102967262268, -0.2914140224456787, -0.8586719632148743, -0.3075169622898102, 0.5237061977386475, -1.126490592956543, -0.16300296783447266, ...