text
stringlengths
25
2.19k
embedding
listlengths
768
768
def etag ( self ) - > pulumi. output [ str ] : return pulumi. get ( self, " etag " )
[ 0.836781919002533, 0.18728013336658478, 0.5158946514129639, -0.2713381052017212, 0.716201901435852, 0.8581399917602539, -0.011814916506409645, 0.1820237934589386, -0.2720343768596649, 0.6615277528762817, 0.41619449853897095, 0.1286241114139557, 0.9964767694473267, -0.28325891494750977, -...
def get _ label ( self, item, target _ lang ) : if'label'in item : return item ['label'] return item ['id']
[ -0.728134274482727, -0.8846356272697449, 0.24492907524108887, -0.07619517296552658, 1.108992338180542, 0.504450261592865, -1.503327488899231, -0.5539771914482117, 1.3119888305664062, 1.3932231664657593, -0.0005356924957595766, -0.1643666923046112, -0.05882519483566284, -1.0467078685760498,...
def dataframe ( self, variable _ list ) : assert isinstance ( variable _ list, list ) arys = [ self. array ( vname ) for vname in variable _ list ] pdf = pd. dataframe ( data = np. column _ stack ( arys ), columns = variable _ list ) del arys return pdf
[ -0.008272930048406124, -0.2833314836025238, 0.26727718114852905, 0.7663813829421997, 0.2046242505311966, -0.46349629759788513, -0.3496270179748535, -0.2025110274553299, -0.1015230119228363, 0.05702068284153938, -0.056351110339164734, 0.5732470154762268, -0.49016496539115906, 0.519040286540...
def _ _ str _ _ ( self ) : if self. _ message : return self. _ message # otherwise construct the message var = self. _ var _ name val = self. _ var _ value atn = self. _ var _ type _ name etn = self. _ exp _ type _ name or " " article = " an " if etn. lstrip ( "? " ) [ 0 ] in " aioeh " else " a " return " argument ` { ...
[ -0.06730713695287704, -0.718924880027771, 0.45021626353263855, -1.1715757846832275, 0.1897057294845581, -0.28056076169013977, 0.22229212522506714, -0.210069477558136, -0.11677942425012589, 0.25755077600479126, 1.6427476406097412, 0.7840690612792969, -0.33873409032821655, 0.5191335678100586...
def _ _ init _ _ ( self, sink : datasink, store _ type : type [ s ], transform : callable [ [ t ], s ] ) - > none : self. _ sink = sink self. _ store _ type = store _ type self. _ transform = transform
[ -0.579870879650116, 0.19138190150260925, 0.3178994953632355, 0.12195669859647751, 0.25978872179985046, -1.364717721939087, 0.6100066900253296, 0.04935974255204201, 0.818050742149353, -1.1357824802398682, -0.523794412612915, 0.9669804573059082, 0.7981199026107788, 0.260703980922699, 0.704...
def test _ api _ can _ get _ a _ user ( self ) : user = user. objects. get ( ) response = self. client. get ( reverse ('details ', kwargs = {'pk': user. id } ), format = " json " ) self. assertequal ( response. status _ code, status. http _ 200 _ ok ) self. assertcontains ( response, user )
[ 0.608424186706543, 0.38309988379478455, 0.5452821254730225, 0.1779661476612091, 0.6421192288398743, 0.9107452034950256, -0.11298831552267075, 0.02181771583855152, -0.2523726522922516, -1.0537952184677124, -0.3064921498298645, -0.05760692432522774, 0.5463652014732361, 0.27575385570526123, ...
def is _ expired ( self ) : # type : ( ) - > bool elapsed = time. time ( ) - self. _ last _ ts return elapsed > self. _ interval
[ 0.004585277289152145, 0.4116932451725006, 0.6145519018173218, -0.040138859301805496, 0.41231846809387207, 0.3332500457763672, -1.2744661569595337, 0.17712204158306122, 0.12312602996826172, 0.15438412129878998, -0.04193919152021408, 0.54725182056427, -0.2369869500398636, 0.15564708411693573...
def itksubtractconstantfromimagefilterius2dius2 _ cast ( * args ) : return _ itksubtractconstantfromimagefilterpython. itksubtractconstantfromimagefilterius2dius2 _ cast ( * args )
[ -0.12978440523147583, -1.1477839946746826, 0.2222442626953125, -1.0386711359024048, -0.8461976647377014, -0.09536035358905792, 0.2937866449356079, 0.04375752434134483, -0.5710753202438354, 0.0866646021604538, -0.5956287384033203, 1.4891166687011719, 0.48267170786857605, -0.6746781468391418...
def offset ( self ) : if self. module. device : self. _ settings. offset = self. module. device. get ( f " out { self. port _ number } _ offset " ) return self. _ settings. offset
[ 0.10840657353401184, -0.05624398589134216, 0.6112488508224487, 0.06540532410144806, -0.20007991790771484, 0.826702892780304, 1.7597922086715698, -0.20471592247486115, 0.10652213543653488, -0.056733131408691406, 0.6028540730476379, 0.614952564239502, -0.9280570149421692, -0.3964327275753021...
def full _ quad _ check ( test _ coeff ) : for perm in itertools. permutations ( np. arange ( test _ coeff. ndim ) ) : if not quad _ check ( test _ coeff. transpose ( perm ) ) : return false return true
[ 0.3477092683315277, -0.2545490264892578, 0.4230031967163086, -0.01228342205286026, -0.3474845886230469, -0.34195011854171753, 0.9665495753288269, 0.1609993278980255, 0.4281817078590393, 0.0787910521030426, -0.5031653642654419, -0.28510719537734985, -1.0550020933151245, -0.4952274560928345,...
def ids _ updated _ sd ( cls, date, freq = " m " ) : if freq = = " w " : _ sql _ base = " select distinct org _ id as fund _ id from org _ weekly _ index _ static \ where statistic _ date ='{ date }'and index _ id ='{ idxid }'". format ( date = date, nv = cls. _ nv, idxid = cls. indexid ) elif freq = = " m " : _ sql _ ...
[ -0.33077120780944824, 0.07281351834535599, 0.5102638006210327, 0.4263955056667328, -0.35071641206741333, -0.6294870972633362, -0.023604588583111763, -0.8315891027450562, 0.7430709004402161, -0.0918213352560997, 0.4879954159259796, 0.5905368328094482, 0.5156418681144714, -0.2514753937721252...
def test _ atomic _ language _ enumeration _ 4 _ nistxml _ sv _ iv _ atomic _ language _ enumeration _ 5 _ 1 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / language / schema + instance / nistschema - sv - iv - atomic - language - enumeration - 5. xsd ", instance = " nistda...
[ -0.46864914894104004, -0.7441902160644531, 0.3458172082901001, 0.6657919883728027, -0.4471181631088257, -0.011133941821753979, 0.5755569934844971, -0.3505603075027466, 0.06368435174226761, 1.1540852785110474, -0.5132102966308594, -0.1894713193178177, -0.35938113927841187, 0.229630321264266...
def _ _ join _ with _ or ( times ) : if not times : return " " if len ( times ) = = 1 : return times [ 0 ] if len ( times ) = = 2 : return " or ". join ( times ) return ", or ". join ( [ ", ". join ( times [ : - 1 ] ), times [ - 1 ] ] )
[ -0.6357158422470093, 0.2230784147977829, 0.7023446559906006, -0.2683441936969757, -0.18656301498413086, -0.29449552297592163, -1.1939983367919922, -0.5811391472816467, 0.34488850831985474, 0.5315197706222534, 0.5958802700042725, -0.9062418341636658, -0.055597998201847076, 0.141185462474823...
def colour _ check ( foreground _ colour = 39, background _ colour = 49 ) : # print ( colour. keys ( ) ) # print ( colour. values ( ) ) if foreground _ colour in colour : # print ( colour [ foreground _ colour ] [ 0 ] ) foreground _ colour = colour [ foreground _ colour ] [ 0 ] if background _ colour in colour : # prin...
[ 0.2258351594209671, -0.3164743185043335, 0.8012498021125793, -0.54276043176651, 0.09353673458099365, -0.3523048460483551, 0.21985043585300446, 0.208980530500412, -0.43950366973876953, 0.44014599919319153, 0.5450186729431152, 0.851284384727478, -0.7976326942443848, 0.8513939380645752, 0.9...
def get _ global _ link _ geometric _ jacobian _ function ( self, link : str, n : int = 1, numpy _ output : bool = false, ) - > cs. function : return self. make _ function ( " j ", link, self. get _ global _ link _ geometric _ jacobian, n = n )
[ -0.0938602164387703, 0.4481325149536133, 0.3587776720523834, 0.827759861946106, -0.3668736219406128, -0.24001729488372803, 1.579715609550476, -0.8625451922416687, -0.22334671020507812, -0.42445799708366394, -0.29711663722991943, 1.419275164604187, -0.07141679525375366, -0.4093765914440155,...
def test _ atomic _ language _ max _ length _ nistxml _ sv _ iv _ atomic _ language _ max _ length _ 1 _ 4 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / language / schema + instance / nistschema - sv - iv - atomic - language - maxlength - 1. xsd ", instance = " nistdata /...
[ 0.42548856139183044, -0.09114968776702881, 0.16868089139461517, 0.7105238437652588, -0.4913405179977417, 0.1443539410829544, -0.23919488489627838, -0.030208948999643326, 0.424238383769989, 0.6793360114097595, -0.2767806947231293, -0.4608115255832672, -0.2873903512954712, 0.1462239474058151...
def test _ example _ input _ two _ clone _ valid _ title ( self, ucc _ smartx _ selenium _ helper, ucc _ smartx _ rest _ helper, add _ input _ two ) : input _ page = inputpage ( ucc _ smartx _ selenium _ helper, ucc _ smartx _ rest _ helper ) input _ page. table. clone _ row ( " dummy _ input _ two " ) input _ page. en...
[ 0.4486454129219055, 0.3003566563129425, 0.7720857858657837, 0.9438456296920776, -0.4251963198184967, 0.7674400210380554, -0.9109976291656494, -1.057511568069458, 0.6188302636146545, 0.34448564052581787, 0.14951877295970917, 0.13585016131401062, 0.15454301238059998, -0.6034334897994995, 0...
def test _ list _ decimal _ enumeration _ 1 _ nistxml _ sv _ iv _ list _ decimal _ enumeration _ 2 _ 3 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / list / decimal / schema + instance / nistschema - sv - iv - list - decimal - enumeration - 2. xsd ", instance = " nistdata / list / ...
[ -0.9594100117683411, -0.6203491687774658, 0.6647066473960876, 0.7777799963951111, 0.09208611398935318, 0.02612004615366459, -0.3108612596988678, 0.36082378029823303, 0.7909388542175293, -0.06267475336790085, -0.9722938537597656, -0.21778374910354614, 0.3368959128856659, 0.5440552830696106,...
def tensor _ not _ equals ( self, other ) : if other is none : return true if ( tensor _ lib. tensor. _ use _ equality and ops. executing _ eagerly _ outside _ functions ( ) ) : self, other = maybe _ promote _ tensors ( self, other ) return gen _ math _ ops. not _ equal ( self, other, incompatible _ shape _ error = fal...
[ -1.1237704753875732, 0.1838410496711731, 0.6800246834754944, 0.4653007984161377, 0.13391144573688507, -0.0026746918447315693, 0.3057425916194916, -1.1593319177627563, 0.2654889225959778, 0.2624296247959137, -0.4393627941608429, -0.10710935294628143, 0.5481943488121033, -0.06748271733522415...
def send _ payload ( payload, url ) : r = requests. post ( url, json = payload ) if r. status _ code! = 200 : logging. warn ( f'send payload error, status code not 200') raise ( ) return r
[ -0.3742591440677643, -0.11374764889478683, 0.7488349080085754, -0.3221430480480194, -0.7212815284729004, -0.27247872948646545, -1.527226448059082, -0.9027770757675171, -0.5347016453742981, 0.7374067306518555, -0.3399750292301178, -0.12764476239681244, -0.15760743618011475, -0.1172392442822...
def renormalize _ node _ probabilites ( pop, exd ) : return renormalize _ node _ probabilities ( pop. size, exd. p _ array )
[ 0.11984675377607346, -0.501979410648346, 0.23589937388896942, 0.16202346980571747, -0.5996953248977661, 0.30530521273612976, -0.9647263884544373, 1.0283902883529663, -0.35888543725013733, 1.40553879737854, 0.6860927939414978, 0.4534047544002533, 0.03432657569646835, -0.17906925082206726, ...
def binary _ search ( data, target, low, high ) : if low > high : return false else : mid = ( low + high ) / / 2 if target = = data [ mid ] : return true elif target < data [ mid ] : return binary _ search ( data, target, low, mid - 1 ) else : return binary _ search ( data, target, mid + 1, high )
[ -0.6246667504310608, -0.23270095884799957, 0.5976983308792114, -0.2974831461906433, -0.03643946349620819, -0.0575663186609745, -0.7239008545875549, -0.7909132838249207, -0.011242838576436043, -0.304438978433609, -0.014093610458076, 0.7500527501106262, -0.746376097202301, -0.429551154375076...
def _ _ deepcopy _ _ ( self, memodict = { } ) : res = matrix ( self. m, self. n, init = false ) res. data = deepcopy ( self. data ) return res
[ -0.5527114272117615, -0.34764939546585083, 0.2644401788711548, -0.11227557808160782, -0.7283974289894104, 0.3292268216609955, 0.5398373603820801, 0.1969834566116333, 0.8066518306732178, -0.8951478004455566, -0.4789993166923523, 0.8310602903366089, -0.5575833320617676, -0.5425257682800293, ...
def get _ global _ link _ quaternion ( self, link : str, q : arraytype ) - > casadiarraytype : # setup assert link in self. urdf. link _ map. keys ( ), " given link does not appear in urdf " root = self. urdf. get _ root ( ) quat = quaternion ( 0. 0, 0. 0, 0. 0, 1. 0 ) if link = = root : return quat. getquat ( ) # iter...
[ -0.04913346469402313, -0.6466737985610962, 0.6892706751823425, 0.08508378267288208, 0.179482564330101, 0.07084139436483383, -0.16241127252578735, 0.12852998077869415, -0.020330537110567093, -0.497613787651062, 0.05482310801744461, 1.6267509460449219, -1.1568095684051514, -0.031230926513671...
def parse _ individuals ( samples ) : individuals = [ ] if len ( samples ) = = 0 : raise pedigreeerror ( " no samples could be found " ) ind _ ids = set ( ) for sample _ info in samples : parsed _ ind = parse _ individual ( sample _ info ) individuals. append ( parsed _ ind ) ind _ ids. add ( parsed _ ind ['individual ...
[ -0.23979097604751587, -0.6971494555473328, 0.4369177222251892, -0.2822974622249603, 0.34254810214042664, 0.8230041265487671, -0.035061873495578766, 0.16447420418262482, -0.03366439789533615, -0.14990803599357605, 0.5070230960845947, -0.4451978802680969, -0.8952410221099854, 0.7143284082412...
def no _ cols ( m, k ) : nss _ all = np. array ( list ( map ( list, itertools. product ( [ 0, 1 ], repeat = m ) ) ) ) nss _ tot = np. sum ( nss _ all, 1 ) return nss _ all [ np. where ( nss _ tot = = k ) ] # arrays of { 0, 1 } of size m with k 1s
[ -0.15327587723731995, 0.36381515860557556, 0.6096116900444031, 0.7800830006599426, -0.5995163321495056, -0.35432982444763184, 0.16820888221263885, -0.5977599620819092, -0.22384369373321533, 0.7965006828308105, -0.8491193652153015, 0.07257500290870667, -0.18113689124584198, -0.2080960571765...
def _ _ init _ _ ( self, exclude _ alerts _ path ) : # dictionaries of exclude alerts, first by alert type, and then by # search text within each alert type. basically a 2 level nested # dictionary. todo : this dictionary is not used at lookup time self. _ by _ source _ then _ search = { } # by search text only ( this ...
[ 0.28270021080970764, -0.08059880882501602, 0.4818304479122162, 0.4379410445690155, -0.9525920152664185, 0.6294222474098206, 0.3228684067726135, 0.3562682271003723, -0.22996163368225098, -0.16789188981056213, -0.15723049640655518, -0.18104322254657745, -0.25693485140800476, -0.5057932734489...
def test _ atomic _ hex _ binary _ length _ 2 _ nistxml _ sv _ iv _ atomic _ hex _ binary _ length _ 3 _ 1 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / hexbinary / schema + instance / nistschema - sv - iv - atomic - hexbinary - length - 3. xsd ", instance = " nistdata / ...
[ 0.019702130928635597, 0.0296162161976099, 0.5085083842277527, 0.836152195930481, 0.15331463515758514, 0.905994176864624, -0.5717944502830505, 0.6192138195037842, 0.19245241582393646, 0.717668890953064, -0.5090015530586243, -0.21829518675804138, 0.16869573295116425, 0.10397733747959137, -...
def apply _ half _ twist ( self, pant, bdy _ idx, direction ) : p = self. _ pants _ decomposition pants _ curve = p. pant _ to _ pants _ curves ( pant ) [ bdy _ idx ] for branch in self. branches _ next _ to _ pants _ curve ( pants _ curve, left ) : typ = self. dt _ branch _ type ( branch ) end _ curve = self. half _ b...
[ -0.7632874846458435, -0.8197025656700134, 0.6988694667816162, -0.20774319767951965, 0.5931898355484009, 0.0637359768152237, 0.4980018734931946, -0.7815002799034119, 0.08768344670534134, -0.4223645329475403, -0.40360963344573975, 1.0535475015640259, -0.5535441040992737, 0.4097524583339691, ...
def crypto _ load ( self, download = true ) : self. crypto _ df = self. load _ dataset ('cryptocurrency')
[ 0.4426828622817993, 0.31372058391571045, 0.1552182286977768, -0.2049073576927185, -0.3921191990375519, 0.28144997358322144, -0.013715039007365704, 0.6609447002410889, -0.5081073045730591, 0.19321830570697784, -0.3667725920677185, 0.8830640316009521, -0.4977041780948639, -1.064711093902588,...
def do _ svm _ sent _ pos _ hs _ ths ( data _ list, utterance _ unprocessed, lex, test _ utterance, file, column, matrix, mode ) : # make vector from the utterance of the test set vec _ test _ utterance = [ ] # vector of the utterance from the test _ set for line in open ( lex ) : line _ split = line. split ( ) n = 0 m...
[ 0.5243459343910217, -0.21683253347873688, 0.897137463092804, -0.17945867776870728, -0.241077721118927, -0.10010452568531036, 0.5192880630493164, 0.4419410824775696, -0.015257150866091251, 0.6439055800437927, -0.46453529596328735, 0.2629420757293701, -0.26643502712249756, 0.0478892996907234...
def initialize _ networks ( min _ c = min _ comparators, max _ c = max _ comparators ) : if max _ c > max _ comparators : raise valueerror ( " max _ c cannot exceed max _ comparators " ) if min _ c < 0 : raise valueerror ( " min _ c must be nonnegative " ) if min _ c > max _ c : raise valueerror ( " min _ c cannot be g...
[ -0.570534348487854, 0.2809910774230957, 0.908420205116272, -0.5633605718612671, 0.1543179303407669, 0.37504079937934875, 0.5532174110412598, -0.7367089986801147, 0.10453365743160248, 0.0760049894452095, -0.534805178642273, -0.1586349755525589, -0.017826808616518974, 0.2672034502029419, -...
def split _ dataset ( data, labels, p _ train = 0. 8, p _ valid = 0. 0, p _ test = 0. 0, ) : def aux ( d _, l _, p _, idx _ ) : n _ tot _ examples _ = d _. shape [ 0 ] n _ taken _ examples _ = int ( n _ tot _ examples _ * p _ ) chosen _ idx _ = choice ( idx _, size = n _ taken _ examples _, replace = false ) free _ ind...
[ -0.6076865196228027, 0.24757744371891022, 0.405426561832428, -0.9722747206687927, -0.4752899706363678, 0.3985785245895386, -0.09352695196866989, 0.15516920387744904, 0.19344213604927063, -0.38070952892303467, -0.2678545117378235, 0.5158711075782776, -0.16514261066913605, -1.076280593872070...
def test _ sum _ with _ valid _ input _ should _ return _ ok ( test _ client ) : url ='/ sum? value1 = { 0 } & value2 = { 1 } '. format ( 1, 2 ) response = test _ client. get ( url ) assert response. data = = b'3 \ n'assert response. status _ code = = 200
[ -0.38057923316955566, -0.2954825758934021, 0.7174380421638489, 0.7537165880203247, -0.07803889364004135, 0.9334896206855774, -0.27040401101112366, -0.3316125273704529, 0.1747441589832306, -0.6393827795982361, -0.4165860712528229, -0.08359134942293167, 0.2832958996295929, -0.497969895601272...
def testgeneratediskname ( self ) : disk _ name = common. generatediskname ( fake _ snapshot ) self. assertequal ('fake - snapshot - 857c0b16 - copy ', disk _ name ) self. asserttrue ( regex _ disk _ name. match ( disk _ name ) ) disk _ name = common. generatediskname ( fake _ snapshot _ long _ name ) self. assertequal...
[ -0.37607714533805847, 0.3830891251564026, 0.9764545559883118, 0.0009899981087073684, -0.1376982480287552, 0.2804720401763916, 0.273702472448349, 0.10194884240627289, 0.0848340392112732, -0.7669172883033752, -0.8925921320915222, -0.7911525368690491, 0.9710718989372253, 0.3431028127670288, ...
def _ read _ config _ file ( config _ filepath : path ) - > dict : try : with open ( config _ filepath, " r " ) as config _ stream : return yaml. safe _ load ( config _ stream ) except ioerror : raise runtimeerror ( f " unable to read config file : { config _ filepath } " ) except parsererror : raise runtimeerror ( f "...
[ 0.16831956803798676, -0.3198694586753845, 0.5084632039070129, -0.27053263783454895, -0.664451539516449, -0.3825790286064148, 0.12567952275276184, 0.5050232410430908, -1.1072295904159546, 0.9894995093345642, -0.08500692993402481, -0.28849512338638306, 0.20981833338737488, 0.1059702709317207...
def cosp _ isccp _ to _ thml ( clisccp, p _ name = " cosp _ prs ", tau _ name = " cosp _ tau " ) : # in order to keep missing data as missing rather than zero, # do one dim at a time with a min _ count kwarg. ( at least for actual obs ) # # note : cosp grid is different from isccp grid, so need to span a couple levels ...
[ 0.7282463312149048, -0.5844532251358032, 0.7521057724952698, -0.7375764846801758, 0.20156659185886383, -0.025908268988132477, -0.07739003747701645, 0.10142427682876587, 0.22482165694236755, 1.3544068336486816, 0.5463539361953735, -0.3917670249938965, 0.4241255223751068, -0.4136585295200348...
def _ getprojectedpageindex ( self, page _ count ) : return page _ count % self. _ adump. max _ dump _ pages
[ -0.6500795483589172, 0.5365284085273743, 0.3016662001609802, -0.6286096572875977, -0.06176706776022911, 0.7346189022064209, -0.4228072166442871, 0.6103570461273193, 0.23388893902301788, -0.024010974913835526, 0.9706829786300659, -0.4759228825569153, -0.002501077950000763, -0.23060806095600...
def create _ user ( self, email, password, * * extra _ fields ) : if not email : raise valueerror ('the email must be set') email = self. normalize _ email ( email ) user = self. model ( email = email, * * extra _ fields ) user. set _ password ( password ) user. id _ external = token _ urlsafe ( 16 ) user. save ( ) ret...
[ 0.4190589189529419, 0.8961387276649475, 0.5469621419906616, 0.06590063869953156, 0.2868845462799072, 0.7201446294784546, -1.0232417583465576, 0.5008949637413025, 0.07646444439888, 0.2936086356639862, -1.2666046619415283, -0.5453920364379883, -0.4381750822067261, -0.8035110831260681, -0.4...
def test _ update _ custom _ gradebook _ column ( self ) : # this method utilises the put request method and will make changes to the canvas instance. this needs consideration. pass
[ -0.8620169162750244, -0.3077472150325775, 0.5310483574867249, -0.056779660284519196, -0.1453269124031067, 0.7347508668899536, 1.686238408088684, -1.1436644792556763, -0.402292400598526, 0.1543998420238495, -1.1790398359298706, 0.21141155064105988, -1.0658420324325562, -0.8711329698562622, ...
def getmsdiff ( diff ) : ms = diff. days * 24 * 60 * 60 * 1000. 0 ms + = diff. seconds * 1000. 0 ms + = 1. 0 * diff. microseconds / 1000. 0 return ms
[ -0.27629801630973816, 0.4424138367176056, 0.575806736946106, -0.4495754539966583, -0.5890912413597107, -0.4310952425003052, 0.2696245610713959, -0.6708312034606934, 0.4919925928115845, -1.4308017492294312, 0.10607793182134628, -0.11148317158222198, -0.09035948663949966, 1.3980613946914673,...
def add _ object ( self, obj _ id, model _ path, * * kwargs ) : raise notimplementederror
[ -0.22106438875198364, -0.7591699361801147, 0.47066646814346313, 1.089113712310791, 0.6894788146018982, 1.2971373796463013, 0.17933493852615356, -0.05143580585718155, 0.08346986025571823, 0.015009826049208641, -0.6482785940170288, -0.12119285017251968, 0.056200988590717316, 0.12157122045755...
def count _ bits ( n ) : val = bin ( n ) return val. count ( " 1 " )
[ -0.5160511136054993, 0.7429370880126953, 0.23843511939048767, 0.9606695771217346, 0.027510059997439384, 1.1826034784317017, 0.649928629398346, -0.4937097430229187, -0.21980524063110352, -0.6168513894081116, -1.6414824724197388, 0.0165318101644516, 0.04917539283633232, 1.040828824043274, ...
def modify _ rule ( switch, pattern, actions, priority, idle _ timeout = openflow. ofp _ flow _ permanent ) : inst. stats. tally _ modify ( switch ) if not experiment : inst. send _ flow _ command ( switch, openflow. ofpfc _ modify, pattern, priority, ( idle _ timeout, actions, uint32 _ max ), openflow. ofp _ flow _ pe...
[ -0.1652022749185562, 0.24779309332370758, 0.5182141065597534, -0.28218355774879456, 1.3493306636810303, -0.23727168142795563, 0.2674257755279541, 0.22337251901626587, 1.0169776678085327, -0.3573925793170929, 0.8296968340873718, 0.10797733068466187, -0.3305681645870209, -0.17557266354560852...
def anonymize _ json ( json _ str, target _ col, encoding ) : target _ col = target _ col. split ( '.') [ - 1 ] nested _ json = ujson. loads ( json _ str. encode ( encoding ) ) anonymize _ nested _ value ( nested _ json, target _ col. split ( '.'), encoding ) return ujson. dumps ( nested _ json )
[ -1.1269571781158447, -0.6998389363288879, 0.5991702079772949, 0.3209993839263916, -0.22394651174545288, -0.5837757587432861, 0.02016928419470787, -0.2619311511516571, -0.3069393038749695, 0.7394376397132874, -1.0324686765670776, 0.905903160572052, 0.7338958382606506, -0.9217665195465088, ...
def find _ opponent ( method, room ) : if room and method = ='find _ opponent': return redirect ('game _ room ', room _ name = room. name ) return none
[ -1.0318644046783447, 0.27026015520095825, 0.7944303750991821, 0.8574315309524536, -0.05339650809764862, -0.22126805782318115, 0.2493419051170349, -0.05610121041536331, 0.014530738815665245, 0.7979138493537903, 0.8539036512374878, -0.38972121477127075, -0.12923301756381989, 0.83790373802185...
def _ create _ package ( self, install _ dir, storage _ dir, info ) : # tar up the files file _ tar = os. path. join ( self. _ work _ dir,'files. tar. gz') with tarfile. open ( file _ tar, " w : gz " ) as tar : for entry _ name in info ['files'] : full _ path = os. path. join ( install _ dir, entry _ name ) tar. add ( ...
[ 0.5561351180076599, -0.047900907695293427, 0.8627543449401855, -0.1675834059715271, 0.4172835648059845, 0.1461833417415619, 0.31764456629753113, 0.3858807682991028, -0.8694606423377991, 0.7828913331031799, 0.2704313397407532, -0.8094916343688965, 0.5912352204322815, -0.41312769055366516, ...
def create _ with _ db ( make _ csv, csv _ out _ name, remove _ banner ) : cursor. execute ( " select * from current _ urls ; " ) connection. commit ( ) results = cursor. fetchall ( ) if make _ csv : csv _ file _ out = open ( csv _ out _ name, " w + " ) csv _ writer = csv. writer ( csv _ file _ out, delimiter = ', ', q...
[ -0.11595337837934494, 0.2862894833087921, 0.821826159954071, 0.7672638893127441, 0.643135666847229, 0.005502169020473957, 0.08945339173078537, 0.7348164319992065, -0.09012682735919952, 0.01820099912583828, -0.2702579200267792, -0.6521273255348206, 0.13832728564739227, 0.6217480301856995, ...
def _ checkthirdpartyreadmesupdated ( input _ api, output _ api ) : readmes = [ ] files = [ ] errors = [ ] for f in input _ api. affectedfiles ( ) : local _ path = f. localpath ( ) if input _ api. os _ path. dirname ( local _ path ) = ='third _ party': continue if local _ path. startswith ('third _ party'+ input _ api....
[ 0.0716605857014656, -1.215080976486206, 0.685716450214386, 0.026369258761405945, 0.14261633157730103, 0.47378674149513245, -0.3196658194065094, -0.19046907126903534, -0.22808952629566193, 0.8694368004798889, 0.446451336145401, 0.3916877210140228, -0.30299854278564453, 0.5900838375091553, ...
def onwindowdeactivated ( self, event ) : self. pointofreference = { } menuroles = [ pyatspi. role _ menu, pyatspi. role _ menu _ item, pyatspi. role _ check _ menu _ item, pyatspi. role _ radio _ menu _ item ] # if we get into a popup menu, the parent application will likely # emit a window - deactivate event. but fun...
[ 0.6235023140907288, -1.4008439779281616, 0.49630922079086304, -0.21114173531532288, -0.3256547749042511, -0.3181377053260803, 0.6373093128204346, 0.11024845391511917, 0.4860478639602661, -0.052483368664979935, -0.23859427869319916, 0.5937427282333374, -0.2916707694530487, 0.307826399803161...
def corrected _ paired _ students _ ttest ( new _ score, baseline _ score, k _ fold, sig _ level = 0. 05 ) : # compute the difference between the results diff = [ y - x for y, x in zip ( new _ score, baseline _ score ) ] # comopute the mean of differences d _ bar = np. mean ( diff ) # compute the variance of difference...
[ -0.672629177570343, -0.2289295643568039, 0.7049870491027832, -0.11821574717760086, 0.04056502878665924, 0.48596295714378357, 0.18527908623218536, 0.09450158476829529, -0.012003562413156033, 1.123199701309204, -0.0743316188454628, 0.22506217658519745, 0.042828191071748734, -0.22389398515224...
def notes _ detail ( key ) : if request. method = ='put': # note = str ( request. data. get ('text ','' ) ) # notes [ key ] = note # return note _ repr ( key ) raise exceptions. notfound ( ) elif request. method = ='delete': notes. pop ( key, none ) return'', status. http _ 204 _ no _ content # request. method = ='get'...
[ -0.6004223823547363, 0.32983848452568054, 0.6285004615783691, -0.8573258519172668, -0.21433423459529877, -0.2971021234989166, -0.4150965213775635, -0.3207305371761322, 0.653829038143158, 1.0567866563796997, 0.9649889469146729, 0.5549144148826599, -0.42734086513519287, 0.23310519754886627, ...
def test _ evaluate _ alert _ true _ alert _ breaching2 ( self, send _ alert ) : trigger = trigger. objects. get ( pk = 9 ) breaching _ channels = [ { " avg " : 6, " channel " : " uw : sta1 : - - : hnn ", " channel _ id " : 1 } ] n _ alerts1 = trigger. alerts. count ( ) alert = trigger. evaluate _ alert ( true, breachi...
[ 0.17879630625247955, 0.0017195225227624178, 0.5061169862747192, -0.0355936624109745, 0.8950364589691162, -0.017128970474004745, 0.3842531740665436, -0.49483349919319153, -0.3424994945526123, 0.09990449249744415, -1.0448347330093384, 0.09926475584506989, -0.34945404529571533, 0.242693036794...
def state _ tax ( self, state _ tax ) : self. _ state _ tax = state _ tax
[ -0.40575408935546875, -0.40040895342826843, 0.2804220914840698, 0.21560759842395782, -0.010013449937105179, 0.22675266861915588, 0.2899499833583832, 0.029696177691221237, -0.9763000011444092, 0.08086160570383072, -1.2405540943145752, -0.4273163080215454, 0.9813242554664612, -0.556363999843...
def make _ roc _ data ( reference, ratios ) : det _ data = make _ det _ data ( reference, ratios ) roc _ data = [ ( fp, 100 - miss, t ) for ( fp, miss, t ) in det _ data ] return roc _ data
[ 0.3725222647190094, 0.15798325836658478, 0.386564701795578, -0.3073776364326477, 0.45644915103912354, 0.15458747744560242, -0.1532561480998993, -0.6472696661949158, -0.6564706563949585, 0.46416205167770386, -0.41054967045783997, -0.16861765086650848, 1.0440597534179688, -0.6132503151893616...
def _ get _ multi _ obj _ scores ( self, preds, preds _ vec ) : utils. thin _ line ( ) print ('calculating evaluation scores for { } detection... '. format ( self. info [ 1 ] ) ) def _ f _ beta _ score ( p, r, beta ) : if p + r = = 0 : return 0. else : return ( ( 1 + ( beta * * 2 ) ) * p * r ) / ( ( beta * * 2 ) * p + ...
[ 0.20527206361293793, -0.6598473787307739, 0.9367291331291199, -0.0828593447804451, 0.654449999332428, -0.3938307464122772, 0.5240378975868225, 0.07466348260641098, -1.0254853963851929, 0.2697460353374481, -0.21124432981014252, 0.2604285478591919, 0.24887098371982574, 0.7644075155258179, ...
def send _ msg ( self, socket, task _ id ) : print ( f " sending task id : { task _ id } " ) socket. send ( str ( task _ id ). encode ('ascii') ) self. out _ sockets. remove ( socket )
[ 0.03624970093369484, 0.4424138367176056, 0.30819129943847656, 0.11028788238763809, -0.6025746464729309, 0.07385128736495972, 0.2852567136287689, -0.5144167542457581, -0.3036222755908966, 1.3031131029129028, -0.6853395104408264, 1.0529292821884155, -0.25482749938964844, 1.1055428981781006, ...
def execution _ id ( self, execution _ id ) : self. _ execution _ id = execution _ id
[ 0.7608108520507812, -0.4706009030342102, 0.0003872778033837676, 1.0518953800201416, 0.4567866027355194, 0.6538123488426208, 0.1550855040550232, 1.2611401081085205, 0.07782997936010361, 0.4252434968948364, -0.4139762818813324, 0.007865038700401783, 0.4225690960884094, 1.0061720609664917, ...
def set _ eventid ( self, event _ id ='epochtime ', label ='event _ id') : if event _ id = ='epochtime': self. eventid = label + " = " + self. epochtimestamp else : self. eventid = label + " = " + event _ id
[ 0.4295715391635895, -0.7971284985542297, 0.6731261014938354, -0.14128512144088745, 0.8390368819236755, 1.2551110982894897, -1.0091218948364258, 0.6731488704681396, 0.5244803428649902, 0.8221591711044312, -0.15497379004955292, 1.3965054750442505, 0.6358792185783386, 0.9017548561096191, 0....
def write _ full _ data _ to _ disk ( self, output _ filepath ) : fileout = open ( output _ filepath, " w " ) for i in self. data : self. write _ one _ seq _ entry _ to _ disk _ immune ( self, i, fileout ) fileout. close ( ) return
[ -0.09419720619916916, -0.8423173427581787, 0.37974032759666443, 0.2884645462036133, 0.9249241948127747, 0.1497391313314438, 1.1525696516036987, 0.2746208608150482, -0.08805911988019943, 0.5367957949638367, -0.5547023415565491, -0.3915409445762634, -0.4268278479576111, 0.28163519501686096, ...
def isfull ( self ) : return self. keycount ( ) = = 3
[ 0.16175581514835358, 0.5314209461212158, 0.40390729904174805, 0.4870063364505768, -0.1796208620071411, 0.6036595702171326, -1.0092175006866455, 0.1358000487089157, 0.01731300912797451, 0.6432381868362427, -1.1993494033813477, -0.537402331829071, -0.4565185606479645, -0.4805710017681122, ...
def removefromindex ( self, page, author ) : ( prefix, index _ author, glossary _ index ) = self. setupvars ( author ) if not page. name. startswith ( prefix ) : return # = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = # ignore if the page being re...
[ -0.09688403457403183, -0.46229782700538635, 0.4811132848262787, -0.42225873470306396, 0.06996612250804901, -0.6334272623062134, -0.08005921542644501, 0.49369698762893677, 0.365247905254364, 0.29270872473716736, -0.09266527742147446, -0.13899530470371246, -1.2037065029144287, 0.099319607019...
def interesting _ context ( self ) : yield self. interesting ( ) self. update _ interest _ queue ( )
[ -0.237786203622818, -0.5839360952377319, 0.507423460483551, -0.5660788416862488, 0.028673576191067696, 0.3605121076107025, -0.3963092267513275, -1.242727518081665, 0.3186335265636444, -0.14143730700016022, -0.0743369311094284, 1.1385371685028076, -0.5358406901359558, -0.2210710346698761, ...
def test _ atomic _ id _ enumeration _ nistxml _ sv _ iv _ atomic _ id _ enumeration _ 1 _ 5 ( 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.18344174325466156, -0.9716343283653259, 0.4193792939186096, 0.23768462240695953, -0.355542927980423, -0.004194837994873524, 0.801970899105072, -0.36298686265945435, 0.25170522928237915, 0.944308876991272, -0.4330161511898041, 0.11418893188238144, 0.01938369683921337, 0.13627691566944122...
def _ div _ python2 ( x, y, name = none ) : with ops. name _ scope ( name, " div ", [ x, y ] ) as name : x = ops. convert _ to _ tensor ( x, name = " x " ) y = ops. convert _ to _ tensor ( y, name = " y ", dtype = x. dtype. base _ dtype ) x _ dtype = x. dtype. base _ dtype y _ dtype = y. dtype. base _ dtype if x _ dtyp...
[ -0.41693294048309326, -0.03141803666949272, 0.7371478080749512, 0.30346906185150146, -0.6513867378234863, -0.4702542722225189, 0.18276743590831757, -1.372579574584961, -0.6509279012680054, 0.08673184365034103, -0.3632781207561493, 0.9814835786819458, 1.2851355075836182, -0.0304425563663244...
def patch _ fields ( ) : # insert patchedfield in the hierarchy between field and its immediate subclasses at runtime to _ patch = [ charfield, emailfield, datefield, uuidfield, booleanfield, integerfield, bigintegerfield, decimalfield, autofield, foreignkey, textfield, jsonfield, pointfield ] for cls in to _ patch : #...
[ -0.8738209009170532, 0.16989146173000336, 0.7157854437828064, -0.6248191595077515, 0.4288575351238251, 0.25156930088996887, 1.0703145265579224, 0.22734588384628296, -0.19060446321964264, -0.32618948817253113, -0.9317503571510315, 0.34831544756889343, -1.0047717094421387, 0.4292198717594147...
async def update ( self, user : userdb ) - > user : await self. connect _ to _ database ( ) user _ update _ result = await user _ db. update ( user ) return user _ update _ result
[ -1.5421825647354126, 0.0001306024641962722, 0.5473739504814148, 0.7460992336273193, -0.5544862747192383, 0.0768992155790329, -0.10663855075836182, 0.029399454593658447, 0.1241726279258728, 0.10100994259119034, -1.0239797830581665, -0.3739088773727417, -0.6526514887809753, -0.46518072485923...
def printstate ( state ) : if type ( state ) is not list : print ( " not a valid list " ) # substitute'' for 0, to make the puzzle look better display = [ x if x! = 0 else'' for x in state ] sqrt = squareofstate ( state ) # iterate through the list, display tab - delimited for x in range ( sqrt ) : print ( * display [ ...
[ -0.055365897715091705, 0.026872333139181137, 0.5985360145568848, 0.05741327255964279, -0.7153145670890808, 0.3676455020904541, -0.33738017082214355, -0.1995488405227661, 1.2224923372268677, 0.08756297826766968, -0.3942614495754242, -0.18329939246177673, 0.22743675112724304, 0.7759897708892...
def is _ not _ constant ( series : np. ndarray ) - > bool : if len ( series ) < = 1 : return false first _ value = none for i in range ( 1, len ( series ) ) : # if not series. mask [ i ] and series. data [ i ]! = first _ value : if series [ i ]! = first _ value : if first _ value is none : first _ value = series. data ...
[ -0.5969604253768921, 0.1743854135274887, 0.6045995354652405, 0.9292080998420715, 0.2751884162425995, 0.38624921441078186, 0.2027987688779831, -0.7096050977706909, 0.4526858627796173, 0.5558875799179077, -0.418770432472229, 0.298352986574173, -0.634692370891571, 0.38299089670181274, -0.40...
def pair ( self, maxdist, master, mwidths, other, owidths ) : alignment = [ none ] * len ( master ) for i, to in enumerate ( master ) : mindist = 10000 minind = none for j, tm in enumerate ( other ) : dist = abs ( to - tm ) if dist > maxdist : continue elif dist < mindist : if 0. 2 < owidths [ j ] / mwidths [ i ] < 2 :...
[ -0.5829746723175049, -0.030119577422738075, 0.5500736236572266, 0.37892046570777893, -0.8147318363189697, -0.4682559072971344, 0.08942984789609909, 0.5524146556854248, 0.8368492126464844, 0.545047402381897, -0.14205989241600037, -0.10000722110271454, -0.7786967158317566, 0.4368797838687897...
def dbm _ to _ mw ( dbm ) : mw = 10 * * ( dbm / 10 ) return ( mw )
[ -0.4782348573207855, 0.7552177309989929, 0.17375051975250244, -0.6561682224273682, 0.6157240867614746, -0.9332088828086853, -0.2887529134750366, -0.4611213207244873, 0.6940947771072388, -0.1884072870016098, -0.4178696274757385, -0.36266615986824036, -0.822376549243927, 0.46153464913368225,...
def delete _ project ( project _ name ) : # delete folder shutil. rmtree ( os. path. join ( project _ dir, project _ name ) ) # delete project info df = pd. read _ csv ( os. path. join ( project _ dir,'projects. csv') ) df = df [ df ['project']! = project _ name ] df. to _ csv ( os. path. join ( project _ dir,'projects...
[ -0.44026103615760803, -0.114530049264431, 0.4257696568965912, 0.25066137313842773, -0.09466013312339783, 0.4823167324066162, 0.6313672065734863, 0.18243373930454254, -0.15674756467342377, 0.5409318208694458, 0.2506732940673828, 0.05846766382455826, -0.08081050962209702, 0.3819941580295563,...
def mk _ versioned _ policies ( policy, version, priority, topology, old _ version = none, fake _ edge _ ports = none ) : # initialize fresh policy objects internal _ policy = networkpolicy ( ) edge _ policy = networkpolicy ( ) # for each switch mentioned in the policy for switch, config in policy : # fixme : am i supp...
[ -0.3066534399986267, -0.5425348877906799, 0.3923560380935669, -0.18492449820041656, 0.24670588970184326, 0.8886061310768127, -0.16869233548641205, 0.42067164182662964, 0.569297730922699, 0.40380826592445374, -0.5379729270935059, -0.5073388814926147, -0.21566718816757202, 0.2109836041927337...
def is _ empty ( self ) : return self. head is none
[ -0.8411914110183716, -0.10954327136278152, 0.420565128326416, 0.018355289474129677, 1.012072205543518, -0.023157557472586632, -0.8468809127807617, -0.26195278763771057, 0.1504824161529541, -0.054830558598041534, -0.8256699442863464, 0.6759560704231262, -0.6454116702079773, 0.18009018898010...
def get ( self, request, * args, * * kwargs ) : unhealthy = false db _ read = true db _ sync = true time _ sync = true def db _ read _ unhealthy ( ) : try : with connection. cursor ( ) as cursor : cursor. execute ( " select 1 ", [ ] ) cursor. fetchone ( ) except : return true return false def db _ sync _ unhealthy ( ) ...
[ -0.5363548398017883, 0.27311909198760986, 0.9801639914512634, -0.23594680428504944, 0.5704493522644043, 0.296482652425766, -1.0122253894805908, -0.8158865571022034, -0.5226883888244629, 0.9745267629623413, 0.4630519151687622, -0.4789455831050873, -0.1773294359445572, 0.6562132835388184, ...
def shared _ step ( self, batch : batchtype, pl _ module : pl. lightningmodule, is _ training : bool ) - > t : batch = batch [ ssldatamoduletype. linear _ head ] if isinstance ( batch, dict ) else batch x, y = self. to _ device ( batch, pl _ module. device ) with torch. no _ grad ( ) : representations = self. get _ rep...
[ 0.024497726932168007, 0.412641704082489, 0.80637526512146, 0.3733009099960327, -0.37867486476898193, 1.195120096206665, 0.19004562497138977, 0.014447692781686783, 0.03645375370979309, -0.040939852595329285, -0.47584807872772217, 0.7322499752044678, -0.3774837851524353, 0.22960101068019867,...
def mock _ connection _ fixture ( ) - > asyncconnection : connection = magicmock ( spec = asyncconnection ) def _ rest _ call _ side _ effect ( path, body = none ) : return path, body connection. _ restcall. side _ effect = _ rest _ call _ side _ effect connection. api _ call = asyncmock ( return _ value = true ) conne...
[ -0.6086975932121277, -0.347572386264801, 0.7250786423683167, -0.33290210366249084, 0.1265304535627365, -0.7238852381706238, 0.1418284773826599, 0.4188080430030823, 0.19362574815750122, -0.2055707722902298, 0.4210505187511444, -0.4006210267543793, -0.08149722218513489, -0.24379730224609375,...
def set _ current _ frame ( self, name ) : selector = self. get _ web _ element _ selector ( name ) self. select _ frame ( selector )
[ -1.0916671752929688, -0.7169432640075684, 0.4673475921154022, 0.5234763622283936, 0.05944840982556343, -0.8226619958877563, 0.8112223148345947, -0.9526559114456177, 0.3929905891418457, 0.6207313537597656, -0.6392336487770081, 0.6619491577148438, -0.2897622585296631, 0.17396393418312073, ...
def _ get _ headers ( self, is _ rate _ limited : bool ) - > jsondict : headers = { sentinelhubratelimit. units _ spent _ header : self. units _ per _ request } if is _ rate _ limited : expected _ request _ wait _ time = max ( bucket. get _ wait _ time ( 0, 1, 1, 0, 0 ) for bucket in self. policy _ buckets if bucket. i...
[ -0.2417769730091095, 0.19041670858860016, 0.6741042137145996, 0.11908208578824997, 0.09091081470251083, 0.0819435566663742, -0.6209307312965393, -0.7194166779518127, -0.06755395233631134, 0.45401614904403687, 0.13759978115558624, 0.1690618097782135, 0.32189467549324036, -0.734953761100769,...
def volume _ as _ millions ( self ) : if any ( [ self. is _ error ( ), self. volume is none, self. last _ price is none ] ) : return " " return " { :. 2f } ". format ( self. volume * self. last _ price / 1000000. 0 )
[ -0.09777139127254486, -1.2156842947006226, 0.5612317323684692, 0.10360777378082275, 0.48830342292785645, -0.8475508093833923, -0.9515761137008667, -0.2996072471141815, 0.4676949381828308, 0.4459872543811798, 1.0871256589889526, 0.054273493587970734, 0.10816348344087601, 0.3394920229911804,...
def updatemappingsondevicetype ( self, typeid, logicalinterfaceid, mappingsobject, notificationstrategy = " never " ) : req = apiclient. onedevicetypemappingurl % ( self. host, " / draft ", typeid, logicalinterfaceid ) try : mappings = json. dumps ( { " logicalinterfaceid " : logicalinterfaceid, " notificationstrategy ...
[ -1.96173095703125, -0.6288591623306274, 0.496031254529953, -0.4521006643772125, -1.0946173667907715, -0.07771491259336472, 0.32955360412597656, -0.8201278448104858, 0.7064495086669922, 0.7886841297149658, -0.5248019099235535, 0.12550228834152222, -0.9471726417541504, 0.026563774794340134, ...
def h _ norm ( x ) : x = x / x [ 2 ] mean = np. mean ( x [ : 2 ], axis = 1 ) s = np. sqrt ( 2 ) / np. std ( x [ : 2 ] ) t = np. array ( [ [ s, 0, - s * mean [ 0 ] ], [ 0, s, - s * mean [ 1 ] ], [ 0, 0, 1 ] ] ) return t
[ -0.1176513135433197, -0.20201106369495392, 0.6848967671394348, 0.7301506996154785, -0.3138302266597748, 0.3381352424621582, 0.32648202776908875, 0.21606022119522095, -0.30155864357948303, 0.7968124151229858, -1.0802885293960571, 0.42830419540405273, 0.40762972831726074, -0.658907949924469,...
def add _ annotations _ using _ mixcr ( self, output _ filepath, annotations _ to _ get, delete _ output = false, debug = false ) : # run mixcr print'running mixcr...'p = popen ( ['mixcr ','align ','- f ','- - write - all ', self. filepath, output _ filepath + '. vdjca ', ], stdout = pipe, stderr = pipe ) out _ err = p...
[ 0.4396049380302429, -1.0028202533721924, 1.0499600172042847, 0.6573712229728699, -0.5397964715957642, -0.5262677669525146, 0.9658482670783997, -0.22935375571250916, 0.09216519445180893, 0.5388632416725159, 0.3713115155696869, -0.30539798736572266, -0.9367628693580627, 0.6177372336387634, ...
def get _ driver ( response : response ) - > webdriver : return response. meta. get ('driver ', none )
[ 0.1259874552488327, -0.7948822379112244, 0.22151564061641693, 0.38052812218666077, 0.8711689114570618, -0.31190744042396545, -0.13022886216640472, -0.21444757282733917, 0.6548914909362793, -0.5788516998291016, 0.34305909276008606, -0.12633490562438965, 0.037127785384655, 0.0366719551384449...
def test _ neutral _ mprobs ( self ) : opt = dict ( max _ evaluations = 2, limit _ action = " ignore " ) aln = load _ aligned _ seqs ( " data / ensg00000198712. fa ", moltype = " dna " ) # default, not optimising root probs natsel = evo _ app. natsel _ neutral ( " mg94hky ", opt _ args = opt, gc = 2 ) result = natsel (...
[ 0.2250266969203949, -0.19589494168758392, 0.44597798585891724, -0.36066412925720215, 0.2602088153362274, 0.48383504152297974, -0.7126175165176392, -0.11608542501926422, 0.11858583986759186, 0.308748334646225, 0.0979786068201065, 0.32040420174598694, -0.753788411617279, 0.37553778290748596,...
def routepointertoitem ( self, inputevent = none ) : # store the original location for scripts which want to restore # it later. # self. oldmousecoordinates = self. utilities. absolutemousecoordinates ( ) self. lastmouseroutingtime = time. time ( ) if self. flatreviewcontext : self. flatreviewcontext. routetocurrent ( ...
[ -0.5165956616401672, -0.6814901828765869, 0.5217391848564148, -0.038260363042354584, 0.31989118456840515, 0.20009727776050568, 0.8449757099151611, -0.012367191724479198, 0.2232048660516739, 0.14776772260665894, 0.22874628007411957, 0.37660515308380127, -0.021742194890975952, -0.27221718430...
def get _ codi _ iterator ( self ) : codi _ labelled _ iterator = customiterator ( self. codi _ dataset. dataset, batch _ size = self. hyper ['batch _ size'], sort _ within _ batch = true, device = self. device ) return codi _ labelled _ iterator
[ -0.0824151337146759, -0.8933364748954773, 0.2540401816368103, -0.575644850730896, -0.5336742997169495, 0.2052200585603714, 0.14049875736236572, 0.13692723214626312, -0.35019245743751526, 0.04825901612639427, 0.5210450291633606, 1.3847298622131348, -0.17439767718315125, -0.6009502410888672,...
def predict ( self, sentence : str ) - > np. array : pass
[ -0.6826221346855164, -0.8499240875244141, 0.20298615097999573, 0.13263238966464996, -0.26918908953666687, -0.6538009643554688, -0.5302742123603821, 0.17449909448623657, -0.2597401738166809, 0.28177937865257263, -0.30333903431892395, 0.6814066767692566, -0.6438744068145752, 0.12147235870361...
def test _ atomic _ qname _ max _ length _ 1 _ nistxml _ sv _ iv _ atomic _ qname _ max _ length _ 2 _ 1 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / qname / schema + instance / nistschema - sv - iv - atomic - qname - maxlength - 2. xsd ", instance = " nistdata / atomic ...
[ 0.028582248836755753, -0.6510353088378906, 0.3523010313510895, 0.7223519682884216, -0.6530375480651855, 0.30662524700164795, -0.5122719407081604, -0.24176105856895447, 0.10985969752073288, 0.3781934976577759, -0.5755797624588013, 0.23387163877487183, 0.5024457573890686, 0.12213924527168274...
def app ( request, caches ) : # get the cache for the given eviction strategy cache = caches [ request. param ] class cachedresource : " " " a cached resource with long expiration and all the different methods " " " @ cache. cached ( timeout = 60 ) def on _ get ( self, req, resp ) : if falconversion _ main < 3 : resp. ...
[ -0.5931547284126282, 0.17428870499134064, 0.8919933438301086, 0.5556558966636658, -0.41020041704177856, -0.03649059310555458, -0.393533319234848, -0.16047558188438416, 0.8480806946754456, 0.3157055675983429, -0.22811144590377808, -0.5782696008682251, 0.7427985072135925, 0.5235649347305298,...
def processing ( self ) : raise notimplementederror ( " class % s doesn't implement amethod ( ) " % self. _ _ class _ _. _ _ name _ _ )
[ -0.5337985754013062, 0.07958059012889862, 0.9267333745956421, 0.18847860395908356, -0.3807523846626282, 0.6557918190956116, 0.8589115142822266, -0.0050627305172383785, 0.3767152726650238, 0.18464621901512146, -0.204771026968956, 0.33147403597831726, 0.3365490138530731, 0.8968890905380249, ...
def test _ write _ privacy ( self ) : from carto. datasets import datasetmanager cc = cartoframes. cartocontext ( base _ url = self. baseurl, api _ key = self. apikey ) ds _ manager = datasetmanager ( self. auth _ client ) df = pd. dataframe ( {'ids': list ('abcd'),'vals': range ( 4 ) } ) cc. write ( df, self. test _ w...
[ -0.83461993932724, 0.8692725896835327, 0.4808803200721741, 0.46185195446014404, 1.0686240196228027, -0.5187293887138367, 0.19138020277023315, -0.542285680770874, -0.26911041140556335, -0.8372995853424072, -0.06283175945281982, 0.6223193407058716, -0.42342409491539, -0.35411250591278076, ...
def handlenotification ( self, _, buffer ) : # pylint : disable = invalid - name # getting iv. if len ( buffer ) = = 18 and buffer [ 0 ] = = 0x04 and buffer [ 1 ] = = 0x10 : self. _ iv = protocol. decode _ iv ( buffer ) # getting status of unlocking. elif len ( buffer ) = = 3 and buffer [ 0 ] = = 0x04 : self. _ is _ un...
[ 0.24081341922283173, -0.027920426800847054, 0.591253936290741, -0.02245328202843666, 0.4727092981338501, -1.0208990573883057, 0.4926201403141022, -0.34051740169525146, 0.41448190808296204, 0.119533970952034, -1.2134548425674438, -0.04827045276761055, -0.24027019739151, -0.4921404719352722,...
def calc _ stationary _ densities ( self, pop, exd, max _ steps, init _ mode = none, init _ data = none, initialize _ pop = true, dt = 1., tol = 1. e - 6, persist _ steps = 5, error _ check _ period = 25, res = none ) : if error _ check _ period is none : # never checks for numerical errors error _ check _ period = max...
[ -0.14689010381698608, 0.2484658658504486, 0.7599737048149109, 0.8377828001976013, -0.055051159113645554, -0.11400128901004791, -0.026021894067525864, -0.23556473851203918, -0.4661712348461151, 0.24301554262638092, 0.6071849465370178, -0.6803034543991089, 0.11580540984869003, 0.199001416563...
def group ( self ) : return self. _ group. parent
[ 0.3181355595588684, 0.7869880199432373, 0.30685093998908997, 0.07112651318311691, -0.5449387431144714, 0.5621262788772583, 1.3751405477523804, -1.045492172241211, -0.48635512590408325, -1.5559942722320557, 0.8837878108024597, 0.7413529753684998, -0.42210596799850464, -0.07259053736925125, ...
def size ( self, value ) : if isinstance ( value, int ) is not true : raise typeerror ( " size must be an integer " ) if value < 0 : raise valueerror ( " size must be > = 0 " ) self. _ _ size = value
[ -0.585479736328125, 0.5878670811653137, 0.5193964838981628, -0.32595160603523254, -0.24267786741256714, 1.3962191343307495, 0.7708274126052856, -0.3433048129081726, -0.03725748136639595, -0.031561076641082764, 0.34176430106163025, -0.6929199695587158, -0.6891262531280518, 0.856612145900726...
def namespace _ id ( self ) - > str : return pulumi. get ( self, " namespace _ id " )
[ 1.7358524799346924, -0.08276648819446564, 0.22459913790225983, 0.578576385974884, 0.5991126894950867, 0.7833181023597717, -0.5576469898223877, -0.18366412818431854, 1.8920706510543823, -0.35489654541015625, 0.028435025364160538, 1.4804182052612305, 0.029850656166672707, -0.1872789412736892...
def bin _ estimate ( data, weights = none ) : if weights is none : weights = np. ones _ like ( data ) q25 = quantile ( data, weights, 0. 25 ) q75 = quantile ( data, weights, 0. 75 ) width = 2. * ( q75 - q25 ) * np. power ( len ( weights ), - 1. / 3. ) if width > 0 : return width, int ( ( data. max ( ) - data. min ( ) )...
[ 0.03065516985952854, 0.09714265912771225, 0.6452555656433105, 0.08405593037605286, -0.7220585942268372, -0.12132926285266876, 0.05329257994890213, -0.5454583168029785, -0.0932825431227684, -0.4600559175014496, -0.3078572154045105, 0.7536346912384033, -0.8298825621604919, 0.9397338032722473...
def pop ( self, lib : str ) : requirejs. _ _ libs. pop ( lib ) requirejs. _ _ shim. pop ( lib )
[ -0.05115559324622154, -0.65505450963974, 0.5690257549285889, -0.5848950743675232, -0.300788015127182, 0.285901814699173, 0.2714379131793976, 0.36547499895095825, 0.14785465598106384, 0.7437137961387634, -0.6628326773643494, -0.046155937016010284, -0.5410431027412415, 0.6329141855239868, ...
def max _ rect0 ( data, m, n ) : maxarea = 0 ll = ( 0, 0 ) ur = ( - 1, - 1 ) for ll _ ix in xrange ( n ) : for ll _ iy in xrange ( m ) : for ur _ ix in xrange ( n ) : for ur _ iy in xrange ( m ) : ll _ t = ( ll _ ix, ll _ iy ) ur _ t = ( ur _ ix, ur _ iy ) area = _ area ( ll _ t, ur _ t ) if area > maxarea and _ all ( ...
[ 0.6470787525177002, 0.20332510769367218, 0.7873725891113281, -0.2768525779247284, -0.1948876529932022, -0.5218408107757568, -0.3699432909488678, 0.47377026081085205, 0.5351564288139343, -0.4160982668399811, 0.45245361328125, -0.14295095205307007, 0.05033529922366142, 0.8956929445266724, ...