text stringlengths 25 2.19k | embedding listlengths 768 768 |
|---|---|
def save _ plot ( self, i ) : plt. figure ( i ) front = self. memory _ archive. contents [ 0 ] fvals = [ rec. fx for rec in front ] fvals = np. asarray ( fvals ) maxgen = ( self. maxeval - self. numinit ) / ( self. nsamples * self. ncenters ) curgen = ( self. numeval - self. numinit ) / ( self. nsamples * self. ncenter... | [
0.4543827474117279,
0.24426935613155365,
0.6411647200584412,
-0.5042865872383118,
0.010993458330631256,
0.46613702178001404,
0.6728544235229492,
0.45953893661499023,
-0.818790078163147,
-0.8749189972877502,
-0.7611411213874817,
0.33244380354881287,
-0.14832843840122223,
0.40149301290512085... |
def get _ data ( self, node ) : raise notimplementederror ( ) | [
-0.7937968969345093,
0.33339452743530273,
0.5091954469680786,
-0.2129025012254715,
0.22160033881664276,
0.8494154810905457,
-0.7367168664932251,
-0.7390745878219604,
-0.37016892433166504,
-0.6738060116767883,
-0.48742836713790894,
1.104162573814392,
0.9214754104614258,
0.3244152069091797,
... |
def from _ expr ( problem, expr ) : raise notimplementederror ('tag. from _ expr') | [
0.1434716135263443,
-0.7585956454277039,
0.5492229461669922,
-0.03531896322965622,
-0.6440842747688293,
-0.49968546628952026,
-0.48337113857269287,
0.7469711303710938,
-0.07973714172840118,
0.248439222574234,
0.252066969871521,
0.025376368314027786,
1.177277684211731,
-0.15221169590950012,... |
def df _ optimize ( df : pd. dataframe, catg _ conv _ threshold : float = 0. 4 ) : numerics = [ " int16 ", " int32 ", " int64 ", " float16 ", " float32 ", " float64 " ] strings = [ " object " ] df _ size = df. shape [ 0 ] start _ mem = df. memory _ usage ( ). sum ( ) / 1024 * * 2 for col in df. columns : col _ type = d... | [
0.4331856071949005,
0.11732443422079086,
1.1030584573745728,
0.01973826065659523,
0.7038816809654236,
-0.482034832239151,
-0.013209346681833267,
-1.2113205194473267,
-0.7133564352989197,
0.17264215648174286,
-0.1909109354019165,
0.6837171912193298,
0.2072981595993042,
0.17482179403305054,
... |
def return _ session _ credentials ( self ) : return self. session ['credentials'] | [
-0.9550895690917969,
-1.381805419921875,
0.3420844078063965,
0.45036476850509644,
-0.42066317796707153,
-0.5447843670845032,
-0.07931618392467499,
-0.9917341470718384,
0.8649611473083496,
0.19608080387115479,
-0.4369657039642334,
0.12060809135437012,
-0.3705997169017792,
-1.088618040084838... |
async def async _ setup _ entry ( hass : homeassistant, entry : configentry, async _ add _ entities : addentitiescallback, ) - > none : coordinator = hass. data [ domain ] [ entry. entry _ id ] async _ add _ entities ( [ tololampnextcolorbutton ( coordinator, entry ), ] ) | [
0.31501758098602295,
0.5499054789543152,
0.3265816867351532,
-0.8006139397621155,
1.0235644578933716,
-0.0742967277765274,
-0.32327356934547424,
0.21716861426830292,
0.9802336692810059,
0.47378042340278625,
-0.1717713326215744,
0.18742229044437408,
1.1944780349731445,
0.2586190700531006,
... |
def display _ note _ name ( self, val = true ) : self. show _ note _ name = val | [
0.4565523862838745,
0.37752658128738403,
0.5360792875289917,
-0.2725183367729187,
-1.23427152633667,
1.215620756149292,
0.5040078163146973,
-0.31457656621932983,
0.11053654551506042,
1.462523102760315,
0.04986007139086723,
0.44936510920524597,
0.22925913333892822,
-0.1879517287015915,
-0... |
def eqns ( inla, inaa, ine2, ink0, ina, inb, inc, ind ) : # # i don not know what these variables are computing but they are used in the conversion to and from utm and lat lon outm = ink0 * inaa * ( ( ina * inla ) - ( inb * math. sin ( 2 * inla ) ) + ( inc * math. sin ( 4 * inla ) ) - ( ind * math. sin ( 6 * inla ) ) )... | [
-0.3668927252292633,
-0.8188225626945496,
0.4568733274936676,
-0.6233293414115906,
-0.44317570328712463,
-0.22830744087696075,
-0.26971063017845154,
0.25513726472854614,
0.1656503826379776,
-0.06294842064380646,
0.10140377283096313,
-0.4240318238735199,
0.47448137402534485,
-0.398038059473... |
def get _ packages ( filename ) : ret = ordereddict ( ) with open ( filename ) as f : for line in f. read ( ). split ('\ n') : line = line. strip ( ) if ( not line ) or line. startswith ('#') : continue name = line. split ('@ ', 1 ) [ 0 ] ret [ name ] = line return ret | [
-0.1261839121580124,
-0.6022435426712036,
0.6285789608955383,
-0.64933180809021,
-1.3773527145385742,
-0.446341335773468,
-0.5551474690437317,
-0.02699977159500122,
-0.8027157783508301,
0.2803722023963928,
-0.985819399356842,
-0.5801011919975281,
0.700945258140564,
-0.05995843559503555,
... |
def inner _ debug _ fn ( real _ inputs ) : # copy the tensor attrs like shape, stride etc by converting to fake tensor # because inductor clears the tensor list in its codegen. and example _ inputs # are available only for the first invocation. fake _ mode = faketensormode ( ) copy _ tensor _ attrs = [ fake _ mode. fro... | [
-0.27667391300201416,
-0.31075164675712585,
0.7979079484939575,
0.37322381138801575,
0.39574089646339417,
-0.29501667618751526,
0.6487271189689636,
-0.052066218107938766,
-0.1733092963695526,
0.24531760811805725,
0.5851672291755676,
0.9644490480422974,
-0.08858531713485718,
-0.024953199550... |
def sum _ x ( st : set ) - > float : sum _ x = 0 for set _ in st : if len ( set _ ) > 0 : sum _ x + = set _ [ 0 ] return sum _ x | [
-0.1537807583808899,
0.810437798500061,
0.3969030976295471,
0.09974627941846848,
0.040832508355379105,
-0.40484902262687683,
-0.28962841629981995,
-0.8131965398788452,
0.06854201853275299,
0.30348971486091614,
-0.6235195994377136,
0.6542800068855286,
0.42252615094184875,
0.0725836232304573... |
def draw ( self, surface ) : self. button. draw ( surface ) self. text1. draw ( surface ) self. text2. draw ( surface ) self. text3. draw ( surface ) | [
-0.32283738255500793,
0.17105035483837128,
0.445367693901062,
0.008384883403778076,
0.10689442604780197,
1.5234875679016113,
0.4813563823699951,
-0.25394102931022644,
-0.604252278804779,
-0.723026692867279,
-0.6982285380363464,
-0.7899250388145447,
-0.808971643447876,
1.0735732316970825,
... |
def addlogicalinterfacetothingtype ( self, thingtypeid, logicalinterfaceid, schemaid = none, name = none ) : req = apiclient. allthingtypelogicalinterfacesurl % ( self. host, " / draft ", thingtypeid ) body = { " id " : logicalinterfaceid } # body = { " name " : name, " id " : logicalinterfaceid, " schemaid " : schemai... | [
-1.1556369066238403,
-0.32043248414993286,
0.5905053019523621,
-0.7588392496109009,
0.08650890737771988,
0.5797955989837646,
-1.1853265762329102,
-0.7512190937995911,
0.22219318151474,
0.26281091570854187,
-0.5754460096359253,
0.7164295315742493,
-1.614258885383606,
0.5009534955024719,
-... |
def check _ solver ( finesse _ folder, lpost, dpost ) : prior _ filename = join ( finesse _ folder,'finesse _ prior _ info. json') data _ filename = join ( finesse _ folder,'finesse _ input. h5') with open ( prior _ filename,'r') as infile : prior = json. load ( infile, parse _ float = np. float64 ) data = io. h5 _ 2 _... | [
-0.4375752806663513,
0.14141543209552765,
0.747043251991272,
0.07338125258684158,
-0.14027731120586395,
-0.37323954701423645,
0.40885329246520996,
-0.05257453769445419,
-0.3006722927093506,
-0.2212354838848114,
-0.2345856875181198,
0.3496813476085663,
-0.06189213693141937,
0.57695263624191... |
def ring _ score _ from _ sequence ( seq, flavour ='geometric ', nb _ pers = none, exponent = 2 ) : if len ( seq ) = = 0 : return 0 if flavour in'geometric': return geometric _ ring _ score ( seq, nb _ pers = nb _ pers, exponent = exponent ) elif flavour = ='gap': return gap _ ring _ score ( seq ) elif flavour = ='ampl... | [
0.04075174033641815,
-0.39713552594184875,
0.7413464784622192,
-0.6348816752433777,
-0.07637156546115875,
-0.3938702940940857,
0.13415232300758362,
-0.2792859375476837,
0.39905187487602234,
0.8533130884170532,
-0.5160595178604126,
-0.29866823554039,
-0.7795348763465881,
-0.281643271446228,... |
def _ update _ merge _ step _ presentation ( presentation, sub _ build, user _ namespace, infra _ step ) : def append _ step _ text ( text ) : if presentation. step _ text : presentation. step _ text + ='\ n'presentation. step _ text + = text if presentation. status! ='success': # something went wrong already before we... | [
-0.21145717799663544,
-0.6792003512382507,
0.7474601864814758,
0.4765743911266327,
-0.40757492184638977,
0.9432569146156311,
-0.44905340671539307,
0.350501149892807,
-0.4194059669971466,
-0.42790040373802185,
-0.4580218493938446,
0.5951430201530457,
-0.42072683572769165,
0.7772952914237976... |
def verify _ memorytable _ offset ( offset ) : fmm. seek ( offset + page _ size ) correct = false if fmm. read ( 8 ) = = xpress _ sig : correct = true fmm. seek ( offset ) return correct | [
0.20976586639881134,
-0.034940339624881744,
0.5470590591430664,
0.13540437817573547,
-0.052344366908073425,
0.8727166652679443,
-0.26365429162979126,
-0.936496376991272,
0.3619161546230316,
-0.3160710334777832,
-0.4888196587562561,
0.04704960808157921,
-0.47708913683891296,
0.4906007349491... |
def create _ log _ book ( self, log _ line _ array, log _ type, instance ) : common _ log _ obj = self. env [ " common. log. book. ept " ] common _ log _ obj. create ( { " type " : log _ type, " module " : " shopify _ ept ", " shopify _ instance _ id " : instance. id if instance else false, " active " : true, " log _ l... | [
-0.7135372161865234,
-0.36446064710617065,
0.42522022128105164,
0.024356339126825333,
0.796390175819397,
1.9357417821884155,
-0.7832996249198914,
-0.1550522744655609,
-0.248587504029274,
0.5566240549087524,
-0.09049919992685318,
-0.15860550105571747,
-0.6060580611228943,
0.2747056186199188... |
def perform _ query ( self, query : midifile ) : query _ fingerprints = self. create _ fingerprints ( query, remove _ doubles = true ) matched _ queries = dict ( ) for fp in query _ fingerprints : for hash _ val in fp. get _ hash _ iterator ( ) : matched _ fingerprint _ list = self. _ fingerprints. get ( hash _ val, no... | [
-0.04074600711464882,
-0.2686771750450134,
0.517302930355072,
0.1636454313993454,
-0.3223474621772766,
-0.12328091263771057,
0.2746821641921997,
0.2310590147972107,
-0.25562307238578796,
-0.39286893606185913,
0.18344707787036896,
-1.068970799446106,
-1.057157039642334,
0.7084997892379761,
... |
def test _ directed _ edge _ hashing ( self ) : v0 = directedvertex ( val ='v0') v1 = directedvertex ( val ='v1') v2 = directedvertex ( val ='v2') e01 = directededge ( ( v0, v1 ) ) e02 = directededge ( ( v0, v2 ) ) e10 = directededge ( ( v1, v0 ) ) another _ e01 = directededge ( ( v0, v1 ) ) edge _ set = set ( [ e01 ] ... | [
0.13177883625030518,
0.05395926907658577,
0.6229998469352722,
-0.020120028406381607,
0.2619287371635437,
1.2174029350280762,
0.3651672303676605,
-0.21685445308685303,
-0.06400571018457413,
0.05393955856561661,
-0.3692852556705475,
-0.11773088574409485,
0.04381215572357178,
-0.4067734479904... |
def plot _ confusion _ matrix ( cm, classes, normalize = false, title ='confidence matrix ', cmap = plt. cm. blues ) : plt. figure ( figsize = ( 5, 5 ) ) plt. imshow ( cm, interpolation ='nearest ', cmap = cmap ) plt. title ( title ) plt. colorbar ( ) tick _ marks = np. arange ( len ( classes ) ) plt. xticks ( tick _ m... | [
-0.1565166860818863,
0.37583890557289124,
0.6652603149414062,
-0.13452516496181488,
-0.63872230052948,
0.002292910125106573,
0.9907140731811523,
0.09855116158723831,
0.20284070074558258,
0.509554922580719,
0.9953086972236633,
0.37901419401168823,
-0.2814062833786011,
0.09383721649646759,
... |
def _ compute _ missing _ indices ( self ) : self. _ missing _ indices = np. nonzero ( self. flat _ indexer = = - 1 ) [ 0 ] | [
-1.5427017211914062,
-0.522240936756134,
0.07612163573503494,
0.11031284183263779,
0.1470036506652832,
0.4582589864730835,
1.1175869703292847,
1.215366005897522,
-0.01754228211939335,
0.2174994796514511,
-0.13949203491210938,
0.4213152527809143,
-0.5087888836860657,
0.30937522649765015,
... |
def emin ( self ) : # build input file input _ file ='emin. mdp'with open ( input _ file,'w') as f : f. write ( textwrap. dedent ('''; run control parameters = integrator = steep emtol = 0. 01 nsteps = 10000 ; max steps ; output frequency for coords ( x ), velocities ( v ) and forces ( f ) = nstxout = 5 nstvout = 0 nst... | [
-0.4217993915081024,
-0.3120870888233185,
0.6653336882591248,
0.36310309171676636,
0.7375624775886536,
0.27001893520355225,
0.12024437636137009,
0.1477651447057724,
-0.4344278573989868,
-0.11877339333295822,
0.059176746755838394,
-0.3975704312324524,
-0.4709787368774414,
0.0543411672115325... |
def distribution _ table _ dataframe ( self ) : pdf = self. dataframe ( dist _ variables ) # weighted count of itemized - deduction returns pdf ['num _ returns _ itemded'] = pdf ['weight']. where ( pdf ['c04470'] > 0., 0. ) # weighted count of standard - deduction returns pdf ['num _ returns _ standardded'] = pdf ['wei... | [
0.6222476363182068,
-0.2709185779094696,
0.3788408041000366,
-0.30001309514045715,
-0.12430579215288162,
0.3207729160785675,
0.056080516427755356,
0.01741323433816433,
-0.6554322242736816,
-0.0733145996928215,
0.5097060203552246,
0.22392188012599945,
0.28008076548576355,
-0.166108861565589... |
def unlink ( self, cr, uid, ids, context = { } ) : for rec in self. browse ( cr, uid, ids, context ) : idss = self. pool. get ('additional. fuel'). search ( cr, uid, [ ('fuel _ amount _ id ','= ', rec. id ) ] ) if idss : raise osv. except _ osv ( _ ('error'), _ ('you can not delete this record, there are additional fue... | [
-0.015005771070718765,
-0.7643259167671204,
0.5950013399124146,
-0.2886265516281128,
-0.36080947518348694,
-0.6357473134994507,
0.5734859704971313,
0.9238256216049194,
-0.0451052188873291,
-0.2572747766971588,
0.7638145685195923,
-0.19574983417987823,
0.08058612793684006,
0.674742639064788... |
def createdevicemanagementextensionpkg ( self, dmedata ) : dmereq = apiclient. dmerequests % ( self. host ) r = requests. post ( dmereq, auth = self. credentials, data = json. dumps ( dmedata ), headers = {'content - type':'application / json'}, verify = self. verify ) status = r. status _ code if status = = 201 : self... | [
-1.9101893901824951,
0.8376355767250061,
0.5779111385345459,
0.46173980832099915,
-0.7887933254241943,
0.18813484907150269,
-0.9471285939216614,
-0.36438119411468506,
0.7218503952026367,
0.6886606216430664,
-0.33325278759002686,
0.061407316476106644,
-1.1082677841186523,
-0.027978647500276... |
def onlywitharch ( arch _ names : list [ str ] ) : for arch in arch _ names : if arch not in pwndbg. gdblib. arch _ mod. archs : raise valueerror ( f " onlywitharch used with unsupported arch = { arch }. must be one of { ', '. join ( arch _ names ) } " ) def decorator ( function ) : @ functools. wraps ( function ) def ... | [
-0.09479298442602158,
0.6417731642723083,
0.6400936245918274,
0.5952224731445312,
-0.7661405205726624,
0.14409169554710388,
-0.2275495082139969,
0.06036395579576492,
1.149631142616272,
0.7782175540924072,
0.6235742568969727,
0.6350970268249512,
0.28582969307899475,
0.6566305756568909,
0.... |
def listtags ( data, limit = none ) : request = utils. getmessagesmodule ( ). datapoldatataxonomystoresannotationtagslistrequest ( parent ='data / { data } '. format ( data = data ) ) return list _ pager. yieldfromlist ( utils. getclientinstance ( ). data _ taxonomystores _ annotationtags, request, limit = limit, field... | [
0.3192051351070404,
1.024646282196045,
0.11338812112808228,
-0.5394318103790283,
0.14183573424816132,
-0.5559951663017273,
-0.5455400347709656,
-0.18646736443042755,
0.6216368079185486,
0.4428567886352539,
-0.26835665106773376,
0.8375627994537354,
0.2620141804218292,
0.6759437918663025,
... |
def prepare ( benchmark _ spec ) : vm = benchmark _ spec. vms [ 0 ] if ( bool ( benchmark _ spec. tpus ) and nvidia _ driver. checknvidiagpuexists ( vm ) ) : raise errors. config. invalidvalue ('invalid configuration. gpus and tpus can not both present in the config.') mnist _ benchmark. prepare ( benchmark _ spec ) _ ... | [
0.5974774360656738,
0.3249134421348572,
0.4488007426261902,
0.1902073621749878,
1.1779924631118774,
0.5189682841300964,
0.22056910395622253,
0.625619113445282,
-0.0006920867599546909,
0.7706735730171204,
-0.18130283057689667,
0.04445315897464752,
0.7189518809318542,
0.5961694717407227,
0... |
def get _ image ( pth, scale, * * kwargs ) : with rio. env ( awssession ( ), aws _ https ='no') as env : with rio. open ( pth ) as src : img = src. read ( * * kwargs ) img = np. moveaxis ( img, 0, - 1 ) return img. astype ( float ) / scale | [
-0.5472796559333801,
0.17745840549468994,
0.5278938412666321,
-0.23418645560741425,
-0.1354472041130066,
0.027047326788306236,
-0.3839261829853058,
-0.9571323394775391,
-0.984055757522583,
1.0050902366638184,
0.4821944236755371,
0.60991370677948,
-0.22720880806446075,
-0.5111570954322815,
... |
def test ( self, values _ scores ) : raise notimplementederror ( ) | [
-0.3662988543510437,
-0.011205976828932762,
0.3047168552875519,
0.5869055986404419,
1.0453917980194092,
0.8994148969650269,
0.6308293342590332,
-0.5842934846878052,
0.036707811057567596,
-0.6502483487129211,
0.2844153940677643,
-0.33671802282333374,
-0.42596039175987244,
0.3708356320858001... |
def _ _ init _ _ ( self, db ) : superdao. _ _ init _ _ ( self, db ) | [
0.7091783881187439,
0.5471926331520081,
0.49791935086250305,
0.8123997449874878,
-0.8747464418411255,
0.49399733543395996,
0.39313986897468567,
1.359772801399231,
1.1354241371154785,
-1.5681142807006836,
-1.3914133310317993,
-0.4588468670845032,
0.727636456489563,
1.0814242362976074,
0.3... |
def compute _ grad _ norm ( grad _ lds ) : return np. absolute ( grad _ lds ). max ( ) | [
-0.5667887330055237,
-0.17443455755710602,
0.4724106192588806,
0.02716967836022377,
-0.4580838680267334,
0.8283281922340393,
-0.24265755712985992,
0.15905539691448212,
-0.48963096737861633,
0.41746729612350464,
0.4758206903934479,
0.8027743101119995,
-0.03766025975346565,
0.792100429534912... |
def quantile ( data, weights, quantile = 0. 5 ) : ind _ sorted = np. argsort ( data ) sorted _ data = data [ ind _ sorted ] sorted _ weights = weights [ ind _ sorted ] # compute the auxiliary arrays cum _ weights = np. cumsum ( sorted _ weights ) if np. sum ( sorted _ weights ) > 0 : num _ data = ( cum _ weights - 0. 5... | [
0.6076124906539917,
0.29546332359313965,
0.5465419292449951,
0.048692408949136734,
-0.23171459138393402,
-0.6531011462211609,
-0.20204384624958038,
-0.0058991811238229275,
-0.22841471433639526,
0.20903053879737854,
0.766014575958252,
-0.01233017910271883,
-1.3535223007202148,
-0.2380647808... |
def remove _ marble ( marbles : list, removed _ marble : str ) : final _ marbles = copy. deepcopy ( marbles ) final _ marbles. remove ( removed _ marble ) return final _ marbles | [
-0.32882675528526306,
-0.4975976049900055,
0.4064757823944092,
0.057325225323438644,
-1.4117107391357422,
0.4417334794998169,
-0.3002236783504486,
1.1219977140426636,
-0.02843952365219593,
1.416852593421936,
-1.1736375093460083,
1.0058025121688843,
-1.3375369310379028,
-0.35100898146629333... |
def process _ text ( filepath : str ) : with open ( filepath,'r ', encoding = encoding ) as f : return [ l. strip ( ) for l in f. readlines ( ) ] | [
0.7716884016990662,
-1.0544636249542236,
0.42437130212783813,
-1.167438268661499,
0.29422783851623535,
0.8722915053367615,
-0.8486142158508301,
1.029088020324707,
0.0724591612815857,
1.0816329717636108,
-0.3305610716342926,
0.006818304769694805,
0.4174249470233917,
0.16129742562770844,
-... |
def plot _ elec _ hourly ( df ) : fig = plt. figure ( figsize = ( 12, 7 ) ) plt. plot ( df. index. hour, df. kwh, '. ', color ='grey ', label ='data point') plt. ylabel ('electricity usage ( kwh )') plt. xlabel ('hour of day') plt. plot ( df. kwh. groupby ( df. index. hour ). mean ( ), label ='avg') plt. legend ( ) | [
-0.40304040908813477,
0.6602706909179688,
0.6029171943664551,
-1.0631344318389893,
-0.3570097088813782,
0.8552216291427612,
-0.13666614890098572,
-0.08922482281923294,
-0.33200958371162415,
0.7235468029975891,
0.3276994526386261,
0.971855878829956,
0.7993593811988831,
0.4146517217159271,
... |
def cabin _ overheat _ protection ( self ) - > str : return self. _ vehicle _ data. get ( " climate _ state ", { } ). get ( " cabin _ overheat _ protection " ) | [
-0.03270134702324867,
-0.45349106192588806,
0.48410746455192566,
0.16472923755645752,
-0.10646563768386841,
0.673597514629364,
-0.30666711926460266,
-0.7221065163612366,
0.5418501496315002,
-0.16404670476913452,
-0.3021639287471771,
-0.4782315790653229,
-0.0823228731751442,
-0.727399408817... |
def list _ clusters ( host = none, vcenter = none, username = none, password = none, protocol = none, port = none, verify _ ssl = true ) : if salt. utils. platform. is _ proxy ( ) : details = _ _ salt _ _ [ " vmware _ info. get _ proxy _ connection _ details " ] ( ) else : details = _ _ salt _ _ [ " vmware _ info. get ... | [
-0.34141767024993896,
0.5350526571273804,
0.5974764823913574,
0.40596017241477966,
-0.032701049000024796,
-0.15126380324363708,
-1.255458116531372,
-0.0387725755572319,
0.3584444522857666,
0.9153817892074585,
0.2673754394054413,
1.2525523900985718,
-1.4571256637573242,
-0.3131738305091858,... |
def click _ on _ submenu ( self, over _ element _ name, name, dont _ wait = none ) : self. put _ mouse _ over ( over _ element _ name ) sleep ( 1 ) self. click _ on ( name ) self. wait _ for _ page _ loaded ( dont _ wait ) | [
-0.007523028180003166,
0.11617767065763474,
0.6830782890319824,
1.0680932998657227,
-0.33080706000328064,
0.16794610023498535,
-0.6416746973991394,
-0.050324346870183945,
-0.3322148621082306,
0.36196020245552063,
-1.0445176362991333,
0.5236636400222778,
-0.5569701790809631,
-0.032932411879... |
def test _ switch ( ) : df _ a = pd. dataframe ( { " a " : [ 1. 0, 2, 3, 1 ], " b " : [ 1. 0, 2, 3, 4 ], " c " : [ 1, 2, 3, 4 ], " d " : [ 1. 7, 4. 7, 6. 6, 7. 8 ], } ) df _ b = pd. dataframe ( { " a " : [ 4. 0, 3, 5, 1 ], " b " : [ 11. 0, 1, 2, 4 ], " c " : [ 4, 2, 2, 4 ], " d " : [ 4. 7, 4. 7, 7. 6, 7. 8 ], } ) df _ ... | [
0.17005591094493866,
0.9367218017578125,
1.0375393629074097,
0.8954968452453613,
1.060310959815979,
0.22865258157253265,
0.27247926592826843,
0.29312288761138916,
-0.3946436643600464,
-0.06483713537454605,
-0.10176371783018112,
0.32852715253829956,
-0.768242359161377,
-0.6332269906997681,
... |
def _ _ init _ _ ( self, k, seed = 10 ) : self. _ k = k self. _ seed = seed minint = np. iinfo ( np. int64 ). min maxint = np. iinfo ( np. int64 ). max self. _ masks = np. random. randomstate ( seed = self. _ seed ). randint ( minint, maxint, self. _ k ) self. _ hashes = np. empty ( self. _ k, dtype = np. int64 ) self.... | [
0.0832449421286583,
0.19795066118240356,
0.5997352004051208,
0.3783456087112427,
-0.2080988734960556,
0.1992083042860031,
0.41945284605026245,
-0.30923572182655334,
0.5598024129867554,
-0.17159180343151093,
-0.7963346242904663,
-0.3355533182621002,
0.42752572894096375,
0.17671364545822144,... |
def build _ filename ( self ) : filename ='{ prefix } - { timestamp } - { serial } - { crawlhost }. warc '. format ( prefix = self. settings ['warc _ file _ prefix'], timestamp = datetime. utcnow ( ). strftime ('% y % m % d % h % m % s'), serial = str ( self. serial ). zfill ( 6 ), crawlhost = self. ip _ address ) if s... | [
0.015538472682237625,
-1.3519400358200073,
0.8882284760475159,
-0.30921611189842224,
1.0288163423538208,
-0.20102564990520477,
0.27540430426597595,
0.25603097677230835,
-0.276226669549942,
-0.5174515843391418,
0.29793521761894226,
0.9748325347900391,
0.8039565682411194,
-0.5813805460929871... |
def compute _ metrics ( p ) : return metric. compute ( predictions = np. argmax ( p. predictions, axis = 1 ), references = p. label _ ids ) | [
-0.7342963218688965,
-0.15173429250717163,
0.10935263335704803,
0.44728222489356995,
0.46310439705848694,
0.5475485920906067,
-0.46342939138412476,
0.6748582124710083,
-0.536415696144104,
0.5487600564956665,
1.183050513267517,
-0.2854686379432678,
0.03884812816977501,
-0.08186975121498108,... |
def test _ table ( ) : with contextlib. redirect _ stdout ( none ) : catalog = sxs. load ( " catalog " ) table = catalog. table assert len ( table [ table [ " object _ types " ] = = " bhbh " ] ) > = 2019 assert len ( table [ table [ " object _ types " ] = = " bhns " ] ) > = 7 assert len ( table [ table [ " object _ typ... | [
0.41298529505729675,
0.3612610995769501,
0.5887876749038696,
0.5397467613220215,
0.8926259875297546,
0.19936686754226685,
0.023227520287036896,
-0.18372346460819244,
-0.2510104179382324,
-0.23968949913978577,
0.008151010610163212,
0.7533293962478638,
0.4716348350048065,
-0.4938113987445831... |
def allow _ cross _ domain ( response : response ) : response. headers ['access - control - allow - origin'] ='*'response. headers ['access - control - allow - headers'] ='content - type'return response | [
1.0427473783493042,
-0.8186959028244019,
0.7545382976531982,
0.2644919455051422,
-0.28310853242874146,
0.5264357328414917,
0.556095540523529,
0.12059782445430756,
0.4190693199634552,
-0.05764853581786156,
0.30891478061676025,
0.729343056678772,
0.31293827295303345,
0.02691565454006195,
0... |
def join ( self, * args, * * kwargs ) : super ( ). join ( * args, * * kwargs ) return self. _ return | [
-0.5671049356460571,
0.13182911276817322,
0.45375338196754456,
0.04060889407992363,
-0.2949730157852173,
0.10340455174446106,
-0.1879064440727234,
0.27148452401161194,
-0.2092972844839096,
-0.4978623390197754,
-0.24345825612545013,
-0.12839289009571075,
-1.5444799661636353,
-0.229774728417... |
def active _ route _ traffic _ minutes _ delay ( self ) - > optional [ float ] : if " active _ route _ minutes _ to _ arrival " in self. _ vehicle _ data. get ( " drive _ state ", { } ) : return self. _ vehicle _ data. get ( " drive _ state ", { } ). get ( " active _ route _ traffic _ minutes _ delay " ) return none | [
0.08079850673675537,
-1.4203864336013794,
0.5064015984535217,
-0.837969958782196,
0.10902095586061478,
0.26130783557891846,
-0.40689417719841003,
-0.35606715083122253,
0.5386227965354919,
0.27625954151153564,
0.30830642580986023,
0.3972350060939789,
0.3980341851711273,
-0.8227960467338562,... |
def pound ( value ) : return f " £ { value :,. 2f } " | [
0.4157031774520874,
0.22747719287872314,
0.25926217436790466,
0.03441575914621353,
0.20933836698532104,
-0.034322746098041534,
0.07437383383512497,
-0.29649895429611206,
0.21250034868717194,
-0.18721473217010498,
0.09086544811725616,
-0.6123952269554138,
0.13635919988155365,
0.074712313711... |
def _ _ iter _ _ ( self ) : while true : episode = random. randrange ( len ( self. buffer ) ) ofs = random. randrange ( self. lens [ episode ] - self. steps _ count - 1 ) yield self. buffer [ episode ] [ ofs : ofs + self. steps _ count ] | [
-0.4982360005378723,
-0.8273570537567139,
0.5652494430541992,
-0.30277878046035767,
-0.2224745750427246,
0.8430930376052856,
-0.1419282853603363,
-0.6602199077606201,
0.46916061639785767,
-0.658248245716095,
0.07849234342575073,
0.14498159289360046,
-0.40968185663223267,
0.0678588300943374... |
def facultydashboard ( request ) : if request. method = ='get': profile = facultyprofile. objects. get ( id = request. session ['id'] ) data = issue _ list. objects. filter ( faculty = profile ) return render ( request, " inventory / facultydashboard. html ", {'data': data } ) | [
0.2532031834125519,
0.3559627830982208,
0.5076719522476196,
0.348895788192749,
0.2667640149593353,
-0.21627257764339447,
0.32430416345596313,
0.5737224817276001,
-0.3818480670452118,
-1.3308179378509521,
1.006614327430725,
-0.7398315668106079,
0.6153174042701721,
-0.012474717572331429,
-... |
def setup _ 4 _ model _ graph ( ) : nnodes = 4 # initialize empty graph graph = nx. digraph ( ) # add nodes ane edges for ii in range ( 1, nnodes + 1 ) : graph. add _ node ( ii ) graph. add _ edge ( 1, 2 ) graph. add _ edge ( 2, 4 ) graph. add _ edge ( 3, 4 ) return graph | [
-0.5324356555938721,
0.6530351638793945,
0.5002063512802124,
0.2075364887714386,
0.29747653007507324,
-0.12396880984306335,
0.5866783261299133,
-0.31666693091392517,
0.2917430102825165,
0.4760546088218689,
-1.0521938800811768,
-0.922302782535553,
-0.17658373713493347,
-0.5970214605331421,
... |
def get _ fs _ usage _ all _ time ( self, fs, select ='*') : dataset ='broad _ bitstore _ app'table _ name ='bits _ billing _ byfs _ bitstore _ historical'query _ string =''. join ( ['select { select } '. format ( select = select ),'from { dataset }. { table _ name } '. format ( dataset = dataset, table _ name = table ... | [
-0.5536246299743652,
0.4829988479614258,
0.874289333820343,
0.22593775391578674,
-0.29124370217323303,
-1.3260457515716553,
0.1853373944759369,
-0.24754002690315247,
0.05393034964799881,
0.2718138098716736,
0.41248905658721924,
-0.0012456938857212663,
0.27496814727783203,
0.676769971847534... |
def get _ cred ( ) : # first try to parse config file try : logging. debug ( " getting info from { } ". format ( config _ file ) ) config = configparser. configparser ( ) config. read ( config _ file ) username = config. get ( server, " username " ) password = config. get ( server, " password " ) except exception as e ... | [
-0.15018966794013977,
-0.9176591038703918,
0.763292133808136,
0.45227137207984924,
-0.6049345135688782,
1.0176790952682495,
0.419865220785141,
0.3556157648563385,
-1.2011607885360718,
0.13213130831718445,
-0.5906497240066528,
0.18456147611141205,
-0.3263266682624817,
0.4676845967769623,
... |
def random _ dpaw _ email ( ) : s =''. join ( random. choice ( string. ascii _ letters ) for i in range ( 20 ) ) return'{ } @ dpaw. wa. gov. au '. format ( s ) | [
-0.603731095790863,
0.5736861228942871,
0.3611789643764496,
-1.8241465091705322,
-0.9097653031349182,
0.8298433423042297,
-0.15017785131931305,
-0.3034415543079376,
0.8206354379653931,
-0.13752077519893646,
0.3616405725479126,
1.08000910282135,
-0.31983712315559387,
-0.9073278307914734,
... |
def update ( self, old, new ) : raise notimplementederror ( ) | [
-0.925981342792511,
-1.2208783626556396,
0.4149126410484314,
-0.02377871796488762,
-0.5469887852668762,
0.8760665059089661,
-0.7873632311820984,
0.04828431084752083,
-0.4427158832550049,
0.18663689494132996,
-0.17797721922397614,
0.6842511892318726,
0.17554089426994324,
0.42956286668777466... |
def _ get _ all _ forums ( self ) : if not hasattr ( self, " _ all _ forums " ) : if self. current _ lti _ context _ id : self. _ all _ forums = list ( forum. objects. filter ( archived = false, lti _ contexts _ _ id = self. current _ lti _ context _ id ) ) else : super ( ). _ get _ all _ forums ( ) return self. _ all ... | [
-0.15372653305530548,
-0.1642574667930603,
0.7313759326934814,
0.5494624972343445,
0.5853753685951233,
0.007982335053384304,
-0.3567359149456024,
-0.2588503658771515,
0.8419352769851685,
-0.28683486580848694,
0.23807446658611298,
0.7482283115386963,
-0.19246292114257812,
0.302108496427536,... |
def link _ clicked ( self, url ) : page = self. ui. webview. page ( ) history = page. history ( ) if history. cangoback ( ) : self. ui. back. setenabled ( true ) else : self. ui. back. setenabled ( false ) if history. cangoforward ( ) : self. ui. next. setenabled ( true ) else : self. ui. next. setenabled ( false ) sel... | [
0.4014277458190918,
0.3059770464897156,
0.7513388991355896,
0.04314865171909332,
0.08796615898609161,
0.0037037809379398823,
0.8275068998336792,
1.3189345598220825,
1.4445630311965942,
-0.30732065439224243,
-0.4933525025844574,
0.7877469658851624,
-0.6254674792289734,
0.6016948819160461,
... |
def load _ ref _ system ( ) : return psr. make _ system ( " " " c - 0. 1488 - 0. 0004 - 0. 0352 c - 1. 3084 - 0. 0034 - 0. 3090 c 1. 2454 0. 0033 0. 2941 h - 2. 3439 - 0. 0062 - 0. 5534 h 1. 3942 0. 2722 1. 3481 h 1. 7883 0. 7290 - 0. 3256 h 1. 6857 - 0. 9885 0. 1272 " " " ) | [
0.12318477779626846,
-0.3868470788002014,
0.5890203714370728,
-1.1519666910171509,
-0.10915561765432358,
0.3449113368988037,
0.20186662673950195,
-0.7745485305786133,
-0.007464510388672352,
-0.13268722593784332,
0.3076556324958801,
0.24968962371349335,
-0.7746675610542297,
0.70035630464553... |
def children _ event ( self, event ) : super ( container, self ). children _ event ( event ) if self. is _ active and not self. constraints : self. _ send _ relayout ( ) | [
0.7531764507293701,
0.3542191684246063,
0.45492058992385864,
0.4943319261074066,
-0.32383716106414795,
-0.008241746574640274,
1.3148680925369263,
0.005512334872037172,
-0.04502970352768898,
0.2633835971355438,
-0.9297164678573608,
0.10854737460613251,
-0.3335815370082855,
-0.48081529140472... |
def get _ who _ liked ( obj ) - > queryset : return who _ liked ( obj = obj ) | [
0.016966352239251137,
-0.46274617314338684,
0.5412372350692749,
0.10245713591575623,
-0.6628592610359192,
0.35090726613998413,
0.20019738376140594,
-0.4881291687488556,
0.03577442467212677,
-0.08135529607534409,
-0.1512908786535263,
0.7738193273544312,
0.46107470989227295,
-1.1020023822784... |
def linear _ interpolation ( left, right, alpha ) : return left + alpha * ( right - left ) | [
0.5571267008781433,
-0.3366943299770355,
0.5258440375328064,
-0.8660252690315247,
-0.19874076545238495,
0.36861538887023926,
-1.3390928506851196,
-0.0824783444404602,
-0.10663533955812454,
0.6788454055786133,
-0.24095509946346283,
-0.957997739315033,
-0.9480372071266174,
-0.015057593584060... |
def _ _ getitem _ _ ( self, idx ) : # start _ time = time. time ( ) batch _ start = idx * self. batch _ size batch _ stop = ( idx + 1 ) * self. batch _ size batch _ files = self. indexes [ batch _ start : batch _ stop, 0 ] batch _ indexes = self. indexes [ batch _ start : batch _ stop, 1 ] sigx = np. zeros ( ( self. ba... | [
-0.9126172661781311,
-0.14812500774860382,
0.5682563185691833,
0.22215665876865387,
-0.38330599665641785,
-0.3468223810195923,
0.6243873834609985,
-0.010792569257318974,
-0.4525117576122284,
0.3975546360015869,
-0.5665572881698608,
0.2777409851551056,
0.27941566705703735,
0.161341086030006... |
def testsendrequestrecieveinvalidresponse ( self ) : self. client. sock. invalid _ response = true self. assertequal ( self. client. send _ request ( 9 ), ( 400, 1 ) ) | [
-0.1834140419960022,
0.02972271852195263,
0.4400981664657593,
0.10655409842729568,
0.447435587644577,
0.8822153806686401,
-0.37874162197113037,
-0.43253228068351746,
0.3726666569709778,
-0.8404174447059631,
-0.301692932844162,
0.31001871824264526,
-0.8611071705818176,
-0.16130036115646362,... |
def start _ session ( loss _ op, summary _ op ) : checkpoint _ dir = os. path. join ( training _ params. checkpoint _ dir, training _ params. checkpoint _ run ) saver = tf. train. saver ( # note : cudnn rnns do not support distributed saving of parameters. sharded = false, allow _ empty = true, max _ to _ keep = traini... | [
0.3048422038555145,
0.10629982501268387,
0.7950815558433533,
0.6995809674263,
-0.389104425907135,
-0.22954225540161133,
1.1823137998580933,
0.17175669968128204,
0.8312569260597229,
0.1998998373746872,
-0.42230895161628723,
0.33509185910224915,
0.9977203011512756,
-0.09376412630081177,
0.... |
def test _ atomic _ id _ enumeration _ nistxml _ sv _ iv _ atomic _ id _ enumeration _ 1 _ 2 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / id / schema + instance / nistschema - sv - iv - atomic - id - enumeration - 1. xsd ", instance = " nistdata / atomic / id / schema + ... | [
-0.40710458159446716,
-1.1553674936294556,
0.4467916488647461,
0.4279579222202301,
-0.4039432108402252,
-0.06602762639522552,
0.19402587413787842,
-0.2787504494190216,
0.1394985318183899,
0.9310932159423828,
-0.21816566586494446,
0.4214584529399872,
0.43042677640914917,
0.1626981496810913,... |
def async _ cache _ time _ based ( async _ caches ) : return async _ caches ['time - based']. cache | [
-0.39698678255081177,
0.34929192066192627,
0.39824098348617554,
0.8113211989402771,
-0.027908017858862877,
-0.014433077536523342,
-0.6095807552337646,
-0.5249320864677429,
-0.011979982256889343,
1.714321255683899,
0.2368784248828888,
-0.7870455980300903,
0.3316068649291992,
0.3666367530822... |
def writecsv ( devicedata ) : with open ('deviceinventory. csv ','a') as file : writer = csv. writer ( file ) writer. writerow ( devicedata ) | [
-1.0377501249313354,
-0.4518029987812042,
0.008042099885642529,
0.7378309369087219,
0.914797306060791,
0.6287632584571838,
0.6950084567070007,
0.775918185710907,
0.053724467754364014,
-0.8468419909477234,
0.5349383354187012,
0.23929600417613983,
0.9314644932746887,
-0.14368975162506104,
... |
def self _ link ( self ) - > pulumi. output [ str ] : return pulumi. get ( self, " self _ link " ) | [
-0.10138546675443649,
-0.5631867051124573,
0.5720475316047668,
0.6697279810905457,
0.40017446875572205,
0.5964094996452332,
1.1608846187591553,
0.3794645667076111,
0.42111867666244507,
-1.1339080333709717,
-0.4499659240245819,
1.888503074645996,
0.07773024588823318,
-1.0573618412017822,
... |
def media _ image _ url ( self ) - > str | none : if ( self. _ currently _ playing. get ( " item " ) is none or not self. _ currently _ playing [ " item " ] [ " album " ] [ " images " ] ) : return none return fetch _ image _ url ( self. _ currently _ playing [ " item " ] [ " album " ] ) | [
-0.4359619617462158,
-0.6345746517181396,
0.3000234067440033,
0.6831657290458679,
0.4324676990509033,
0.07005857676267624,
0.06762193143367767,
-0.3801020383834839,
-0.1370028406381607,
0.6983453631401062,
0.8816255331039429,
0.48176145553588867,
-0.28442510962486267,
0.0002726267848629504... |
def minimum _ object _ size ( self ) : # in bytes - assume this is filesystem, so " optimum " is 32mb return self. ftp _ settings [ " object _ size " ] | [
-0.1994291990995407,
-0.282873272895813,
0.5960954427719116,
-0.07225166261196136,
-0.3310353457927704,
0.6087402701377869,
0.05434225872159004,
-1.3806625604629517,
0.031210048124194145,
-0.7999982833862305,
-0.2083374261856079,
-0.18905815482139587,
-0.5779922008514404,
-0.18864808976650... |
def test _ atomic _ language _ max _ length _ 4 _ nistxml _ sv _ iv _ atomic _ language _ max _ length _ 5 _ 2 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / language / schema + instance / nistschema - sv - iv - atomic - language - maxlength - 5. xsd ", instance = " nistda... | [
0.30615857243537903,
-0.42919161915779114,
0.14516335725784302,
0.43767088651657104,
-0.9746283292770386,
-0.11644214391708374,
-0.2441890686750412,
-0.3842926025390625,
-0.32573267817497253,
0.8257430791854858,
-0.8851901888847351,
-0.1313818246126175,
-0.0867372378706932,
0.2690657377243... |
def charge _ current _ request _ max ( self ) - > int : return self. _ vehicle _ data. get ( " charge _ state ", { } ). get ( " charge _ current _ request _ max " ) | [
-1.0333000421524048,
-0.6040642261505127,
0.7210682034492493,
1.0351938009262085,
0.30822280049324036,
0.12276057153940201,
-1.2851451635360718,
-0.2821260392665863,
-0.17070551216602325,
-0.2882993519306183,
0.4821135699748993,
0.2695782780647278,
-0.034996148198843,
0.07962151616811752,
... |
def predict ( self, year, option _ set ) : if not epop. is _ valid ( option _ set ) or epop. get _ area ( option _ set ) = = epop. area _ vice _ model : raise epop. invalidoption ( " invalid option when predicting " ) area, duration, timepoint = self. _ translate _ option ( option _ set ) args = ['- p - area ', area,'-... | [
-0.5215821266174316,
0.12038013339042664,
0.6276683807373047,
0.0697050541639328,
-0.14005595445632935,
0.5104197263717651,
-0.05829736217856407,
-0.19748960435390472,
0.16924822330474854,
0.5547503232955933,
0.5434643626213074,
0.5468990802764893,
0.08726313710212708,
-0.21127937734127045... |
def getestimate ( self ) : return self. estimate | [
0.5023105144500732,
-0.7650687098503113,
0.3315313756465912,
0.7588253021240234,
-0.0804109126329422,
-0.25172069668769836,
-0.6581234931945801,
0.011518076062202454,
-0.8574716448783875,
-0.34526166319847107,
0.20487070083618164,
0.9418320655822754,
-1.652735710144043,
0.351764440536499,
... |
def get _ value ( self ) : # distance between cities distance = self. coords ( ) # euclidean sum between coordinates of cities total _ sum = 0 # loop through coordinates and find the distance between each adjacent cities for i in range ( len ( distance ) ) : dist = 0 x1 = distance [ i ] [ 0 ] y1 = distance [ i ] [ 1 ] ... | [
-0.0072892652824521065,
0.019064532592892647,
1.030098557472229,
-0.9589055776596069,
0.0039008832536637783,
0.2672993242740631,
0.7147231698036194,
0.013394402340054512,
-0.3065038025379181,
0.3699307143688202,
-0.17310620844364166,
-0.07708705216646194,
-0.23907142877578735,
-0.359804302... |
def url _ changed ( self ) : page = self. ui. webview. page ( ) history = page. history ( ) if history. cangoback ( ) : self. ui. back. setenabled ( true ) else : self. ui. back. setenabled ( false ) if history. cangoforward ( ) : self. ui. next. setenabled ( true ) else : self. ui. next. setenabled ( false ) url = sel... | [
0.5786018967628479,
-0.05775134265422821,
0.6868430376052856,
0.2452109009027481,
-0.37099069356918335,
0.10841698944568634,
0.3699397146701813,
1.2991547584533691,
0.9526014924049377,
0.10345514863729477,
-0.3717988133430481,
0.8974089026451111,
-0.3458482027053833,
0.8242404460906982,
... |
def update _ connection ( old _ con :'nm. connection ', new _ con :'nm. connection ', main _ loop :'glib. mainloop') : logger. info ( " updating existing connection with new configuration " ) def update _ callback ( client, result, data ) : main _ loop. quit ( ) old _ con. replace _ settings _ from _ connection ( new _... | [
-0.35064825415611267,
-1.052799105644226,
0.40306299924850464,
0.27101871371269226,
-0.5803130865097046,
-0.11306113749742508,
-0.4437781572341919,
-0.07467617839574814,
-1.0196919441223145,
1.7946138381958008,
-0.03794379532337189,
-0.15971292555332184,
-0.4278838634490967,
0.317308455705... |
def _ del _ note ( text : str, user : karmauser ) - > str : _, note _ id = _ parse _ note _ cmd ( text ) if not note _ id : return f " sorry { user. username }, it seems you did not provide a valid id. " with database. session _ manager ( ) as session : query = session. execute ( select ( karmanote ). filter _ by ( id ... | [
0.5400815606117249,
0.505810558795929,
0.594357967376709,
0.4068007171154022,
-0.49285468459129333,
-0.22965002059936523,
-0.17615731060504913,
0.5022917985916138,
0.0229265745729208,
0.38177308440208435,
0.5942001342773438,
0.5583959221839905,
-0.8514330983161926,
-0.2502988278865814,
0... |
def map _ source _ class _ id ( self, source _ class _ id ) : return self. class _ from _ source _ map [ source _ class _ id ] | [
-1.0988637208938599,
-0.7855474948883057,
0.4164262115955353,
-0.5471821427345276,
-0.29510068893432617,
0.6587395668029785,
-0.1632108837366104,
-0.18531523644924164,
1.3186779022216797,
0.04260203614830971,
-0.37950631976127625,
0.38582053780555725,
0.9531912803649902,
0.4057650566101074... |
def test _ atomic _ boolean _ pattern _ 4 _ nistxml _ sv _ iv _ atomic _ boolean _ pattern _ 5 _ 2 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / boolean / schema + instance / nistschema - sv - iv - atomic - boolean - pattern - 5. xsd ", instance = " nistdata / atomic / bo... | [
-0.11786932498216629,
-0.7089716792106628,
0.4369848966598511,
0.7575802206993103,
-0.5300102829933167,
0.0810534730553627,
0.2976017892360687,
-0.5459039211273193,
-0.9227461218833923,
1.0553135871887207,
-0.7232131361961365,
0.18536537885665894,
-0.35440388321876526,
0.01323844026774168,... |
def gen _ all _ combs ( outcomes, length ) : ans = set ( [ ( ) ] ) for dummy _ idx in range ( length ) : temp = set ( ) for seq in ans : if len ( list ( seq ) ) = = 0 : outc = list ( outcomes ) else : lista = list ( outcomes ) outc = lista [ max ( list ( seq ) ) + 1 : ] for item in outc : new _ seq = list ( seq ) new _... | [
-0.8926088213920593,
0.39511898159980774,
0.8539006114006042,
0.186319962143898,
-0.5050801038742065,
0.29015132784843445,
0.53907710313797,
0.5886290669441223,
1.0673660039901733,
0.08289032429456711,
-0.3207400143146515,
-0.5528549551963806,
0.2633604109287262,
0.02225109003484249,
-0.... |
def locked ( self, locked ) : if locked is none : raise valueerror ( " invalid value for ` locked `, must not be ` none ` " ) # noqa : e501 self. _ locked = locked | [
0.04357212781906128,
0.36650219559669495,
-0.0888471007347107,
0.5663490891456604,
0.9365689158439636,
0.7716817855834961,
1.3112335205078125,
-0.22079475224018097,
0.44175297021865845,
-0.6655423641204834,
-1.0309456586837769,
-0.27176713943481445,
-0.17120327055454254,
-0.649669349193573... |
def gettensordimensions ( partition ) : # print'* * * * * * get tensor dim * * * * * *'ret = [ ] rows = list ( partition ) for row in rows : xi = row [ 1 ] a = [ ] a. extend ( xi. shape ) a. append ( np. square ( norm ( xi, 2 ) ) ) ret. append ( a ) return [ tensorops. getdim ( ret ) ] | [
-0.1966373771429062,
-0.14710216224193573,
0.6353986263275146,
0.9313001036643982,
-0.28984758257865906,
-0.7072391510009766,
0.3663000762462616,
0.38830527663230896,
0.11743753403425217,
0.29887154698371887,
-0.6004790663719177,
-0.9251105189323425,
0.5177193284034729,
-0.6414770483970642... |
def load ( self, dataset _ uri : str, *, dataset _ id : str = none, dataset _ version : str = none, dataset _ name : str = none, lazy : bool = false, compute _ digest : computedigest = computedigest. only _ if _ missing, strict _ digest : bool = false, handle _ score _ split : bool = true ) - >'dataset': | [
-0.3822241723537445,
0.6513819098472595,
0.6320635080337524,
0.029101109132170677,
-0.4779384732246399,
-0.5744592547416687,
-0.46801066398620605,
0.612490177154541,
0.5601038932800293,
-0.8291884660720825,
0.34096917510032654,
0.34861335158348083,
-0.39947691559791565,
-0.6152470707893372... |
def test _ list _ decimal _ enumeration _ 2 _ nistxml _ sv _ iv _ list _ decimal _ enumeration _ 3 _ 2 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / list / decimal / schema + instance / nistschema - sv - iv - list - decimal - enumeration - 3. xsd ", instance = " nistdata / list / ... | [
-0.7685797810554504,
-0.6170173287391663,
0.6403167247772217,
0.5285072922706604,
-0.07435185462236404,
0.13002675771713257,
-0.6749119758605957,
0.4247470200061798,
1.0518889427185059,
0.4436318874359131,
-0.9265477061271667,
-0.07559207081794739,
0.3537478446960449,
0.22731690108776093,
... |
def _ color _ styles ( ) : return'\ n '. join ('''# table. color - % d > td [ class ='id'] { background - color : rgb ( % d, % d, % d ) ; % s }'''% ( i, r, g, b,'color : # 000! important ;'if _ is _ bright ( ( r, g, b ) ) else'' ) for i, ( r, g, b ) in enumerate ( colormaps. default * 255 ) ) | [
0.24779663980007172,
-0.2063916027545929,
0.6427816152572632,
-0.025266258046030998,
0.7112756371498108,
-0.33219560980796814,
-0.8077619075775146,
-0.2211603820323944,
-0.6292356848716736,
0.5709038972854614,
0.06832330673933029,
-0.17666932940483093,
0.1545618325471878,
-0.20163851976394... |
def _ _ add _ _ ( self, other : block ) - > block : if not isinstance ( other, block ) : return notimplemented if ( len ( other. extra _ blocks ) = = 0 ) : # reduces the amount of extra objects / references created other _ cpy = other else : other _ cpy = block ( namespace = other. namespace, base _ name = other. base ... | [
0.2695437967777252,
-0.20044121146202087,
1.025655746459961,
-0.2738095223903656,
-0.13191765546798706,
0.5824657678604126,
-0.040526293218135834,
-0.6277112364768982,
0.7755489945411682,
-0.3386245667934418,
-0.2178875207901001,
0.8114987015724182,
0.052269790321588516,
0.7460761070251465... |
def shim ( self ) - > dict : return dict ( requirejs. _ _ shim ) | [
-0.57503342628479,
-0.7280991673469543,
0.4825744926929474,
-0.18595574796199799,
-1.1813734769821167,
-0.7215893864631653,
0.5423240065574646,
0.06484878808259964,
1.0727730989456177,
-0.021331435069441795,
-1.699347972869873,
-0.2873213589191437,
0.5608778595924377,
0.9401703476905823,
... |
def closeevent ( self, event ) : # self. destroylayer ( ) # mandatory for proper close # we do not want to close the plugin when closing the debug window # self. closingplugin. emit ( ) self. inspector. hide ( ) self. inspector. setpage ( none ) self. inspector. destroy ( ) event. accept ( ) | [
0.44943967461586,
-0.710524320602417,
0.5080599188804626,
0.10772281140089035,
0.14525334537029266,
0.4438576102256775,
0.9813101291656494,
0.4266546666622162,
-0.30464717745780945,
-0.7907146215438843,
0.1211407333612442,
-0.15721362829208374,
-0.9971123933792114,
1.2965309619903564,
1.... |
def get _ ss _ dist ( n = 10000, recalc = false ) : base _ path = " { } / inputs / ss _ distribution. txt ". format ( sdp ) if os. path. exists ( base _ path ) and not recalc : with open ( base _ path ) as f : values = f. readlines ( ) else : s _ data _ path = " { } / inputs / s _ vs _ depth data. xlsx ". format ( sdp ... | [
-0.10310914367437363,
0.24261581897735596,
0.6515710949897766,
0.08679550886154175,
0.011418367736041546,
0.5160475969314575,
-0.1201525330543518,
0.2438744604587555,
0.24825423955917358,
-0.012519759126007557,
-0.6486604809761047,
0.851269543170929,
0.2963462471961975,
0.22108043730258942... |
def test _ get _ all _ cves _ secretariat ( ) : res = requests. get ( f'{ env. awg _ base _ url } { cve _ url } / ', headers = utils. base _ headers ) assert res. status _ code = = utils. http _ ok assert len ( json. loads ( res. content. decode ( ) ) ['cverecords'] ) > = 1 | [
0.45429128408432007,
-0.24910710752010345,
0.6035037040710449,
0.5798904299736023,
0.8470136523246765,
0.3989934027194977,
-1.3044912815093994,
0.7455825805664062,
0.06421838700771332,
-0.4280482828617096,
-0.5666936635971069,
0.4853273630142212,
0.3126950263977051,
0.027323508635163307,
... |
def array _ to _ str ( array : list ) - > str : if not array : return " " string ='' for i in range ( len ( array ) ) : for j in range ( len ( array [ i ] ) ) : string + = array [ i ] [ j ] return string | [
-0.595611572265625,
-0.19388994574546814,
0.5013777613639832,
-0.014017214998602867,
0.042226340621709824,
0.6872103810310364,
-0.17836640775203705,
-0.1763109415769577,
0.6707318425178528,
1.1638075113296509,
0.19906049966812134,
-0.05922262743115425,
-0.0943894162774086,
0.55315399169921... |
def get _ image ( self, movie _ name ) : movie _ name = movie _ name. lower ( ) current _ directory = self. image _ directory + " \ \ " + movie _ name + ". png " if os. path. isfile ( current _ directory ) = = true : image = pil. image. open ( current _ directory ) self. frame _ image ( image ) else : movie _ nameurl =... | [
-1.4786460399627686,
0.2748856246471405,
0.9338041543960571,
0.5447384119033813,
-0.0013209922472015023,
-0.1924714595079422,
-0.052291031926870346,
0.016552764922380447,
-0.23875057697296143,
0.8592988848686218,
0.04883120208978653,
0.5549865961074829,
-0.0335557647049427,
0.9771763086318... |
async def drive _ actuator ( self, val, seat = 0 ) : if val < 0 : await self. actuator. reduce _ delta ( self. increment ) elif val > 0 : await self. actuator. increase _ delta ( self. increment ) | [
-0.67767333984375,
0.10700240731239319,
0.4750913083553314,
0.5766552686691284,
0.3341139853000641,
0.5001540184020996,
0.32742005586624146,
-0.28313350677490234,
0.2933664917945862,
-0.5454026460647583,
0.9210373163223267,
0.6977165341377258,
-0.06920064985752106,
0.3682715892791748,
1.... |
def node _ method _ new ( node : list, name, args, stmt ) - > none : node. append ( [ " node _ method ", name, args, stmt ] ) | [
-0.4725184142589569,
1.0238858461380005,
0.4019230604171753,
-0.30117735266685486,
0.18886803090572357,
-1.1095770597457886,
-1.0630931854248047,
-0.054124657064676285,
-0.9291089773178101,
0.33008691668510437,
-0.28004613518714905,
0.3425392806529999,
0.5450698733329773,
1.243305087089538... |
def release _ proxy ( mimic _ server, proxy _ resource, resp _ time = - 1, is _ failure = false ) : params = proxy _ resource if is _ failure : params ['is _ failure'] ='true'if resp _ time > = 0 : # must be positive! xxx : bug params ['response _ time'] = resp _ time else : print ( " resp time : { } ". format ( resp _... | [
-0.6051409244537354,
0.2607056200504303,
0.6578748226165771,
-0.10255246609449387,
-0.15754973888397217,
0.17176146805286407,
-0.7124096155166626,
0.03624444454908371,
0.17449624836444855,
-0.040397997945547104,
-0.21703863143920898,
0.22517350316047668,
-1.2992970943450928,
-0.08955621719... |
def test _ bad _ exe _ args _ 2 ( ) : exe _ args = [ " list - includes - int ", 5 ] with pytest. raises ( typeerror ) : _ = runsettings ( " python ", exe _ args = exe _ args ) | [
-0.18334485590457916,
0.4331706166267395,
0.5862256288528442,
0.6348907947540283,
0.5415356755256653,
0.34770891070365906,
-0.22294722497463226,
0.03132929280400276,
-0.21203091740608215,
0.6684210300445557,
-1.0962581634521484,
-0.22663632035255432,
-1.1805528402328491,
0.8337451219558716... |
def get _ env _ var _ info ( self, subs ) : actions _ table = { self. replace _ var :'replace ', self. append _ var :'append ', self. prepend _ var :'prepend ', } vars _ by _ action = { } for varname, inputs in self. env _ vars. iteritems ( ) : raw _ value, method = inputs value = raw _ value % subs action = actions _ ... | [
-0.7528270483016968,
-0.20944634079933167,
0.417582631111145,
-0.29541996121406555,
0.038783274590969086,
-0.3207018971443176,
0.22368110716342926,
-0.6116992235183716,
-0.8424779176712036,
0.10248293727636337,
-0.42958492040634155,
0.2605593800544739,
1.0996547937393188,
0.901840567588806... |
def examine _ tags ( overpass _ json, specific _ tags = none ) : def _ count _ tags ( element, tags _ dict, specific _ tags ) : if'tags'in element : for key, value in element ['tags']. items ( ) : if specific _ tags : if not any ( re. compile ( tag ). match ( key ) for tag in specific _ tags ) : continue if key not in ... | [
-0.4243433475494385,
-0.07271088659763336,
0.6122921109199524,
-0.8033533096313477,
-0.05237559229135513,
-0.5308976769447327,
0.04052814841270447,
0.16802191734313965,
-0.2621343731880188,
-0.05956261232495308,
-0.3749132752418518,
0.38163048028945923,
0.5851844549179077,
1.66797590255737... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.