text stringlengths 25 2.19k | embedding listlengths 768 768 |
|---|---|
def calculate _ va _ from _ vj _ vr ( vj, vr ) : if vj is not none and vr is not none : va = math. degrees ( math. atan ( vj / vr ) ) return va return none | [
0.8305470943450928,
-0.3359009325504303,
0.544960618019104,
-0.19589528441429138,
-0.4463091194629669,
-0.6845741868019104,
0.28710126876831055,
-0.09479547291994095,
0.7451517581939697,
1.1154141426086426,
0.5346362590789795,
0.36814528703689575,
-0.13170716166496277,
-0.09048983454704285... |
def endni ( self, * args ) : return _ snap. tngraph _ endni ( self, * args ) | [
0.2806278467178345,
1.5420265197753906,
0.0999627485871315,
0.6027770638465881,
0.3310677707195282,
-0.7195648550987244,
-0.03682655841112137,
-0.3477741777896881,
-1.3195737600326538,
0.6562466025352478,
-1.1257227659225464,
-1.301931619644165,
-1.1916460990905762,
-0.38447070121765137,
... |
def reserve ( self, * args ) : return _ snap. tundirnet _ reserve ( self, * args ) | [
-0.9141486287117004,
-0.3252822458744049,
-0.06168576329946518,
-0.3097081482410431,
1.443695306777954,
0.16469796001911163,
0.47908321022987366,
-0.8438488245010376,
-0.9756904244422913,
-0.5585698485374451,
-0.12729643285274506,
-1.196439504623413,
-1.1922008991241455,
-0.000504933879710... |
def parse _ query ( self, command, *, send _ args = ( none, none ), recv _ args = ( none, none ), format = none ) : ans = self. query ( command, send _ args = send _ args, recv _ args = recv _ args ) if format : parser = self. parsers. setdefault ( format, parseprocessor ( format ) ) ans = parser ( ans ) return ans | [
-0.26138997077941895,
-0.32952654361724854,
0.6174092888832092,
-0.2745799422264099,
-0.3809247314929962,
-0.3537391424179077,
-1.0506718158721924,
0.06180815398693085,
0.4814963936805725,
-0.35953471064567566,
0.5261038541793823,
0.5288081765174866,
-0.6185721755027771,
0.5602273941040039... |
def readnetfromfile ( fn ) : in = { } aux1 = { } aux2 = { } f = open ( fn,'r') for line in f : foundedge = false claves = line. split ( ) if len ( claves ) > 3 and claves [ 1 ] = ='duplex - link': foundedge = true nodo1 = str ( claves [ 2 ]. strip ('$ ns ( )') ) nodo2 = str ( claves [ 3 ]. strip ('$ ns ( )') ) # print'... | [
-0.0221828892827034,
-0.36813241243362427,
0.9563656449317932,
-0.5819981694221497,
-1.1960434913635254,
0.1854580193758011,
0.06362587958574295,
0.1004219725728035,
-0.642306387424469,
0.38541746139526367,
-0.3459029495716095,
0.3081439435482025,
0.9084935784339905,
-0.15191277861595154,
... |
def compute _ higher _ representatives ( self, n _ dim, deg, current _ page ) : # handle trivial cases if self. hom [ current _ page ] [ n _ dim ] [ deg ]. dim = = 0 : self. hom _ reps [ current _ page ] [ n _ dim ] [ deg ] = [ ] return # lift image to page hom _ barcode = self. hom [ current _ page ] [ n _ dim ] [ deg... | [
-0.5116478800773621,
-0.08631527423858643,
0.798166036605835,
-0.5863450169563293,
0.43148073554039,
-0.29581189155578613,
0.8469588756561279,
0.7068936228752136,
-0.45818042755126953,
0.22611764073371887,
-0.1672821044921875,
0.09591469913721085,
0.28011947870254517,
0.023855898529291153,... |
def test _ mail _ webhook _ closed ( self ) : mail _ ticket = mailticket ( ) mail _ ticket. mailtitle = " test " mail _ ticket. mailmessageid ='123456'mail _ ticket. mailsenderaddress ='test @ example. com'mail _ ticket. githubissuenumber = 1 mail _ ticket. save ( ) httpretty. register _ uri ( uri = " http : / / 127. 0... | [
-0.0009168261312879622,
0.09216350317001343,
0.6896739602088928,
-0.5029533505439758,
0.3890495002269745,
0.7697954773902893,
-0.24555492401123047,
0.35826095938682556,
-0.14706800878047943,
-0.443608820438385,
-1.3511046171188354,
0.38078489899635315,
-0.8419132828712463,
0.59707403182983... |
def next _ step ( self, event _ data = none ) : # step must be flagged complete to advance if self. _ step _ complete : if self. active : # if skipping steps trigger unperformed actions if not self. _ step _ triggered : if self. evaluate _ thresholds ( ) : self. trigger ( ) # sequence is already active, advance to next... | [
-0.20328642427921295,
-0.6093024611473083,
0.5017328858375549,
-0.07289165258407593,
-0.03624020889401436,
-0.2773711681365967,
0.3044570982456207,
0.45812252163887024,
-0.2541331350803375,
-0.34242263436317444,
-0.3171634376049042,
-0.042867813259363174,
0.10701989382505417,
0.64153647422... |
def content ( self ) : return [ os. path. join ( self. trashinfo _ path, filename ) for filename in os. listdir ( self. trashinfo _ path ) ] | [
0.3785952627658844,
-1.1058707237243652,
0.4294397234916687,
-0.13150596618652344,
0.6160273551940918,
0.5352712869644165,
0.03346998617053032,
0.718494176864624,
-0.31833431124687195,
-0.27807438373565674,
-0.13407829403877258,
-1.063308596611023,
0.3728339970111847,
0.2678966820240021,
... |
def cluster _ clones ( self, min _ ident _ within _ cluster = 0. 97, path _ to _ vsearch = none, temp _ dirpath = none ) : if temp _ dirpath = = none : temp _ dirpath = tempfile. mkdtemp ( dir = os. getcwd ( ) ) +'/'else : temp _ dirpath = tempfile. mkdtemp ( dir = temp _ dirpath ) +'/'# fisrt group sequences by v and ... | [
0.24808791279792786,
-0.2145041972398758,
0.9233657717704773,
0.9619300365447998,
-0.31911131739616394,
-0.34093305468559265,
0.5339841246604919,
0.1151796504855156,
0.6140097379684448,
0.6127434968948364,
0.26125696301460266,
0.6196115612983704,
-0.4270840585231781,
-0.29972243309020996,
... |
def begin _ create _ or _ update _ environment ( self, project _ name : str, environment _ name : str, body : json, user _ id : str = " me ", *, content _ type : str = " application / json ", * * kwargs : any ) - > lropoller [ json ] : | [
-0.6606861352920532,
-0.17554453015327454,
0.514071524143219,
0.20875602960586548,
-0.06374198943376541,
0.6883585453033447,
-0.34062889218330383,
-0.852094292640686,
0.06426405906677246,
0.9561042785644531,
-0.2133631855249405,
0.37527456879615784,
-0.4337402284145355,
0.49909788370132446... |
def unique _ id ( self ) - > str : return self. _ nuki _ device. nuki _ id | [
0.47820577025413513,
0.015903081744909286,
0.3457840085029602,
0.4739528298377991,
0.374042272567749,
0.5497872829437256,
0.49364256858825684,
-0.031031925231218338,
1.1087250709533691,
-0.9795606732368469,
0.10324424505233765,
-0.12626320123672485,
-0.18317057192325592,
-0.416757047176361... |
def open _ restaurant ( self ) : print ( " \ tthe restaurant is open now. " ) | [
-0.4709855020046234,
-0.7598192095756531,
0.38978585600852966,
-0.07981520891189575,
-0.2868402898311615,
0.5911405682563782,
0.17486003041267395,
1.548472285270691,
-0.698505163192749,
-0.052070651203393936,
-0.14859645068645477,
1.8206543922424316,
-0.5289990305900574,
-0.018226742744445... |
def isedge ( self, * args ) : return _ snap. tbpgraph _ isedge ( self, * args ) | [
-0.020959923043847084,
1.4424158334732056,
0.48062649369239807,
1.1794872283935547,
1.6846389770507812,
-0.2611496150493622,
0.8884331583976746,
0.5544346570968628,
-0.5509318113327026,
0.7353175282478333,
0.19926871359348297,
-0.41847196221351624,
-2.2003445625305176,
0.17985060811042786,... |
def create ( projectname, comment ) : db = get _ db _ access ( ) if projectname in db. projectls ( ) : print " the given project already exists " elif comment is none : db. createproject ( projectname ) else : db. createproject ( projectname, comment ) | [
0.49921321868896484,
0.5791231989860535,
0.29161378741264343,
-0.12033651769161224,
1.6835346221923828,
0.6116597056388855,
-0.358023464679718,
-0.29266080260276794,
0.058551352471113205,
0.35170483589172363,
0.2625553607940674,
-0.8806302547454834,
-1.3699661493301392,
-0.0969634503126144... |
def getnrfmid ( * args ) : return _ snap. tstr _ getnrfmid ( * args ) | [
0.1505689024925232,
-0.16711625456809998,
0.43883565068244934,
0.01803557574748993,
0.5750910043716431,
-0.08797302842140198,
0.10373728722333908,
-0.567492663860321,
-0.18382883071899414,
-0.478631854057312,
0.045630376785993576,
0.28972744941711426,
-0.6682423949241638,
1.140124320983886... |
def _ _ aggregate _ matrix ( self ) : if self. _ _ aggregatematrix is not none : return self. _ _ aggregatematrix alllines = [ ] for writing in self. list _ of _ works _ content ( ) : alllines + = writing self. _ _ aggregatematrix = self. _ _ tmfunction ( alllines, self. _ _ ignorespecialnoun ) return self. _ _ aggrega... | [
-0.15254972875118256,
0.13960395753383636,
0.4178895056247711,
-1.1853870153427124,
0.38846051692962646,
-0.7553038001060486,
0.8274739384651184,
-0.14945995807647705,
-0.43399932980537415,
0.010567429475486279,
0.925451397895813,
-0.3972691297531128,
-0.48277199268341064,
0.16912628710269... |
def download _ data ( project _ name : str, all _ or _ labeled : str ) : df = pd. read _ csv ( os. path. join ( project _ dir, project _ name,'data. csv') ) if all _ or _ labeled = ='labeled': df = df [ df ['verified']! ='0'] # process the labels df ['label'] = df ['label']. apply ( lambda x : str ( x ). replace (': se... | [
-0.18319502472877502,
-0.2907499372959137,
0.3173225522041321,
-0.32336729764938354,
-0.22278910875320435,
0.11578777432441711,
-1.3849395513534546,
0.8148179650306702,
-0.38865822553634644,
0.1494414359331131,
-0.11189165711402893,
0.521460771560669,
-0.2501383423805237,
0.193433046340942... |
def _ _ init _ _ ( self ) : engine = db _ connect ( ) create _ table ( engine ) self. session = sessionmaker ( bind = engine ) print ( " * * * * duplicatespipeline : database connected * * * * " ) | [
0.27197131514549255,
-0.21218736469745636,
0.4107905924320221,
0.515637993812561,
0.39113888144493103,
0.2238692343235016,
-0.0746263787150383,
0.39312827587127686,
-0.08473538607358932,
0.40970420837402344,
-0.9484082460403442,
-0.45279043912887573,
0.47875311970710754,
0.4554102718830108... |
def cal _ psnr2 ( clean, noisy, normalized = true ) : if normalized : clean = clean. add ( 0. 5 ). mul ( 255 ). clamp ( 0, 255 ) noisy = noisy. add ( 0. 5 ). mul ( 255 ). clamp ( 0, 255 ) clean, noisy = to _ numpy ( clean ), to _ numpy ( noisy ) psnr = np. array ( [ compare _ psnr ( clean [ i, 0 ], noisy [ i, 0 ], data... | [
-0.3601164221763611,
-0.7206839323043823,
0.6917186379432678,
0.13504907488822937,
-0.30434703826904297,
-0.7634809017181396,
-0.6554285287857056,
-0.6475346088409424,
-0.3663654923439026,
0.7045936584472656,
-0.5093965530395508,
0.38386380672454834,
-0.13299225270748138,
0.917058646678924... |
def _ ops _ to _ hash ( ops, axes _ mapping ) : axes _ key = [ ] for idx, axis in enumerate ( axes _ mapping ) : if axis [ 0 ] = ='x': loop _ axis = idx axes _ key. append ( " { } { } _ { } ". format ( axis [ 0 ], axis [ 4 ], axis [ 3 ] ) ) tensors = [ ] tensor _ codes = [ ] for op in ops : for tensor in op [ 1 : 4 ] :... | [
0.21571046113967896,
0.19664603471755981,
0.9534544348716736,
-0.11243952810764313,
-0.5436345338821411,
-0.4119052290916443,
0.5405436158180237,
-0.09014908224344254,
-0.4711258113384247,
1.3033746480941772,
-0.16826695203781128,
0.08016010373830795,
0.4610653519630432,
-0.313207238912582... |
def api _ ldiscnodes ( ) : url _ api = { " https : / / api. radar. f - secure. com / api / integration / scannodes / discoveryscan " } headers = {'content - type':'application / json ','apiaccesskey':'% s'% accesskey,'apisecretkey':'% s'% secretkey } # headers ['apiaccesskey'] = accesskey # headers ['apisecretkey'] = s... | [
-0.7462424039840698,
0.1583915650844574,
0.7445704936981201,
-0.5518701672554016,
0.359417587518692,
-0.07927010953426361,
-0.6929908394813538,
-0.021123280748724937,
-0.7017219066619873,
0.28483590483665466,
-0.779596745967865,
0.792404294013977,
0.3911392092704773,
0.7041597366333008,
... |
def testgotoregisterfunction ( self ) : startpageurl = self. po. current _ url ( ) self. po. set _ page _ load _ marker ( ) self. po. goto _ register ( ) self. po. wait _ for _ page _ to _ load ( ) endpageurl = self. po. current _ url ( ) assert startpageurl! = endpageurl, \ " user was not taken to the register webpage... | [
-0.479693204164505,
1.0581594705581665,
0.2761784791946411,
0.1468900442123413,
1.1189062595367432,
-0.18075978755950928,
0.6014018654823303,
0.36615073680877686,
-0.597181499004364,
-0.4191499352455139,
-0.6852350831031799,
0.4072711765766144,
-0.37338370084762573,
0.0065229893662035465,
... |
def test _ calculate _ spend _ cost _ basis1 _ buy _ used _ by _ 2 _ sells _ taxable ( accountant ) : asset = a _ btc cost _ basis = accountant. pots [ 0 ]. cost _ basis asset _ events = cost _ basis. get _ events ( asset ) asset _ events. acquisitions _ manager. add _ acquisition ( assetacquisitionevent ( amount = fva... | [
0.6053914427757263,
-0.4775633215904236,
0.8738971948623657,
0.677276611328125,
0.27736055850982666,
-0.25896888971328735,
0.8393074870109558,
-0.8242812156677246,
-0.12427418678998947,
0.25824400782585144,
-0.3107525706291199,
0.009436928667128086,
0.033647965639829636,
-0.326713174581527... |
def cnn _ nn _ run ( config, model _ class, target _ dsets, y _ codebook, num _ epochs, wrk _ dir, rank, to _ gpu, memmap, modelstatedict _ path = none, options = { } ) : pid = " { } - { } ". format ( os. getpid ( ), rank ) # process id description print ( " process id ", pid ) fdtype, ldtype = get _ tensordtypes ( to ... | [
-0.4850232005119324,
-0.136135071516037,
0.9064403772354126,
0.473161518573761,
-0.2640116512775421,
-0.2051289975643158,
0.5748993754386902,
0.1198289766907692,
-0.15666207671165466,
-0.306441992521286,
-0.14232733845710754,
0.5784964561462402,
0.39344730973243713,
0.29940515756607056,
... |
def _ reconstruct ( self, observation, return _ torch : bool = false, return _ std : bool = false, cut _ ouput : bool = true, * args, * * kwargs ) : # initialize xmean xmean = 0 # create torch tensor if necessary and put in on the same device as # the cinn model if not torch. is _ tensor ( observation ) : observation =... | [
-0.15876993536949158,
0.3596061170101166,
0.7927050590515137,
0.14007914066314697,
-0.2992548644542694,
0.03445657715201378,
0.7582862973213196,
0.8382649421691895,
-0.21980097889900208,
0.4114493429660797,
0.2705842852592468,
-0.455081582069397,
-0.09137879312038422,
-0.5581821799278259,
... |
def test _ processs _ id _ delete ( self ) : pass | [
0.42470887303352356,
-1.006381630897522,
0.15471376478672028,
0.032122232019901276,
0.21104232966899872,
0.049706898629665375,
0.2304190993309021,
0.26236429810523987,
1.375617504119873,
-0.7263108491897583,
-0.5675106048583984,
0.5197156667709351,
-0.7793009281158447,
-0.5913724303245544,... |
def texcept _ throwfull ( * args ) : return _ snap. texcept _ throwfull ( * args ) | [
0.8141573071479797,
0.2670459747314453,
0.45529112219810486,
0.02951153554022312,
-0.6079436540603638,
0.7906084656715393,
0.3850547671318054,
0.21998341381549835,
-0.027843277901411057,
1.5536911487579346,
-0.5750669240951538,
-0.595048189163208,
0.1908651739358902,
-0.16125310957431793,
... |
def to _ csv ( self, * args, * * kwargs ) : return dataframe ( self ). to _ csv ( * args, * * kwargs ) # convert to a normal pd. dataframe before exporting | [
-0.4497621953487396,
0.26276251673698425,
0.341162770986557,
0.5367655158042908,
0.12286121398210526,
-0.8332713842391968,
-0.34787285327911377,
-0.22702644765377045,
0.3270140290260315,
-0.9766305685043335,
0.37026476860046387,
1.0618617534637451,
0.18586407601833344,
-0.14857836067676544... |
def test _ io _ failure ( self ) : self. expect _ io _ error _ in _ get _ statuses ( ) self. replay _ mocks ( ) self. assert _ watch _ result ( [ 0, 1, 2 ] ) self. verify _ mocks ( ) | [
-0.24482367932796478,
0.3507075011730194,
0.2795546352863312,
0.8730403780937195,
1.5510395765304565,
0.6419615149497986,
1.2982361316680908,
-0.03287682309746742,
-0.7927848696708679,
-0.6328710317611694,
-0.7315004467964172,
-0.2321338653564453,
0.05353573337197304,
-0.4424161911010742,
... |
def vendor _ name ( self ) : return self. _ vendor _ name | [
-0.2121325433254242,
-0.30980804562568665,
0.3058077394962311,
0.48875319957733154,
-0.8335195183753967,
0.6076815128326416,
0.9767182469367981,
0.3637951612472534,
0.32240962982177734,
0.09293008595705032,
-0.018406886607408524,
0.35159558057785034,
0.9174255132675171,
0.3810391426086426,... |
def prime _ to _ dict ( prime, var _ count ) : term = { } for var in xrange ( 1, var _ count + 1 ) : pvar = 3 * ( var - 1 ) + 1 if prime [ pvar ] = = 0 : continue val = prime [ pvar + 1 ] term [ var ] = val return term | [
-0.21756912767887115,
0.3713269531726837,
0.46222952008247375,
-0.6310303807258606,
-1.2563214302062988,
-0.26628464460372925,
-0.18312962353229523,
0.349488765001297,
-0.09494688361883163,
0.5305864214897156,
-0.7541767954826355,
0.0464332140982151,
-0.4586617946624756,
0.2826105654239654... |
def teardown ( self ) : tables = ( self. test _ write _ table, self. test _ write _ batch _ table, self. test _ write _ lnglat _ table, self. test _ query _ table, self. mixed _ case _ table. lower ( ), self. write _ named _ index, ) sql _ drop ='drop table if exists { } ;'if self. apikey and self. baseurl : cc = carto... | [
-0.5548527836799622,
-0.41885659098625183,
0.5660028457641602,
0.11476324498653412,
0.3254522979259491,
-0.4725445806980133,
0.646104633808136,
-0.702968180179596,
-0.003308339510113001,
0.0831725001335144,
-0.3133881688117981,
-0.09513412415981293,
-0.7399930357933044,
0.2696780264377594,... |
def _ calc _ one _ year ( self, zero _ out _ calc _ vars = false ) : if zero _ out _ calc _ vars : self. _ _ records. zero _ out _ changing _ calculated _ vars ( ) # pdb. set _ trace ( ) ei _ payrolltax ( self. _ _ policy, self. _ _ records ) dependentcare ( self. _ _ policy, self. _ _ records ) adj ( self. _ _ policy,... | [
0.7010432481765747,
-0.6204413771629333,
0.9065238237380981,
-0.43975093960762024,
-0.4345603287220001,
0.5668011903762817,
0.7672212719917297,
0.07357435673475266,
0.12627765536308289,
0.23280568420886993,
-0.3865947425365448,
0.11838263273239136,
0.07250849902629852,
-0.0488898940384388,... |
def add _ unet _ up ( self, depth = 4, width = 2, filters = 32, max _ filters = 128, summary = true, summary _ activation = true ) : assert self. net is not none, " branches are not merged. call merge _ branches. " for saved in self. saved _ layers : assert saved is not none, " no saved layers for branch. call add _ un... | [
-1.1173770427703857,
0.4076506495475769,
1.0921345949172974,
0.38739222288131714,
0.4793049991130829,
-0.03460938110947609,
0.5078327655792236,
-0.12665867805480957,
0.32966428995132446,
-0.31955280900001526,
-0.23078937828540802,
-0.11740139871835709,
-0.2545630633831024,
0.44422939419746... |
def _ addneededproperties ( self, context ) : if not context. hasproperty ('forum _ sendto _ values') : context. manage _ addproperty ('forum _ sendto _ values ', [ ],'lines') if not context. hasproperty ('forum _ sendto _ all') : context. manage _ addproperty ('forum _ sendto _ all ', false,'boolean') | [
-0.5482620000839233,
0.025430994108319283,
0.45421910285949707,
-0.4376870095729828,
0.9660372138023376,
0.20769435167312622,
-0.2815336287021637,
-0.34869498014450073,
0.008401328697800636,
-0.4809980094432831,
0.32334667444229126,
-0.08558561652898788,
-0.022899175062775612,
1.0741913318... |
def integrate _ img ( img, img _ binarize ) : height, width, channels = img. shape img _ integral = np. zeros ( ( height, width ), np. float32 ) " " " get integral at the first column " " " for i in range ( 1, height ) : k = 1 img _ integral [ i ] [ 0 ] = img _ integral [ i - 1 ] [ 0 ] nincr = num _ of _ incrs while i ... | [
-0.2629743814468384,
0.17402879893779755,
1.003108024597168,
-0.3925389051437378,
0.11503451317548752,
-0.7454314827919006,
1.0159831047058105,
-0.3933388590812683,
-0.20685191452503204,
0.5951589345932007,
0.49138328433036804,
0.053158119320869446,
-0.5664560198783875,
0.6950333714485168,... |
def get _ context _ size ( self, eval _ past _ cases, eval _ past _ ips, geo _ costs ) : eval _ past _ ips _ len = len ( next ( iter ( eval _ past _ ips. values ( ) ) ) [ - 1 ] ) * nb _ lookback _ days eval _ past _ cases _ len = len ( next ( iter ( eval _ past _ cases. values ( ) ) ) [ - 1 ] ) * nb _ lookback _ days g... | [
-0.5011696815490723,
1.2937488555908203,
0.5040608048439026,
-0.9131476879119873,
-0.3770543932914734,
0.2661529779434204,
0.4801943302154541,
0.020785314962267876,
-0.11941491067409515,
0.29567962884902954,
0.6841199994087219,
0.09080284088850021,
0.048836998641490936,
-0.1411204338073730... |
def list ( self, engine _ path, path ) : path = self. vault. normalize ( " / " + engine _ path + " / metadata / " + path ) address = self. vault. vault _ adress + " / v1 " + path request = self. vault. requests _ request ( " list ", address, headers = self. vault. token _ header ) try : data = json. loads ( request. co... | [
-0.5823198556900024,
-0.23098812997341156,
0.6419829726219177,
-0.09041973203420639,
0.48424002528190613,
-0.7264193892478943,
-2.2562320232391357,
0.10388042777776718,
-0.5705059170722961,
1.9097410440444946,
-0.5798065066337585,
1.3202366828918457,
-0.18175849318504333,
-0.55957949161529... |
def getaddwidv ( * args ) : return _ snap. tstrutil _ getaddwidv ( * args ) | [
-0.542264997959137,
0.49038389325141907,
0.460255891084671,
-0.7193143963813782,
0.4341009557247162,
0.7209990620613098,
0.4375668168067932,
-0.34503066539764404,
-0.5795871019363403,
-1.6232048273086548,
-0.3387257158756256,
1.0149433612823486,
0.47684720158576965,
0.976733922958374,
-0... |
def test _ atomic _ hex _ binary _ pattern _ 4 _ nistxml _ sv _ iv _ atomic _ hex _ binary _ pattern _ 5 _ 4 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / hexbinary / schema + instance / nistschema - sv - iv - atomic - hexbinary - pattern - 5. xsd ", instance = " nistdata... | [
-0.11229235678911209,
-0.3290313184261322,
0.42790794372558594,
0.6660351157188416,
-0.10877145826816559,
0.10730277746915817,
0.10484791547060013,
-0.45762965083122253,
-0.4821995794773102,
0.29100915789604187,
-0.7475986480712891,
-0.5101180672645569,
-0.786983847618103,
0.56116771697998... |
def applynetwork ( weights, biases, input ) : n _ layers = len ( weights ) layer = input for i in range ( n _ layers ) : layer = sigmoid ( np. dot ( layer, weights [ i ] ) + biases [ i ] ) return layer | [
0.15579009056091309,
0.16134513914585114,
0.3334217965602875,
0.4999796450138092,
0.21643005311489105,
0.39462563395500183,
0.31536245346069336,
0.6441271305084229,
0.48818138241767883,
-0.3583279550075531,
0.10338987410068512,
-0.3849509656429291,
-1.2166094779968262,
0.6805497407913208,
... |
def set _ lr _ scale ( self, args _ lrscale ) : raise deprecationwarning | [
-0.02552657201886177,
-0.4377192258834839,
0.5379695296287537,
-0.8556210398674011,
0.40466609597206116,
-0.4179302155971527,
-1.7243461608886719,
-0.4749987721443176,
-0.7719761729240417,
0.3803234100341797,
-0.1359628438949585,
-0.2612400949001312,
-0.5208593606948853,
0.9384130835533142... |
def compute _ indexers ( self, refresh : bool = true ) : for entry in self. _ links. values ( ) : if refresh or entry. flat _ indexer is none : entry. precompute ( ) | [
-0.9109523892402649,
0.08354581892490387,
0.2973250448703766,
0.8108761310577393,
0.8824024200439453,
-0.338322252035141,
0.7083135843276978,
0.44323885440826416,
0.41452887654304504,
-0.3746107220649719,
-0.11599629372358322,
0.1773623526096344,
-0.5947345495223999,
1.081429123878479,
-... |
def read _ file ( path ) : try : with open ( path,'r +') as fh : contents = fh. read ( ) except ioerror as e : die ( " error : % s " % e ) return contents | [
0.503829836845398,
-0.5151031613349915,
0.6932004690170288,
0.2661721706390381,
-0.8181266784667969,
0.46345770359039307,
-0.8157672882080078,
-0.8316211700439453,
-0.9685872793197632,
0.27106308937072754,
0.9660232067108154,
-0.8691234588623047,
0.17291387915611267,
-1.1337010860443115,
... |
def _ createtwistjointdrivers ( self ) : dgrp = mc. group ( n = " { } _ { } _ nurbsdrivers _ { } _ { } ". format ( self. side, self. name, self. suffix, self. instance _ num ), em = 1, p = self. mod _ dict [ " notransform " ] ) for limb in [ [ " upper ", self. nurbs [ " hip " ] ], [ " lower ", self. nurbs [ " knee " ] ... | [
-0.7027665972709656,
-0.4847850203514099,
0.5279573798179626,
-1.0551636219024658,
0.3360459804534912,
-0.3991459906101227,
0.8193821907043457,
-0.21638904511928558,
-0.2546718418598175,
-0.29027122259140015,
-0.1443764567375183,
-0.3131657838821411,
-0.8153563141822815,
0.0516232810914516... |
def setup _ network ( sockfamily, prog _ cfgs ) : net _ config = { } # assign interfaces and ip addresses to all involved programs ifacemgr = ifacemanager ( sockfamily ) # fake interface for deckard itself deckard _ iface = ifacemgr. allocate ('deckard') os. environ ['socket _ wrapper _ default _ iface'] = deckard _ if... | [
-1.1069167852401733,
0.7161792516708374,
0.571561336517334,
-0.8509835600852966,
0.008162448182702065,
-0.36164429783821106,
0.28589367866516113,
-0.04687494784593582,
-0.08788511157035828,
-0.08203599601984024,
-0.3464043438434601,
-0.39066821336746216,
-0.024655085057020187,
1.5287286043... |
def output _ data _ definitions ( self ) : return { self. key _ outputs : datadefinition ( [ - 1, - 1, self. embeddings _ size ], [ torch. tensor ], " batch of embedded sentences [ batch _ size x sentence _ length x embedding _ size ] " ) } | [
0.3458977937698364,
-0.4679808020591736,
0.2078772783279419,
-0.2163633555173874,
-0.731103241443634,
-0.12697724997997284,
-0.03706808760762215,
-0.053539350628852844,
-0.8137621283531189,
0.09567221999168396,
-1.2783360481262207,
0.3249148726463318,
0.154091477394104,
0.6059436798095703,... |
def gettimezone ( self ) : return self. _ time _ zone | [
-0.260464072227478,
-0.25463637709617615,
0.1332663595676422,
0.37581589818000793,
0.6599649786949158,
-0.2667890787124634,
1.072675108909607,
0.05304805561900139,
0.7868980169296265,
-0.5541152954101562,
-0.5827547907829285,
0.41807126998901367,
-0.7848216891288757,
-0.1185622438788414,
... |
def set _ predictor ( self, predictor, t = none ) : if predictor is none : self. coord _ mapping = functools. partial ( _ default _ coord _ mapping, self. search _ range ) else : self. coord _ mapping = _ wrap _ predictor ( self. search _ range, predictor, t ) self. _ clean = false | [
-1.6742055416107178,
-0.2819831073284149,
0.42806634306907654,
0.014186760410666466,
-0.010633653029799461,
0.2919514775276184,
-0.0021983778569847345,
0.21660415828227997,
-0.5348368287086487,
-0.18175791203975677,
-0.44717323780059814,
0.05195563659071922,
0.8871015310287476,
-0.30332592... |
def display _ mol ( mol : chem. mol ) : def mol _ with _ atom _ index ( mol ) : atoms = mol. getnumatoms ( ) for idx in range ( atoms ) : mol. getatomwithidx ( idx ). setprop ('molatommapnumber ', str ( mol. getatomwithidx ( idx ). getidx ( ) ) ) return mol mol = mol _ with _ atom _ index ( mol ) allchem. compute2dcoor... | [
-0.0672881230711937,
-1.1285842657089233,
0.6639529466629028,
-0.3650243580341339,
-0.7422256469726562,
-0.047747835516929626,
0.44688355922698975,
0.20621103048324585,
0.6057881712913513,
-0.526030957698822,
0.4335980713367462,
0.09965042769908905,
0.9255538582801819,
0.01222090795636177,... |
def battery ( self, battery ) : if battery is none : raise valueerror ( " invalid value for ` battery `, must not be ` none ` " ) # noqa : e501 self. _ battery = battery | [
-0.05219916254281998,
0.5299403667449951,
-0.14029525220394135,
1.0319243669509888,
0.7304766774177551,
0.6337891817092896,
0.22432202100753784,
-0.2774685323238373,
-0.6317384243011475,
-0.1884642243385315,
-0.3708314001560211,
-0.40454360842704773,
-0.6481699347496033,
0.3582354485988617... |
def deledge ( self, * args ) : return _ snap. tundirnet _ deledge ( self, * args ) | [
-0.8022640943527222,
0.31319305300712585,
0.2759374678134918,
0.6272450089454651,
0.788600742816925,
0.3687766492366791,
0.286394864320755,
0.11900278180837631,
-0.593958854675293,
-0.4910249412059784,
0.057334575802087784,
-0.68797367811203,
-1.5495136976242065,
0.5441433787345886,
0.61... |
def clean _ format ( self ) : input _ format = self. cleaned _ data. get ('format') if not input _ format : input _ format = format _ json if input _ format not in input _ formats : # errors. append ( forms. validationerror ) raise forms. validationerror ( _ ('the format should be either json or csv.') ) return input _... | [
-0.34906721115112305,
-0.32843276858329773,
0.5810120701789856,
0.11758125573396683,
-0.14480441808700562,
0.27825021743774414,
-0.3999282121658325,
-0.4628869891166687,
0.2316160798072815,
-0.2726472318172455,
1.2404906749725342,
-0.0021661033388227224,
0.23022188246250153,
0.998218178749... |
def get _ lm _ f0tau _ allmodes ( mass, spin, modes ) : f _ 0, tau = { }, { } for lmn in modes : l, m, nmodes = int ( lmn [ 0 ] ), int ( lmn [ 1 ] ), int ( lmn [ 2 ] ) tmp _ f0, tmp _ tau = get _ lm _ f0tau ( mass, spin, l, m, nmodes ) for n in range ( nmodes ) : f _ 0 ['% d % d % d'% ( l, m, n ) ] = tmp _ f0 [ n ] tau... | [
-0.11869975179433823,
-0.9717528223991394,
0.4838331341743469,
-0.7592254877090454,
-0.4289086163043976,
-0.3122090697288513,
-0.6666461229324341,
0.325801283121109,
-0.4314340054988861,
-0.5601828098297119,
-0.6219949126243591,
-0.6397073268890381,
0.3770669400691986,
0.9731711745262146,
... |
def create _ authorization _ response ( self, request, token _ handler ) : return self. create _ token _ response ( request, token _ handler ) | [
-0.27129605412483215,
-0.3544929325580597,
0.07471021264791489,
0.4820360839366913,
-0.34299081563949585,
-0.4345548450946808,
0.29711031913757324,
-0.26987889409065247,
-0.159531369805336,
-0.33291348814964294,
-0.24194709956645966,
-0.3714488446712494,
0.2923968732357025,
-0.205428034067... |
def getgeoenabled ( self ) : return self. _ geo _ enabled | [
0.8784745335578918,
0.17270711064338684,
0.30058127641677856,
1.4257768392562866,
0.10334717482328415,
1.079416275024414,
-0.21773768961429596,
0.8766894340515137,
-0.2700682282447815,
0.34652626514434814,
-1.0766321420669556,
0.4277893006801605,
-0.7260064482688904,
-0.1281658113002777,
... |
def frame _ ch2 _ sgm _ change ( self ) : self. frame _ ch2 _ raw. setcurrentindex ( self. frame _ ch2 _ sgm. currentindex ) self. frame _ ch2 _ flt. setcurrentindex ( self. frame _ ch2 _ sgm. currentindex ) | [
-0.9708425998687744,
-1.5566298961639404,
0.4169020652770996,
-0.1441866010427475,
-0.20555712282657623,
-0.16763629019260406,
0.7052249908447266,
-0.1184857189655304,
-0.8649269342422485,
-0.014535236172378063,
-1.245489239692688,
1.6816825866699219,
0.7757633328437805,
0.3261414468288421... |
def amp _ by _ time ( x, fs, f _ range, filter _ kwargs = none, hilbert _ increase _ n = false, remove _ edge _ artifacts = true ) : # set default filtering parameters if filter _ kwargs is none : filter _ kwargs = { } # filter signal x _ filt, kernel = bandpass _ filter ( x, fs, fc = f _ range, return _ kernel = true,... | [
-0.13133761286735535,
-0.08472388982772827,
0.7462074756622314,
-0.06697601824998856,
-0.86017906665802,
-0.4307151436805725,
-0.26274046301841736,
-0.2942655086517334,
0.16445466876029968,
1.4167286157608032,
0.3473386764526367,
0.9569288492202759,
0.8281433582305908,
0.1432964950799942,
... |
def update _ loadbalancer ( self, blb _ id, name = none, desc = none, client _ token = none, config = none ) : path = utils. append _ uri ( self. version,'blb ', blb _ id ) params = { } if client _ token is none : params [ b'clienttoken'] = generate _ client _ token ( ) else : params [ b'clienttoken'] = client _ token ... | [
-0.1932670772075653,
-0.4686577022075653,
0.6458389163017273,
-0.023581260815262794,
-0.1537741720676422,
0.3514445722103119,
-1.090793490409851,
-0.5787688493728638,
0.045621488243341446,
0.9541275501251221,
-1.4480401277542114,
1.2641355991363525,
-1.4321770668029785,
0.34922102093696594... |
def prepare _ request _ body ( self, client _ id = none, code = none, body ='', redirect _ uri = none, * * kwargs ) : code = code or self. code return prepare _ token _ request ('authorization _ code ', code = code, body = body, client _ id = self. client _ id, redirect _ uri = redirect _ uri, * * kwargs ) | [
-0.8502692580223083,
1.090707778930664,
0.6309901475906372,
0.29445913434028625,
0.20832976698875427,
-0.5388387441635132,
-0.6321892738342285,
-0.18584975600242615,
1.5193291902542114,
-0.16228340566158295,
0.2719760537147522,
0.8992642760276794,
0.11796105653047562,
0.08970801532268524,
... |
def test _ sign _ rsa _ sha1 ( self ) : base _ string = self. control _ base _ string _ rsa _ sha1 private _ key = self. rsa _ private _ key control _ signature = self. control _ signature _ rsa _ sha1 sign = sign _ rsa _ sha1 ( base _ string, private _ key ) self. assertequals ( sign, control _ signature ) sign = sign... | [
-0.4297586977481842,
-1.1281780004501343,
0.32881617546081543,
0.45103681087493896,
0.8630954623222351,
-0.24013613164424896,
-0.01983012817800045,
0.09009304642677307,
0.5793710947036743,
-0.028226150199770927,
-0.5191208720207214,
-0.25721895694732666,
-0.5342974662780762,
-0.09418748319... |
def isuc ( * args ) : return _ snap. tch _ isuc ( * args ) | [
-0.05931699648499489,
0.5218742489814758,
0.5508851408958435,
0.49518805742263794,
0.45845040678977966,
0.4906047284603119,
0.34647148847579956,
1.1524306535720825,
-0.4196191728115082,
0.777860701084137,
-0.3740481436252594,
0.3446364104747772,
-0.4458717703819275,
0.5001949667930603,
-... |
def _ _ init _ _ ( self, path _ prefix : str = none, redshift _ galaxy : float = 1. 0, setup _ hyper : setuphyper = none, setup _ light : union [ setuplightparametric, setuplightinversion ] = none, setup _ mass : union [ setupmasstotal, setupmasslightdark ] = none, setup _ smbh : setupsmbh = none, ) : self. path _ pref... | [
0.07683801651000977,
-0.3007335960865021,
0.6517616510391235,
0.9366021752357483,
0.23966312408447266,
-0.1364317089319229,
0.2008223682641983,
0.3551713526248932,
0.15158602595329285,
-0.12781980633735657,
0.09817180782556534,
0.12091168016195297,
-0.0702577531337738,
0.8992074131965637,
... |
def add _ showtime ( request ) : if not request. user. is _ superuser : messages. error ( request,'sorry, only store owners can do that.') return redirect ( reverse ('home') ) if request. method = ='post': form = showtimeform ( request. post ) if form. is _ valid ( ) : showtime = form. save ( ) messages. success ( requ... | [
0.029679352417588234,
0.646966278553009,
0.8516824841499329,
0.746961772441864,
0.1429695039987564,
0.3499777913093567,
0.2503763437271118,
0.8319610953330994,
0.8974012136459351,
-0.010221659205853939,
-0.1730283796787262,
-0.759911835193634,
-0.2802124321460724,
0.35882213711738586,
0.... |
def parse _ string ( string _ board, game _ board ) : # only call the parse board method for now. # the details with player management will be worked out later. parser. parse _ board ( string _ board, game _ board ) | [
0.8472613096237183,
-0.5493068695068359,
0.293941468000412,
0.2201298326253891,
0.13621143996715546,
-0.3853543698787689,
-0.3543815612792969,
0.005193880293518305,
-0.4289090633392334,
-0.23542992770671844,
0.29807180166244507,
0.6172505617141724,
-0.13960689306259155,
-0.1018545776605606... |
def new ( * args, * * kargs ) : obj = itksubtractconstantfromimagefilterid3did3 _ superclass. _ _ new _ orig _ _ ( ) import itktemplate itktemplate. new ( obj, * args, * * kargs ) return obj | [
1.270392656326294,
0.5525494813919067,
0.4982301890850067,
-1.076072096824646,
-0.9555686116218567,
0.9880985617637634,
-0.5804224610328674,
1.1283107995986938,
0.8736200928688049,
-0.1924966722726822,
-1.5261445045471191,
-0.4675750732421875,
0.02170463837683201,
-0.6139510869979858,
0.... |
def get _ data _ from _ sources ( sources, start, end ) : start = start - timedelta ( days = 7 ) index = pandas. datetimeindex ( start = start, end = end, freq ='d'). date merged _ frame = pandas. dataframe ( index = index, columns = ['price ','priority'], dtype ='float64') for source in sources. order _ by ('priority'... | [
-1.0919262170791626,
0.8653534650802612,
0.5582117438316345,
-0.3241797089576721,
0.13176578283309937,
-0.340515673160553,
-1.2371114492416382,
-0.2875678241252899,
0.09911112487316132,
-0.8341028690338135,
0.13018132746219635,
0.1760229766368866,
0.5235539078712463,
0.1486012041568756,
... |
def test _ value _ error ( self ) : with pytest. raises ( valueerror ) : savannah. set _ parameters ( f _ max = - 100 ) with pytest. raises ( valueerror ) : savannah. set _ parameters ( alpha = - 0. 3 ) | [
-0.3557318449020386,
1.054766297340393,
0.21399256587028503,
0.42076095938682556,
1.3820836544036865,
0.2933054268360138,
-0.5606768131256104,
0.367507666349411,
-0.5735876560211182,
0.8096254467964172,
-0.06378201395273209,
0.8305903077125549,
0.6198867559432983,
1.5074647665023804,
-0.... |
async def test _ options _ flow _ connection _ error ( hass : homeassistant ) - > none : config _ entry = mockconfigentry ( domain = domain, title = " nina ", data = deepcopy ( dummy _ data ), ) config _ entry. add _ to _ hass ( hass ) with patch ( " pynina. baseapi. baseapi. _ makerequest ", side _ effect = apierror (... | [
-0.7337628602981567,
0.08194215595722198,
0.3924155533313751,
-0.30684369802474976,
0.9434511065483093,
-0.12905524671077728,
-0.22338761389255524,
0.08437755703926086,
0.3844260573387146,
-0.08911047130823135,
-0.5386003851890564,
-0.026750024408102036,
0.08188200742006302,
-0.04801278188... |
def begni ( self, * args ) : return _ snap. tneanet _ begni ( self, * args ) | [
0.44985851645469666,
0.37793320417404175,
0.23821279406547546,
0.675805389881134,
0.9896681904792786,
-0.5781950354576111,
-0.07766496390104294,
-0.9511321187019348,
-0.6101922988891602,
-0.2571566700935364,
-0.05550398677587509,
-1.0681508779525757,
-0.0814196839928627,
0.4203288555145263... |
def test _ search ( self ) : result = result ( retval = { " user " : { " id " : 5, " name " : " john ", " children " : ['kevin ','britney'] } } ) self. assertequal ( result. search _ value ( " user. id " ), 5 ) self. assertequal ( result. search _ value ( " user. children " ), ['kevin ','britney'] ) self. assertisnone ... | [
-0.031020114198327065,
1.0523313283920288,
0.6374077796936035,
0.49725425243377686,
0.26847144961357117,
0.038763582706451416,
0.13048651814460754,
-0.8865780830383301,
-0.276256799697876,
-0.4118943214416504,
-0.4249364137649536,
-0.6072045564651489,
-0.05290450528264046,
0.18852905929088... |
def _ _ init _ _ ( self, * args ) : _ snap. tneanet _ swiginit ( self, _ snap. new _ tneanet ( * args ) ) | [
-0.611661970615387,
0.3239533305168152,
0.11840436607599258,
-0.6933669447898865,
0.22335276007652283,
0.02491944096982479,
0.5506352186203003,
-0.4909038245677948,
-0.8518421053886414,
0.15159869194030762,
-0.4162139892578125,
-1.4143710136413574,
0.2251909375190735,
1.0510036945343018,
... |
def write _ csv ( df, path ) : # note : paths need to be represented only as string in pyspark path = path if isinstance ( path, str ) else str ( path ) df. write. csv ( path, mode = " overwrite ", header = true ) | [
-0.611825168132782,
-0.15533074736595154,
0.2865096628665924,
0.6032270789146423,
0.6005914211273193,
-0.898162841796875,
0.34891414642333984,
0.03936047852039337,
-0.7579688429832458,
-1.0447858572006226,
0.48584702610969543,
0.27856725454330444,
0.1825537383556366,
-0.17910325527191162,
... |
def refresh ( self ) : self. schedules = self. _ get _ schedules ( ) | [
0.015603539533913136,
-0.44944727420806885,
0.21079939603805542,
0.6431692242622375,
-0.6384416818618774,
-0.23146185278892517,
-0.6830185651779175,
-0.8400272130966187,
-0.019247421994805336,
0.45285043120384216,
0.5109104514122009,
1.2046562433242798,
0.24237452447414398,
-0.277885645627... |
def get _ repolist _ to _ server ( self, repolist ) : self. logger. debug ( " return product list to server via list " ) ret = [ ] for elem in repolist : d = elem. split ( " ; " ) ret. append ( [ d [ 0 ], d [ 2 ] + " - " + d [ 3 ], d [ 1 ] ] ) # [ ['mysql. workbench,'6. 2. 4 - go1 ', 456453de782... ],... ] return ret | [
-1.7447044849395752,
-0.5441200137138367,
0.6268594264984131,
0.10352201014757156,
0.13930638134479523,
0.5366556644439697,
-0.030583878979086876,
-0.0927879810333252,
0.7439684867858887,
1.4206020832061768,
-1.5303995609283447,
0.06411375850439072,
-0.8234542608261108,
0.01810932904481887... |
def icon ( self ) : return self. var _ icon | [
0.2755298912525177,
-0.3593020439147949,
0.23733723163604736,
-0.08748514205217361,
-0.7613083720207214,
0.0813698098063469,
0.9421783089637756,
0.3250054121017456,
-0.3989511728286743,
0.06744139641523361,
-0.4794248640537262,
0.688801109790802,
0.047996263951063156,
-0.607962429523468,
... |
def getdata ( self ) : return self. data | [
-0.28760218620300293,
-0.7202747464179993,
0.2497812658548355,
-0.25493812561035156,
0.23781222105026245,
1.3421093225479126,
-0.36205795407295227,
-0.6444982290267944,
0.3786126673221588,
-1.9520658254623413,
-0.298560231924057,
0.9837871193885803,
-0.32372167706489563,
-0.238221824169158... |
def _ _ init _ _ ( self, name ) : self. name = name if self. is _ not _ in _ db ( ) : print ( name + " is not in db " ) self. add _ to _ db ( ) | [
-0.30248507857322693,
-0.14681214094161987,
0.4788413941860199,
0.2850443124771118,
-0.42746782302856445,
1.0069323778152466,
-0.5229918956756592,
-0.06988155841827393,
0.024209564551711082,
0.7306993007659912,
-0.6535604000091553,
-0.380071759223938,
-0.7600429058074951,
1.090933442115783... |
def get _ records _ table ( for _ habit, n ) : today = now ( ) tomorrow = today + timezone. timedelta ( days = 1 ) n _ days _ ago = today - timezone. timedelta ( days = n ) # find successes in last n days successes = record. objects. filter ( habit = for _ habit, date _ _ gt = n _ days _ ago, date _ _ lt = tomorrow ). ... | [
-0.7639335989952087,
0.9326132535934448,
0.6970159411430359,
-0.6824342608451843,
0.08638321608304977,
-0.06733793020248413,
-0.3526269793510437,
-0.4449329376220703,
-1.3107911348342896,
-0.2016626000404358,
0.1863701194524765,
0.35568341612815857,
0.1687593013048172,
0.5443724989891052,
... |
def on _ pushbutton _ save _ realtime _ clicked ( self ) : # todo : save the last one data pass | [
0.48263823986053467,
0.18211601674556732,
0.5415340065956116,
0.21807479858398438,
0.4141736924648285,
-0.34667056798934937,
0.029596593230962753,
0.5738121867179871,
0.5720208287239075,
1.02975594997406,
-1.6148788928985596,
-0.5337970852851868,
-0.5683121681213379,
0.8733130693435669,
... |
def run ( self ) : respondents _ dict, variable _ parameters = self. unpack _ data ( folder = self. data _ type, year = self. year, year _ lookup = self. data _ map [ self. data _ type ] ) # handle edge where the 2011 population characteristics contains more than 2000 columns, remove fields related # to the csaq survey... | [
-0.684474766254425,
-0.7950485944747925,
0.6479518413543701,
-0.8035777807235718,
-0.3988463878631592,
0.36586993932724,
0.12661725282669067,
0.38371142745018005,
0.300274133682251,
0.7342533469200134,
-0.31704553961753845,
-0.15376169979572296,
0.13043704628944397,
-0.23660705983638763,
... |
def get _ phone _ number ( username ) : try : return phonetousernamemapping. objects. get ( username = username ). phone except phonetousernamemapping. doesnotexist : return none | [
-0.480081170797348,
-0.08248186111450195,
0.34422194957733154,
0.5782684087753296,
0.11243704706430435,
0.25428250432014465,
0.17949891090393066,
-0.10892564803361893,
0.46725597977638245,
-0.32690468430519104,
-0.20294177532196045,
-1.3224917650222778,
0.06563032418489456,
0.0269292015582... |
def _ signal _ write _ ha _ state ( self, channels : list [ int ] | none ) - > none : if channels is none : async _ dispatcher _ send ( self. _ hass, f " { self. webhook _ id } _ all ", { } ) return for channel in channels : async _ dispatcher _ send ( self. _ hass, f " { self. webhook _ id } _ { channel } ", { } ) | [
-0.010976647026836872,
-0.07742350548505783,
0.3777233362197876,
-0.2591038942337036,
1.6307523250579834,
-0.4053918719291687,
-0.19559992849826813,
0.299298495054245,
0.000583156943321228,
0.4061083495616913,
-0.69095379114151,
-0.5203308463096619,
0.4815228283405304,
1.0909521579742432,
... |
def quadratic ( x1, x2 ) : return ( x1 - 1 ) * * 2 + 8 * ( x2 - 1 ) * * 2 | [
0.8735784292221069,
-0.6010558009147644,
0.46421292424201965,
0.2986086308956146,
-0.24380779266357422,
-0.4557076692581177,
-1.6517164707183838,
-1.7367677688598633,
-0.9767928719520569,
0.22059370577335358,
-0.5290944576263428,
1.2817009687423706,
0.062241263687610626,
-1.474514603614807... |
def endmodeneti ( self, * args ) : return _ snap. tmmnet _ endmodeneti ( self, * args ) | [
-1.192698359489441,
0.2087969183921814,
0.7031919956207275,
-0.3131062984466553,
0.9545527696609497,
0.3253762125968933,
-0.22385814785957336,
-0.2186284214258194,
-0.9150556325912476,
0.27360761165618896,
-0.6445600390434265,
-0.6631286144256592,
-0.8255023956298828,
0.4456770718097687,
... |
def _ telegram _ location _ callback ( self, update, context ) : self. _ from _ telegram _ location _ publisher. publish ( navsatfix ( header = header ( ), latitude = update. message. location. latitude, longitude = update. message. location. longitude, position _ covariance _ type = navsatfix. covariance _ type _ unkn... | [
0.02602572739124298,
-1.6971079111099243,
0.24409349262714386,
-0.6428947448730469,
-0.46890777349472046,
0.6218287944793701,
-0.04501553997397423,
0.5972904562950134,
-0.1118813008069992,
0.5155593156814575,
0.06169857457280159,
0.44285693764686584,
0.8503823280334473,
-0.4076289534568786... |
def makemask _ rgrowth ( self, valuemap, coordinate, voxnum, maskname ='rgmask. nii. gz') : import warnings warnings. simplefilter ('always ', userwarning ) if isinstance ( voxnum, int ) : voxnum = [ voxnum ] if len ( voxnum ) = = 1 : voxnum = voxnum * len ( coordinate ) if len ( voxnum )! = len ( coordinate ) : raise ... | [
-0.9428619146347046,
0.13827359676361084,
0.5803186893463135,
0.7196775674819946,
0.40038248896598816,
-0.17600171267986298,
0.9343051314353943,
-1.069287657737732,
-0.056220199912786484,
0.031415052711963654,
0.0445963554084301,
-0.3376152515411377,
-0.37373873591423035,
0.007425443269312... |
def get _ coco ( data _ path : str, batch _ size : int ) - > dataloader : train _ path = data _ path +'/ train2017'annotation _ file _ path = data _ path +'/ annotations / instances _ train2017. json'coco _ training _ data = cococaptions ( root = data _ path, annfile = annotation _ file _ path, transform = transforms. ... | [
0.3895828127861023,
0.11615438014268875,
0.3571491241455078,
-0.6788439750671387,
-0.5464354157447815,
-0.06241937726736069,
0.0838342234492302,
0.3670049011707306,
-1.0224595069885254,
-0.337473064661026,
-0.5267232656478882,
0.5022620558738708,
0.8075945973396301,
-0.42091983556747437,
... |
def post ( self, request ) : form = addreservation ( request. post ) if form. is _ valid ( ) : added _ reservation = reservation. objects. create ( car = form. cleaned _ data [ " car " ], driver = form. cleaned _ data [ " driver " ], start _ date = form. cleaned _ data [ " start _ date " ], end _ date = form. cleaned _... | [
-0.20503196120262146,
0.6537380814552307,
0.7798020839691162,
0.30691033601760864,
0.006601989734917879,
0.5968316197395325,
-0.9806790947914124,
0.506187379360199,
-0.283384770154953,
0.20857751369476318,
0.7034538984298706,
-0.6339331865310669,
-0.12264618277549744,
0.13590581715106964,
... |
def _ _ acquire _ cset _ blocks ( self, cset ) : blocks = [ ] for chan in cset. chan : if chan. is _ interleaved ( ) : continue ; # skip interleaved blocks. extend ( self. _ _ acquire _ chan _ block ( chan ) ) return blocks | [
0.5365859866142273,
-0.7079477310180664,
0.4593025743961334,
-0.04363328590989113,
0.16070938110351562,
0.41478267312049866,
0.41173863410949707,
-1.2109602689743042,
0.7511724829673767,
0.025974314659833908,
0.1379121094942093,
-0.10362637042999268,
-0.437007337808609,
1.0273228883743286,... |
def norm _ percolumn _ allrows ( df, index _ ='datetime') : df _ = df. set _ index ( index _ ). copy ( ) for i in df _. columns. values : df _ [ i ] = df _ [ i ] / np. max ( np. abs ( df _ [ i ]. values ) ) df _ = df _. reset _ index ( ) return df _ | [
-0.09290171414613724,
0.40092676877975464,
0.9096591472625732,
0.7786630392074585,
-0.3375100791454315,
0.12550221383571625,
0.18024466931819916,
0.3206580579280853,
-0.13779392838478088,
0.09480930864810944,
0.9347448945045471,
-0.31470412015914917,
0.657317042350769,
0.07487765699625015,... |
def get ( self, bpmr, corr ) : i = self. index ( bpmr [ 0 ], bpmr [ 1 ] ) j = self. index ( corr [ 0 ], corr [ 1 ] ) if self. _ mask and self. _ mask [ i, j ] : return none return self. m [ i, j ] | [
0.26220032572746277,
-0.7203039526939392,
0.5493515729904175,
-0.1445295810699463,
0.05205748602747917,
-0.7091406583786011,
0.3560372591018677,
-1.4820358753204346,
-0.596229612827301,
-0.5026242136955261,
1.0106772184371948,
0.8566080927848816,
-1.932167410850525,
-1.6766055822372437,
... |
def _ _ init _ _ ( self, alpha _ calcs, params = none ) : self. params = params or { } self. calcs = alpha _ calcs | [
0.7370094656944275,
0.18864619731903076,
0.48867812752723694,
0.6296894550323486,
-0.03340587019920349,
0.4855208396911621,
0.10480839014053345,
-0.06071317195892334,
0.1459132432937622,
-0.43581169843673706,
0.11037550866603851,
-0.5892789959907532,
0.14432856440544128,
1.439148187637329,... |
def test _ participation ( ) : test _ path = tempfile. mkdtemp ( ) x _ train, metadata = participation ( test _ path ) try : assert x _ train. shape = = ( 872, 7 ) except : shutil. rmtree ( test _ path ) raise ( ) | [
0.765735924243927,
0.538327693939209,
0.43878358602523804,
-0.1305272877216339,
1.240256428718567,
0.9619907140731812,
0.8777884244918823,
0.6986820697784424,
-0.2110915184020996,
0.16250334680080414,
0.20116670429706573,
-1.0099238157272339,
-0.31986454129219055,
-1.1589432954788208,
0.... |
def update ( self ) : self. api. update ( ) if self. api. result is none : return name ='{ } { } { } '. format ( self. var _ name. lower ( ), self. var _ type, self. var _ period ) state = self. api. result [ name ] if self. var _ type = ='time': self. var _ state = state elif self. var _ type = ='value': self. var _ s... | [
-1.0213212966918945,
-0.7028336524963379,
0.46621206402778625,
-0.5973877906799316,
-0.422249972820282,
-0.253507524728775,
-0.17681977152824402,
-0.8292686343193054,
-0.1562122106552124,
0.5963332056999207,
-0.09176860749721527,
0.21479804813861847,
-0.2515994906425476,
0.9287183284759521... |
def _ full _ path ( file _ ) : module _ path = os. path. dirname ( os. path. realpath ( _ _ file _ _ ) ) return os. path. join ( module _ path, '.. ','adas _ data ', file _ ) | [
0.8321028351783752,
0.0018011389765888453,
0.4692869484424591,
-0.7801933884620667,
-0.3061352074146271,
1.412845253944397,
0.2926446199417114,
0.24315910041332245,
-0.5767828226089478,
0.38315415382385254,
0.5934582352638245,
0.6058021783828735,
1.0775012969970703,
0.28958773612976074,
... |
def assemble _ full _ matrix ( data _ dir, nk, simple = true ) : if simple : mat _ str ='_ simple'else : mat _ str ='_ canonical'matrix = np. memmap ( data _ dir +'scattering _ matrix'+ mat _ str + '. mmap ', dtype ='float64 ', mode ='w + ', shape = ( nk, nk ) ) mat _ row _ dir = data _ dir +'mat _ rows /'for k in rang... | [
-0.5776742100715637,
-0.1864745318889618,
0.6828417778015137,
-0.3031198978424072,
-0.17105326056480408,
0.3218059837818146,
0.05827053636312485,
0.2084161341190338,
0.31256285309791565,
0.32586440443992615,
0.2156580239534378,
0.1561642289161682,
0.6764861345291138,
0.5120364427566528,
... |
def get _ auth _ token ( self, verifier, oauth _ token, oauth _ token _ secret ) : endpoint ='/ oauth / access _ token'oauth = oauth1 ( self. consumer _ key, client _ secret = self. consumer _ secret, resource _ owner _ key = oauth _ token, resource _ owner _ secret = oauth _ token _ secret, verifier = verifier ) respo... | [
-0.17246603965759277,
-0.9782356023788452,
0.5198513865470886,
0.13616019487380981,
0.25697293877601624,
-0.497554212808609,
-0.777435302734375,
0.256708025932312,
-0.6714536547660828,
-0.15625907480716705,
-0.6532787084579468,
1.0270856618881226,
0.42676329612731934,
-0.003778558224439621... |
def putuint ( self, * args ) : return _ snap. tsout _ putuint ( self, * args ) | [
-0.015646230429410934,
0.417671799659729,
0.7116929292678833,
-0.6749489903450012,
0.20532885193824768,
-0.1126864105463028,
0.9612950086593628,
1.5435338020324707,
-0.0687037855386734,
-0.5975815057754517,
-0.9898908138275146,
-0.6016068458557129,
-0.3171411156654358,
0.3099425733089447,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.