text
stringlengths
25
2.19k
embedding
listlengths
768
768
def stack _ corr ( mytuple, cutoff ) : print ('number of files being stacked :'+ str ( len ( mytuple. filepaths ) ) ) ; a = np. zeros ( ( len ( mytuple. yvalues ), len ( mytuple. xvalues ) ) ) c = 0 ; it = np. nditer ( mytuple. zvalues [ 0, :, : ], flags = ['multi _ index'], order ='f') ; # iterate through the 3d array...
[ -0.4572727680206299, 0.12512966990470886, 0.7640172839164734, -0.917300820350647, -0.14671573042869568, -0.3978508412837982, 1.5421050786972046, -0.264300674200058, 0.02172519825398922, 0.575189471244812, 0.5117586851119995, 0.3014865517616272, -0.7486348748207092, -0.11786840111017227, ...
def _ validate _ features ( self, values ) : return [ feature. return _ type ( value ) for feature, value in zip ( self. feature, values ) ]
[ -0.8747715353965759, -0.511404275894165, 0.32107508182525635, 0.9737470149993896, 1.0133929252624512, -0.20444774627685547, -0.41951099038124084, -0.015135858207941055, -0.3767101466655731, -0.29120293259620667, -0.1422184705734253, -0.28865379095077515, -0.41734778881073, 0.27799248695373...
def getdevice ( self, typeid, deviceid, expand = none ) : deviceurl = apiclient. deviceurl % ( self. host, typeid, deviceid ) r = requests. get ( deviceurl, auth = self. credentials, params = expand, verify = self. verify ) status = r. status _ code if status = = 200 : self. logger. debug ( " device was successfully re...
[ -1.224954605102539, -0.1644953489303589, 0.9798337817192078, 0.6198232769966125, -0.31208381056785583, -0.41223013401031494, -0.11978393793106079, -0.6154999136924744, 0.35228854417800903, 0.12157580256462097, 0.6281178593635559, 1.3433573246002197, -1.5482027530670166, -0.2227929234504699...
def wkt ( self ) : if len ( self. shapes ) = = 0 : return " " elif len ( self. shapes ) = = 1 : return self. shapes [ 0 ]. wkt else : return " multipolygon ( \ n % s \ n ) " % ( ", \ n ". join ( map ( lambda shape : " \ t " + shape. wkt. replace ( " polygon ", " " ), self. shapes ) ) )
[ 0.4354150891304016, -0.6888172030448914, 0.7294915914535522, -0.7624351382255554, -0.16329191625118256, -0.03677022084593773, -0.3878984749317169, 0.06470464915037155, 0.7586492896080017, -0.08264325559139252, -0.04291193187236786, 0.027305688709020615, 0.5086992383003235, 0.05226990580558...
def test _ regrow _ fodder _ savannah ( self ) : self. s. fodder _ in _ cell = 20 self. s. regrow _ fodder ( ) assert self. s. fodder _ in _ cell = = 104
[ -0.3955366015434265, 1.2826358079910278, 0.425254225730896, 0.0607169009745121, 0.9832466840744019, -0.9647508859634399, 0.42573675513267517, 0.025573506951332092, 0.38661471009254456, -0.5264739990234375, -0.7142844200134277, 0.34636321663856506, 0.2889775037765503, 0.5168430209159851, ...
def test _ get _ cve _ by _ count _ only _ true ( ) : res = requests. get ( f'{ env. awg _ base _ url } { cve _ url } / ', headers = utils. base _ headers, params = {'count _ only': 1 } ) assert len ( json. loads ( res. content. decode ( ) ) ) = = 1 # only count is returned assert json. loads ( res. content. decode ( )...
[ 0.12257726490497589, 0.08146044611930847, 0.5031481981277466, 0.5757227540016174, 1.0593304634094238, 0.23090523481369019, -0.4922748804092407, 0.866309642791748, -0.0173707976937294, -0.19067436456680298, 0.10981068760156631, 0.1375085711479187, 0.05347087234258652, 0.033382490277290344, ...
def _ reduce _ alignments ( y, x, ship _ sets, ship _ alignments ) : # if is first element to add to ship _ sets, add it and skip checking against itself. if len ( ship _ sets ) = = 0 : ship _ sets [ ( y, x ) ] = ship _ alignments return is _ subset = false # compare new alignments to existing ones. for coord, valid _ ...
[ -0.18011337518692017, 0.11167901754379272, 0.8883978128433228, -0.41679054498672485, -0.8115313649177551, 0.29654547572135925, 0.5176267027854919, -0.12153134495019913, 0.574901282787323, 0.40618619322776794, 0.8108248710632324, 0.661860466003418, 0.33861055970191956, -0.8382889032363892, ...
def test _ fodder _ in _ cell _ callable ( self ) : self. cell. fodder _ in _ cell
[ -0.3097793757915497, 0.7232035398483276, 0.42008543014526367, 0.5180884599685669, 0.1113843247294426, -0.5436697602272034, 0.97341388463974, -0.35398998856544495, -0.21001076698303223, -0.4192329943180084, -0.2886793613433838, 0.2037210464477539, -0.17267802357673645, 0.9892750978469849, ...
def _ getch _ linux ( prompt ) : print ( prompt, end = " " ) sys. stdout. flush ( ) fd = sys. stdin. fileno ( ) old = termios. tcgetattr ( fd ) new = termios. tcgetattr ( fd ) new [ 3 ] = new [ 3 ] & ~ termios. icanon & ~ termios. echo new [ 6 ] [ termios. vmin ] = 1 new [ 6 ] [ termios. vtime ] = 0 termios. tcsetattr ...
[ 0.2386309951543808, -0.41991081833839417, 0.6643058657646179, 0.021329686045646667, -0.8473072648048401, -0.014589197002351284, -0.21163566410541534, -0.7464721202850342, -0.3187924921512604, -0.39889034628868103, 0.16196401417255402, 0.634772002696991, -0.03548773378133774, -1.00586926937...
def sliding _ window ( image, windowsize, horizontalstride = 4, verticalstride = 4 ) : for y in xrange ( 0, image. shape [ 0 ], verticalstride ) : for x in xrange ( 0, image. shape [ 1 ], horizontalstride ) : yield ( x, y, image [ y : y + windowsize [ 1 ], x : x + windowsize [ 0 ] ] )
[ -0.022464869543910027, -0.1519685834646225, 0.5143486857414246, 0.5446764230728149, -0.5708515048027039, -0.2551997900009155, 0.11787751317024231, -0.4044077396392822, -0.19659094512462616, 0.20209616422653198, -0.4988458454608917, 0.45967093110084534, -0.2640688419342041, 0.50415760278701...
def task _ 5 _ 2 _ 4 ( ) : # todo task 5. 2. 4 : your code goes here sim = simulation ( ) sim. sim _ param. s = 10000 tic _ sys _ util = timeindependentcounter ( ) i = 1 pyplot. subplots _ adjust ( hspace = 0. 6 ) for rho in [. 5,. 9 ] : sim. sim _ param. rho = rho sim. reset ( ) for alpha in [. 1,. 05 ] : for sim _ ti...
[ 0.48153236508369446, 0.2469634860754013, 0.8899852633476257, 0.8137435913085938, 0.10850886255502701, 0.4152776002883911, 1.2974001169204712, -0.44773992896080017, -0.4189048111438751, 1.0424094200134277, -0.6277686357498169, 0.8835269212722778, 0.015460855327546597, 0.8365755081176758, ...
def print _ build _ errors _ and _ exit ( build _ errors : dict [ str, list [ docbuilderror ] ], spelling _ errors : dict [ str, list [ spellingerror ] ], ) - > none : if build _ errors or spelling _ errors : if build _ errors : display _ errors _ summary ( build _ errors ) console. print ( ) if spelling _ errors : dis...
[ -0.8567909002304077, -0.5287355184555054, 0.2733885645866394, 0.46592170000076294, 0.6319089531898499, 1.2608788013458252, 0.24017333984375, 0.3054403066635132, 0.3959839642047882, 0.2951415479183197, 0.26648369431495667, 0.8458335399627686, -0.12495861947536469, 0.462523877620697, 1.144...
def sandboxed _ install _ run ( virtualenv, script _ runner ) : venv _ pythonpath = glob. glob ( os. path. join ( virtualenv. virtualenv, " lib ", " python * ", " site - packages " ) ) [ 0 ] class statuswrapper : def _ _ init _ _ ( self, stdout = none, stderr = none, success = none ) - > none : self. stdout = stdout se...
[ -0.02672717161476612, -0.8269306421279907, 0.6511003971099854, 0.2975464165210724, -0.4478244185447693, 0.03543234243988991, 0.4828682243824005, 0.028870781883597374, 1.4822704792022705, 0.6118608713150024, -0.2778084874153137, 0.6319697499275208, -0.01777254417538643, 0.6916124820709229, ...
def create _ superuser ( self, email, password, * * extra _ fields ) : extra _ fields. setdefault ('is _ staff ', true ) extra _ fields. setdefault ('is _ superuser ', true ) extra _ fields. setdefault ('is _ validated ', true ) if extra _ fields. get ('is _ staff') is not true : raise valueerror ('superuser must have ...
[ 0.2315082997083664, 1.2209017276763916, 0.6824883818626404, 0.7329623103141785, 0.4216907024383545, 0.5824920535087585, -0.5489802360534668, 0.5687165260314941, 0.19227059185504913, -0.36891546845436096, -0.8645654320716858, 0.45463865995407104, -0.23373906314373016, -0.5831742882728577, ...
def snap ( g1, g2, tolerance ) : return ( geom _ factory ( lgeos. methods ['snap'] ( g1. _ geom, g2. _ geom, tolerance ) ) )
[ 0.26045456528663635, -0.32515332102775574, 0.36812591552734375, -0.0711875930428505, -1.1978894472122192, 0.3802042007446289, -1.4090685844421387, -1.5010720491409302, -1.0889140367507935, 0.4937744140625, 0.15660981833934784, 0.8435318470001221, 1.0739222764968872, -1.8539634943008423, ...
def compose _ image _ meta ( image _ id, original _ image _ shape, image _ shape, window, scale ) : meta = np. array ( [ image _ id ] + # size = 1 list ( original _ image _ shape ) + # size = 3 list ( image _ shape ) + # size = 3 list ( window ) + # size = 4 ( y1, x1, y2, x2 ) in image cooredinates [ scale ] # size = 1...
[ -0.3239381015300751, -0.9943810701370239, 0.5122179388999939, 0.04359978437423706, -0.13189321756362915, -0.32812100648880005, -0.1773442029953003, 0.13215045630931854, -0.7540445327758789, 1.4888134002685547, 0.32455480098724365, 1.0331530570983887, 0.5416191816329956, 0.33586743474006653...
def on _ response ( * args ) : print'server _ message ', args
[ 0.8600422739982605, -0.8459217548370361, 0.3028774857521057, 0.03945964202284813, 0.9665534496307373, -0.21239478886127472, 0.14974269270896912, -0.7057782411575317, -0.5866333246231079, -0.3683927059173584, -0.5656799077987671, 0.48191872239112854, -0.7409418225288391, 0.3661094605922699,...
def post _ search ( user _ id, choice, orderedarray ) : # check if the user is privileged or not cursor. execute ('''select privileged. uid from users, privileged where privileged. uid =?'' ', ( user _ id, ) ) conn. commit ( ) priv _ user = cursor. fetchall ( ) if priv _ user = = [ ] : is _ priv = false else : is _ pri...
[ 0.30427396297454834, -0.41293737292289734, 0.8266175389289856, 1.1283239126205444, 0.09754890203475952, 0.4576758146286011, 0.1950332075357437, -0.6918244957923889, 0.34912389516830444, -0.1513221561908722, -0.01306114625185728, 0.25612470507621765, -0.6330232620239258, 0.17565031349658966...
def crypt _ path _ name ( self, path _ item _ name : str ) - > optional [ str ] : b64 _ path _ bytes = bytes ( path _ item _ name, " utf - 8 " ) path _ bytes = none try : path _ bytes = urlsafe _ b64decode ( b64 _ path _ bytes ) except binascii. error : return none assert ( path _ bytes is not none ) plaintext _ bytes ...
[ -0.2782607972621918, -0.25847747921943665, 0.6064175367355347, 1.027248501777649, -0.649939239025116, -0.426685094833374, -0.4342440664768219, -0.7184630632400513, 0.5981254577636719, 1.3514506816864014, -0.43543386459350586, -0.699543833732605, -1.033463954925537, -1.1441468000411987, -...
def render ( self, workbook, *, title ) : def add _ format ( fmt ) : return self. add _ format ( workbook, fmt ) escaped _ title = self. invalid _ sheet _ name _ expr. sub ( " ", title ) worksheet = workbook. add _ worksheet ( escaped _ title ) worksheet. set _ paper ( self. paper ) if self. orientation = = self. orien...
[ -0.7603785395622253, 0.5752215385437012, 0.7046480774879456, 0.3574632406234741, -0.06212740018963814, 0.8225868940353394, -0.5166732668876648, -0.27519041299819946, 0.26261818408966064, -0.32308879494667053, 0.2586350739002228, -0.16963104903697968, -0.7325331568717957, 0.4138962328433990...
def check _ fleet _ edges ( aliens, ai _ settings ) : for alien in aliens. sprites ( ) : if alien. check _ edges ( ) : change _ fleet _ direction ( aliens, ai _ settings ) break
[ -0.5499165654182434, 0.12597428262233734, 0.42979755997657776, 0.38277989625930786, 0.6759770512580872, -0.6431111097335815, 0.07588515430688858, 0.10715761035680771, 0.10486496984958649, 0.7189998030662537, 0.3830757141113281, -0.1450364887714386, 0.42851486802101135, 1.0877476930618286, ...
def updatedevicemanagementextensionpkg ( self, bundleid, dmedata ) : dmereq = apiclient. dmesinglerequest % ( self. host, bundleid ) r = requests. put ( dmereq, auth = self. credentials, data = json. dumps ( dmedata ), headers = {'content - type':'application / json'}, verify = self. verify ) status = r. status _ code ...
[ -2.1040573120117188, 0.183911994099617, 0.44377923011779785, 0.29996705055236816, -1.0398565530776978, 0.4043857753276825, -0.4467572867870331, -0.04311075434088707, 0.8324708342552185, 0.944266140460968, -0.4359819293022156, 0.6215603947639465, -1.105892539024353, -0.10852149873971939, ...
def reviewspellcurrentline ( self, inputevent ) : self. _ reviewcurrentline ( inputevent, 2 ) return true
[ -0.6145222783088684, -1.1956902742385864, 0.2407466620206833, -0.19564421474933624, -0.7340410947799683, 1.6911084651947021, -0.1997496336698532, -0.26467564702033997, -0.4185841381549835, 0.06601642817258835, -0.2173898071050644, 0.437205970287323, -0.5277372598648071, -0.1889491528272628...
def mkdir ( path ) : if not os. path. exists ( path ) : os. makedirs ( path ) return path
[ 0.330565869808197, 0.23818466067314148, 0.37277957797050476, -0.3013772666454315, -0.4090571701526642, 1.27569580078125, 0.7121129631996155, -1.1072666645050049, 0.4151262044906616, -1.1851085424423218, 0.404291033744812, -0.8872697949409485, 0.23623298108577728, -0.24988031387329102, 0....
def log _ deriv ( self, x0s ) : return np. array ( [ self. _ local _ params ( x0 ) [ 0 ] for x0 in x0s ] )
[ -0.33435648679733276, -0.6887155771255493, 0.2952428460121155, -0.5082542300224304, 0.48159486055374146, -0.06489568948745728, -0.8749263882637024, -0.039771176874637604, -0.5864783525466919, 0.21305713057518005, -0.25646141171455383, 0.9437607526779175, 0.18708288669586182, 0.644827008247...
def getsmalllibor ( self, x = [ ], datelist = [ ], simnumber = 1 ) : # calculate indexes # get libor simulated curves for specific tenors or for all tenors if no datelist is provided # calculate indexes if ( len ( self. libor ) = = 0 ) : self. getlibor ( ) self. smalllibor = self. libor. loc [ datelist ] return pd. dat...
[ -0.24083071947097778, 0.6825380325317383, 0.3768463134765625, 0.15575957298278809, -0.7802484631538391, 0.5161257386207581, -0.7378979921340942, -0.08800992369651794, 0.7601240277290344, -0.461704283952713, -0.5964229702949524, 0.4191440939903259, -0.7327405214309692, -1.0302250385284424, ...
def initialize _ states _ basic ( p _ array, num _ nodes, init _ mode, init _ data, i _ healthy _ state, i _ infective _ state ) : # starts by seting all p to zero, regardless of the mode p _ array [ : ] = 0. # initialization modes elif ladder if init _ mode in [ " fixed _ frac ", " frac ", " p ", " fixed _ p " ] : # i...
[ -0.23081395030021667, -0.6147170662879944, 0.8615922927856445, 0.05221577733755112, 0.46458256244659424, -0.041183438152074814, 0.32036030292510986, -0.03935617953538895, -0.2458801120519638, 0.23322467505931854, -0.28316596150398254, 0.19753839075565338, -0.2264838069677353, -0.2558712661...
def _ update _ workspace ( self, workspace, pool, verbose = false ) : if verbose : print ( " database : update for \ " % s \ " " % workspace. name ) filesystem _ jobids = workspace. valid _ jobids self. _ fsjid. update ( filesystem _ jobids ) if verbose > 1 : print ('database : update found these jobids in workdir ', f...
[ -1.1739704608917236, -0.572888970375061, 0.3293306529521942, -0.8328109383583069, 0.0442270003259182, -0.5074850916862488, -0.018674300983548164, -0.23902350664138794, -0.12470293790102005, 0.2990427017211914, 0.0147859463468194, -0.006126390304416418, -1.153485894203186, 0.940851986408233...
def test _ fail _ addresses _ wrong _ type ( self ) : self. assertfiltererrors ( {'addresses': address ( self. trytes1 ), }, {'addresses': [ f. type. code _ wrong _ type ], }, )
[ -0.5183855295181274, 0.5338771343231201, 0.2980287969112396, -0.16280151903629303, 0.5873270630836487, 0.12662272155284882, 0.08959390968084335, -0.8601906895637512, 0.2552117705345154, 0.7271280884742737, -0.11509320139884949, 1.010828971862793, -0.03089599683880806, 1.1071536540985107, ...
def initialize _ w ( self ) : prior _ means = [ ] prior _ log _ vars = [ ] post _ means = [ ] post _ log _ vars = [ ] with tf. name _ scope ( " encoder _ layer _ weights " ) : for i in range ( 1, self. length _ encoder ) : d _ in, d _ out = ( self. n _ encoder [ i - 1 ], self. n _ encoder [ i ] ) print ( d _ in, d _ ou...
[ -0.3627792298793793, 0.08803341537714005, 0.7097034454345703, -0.1794392317533493, 0.01764163188636303, -0.17932894825935364, 0.8173569440841675, -0.6192582845687866, -0.7976431846618652, -0.0022822865284979343, -0.5268979668617249, 0.8176144957542419, 0.2677161693572998, 1.361129403114318...
async def off ( ctx : bot. context ) : try : role _ db = await bot. db. get ( partyhard _ roles, guild _ id = ctx. guild. id ) except partyhard _ roles. doesnotexist : return role = bot. utils. get ( ctx. guild. roles, id = role _ db. role _ id ) if role not in ctx. author. roles : return await ctx. author. remove _ ro...
[ 0.6272138357162476, 0.1490563601255417, 0.7551294565200806, -0.2894851267337799, 0.4814843237400055, 0.5479615330696106, -0.833579421043396, 1.0342328548431396, 0.10607990622520447, 0.25389012694358826, 0.4729970097541809, 0.43309736251831055, -1.319252371788025, 0.21829859912395477, 0.6...
def _ _ str _ _ ( self ) : return self. raw
[ -0.7528669834136963, -1.5099987983703613, 0.6702873706817627, -1.413440227508545, -1.0174893140792847, 0.9325428009033203, -0.2371186912059784, -0.5711850523948669, 0.5667788982391357, -0.848119854927063, 0.36225542426109314, 0.9397090077400208, 0.8690137267112732, -0.8407193422317505, -...
def parse ( self ) : with open ( self. filename,'rb') as arionfile : self. tree = et. parse ( arionfile ) return super ( arionbankiparser, self ). parse ( )
[ 0.25117671489715576, -0.544544517993927, 0.34025901556015015, -0.11805471032857895, 0.06260024011135101, 0.7678250074386597, -0.3050096929073334, 1.138197660446167, 0.08447476476430893, -0.3350752294063568, 0.33603528141975403, -1.2112852334976196, -1.0562902688980103, -0.8920775055885315,...
def ascon _ process _ associated _ data ( s, b, rate, associateddata ) : if len ( associateddata ) > 0 : a _ zeros = rate - ( len ( associateddata ) % rate ) - 1 a _ padding = to _ bytes ( [ 0x80 ] + [ 0 for i in range ( a _ zeros ) ] ) a _ padded = associateddata + a _ padding for block in range ( 0, len ( a _ padded ...
[ 0.3819078207015991, 0.07721604406833649, 0.5042682886123657, -0.4731728136539459, -0.15850558876991272, -0.6157426238059998, 0.3174607753753662, -0.23624883592128754, 0.6249532699584961, 0.43095463514328003, 0.30202338099479675, 0.3602811098098755, 0.04841270670294762, -0.05179240554571152...
def test _ invalid _ user _ message _ add ( self ) : with self. client as c : with c. session _ transaction ( ) as session : session [ curr _ user _ key ] = 0xdeadbeef response = c. post ( " / messages / new ", data = { " text " : " hello " }, follow _ redirects = true ) self. assertequal ( response. status _ code, 200...
[ -0.06794595718383789, 0.07945726811885834, 0.5901631712913513, 0.35055068135261536, 0.11858560144901276, 0.9838632345199585, -0.035874586552381516, -0.6604346036911011, 0.1971973329782486, -0.9194222688674927, 0.29760655760765076, 0.11628296971321106, -0.32540860772132874, 0.67482805252075...
def repeat _ pattern ( self ) : if self. _ pattern. get ( " freq _ subday _ interval ", 0 ) : _ subday _ interval = self. _ pattern [ " freq _ subday _ interval " ] repeat _ every = " { 0 } : 0 { 1 } ". format ( int ( _ subday _ interval / 3600 ), int ( ( ( _ subday _ interval / 60 ) - ( ( _ subday _ interval / 3600 ) ...
[ -1.2877033948898315, 0.11654545366764069, 0.8297566771507263, -0.8999801874160767, -0.12798167765140533, 0.34224867820739746, -0.08416607975959778, -0.23197755217552185, -0.6694227457046509, 0.8275995850563049, -0.99090576171875, -0.1486145704984665, 0.2286129891872406, -0.6095658540725708...
def test _ atomic _ language _ max _ length _ 2 _ nistxml _ sv _ iv _ atomic _ language _ max _ length _ 3 _ 1 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / language / schema + instance / nistschema - sv - iv - atomic - language - maxlength - 3. xsd ", instance = " nistda...
[ 0.2692805230617523, 0.01935867965221405, 0.4279527962207794, 0.9653552174568176, -0.4944065511226654, 0.7198343873023987, -0.7881850004196167, 0.3744427263736725, 0.665195643901825, 1.0899242162704468, -0.43970760703086853, 0.15895861387252808, 0.26054567098617554, -0.4934176206588745, 0...
def cube ( x, y, z, s = 1 ) : mcube = [ ( ( x, y, z ), ( x + s, y, z ) ), ( ( x, y, z ), ( x, y + s, z ) ), ( ( x, y, z ), ( x, y, z + s ) ), ( ( x, y, z + s ), ( x + s, y, z + s ) ), ( ( x, y, z + s ), ( x, y + s, z + s ) ), ( ( x + s, y, z + s ), ( x + s, y, z ) ), ( ( x + s, y, z + s ), ( x + s, y + s, z + s ) ), ( ...
[ -0.5299966335296631, -0.20452526211738586, 1.1459603309631348, -0.20300321280956268, -0.8280322551727295, -0.29156967997550964, 0.36143091320991516, 0.10794103145599365, 0.5071940422058105, 0.235777348279953, -1.1522157192230225, -0.2722785770893097, -0.27683576941490173, -0.45274686813354...
async def test _ setup _ entry ( opp : openpeerpower ) : id = str ( uuid4 ( ) ) config _ entry = mockconfigentry ( domain = twinkly _ domain, data = { conf _ entry _ host : test _ host, conf _ entry _ id : id, conf _ entry _ name : test _ name _ original, conf _ entry _ model : test _ model, }, entry _ id = id, ) def s...
[ -0.0669083520770073, 0.23245768249034882, 0.35446467995643616, -0.8206933736801147, 0.8398610353469849, -0.3944685459136963, 0.6366506814956665, 0.389154851436615, 0.15456129610538483, 0.5146655440330505, -0.34225666522979736, 0.05592675134539604, 0.5487233996391296, 0.4120398163795471, ...
def _ generate _ kernel _ args ( ops, axes _ mapping, dims, ctx ) : # list arguments to kernel args = [ " unsigned int shapea " ] arg _ desc = " i " params = [ axes _ mapping [ 0 ] [ 4 ] ] if dims = = 2 : args. append ( " unsigned int shapeb " ) arg _ desc = arg _ desc + " i " params. append ( axes _ mapping [ 1 ] [ 4 ...
[ -0.14828255772590637, 0.5350985527038574, 1.0266225337982178, -0.4537978768348694, 0.4018557071685791, 0.04797561466693878, 0.7141159176826477, 0.16786077618598938, -0.4597201943397522, 0.7918264269828796, 0.1126200333237648, -0.10680463165044785, 0.5749298930168152, 0.6308254599571228, ...
def _ recalc _ fp ( self ) : self. _ fp30bit = float ( ( " - " if self. _ negative else " " ) + str ( self. _ mantissa [ 0 ] ) + ". " + " ". join ( map ( str, self. _ mantissa [ 1 : ] ) ) + " e " + str ( self. _ exponent ) )
[ 0.35666343569755554, -0.6904165148735046, 0.5704020857810974, -1.0441912412643433, -0.42706945538520813, -0.06671666353940964, -0.47453954815864563, 0.11658725142478943, -0.04146735742688179, 0.21988308429718018, -0.0010863817296922207, 0.47708776593208313, -0.016940290108323097, 0.3388881...
def main ( self ) : mswitch. subscribe ( self. iq, self. isq ) self. tick ( ) # self. mainloop ( )
[ 0.776262640953064, -0.17231780290603638, 0.35436931252479553, 0.8628526926040649, -0.10401958972215652, 0.5827596187591553, -0.24268163740634918, -0.11736095696687698, 0.48077622056007385, -0.7501861453056335, 0.17867696285247803, 0.3556993901729584, -0.5149765610694885, 0.5014470815658569...
def element _ clickable ( self, element : str ) - > none : wdw ( self. driver, 5 ). until ( ec. element _ to _ be _ clickable ( ( by. xpath, element ) ) ). click ( )
[ -0.20498284697532654, 0.2630924582481384, 0.42813581228256226, 0.48755744099617004, 0.1369743049144745, 0.0992119237780571, 0.8530600666999817, 0.36236754059791565, -0.608864963054657, 0.5722924470901489, -0.14598838984966278, 0.17467880249023438, -0.3299587666988373, -0.2999952733516693, ...
def _ move _ mesh _ to _ cluster ( self, event : str, gradient = false, hpc _ cluster = none ) : if event is none : if gradient : self. print ( " moving example gradient to cluster ", emoji _ alias = " : package : " ) self. move _ gradient _ to _ cluster ( hpc _ cluster ) else : # this happens when we want to move the ...
[ 0.40705233812332153, 0.4211060404777527, 0.7362380027770996, 0.2838520109653473, 0.8424836993217468, 0.8858940601348877, 0.5282106995582581, -0.21471232175827026, -0.33185774087905884, 0.2876850366592407, -0.581773579120636, 0.9750590920448303, -0.5389481782913208, 0.48217421770095825, 0...
def get _ ext ( self, format = none, * * kwargs ) : try : format = format or self. default _ params ['format'] return ". % s " % format. lower ( ) except keyerror : pass
[ 0.2513233721256256, -0.29738849401474, 0.4664009213447571, 0.8864112496376038, 0.31262391805648804, 0.04211243987083435, -1.033935308456421, -0.5690573453903198, 0.46294790506362915, 0.058329444378614426, 0.7445623874664307, 0.37494367361068726, -0.3292507529258728, 1.138465404510498, -0...
def step ( self, states, actions, rewards, next _ states, dones ) : pass
[ -0.13644304871559143, 0.10601818561553955, 0.04669792577624321, 0.23239460587501526, 1.0665338039398193, -0.21186742186546326, -0.6395834684371948, 0.2122233808040619, 0.24908360838890076, -0.48000890016555786, -0.4852103292942047, -0.5769951939582825, 0.4957357347011566, -0.42071875929832...
def test _ atomic _ any _ uri _ min _ length _ 4 _ nistxml _ sv _ iv _ atomic _ any _ uri _ min _ length _ 5 _ 4 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / anyuri / schema + instance / nistschema - sv - iv - atomic - anyuri - minlength - 5. xsd ", instance = " nistdata...
[ 0.18634480237960815, -0.5763809084892273, 0.39198723435401917, 0.501033365726471, -0.4517849087715149, -0.4713539481163025, -0.052973438054323196, -0.8511589169502258, 0.1269344538450241, -0.3210185170173645, -0.11668268591165543, -0.23231248557567596, -1.1236673593521118, 0.24476593732833...
def status _ message ( self ) - > pulumi. output [ str ] : return pulumi. get ( self, " status _ message " )
[ 0.6210805773735046, -0.25149446725845337, 0.07187771797180176, 0.3223161995410919, 0.6410938501358032, 0.39635130763053894, -0.3703669309616089, 0.3545481860637665, -0.17179708182811737, -0.11296280473470688, 0.3906325697898865, 0.7697850465774536, 0.10342027246952057, -0.3915301561355591,...
def _ read _ raw ( self ) : # request the data, wait, and read the data # 0x03 = read command # 0x00 = read starting at byte 0 # 0x04 = read 4 bytes self. pi. i2c _ write _ device ( self. handle, [ 0x03, 0x00, 0x04 ] ) time. sleep ( 0. 1 ) # even though 4 bytes were requested, 8 are returned, only get the data # byte 0...
[ -0.48413997888565063, -0.1165301725268364, 0.8503577709197998, -0.05676162242889404, 0.07274063676595688, -0.26755785942077637, -0.4413924813270569, -0.7923253178596497, -0.34943029284477234, -1.2745592594146729, -0.00023062936088535935, 0.04008818790316582, -0.4979650676250458, -0.3469440...
def dead ( self ) - > bool : return not self. alive
[ -1.0963340997695923, -0.9149690866470337, 0.6480377912521362, 0.5391224026679993, 0.40836694836616516, 2.033757209777832, -0.8652840852737427, -0.10878070443868637, 0.060976359993219376, -0.39849618077278137, 0.018804915249347687, -0.5828658938407898, -1.0660223960876465, -0.59435248374938...
def close ( self ) : return self. _ _ swift. close ( )
[ 0.11580315977334976, -0.3525213599205017, 0.5999663472175598, -0.4920467138290405, -0.6391997337341309, 1.002929925918579, 0.12858885526657104, -0.3888426423072815, -0.8978753089904785, -1.4490740299224854, 0.914798378944397, 0.10705463588237762, -1.1590169668197632, 0.8214621543884277, ...
def instrument _ training ( net, training _ set, epochs : int = num _ epochs, learning _ rate : float = learning _ rate, momentum : float = momentum, set _ epoch : callable [ [ int ], none ] = lambda n : none, stats _ collector : optional [ statscollector ] = none, ) - > list [ epochmeasurement ] : def time _ iteration...
[ -0.42850977182388306, 0.4319421648979187, 0.9253247976303101, -0.3019135594367981, 0.8026933073997498, -0.109940305352211, 0.22855694591999054, -0.6424173712730408, -0.6091902256011963, 0.35818973183631897, 0.12247302383184433, -0.2677161693572998, 0.7353441715240479, 0.6569986343383789, ...
def hasmetadata ( self, block, metadatakey ) : if block. getworld ( ) = = self. owningworld : return super ( blockmetadatastore, self ). hasmetadata ( block, metadatakey ) else : raise illegalargumentexception ( " block does not belong to world " + self. owningworld. _ _ name _ _ )
[ 0.4041565954685211, 0.021465154364705086, 0.5216251611709595, 0.5429148077964783, -0.42617473006248474, 0.8829261660575867, -0.3710138201713562, -0.49635735154151917, -0.30480891466140747, 0.787347674369812, 0.3175554573535919, 0.7076517343521118, -0.4305380880832672, 1.4022454023361206, ...
def one _ time ( self, pattern _ dict ) : if isinstance ( pattern _ dict, bool ) : pattern _ dict = { } pattern _ dict ['freq _ type'] ='one _ time'schedule _ pattern = schedulepattern ( self. _ pattern ) self. _ pattern = schedule _ pattern. create _ schedule _ pattern ( pattern _ dict ) self. _ modify _ task _ proper...
[ -0.7898244857788086, 0.987610936164856, 0.4826638400554657, -0.3989357650279999, 0.46070849895477295, 0.175962895154953, 0.6119453310966492, 0.9068214893341064, 0.7971744537353516, 0.2817831039428711, -0.6395120620727539, 0.00104507093783468, -0.18712647259235382, 0.20030783116817474, 0....
def main ( input _ file, output _ file ) : # import modules import csv, os from openpyxl import workbook # open text file with csv reader. in _ fl _ obj = open ( input _ file ) csv _ obj = csv. reader ( in _ fl _ obj ) # create new excel workbook object. wb = workbook ( ) ws = wb. active ws. title = os. path. basename ...
[ 0.5337287187576294, -0.6904487013816833, 0.43847066164016724, 0.9595724940299988, -0.248496875166893, 0.5143076181411743, 0.8591234087944031, 0.866404116153717, -0.4395236372947693, -0.010072651319205761, 0.17924775183200836, 0.05231364071369171, 0.10485614091157913, -0.05131576582789421, ...
async def test _ socks5 _ request ( ) : network _ backend = httpcore. asyncmockbackend ( [ # the initial socks connect # v5 noauth b " \ x05 \ x00 ", # v5 suc rsv ip4 127. 0. 0. 1 : 80 b " \ x05 \ x00 \ x00 \ x01 \ xff \ x00 \ x00 \ x01 \ x00 \ x50 ", # the actual response from the remote server b " http / 1. 1 200 ok ...
[ -0.31251224875450134, 0.020976413041353226, 0.6569859981536865, -0.5522564053535461, 0.6914917230606079, -0.13796360790729523, 0.4873153269290924, -0.7936305403709412, -0.7381432056427002, -0.32110464572906494, -0.15328945219516754, 0.34912240505218506, -0.6312280297279358, -0.164013430476...
def cn _ scalevariance ( self, variance _ ratio ) : depr ('scalevariance ', 1. 1,'obj = obj * variance _ ratio') new _ obj = self. copy ( ). withscaledvariance ( variance _ ratio ) self. _ profile = new _ obj. _ profile self. _ profile _ for _ stored = none # reset the stored profile as it is no longer up - to - date s...
[ 0.24769514799118042, -0.5115067958831787, 0.8064131736755371, 0.6662716269493103, -0.3025771975517273, 0.10152994096279144, 0.37251269817352295, -0.725307285785675, 0.015804339200258255, 0.21958976984024048, -1.27590811252594, 0.13008928298950195, -0.6437985897064209, -0.023877505213022232...
def rotation ( omega, th ) : skomega = skew ( omega ) r = np. eye ( 3 ) + np. sin ( th ) * skomega + ( 1 - np. cos ( th ) ) * skomega. dot ( skomega ) return r
[ 0.16379384696483612, 0.28738972544670105, 0.36675211787223816, -0.9240909218788147, 0.5366607308387756, -0.48613011837005615, -0.04422508180141449, 0.3995618224143982, 1.1174886226654053, 1.2075562477111816, -0.4864678382873535, 0.4360828697681427, -0.34654372930526733, -0.7159662842750549...
def set _ contrast ( self, contrast ) : self. _ write _ command ( [ lcdbackpack. set _ contrast, contrast ] )
[ 0.008057931438088417, -0.00647823978215456, 0.5108218193054199, 0.3469369113445282, 1.2025667428970337, 0.4916902184486389, 0.6903029084205627, -0.2589700520038605, 0.9770843982696533, -0.7180938720703125, -0.6540719270706177, 0.31820404529571533, -1.4529885053634644, 0.6308335661888123, ...
def append _ ( self, path : str, payload : dict, rev : int ) - > dict : return self. _ http. patch ( path, payload, rev = rev )
[ -0.24325434863567352, -0.09363988786935806, 0.6465882658958435, -1.1383001804351807, -1.1188946962356567, 0.4362727999687195, -1.0162467956542969, 0.13134372234344482, -0.5616280436515808, -0.3708532452583313, 0.5203084945678711, 0.15141873061656952, -0.17149201035499573, -0.87893933057785...
def _ _ init _ _ ( self, t, trj, ats, molno ) : self. timestep = t self. ats = ats self. nclusts = molno self. clusterids = np. zeros ( molno ) ( self. pos, self. box ) = self. readgro ( trj ) self. rng = none if len ( self. pos )! = 3 * molno * ats : raise runtimeerror ( " incorrect number of atoms or molecules " ) # ...
[ -0.005339209921658039, -0.10815046727657318, 0.45285719633102417, -0.5010294318199158, 0.30425184965133667, -0.23457404971122742, -0.7694608569145203, 0.1582963913679123, -0.4651733338832855, 0.1547074168920517, 0.25198736786842346, -0.7658758163452148, 0.8110154271125793, -0.2876553535461...
def scheduled _ charging _ mode ( self ) - > str : return self. _ vehicle _ data. get ( " charge _ state ", { } ). get ( " scheduled _ charging _ mode " )
[ -0.5211079120635986, -0.28162792325019836, 0.4676022231578827, 0.45530083775520325, 0.42281559109687805, 1.1074262857437134, -0.8957271575927734, 0.06039246544241905, -0.14263154566287994, -0.2981683909893036, -0.20640598237514496, -0.41894206404685974, 0.5658260583877563, -0.4685672521591...
def run ( self, * * kwargs : any ) - > none : note _ id = 1 title = " undefined " for node in self. document. traverse ( ) : if isinstance ( node, nodes. section ) : if node [ " names " ] : # pragma : nocover title = nodes. make _ id ( node [ " names " ] [ 0 ] ) # add automatic ids only to admonition nodes that are not...
[ 0.003948674071580172, 0.1522514522075653, 0.584089457988739, -0.8835116028785706, 0.7608233690261841, 0.2816614806652069, 0.017823437228798866, -0.48584848642349243, -0.33612847328186035, 0.6103580594062805, -0.018364090472459793, 0.6761334538459778, 0.06480606645345688, 1.093481421470642,...
def generatemap ( ) : scenariopath = " / mydro _ ecmwf / mhydro _ ecmwf _ 20180910 / scenario of mhydro _ ecmwf _ 20180910 " outputtimeseriesname = " vierwaldstaettersee - 19186. 5 - hpoint - water level " inputrasterpath = " dhm100m _ viwa " outputrastername = " outputmap " # get latest simulation scmgr = app. modules...
[ -0.3740469515323639, 0.006945430301129818, 0.7620336413383484, 0.655307948589325, -0.16012956202030182, 0.11253528296947479, 0.5926177501678467, 0.042000364512205124, -0.13799917697906494, 0.039809778332710266, 0.6672670841217041, -0.4824739992618561, 0.6081140637397766, 0.9344146251678467...
def boxplots _ all _ mse ( ) : # all _ overal _ min = [ ] best _ mae = [ ] last _ mae = [ ] best _ mse = [ ] last _ mse = [ ] for j, error _ method in enumerate ( ['absolute ','mean squared'] ) : all _ best = [ ] all _ last = [ ] t, x, y = open _ data ( ) cooling ='linear'filename ='sa _'+ cooling +'_'+ error _ method ...
[ 0.42415651679039, -0.17645038664340973, 0.8772634267807007, -0.2355106770992279, 0.03366602957248688, -0.1088583841919899, 0.3074372112751007, -0.4827442169189453, -0.26084187626838684, 0.3934766948223114, -0.2416173666715622, 0.7552807331085205, 0.7857671976089478, 0.5127092003822327, 0...
def inv _ line _ characteristic _ hashcode ( self, invoice _ line ) : return " % s - % s - % s - % s - % s " % ( invoice _ line ['account _ id'], invoice _ line. get ('tax _ line _ id ','false'), # thanh : group only for account, no group for product _ id # invoice _ line. get ('product _ id ','false'), false, # thanh ...
[ 0.6873270869255066, -0.9569607377052307, 0.39936885237693787, -0.14910002052783966, 0.5921449661254883, 0.7165366411209106, -0.534243643283844, 0.18872018158435822, -0.9035536050796509, 0.7032153010368347, 0.16356658935546875, 0.30655041337013245, -0.1787300556898117, -0.8047100901603699, ...
def test _ list _ integer _ min _ length _ 2 _ nistxml _ sv _ iv _ list _ integer _ min _ length _ 3 _ 4 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / list / integer / schema + instance / nistschema - sv - iv - list - integer - minlength - 3. xsd ", instance = " nistdata / list / ...
[ 0.007591720670461655, -0.5153868198394775, 0.3639988899230957, 0.27879655361175537, -0.25751325488090515, 0.13784106075763702, -0.855298638343811, -0.17805369198322296, 1.3693439960479736, 0.593919038772583, -0.8230842351913452, -0.09748341143131256, -0.8040196299552917, 0.3854401707649231...
def uni ( self ) : pairs = list ( self. end ) pairs. sort ( ) return link ( pairs [ 0 ] [ 0 ], pairs [ 0 ] [ 1 ], pairs [ 1 ] [ 0 ], pairs [ 1 ] [ 1 ] )
[ -0.48559287190437317, 0.16217884421348572, 0.671791136264801, 0.1248757466673851, 0.5209562182426453, 0.6394934058189392, 0.22380267083644867, 0.5248942375183105, 0.007983705960214138, -1.2766523361206055, -0.16143403947353363, 0.3890128433704376, -1.065688133239746, -1.3522363901138306, ...
def _ _ init _ _ ( self, coordinator : tolosaunaupdatecoordinator, entry : configentry ) - > none : super ( ). _ _ init _ _ ( coordinator, entry ) self. _ attr _ unique _ id = f " { entry. entry _ id } _ lamp _ next _ color "
[ 0.2962524890899658, 0.41611120104789734, 0.2804969847202301, -0.13420917093753815, -0.2486308366060257, -0.0007286587497219443, -0.10650814324617386, 0.2885235846042633, 0.23019182682037354, 0.24455733597278595, -0.3112817704677582, 0.260646253824234, 1.1592105627059937, 0.2090193480253219...
def door _ pr ( self ) - > int : return self. _ vehicle _ data. get ( " vehicle _ state ", { } ). get ( " pr " )
[ -0.41253697872161865, 0.4814302623271942, 0.40607312321662903, -0.29133152961730957, 0.3754142224788666, 0.032850347459316254, -0.4889756739139557, 0.6945975422859192, 0.3745504915714264, 0.4822002649307251, 0.31497541069984436, 0.17623409628868103, -1.2087023258209229, -0.2602431774139404...
def _ reset _ parameters ( self ) : for p in self. parameters ( ) : if p. dim ( ) > 1 : xavier _ uniform _ ( p )
[ -0.48067742586135864, 0.95361328125, 0.1650800257921219, 0.055716920644044876, 1.0891250371932983, -0.22317098081111908, 0.29572540521621704, 0.2632133364677429, -0.622570812702179, 1.1076022386550903, -0.19013988971710205, 1.2785329818725586, -0.7973158955574036, 0.2838200032711029, -1....
def command ( name, nargs = 0, complete = none, range = none, count = none, bang = false, register = false, sync = false, allow _ nested = false, eval = none ) : def dec ( f ) : f. _ nvim _ rpc _ method _ name ='command : { } '. format ( name ) f. _ nvim _ rpc _ sync = sync f. _ nvim _ bind = true f. _ nvim _ prefix _ ...
[ 0.07485054433345795, -0.01841832511126995, 1.0355814695358276, -0.4044819474220276, -0.5196459889411926, -0.8856440782546997, -0.12286604940891266, -0.23176148533821106, 0.43136030435562134, 0.12429404258728027, -0.10653015226125717, -0.4328587055206299, 0.09129772335290909, -0.08192207664...
def bbo _ download ( self, download = true ) : if download : self. download _ data ('bbo')
[ 0.9393787384033203, -0.2961096167564392, 0.41606810688972473, 0.5610929131507874, 0.0237173642963171, 0.24196135997772217, -0.05603308603167534, 0.28383734822273254, -0.06947792321443558, 0.2609694004058838, -0.1618831306695938, 0.2860868275165558, -0.32187315821647644, 0.1391790211200714,...
def test _ atomic _ any _ uri _ max _ length _ 4 _ nistxml _ sv _ iv _ atomic _ any _ uri _ max _ length _ 5 _ 2 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / anyuri / schema + instance / nistschema - sv - iv - atomic - anyuri - maxlength - 5. xsd ", instance = " nistdata...
[ 0.016286443918943405, -0.4106336832046509, 0.26342856884002686, 0.9008758664131165, -0.768968939781189, -0.41040700674057007, -0.23719774186611176, -0.40876221656799316, -0.32099443674087524, 0.06127196550369263, -0.24456584453582764, -0.2929132282733917, -0.4000365436077118, 0.50283944606...
def read _ credentials ( ) : path = os. path. expanduser ( " ~ /. astrotweet. json " ) f = open ( path,'r') creds = json. load ( f ) f. close ( ) return creds
[ -0.18172971904277802, -1.4878009557724, 0.5401859879493713, -0.9216414093971252, -0.4625265300273895, 0.6111578345298767, -0.718826413154602, -0.2839359641075134, -1.005767583847046, 0.803677499294281, 0.20736318826675415, 0.4710378348827362, 0.4787226617336273, -1.0673918724060059, 0.60...
def first _ symbolic _ object ( * objects : any ) - > symbolicexpression | none : for obj in objects : if isinstance ( obj, symbolicexpression ) : return obj return none
[ 0.6666951179504395, -0.14764347672462463, 0.5037713050842285, 0.5511903166770935, 0.4040192663669586, -0.6124866604804993, 1.1548449993133545, -0.34944823384284973, -0.5708286166191101, -0.08186586946249008, -0.31235480308532715, 0.5524292588233948, 0.12944220006465912, 0.3089334964752197,...
def name ( self ) - > optional [ pulumi. input [ str ] ] : return pulumi. get ( self, " name " )
[ 0.40567412972450256, -0.13324537873268127, 0.4592471122741699, 0.07128655910491943, 0.5618420243263245, 0.8966439366340637, 0.0582989864051342, -0.3534304201602936, 0.6611905097961426, 0.6750738024711609, 0.007086642552167177, 0.44384142756462097, 0.4012888967990875, -0.849596381187439, ...
def frequency ( self ) : return self. _ frequency
[ 0.05539482459425926, 0.019339073449373245, 0.13431717455387115, 0.5368322134017944, 0.3139432668685913, 0.1864617019891739, 0.6117797493934631, -0.100728340446949, 0.2811168134212494, -1.776984691619873, 0.16885536909103394, -0.07696539908647537, 0.08017056435346603, 0.032510221004486084, ...
def show _ tri _ plot ( im1, im2, im3 ) : fig = plt. figure ( ) f, ( ax1, ax2, ax3 ) = plt. subplots ( 3, 1, sharex ='col') ax1. imshow ( im1, cmap ='gray') ax2. imshow ( im2, cmap ='gray') ax3. imshow ( im3, cmap ='gray') plt. show ( )
[ 0.7393910884857178, 0.8315883278846741, 0.5385998487472534, -0.5925685167312622, -0.2622937560081482, 0.8907281756401062, 0.7476740479469299, 0.9079049825668335, -0.35964643955230713, 0.45530757308006287, 0.6414086818695068, 0.45603302121162415, 0.026343708857893944, -0.5978012681007385, ...
def communicate ( comm, open _ msg ) : _ = open _ msg # ignored logger. debug ( " comm'communicate'opened. " ) @ comm. on _ msg def handle _ msg ( msg ) : " " " handle message. " " " logger. debug ( " message received : % r ", msg ) data = msg ['content'] ['data'] event = data. get ('event ', none ) logger. debug ( " r...
[ -0.6868942975997925, -0.12493405491113663, 1.1077479124069214, 0.15627679228782654, 0.009715517051517963, -0.4378882646560669, -0.06253016740083694, -0.5020731091499329, -0.5059184432029724, -0.4348668158054352, -0.07426507771015167, -0.283483624458313, -0.7268263101577759, 0.4391087293624...
def download _ chapter _ body _ in _ scraper ( self, chapter : chapter ) - > str : raise fallbacktobrowser ( )
[ -0.9409812092781067, -1.033193588256836, 0.5234389901161194, 0.08092710375785828, -0.07042452692985535, 0.15330073237419128, -0.13692988455295563, -0.7223544120788574, 0.6035191416740417, 0.3958468437194824, 0.0734863132238388, -0.22903576493263245, 0.3691105246543884, 1.0632762908935547, ...
def main ( ) : genes = collections. defaultdict ( list ) for item in glob. glob ( " *. fa " ) : bname = os. path. basename ( item ). split ( ". " ) [ 0 ] identifier, gene = bname. split ( " _ " ) genes [ gene ]. append ( identifier ) outdir = os. path. join ( os. getcwd ( ), " aggregated " ) if not os. path. isdir ( ou...
[ -0.20734624564647675, -0.2624087929725647, 0.9274318814277649, 0.3408840596675873, 0.3274956941604614, 0.04559585452079773, 1.2133288383483887, 0.7481595277786255, -0.3124738931655884, 0.3147886097431183, -0.6486080288887024, -0.1607472151517868, 0.8404691815376282, 0.19696815311908722, ...
def _ get _ header _ position ( header _ row : list [ str ], column _ title : str ) - > int : for pos, column in enumerate ( header _ row ) : if column _ title. lower ( ) in column. lower ( ) : return pos raise exception ( " expected column header not found for { } ". format ( column _ title ) )
[ -0.09489216655492783, -0.6566553115844727, 0.730069100856781, 0.04490458592772484, -0.30416685342788696, -0.33804407715797424, -0.6021894216537476, -0.08153470605611801, -0.9725209474563599, 0.5576638579368591, 0.35195210576057434, -0.4967336058616638, -0.555404782295227, -0.76071810722351...
async def send _ hand ( self, player, player _ num ) : def react _ check ( msg ) : def check ( reaction, reacting _ user ) : return reacting _ user! = self. client. user and str ( reaction. emoji ) in self. emojis and reaction. message. id = = msg. id return check embed _ hand = discord. embed ( title = f " { self. use...
[ -0.31510505080223083, 0.3262612223625183, 0.944666862487793, 0.08775114268064499, 0.7072174549102783, 0.10609546303749084, 0.37613368034362793, -0.49981796741485596, 0.3123871982097626, 0.8115279674530029, -0.04325324669480324, 0.44576457142829895, -1.0805087089538574, -0.19402456283569336...
def metadata ( self, path ) : raise notimplementederror
[ -0.7673989534378052, -0.5624187588691711, 0.4442524313926697, 0.3241887092590332, 0.3419520854949951, 0.879643440246582, -0.2073051929473877, -0.06888092309236526, -0.37888413667678833, 0.44570285081863403, 0.12196457386016846, 0.5874967575073242, 1.0441169738769531, 0.24257703125476837, ...
def put ( self, type : type [ t ], item : t ) - > none : logger. info ( " getting sinkhandlers for \ " { type } \ " ". format ( type = type. _ _ name _ _ ) ) try : handlers = self. _ put _ types [ type ] except keyerror : try : logger. info ( " building new sinkhandlers for \ " { type } \ " ". format ( type = type. _ _...
[ -1.629900574684143, -0.0749892145395279, 0.6413012146949768, -0.4120934009552002, 0.7388185858726501, -0.08156177401542664, 0.3718816637992859, -0.8407058715820312, 0.4574723541736603, 0.6426642537117004, -1.0870099067687988, 0.9213340878486633, -0.9417074918746948, -0.20767000317573547, ...
def is _ date ( value ) - > bool : int _ date _ patterns = [ r " ^ ( 19 | 20 ) \ d { 2 } $ ", r " ^ \ d { 4 } ( 0? [ 1 - 9 ] | 1 [ 012 ] ) $ ", r " ^ \ d { 4 } ( 0? [ 1 - 9 ] | 1 [ 012 ] ) ( 0? [ 1 - 9 ] | [ 12 ] \ d | 3 [ 01 ] ) $ " ] fmts = [ " % y 年 % m 月 % d 日 ", " % y 年 ", " % y 年 % m 月 ", " % y - % m - % d ", " %...
[ -0.13156376779079437, -0.19448967278003693, 1.2393076419830322, 0.43446025252342224, -0.8927000164985657, 0.4191533923149109, -0.2027614265680313, -0.42220339179039, 0.9038316011428833, -0.34435969591140747, -0.266422837972641, -0.05243315547704697, -0.8037964105606079, 0.5635491013526917,...
def parseihex ( filename ) : data = b'' with open ( filename,'r') as hexfile : try : for line in hexfile. readlines ( ) : if line = =': 00000001ff \ n': return data elif line = =': 00000001ff': return data if line [ 0 ]! =':': raise exception ( " invalid hexfile! ", filename ) dbg _ bytes = int ( line [ 1 : 3 ], 16 ) #...
[ 0.4106570780277252, -0.16730022430419922, 0.9572893381118774, -0.7075700759887695, 0.11610649526119232, 0.6637886166572571, 0.1708775758743286, 0.48151081800460815, -0.37832391262054443, -0.38034680485725403, -0.2564241588115692, -0.4968090057373047, -0.8153030872344971, 0.690218448638916,...
def plot _ rupture _ mags _ vs _ occurrence _ rates ( self, color _ param = none, timespan = none, marker ='o ', cmap ='jet ', * * kwargs ) : import matplotlib from plotting. generic _ mpl import plot _ xy ruptures = self. get _ ruptures _ poisson ( timespan = timespan ) mags = np. array ( [ rup. mag for rup in rupture...
[ -0.017478322610259056, 0.0757797509431839, 0.7176151871681213, -0.8787024021148682, 0.18785174190998077, 0.11950959265232086, 0.190340057015419, 0.26244327425956726, 0.3217652440071106, -0.2156774252653122, 0.8909143209457397, 0.5030877590179443, 0.3099759519100189, 0.27977612614631653, ...
def _ list _ hosts ( self ) : raw _ list = self. nessus. request _ list ('report2 / hosts ','hostlist ','host ', report = self. uuid ) hosts = [ ] for host in raw _ list : h = host ( nessus = self. nessus, report = self, hostname = host ['hostname'] ) h. total = host ['severity'] level _ counts = host ['severitycount']...
[ -0.2041996717453003, 0.4255868196487427, 0.34664276242256165, 0.281074583530426, 1.0529011487960815, -0.13335929811000824, -1.2021411657333374, 0.9893804788589478, -0.4813816249370575, -0.5315823554992676, -0.14760124683380127, 0.13946059346199036, -0.4835619032382965, -0.01515113189816475...
def test _ parameters _ mountain _ and _ ocean ( self ) : assert self. o. fodder _ in _ cell = = 0 assert self. o. f _ max = = 0 assert self. o. animal _ can _ enter is false
[ -0.4777950048446655, -0.38338610529899597, 0.3342139422893524, 0.8194345235824585, 1.6163843870162964, 0.9148860573768616, 0.5529767274856567, -0.20442485809326172, -1.2821159362792969, -0.059306997805833817, 0.23622013628482819, 0.6918818950653076, 0.06752698868513107, 1.2759029865264893,...
def testcheckparams ( self ) : def cb ( e = none ) : self. passed = self. passed and e is none def check ( param1, param2 ) : if param1 and param2 : self. passed = true return true checkfunc = functioncall ( check, {'param1':'non - empty string ','param2':'asdfasdf'} ) self. server. watch _ function ( checkfunc, cb ) a...
[ -0.26482322812080383, 0.2497233897447586, 0.5483195781707764, 0.5788787603378296, 1.003321886062622, 0.523384690284729, 0.11035957932472229, -0.16643741726875305, -1.0853396654129028, -0.01064105611294508, -0.008775437250733376, 0.651812732219696, -0.13958320021629333, 0.7541891932487488, ...
def get _ main _ file ( ) : return _ _ main _ _. _ _ file _ _
[ 0.593281090259552, -0.7954510450363159, 0.9041179418563843, 0.3332279324531555, -0.25826746225357056, 0.7694467902183533, 0.9514047503471375, 0.7177327275276184, -0.9247454404830933, -0.6224690079689026, 1.2693837881088257, 0.561294436454773, -0.19502657651901245, -0.0008571942453272641, ...
def line _ search ( objective, theta, s ) : # initial step size alpha = 0. # objective function at start of line search s0 = objective ( theta ) # anonymous function : evaluate objective function along line, parameter is a sa = lambda a : objective ( theta - a * s ) # compute initial jacobian : is objective function in...
[ 0.33226683735847473, -0.3158697783946991, 0.5295031666755676, -0.0646638423204422, -0.5020707249641418, -0.19103609025478363, 0.4263610243797302, -0.11423180997371674, -0.5294843316078186, 0.3269020617008209, 0.09782873094081879, 0.054555587470531464, 0.13690488040447235, 0.280362606048584...
def get _ doc _ types ( doc : doc ) - > set [ str ] : types = [ token. _. spaczz _ type for token in doc if token. _. spaczz _ type ] return set ( types )
[ 0.7993870377540588, 0.503883957862854, 0.3487393856048584, 0.41149020195007324, -0.1298518180847168, 0.42515766620635986, 0.23995977640151978, -0.66301029920578, -0.33090221881866455, 0.25854992866516113, -0.8129318952560425, 0.43026039004325867, -0.7620638608932495, 0.2111583799123764, ...
def get _ texture ( self, tex _ param ) : bs = tex _ param. shape [ 0 ] tex _ base = self. texbase [ none, :, : ]. expand ( bs, - 1, - 1 ) return self. meantex + torch. bmm ( tex _ base, tex _ param [ :, :, none ] )
[ -0.01212260127067566, 0.09802427887916565, 0.5238925814628601, 0.5094630718231201, -0.16501246392726898, -0.35575246810913086, -0.13491883873939514, 0.2539418339729309, 0.1051657423377037, 0.779811441898346, 0.39556393027305603, 0.7487586736679077, -0.9148927927017212, -0.17339050769805908...
def test _ atomic _ id _ pattern _ nistxml _ sv _ iv _ atomic _ id _ pattern _ 1 _ 5 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / id / schema + instance / nistschema - sv - iv - atomic - id - pattern - 1. xsd ", instance = " nistdata / atomic / id / schema + instance / n...
[ 0.1820743978023529, -0.42790645360946655, 0.3896525800228119, 0.36358869075775146, -0.33211812376976013, 0.16687072813510895, 0.8252713084220886, -0.2857721745967865, 0.3850478231906891, 0.9591297507286072, -0.3019044101238251, 0.14745181798934937, -0.14033307135105133, 0.05839336663484573...
def find _ unique _ elements ( table, index ) : unique _ elems = list ( set ( line [ index ] for line in table ) ) return unique _ elems
[ 0.041567012667655945, -0.41061192750930786, 0.3217623233795166, 0.5620507597923279, 0.7996213436126709, 0.32789313793182373, 0.07023124396800995, 0.16245299577713013, 0.2238323837518692, 0.14766041934490204, -0.8269858360290527, 0.213788703083992, 0.3270922601222992, -0.5566964149475098, ...
def get _ high _ scores ( self, request ) : scores = score. query ( score. won is true ). order ( score. guesses ). fetch ( request. results ) return scoreforms ( items = [ score. to _ form ( ) for score in scores ] )
[ -0.5333953499794006, 0.5655990242958069, 0.3600335419178009, 0.8543125987052917, 0.7561585307121277, -0.5518755316734314, -0.36983469128608704, -0.6730029582977295, 0.09784258157014847, -0.19869114458560944, -0.9206404685974121, -0.5692591667175293, 0.19916263222694397, 0.21210941672325134...
def test _ atomic _ hex _ binary _ white _ space _ nistxml _ sv _ iv _ atomic _ hex _ binary _ white _ space _ 1 _ 2 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / hexbinary / schema + instance / nistschema - sv - iv - atomic - hexbinary - whitespace - 1. xsd ", instance =...
[ -0.5424703359603882, -0.23174531757831573, 0.45547959208488464, 0.43733471632003784, -0.10877852886915207, 0.2654971778392792, -0.13188140094280243, -0.20799697935581207, -0.019666781648993492, 0.3565881848335266, -0.23461224138736725, -0.03134391829371452, 0.13147132098674774, 1.306128621...