text
stringlengths
25
2.19k
embedding
listlengths
768
768
def dice _ metric ( y _ true, y _ pred ) : y _ true _ f = k. greater ( y _ true, 0. 5 ) y _ pred _ f = k. greater ( y _ pred, 0. 5 ) return dice ( y _ true _ f, y _ pred _ f )
[ 0.8650091290473938, -0.503025233745575, 0.44689977169036865, 0.5912101864814758, -1.0080788135528564, 0.7217676043510437, -0.13730724155902863, 0.2941097319126129, -1.3733683824539185, 0.7128112316131592, 1.0361192226409912, 1.0058971643447876, 1.102647066116333, 0.24151387810707092, -0....
def create _ service _ direct _ resource _ view ( request ) : service = ar. get _ service _ matchdict _ checked ( request ) resource _ name = ar. get _ multiformat _ post ( request, " resource _ name " ) resource _ display _ name = ar. get _ multiformat _ post ( request, " resource _ display _ name ", default = resourc...
[ 0.25671473145484924, -0.5093924403190613, 0.49133485555648804, -0.5130747556686401, -0.8530253767967224, 0.6103924512863159, 0.1018085703253746, -0.7214166522026062, -0.7928411960601807, -0.43950676918029785, 1.5944838523864746, 0.44203153252601624, 0.14493778347969055, 0.4762963354587555,...
def debug ( self, text, verbose = 3 ) : self. output. debug ( text, verbose )
[ 0.8082780241966248, 0.27839821577072144, 0.32358238101005554, 0.5119573473930359, 0.15549848973751068, 0.051310669630765915, -0.2823735475540161, 0.2681117653846741, -0.28898748755455017, 0.19358202815055847, 0.06524229794740677, 0.2524338960647583, -0.9401841163635254, 0.6218859553337097,...
def _ internal _ poll ( self, _ deadstate = none ) : if self. returncode is none : if waitforsingleobject ( self. _ handle, 0 ) = = wait _ object _ 0 : self. returncode = getexitcodeprocess ( self. _ handle ) return self. returncode
[ -0.5766839981079102, -0.662530243396759, 0.8042718768119812, -0.12257898598909378, -0.42442449927330017, 0.221806138753891, 0.5818437933921814, 0.1952126920223236, 0.3470788598060608, -0.05704091489315033, 0.8906633853912354, -0.3158591687679291, -0.6608298420906067, -0.38123512268066406, ...
def updatedateindex ( map, crime, tipo ) : occurreddate = crime [ tipo ] entry = om. get ( map, occurreddate ) if entry is none : datentry = newdataentry ( crime ) om. put ( map, occurreddate, datentry ) else : datentry = me. getvalue ( entry ) adddateindex ( datentry, crime, tipo ) return map
[ -0.2704896926879883, -0.6404767036437988, 0.4816727936267853, 0.06589864194393158, -0.19287876784801483, 0.8696770071983337, -0.006928538903594017, 0.5182483196258545, 0.6294625997543335, -0.021353518590331078, 0.25887295603752136, 0.7252482771873474, -0.2516363859176636, -0.04512125626206...
def isnotastopword ( self, word ) : if word in self. stopwords : return false return true
[ -1.492979645729065, -0.1879240721464157, 0.11976584792137146, 0.1705082803964615, -0.6857099533081055, 0.9674479365348816, -0.6475070118904114, -0.6483789086341858, -1.0739773511886597, 0.5416430830955505, -0.28647610545158386, -0.6796280741691589, -1.5049251317977905, 1.1224356889724731, ...
async def create _ event _ manager _ interview _ room ( self, guild : discord. guild, event _ manager _ app : list [ str ] ) - > none : event _ manager _ app _ cat = discord. utils. get ( guild. categories, id = self. event _ manager _ app _ cat _ id ) event _ manager = discord. utils. get ( guild. members, id = event ...
[ 0.8481450080871582, -0.44790512323379517, 0.8108823895454407, -0.18698245286941528, 0.029685700312256813, -0.22988060116767883, -1.1776846647262573, 0.42505159974098206, -0.5664902329444885, 0.574798583984375, 0.4775335490703583, 0.2841200530529022, -0.6519193649291992, 0.9851965308189392,...
def get _ unfiltered _ chars ( self, payload, ref _ payload, delim, tag, attr ) : ref _ chars = ref _ payload. replace ( delim,'' ). replace ('9 ','' ) fuzz _ chars = payload. replace ( delim,'' ). replace ('9 ','' ) remove _ chars = set ( [ ] ) unfiltered _ chars _ list = [ ] html _ entities = ['& # 39 ','& quot ; ','...
[ 0.3187798857688904, -0.12218762189149857, 0.8633745312690735, -1.1037334203720093, -0.9927279353141785, -0.4143661558628082, 0.34668147563934326, -0.28876689076423645, 0.07394691556692123, 0.5115979313850403, -0.1177084669470787, 0.7302873134613037, -0.1953989416360855, 0.7109044790267944,...
def draw _ fitregions ( self, trans ) : if self. _ fitr is not none : self. _ fitr. remove ( ) # find all regions regwhr = np. copy ( self. _ fitregions = = 1 ) # fudge to get the leftmost pixel shaded in too regwhr [ np. where ( ( self. _ fitregions [ : - 1 ] = = 0 ) & ( self. _ fitregions [ 1 : ] = = 1 ) ) ] = true s...
[ 0.305046409368515, 0.23753388226032257, 0.596530020236969, -0.35920941829681396, -0.3683263957500458, 0.702174186706543, 0.3138018846511841, -0.024602139368653297, 0.1719651222229004, -0.9356725811958313, 0.319580078125, 0.6052109599113464, -0.48742741346359253, 0.8697091937065125, -0.34...
def update _ occupancy _ rates ( ) : try : cronutils. require _ cron ( request. headers ) counts = parkingeventrepository ( ). get _ occuring _ paid _ event _ counts ( ) occupancyratesrepository ( ). refresh _ occupancies ( counts ) return'', 201 except cronutils. notcroncallerexception as e : logger. exception ( e ) a...
[ 0.3027026653289795, -0.31563103199005127, 0.6694157719612122, 0.3276308476924896, 0.11983301490545273, -0.37325945496559143, 0.05567238852381706, -0.261837363243103, -0.24783797562122345, 0.48978176712989807, 1.1457688808441162, -0.561408519744873, -0.5499093532562256, 0.2433755248785019, ...
def islocalhost ( ip ) : return ip in ('127. 0. 0. 1 ','localhost')
[ 0.35635867714881897, 0.3242814838886261, 0.3378358781337738, 0.7220133543014526, -0.971987783908844, -0.00537916412577033, -0.3511660397052765, 0.27684763073921204, 1.3705332279205322, 0.3000026345252991, 0.21231336891651154, -0.5300976037979126, -0.32443782687187195, -0.6071516275405884, ...
def _ translate _ _ interfaces _ interface _ carrier _ delay ( input _ yang _ obj, translated _ yang _ obj = none ) : if input _ yang _ obj. down. _ changed ( ) : input _ yang _ obj. down = input _ yang _ obj. down if input _ yang _ obj. up. _ changed ( ) : input _ yang _ obj. up = input _ yang _ obj. up if input _ yan...
[ -0.5534800887107849, -0.32715335488319397, 0.6034550070762634, -0.890222430229187, -0.13557080924510956, 0.320883572101593, 1.0506051778793335, -0.5632346868515015, 0.5605819821357727, -0.3421132564544678, -0.5545246601104736, -0.3166791498661041, 0.26929035782814026, 0.16005459427833557, ...
def set _ session _ hook ( self, hook ) : self. session _ hook = hook
[ -0.8772280812263489, -0.6700327396392822, 0.24047228693962097, 0.7511987090110779, 0.3938983380794525, 0.5311143398284912, 0.5305297374725342, -0.4781210124492645, 0.6686348915100098, 0.4393063485622406, -0.27922728657722473, 1.1561626195907593, -0.10202345252037048, -0.20049571990966797, ...
def create _ tensor ( t ) : return jnp. array ( t )
[ -0.5970449447631836, -0.4366872310638428, 0.10127253830432892, -1.0884990692138672, 0.29741114377975464, 0.10391314327716827, -0.11517377942800522, -0.9173622131347656, -0.6502805948257446, 0.5994873046875, -1.2819032669067383, 0.5702328085899353, 0.7557569146156311, -1.1891026496887207, ...
def get _ role _ by _ uid ( self, uid ) : user = user ( self. db, uid ) return role ( self. db, user. role _ id )
[ 0.6632041931152344, -0.31430572271347046, -0.14958040416240692, -0.37593913078308105, 0.5128539800643921, -0.06390973180532455, -0.8112828135490417, -0.5650004148483276, 0.7834399342536926, -0.5485191345214844, 0.5931224822998047, 0.547495424747467, -0.27642500400543213, 0.4778654575347900...
def read _ data ( self ) : if os. path. exists ( self. file _ name ) : with open ( self. file _ name,'rb') as f : try : self. data = json. load ( f ) except : self. data = none self. indexer. initialize _ index ( ) else : print ( " file does not exist " ) return none
[ -0.4247836172580719, -0.7967602014541626, 0.633300244808197, -0.5517643094062805, 0.25936397910118103, -0.08879939466714859, -0.37115851044654846, -0.05459192767739296, -0.7474595308303833, 0.04992886260151863, 0.186387300491333, 0.2198459804058075, -0.500429093837738, -0.6384150981903076,...
def load _ model ( path ) : with open ( path + ". pkl ", " rb " ) as f : model = pickle. load ( f ) model. extractor = cv2. sift _ create ( ) model. index = faiss. read _ index ( path + ". idx " ) return model
[ -0.07899113744497299, -0.275242418050766, 0.1010616198182106, -0.12024533003568649, -0.6391056180000305, 0.03523623198270798, -0.11164151132106781, -0.5710726380348206, 0.4355015456676483, 0.2376212477684021, -0.7385888695716858, -1.3091976642608643, 0.7204462885856628, -1.0416368246078491...
def checkmultiplicity ( self ) - > none : global pid mysite = self. mysite pywikibot. debug ( f'checking multiplicity : pid = { pid }') with self. lock : processes = [ ] used _ pids = set ( ) count = 1 now = time. time ( ) for proc in self. _ read _ file ( raise _ exc = true ) : used _ pids. add ( proc. pid ) if now - ...
[ -0.3523567318916321, -1.149503231048584, 0.7528550624847412, -0.412898987531662, 0.692265510559082, 0.15545451641082764, 0.4362698197364807, 0.2896082401275635, 0.2666110694408417, 0.12464037537574768, -0.19561266899108887, 0.4031003713607788, -0.6190183162689209, 1.0539028644561768, 0.3...
def format _ help ( self ) : def _ split _ bracketed _ expression ( expression ) : " " " splits an expresion on whitespace, keeping bracketed portions together. args : expression : string single - line expression to split. returns : list of strings, representing the split expression. " " " parts = [ ] current _ part = ...
[ 0.48530489206314087, -0.19780172407627106, 0.9653111696243286, 0.07736044377088547, -0.18318036198616028, -0.7296623587608337, 1.0352972745895386, -0.9126647114753723, -0.44554564356803894, 0.29398542642593384, 1.1277176141738892, 0.6027779579162598, 0.6174383163452148, 0.2939209043979645,...
def gen _ palindromic _ decompositions ( string ) : def recursive ( string, start, sol, res ) : if start = = len ( string ) : res. append ( [ x for x in sol ] ) return for last in xrange ( start, len ( string ) ) : if is _ palindromic ( string, start, last ) : sol. append ( string [ start : last + 1 ] ) recursive ( str...
[ 0.053334902971982956, -0.3317529559135437, 0.5977924466133118, 0.03723093494772911, -0.43019309639930725, 0.18020209670066833, 0.9214261174201965, -0.20508645474910736, 0.20813536643981934, -0.23689712584018707, -0.7397226691246033, -0.6100789308547974, -1.5002119541168213, -0.099333457648...
def get _ market _ entities ( self, uuid ='market ', * * kwargs ) : return self. request ( f'markets / { uuid } / entities ', * * kwargs )
[ -1.3872196674346924, -0.05361293628811836, 0.17829909920692444, -0.16749683022499084, 0.7532860040664673, -0.069460928440094, -0.3034289479255676, -0.13382478058338165, -0.15954755246639252, 0.04270618408918381, 0.19652250409126282, 0.7476093173027039, -0.9549143314361572, 0.39207649230957...
def forward ( self, rgb _ image ) : print ( " building model start " ) start _ time = time. time ( ) rgb _ image _ scale = rgb _ image * 255. 0 red, green, blue = tf. split ( rgb _ image _ scale, 3, 3 ) gbr _ image = tf. concat ( [ blue - vgg _ mean [ 0 ], green - vgg _ mean [ 1 ], red - vgg _ mean [ 2 ] ], 3 ) assert ...
[ -0.26432231068611145, 0.21261420845985413, 0.8622351288795471, 0.5440382957458496, 0.6713674068450928, 0.608496904373169, 0.6161592602729797, -0.5573663711547852, -0.48809006810188293, 0.4041185975074768, -0.4217609167098999, -0.11221938580274582, 0.19998188316822052, -0.020993702113628387...
def startup _ gen ( * args, * * kwargs ) : complain _ on _ error = kwargs. pop ( " complain _ on _ error ", true ) if kwargs : first _ unknown _ kwarg = sorted ( kwargs ) [ 0 ] raise valueerror ( " invalid argument : { } ". format ( first _ unknown _ kwarg ) ) argv = [ " startup - gen " ] argv. extend ( args ) return r...
[ -0.5702162981033325, 0.03503669053316116, 1.0109522342681885, 1.1701067686080933, 0.0694086104631424, 0.07012057304382324, 0.11657299846410751, 0.372262567281723, -0.3459945023059845, -0.5888618230819702, -0.24327045679092407, 0.6905331015586853, -0.31162765622138977, 0.6003731489181519, ...
def _ sudoexecutesync ( self, asargs ) : reporter. log ('executing [ sudo ] : % s'% ( asargs, ) ) ; reporter. flushall ( ) ; irc = 0 ; try : irc = utils. sudoprocesscall ( asargs, shell = false, close _ fds = false ) ; except : reporter. errorxcpt ( ) ; return ( false, 0 ) ; reporter. log ('exit code [ sudo ] : % s ( %...
[ -0.34635910391807556, 0.6924511194229126, 0.7215201258659363, -0.17375491559505463, 0.5361661314964294, -0.43494755029678345, 0.03506919741630554, 0.6434000134468079, -0.38379576802253723, 0.23928451538085938, -0.30271461606025696, 0.025713179260492325, 0.31511208415031433, 0.5433096289634...
def shape ( self ) : return self. pile. shape + self. geobox. shape
[ 0.2388244867324829, -0.5524452924728394, 0.43794432282447815, -0.33027148246765137, 1.1567695140838623, 1.6922208070755005, 0.2925852835178375, 0.33640509843826294, 0.6154769659042358, 0.06663168221712112, 0.24052143096923828, 0.04097416624426842, -0.2790273427963257, -0.24388103187084198,...
def create _ comment ( self, comment = none ) : new _ comment = comment ( author = self. user, content = " test _ content ", parent = comment, thread = self. thread ) new _ comment. save ( ) return new _ comment
[ 0.4916050434112549, -0.9269528388977051, 0.10901393741369247, 0.4679090976715088, 1.2524690628051758, -0.129083052277565, 1.0253987312316895, -0.32603031396865845, -0.30829089879989624, -0.5221697092056274, -0.8714121580123901, -1.1597412824630737, -1.5916739702224731, -0.4343343675136566,...
def execute _ commands ( commands ) : iterator = iter ( commands ) while true : # hint : implement iteration here command = next ( iterator ) if command = ='ping': print ('pong') else : print ('error')
[ -0.6296764016151428, -0.09288018196821213, 0.5222334861755371, 0.8151017427444458, 0.723422110080719, 0.5315822958946228, -0.3078574538230896, -0.8576423525810242, -0.429826021194458, 0.13688965141773224, 0.5600612163543701, -0.024013577029109, -0.254045695066452, 0.5306599736213684, -0....
def get _ server _ fields ( self, instance ) : try : server _ fields = request _ plugin _ render ( instance ) except : logger. debug ('error requesting to server') return server _ fields
[ -1.566375732421875, 0.09536495804786682, 0.4388633966445923, -0.7357945442199707, 0.09090729802846909, -0.19180388748645782, -0.45437735319137573, -0.4791259765625, 0.30211755633354187, -0.18549872934818268, -1.4624508619308472, 0.08538305014371872, -1.301094651222229, -0.4685688316822052,...
def utility ( board ) : if winner ( board ) = = x : return 1 elif winner ( board ) = = o : return - 1 else : return 0 raise notimplementederror
[ -0.5395069122314453, 0.44475147128105164, 0.7384781837463379, 0.8258832097053528, -0.32052183151245117, 0.2495105117559433, 0.9307163953781128, 0.20437853038311005, 0.7577399015426636, 0.14909788966178894, -0.03271406888961792, 0.3820348381996155, 0.8787054419517517, -0.49410566687583923, ...
def find _ by _ timestamp ( self, timestamp, category ) : eventid = self. _ locate _ event ( timestamp, category ) eventref : documentreference = self. eventcollectionref. document ( eventid ) event = event. from _ dict _ and _ reference ( eventref. get ( ). to _ dict ( ), eventref ) return event
[ 0.5443276166915894, -0.08761273324489594, 0.27976688742637634, -0.31142115592956543, 0.33855387568473816, -0.6630733609199524, -0.3209472596645355, -0.9626797437667847, 0.3403396010398865, 0.3285553455352783, 0.3732365071773529, 0.17589974403381348, 0.5383149981498718, -0.11794692277908325...
def project _ home ( ) : if'uid'in session : user _ info = app. config ['user _ store']. get _ user _ info ( session ['uid'] ) user _ info _ json = json. dumps ( user _ info ) return make _ response ( render _ template ( get _ template _ path ('home'), userinfo = user _ info _ json ) ) else : return redirect ( url _ fo...
[ -0.10757654905319214, -0.004541567526757717, 0.374491423368454, 0.6881669163703918, -0.2581210732460022, 0.7605452537536621, 0.611449658870697, -0.09473289549350739, 0.9935839772224426, 0.39039283990859985, 0.4988403916358948, 0.11450246721506119, -0.03461160138249397, -0.5617688298225403,...
def _ _ enter _ _ ( self ) : if self. aborted _ by _ user : return self # prompt for credentials until valid ones are given, user aborts, or user presses ctrl + c. while true : if self. _ _ cached _ cookies : # no need to prompt for credentials. authenticated = self. _ _ authenticate ( ) elif not self. prompt _ for _ c...
[ -0.18315839767456055, -0.1969250589609146, 0.6553340554237366, 0.8932119607925415, -0.35651907324790955, 0.10381171852350235, 0.6530627012252808, -0.9749546051025391, 0.401347815990448, -0.5923711657524109, 0.695215106010437, 0.099477618932724, 0.05227049067616463, -0.47800663113594055, ...
def has _ tabular _ format ( self, document _ soup ) : if document _ soup. find ( " p ", string = re. compile ( ". * gesamtstimmrechtsanteile. * " ) ) : return true else : return false
[ 1.108704924583435, -0.6463139653205872, 0.5704287886619568, 0.31712958216667175, -0.7162863612174988, 0.7351866364479065, -0.3482513427734375, 0.4241671562194824, -0.6477922201156616, 0.6958231329917908, 0.7004657983779907, -0.4442468583583832, 0.11365633457899094, 0.58172607421875, -0.7...
def test _ aux _ differential _ srv _ transform ( self ) : dim = 3 n _ sampling _ points = 2000 sampling _ times = gs. linspace ( 0. 0, 1. 0, n _ sampling _ points ) curve _ a = self. curve _ fun _ a ( sampling _ times ) tangent _ vec = gs. transpose ( gs. tile ( gs. linspace ( 1. 0, 2. 0, n _ sampling _ points ), ( di...
[ 0.09489789605140686, 0.26688307523727417, 0.7413195967674255, -0.3780535161495209, -0.43359509110450745, -0.08636157214641571, 0.9560853242874146, -0.5203701853752136, 1.0019187927246094, 0.14445236325263977, -0.9614978432655334, 0.24098262190818787, 0.3844054639339447, -0.2368979454040527...
def serialize ( self ) : return {'id': self. id,'name': self. name, }
[ -0.7091419696807861, -1.7656294107437134, 0.46321260929107666, -1.3251674175262451, -1.3194129467010498, 0.04855658859014511, -0.9021090865135193, -0.40104544162750244, 0.19964152574539185, -0.28634703159332275, -2.0394914150238037, 0.1440408080816269, -0.48763325810432434, -0.059249565005...
def stat _ model ( self ) : return self. _ stat _ model
[ 0.2679208815097809, -0.44416293501853943, 0.07834885269403458, 0.3051972985267639, 0.8866532444953918, 1.6096595525741577, 0.7984203100204468, -0.4735006093978882, 0.4202980697154999, -0.2882736325263977, -0.16224965453147888, -0.31237170100212097, 0.683010458946228, -0.3482978940010071, ...
def test _ variables ( self ) : reward _ normalizer, _ = self. _ setup (. 5 ) self. assertlen ( reward _ normalizer. variables, 4 ) self. assertlen ( reward _ normalizer. trainable _ variables, 2 )
[ 0.07589031010866165, 0.7725130915641785, 0.1559676080942154, -0.36786749958992004, 0.212336003780365, 0.12935771048069, 0.2982152998447418, -0.028326794505119324, -0.22440502047538757, 0.06223807483911514, -0.7639883756637573, -0.5510615706443787, -0.6731227040290833, -0.1663541942834854, ...
def update _ tag ( tag _ id, description ) : update _ spec = tag _ svc. updatespec ( ) update _ spec. setdescription = description tag _ svc. update ( tag _ id, update _ spec )
[ 0.22118328511714935, -0.5708572268486023, 0.27956700325012207, -0.394157737493515, 0.5506499409675598, -0.2657128870487213, -1.414906620979309, 0.39225730299949646, -0.42184269428253174, 0.8637022376060486, 0.04055535048246384, 1.3862996101379395, 0.010938418097794056, 0.7851046323776245, ...
def prime _ subfield ( self ) : return gf2
[ 0.4447777569293976, 0.3736334443092346, 0.35349103808403015, 0.053021278232336044, -0.23897773027420044, 1.008431315422058, 0.14241334795951843, -0.8764212131500244, -0.17654743790626526, -0.6252524256706238, -1.0123285055160522, -0.06093582883477211, -0.8995218873023987, -1.01455831527709...
def writeasciitable ( fn, h, d, fmtdata ='e') : fil = open ( fn,'w') ncol = len ( h ) - 1 # number of columns - 1 fmth ='% s'+ ncol *'% s'+'\ n'fil. write ( fmth % ( tuple ( h ) ) ) # header if fmtdata = = none : fmtdata ='e'if fmtdata = ='e': fmtd ='% e'+ ncol *'% e'+'\ n'elif fmtdata = ='f': fmtd ='% f'+ ncol *'% f'+...
[ -0.44714784622192383, -0.5799505710601807, 0.9986472129821777, -0.23294803500175476, -0.14353208243846893, 0.2581503391265869, -0.45116209983825684, -0.03226152062416077, -0.9035341739654541, -0.23188434541225433, 0.086777463555336, 0.10936421900987625, 0.6404368877410889, 0.49925389885902...
def _ _ init _ _ ( self, name, mix, * args, * * kwargs ) : kwargs. update ( { " mix " : mix } ) super ( zeroinflatedpoisson, self ). _ _ init _ _ ( name, * args, * * kwargs )
[ 0.12071811407804489, -0.22191764414310455, 0.7103227376937866, -0.5385333299636841, 0.33475440740585327, 0.43095096945762634, 0.08076238632202148, 0.6291924715042114, 0.3735257685184479, -1.1663610935211182, -0.777264416217804, -0.5560635328292847, -0.7437059879302979, 1.017088770866394, ...
def get _ activation _ by _ aid ( self, aid ) : act _ list = activation ( self. db ). list ( activation _ id = aid ) if len ( act _ list ) = = 0 : return none return act _ list [ 0 ]
[ -0.1369369626045227, -0.15594585239887238, 0.22693432867527008, -0.005992901977151632, 0.1465393304824829, -1.053214192390442, 0.6721286177635193, -0.4209783971309662, 0.7896167635917664, 1.0823445320129395, 0.25245776772499084, 0.37987369298934937, -0.6399576663970947, -0.0607801936566829...
def test _ cancelling _ booking _ with _ block ( self ) : event _ type = baker. make _ recipe ('booking. event _ type _ pc') event = baker. make _ recipe ('booking. future _ pc ', event _ type = event _ type ) blocktype = baker. make _ recipe ('booking. blocktype5 ', event _ type = event _ type ) block = baker. make _ ...
[ 0.518112063407898, 0.5291650295257568, 0.7498763799667358, 1.3374054431915283, -0.6104787588119507, 0.6841074228286743, 0.2023448497056961, 0.8262280225753784, -0.4778154492378235, -0.06260937452316284, -0.39744678139686584, -0.14815188944339752, -0.2130720168352127, 0.789082944393158, 1...
def read _ count _ file ( count _ file ) : with open ( count _ file,'r') as input _ file : dialect = csv. sniffer ( ). sniff ( input _ file. readline ( ) ) df = pandas. read _ csv ( count _ file, sep = dialect. delimiter ) col2 = df. iloc [ :, 1 ] if not is _ numeric _ dtype ( col2. dtype ) : df. drop ( df. columns [ [...
[ 0.2872326076030731, 0.11566959321498871, 0.653216540813446, 0.8854973912239075, 0.7425521612167358, 0.3662450909614563, 0.5850599408149719, 0.2153410166501999, -1.0842912197113037, 0.9383910894393921, 0.6674790382385254, -0.21737003326416016, -0.11364876478910446, -0.38901567459106445, 1...
def get _ ph ( self, repeats, wait ) : msg = self. device. send ( " get - ph ", repeats, wait ) if msg. iserror ( ) : raise exception ( msg. geterror ( ) ) return msg. getdoubleparam ( 0 )
[ -0.7953148484230042, 1.2881627082824707, 0.7027051448822021, 1.1181102991104126, 0.001599001931026578, 0.1269136667251587, -0.2630229592323303, -0.8126247525215149, -0.25869229435920715, -0.4642004072666168, 0.1540348380804062, 0.6272209882736206, -1.1732642650604248, -0.6781083941459656, ...
async def async _ set _ value ( self, value : str ) - > none : self. _ attr _ native _ value = value
[ -0.32693514227867126, 0.127556711435318, 0.47020792961120605, -0.5333524942398071, -1.0975885391235352, 0.060065705329179764, -0.477879136800766, 0.19104495644569397, -0.7210749387741089, 0.5321959853172302, -0.29544731974601746, 0.5333376526832581, 0.9757121801376343, -0.2784254550933838,...
def writegitcommands ( filename, all _ renames, old _ renames _ to _ delete ) : with open ( filename,'w') as git _ file : git _ file. write ( " #! / bin / sh \ n " ) git _ file. write ( " # git commands to add all renames and delete old ones. \ n " ) git _ file. write ( " # this file is automatically generated by gener...
[ -0.09317877143621445, -0.6077666282653809, 0.7881577610969543, -0.40281942486763, 1.331575870513916, 0.48945745825767517, -0.3706583082675934, 0.5287081003189087, -0.6734086871147156, 0.07462349534034729, -0.7554141283035278, 0.2658386528491974, 0.5834323167800903, 1.0277583599090576, 0....
def _ login ( self, force = false ) : now = time. time ( ) if abs ( now - self. session _ start _ time ) > = self. session _ timeout or \ force = = true : self. vmem _ vip. basic. login ( ) self. vmem _ mga. basic. login ( ) self. vmem _ mgb. basic. login ( ) self. session _ start _ time = now return true return false
[ -0.9042275547981262, 0.09701018035411835, 0.7353792786598206, 0.39353179931640625, -0.5343400239944458, 0.09137102216482162, -0.5123754143714905, -0.2639663517475128, 0.13177262246608734, 1.0326159000396729, 0.10279066860675812, 0.22718708217144012, -0.7577494978904724, -0.0944720655679702...
def consume ( self, key, num _ tokens ) : # note ( kgriffs ) : assume that the key will be present, since # replenish ( ) will always be called before consume ( ). tokens _ in _ bucket = self. _ buckets [ key ] [ 0 ] if tokens _ in _ bucket < num _ tokens : return false # note ( kgriffs ) : in a multi - threaded applic...
[ -0.19567257165908813, 0.3331206440925598, 1.0654065608978271, -0.6309137940406799, -0.29165810346603394, -0.2079455405473709, 0.07998459786176682, -0.49144142866134644, -0.6521187424659729, 0.13439707458019257, -0.4051209092140198, -0.4703792631626129, -1.0552875995635986, -0.0225983522832...
def split ( str, delimiters, joiner = none ) : result, element = [ ],'' for c in str : if c in delimiters : result. append ( element ) element ='' if joiner : result. append ( joiner ) else : result. append ( c ) else : element + = c result. append ( element ) return result
[ -0.5179658532142639, 0.5065369606018066, 0.2422993779182434, 0.6454693675041199, -0.5330640077590942, -0.29777297377586365, -0.9875028729438782, 0.5743601322174072, -0.24713924527168274, 0.09020303934812546, 0.0948609709739685, -0.32334282994270325, -0.9741562604904175, -0.1626923233270645...
def test _ register _ user ( self ) : user = { " username " : " rozzah1 ", " password " : " password " } userdata = json. dumps ( user ) response = self. client. post ( " / v1 / auth / register ", data = userdata, content _ type = " application / json " ) self. assertequal ( response. status _ code, 201 ) output = json...
[ -0.7008563280105591, 1.0186830759048462, 0.5085681676864624, 0.8544243574142456, 0.8460706472396851, 0.8148233890533447, -0.2510102093219757, 0.053703948855400085, -0.2743813395500183, -0.6269124746322632, -1.4346020221710205, 0.28068339824676514, 0.008981754072010517, 0.09686934947967529,...
def matrix _ mul ( m _ a, m _ b ) : if not isinstance ( m _ a, list ) : raise typeerror ( " m _ a must be a list " ) if not isinstance ( m _ b, list ) : raise typeerror ( " m _ b must be a list " ) for item in m _ a : if not isinstance ( item, list ) : raise typeerror ( " m _ a must be a list of lists " ) for item in m...
[ 0.2416309267282486, 0.3192812502384186, 1.2877007722854614, 0.4008025527000427, 0.4392664432525635, -0.16029687225818634, 0.5232872366905212, 0.871044933795929, 0.08625369518995285, 0.6500224471092224, 0.001517666969448328, -0.24008809030056, -0.5407586097717285, 0.9219518303871155, 0.68...
def _ get _ cpo _ array _ type ( val ) : # check empty array if not val : return type _ intarray # get the most common type for all array elements cet = none for v in val : nt = _ get _ cpo _ type ( v ) if nt is none : return none # combine with global type cet = nt if cet is none else cet. get _ common _ type ( nt ) i...
[ 0.47498586773872375, 0.09360243380069733, 0.7994170188903809, 0.6462823152542114, 0.10499382019042969, 0.25379395484924316, 0.9878599047660828, -0.9006861448287964, 0.0014723713975399733, 0.6732340455055237, 0.32342037558555603, 0.4198879897594452, -1.1532138586044312, 0.811532735824585, ...
def _ _ init _ _ ( self, plist ) : # parameter names self. params = plist [ :, 0 ] self. llim = plist [ :, 1 ] self. rlim = plist [ :, 2 ]
[ 0.07905188202857971, 0.2005959302186966, 0.2611730396747589, 0.31562426686286926, -0.5391718745231628, 0.36980733275413513, -0.1111314669251442, 0.231388121843338, 0.24956218898296356, 0.9510640501976013, -1.3865545988082886, -0.524026095867157, -0.6665158271789551, 0.32140085101127625, ...
def register _ images ( output _ map, grapher, epoch, post _ every = 5, prefix ='train') : is _ posting _ epoch = epoch > 0 and epoch % post _ every = = 0 if args. distributed _ rank = = 0 and grapher is not none and is _ posting _ epoch : # only send stuff to visdom once. for k, v in output _ map. items ( ) : if isins...
[ -1.0817512273788452, 0.738821804523468, 0.6947426795959473, 0.4677552878856659, -0.21739956736564636, -0.8156646490097046, 0.2665572762489319, -0.041485097259283066, -1.1486679315567017, 0.07613552361726761, -0.12574563920497894, -0.18009237945079803, 0.31619930267333984, 1.189914345741272...
def importinvertedindexfromfile ( self, pathtofile ) : with open ( pathtofile,'r') as invertedindexfile : for line in invertedindexfile : if ( line [ 0 ] )! ='\ t': term = line. split (':') [ 0 ] # extract term else : termdocentry = line. split (':') docid = int ( termdocentry [ 0 ]. strip ( ) ) self. docidset. add ( d...
[ -0.45866110920906067, -0.5898995399475098, 0.5274695754051208, -0.7512798309326172, 0.12175694108009338, 0.5061913728713989, 0.7914202213287354, 0.15250086784362793, -0.5149624347686768, 0.6748928427696228, -0.6171543002128601, -0.18721890449523926, -0.7682173848152161, -0.6658638119697571...
def base _ command ( self ) - > str : return f " sam { command _ name } "
[ 0.4329456090927124, -1.2738206386566162, 0.5725864768028259, 0.47765156626701355, 0.8494685888290405, 0.8912637233734131, -0.39538106322288513, -0.3856710195541382, 0.5865171551704407, -0.7150936722755432, 0.34710896015167236, 0.4372115135192871, 0.19530454277992249, 0.29078128933906555, ...
def convert _ cribbed _ to _ regex ( string : str ) - > list : # todo what happens when we have multiple spaces? # split into individual words crib _ split = string. split ( " " ) # if only 1 word, must be contained within a word if len ( crib _ split ) = = 1 : crib _ split [ 0 ] = ". * " + crib _ split [ 0 ] + ". * " ...
[ 0.13132846355438232, -0.17529161274433136, 0.86432284116745, 0.14613114297389984, -0.16683408617973328, 0.023260705173015594, 0.25119906663894653, 1.1511528491973877, -0.027570467442274094, 0.9467532634735107, -0.5747532248497009, 0.7199862003326416, -0.7155352234840393, -0.199011698365211...
def post ( self, email, username, password ) : if not request. is _ json : return jsonify ( { " message " : " missing json in request " } ), 400 email = normalize _ email ( email ) if check _ username ( username ) : return check _ username ( username ) user = user. query. filter _ by ( email = email ). first ( ) if use...
[ -1.1768347024917603, 0.06751161068677902, 0.9483140110969543, 0.44486337900161743, 0.26196131110191345, 0.24056817591190338, 0.7562322616577148, -0.4822905957698822, 0.5518894791603088, 0.5683239102363586, -0.606368362903595, -0.27203014492988586, -0.19951939582824707, -0.3572496175765991,...
def djikstra _ heuristic ( graph, src, dest, parents ) : return graph. edges [ ( src, dest ) ]. get _ distance ( )
[ -0.6844161748886108, 0.923783004283905, 0.28266769647598267, 0.17926406860351562, -0.946108877658844, -0.1341085284948349, -0.45791688561439514, 0.622606098651886, -0.13765700161457062, 0.7288081049919128, -0.08884678781032562, -0.3027128279209137, 0.3263549208641052, -0.5958183407783508, ...
def analyze ( statement ) : statement = statement. lower ( ) for item in convos : match = re. search ( item [ 0 ], statement ) if match : response = np. random. choice ( item [ 1 ] ) return response. replace ('{ 0 } ', reflect ( match. group ( 0 ) ) )
[ -0.46555769443511963, -0.5994685888290405, 0.5391860008239746, -0.6636204719543457, 0.21264208853244781, -1.144857406616211, -0.13823017477989197, -0.648184597492218, 1.1769781112670898, 0.2288903295993805, 0.33497893810272217, 0.0726921558380127, -0.3942837417125702, -0.5292376279830933, ...
def _ get _ cpo _ type _ str ( val ) : return _ get _ cpo _ type ( val ). get _ name ( )
[ 0.06051160395145416, -0.026160333305597305, 0.24270868301391602, 0.167093425989151, -1.1577224731445312, 0.5095385909080505, 0.6892678737640381, -0.9478505253791809, -0.552157998085022, 1.3789002895355225, -0.0501825213432312, -0.29831719398498535, -0.4836823642253876, -0.229147270321846, ...
def ownership _ verification _ certificate _ arn ( self ) - > optional [ str ] : return pulumi. get ( self, " ownership _ verification _ certificate _ arn " )
[ 0.8532953262329102, -1.118599772453308, 0.5430546998977661, 1.4902141094207764, 1.3085963726043701, 0.578802227973938, 0.6434293389320374, 0.5065968036651611, 0.6681456565856934, -1.1660730838775635, -0.08549438416957855, 1.3774687051773071, 0.28677472472190857, -0.4670356810092926, 0.06...
def disabled ( name ) : return name in get _ disabled ( )
[ -0.16874535381793976, -0.10189711302518845, 0.031268052756786346, 0.7013267874717712, -1.2793562412261963, 0.5109462738037109, -0.8432027697563171, 0.6068321466445923, 0.14627695083618164, -0.3122951090335846, -0.7486771941184998, -0.5346864461898804, -1.5153974294662476, -0.07843535393476...
def remove _ if ( ary, predicate, extra _ args = [ ], preamble = " ", queue = none, wait _ for = none ) : return copy _ if ( ary, "! ( % s ) " % predicate, extra _ args = extra _ args, preamble = preamble, queue = queue, wait _ for = wait _ for )
[ -0.032705388963222504, 0.29702094197273254, 0.6199120879173279, 0.40457019209861755, -1.210435152053833, -0.7402289509773254, -0.45875629782676697, 1.175115942955017, 0.06358093023300171, 1.2109793424606323, 0.057140760123729706, -0.1643572598695755, -0.3259710669517517, 0.2175094187259674...
def test _ list _ alumno _ con _ alumno _ curso _ otra _ institucion ( self ) : self. client. force _ authenticate ( user = self. user _ admin ) anio _ lectivo = self. anio _ lectivo _ 2. id response = self. client. get ( f " / api / alumnos / list /? anio _ lectivo = { anio _ lectivo } " ) self. assertequal ( response...
[ -0.038695186376571655, -0.5783290863037109, 0.5070220232009888, -0.33886033296585083, 1.212528944015503, 1.178822636604309, -0.37109455466270447, -0.3020794689655304, -0.04347202181816101, 0.27914050221443176, -0.5324798226356506, 1.2133677005767822, 0.9036584496498108, -0.0517775900661945...
def _ _ connect _ output _ signals _ ui ( self ) : for output in self. _ _ output _ list : output. signal. rop _ name _ changed. connect ( self. _ _ output _ update _ ui ) output. signal. being _ deleted. connect ( self. _ _ remove _ output _ item ) output. signal. camera _ changed. connect ( self. _ _ camera _ update ...
[ -1.12803053855896, -1.479032039642334, 0.5639553070068359, 0.39297226071357727, 0.1490183174610138, -0.021239159628748894, 0.6714827418327332, -0.958497166633606, -0.5847944617271423, 0.14550650119781494, -0.22981619834899902, -0.9939291477203369, -0.13278613984584808, 0.7843380570411682, ...
def _ _ getitem _ _ ( self, item ) : if item = = 0 : return self. x elif item = = 1 : return self. y elif item = = 2 : return self. z else : raise indexerror ( " index out of range : vector 3d has x [ 0 ], y [ 1 ] and z [ 2 ] items. item calls greater than 2 " " not permitted " )
[ -0.7715497016906738, -0.1942363977432251, 0.7424018383026123, 0.8661426305770874, -0.027262218296527863, 0.8060527443885803, 0.4780168831348419, -0.9229826927185059, 0.30218297243118286, -0.31556469202041626, 0.14478103816509247, 0.19462834298610687, -0.07465110719203949, -1.40580165386199...
def rotate ( self, theta ) : # first we need to shift the shape to the origin. centre = self. get _ centre ( ) self. shift ( - centre [ 0 ], - centre [ 1 ] ) # rotate all the points about the origin. new _ pts = [ ] for pt in self. points : x _ new = pt [ 0 ] * math. cos ( theta ) - pt [ 1 ] * math. sin ( theta ) y _ n...
[ 0.056962158530950546, -0.2676007151603699, 0.32366639375686646, -0.6834763884544373, 1.313493251800537, 0.16641871631145477, -0.2119103968143463, 0.4578547179698944, -0.3763934373855591, -0.21192090213298798, -0.23955197632312775, 0.4544855058193207, 0.13216762244701385, -0.512413561344146...
def encode _ invocation _ params ( params ) : final _ params = [ ] for p in params : if isinstance ( p, bool ) : final _ params. append ( {'type': contractparametertypes. boolean. value,'value': p } ) elif isinstance ( p, int ) : final _ params. append ( {'type': contractparametertypes. integer. value,'value': p } ) el...
[ -0.2920686900615692, -0.39601728320121765, 0.8203815817832947, 0.015411716885864735, 0.39254653453826904, 0.10062853246927261, -0.34760111570358276, -0.16467522084712982, -0.19763533771038055, 0.9936323165893555, -0.07031293213367462, 0.9025834798812866, -1.0687757730484009, 1.553056597709...
def _ _ init _ _ ( self, grid, location ) : self. grid = grid self. location = location
[ 0.4836680293083191, -0.9745996594429016, 0.5005079507827759, 0.04382225126028061, 0.20509466528892517, -0.15844108164310455, -0.6873718500137329, 1.1004230976104736, -0.2144567370414734, 0.31086528301239014, -0.052593182772397995, 0.868060290813446, 0.21452473104000092, 0.19138120114803314...
def get _ dnpq ( self ) : return self. dnpq
[ -1.3217697143554688, -0.13904069364070892, 0.427103191614151, -0.07690569758415222, -0.8805714845657349, -0.21403637528419495, -0.8605485558509827, -1.0344698429107666, 0.3243122100830078, -0.586174488067627, -0.3046024739742279, 0.3619445562362671, -0.6414375901222229, -0.3155614733695984...
def test _ auto _ cancel _ open _ orders _ without _ count _ down _ time ( ) : client = client ( key, secret ) client. auto _ cancel _ all. when. called _ with ( symbol = " btcusdt ", count _ down _ time = none ). should. throw ( parameterrequirederror )
[ 0.9860334992408752, 0.19030073285102844, 0.3456035256385803, 0.8759779334068298, -0.015769917517900467, 0.7501163482666016, 0.7074618339538574, -0.16616275906562805, -0.5732230544090271, -0.2459382563829422, -0.11534874886274338, -0.450156569480896, -0.02748052589595318, 0.8587919473648071...
def encrypt ( self, # type : cryptomanager plaintext, # type : union [ str, bytes, bytearray ] encrypter _ alias = none, # type : str ) - > dict : pass
[ -0.8750283122062683, 0.8116738200187683, 0.5899676084518433, -0.1512378603219986, -0.3706713318824768, -0.39854225516319275, -0.0644383430480957, 0.0076074921526014805, 0.13229748606681824, -0.06916145980358124, -0.9886304140090942, 0.4446061849594116, -0.6629571318626404, 0.55981487035751...
def _ _ repr _ _ ( self ) : return'< twilio. pricing. v2 > '
[ -0.14523173868656158, -0.4664316177368164, 0.38989123702049255, -0.715749204158783, -0.9887611269950867, 0.9226168990135193, -0.7076972126960754, 0.126995250582695, 0.36247166991233826, 1.265499234199524, 0.26521143317222595, -0.5686448812484741, 0.2684732973575592, -0.5857624411582947, ...
def cross _ reference _ specimens ( self, specimen _ df : dataframe, colonies _ df : dataframe, entity _ type : str ) - > dataframe : specimen _ df = specimen _ df. alias ( " specimen " ) colonies _ df = colonies _ df. alias ( " colony " ) # join the specimen information with the colony information specimen _ df = spec...
[ 0.3146861791610718, -0.2514466643333435, 0.7220255732536316, -0.062414247542619705, 0.3579447865486145, 0.27221381664276123, 0.12611450254917145, 0.30873215198516846, 0.1314331442117691, 0.8508658409118652, 1.0334960222244263, 0.3098868727684021, -0.18922749161720276, -0.0909305214881897, ...
def extend ( self, iterable : iterable [ _ t ] ) - > none : if isinstance ( iterable, type ( self ) ) : # don't use sums! iterable = iterable. original _ layout ( ) for value in iterable : self. append ( value )
[ 0.05201856046915054, 0.8279532790184021, 0.6608881950378418, 0.9811776280403137, -0.1882673054933548, 0.5007387399673462, -0.1152912974357605, 0.17315219342708588, 0.5317468047142029, -0.7864365577697754, 0.28596189618110657, -0.3514040410518646, 0.016692226752638817, 0.32261112332344055, ...
def remove _ books ( self, * args ) : for book in args : if book. book _ id in self. books : book. unshelf ( ) print ( " removed books from shelf. \ n " " the { shelf } shelf now contains : ". format ( shelf = self. name ) ) self. report ( )
[ 0.16345688700675964, -0.2831018269062042, 0.16765396296977997, 0.8108206987380981, 1.0240082740783691, 0.738731861114502, 0.7913259267807007, 0.17853182554244995, -1.5252821445465088, -0.02929876185953617, -0.2896493971347809, -0.5930743217468262, -1.1941345930099487, 1.132582187652588, ...
def request _ remote _ metrics _ calc ( epoch, model, grapher, prefix, post _ every ) : assert hasattr ( model,'metrics _ client') and model. metrics _ client is not none, " metrics client not created. " assert hasattr ( model,'test _ images') and model. test _ images is not none, " metrics test images not setup. " # g...
[ -0.47167474031448364, 0.49065569043159485, 0.9083610773086548, -0.2789084017276764, -0.13178400695323944, 0.29723653197288513, 0.11284691840410233, -0.4851537048816681, -1.2953048944473267, -0.03796630725264549, -0.5204854011535645, 0.5960071086883545, 0.023037007078528404, 1.0378252267837...
def get _ flow ( self, heading, velocity, filter _ steps = 0 ) : rf _ angle = np. pi / 4. 0 left = [ np. sin ( heading - rf _ angle ), np. cos ( heading - rf _ angle ) ] right = [ np. sin ( heading + rf _ angle ), np. cos ( heading + rf _ angle ) ] flow = np. dot ( np. array ( [ left, right ] ), velocity ) # if we are ...
[ 0.22284214198589325, -0.020732257515192032, 0.5230477452278137, 0.059511709958314896, -0.21303947269916534, -0.32673904299736023, -0.03984025865793228, -0.6162294745445251, 0.3358478546142578, -0.004909940995275974, 0.036431845277547836, 0.6330986022949219, -0.14897704124450684, 0.38267430...
def get _ value ( self ) - > scalartype : if self. yaml _ node. tag = ='tag : yaml. org, 2002 : str': return self. yaml _ node. value if self. yaml _ node. tag = ='tag : yaml. org, 2002 : int': return int ( self. yaml _ node. value ) if self. yaml _ node. tag = ='tag : yaml. org, 2002 : float': return float ( self. yam...
[ 0.5287204384803772, -0.336127907037735, 0.6784758567810059, -0.24940702319145203, 0.3891392648220062, -1.06605064868927, -0.30748865008354187, -0.7370774745941162, -0.5248787999153137, -0.5247394442558289, 0.2956487834453583, 1.3100768327713013, 0.3998619019985199, 1.0159326791763306, 0....
def phase _ mutations ( bam _ file, start, end ) : from collections import counter logging. debug ('looking for mutations on the same codon to be phased') haps = [ ] # coverage = 0 cml = shlex. split ('samtools view % s sample _ consensus : % d - % d'% ( bam _ file, start, end ) ) proc = subprocess. popen ( cml, stdout...
[ 0.32211536169052124, -0.13519927859306335, 0.6408517360687256, 0.5182622075080872, 0.03255510702729225, -0.769885778427124, 0.05058934539556503, 0.4082549512386322, 0.081474669277668, -0.043153148144483566, 0.4238874912261963, -0.40506449341773987, 0.16027426719665527, -0.1071639209985733,...
def passwordify ( s ) : digits = [ str ( x ) for x in range ( 0, 10 ) ] lower = [ chr ( x ) for x in range ( ord ('a'), ord ('z') + 1 ) ] upper = [ chr ( x ) for x in range ( ord ('a'), ord ('z') + 1 ) ] symbols = "!? + - = * / @ # $ % & ( ) [ ] ; :,. < > " def at ( l, x ) : return l [ ord ( x ) % len ( l ) ] return''....
[ -0.4474872648715973, -0.44700175523757935, 0.45721668004989624, -0.9598656892776489, -0.3227587938308716, -0.2940961718559265, -0.026571303606033325, 0.36570799350738525, 0.5216773152351379, 0.5466793775558472, -1.1814059019088745, 0.5639112591743469, -0.28123536705970764, -0.5974254608154...
def _ _ init _ _ ( self, data ) : self. data = data self. left = none self. right = none self. depth = 0 self. parent = none
[ 0.08536478132009506, 0.0064440276473760605, 0.4353022277355194, -0.09292878210544586, -0.542477011680603, 0.1382886916399002, 0.02098221704363823, -0.004698931239545345, 0.4727199971675873, -0.8402596712112427, -1.0617499351501465, 0.17593777179718018, -0.4718490540981293, 1.58144915103912...
def _ translate _ _ interfaces _ interface _ ipv6 _ address ( input _ yang _ obj, translated _ yang _ obj = none ) : translated _ yang _ obj. type = " global " translated _ yang _ obj. algorithm _ type = " none " if input _ yang _ obj. prefix _ length. _ changed ( ) : translated _ yang _ obj. prefix _ length = input _ ...
[ -0.6480152606964111, -0.0933888852596283, 0.30315056443214417, -0.7783344984054565, -0.2949449419975281, -0.05927497521042824, 1.2618807554244995, -0.09283279627561569, 1.075783371925354, 1.097866177558899, -0.8367109298706055, 0.580086886882782, -0.49168917536735535, -0.18286442756652832,...
def to _ sql _ statement _ create ( self ) : return sql _ text ( f " create function { self. literal _ schema }. { self. literal _ signature } { self. definition } " )
[ -0.05282704532146454, -0.8073375225067139, 0.3597510755062103, 0.1213245838880539, 0.33917659521102905, -0.3486696481704712, -0.9582304358482361, -0.14945262670516968, -0.6203365921974182, 0.18587034940719604, -0.12028470635414124, 0.6154471039772034, 0.32394275069236755, -0.08809752017259...
def raw _ league _ statistics ( ) : leagues = pd. read _ sql ( " select * from league ", getdata. conn ) print ( leagues. isnull ( ). sum ( ) ) print ( leagues. describe ( ) ) print ( leagues. dtypes )
[ -0.03917635232210159, 0.4931448996067047, 0.5324527025222778, -0.7243937253952026, 0.7273737788200378, -0.07386744767427444, -0.4732702672481537, -0.7624103426933289, 0.06699376553297043, -0.5424013733863831, -0.33764776587486267, 1.3525971174240112, 1.8832221031188965, -0.8410545587539673...
def setup _ dashboard ( self ) : # draw dashboard with border arcade. draw _ rectangle _ filled ( * * self. _ dashboard _ data, color = arcade. color. blue ) arcade. draw _ rectangle _ outline ( * * self. _ dashboard _ data, color = arcade. color. black, border _ width = 2 * margin ) # calculate timer ( in mm : ss form...
[ 0.37209418416023254, 0.32528382539749146, 0.8760702610015869, -0.663666844367981, 0.33095860481262207, 0.3408287465572357, 0.556100606918335, -0.16870123147964478, -0.5093551278114319, -0.3133443593978882, 0.36364373564720154, 0.43948453664779663, 0.3312743306159973, 1.1683636903762817, ...
async def issue _ updated _ event ( event, gl, * args, * * kwargs ) : jsonstr = json. dumps ( event. _ _ dict _ _ ) await createissuegreetingforupdate ( gl, event ) ;
[ -0.5179213285446167, -0.6719861626625061, 0.5313654541969299, 0.09925933182239532, -0.4704996347427368, 0.4091417193412781, -0.7782559990882874, 0.1816197633743286, 0.0744057446718216, 0.8180148601531982, -0.5265628099441528, 0.23230959475040436, 0.22808554768562317, -0.12629640102386475, ...
def bssc _ init _ grafana _ version ( self, log ) : if not self. bssc _ is _ up ( log ) : self. bssc _ grafana _ version = clog. error _ msg return grafana _ version = self. bssc _ server. bes _ grafana _ version ( log ) if grafana _ version is none : self. bssc _ grafana _ version = clog. error _ msg self. bssc _ fail...
[ -0.16191358864307404, -0.3251359760761261, 0.7167303562164307, 1.069103479385376, 0.8863176107406616, -0.27649053931236267, 0.27645543217658997, -0.6812242865562439, -0.18547426164150238, 0.13280606269836426, -0.20137669146060944, 1.2013800144195557, 0.5703650712966919, 0.31202271580696106...
def new _ note ( self, y _ coord, x _ coord, height = 30, width = 30, totextlist = none, blank = false, divider = 0, box _ char = none ) : skip = ['' ] if blank : skip = [ ] if totextlist is none and not self. dictionary _ mode : totextlist = self. textlist else : totextlist = self. display _ dict frame = self. make _ ...
[ -0.43826550245285034, 0.3696502447128296, 0.6704046130180359, -0.70918869972229, -1.2487831115722656, -0.013111170381307602, 0.0595051608979702, -0.2713838815689087, -0.22691139578819275, 0.04018337279558182, 0.012890574522316456, 0.14417634904384613, -0.20989170670509338, -0.1995967775583...
def compare ( self, other ) : if self. type! = other. type : return self. type. id - other. type. id if self. name! = other. name : return self. type. id - other. type. id sclen = len ( self. children ) oclen = len ( other. children ) if sclen! = oclen : return sclen - oclen for sc, oc in zip ( self. children, other. c...
[ -0.25301381945610046, -0.5145622491836548, 0.9346446394920349, -0.30209431052207947, 0.02337639592587948, 0.10391923040151596, 0.3780819773674011, -0.9579997658729553, -0.1638472080230713, -0.12364692240953445, -0.8233359456062317, -0.0934256762266159, -0.7168657183647156, 1.10808742046356...
def make _ pizza ( * toppings ) : print ( toppings ) print ('- - - -')
[ -0.3453202247619629, 0.06876228004693985, 0.36703982949256897, 1.2324329614639282, -0.6028178334236145, 0.6106467843055725, -0.16332654654979706, 0.38214993476867676, -0.8664469718933105, -0.5232698917388916, -0.7817627787590027, -0.3160264790058136, 0.03254993259906769, -0.646445333957672...
def print _ progress _ bar ( iteration, total, prefix ='', suffix ='', decimals = 1, length = 100, fill ='', print _ end = " \ r " ) : percent = ( " { 0 :. " + str ( decimals ) + " f } " ). format ( 100 * ( iteration / float ( total ) ) ) filled _ length = int ( length * iteration / / total ) bar = fill * filled _ leng...
[ 0.3322760760784149, 0.20396463572978973, 0.7077202796936035, -0.39342597126960754, -0.2540969252586365, 0.759699821472168, -0.04649960249662399, -0.47372984886169434, -0.9911788105964661, 0.13109999895095825, 0.044989366084337234, -0.0916791632771492, -0.6317523121833801, 0.295718789100647...
def _ _ str _ _ ( self ) : return f " { self. x, self. y, self. z, self. w } "
[ 0.018734410405158997, -1.5921332836151123, 0.3561401963233948, -1.6336073875427246, -0.16965040564537048, 0.5266047120094299, 0.14428254961967468, -0.8065420389175415, -0.4859791696071625, -0.31182822585105896, 0.32890379428863525, 0.03377154469490051, 0.24553708732128143, -0.4636955261230...
def _ check _ rbl _ addr ( self, addresses, rbl _ server, subtest = none ) : if self. ctxt. skip _ rbl _ checks : return false if subtest is not none : try : subtest = regex ( subtest ) except re. error as e : self. ctxt. err ( " invalid regex % s : % s ", subtest, e ) return false for addr in addresses : if " @ " in a...
[ -0.11358324438333511, 0.09443363547325134, 0.6173464059829712, -0.07602602988481522, 0.17394255101680756, 0.4899841845035553, 0.1900206208229065, -0.2841903865337372, 0.29183685779571533, 0.16206909716129303, 0.560494065284729, 0.7742224335670471, -1.298219919204712, 0.5081073045730591, ...
def findconn ( self, st ) : en = np. complex128 ( 0 ) for k in range ( self. nspins - 1 ) : en - = st [ k ] * st [ k + 1 ] if self. pbc : en - = st [ 0 ] * st [ - 1 ] self. mel [ 0 ] = en [ 0 ] return self. iflips, self. mel
[ -1.196751594543457, -0.6373391151428223, 0.3860000967979431, 0.24159060418605804, -0.5026369094848633, -0.23766866326332092, 0.24624967575073242, -0.1827719658613205, 0.6365301609039307, 0.5107228755950928, -0.06634973734617233, -0.4962588846683502, -0.9388979077339172, 0.6790152192115784,...
def route ( self, path : str, methods : typing. optional [ typing. list [ str ] ] = none, name : typing. optional [ str ] = none, include _ in _ schema : bool = true, ) - > typing. callable : # type : ignore [ type - arg ] warnings. warn ( " the ` route ` decorator is deprecated, and will be removed in version 1. 0. 0....
[ -0.7734978795051575, 0.2914144694805145, 0.6326445937156677, -0.12549887597560883, -0.4522091746330261, -0.6358678340911865, -0.6047593951225281, 0.3149271309375763, 0.36899811029434204, 0.13075877726078033, -0.025278473272919655, 0.3658895194530487, 0.16216950118541718, -0.190986841917037...
def split ( x, y, ratio = 0. 7 ) : idx = round ( len ( x ) * ratio ) x _ train, y _ train = x [ : idx ], y [ : idx ] x _ test, y _ test = x [ idx : ], y [ idx : ] return ( x _ train, y _ train ), ( x _ test, y _ test )
[ -0.6023917198181152, 0.5476145148277283, 0.4668775498867035, -0.6267712116241455, -0.31301403045654297, -0.15170536935329437, -0.8640997409820557, -0.09066560119390488, -0.4348441958427429, 0.5066184401512146, -0.022580586373806, -0.31565946340560913, -0.10755517333745956, -1.3586519956588...
def compute ( self, img ) : kps, descriptors = self. extractor. detectandcompute ( img, none ) bow _ descriptor = np. zeros ( self. n _ words ) n _ words _ in _ img = len ( kps ) if n _ words _ in _ img = = 0 : return bow _ descriptor if self. use _ root _ sift : descriptors / = ( descriptors. sum ( axis = 1, keepdims ...
[ 0.39607930183410645, 0.02600719779729843, 0.6566243767738342, 0.2501572072505951, -0.09872141480445862, -0.23912382125854492, 0.16885633766651154, 0.6559527516365051, 0.5748056173324585, 0.8312331438064575, 0.40550941228866577, 1.0550098419189453, -0.1378924399614334, 1.3916358947753906, ...