text
stringlengths
25
2.19k
embedding
listlengths
768
768
def log10 ( self, k, te, ne ) : te, ne = np. broadcast _ arrays ( te, ne ) log _ temperature = np. log10 ( te ) log _ density = np. log10 ( ne ) c = self. splines [ k ] ( log _ temperature, log _ density ) return c. diagonal ( )
[ 0.26040714979171753, -0.40688619017601013, 0.4332236647605896, -1.5691369771957397, 0.363048791885376, -0.18640071153640747, -0.8948941230773926, 0.8889061808586121, 0.3572766184806824, 0.7395040392875671, 0.5155941247940063, -0.13616864383220673, 0.756483256816864, -0.8137292861938477, ...
def non _ mig ( nm _ df, db _ id, sim _ year ) : nm _ df ['non _ mig _ pop'] = nm _ df ['persons'] - nm _ df ['mig _ out _ net'] # drop unnecessary columns nm _ df = nm _ df [ ['type ','mildep ','households ','persons ','mig _ out _ net ','non _ mig _ pop ','mig _ in _ net ','yr'] ] # record non migration population in...
[ -0.5649409294128418, 0.5713329315185547, 0.6080939769744873, -0.1714966744184494, -0.09867028146982193, 0.750985860824585, 0.18342183530330658, 0.1358320713043213, 0.19529923796653748, 0.5015724897384644, 0.02220875956118107, -0.13880954682826996, -0.7491428852081299, 0.8888373970985413, ...
def begin _ create _ dev _ box ( self, project _ name : str, dev _ box _ name : str, body : union [ json, io ], user _ id : str = " me ", * * kwargs : any ) - > lropoller [ json ] : _ headers = case _ insensitive _ dict ( kwargs. pop ( " headers ", { } ) or { } ) _ params = kwargs. pop ( " params ", { } ) or { } conten...
[ -0.7073889374732971, 0.024089064449071884, 0.9039139151573181, -0.08322637528181076, -0.481900155544281, -0.15620751678943634, -0.32063645124435425, -1.2682143449783325, -0.04887380450963974, -0.35638296604156494, -0.3127609193325043, 0.7450724840164185, 0.023815462365746498, 0.08331020921...
def as _ enum ( self ) : return self. actual _ state
[ -1.313927412033081, -1.4857701063156128, 0.5416123270988464, -0.3190334141254425, 0.2005288451910019, 0.213632270693779, -0.015412584878504276, -0.41845691204071045, 1.7397549152374268, 0.37118372321128845, -0.2546320855617523, 0.9214139580726624, 0.5208362936973572, -0.40160590410232544, ...
def shape ( self ) : wkt = self. wkt if wkt : try : result = loads ( self. wkt ) return result except : return none
[ 0.3481822609901428, -0.37678253650665283, 0.49283385276794434, -0.8651629686355591, -0.4474692940711975, -0.12115777283906937, -0.25355517864227295, -0.4270704388618469, 0.3335683047771454, -0.8861314058303833, 0.42153313755989075, -0.28621187806129456, -0.8620131611824036, -0.761175513267...
def _ _ new _ _ ( cls, *, channel _ id =..., name =..., position =..., ) : # channel _ id if channel _ id is... : channel _ id = 0 else : channel _ id = validate _ id ( channel _ id ) # name if name is... : name ='' else : name = validate _ name ( name ) # position if position is... : position = 0 else : position = val...
[ 0.2906097173690796, -1.3262689113616943, 0.8071103692054749, -0.17251744866371155, 0.060311511158943176, 0.08761409670114517, -0.7010766267776489, -0.23549884557724, -0.07056649029254913, -0.2164030820131302, -0.8290398716926575, -0.15903230011463165, 0.00325426971539855, 0.481145918369293...
def load ( ) : data = _ get _ data ( ) return du. process _ recarray ( data, endog _ idx = 0, dtype = float )
[ -0.627758264541626, 0.7987447381019592, 0.4674787223339081, -0.7771898508071899, 0.11158778518438339, -1.0927186012268066, 0.0409216582775116, -0.33103907108306885, -0.4598960280418396, -0.24013292789459229, 0.057415761053562164, 0.9671667814254761, -0.4764721989631653, -1.2714163064956665...
def binary _ path ( self ) - > str : return os. path. join ( self. server _ directory _ path, self. _ binary _ path )
[ 0.2872077226638794, -1.1997426748275757, 0.4822245240211487, 0.6288432478904724, 0.46272408962249756, 1.485332727432251, 0.8997102975845337, -0.10808691382408142, -0.6398254632949829, -0.3908306062221527, 0.15572908520698547, 0.6454537510871887, -1.1416254043579102, 0.18766164779663086, ...
def find _ ndcg _ with _ mapping ( reference, hypothesis ) : # with ties, large numbers are put at the end. reference, hypothesis = _ order _ lists ( reference, hypothesis ) # sorts the predictions sorted _ hypothesis = sorted ( [ x for x in enumerate ( hypothesis ) ], key = lambda x : x [ 1 ], reverse = true ) # maps ...
[ 0.017275122925639153, 0.7043411135673523, 0.6698719263076782, -0.188839852809906, -1.0269724130630493, -0.7982181310653687, -0.42447981238365173, -0.20792225003242493, -0.6579363346099854, 0.9515207409858704, 0.4952448308467865, 0.7263669967651367, 0.04815821722149849, 1.160378336906433, ...
def _ _ sgd _ one ( self ) : # calc dl / dalpha ay = np. multiply ( self. alpha, self. y ) ayk = np. multiply ( self. k, ay ) dl _ dalpha = 1. 0 - 0. 5 * np. multiply ( self. y, np. sum ( ayk, axis = 1 ) ) dl _ dalpha [ dl _ dalpha < 0 ] = 0 dl _ dalpha [ dl _ dalpha > 10 ] = 10 # update alpha and constrain self. alpha...
[ -0.10082023590803146, 0.025537792593240738, 0.8531824350357056, -1.1147912740707397, -0.2829177975654602, 0.5827350616455078, 0.4010377526283264, 0.740526556968689, 0.3792826533317566, 0.5996106266975403, 0.38204675912857056, 0.34612712264060974, 0.28060460090637207, 0.9373713731765747, ...
def calc _ total _ magnetisation ( self ) : return sum ( sum ( self. _ spins ) )
[ -0.10570983588695526, -0.1736389547586441, 0.3075588345527649, -0.4274134337902069, 0.4718998074531555, 0.25522151589393616, 0.8726269006729126, 0.5749958157539368, 0.7522082924842834, 0.1923898607492447, -1.1407253742218018, -0.1674976497888565, -0.43683943152427673, -0.24113227427005768,...
def train ( self, corpus, epochs = 100 ) :
[ -1.21848726272583, 1.2458583116531372, 0.04223644360899925, 0.13648861646652222, 1.003003716468811, -0.4180322289466858, -0.1567257046699524, 1.0766270160675049, -0.8625310659408569, 0.40781959891319275, -1.2138596773147583, 0.02133091166615486, 0.5772032141685486, -0.28069669008255005, ...
def is _ initialized ( self ) - > bool : return requirejs. _ _ is _ initialized
[ -0.5493363738059998, -0.7189335227012634, 0.5290289521217346, 0.1927817016839981, 0.49372726678848267, -0.7097249031066895, 0.41586995124816895, 0.10132312774658203, 0.3033669590950012, 0.22864151000976562, -1.241580605506897, 0.08835525065660477, -0.051758620887994766, 1.1286298036575317,...
def test _ list _ integer _ enumeration _ nistxml _ sv _ iv _ list _ integer _ enumeration _ 1 _ 3 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / list / integer / schema + instance / nistschema - sv - iv - list - integer - enumeration - 1. xsd ", instance = " nistdata / list / inte...
[ -0.9812966585159302, -0.4133661985397339, 0.48071685433387756, 0.44916853308677673, -0.15018951892852783, 0.17151430249214172, -0.09550664573907852, 0.6372298002243042, 1.6809264421463013, 0.853240966796875, -0.5901033282279968, -0.46014782786369324, -0.5562036633491516, 0.5570637583732605...
def weight _ structural ( self ) : return self. weight _ mtow - self. weight _ prop - self. weight _ batt - self. weight _ payload - self. weight _ electronics
[ 0.1753241866827011, -0.8147455453872681, 0.4924781918525696, -0.27314120531082153, 0.2699354588985443, 0.34774667024612427, 0.4997522830963135, -0.18967202305793762, -1.010361909866333, -0.16022959351539612, -0.19894297420978546, -0.01867583394050598, -0.8216730356216431, -0.27220216393470...
def read _ method _ details ( ) : with open ( " collect. txt ",'r') as fp : collector _ details = fp. read ( ) fp. close ( ) with open ( " cluster. txt ",'r') as gp : cluster _ details = gp. read ( ) gp. close ( ) " " " with open ('before _ clusture. png ','r') as i1 : cluster _ image = i1. read ( ) i1. close ( ) with ...
[ -0.4074977934360504, -0.28737783432006836, 0.794854462146759, -0.6609356999397278, 0.39607247710227966, 0.8937637805938721, 0.6440145373344421, -1.1703845262527466, -1.0419195890426636, 0.63970947265625, 0.030056236311793327, 0.21921375393867493, 0.5074610710144043, 0.5981355905532837, 0...
def extract _ catalog _ data ( line ) : # normalize line data line _ data = line. split ('qty :') [ 1 ]. split ('' ) data _ array = list ( map ( normalize _ data, line _ data ) ) # pull out order data for index, element in enumerate ( data _ array ) : data _ array [ index ] = element. split ('' ) [ 0 ]. strip ('\ n $')...
[ -0.5642956495285034, -0.5873185396194458, 0.510550856590271, 0.09970729798078537, -0.017467495054006577, -0.22848384082317352, -0.6803973913192749, -0.22041451930999756, -0.04029764607548714, 0.2700587213039398, -0.597107470035553, 0.5941655039787292, 0.28217899799346924, -0.70454579591751...
def _ _ init _ _ ( self ) : super ( ). _ _ init _ _ ( ) self. solutiondict = {'across the top': ['a1 ','b1 ','c1'],'across the middle': ['a2 ','b2 ','c2'],'across the bottom': ['a3 ','b3 ','c3'],'down the left side': ['a1 ','a2 ','a3'],'down the middle': ['b1 ','b2 ','b3'],'down the right side': ['c1 ','c2 ','c3'],'lef...
[ 0.028058622032403946, 0.2522696852684021, 0.823223352432251, -0.40946805477142334, -0.22779059410095215, -0.2816627025604248, 0.8963021636009216, 0.3300575315952301, -0.1691257655620575, 0.3634570837020874, -1.1224026679992676, -0.9183979034423828, 0.25925272703170776, 0.20013491809368134,...
def normalize ( data ) : # lets make sure everything in the array is a float.. for i in range ( 0, len ( data ) ) : data [ i ] = list ( map ( float, data [ i ] ) ) # rotate the array for easy access to min / max rotatedarray = list ( zip ( * data [ : : - 1 ] ) ) # loop through each feature, find the min / max of that f...
[ -0.07508300989866257, -1.0252419710159302, 0.7828539609909058, 0.3039345443248749, -0.19823142886161804, 0.11108230799436569, 0.24831749498844147, 0.22929978370666504, 0.45611709356307983, -0.11599422991275787, 0.28484290838241577, 0.09799965471029282, -0.7383379936218262, 0.06646628677845...
def get _ data ( afile, file _ type = none, * * keywords ) : if isstream ( afile ) and file _ type is none : file _ type = _ _ file _ type _ _ return read _ data ( afile, file _ type = file _ type, * * keywords )
[ 0.26169365644454956, -0.009527123533189297, 0.4846267104148865, 0.6753565073013306, -0.22072887420654297, 0.21860045194625854, -1.1896313428878784, -0.3818438649177551, -0.5600891709327698, -0.5300624966621399, 0.7113012075424194, 0.7035418152809143, -0.20598553121089935, 0.883372902870178...
def frame _ ch2 _ flt _ change ( self ) : self. frame _ ch2 _ raw. setcurrentindex ( self. frame _ ch2 _ flt. currentindex ) self. frame _ ch2 _ sgm. setcurrentindex ( self. frame _ ch2 _ flt. currentindex )
[ -0.649046003818512, -1.4830925464630127, 0.36951395869255066, -0.491061806678772, -0.2783712148666382, -0.33363571763038635, 0.8855334520339966, -0.11386990547180176, -0.9765222072601318, -0.4148982763290405, -1.451820731163025, 1.7668266296386719, 0.7642043828964233, 0.2634773850440979, ...
def preprocess ( model, in _ dir, out _ dir, text, audio _ filename, mel _ filename, p = 0, speaker _ id = none, fast = false ) : r = hparams. outputs _ per _ step downsample _ step = hparams. downsample _ step if use _ cuda : model = model. cuda ( ) model. eval ( ) if fast : model. make _ generation _ fast _ ( ) mel _...
[ 0.24442356824874878, -0.15917930006980896, 0.9818572402000427, 0.20816531777381897, -0.6704986095428467, -0.9620841145515442, -0.27347931265830994, 0.8541841506958008, 0.27903836965560913, 0.3379806578159332, 0.3217673599720001, -0.1382756233215332, -0.4296793043613434, 0.20778770744800568...
def nucs _ 2dsegm _ last ( self ) : self. nucs _ 2dsegm _ last _ value = self. frame _ dapi _ raw. currentindex self. nucs _ 2dsegm _ last _ lbl. settext ( str ( self. nucs _ 2dsegm _ last _ value ) )
[ -1.324158787727356, -0.6692209839820862, 0.6230986714363098, -1.017652153968811, 0.6706154346466064, 0.41300222277641296, 0.4354725182056427, -0.9142153859138489, -0.38421422243118286, -0.653152346611023, -0.18211662769317627, 0.10254732519388199, 0.1694188117980957, 0.18309058248996735, ...
def create _ hparams ( hparams _ string = none, verbose = false ) : hparams = tf. contrib. training. hparams ( # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # experiment parameters # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # epochs = 120, frame _ size = 160, bfcc _ band = 18, nb ...
[ 0.8347049355506897, -0.1679505854845047, 1.0512809753417969, 0.4473237991333008, 1.0754162073135376, 0.9614489078521729, 0.7240023016929626, 0.23375624418258667, -1.2259317636489868, -0.07375253736972809, -0.4229338467121124, -0.23707829415798187, -0.46445953845977783, -0.4908785820007324,...
def createdaemon ( daemonclass ) : try : pid = os. fork ( ) if pid > 0 : # parent glob. logger. info ('daemon : % s, pid : % s'% ( daemonclass, pid ) ) return pid except oserror, error : print'unable to fork. error : % d ( % s )'% ( error. errno, error. strerror ) os. _ exit ( 1 ) # child module = _ _ import _ _ ( daem...
[ 0.13554997742176056, -0.4756917953491211, 0.7430874705314636, -0.079597108066082, -0.34731781482696533, 0.7817974090576172, 0.7407852411270142, -0.3342032730579376, 0.6764852404594421, -0.12586070597171783, 0.1296570599079132, 0.23905864357948303, -0.10787387937307358, 0.6424979567527771, ...
def get _ dev _ box _ by _ user ( self, project _ name : str, dev _ box _ name : str, user _ id : str = " me ", * * kwargs : any ) - > json : error _ map = { 401 : clientauthenticationerror, 404 : resourcenotfounderror, 409 : resourceexistserror, 304 : resourcenotmodifiederror, } error _ map. update ( kwargs. pop ( " e...
[ -1.32399320602417, 0.11096368730068207, 0.8636845946311951, 0.3393118381500244, -0.5736048817634583, -0.6156491041183472, 0.3319913446903229, -1.5775575637817383, -0.2610158622264862, -0.6565797328948975, -0.449914813041687, 1.2863097190856934, -0.057664867490530014, 0.09571217000484467, ...
async def description ( self, ctx : context, *, description : unicode ) - > none : self. embeds [ ctx. author ]. embed. description = description await ctx. send ( " embeds description updated. " )
[ 0.3347112834453583, 0.12395834922790527, 0.4421503245830536, 1.0642386674880981, 0.1911759376525879, 1.195424199104309, -0.7143855690956116, 0.07352931052446365, 0.37785935401916504, 0.3559699058532715, -0.9183319807052612, 1.5526498556137085, -0.8287968039512634, 0.14739862084388733, -0...
def test _ remove _ hooks2 ( self ) : example _ py2 _ check = false standard _ library. install _ hooks ( ) old _ meta _ path = copy. copy ( sys. meta _ path ) standard _ library. remove _ hooks ( ) standard _ library. scrub _ future _ sys _ modules ( ) if utils. py2 : self. asserttrue ( len ( old _ meta _ path ) = = l...
[ 0.08522193878889084, 0.1260928213596344, 0.426712304353714, 0.9602178931236267, 0.4272290766239166, 0.6042747497558594, 0.740311324596405, 0.4059417247772217, -0.22580499947071075, 0.05415672808885574, -0.4454820454120636, 0.2012227326631546, -0.1586432158946991, -0.030721094459295273, 0...
def _ edit _ batch ( self, examples, max _ seq _ length, beam _ size ) : source _ words, insert _ words, insert _ exact _ words, delete _ words, delete _ exact _ words, _, edit _ embed = self. editor. _ batch _ editor _ examples ( examples ) encoder _ input = self. editor. encoder. preprocess ( source _ words, insert _...
[ 0.14706695079803467, 0.17202511429786682, 0.5344332456588745, 0.43160131573677063, -0.5180250406265259, -0.31717199087142944, 0.1714344322681427, 0.794449508190155, -0.010067788884043694, 0.8269102573394775, -0.3824939727783203, 0.11666765809059143, -0.1535489559173584, 0.8965839147567749,...
def get _ catalog ( self, dataset = none, limit = none, refresh = false ) : logger. info ('get _ catalog : retrieving { }, limit { } '. format ( dataset if dataset else'all datasets ', limit ) ) # no need to download more data if : # - - if the dataset matches, and the new limit is smaller # - - if the previous dataset...
[ -0.8571979403495789, 0.8195217251777649, 0.9349096417427063, -0.18923772871494293, -0.10689890384674072, -0.7534829378128052, -0.30864855647087097, 0.03267981484532356, 0.3570759892463684, -0.411090612411499, 0.43240296840667725, 0.9915607571601868, 0.28899744153022766, -0.1407749503850937...
def get _ queryset ( self ) : queryset = super ( ). get _ queryset ( ) if self. order : return queryset. filter ( order = self. order, declined _ at _ _ isnull = true ). select _ related ('artist') user = self. request. user return queryset. all _ visible _ for _ artist ( user ). select _ related ('order')
[ 0.18106144666671753, 0.14055193960666656, 0.7608125805854797, 0.2571242153644562, 0.0006175095331855118, 0.14361506700515747, -0.2207787185907364, -0.30706337094306946, 0.9945898652076721, -0.20128613710403442, 0.40005943179130554, 0.7062118053436279, 0.3211356997489929, 0.4649965167045593...
def _ retrieve _ objects ( self, * * kwargs ) - > list [ storedfile ] : return [ storedfile ( client = self. _ client, json = stored _ files _ json ) for stored _ files _ json in self. _ value ]
[ -0.14128795266151428, -0.6025839447975159, 0.25422510504722595, 0.28128302097320557, 1.2964736223220825, 0.18282431364059448, 0.16099509596824646, -0.4858880043029785, -0.5122336149215698, -0.734964907169342, -0.6425445675849915, -0.21044114232063293, -0.007881645113229752, 0.0876495465636...
async def _ refetch _ message ( message : union [ message, partialmessage ] ) : return await message. channel. fetch _ message ( message )
[ 0.40113672614097595, 0.5033515691757202, 0.34451451897621155, -0.23291261494159698, -0.1661021113395691, -0.18398259580135345, -0.7952563762664795, -1.833310842514038, -0.12493875622749329, -0.20187991857528687, 1.1385232210159302, 0.6834885478019714, -1.067033290863037, 0.0742536708712577...
def unwire ( self, block ) : if not block. metablock. wired : raise valueerror ( " unwire on unwired block " ) block. flush ( self. fsh ) block. metablock. wired = false self. buffer. remove ( block )
[ 0.38737571239471436, 0.2329491525888443, 0.631870448589325, -0.6371174454689026, -0.22223122417926788, 0.6688768863677979, -0.10296303033828735, -0.2263191193342209, 0.12451384216547012, -0.001265665632672608, -0.7384775280952454, 0.8206831812858582, -1.6534037590026855, 1.4404895305633545...
def dem _ creator ( h, h _ wt, seed, elev _ range, sigma, gradient, max _ level, demcreator _ option ) : input _ dems = [ ] name = [ ] parameter = [ ] dem _ arr = numpy. zeros ( ( 2 * * max _ level, 2 * * max _ level ), dtype = float ) if demcreator _ option = ='fm2d': for i in range ( 0, len ( h ) ) : # generate other...
[ -0.7065085172653198, -0.3719027638435364, 0.9398084878921509, 0.4559408128261566, -0.028838666155934334, 0.7427405714988708, 0.5674686431884766, -0.29950910806655884, -0.38124504685401917, -0.46430328488349915, -0.0895567312836647, 0.04156901687383652, 0.46293896436691284, 1.56019544601440...
def _ _ init _ _ ( self, config, logger, topic, messages, name ='topicmessage ', ) : super ( topicmessage, self ). _ _ init _ _ ( config, logger, utils. get _ gcp _ resource _ name ( name ), ) self. name = name self. messages = messages self. topic = topic
[ 0.36752671003341675, 0.0816560760140419, 0.43417850136756897, -0.0027930105570703745, -0.0217382051050663, 0.15302766859531403, -0.4387481212615967, -0.45022425055503845, -0.5872624516487122, 0.6053643822669983, -0.11336614936590195, -0.7068852782249451, -0.4519526958465576, 0.610008597373...
def test _ atomic _ id _ enumeration _ 3 _ nistxml _ sv _ iv _ atomic _ id _ enumeration _ 4 _ 4 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / id / schema + instance / nistschema - sv - iv - atomic - id - enumeration - 4. xsd ", instance = " nistdata / atomic / id / schem...
[ -0.2630991041660309, -0.5853080749511719, 0.471162348985672, 0.16244082152843475, -0.20650392770767212, -0.04351320117712021, 0.18909290432929993, -0.4473660886287689, 0.3368230164051056, 0.5744225978851318, -0.21583972871303558, -0.4169119596481323, -0.131405308842659, -0.524010181427002,...
def split _ and _ scale _ data ( labels, examples ) : print " splitting training and test sets " print # turning lists into numpy arrays total _ array = np. array ( examples ) # scale the features so they have 0 mean total _ scaled = preprocessing. scale ( total _ array ) # numpy array of the labels total _ labels = np...
[ -0.6600139737129211, -0.07397908717393875, 0.412385493516922, -0.7091711759567261, 0.09063158929347992, 0.14362961053848267, -0.4789954423904419, 0.29759278893470764, 0.24871009588241577, 0.9001675248146057, -0.20342040061950684, 0.13565225899219513, -0.19090040028095245, 0.201568126678466...
def handle _ grafana _ payload ( payload, name2file, play _ queue ) : if payload is none : raise grafanapayloadexception ( " no payload, ignoring " ) logger = logging. getlogger ( _ _ name _ _ ) logger. debug ( f " got payload : { payload } " ) status = payload. get ( " status " ) if status is none : raise grafanapaylo...
[ 0.24156752228736877, -0.18815770745277405, 0.7612084746360779, 0.1151055172085762, -0.098598413169384, -0.1783723384141922, -0.1383984088897705, -0.4566081464290619, 0.03644062951207161, 0.08079122006893158, 0.42221927642822266, -0.27114337682724, -0.1334616243839264, 0.1006198450922966, ...
def test _ qv _ success ( self ) : dir _ name = os. path. dirname ( os. path. abspath ( _ _ file _ _ ) ) successful _ json _ file = " qv _ data _ moderate _ noise _ 300 _ trials. json " with open ( os. path. join ( dir _ name, successful _ json _ file ), " r ", encoding = " utf - 8 " ) as json _ file : successful _ dat...
[ -0.19573692977428436, 0.18983052670955658, 0.6729837656021118, -0.3244986832141876, -0.11538974940776825, 0.6150474548339844, 0.47496768832206726, -0.7055917978286743, 0.28388139605522156, -0.2254638373851776, -0.6144935488700867, 0.19618509709835052, 0.20586667954921722, -0.08668109774589...
def accept _ notes ( port, channel ) : for message in port : if message. type in ('note _ on ','note _ off') : print ( message ) if message. channel = = channel : yield message
[ 0.4146595895290375, -0.23189890384674072, 0.6928467750549316, -1.131211757659912, 0.04865121468901634, 0.38863715529441833, -0.4232933223247528, -1.4647611379623413, -0.39153924584388733, 0.8237223625183105, 0.2901444137096405, 1.0093998908996582, -1.1785215139389038, 0.4588194787502289, ...
def size ( self ) : return pix2coord ( self. _ xsize, self. _ ysize, self. samplerate, self. c )
[ 0.628258466720581, -0.794797420501709, 0.5684692859649658, -1.351806879043579, -0.056472089141607285, -0.2596365213394165, -0.017711613327264786, -1.020469069480896, 0.5386021137237549, -0.8866365551948547, -0.38104116916656494, -0.10770034790039062, -0.1849067509174347, -0.251325249671936...
def deleteruleonlogicalinterface ( self, logicalinterfaceid, ruleid ) : req = apiclient. oneruleforlogicalinterfaceurl % ( self. host, " / draft ", logicalinterfaceid, ruleid ) resp = requests. delete ( req, auth = self. credentials, verify = self. verify ) if resp. status _ code = = 204 : self. logger. debug ( " logic...
[ 0.5176379084587097, -0.3420102894306183, 0.1533675640821457, -1.0286442041397095, 0.3442741632461548, 0.7266542911529541, -0.8285556435585022, 0.24137678742408752, 0.6176449060440063, 0.49116483330726624, 0.11030828207731247, 0.6872734427452087, -2.1220602989196777, 0.6506319046020508, 0...
def _ default _ coord _ mapping ( search _ range, level ) : return _ points _ to _ arr ( level ) / search _ range
[ -1.1855627298355103, -0.5411255359649658, 0.2633937895298004, 0.03363814949989319, 0.24586430191993713, 0.3861047029495239, 0.45711758732795715, -0.3949386179447174, -0.9287059903144836, -0.015972651541233063, 0.1892949640750885, -0.8012416362762451, 0.0763912945985794, -0.5126195549964905...
def log _ sigmoid ( x, name = none ) : with ops. name _ scope ( name, " logsigmoid ", [ x ] ) as name : x = ops. convert _ to _ tensor ( x, name = " x " ) return gen _ math _ ops. neg ( gen _ nn _ ops. softplus ( - x ), name = name ) # pylint : disable = invalid - unary - operand - type
[ -0.7056760191917419, 0.6833109259605408, 0.6346368193626404, 0.8744003176689148, -1.177520751953125, 0.2534894049167633, -1.0597898960113525, -0.3267521858215332, 1.1198294162750244, 0.31272122263908386, -1.0452128648757935, 0.2625289857387543, 0.2128307968378067, -1.0008257627487183, 0....
def test _ atomic _ language _ enumeration _ 1 _ nistxml _ sv _ iv _ atomic _ language _ enumeration _ 2 _ 5 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / language / schema + instance / nistschema - sv - iv - atomic - language - enumeration - 2. xsd ", instance = " nistda...
[ -0.3770025670528412, -1.1407902240753174, 0.487032026052475, 0.6637542247772217, -0.5585260987281799, 0.005538193974643946, 0.5453401803970337, -0.059417858719825745, -0.6234511733055115, 0.7853430509567261, -0.7866291403770447, 0.1002926155924797, 0.4766713082790375, 0.34335267543792725, ...
def customer _ profile _ id ( self, customer _ profile _ id ) : self. _ customer _ profile _ id = customer _ profile _ id
[ 1.9430230855941772, -0.13373661041259766, -0.04110453650355339, 0.8986666798591614, -0.12832383811473846, 0.4649096131324768, 0.08650461584329605, 0.39939773082733154, -0.3004172146320343, 0.5192021131515503, -1.864852786064148, -0.4403044283390045, -0.7002742886543274, 0.43428295850753784...
def test _ init ( self ) : p = rtaxtaxonassigner ( { } ) self. assertequal ( p. name,'rtaxtaxonassigner') # default parameters correctly initialized default _ params = {'id _ to _ taxonomy _ fp': none,'reference _ sequences _ fp': none,'header _ id _ regex': " \ \ s + \ \ s + ( \ \ s +? ) \ / ",'read _ id _ regex': " \...
[ -0.07200317084789276, -0.9883239269256592, 0.41653040051460266, -0.45324358344078064, 0.6617578268051147, 0.03069636970758438, -0.0865783616900444, 0.47738826274871826, -0.9016203284263611, 0.20641320943832397, -0.15518639981746674, -0.4392792284488678, -0.30085715651512146, 0.143094852566...
def prepare _ cohort _ pairsets _ for _ metadata _ exports ( latest _ tsca _ id, blacklist, paths _ to _ samples _ info, google _ bucket _ id ) : # download remote pairs download _ remote _ pairs ( namespace, workspace ) # retrieve pairs pairs = pd. read _ table ('pairs / remote _ pairs. txt') # get all samples with co...
[ 0.09304555505514145, -0.42823198437690735, 0.4404885470867157, -0.23439756035804749, -0.5080645680427551, -0.28651729226112366, 0.11479409039020538, 0.1943933665752411, 0.5306311845779419, 1.0467065572738647, 0.7022207379341125, 0.5859097838401794, 0.23219817876815796, 0.320674329996109, ...
def backward ( ctx : any, grad _ output : tensor ) - > tuple [ optional [ tensor ], optional [ tensor ], optional [ tensor ], optional [ tensor ], optional [ tensor ] ] : # call the backward function in the tile instance. grad _ input = ctx. analog _ tile. backward _ indexed ( grad _ output ) # store the parameters nee...
[ -0.370435506105423, 0.17486213147640228, 0.6002426147460938, -0.1866791993379593, 0.5006225109100342, -0.302309513092041, 1.166813611984253, -1.0460556745529175, -0.5459592938423157, 0.061004333198070526, -0.3133730888366699, 0.4325411021709442, -0.2754148840904236, -0.9254968166351318, ...
def sha512 ( message ) : return hashlib. sha512 ( to _ bytes ( message ) ). hexdigest ( )
[ 0.9942551851272583, -0.4563787579536438, 0.24470464885234833, -0.4219687581062317, -1.6437513828277588, -0.2538259029388428, -1.3011835813522339, -0.26908984780311584, 0.7748684287071228, -0.24620507657527924, 0.5999009013175964, 0.15568552911281586, -0.9165385961532593, -0.091798536479473...
def getcameraname ( self ) : return self. cname
[ -0.7408421635627747, -1.0840481519699097, 0.6045573353767395, 0.7207856774330139, -0.770898699760437, 0.5902920961380005, 0.15317167341709137, -0.46295949816703796, 0.28774377703666687, 0.3447166383266449, -0.2790237367153168, -0.1000949814915657, -0.04205993935465813, 0.43533340096473694,...
def _ _ init _ _ ( self, graph ) : self. graph = graph
[ 0.5112175345420837, -0.05133515223860741, 0.10561695694923401, 0.5395224690437317, -0.23342333734035492, 0.31094974279403687, 0.16575998067855835, 0.8913241624832153, 0.11297135800123215, -0.19937507808208466, -0.27921804785728455, 0.1395077109336853, 0.16408227384090424, 0.347189009189605...
def install _ calamari ( distro = none ) : distro = distro or get _ distro ( ) logger. debug ('installing calamari...') pkgs = distro. pkg _ manager. enumerate _ repo ('/ opt / ice / calamari'). split ( ) distro. pkg _ manager. install ( pkgs )
[ -0.5022298097610474, 0.5153299570083618, 0.4775916039943695, 0.8038609623908997, 0.006964367348700762, 1.1323399543762207, -0.2038246989250183, 0.528748631477356, -0.26858749985694885, 0.7851190567016602, -0.12982255220413208, -0.45656585693359375, -0.6886508464813232, 0.2207525223493576, ...
def admin _ user _ global _ sign _ out ( userpoolid = none, username = none ) : pass
[ -0.6847950220108032, 0.4347895681858063, 0.2663274109363556, 0.8364490270614624, -0.3429792821407318, 0.5726112127304077, 1.4525624513626099, 0.2166435271501541, -0.41467422246932983, 0.9414182305335999, -0.9997244477272034, 1.6971081495285034, -1.4961947202682495, 0.08930167555809021, 0...
def http _ stacta ( http _ testdata _ dir ) : return http _ testdata _ dir / " cleantopo " / " cleantopo. json "
[ -0.4863883852958679, -1.293987512588501, 0.2601131498813629, -1.0549240112304688, 0.22547908127307892, 0.5797300934791565, 0.6026676893234253, -0.16101400554180145, -0.4056800305843353, 0.09917914122343063, 0.46202516555786133, 1.142358422279358, 0.9575344920158386, -0.8679539561271667, ...
def process _ cleaning _ fee ( self, df, col ='cleaning _ fee') : # copy all columns except the cleaning fee new _ df = df [ [ c for c in df. columns if c! = col ] ] # fill na with zero new _ df [ col ] = df [ col ]. fillna ('0') new _ df [ col ] = new _ df [ col ]. apply ( lambda x : x. replace ('$ ','' ). replace ( '...
[ 0.484914094209671, 0.6747283935546875, 0.6205078363418579, 0.25914230942726135, -0.2207319289445877, -0.24494609236717224, -0.12927624583244324, 0.8239851593971252, -0.11846887320280075, 1.012125849723816, 0.4814564883708954, 0.6967193484306335, 0.837931215763092, 0.4066842198371887, 1.4...
def grid _ search _ cv _ plot ( params, combinations, accuracies, filename = none ) : # get names of varied parameters plot _ axes = [ x for x in params. keys ( ) if " random _ state " not in x ] ndim = len ( plot _ axes ) assert ndim < = 3 # get list of points points = { name : [ ] for name in plot _ axes } points [ "...
[ 0.8172661066055298, 0.18023568391799927, 0.8323184251785278, -0.1251819133758545, -0.18486516177654266, 0.32078176736831665, 0.5725146532058716, 0.12925079464912415, -0.27085721492767334, 0.0746954157948494, 0.897285521030426, 0.9738849997520447, 0.6430023908615112, -0.22351160645484924, ...
def getdevicelocation ( self, typeid, deviceid ) : deviceurl = apiclient. deviceurllocation % ( self. host, typeid, deviceid ) r = requests. get ( deviceurl, auth = self. credentials, verify = self. verify ) status = r. status _ code if status = = 200 : self. logger. debug ( " device location was successfully obtained ...
[ -1.7613837718963623, -0.8114857077598572, 0.6590893864631653, 0.3671922981739044, -0.0729425922036171, -0.4037370979785919, 0.502166748046875, -1.069435954093933, -0.0639166310429573, 0.20396900177001953, 0.28640326857566833, 1.1513992547988892, -0.712924063205719, 0.0016685641603544354, ...
def league _ to _ teams ( league ) : tds = json. loads ( gd. get _ teams _ data ( ) ) teams = [ ] if season is none : for i in range ( len ( tds ) ) : td = tds [ i ] leagues = sorted ( list ( td ['leagues']. keys ( ) ) ) if league in leagues : teams = sorted ( list ( td ['leagues'] [ league ] ) ) break else : td = tds ...
[ 0.29491978883743286, -0.4583486318588257, 0.6757577061653137, -0.7408984899520874, -0.14391350746154785, -0.4163423776626587, -0.7871426939964294, -0.37809479236602783, 0.7710313200950623, 0.1674162596464157, -0.13098636269569397, 0.6382864713668823, 0.9516653418540955, -0.0016386709176003...
def isic _ request ( response, num = 100 ) : start _ url = f'https : / / isic - archive. com / api / v1 / image? limit = { num } \ & sort = name & sortdir = 1 & detail = true'headers = {'accept':'application / json'} r = requests. get ( start _ url, headers = headers ) data = r. json ( ) return data
[ -1.141966462135315, 0.014186544343829155, 0.6317679286003113, -0.000010939477760985028, 0.23277898132801056, -0.9912591576576233, -0.6192435026168823, -0.34521210193634033, 0.19058279693126678, 0.6308541893959045, -0.4583706855773926, 0.8216331005096436, -0.15617193281650543, -1.1538375616...
def choose ( n, k ) : if 0 < = k < = n : ntok = 1 ktok = 1 for t in range ( 1, min ( k, n - k ) + 1 ) : ntok * = n ktok * = t n - = 1 return ntok / / ktok else : return 0
[ -0.14143283665180206, 0.5713111162185669, 0.5964630246162415, 0.7242382168769836, -0.4076959788799286, -0.4444061517715454, 0.293894499540329, -0.5819393396377563, -0.39606648683547974, 0.10064619779586792, -0.1398262232542038, -0.3498971462249756, -0.18120011687278748, 0.7249667644500732,...
def listmethods ( self, request, context ) : context. code ( beta _ interfaces. statuscode. unimplemented )
[ -1.2152079343795776, -0.04790188744664192, 0.2924884259700775, 0.3702049255371094, 0.7906677722930908, -0.5589110255241394, 0.06703636795282364, -1.2791626453399658, 0.41531801223754883, -0.3573552370071411, -0.4711196720600128, 0.3634994626045227, -0.5754351019859314, 0.3018852174282074, ...
def test _ n _ user _ download _ dir ( self ) - > none : # directory is set by the system and does not exist download _ path = user _ download _ dir ( app _ name ='fake _ download _ dir _ for _ tests') self. assertisnotnone ( download _ path ) self. assertfalse ( download _ path. is _ dir ( ) ) download _ path = user _...
[ -0.21901164948940277, 0.14474397897720337, 0.47866493463516235, 0.7370585799217224, 1.0006508827209473, 0.1470523476600647, -0.0016944275703281164, -0.649153470993042, 0.8912693858146667, -0.6537840962409973, -0.23398834466934204, 0.14895978569984436, 0.9456639289855957, 0.8146408200263977...
def file _ name ( video _ name ) : video _ name = str ( video _ name ) text _ video = str ( video _ name [ 13 : - 4 ] ) + ". txt " return text _ video
[ 0.06060943007469177, -1.310241937637329, 0.6547792553901672, 0.015474704094231129, -0.6602454781532288, 0.1317020058631897, -0.49875688552856445, 0.5525692105293274, 0.4098866879940033, 1.142691731452942, 0.021833190694451332, 0.7797377705574036, -0.111061692237854, -0.22476184368133545, ...
def test _ atomic _ qname _ min _ length _ nistxml _ sv _ iv _ atomic _ qname _ min _ length _ 1 _ 3 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / qname / schema + instance / nistschema - sv - iv - atomic - qname - minlength - 1. xsd ", instance = " nistdata / atomic / qn...
[ 0.3798859417438507, -0.3456571698188782, 0.4449300169944763, -0.09834050387144089, -0.4582848846912384, 0.565719723701477, -0.43276870250701904, -0.7050900459289551, 1.1071181297302246, 0.3495412766933441, -0.23158380389213562, -0.18270084261894226, -0.6425185799598694, -0.3283233344554901...
def mock _ connection _ init _ fixture ( ) : with patch ( " homeassistant. components. homematicip _ cloud. hap. asynchome. init ", return _ value = none, ), patch ( " homeassistant. components. homematicip _ cloud. hap. asyncauth. init ", return _ value = none, ) : yield
[ -0.12228287011384964, -0.6394773125648499, 0.7036269307136536, 0.19831377267837524, 0.3319747745990753, -0.33553943037986755, 0.031298015266656876, 0.26073917746543884, 0.344113290309906, -0.06057560816407204, 0.22997476160526276, -1.1024181842803955, -0.19703012704849243, -0.3697370886802...
def make _ marker ( angle ) : my _ marker = marker ( type = marker. arrow ) my _ marker. header. frame _ id = " odom " # we only rotate in one plaen, quaternion only uses two values quaternion = quaternion _ from _ euler ( math. radians ( angle ), 0. 0, 0. 0 ) my _ marker. pose. orientation. x = quaternion [ 0 ] my _ m...
[ -0.9504509568214417, -0.42041802406311035, 0.6303812861442566, -0.9193915724754333, -0.027905337512493134, 0.13211292028427124, 0.36775240302085876, -0.39662644267082214, 0.8289240002632141, -0.19426648318767548, -0.8725565075874329, 0.018469344824552536, -0.032462265342473984, -0.67672145...
def addlisttolist ( self, list, title ) : if len ( list ) = = 0 : return self. music = [ ] if self. listname = = title : self. listwidget. clearcontents ( ) self. currentindex = - 1 self. listname = title self. music. extend ( list ) self. currentindex = - 1 # if self. playing = = 0 : # self. currentindex = temp = - 1 ...
[ -1.30386221408844, -0.01992090418934822, 0.7439376711845398, -0.18612557649612427, 0.15477228164672852, 1.305110216140747, -0.24860906600952148, 0.21251654624938965, 1.3019660711288452, 0.2639343738555908, -0.7834306359291077, -0.47465449571609497, -0.9927026033401489, 0.5847477316856384, ...
def is _ prime ( num ) : if num < = 0 : raise valueerror ('number being checked for prime - ness must be positive.') if num = = 2 : return true numbers = range ( 2, num ) for i in numbers : if num % i = = 0 : return false return true
[ -0.8052172660827637, 0.3180884122848511, 0.49093762040138245, 1.1784169673919678, 0.3030533194541931, 0.40870875120162964, -0.9374273419380188, 0.15369319915771484, 0.8025822639465332, -0.7061972618103027, -0.07696457207202911, -0.7721720933914185, -0.6894459128379822, 0.5375548601150513, ...
def drawmana ( self, hero : hero, position ) : mana = self. main _ font. render ( str ( hero. mana ) + " / " + str ( hero. max _ mana ), true, configuration. main _ font _ white ) if position = = configuration. top : self. window. blit ( mana, configuration. mana _ top _ position ) else : self. window. blit ( mana, con...
[ 0.008971965871751308, -0.20675013959407806, 0.6082584261894226, -0.3659786581993103, -0.6497888565063477, 0.46193692088127136, -0.36100462079048157, 0.6284478306770325, 0.5740740895271301, -0.24955514073371887, 0.39959293603897095, 0.5188283920288086, 0.07975812256336212, 0.412926822900772...
def updatedevice ( self, typeid, deviceid, metadata, deviceinfo = none, status = none ) : deviceurl = apiclient. deviceurl % ( self. host, typeid, deviceid ) payload = {'status': status,'deviceinfo': deviceinfo,'metadata': metadata } r = requests. put ( deviceurl, auth = self. credentials, data = json. dumps ( payload ...
[ -1.7494584321975708, -0.8268868923187256, 0.801202654838562, 0.48839154839515686, -0.5056651830673218, 0.12488453090190887, -0.14467422664165497, 0.12204374372959137, -0.25102055072784424, 0.6631401181221008, 0.09032969921827316, 1.0289016962051392, -1.4555877447128296, -0.1540942937135696...
def get _ platform _ parameter ( self, param, silent = false ) : # pytau. start ( self. timers ['get _ platform _ parameter'] ) val = none try : val = self. platform _ conf [ param ] except keyerror, ex : if not silent : self. fwk. warning ('cm : no platform data for % s ', param ) # pytau. stop ( self. timers ['get _ ...
[ 0.3199281096458435, 0.12731364369392395, 0.3599449396133423, 0.08113951981067657, -0.9126330018043518, 0.26021939516067505, 0.7085530161857605, -0.6664411425590515, -0.6190889477729797, 0.38375258445739746, 0.07207030802965164, 0.27819493412971497, -0.9821183085441589, 0.8842546343803406, ...
def links ( self ) : return self. _ links
[ -0.7752522826194763, -0.22537222504615784, 0.09558562934398651, 0.2511408030986786, 0.891920268535614, 0.6692816019058228, 0.013096191920340061, 0.532479465007782, 0.6986308693885803, -2.413895606994629, -0.4364405572414398, 0.5816490650177002, -0.5345443487167358, 0.04284270852804184, -...
def plotter3d ( df, plot _ title, kwargs = none ) : parameters = {'plot _ title':'s ','x':'compensation ','x _ units':'td ','y':'av _ disp ','y _ units':'td ','z':'height ','z _ units':'pa ','groupvar':'band ','groupvar _ values': [ 0, 1, 2, 3, 4, 5, 6, 7, 8 ], } if kwargs is none : kwargs = parameters traces = [ ] # c...
[ 0.023135533556342125, 0.5642462968826294, 0.9959043264389038, 0.14384175837039948, -0.3459948003292084, 0.549450695514679, 0.5351124405860901, -0.48566189408302307, -0.2891443967819214, 0.3871443569660187, 0.08710508048534393, 0.6884512901306152, -0.028240129351615906, -0.1944073736667633,...
def auth _ login ( self, challenge = none ) : if challenge is none : return self. user else : return self. password
[ -0.33304932713508606, -0.43131592869758606, 0.47013550996780396, 1.0375491380691528, -0.7743110060691833, -0.22730745375156403, -0.01900508627295494, 0.00108915357850492, 0.9157501459121704, -0.6333547234535217, 0.27700236439704895, -0.15147915482521057, 0.04489649832248688, -0.45629179477...
def validate ( self, allow _ empty = true, allow _ wildcards = true, allow _ backref = true ) : all _ empty = true wildcard _ used = false backref _ used = false backref _ re = re. compile ('@ \ d +') for key in ( " artifactid ", " groupid ", " extension ", " version ", " classifier ", " namespace " ) : val = getattr (...
[ -0.3926379084587097, -0.10826220363378525, 0.767814576625824, -0.308357298374176, 0.006854687817394733, 0.6719250679016113, 0.864082396030426, 0.11192985624074936, -0.8098686933517456, 0.373818963766098, 0.6265859007835388, 0.9209644794464111, -0.8076503872871399, 0.20054441690444946, 0....
def _ get _ max _ bw _ threshold _ absolute ( self ) : return self. _ _ max _ bw _ threshold _ absolute
[ 0.3894217908382416, -1.011736512184143, 0.9246627688407898, 1.084271788597107, -0.20745408535003662, 0.8201651573181152, -0.34386515617370605, -0.28431594371795654, -0.8331477046012878, -0.14169929921627045, -0.22378931939601898, 1.001960039138794, -0.39737096428871155, 0.6630814671516418,...
def update _ params ( self, other _ model ) : assert other _ model is not self. model for name, param in other _ model. named _ parameters ( ) : if name in self. shadow : self. _ update _ param ( name, param. data )
[ -0.3257163465023041, -0.6896080374717712, 0.6632381677627563, 0.10835745185613632, -0.2902766168117523, 0.5900699496269226, -0.4793948233127594, -0.3780891001224518, -0.5370285511016846, 1.1240122318267822, -0.9214061498641968, 0.6921154260635376, 0.12775181233882904, 1.7311594486236572, ...
def best _ yelp _ id _ with _ name ( location, category, coordinate _ str = none, disallowed _ yelp _ ids = [ ], strategy _ name = " distance " ) : extra _ yelp _ params = { } if coordinate _ str is not none : extra _ yelp _ params ['cll'] = coordinate _ str # for these strategies, use yelpapi # then reset strategy _ n...
[ 0.2265072613954544, -1.4502793550491333, 0.8312371373176575, -0.1364278346300125, -0.5514718294143677, -0.2540850043296814, -0.7615150809288025, -0.04867527261376381, 0.4352123737335205, 0.8955305218696594, -0.15932968258857727, 0.6776852011680603, 0.11361180990934372, 0.5339221954345703, ...
def anagram ( string1, string2 ) : return to _ hash ( string1 + string2 ) = = 0
[ 0.06945326924324036, -0.1088903620839119, 0.45644325017929077, 0.7940493822097778, -0.9646240472793579, 0.5721433758735657, -1.6361491680145264, 0.047206297516822815, -0.028395038098096848, 0.5862257480621338, -0.25456252694129944, 0.9437165260314941, -0.230440154671669, -0.794248938560485...
def _ get _ args _ for _ reloading ( ) : rv = [ sys. executable ] py _ script = sys. argv [ 0 ] if os. name = ='nt'and not os. path. exists ( py _ script ) and \ os. path. exists ( py _ script + '. exe') : py _ script + = '. exe'if os. path. splitext ( rv [ 0 ] ) [ 1 ] = = '. exe'and os. path. splitext ( py _ script ) ...
[ -0.7541797757148743, -0.8752579092979431, 0.8519047498703003, 0.1783132404088974, 1.0007421970367432, -0.07401100546121597, -0.058306869119405746, -0.33317112922668457, -0.055714335292577744, 0.9249322414398193, -0.052468106150627136, 0.684623122215271, -0.29363176226615906, 0.602583765983...
def from _ json ( cls, representation ) : return cls ( property = representation ['property'], prefix = representation. get ('prefix') )
[ -0.37242814898490906, -1.1739479303359985, 0.2284671515226364, -1.1999869346618652, -0.811751663684845, -0.33474528789520264, -0.6978912353515625, 0.1668197214603424, 1.145748257637024, 0.7368232011795044, -0.30316054821014404, -0.21665872633457184, 0.7777466177940369, -1.0804814100265503,...
def cost ( u : dict, v : dict ) - > tuple : u, v = set ( u. keys ( ) ), set ( v. keys ( ) ) # anime in v that's not in u is an addition # anime in u that's not in v is a removal return len ( v - u ), len ( u - v )
[ -0.6675841212272644, 0.5779783129692078, 0.5632631182670593, -1.1053638458251953, -0.768375813961029, -0.054032858461141586, 0.3295848071575165, 1.11650812625885, 0.4970701336860657, 1.0441744327545166, -0.8882821202278137, -0.09035854786634445, -0.21270640194416046, -0.4624537229537964, ...
def parse _ sentiment ( nn _ sent, nn _ sent _ all ) : pos _ count = nn _ sent [ 0 ] ['positive'] + nn _ sent [ 0 ] ['verypositive'] pos _ count _ all = nn _ sent _ all [ 0 ] ['positive'] + nn _ sent _ all [ 0 ] ['verypositive'] pos _ percent = float ( pos _ count ) / nn _ sent [ 1 ] pos _ percent _ all = float ( pos _...
[ -0.24290180206298828, -1.6156874895095825, 0.8502670526504517, -0.9623968005180359, -0.0008923463174141943, -0.012468444183468819, -1.1135066747665405, -0.4938041567802429, -1.0067485570907593, 0.8196261525154114, -0.45278772711753845, -0.7001686692237854, 0.3688428997993469, 0.53824484348...
def _ get _ trust ( self ) : return decimal ('0. 5')
[ 0.3846046030521393, -0.8046505451202393, 0.39453232288360596, -0.40731704235076904, 0.34271323680877686, 0.5278980135917664, 0.33081045746803284, -0.6578800678253174, -1.0735276937484741, 0.1988557130098343, 0.019283689558506012, 0.17240765690803528, -0.3994462192058563, -0.449224412441253...
def polynomialcod ( sol, x, y ) : # compute ybar n = len ( x ) ybar = 1 / n * sum ( y ) # compute sstot sstot = sum ( [ ( y [ i ] - ybar ) * * 2 for i in range ( len ( y ) ) ] ) # calculate ssres power = len ( sol ) ssres = sum ( [ ( y [ i ] - sum ( [ sol [ j ] * x [ i ] * * ( power - ( j + 1 ) ) for j in range ( power...
[ 0.38098177313804626, 0.08410139381885529, 0.6855762600898743, 0.0673883706331253, -0.8832593560218811, 0.3142312467098236, 0.2647777497768402, -0.5170924067497253, 0.684593677520752, 0.6086089611053467, 0.13208307325839996, 0.2249087542295456, 0.17786705493927002, -0.41686734557151794, -...
def tasks _ db ( dag _ id, execution _ date ) : return [ {'task _ id':'1a ','dag _ id':'did2 ','execution _ date': date _ one,'state':'success ','run _ id':'12345 ','external _ trigger':'something ','start _ date': date _ one,'end _ date': date _ one,'duration':'20mins ','try _ number':'1 ','operator':'smooth ','queued...
[ 0.061334479600191116, 0.7165519595146179, 0.8989498615264893, -0.22406592965126038, -0.2410673201084137, 0.11652271449565887, 0.14413774013519287, 0.15848220884799957, -1.2133300304412842, 0.3124299943447113, -0.7400556802749634, 0.02365729585289955, 1.176883578300476, 0.4335803687572479, ...
def initialize _ states ( self, pop, exd, init _ mode, init _ data ) : raise notimplementederror
[ -0.46047359704971313, -0.5792948007583618, 0.4061511754989624, -0.02631334960460663, -0.0035613607615232468, 0.6048444509506226, -0.20117296278476715, 0.14693337678909302, 0.1798931211233139, 0.3320419192314148, -0.4110100567340851, -0.47932878136634827, 0.6368284225463867, -0.335058391094...
def _ _ init _ _ ( self, * * kwargs ) : cls = type ( self ) if not getattr ( cls,'action ', none ) : raise valueerror ('no action to call. provide an action.') if ( not getattr ( cls,'success _ url ', none ) and not getattr ( cls,'get _ success _ url ', none ) ) : raise valueerror ('no url to redirect to. provide a suc...
[ -0.4610757529735565, 0.6940633654594421, 0.6823039054870605, 0.7892930507659912, 0.4171742796897888, 0.3881387412548065, 0.07686848938465118, -0.05344468355178833, 0.7379273176193237, -0.2620956599712372, 0.22774170339107513, 0.609588623046875, 0.713525652885437, 0.9328310489654541, 0.59...
async def return _ async _ value ( value ) : return value
[ -0.4593944549560547, 0.4008557200431824, 0.2512909173965454, 0.04344340041279793, -0.4279283881187439, -0.7635551691055298, -0.23780924081802368, -0.5140236020088196, 0.13700233399868011, -0.14053437113761902, 0.6477303504943848, 0.35005566477775574, 0.3351120948791504, -0.4918860197067261...
def test _ natsel _ timehet _ mprobs ( self ) : opt = dict ( max _ evaluations = 2, limit _ action = " ignore " ) aln = load _ aligned _ seqs ( " data / ensg00000198712. fa ", moltype = " dna " ) natsel = evo _ app. natsel _ timehet ( " mg94hky ", tip1 = " human ", tip2 = " chimp ", opt _ args = opt, gc = 2, optimise _...
[ -0.12650522589683533, -0.20452052354812622, 0.5139734745025635, -0.5209502577781677, 0.6132044196128845, 0.583109974861145, -0.7822645306587219, -0.6333946585655212, -0.32559603452682495, 0.7538378834724426, 0.026162732392549515, -0.14737814664840698, -0.23768676817417145, 0.05089669302105...
def get _ alarm _ inputs ( ) : # gets the alarm time from the new alarm input box and calculates delay. alarm _ time = request. args. get ( " alarm " ) alarm _ label = request. args. get ( " alarm _ label " ) alarm _ repeat = request. args. get ( " alarm _ repeat " ) alarm. run ( blocking = false ) # gets the time for ...
[ -0.3810088038444519, -0.04764476418495178, 0.702807605266571, 0.8466434478759766, 0.7433481216430664, -0.021536588668823242, -0.046129122376441956, -0.24806493520736694, -0.38460126519203186, -0.09501326829195023, 0.00031753789517097175, 0.41056787967681885, -0.13285724818706512, 0.4295609...
def test _ example _ input _ one _ edit _ close _ entity ( self, ucc _ smartx _ selenium _ helper, ucc _ smartx _ rest _ helper, add _ input _ one ) : input _ page = inputpage ( ucc _ smartx _ selenium _ helper, ucc _ smartx _ rest _ helper ) input _ page. table. edit _ row ( " dummy _ input _ one " ) self. assert _ ut...
[ -0.6228377819061279, 0.2933482825756073, 0.5068944692611694, 0.62831711769104, 0.4407542049884796, 0.8528099656105042, 0.5295193195343018, -0.006634221877902746, 0.5452671647071838, 0.34650248289108276, 0.4757346212863922, -0.3423628509044647, -0.09287349879741669, 0.5167128443717957, 0....
def _ class _ labels _ to _ ids ( labels _ path : str, ) - > dict : class _ labels = { } with open ( labels _ path, " r " ) as class _ labels _ file : class _ id = 1 for class _ label in class _ labels _ file : class _ labels [ class _ label. strip ( ) ] = class _ id class _ id + = 1 return class _ labels
[ -1.2300474643707275, -1.1135252714157104, 0.41980329155921936, -1.0601261854171753, 0.3643515408039093, 0.4398512542247772, -0.1407189667224884, -0.1453196257352829, -0.23767636716365814, 0.9098877906799316, -1.2071799039840698, -0.4909308850765228, 0.2652026116847992, -0.2611995339393616,...
def network _ id ( self, network _ id ) : self. _ network _ id = network _ id
[ 0.3387468755245209, -0.5651521682739258, -0.38317739963531494, 0.9631145596504211, 1.388139247894287, 1.2012320756912231, -0.28978830575942993, 0.8155481815338135, 0.659420371055603, -0.5424840450286865, -0.7243451476097107, 0.02359822206199169, 0.08528845757246017, 1.4501571655273438, -...
def new ( * args, * * kargs ) : obj = itksubtractconstantfromimagefiltericf3cficf3. _ _ new _ orig _ _ ( ) import itktemplate itktemplate. new ( obj, * args, * * kargs ) return obj
[ 1.6204677820205688, -0.43179935216903687, 0.17012086510658264, -0.4629332423210144, 0.19858013093471527, -0.23052087426185608, 1.0139645338058472, 0.28907254338264465, -0.30161112546920776, -0.016681049019098282, -1.4209182262420654, -0.7923495769500732, 0.13838118314743042, -0.30520975589...
def lower _ optimized _ joint _ limits ( self ) - > cs. dm : return cs. dm ( [ self. get _ joint _ lower _ limit ( jnt ) for jnt in self. urdf. joints if jnt. name in self. optimized _ joint _ names ] )
[ -0.2107495814561844, -0.24467971920967102, 0.4739600419998169, -0.27223822474479675, 0.2105889618396759, -0.17982564866542816, -0.2911912500858307, -0.9785263538360596, -0.4611896872520447, -0.49111324548721313, -0.012578412890434265, 0.7503876090049744, -0.9315207004547119, -1.03702747821...
def _ build _ ssh _ cmd ( self, instance _ data, what ) : base = " ssh % s - i % s % s @ % s - p % s " % ( self. _ ssh _ params ( instance _ data ), instance _ data. ssh. keyfile, instance _ data. ssh. user, instance _ data. ssh. host, instance _ data. ssh. port ) if what is none or what = = " " : return base return " ...
[ -0.47340694069862366, -1.1820640563964844, 0.7860839366912842, -0.40989813208580017, 0.5699604153633118, 0.7555722594261169, -0.9431488513946533, -0.22891877591609955, -0.5559788942337036, -0.3432523310184479, 0.3811899721622467, 0.9536905884742737, 0.016931913793087006, -0.657950341701507...
def test _ report _ skeleton ( snapshot, clients ) : client, _ = clients rsp = client. get ( " / api / v1 / result - tree " ) assert rsp. status _ code = = 200 rsp _ json = rsp. get _ json ( ) assert rsp _ json [ " status " ] = = " init " snapshot. assert _ match ( rsp _ json )
[ 0.021987304091453552, 0.8120608329772949, 0.5794957876205444, -0.5713587999343872, 0.9238956570625305, -0.08476536720991135, 0.008195426315069199, -0.14242804050445557, -0.12978674471378326, -0.8954156637191772, -0.48983651399612427, 0.16061945259571075, -0.3028866648674011, -0.06711708754...