text
stringlengths
25
2.19k
embedding
listlengths
768
768
def save _ img _ with _ bounding _ box ( self, img, new _ img _ name ) : print ('plants are being detected...') start = time. time ( ) contour _ list = self. get _ bounding _ boxes ( img ) for contour in contour _ list : x, y, w, h = contour cv2. rectangle ( img, ( x, y ), ( x + w, y + h ), ( 255, 0, 255 ), 2 ) end = t...
[ -0.6161588430404663, -0.8079014420509338, 0.5453858375549316, 1.1031025648117065, 0.3870839774608612, -0.40624645352363586, 0.37504175305366516, -0.3280021846294403, -0.2562048137187958, 0.48720017075538635, -1.2227044105529785, -0.3078308403491974, 0.5850751399993896, 0.6887735724449158, ...
def module _ installer ( package ) : global on _ pip global on _ easy _ install print ('setting up :'+ package ) if on _ pip : pip. main ( ['install ', package ] ) # pip command elif on _ easy _ install : easy _ install. main ( ['- u ', package ] ) # easy _ install command else : return none
[ -0.7710123062133789, 0.09223270416259766, 0.5550327301025391, 0.6084104180335999, 0.6065597534179688, -0.3558925688266754, 0.19023823738098145, 0.48211508989334106, 0.027133174240589142, 0.13821959495544434, -0.2114754170179367, -0.5373924970626831, -0.2044871300458908, 0.9888028502464294,...
def user ( self, user ) : self ['user'] = user
[ -0.9701633453369141, 0.3401336669921875, 0.1251215934753418, 0.17263224720954895, -0.42050832509994507, 0.4293571710586548, 0.6788442134857178, 0.18353433907032013, 0.038702018558979034, -0.9689381122589111, -2.0016751289367676, -0.400892972946167, 0.5803775191307068, 0.4005632996559143, ...
def get _ relevant _ disorders ( self ) : return self. relevant _ disorders
[ -0.33415210247039795, -0.7713743448257446, 0.3793085813522339, -0.09886565059423447, 0.026136137545108795, 0.6759425401687622, 0.29963624477386475, -0.16715693473815918, 0.2993319630622864, -1.619723916053772, -0.2379784733057022, 0.8992713689804077, 0.32936906814575195, 0.0316465906798839...
def getlengthfrommidpointtoend ( self, edge, midpoint ) : length = 0. 0 lat _ long ='' midpoint. transform ( self. transform ) edge. transform ( self. transform ) # print ( " we have an edge { } ". format ( edge ) ) if ( len ( edge. getpoints ( ) ) = = 0 ) : pointstart, pointend = self. getstartandendvertices ( edge, 0...
[ 0.5661381483078003, -1.1211872100830078, 0.7862909436225891, -0.9163626432418823, -0.24691393971443176, 0.4420664608478546, -0.32026565074920654, 1.0198533535003662, 0.2411746382713318, 1.0113779306411743, -0.34394484758377075, 0.019636506214737892, -0.3791654706001282, 0.3640440106391907,...
def user _ exist _ or _ not ( username ) : return " " " let username = " { username } " return is _ null ( document ( concat ( " { user _ collection } / ", username ) ) ) " " ". format ( username = username, user _ collection = _ db _ nomenclature. user _ collection )
[ -0.6130518913269043, -0.3812316656112671, 0.3539550304412842, -0.1424684226512909, 0.46795809268951416, 0.8956782817840576, 0.3349820077419281, -0.2949715554714203, 0.08786410838365555, 0.7459189295768738, 0.043118249624967575, -0.9320667386054993, -0.19549274444580078, 0.4042588174343109,...
def get _ pairing _ data ( self ) : pairing _ stats = { } other _ pairings = { } for metadata in self. project. collect _ metadata ( ) : if not self. filter _ story ( metadata ) : continue # pairing preprocessing # get raw pairings rawpairings = metadata [ " ships " ] # split pairings with more than 2 members into indi...
[ -0.13925017416477203, 0.16753672063350677, 0.7033358216285706, -0.41645342111587524, -0.5129957795143127, -0.20689047873020172, 0.5640121102333069, 0.05765140429139137, -0.054673563688993454, -0.10922854393720627, 0.4309619069099426, 0.056065745651721954, 0.38699400424957275, 0.73605787754...
async def _ test _ unlinked _ light ( hass, mqtt _ mock, config, num _ switches ) : mac = config [ " mac " ] num _ lights = 2 async _ fire _ mqtt _ message ( hass, f " { default _ prefix } / { mac } / config ", json. dumps ( config ), ) await hass. async _ block _ till _ done ( ) async _ fire _ mqtt _ message ( hass, "...
[ 0.5953130125999451, 0.4228915870189667, 0.4181773066520691, -0.39092451333999634, 0.3543756604194641, -0.029658464714884758, -0.05550003424286842, 0.2548900544643402, 0.2067241370677948, -0.48243844509124756, -0.27072715759277344, -0.09762952476739883, 0.11392883211374283, 0.57996946573257...
def iter _ rows ( self, layer _ name, field _ names, update = false, where _ clause = none, limit = none, prefix = none, postfix = none ) : layer _ path = os. path. join ( self. path, layer _ name ) cursor _ factory = arcpy. da. searchcursor if update : cursor _ factory = arcpy. da. updatecursor logging. debug ('{ curs...
[ -0.13511107861995697, 0.18560285866260529, 0.7190539240837097, -0.36176806688308716, -0.6660932302474976, -0.942104160785675, -0.2974195182323456, 0.3605729341506958, -0.201513409614563, -0.29126185178756714, 0.6457816958427429, 0.6665329337120056, 0.3893289268016815, 0.3707938492298126, ...
def test _ core _ archival _ formats ( uri, filename, type _ hints, expected ) : with requests _ mock. mocker ( ) as mock : # interdict network requests to retrieve data from the localized store instead. mock. get ( uri, content = read _ file ( filename ) ) # interdict local file requests ( occurs when running on an ac...
[ 0.06187605857849121, 0.014342733658850193, 0.5468112230300903, -0.7563992142677307, 0.7167895436286926, 0.4652152955532074, -0.05186215043067932, 0.08888321369886398, -0.5085693001747131, -0.48560160398483276, 0.5257331132888794, 0.503514289855957, 0.1261955350637436, -0.20494775474071503,...
def _ handle _ error ( self, failure, item, spider ) : # do nothing, just log log. err ( failure )
[ -0.5216243863105774, -0.19391319155693054, 0.17015671730041504, 0.23616406321525574, 0.7794451117515564, 0.06479949504137039, -0.28745707869529724, 0.5693750977516174, 0.6258878111839294, -0.829476535320282, -0.1219671368598938, -0.49764201045036316, 0.49763229489326477, -0.240848198533058...
def wrap _ loss ( self, loss, model ) : kl = 0. for m in model. named _ modules ( ) : if m [ 0 ] in self. names : id = np. where ( np. array ( self. names ) = = m [ 0 ] ) [ 0 ] [ 0 ] w, b = self. prior _ means [ id ] w _ var, b _ var = self. prior _ logvars [ id ] curr _ mean = m [ 1 ]. weight curr _ logvar = m [ 1 ]. ...
[ -0.677210807800293, -0.5430107116699219, 0.4885936975479126, -0.36134323477745056, -0.8385128974914551, 0.3087889850139618, -0.4562978446483612, -0.4528508186340332, 0.2561246454715729, 0.801964282989502, 0.4915021061897278, 0.7005484700202942, 0.46538224816322327, 0.7401667237281799, 0....
def _ _ repr _ _ ( self ) - > str : return " < twilio. numbers. v2. hostednumberorderpage > "
[ 0.16259916126728058, -0.19548629224300385, 0.4514375925064087, -0.8100036382675171, -0.52740079164505, 1.1983733177185059, -0.5586894750595093, 0.3148587942123413, 0.5662243366241455, 0.17592047154903412, 0.040019456297159195, -1.0394285917282104, 0.2925257384777069, 0.05868994817137718, ...
def kind ( self ) - > optional [ str ] : return pulumi. get ( self, " kind " )
[ 0.9982480406761169, 0.7434368133544922, 0.3673897087574005, 0.7305705547332764, 1.1483298540115356, 1.2403801679611206, 0.03756310045719147, -0.5454012751579285, 0.5831287503242493, 0.26462751626968384, 0.7707111835479736, 1.3229680061340332, 0.06667038798332214, -1.1392662525177002, -0....
def without _ selfloops ( g ) : h = g. copy ( ) num _ loops = nx. number _ of _ selfloops ( g ) if num _ loops : log. warning ( " network contains % d self - loops. removing... ", num _ loops ) h. remove _ edges _ from ( nx. selfloop _ edges ( g ) ) return h
[ -0.005897272378206253, 0.354963093996048, 0.406760036945343, 0.2702831029891968, -1.5284929275512695, 0.5786855220794678, 0.9734000563621521, -0.7682784795761108, 0.9868825078010559, 0.3471606373786926, -0.3531635105609894, -0.5103846192359924, -0.9869994521141052, -0.19232213497161865, ...
def merge _ dicts ( x, y ) : z = x. copy ( ) z. update ( y ) return z
[ -0.8857298493385315, -0.09071847051382065, 0.6535080671310425, -0.5116850137710571, -1.4791696071624756, -0.11878545582294464, -1.786810040473938, -0.6210542321205139, 0.11515024304389954, 0.029561670497059822, -0.09670811146497726, 0.344314843416214, 0.16101597249507904, -1.37256538867950...
def project ( self ) - > pulumi. output [ str ] : return pulumi. get ( self, " project " )
[ 0.5119717121124268, 0.26811400055885315, 0.42747026681900024, 0.47700226306915283, 0.49848753213882446, 0.9674628973007202, 0.11106149107217789, 0.29852789640426636, 0.3021675646305084, 0.014791194349527359, 0.9372483491897583, 0.199647456407547, 0.20256730914115906, -1.3161094188690186, ...
def main _ movements ( ) : dmcontroller. stop ( ) speed _ list = [ speedsettings. speed _ fastest, speedsettings. speed _ medium, speedsettings. speed _ veryveryslow ] for x in speed _ list : logger. info ( " speed " + str ( x ) ) dmcontroller. stop ( ) logger. info ( " forward " ) dmcontroller. forward ( x ) time. sle...
[ -0.22071121633052826, 0.9988171458244324, 0.5821161270141602, 0.30132317543029785, 0.5969144701957703, -0.24286746978759766, 0.46086713671684265, -0.2764301300048828, -0.31496942043304443, 0.03678111359477043, -0.7768606543540955, -0.2819697856903076, -0.13187001645565033, 0.29585623741149...
def _ remove ( self ) : if self. _ account = = none : print ( " no account is current " ) else : self. _ bank. remove ( self. _ account. getpin ( ) ) self. _ account = none print ( " account removed " )
[ 0.24169312417507172, -0.6869819760322571, 0.41881313920021057, 0.04174315556883812, 0.12310528010129929, 0.2794795334339142, 1.409629464149475, 1.0017505884170532, 0.32842373847961426, 0.37369176745414734, 0.38993948698043823, 0.4674464166164398, -1.2489415407180786, -0.006221016403287649,...
def _ _ togglestate ( self ) : if self. curr _ state = = 1 : self. curr _ state = 0 self. a. state = self. curr _ state # self. a. trigger ( ) else : self. curr _ state = 1 self. a. state = self. curr _ state # self. a. trigger ( )
[ -1.0385154485702515, -0.6938259601593018, 0.542628288269043, 0.08214277774095535, -0.02650441974401474, 0.18759413063526154, 1.2643333673477173, 1.1296718120574951, 0.5963121056556702, 0.19486598670482635, 0.3730674684047699, -0.020978456363081932, -0.5063120126724243, 0.2761552929878235, ...
def read _ file ( file _ name ) : f = open ( file _ name, " r " ) data = f. readlines ( ) return data
[ 0.295170396566391, -0.468191921710968, 0.3654435873031616, -0.3575621247291565, 0.00947476364672184, 0.8526300191879272, -1.004610300064087, 1.001715898513794, -1.1911015510559082, -0.047062940895557404, 0.3452645540237427, -0.05394076555967331, 0.5210315585136414, -0.47195157408714294, ...
def wrapper _ formatter _ factory ( ctx, field, formatter ) : if isinstance ( formatter, wrapperformatter ) : return formatter if callable ( formatter ) : return wrapperlambdaformatter ( ctx, field, formatter ) if isinstance ( formatter, int ) : return wrapperfixedwidthformatter ( ctx, field, formatter ) if isinstance ...
[ -0.8010603785514832, -1.159013032913208, 0.4104548990726471, -0.1653703898191452, -1.0556124448776245, 0.07961345463991165, -0.6544475555419922, -0.6282446384429932, 0.7140926718711853, -0.7630053758621216, 0.8685351610183716, 0.4312458038330078, 0.4052436053752899, 1.0442148447036743, 0...
def test _ remove _ multi _ line _ comments ( self ) : self. assertisnone ( jsonsimpleconfig. loads ( " / * " + jsccommentstestsuite. _ _ example _ jsc + " * / " ) ) self. assertisnone ( jsonsimpleconfig. loads ( " / * \ n " + jsccommentstestsuite. _ _ example _ jsc + " \ n * / " ) ) self. assertisinstance ( jsonsimple...
[ 0.5870755910873413, -0.4953421652317047, 0.811397910118103, -0.6762839555740356, -0.39441996812820435, -0.17475025355815887, 0.07565674185752869, -0.15235207974910736, 0.15142576396465302, 0.21083882451057434, -1.1540484428405762, -0.2483125478029251, 0.37143707275390625, 0.494919985532760...
def removedisableddefinitions ( mojom, enabled _ features ) : mojom. import _ list = ast. importlist ( [ imported _ file for imported _ file in mojom. import _ list if _ isenabled ( imported _ file, enabled _ features ) ] ) mojom. definition _ list = [ definition for definition in mojom. definition _ list if _ isenable...
[ 0.6783634424209595, 0.041595686227083206, 0.36336129903793335, 1.0652832984924316, -0.9126923680305481, -0.22577226161956787, 0.17483538389205933, 1.6636199951171875, -0.17479340732097626, 0.5810707211494446, -0.8638632893562317, -0.017087120562791824, -0.4194565415382385, 0.99732166528701...
def _ _ eq _ _ ( self, other ) : if isinstance ( other, task ) : return self. _ id = = other. id return false
[ -0.29991355538368225, -0.4608640968799591, 0.6629323959350586, 0.5889182686805725, 0.07844926416873932, 0.6311349272727966, 0.6618465781211853, -0.7464663982391357, 0.7479486465454102, 0.1566927433013916, -1.2849068641662598, 0.36490824818611145, 0.14560674130916595, 0.20810459554195404, ...
def _ parsesaml ( saml, saml _ type ) : if saml _ type = ='request': for param in saml : # query strings with no names may be recorded as null in har ( looking at you fiddler ) if param ['name'] is not none and param ['name']. lower ( ) = ='samlrequest': try : request _ encoded = param ['value']. replace ('% 2b ','+') ...
[ 0.37047529220581055, -1.0307164192199707, 0.6634564995765686, 0.24133437871932983, -1.0850803852081299, -0.4381727874279022, -0.2368287742137909, -0.4993104040622711, 1.5938050746917725, -0.06160764768719673, 0.9756426215171814, -0.3699541985988617, -0.11078989505767822, 0.4002977609634399...
def pr ( n, r1, r2 ) : # matriz identidad i = [ [ float ( i = = j ) for j in range ( n ) ] for i in range ( n ) ] return exchangerows ( i, r1, r2 )
[ -0.29110589623451233, 0.8207043409347534, 0.3320029079914093, 0.6894973516464233, 0.39625588059425354, -0.5835543870925903, -0.9797916412353516, -0.43793654441833496, -0.022865090519189835, 1.0443272590637207, 0.8579016923904419, 0.09599368274211884, -0.6543580889701843, -0.361919313669204...
def build _ skeleton ( ) - > none : log. info ( " started rebuilding skeleton schema. " ) path _ query = os. path. join ( os. path. dirname ( _ _ file _ _ ), " create _ skeleton. sql " ) with open ( path _ query, " r " ) as f : query = f. read ( ) db. execute _ query ( query ) log. info ( " finished rebuilding skeleton...
[ -0.42859625816345215, 0.33379316329956055, 0.3008769750595093, 0.45646941661834717, 1.1046711206436157, 0.10851794481277466, 0.9644426107406616, 0.2734505236148834, -0.853394627571106, -0.15930570662021637, 0.21819430589675903, 1.1754016876220703, 0.029328886419534683, -0.6745506525039673,...
def yaml _ loader ( filepath : str ) - > dictionary : with open ( filepath,'r') as file _ descriptor : data = yaml. load ( file _ descriptor, loader = yaml. fullloader ) return data
[ 0.7508178353309631, -0.6128559708595276, 0.2674861550331116, -1.5435001850128174, -1.2898694276809692, -0.6227931380271912, 0.04588507115840912, 0.49524998664855957, -0.560356080532074, 0.2975209057331085, -0.6991302967071533, 0.2039606124162674, 1.2019330263137817, 0.7427999377250671, -...
def path ( self ) - > optional [ str ] : return pulumi. get ( self, " path " )
[ 1.0729804039001465, 0.35089603066444397, 0.2494802474975586, 0.7190569639205933, 1.0290385484695435, 1.382920742034912, 0.49273666739463806, -0.1817772090435028, 0.5736302137374878, -0.18222402036190033, 0.8819752931594849, 0.09467336535453796, -0.17218023538589478, -1.2147738933563232, ...
def remove _ old _ data ( fits, cols, cut ) : f = pyfits. open ( fits ) data = f [ 1 ]. data f. close ( ) # # - - - find where the cut time # pos = 0 dtime = list ( data ['time'] ) for k in range ( 0, len ( dtime ) ) : if dtime [ k ] > = cut : pos = k break # # - - - remove the data before the cut time # udata = [ ] fo...
[ 0.06741121411323547, -0.2601310908794403, 0.6167929172515869, -0.6311668753623962, -0.32924672961235046, 0.3877817392349243, 0.18832597136497498, 0.13410919904708862, -0.6269637942314148, 0.3589438199996948, -0.3071564733982086, 0.24492835998535156, -0.2870319187641144, -0.6346437931060791...
def startswith ( self, prefix ) : children = self. root. children for c in prefix : if c not in children : return false treenode = children [ c ] children = treenode. children return true
[ 0.021719105541706085, -0.12536688148975372, 0.6852700710296631, 0.19273757934570312, -0.6051340699195862, -0.6108250021934509, -0.9321838021278381, -0.05729660764336586, 0.5580241084098816, 0.12933076918125153, -0.5574207305908203, -0.06139173358678818, -0.25705811381340027, 0.751829922199...
def email _ body _ template _ external ( self ) : return self. _ email _ body _ template _ external
[ -0.1487821340560913, -0.05548078194260597, 0.7460328936576843, -0.13574890792369843, -1.0522606372833252, 0.8702593445777893, -0.5207623243331909, -0.8167946934700012, 0.6056461334228516, 0.42621421813964844, -1.0272963047027588, 0.6390591263771057, -0.4473567605018616, -0.3273627758026123...
def bitcount ( i ) : res = 0 while i > 0 : res + = i & 1 i > > = 1 return res
[ -0.027094420045614243, 0.1416408121585846, 0.490921288728714, 0.2622121572494507, -0.4008260667324066, 0.9469606876373291, 1.3772656917572021, -0.24091742932796478, -0.20223167538642883, -0.6227120757102966, -1.061051607131958, 0.39541658759117126, -0.9168203473091125, -0.09069495648145676...
def _ _ setitem _ _ ( self, index : int, value : _ t ) - > none : # get old value, remove old value from # position, insert new value and go along # to other positions and update. # adjust index if necessary length, storage = len ( self ), self. _ st index = self. _ nmlz _ index ( index, length ) binop, inverse = self....
[ -0.7804250121116638, 0.3884381055831909, 0.6832575798034668, 0.1293797641992569, -0.552125871181488, 0.24923254549503326, 0.5196051001548767, -0.46006155014038086, -0.08246913552284241, 0.3084658682346344, -0.9641366600990295, 0.13123445212841034, -0.37497544288635254, -0.1849280446767807,...
def get _ sections _ for _ grading ( self, svc, course : course, grading _ student _ id ) - > optional [ list ] : # pragma : nocover return none
[ -0.2200908660888672, 0.2824483811855316, 0.3465408384799957, 0.14871643483638763, 0.5053444504737854, 0.40857240557670593, -0.08736218512058258, -1.0755834579467773, -0.5794225335121155, -0.07684925943613052, 0.5539567470550537, -0.2650039792060852, -0.08930911123752594, 0.6697276830673218...
def check _ jsov ( template ) : if not " root " in template : print ( " error : object'root'is missing from the top. " ) return false if not " children " in template ['root'] : print ( " error : object'root'lacks a child called'children '. " ) return false if not isinstance ( template ['root'] ['children'], dict ) : pr...
[ -0.7743996381759644, 0.007910278625786304, 0.8746851086616516, 0.3939264118671417, -0.8372204303741455, -0.18981631100177765, 0.9958551526069641, -0.23660266399383545, 0.020167013630270958, 0.16000083088874817, -0.8677107691764832, -1.1634016036987305, 0.052740152925252914, 1.0810381174087...
def test _ paid _ special _ resolution _ correction _ attachments ( session, config ) : # setup filing + business for email legal _ type = business. legaltypes. coop. value legal _ name ='test cp sr business'token ='token'status ='paid'original _ filing = prep _ cp _ special _ resolution _ filing ( cp _ identifier,'1 '...
[ 0.882043719291687, -0.24644406139850616, 0.8088486790657043, -0.027196522802114487, 0.40686872601509094, 0.27955126762390137, 0.2759232521057129, 0.4513396620750427, -0.02003212831914425, -0.27646419405937195, -0.03182557225227356, 0.19415885210037231, 0.5536152124404907, 0.148367062211036...
def testfilter ( self ) : collection = ee. imagecollection ( ee. image ( 1 ) ) noop _ filter = ee. filter ( ) filtered = collection. filter ( noop _ filter ) self. assertisinstance ( filtered, ee. imagecollection ) self. assertequal ( ee. apifunction. lookup ('collection. filter'), filtered. func ) self. assertequal ( ...
[ -0.8903748393058777, 0.0681074857711792, 0.30366167426109314, -0.690567672252655, 0.6431456208229065, -0.27843672037124634, 0.645190417766571, -0.3579588830471039, 0.34898436069488525, -0.6239896416664124, 0.06238396093249321, 0.1452818363904953, 0.0025504932273179293, 0.7459762096405029, ...
def add _ volume _ to _ volumes _ table ( tenant _ uuid, datastore _ url, vol _ name, vol _ size _ in _ mb ) : err _ msg, _ auth _ mgr = get _ auth _ mgr ( ) if err _ msg : return err _ msg logging. debug ( " add to volumes table ( % s % s % s % s ) ", tenant _ uuid, datastore _ url, vol _ name, vol _ size _ in _ mb ) ...
[ -0.0337703563272953, -0.03919772058725357, 0.7707858085632324, -0.3526700437068939, 0.11769068241119385, -0.27939045429229736, -0.20612171292304993, -0.039063237607479095, 0.4190826117992401, 0.3463442027568817, 0.46790480613708496, -0.3008553981781006, 0.031828511506319046, -0.57312333583...
def synth _ coeffs _ static ( self, *, nmax = none, * * kwargs ) : time = self. model _ static. breaks [ 0 ] return self. model _ static. synth _ coeffs ( time, nmax = nmax, * * kwargs )
[ -1.1409311294555664, -0.10533454269170761, 0.19231711328029633, 0.5729063749313354, -0.38023099303245544, -0.5232176184654236, -0.6719586849212646, -1.585031270980835, -0.5408534407615662, 0.12804238498210907, -1.6561377048492432, -0.045697543770074844, 0.7928447723388672, -0.2105300277471...
def create _ venv ( path : str, packages : list [ str ] = [ ], pip _ opts : list [ str ] = [ ] ) - > list [ str ] : logging. info ( " creating virtual environment... " ) venv. create ( path, clear = true, symlinks = false, with _ pip = true ) if os. name = = " nt " : python = os. path. join ( path, " scripts ", " pytho...
[ 0.0527988001704216, 0.24666771292686462, 0.7041547894477844, 0.2865123748779297, 0.47589442133903503, 0.2054355889558792, -0.32806196808815, -0.5521360635757446, -0.0013756250264123082, 0.8665781021118164, -0.7136993408203125, -0.0917326882481575, -0.2733399569988251, 0.4658535122871399, ...
def add _ layout _ pins ( self ) : # add vdd / gnd via stacks for cols in range ( ( self. column _ size * 2 ) - 1 ) : inst = self. cell _ inst [ cols ] for pin _ name in [ " vdd ", " gnd " ] : for pin in inst. get _ pins ( pin _ name ) : if inst. mod. cell _ name = ='sky130 _ fd _ bd _ sram _ _ sram _ sp _ colend'or'sk...
[ 0.04927138611674309, 0.6383335590362549, 1.0197334289550781, 0.05256982147693634, 0.06944310665130615, 0.5752306580543518, 1.2620787620544434, 0.15046939253807068, 0.545320987701416, 0.8551749587059021, -0.06327938288450241, 0.6377857327461243, 0.1454293578863144, 0.3274383246898651, 1.1...
def login ( ) - > str : email = request. form. get ( " email " ) password = request. form. get ( " password " ) if auth. valid _ login ( email, password ) : session _ id = auth. create _ session ( email ) res = jsonify ( { " email " : " { } ". format ( email ), " message " : " logged in " } ) res. set _ cookie ( " sess...
[ -0.5481553673744202, -0.25004518032073975, 0.7896915078163147, 0.1977604627609253, -0.7226195931434631, -0.34695884585380554, -0.3379687964916229, -0.4869003891944885, 0.3137672543525696, 0.22685332596302032, -0.09798049926757812, 0.40584805607795715, -0.026443975046277046, -1.158056497573...
def test _ character _ name _ global ( self, mock _ user _ input ) : character _ name ( ) self. assertequal ( pokemon, {'name':'dave ','position': [ 0, 0 ],'hp': 10 } )
[ -0.5227351188659668, -0.19976548850536346, 0.5746668577194214, -0.16518642008304596, 0.19476096332073212, 1.2211861610412598, -0.049138568341732025, -0.09783866256475449, -0.5721712708473206, 0.09316473454236984, -1.4100544452667236, -0.019056400284171104, -0.07442352175712585, -0.24847117...
def test _ substract _ scalar ( ctx _ factory ) : context = ctx _ factory ( ) queue = cl. commandqueue ( context ) # test data a = np. array ( [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ] ). astype ( np. float32 ) # convert a to a gpu object a _ gpu = cl _ array. to _ device ( queue, a ) result = ( a _ gpu - 7 ). get ( ) assert (...
[ 0.4804189205169678, 0.49060189723968506, 0.7266696691513062, 0.46545541286468506, 0.24542859196662903, 0.4469414949417114, 0.6928051710128784, -0.7465563416481018, 0.236819326877594, -0.8099201917648315, -0.011367526836693287, 0.24268600344657898, -0.07684146612882614, 0.4258211553096771, ...
def _ _ init _ _ ( _ _ self _ _, *, description : optional [ pulumi. input [ str ] ] = none, labels : optional [ pulumi. input [ mapping [ str, pulumi. input [ str ] ] ] ] = none, name : optional [ pulumi. input [ str ] ] = none, project : optional [ pulumi. input [ str ] ] = none ) : if description is not none : pulum...
[ -0.37619149684906006, 0.4114723205566406, 0.7748405337333679, -0.5206418633460999, 0.6631491780281067, 0.903119683265686, -1.2964919805526733, 0.4430619478225708, 0.1145244836807251, -0.009351872839033604, -0.8752291798591614, 0.6013125777244568, 0.0885101780295372, -0.39216864109039307, ...
def extract _ params ( self ) : if self. _ _ method in ('pull ','post') : query = self. _ _ payload else : query = six. moves. urllib. parse. urlparse ( self. _ _ relative _ url ). query p = { } if not query : return p for key, value in urllib. parse. parse _ qsl ( query, keep _ blank _ values = true, strict _ parsing ...
[ -0.5693182945251465, 0.5186218619346619, 0.5465238690376282, 0.018700169399380684, -0.6699428558349609, -0.32180115580558777, -0.7282208204269409, -0.39382147789001465, -0.31854450702667236, 0.6536373496055603, -0.20022836327552795, -0.5333908200263977, -0.3453408479690552, 0.7129182219505...
def isbusy ( self ) - > bool :...
[ -0.13940636813640594, 0.07369176298379898, 0.8514384031295776, 1.2807660102844238, 0.8825372457504272, 0.14905478060245514, -0.21726632118225098, -0.618905246257782, -0.8219015598297119, -0.3816945254802704, -1.3394732475280762, 1.2667579650878906, -0.0844823345541954, -0.02653904445469379...
def testgetthermodata ( self ) : outputdirectory = os. path. join ( self. mop4. settings. filestore, '.. ', '..') self. mop4. setdefaultoutputdirectory ( outputdirectory ) self. gauss3. setdefaultoutputdirectory ( outputdirectory ) self. molpro1. setdefaultoutputdirectory ( outputdirectory ) mol = molecule ( ). fromsmi...
[ 0.45718854665756226, 0.14683926105499268, 0.37256401777267456, 0.03364768251776695, 0.16573163866996765, 0.2283378392457962, 0.11603567004203796, -0.3741486966609955, -0.33049923181533813, -0.8617470264434814, -0.5864889025688171, -0.036980658769607544, -0.24066050350666046, -0.00298156403...
def get _ sine _ wave _ canvas ( * args, * * kwargs ) : width = args [ 0 ] # pixel width for 1 sine wave height = args [ 1 ] # pixel height of sine wave canvas = canvas ( row _ count = height, lpad _ count = width ) global colour _ ptr # global to persist between calls colour _ ptr = ( colour _ ptr + 1 ) % 3 # colour _...
[ 0.3021164834499359, 0.33163130283355713, 0.9110907912254333, -0.0973888635635376, -0.060780711472034454, -0.02214956469833851, -0.0667620524764061, -0.7969454526901245, 0.8307910561561584, -1.027414083480835, 0.2780853807926178, 0.4696729779243469, -0.7553311586380005, 1.394354224205017, ...
def plotthreestdlimits ( self, ax, vals, vmin, vmax, plot _ axis = " x ", plot _ upper = true, plot _ lower = true ) : stds _ and _ colors = ( ( 5, " g " ), ( 4, " y " ), ( 3, " r " ) ) for std, col in stds _ and _ colors : ax = self. plotstdlimits ( ax, vals, vmin, vmax, std, col, plot _ axis, plot _ upper, plot _ low...
[ 0.8989827632904053, 0.8090580105781555, 0.42930617928504944, 0.11931878328323364, -0.7053269147872925, 0.8706347942352295, -0.5845599174499512, -0.6686389446258545, -0.19592595100402832, 0.3899950683116913, -0.26181259751319885, 1.3540780544281006, 0.008405983448028564, -0.6079260110855103...
def insert ( self, word : str ) - > none : charlist = [ char for char in word ] node = self for char in charlist : if char not in node. childlist : curnode = self. letternodes ( char, node ) node. children. append ( curnode ) node. childlist. append ( char ) node = curnode else : index = node. childlist. index ( char )...
[ -0.6221201419830322, 1.2435224056243896, 0.705841064453125, -0.37378692626953125, -0.5066245794296265, 0.6769896149635315, 0.6191087365150452, 0.6465985178947449, 0.03130938485264778, 0.37596395611763, -0.9328426122665405, 0.45783674716949463, -1.4944636821746826, 0.18818512558937073, -0...
def download ( self ) : url = self. url dirname = self. rawfilesdir if not os. path. isdir ( dirname ) : os. mkdir ( dirname ) zip _ name = " mfpt - fault - data - sets - 20200227t131140z - 001. zip " print ( " downloading zip file " ) urllib. request. urlretrieve ( url, os. path. join ( dirname, zip _ name ) ) print (...
[ -0.09863503277301788, -0.24559162557125092, 0.6411170363426208, 0.13803720474243164, -0.24130892753601074, -0.499417245388031, 0.5519152879714966, 0.7403886318206787, 0.6644821763038635, -1.1322373151779175, -0.2959788143634796, -0.1592586636543274, -0.23573681712150574, 0.3227894902229309...
def get _ response ( self ) : return self. _ output. get ('response ', none )
[ 0.44227343797683716, -0.5750922560691833, 0.38536345958709717, 0.9567039608955383, -0.2635214030742645, -0.7645606994628906, 1.0230540037155151, -1.1136068105697632, 0.6023455262184143, -0.9938423037528992, -0.008242899551987648, -0.48548567295074463, -0.5703140497207642, -1.02683806419372...
def test _ not _ match _ between ( self, basic _ logfile ) : matcher = logmatcher ( log _ path = basic _ logfile ) matcher. match ( regex = re. compile ( r " second " ), timeout = 0. 5 ) matcher. mark ( " start " ) matcher. match ( regex = re. compile ( r " fourth " ), timeout = 0. 5 ) matcher. mark ( " end " ) assert ...
[ 0.128354012966156, -0.44850578904151917, 0.8692739605903625, 0.08003166317939758, 0.256394624710083, 1.133700966835022, -0.2578256130218506, -0.14143502712249756, -1.1568681001663208, -0.9119336009025574, -0.5574267506599426, -0.6832356452941895, -1.139084815979004, -0.17757835984230042, ...
def _ parse _ source _ responses _ entities ( self, responses : responses ) - > entities : def entity ( case _ node, test _ case _ status : str ) - > entity : " " " transform a test case into a test case entity. " " " name = case _ node. get ( " name ", " < nameless test case > " ) return dict ( key = name, name = name...
[ -0.2588403522968292, -1.018913745880127, 0.28708162903785706, -0.8191354274749756, 0.36208832263946533, 0.48316633701324463, 0.6220663189888, 0.09536033123731613, 0.9280217289924622, -0.20409169793128967, -0.0014835867332294583, -0.9176557660102844, 0.5049013495445251, 0.6733628511428833, ...
def _ normalize ( observed _ spectrum, template _ spectrum ) : unc = observed _ spectrum. uncertainty. represent _ as ( stddevuncertainty ) num = np. nansum ( ( observed _ spectrum. flux * template _ spectrum. flux ) / ( unc. array * * 2 ) ) denom = np. nansum ( ( template _ spectrum. flux / unc. array ) * * 2 ) return...
[ 0.4233088791370392, -0.5585470795631409, 0.46804797649383545, -0.7494228482246399, -0.5095385313034058, 0.01084849052131176, 0.619048535823822, 1.0795578956604004, 0.14470607042312622, -0.44159698486328125, 0.23272036015987396, 0.6986642479896545, 0.059399791061878204, 0.22474123537540436,...
def test _ multiple _ gen _ nexts ( self ) - > none : id _ gen = self. _ create _ id _ generator ( ) async def test _ gen _ next ( ) - > none : ctx1 = id _ gen. get _ next ( ) ctx2 = id _ gen. get _ next ( ) ctx3 = id _ gen. get _ next ( ) # request three new stream ids. self. assertequal ( await ctx1. _ _ aenter _ _ (...
[ -0.639985203742981, 0.1996179074048996, 0.9680879712104797, -0.08588564395904541, 1.1346590518951416, 0.14938506484031677, 0.11588141322135925, -0.5945577621459961, -0.3466046452522278, -0.6063054800033569, -1.08465576171875, -0.17050378024578094, -0.549618124961853, 0.05876940116286278, ...
def findfilecontainingsymbol ( self, * args, * * kwargs ) : # real signature unknown pass
[ 0.34122949838638306, -0.1435004323720932, 0.4935081899166107, 0.15435077250003815, 0.23742149770259857, 0.16276805102825165, 1.3225525617599487, -0.4952014088630676, -0.8541036248207092, -1.035733938217163, -0.1136704832315445, -0.08204730600118637, -0.36768966913223267, 0.8923215270042419...
def grandir ( self ) : self. _ taille + = 0. 02
[ 0.7633602023124695, 0.07675517350435257, 0.4274820387363434, -0.986160159111023, 1.0286492109298706, 1.565073847770691, -0.08375010639429092, -0.41554179787635803, -1.4574793577194214, -0.004241627641022205, -0.08978868275880814, 0.32102248072624207, 0.18250834941864014, 0.7654200196266174...
def insert _ segment ( self, dimension : tabledimension ) : [ selection _ row _ start, selection _ row _ end, selection _ col _ start, selection _ col _ end ] = self. get _ selected _ range ( ) if dimension = = tabledimension. row : self. insertrow ( selection _ row _ start ) else : self. insertcolumn ( selection _ col...
[ -1.0976390838623047, 0.496723473072052, 0.6379310488700867, 0.47780144214630127, 0.6133677363395691, 0.6063054800033569, 0.8768105506896973, -0.39456868171691895, -0.700621485710144, 0.3663193881511688, -0.47811925411224365, 0.05736744403839111, -0.3221902847290039, 0.03808363154530525, ...
def limit ( num, minimum, maximum ) : num = min ( maximum, num ) num = max ( minimum, num ) return num
[ -0.026401901617646217, -0.22803965210914612, 0.6175388097763062, 1.0404515266418457, -0.14603683352470398, 0.07735919952392578, -0.9350060224533081, -0.4041898250579834, -0.024603605270385742, -0.3123561143875122, -0.4392976760864258, 0.8442835807800293, -0.5984880924224854, -1.35917770862...
def do _ sdn _ controller _ add ( cc, args ) : field _ list = ['ip _ address ','port ','transport ','state'] # use field list as filter user _ specified _ fields = dict ( ( k, v ) for ( k, v ) in vars ( args ). items ( ) if k in field _ list and not ( v is none ) ) try : controller = cc. sdn _ controller. create ( * * ...
[ -0.560254693031311, 0.4809291362762451, 0.5474326014518738, 0.4176512062549591, 0.7472866177558899, 0.39883723855018616, 0.011835186742246151, -0.5543108582496643, 0.15543588995933533, -0.23293763399124146, -0.4912186563014984, -0.3534877896308899, 0.5463742613792419, -0.36835941672325134,...
def lower ( f ) : res = f. copy ( ) res. output _ project ( ) res. minimize ( ) return res
[ 0.5116297602653503, -0.34360262751579285, 0.22540950775146484, 0.8529500365257263, -0.5884944796562195, -0.430055171251297, 1.1186943054199219, -0.6950080990791321, 0.1304030567407608, -0.31016620993614197, 0.47922226786613464, -0.42033782601356506, -0.5884631276130676, -0.8560454845428467...
def test _ simple _ padding ( ) : _ assert _ inout _ for _ expected _ output ( input _ length = 3, expected = 5, padding = 1 )
[ 0.5718333721160889, 0.989885151386261, 0.2866632640361786, 0.3244608938694, -0.22845105826854706, 0.8373326063156128, 0.28172969818115234, -0.23755645751953125, 0.6141400337219238, -0.6056044101715088, -1.0443060398101807, -0.27495458722114563, -0.3055160939693451, 0.7577165961265564, 0....
def create _ ltc _ connection ( ) : access = authserviceproxy ( " http : / / litecoinrpc : 12345678 @ 47. 88. 59. 35 : 2300 " ) return access
[ -0.0690498799085617, -0.808870255947113, 0.4737570583820343, -1.8963757753372192, 0.6266945600509644, -0.7342029809951782, -0.7302166819572449, 0.09050904214382172, -0.10506463795900345, -0.790412425994873, 0.7034884691238403, 0.14525870978832245, -1.420099139213562, -0.5176466107368469, ...
async def validate ( self, session, request, validator : " acmetk. server. challenge _ validator. challengevalidator ", ) - > challengestatus : try : await validator. validate _ challenge ( self, request = request ) except acmetk. server. challenge _ validator. couldnotvalidatechallenge as e : self. error = e. to _ acm...
[ -0.7024289965629578, -0.15665189921855927, 0.35639020800590515, 0.2864622473716736, -0.6783214807510376, -0.054027777165174484, -0.3749295473098755, 0.24746862053871155, 0.501509964466095, -0.3092605173587799, 0.30940502882003784, -0.1399194598197937, 0.09166030585765839, 0.020617401227355...
def binary _ search ( elem : any, arr : sequence ) - > optional [ int ] : def search _ recursive ( left, right ) : if left > = right : return none if arr [ left ] = = elem : return left middle = left + ( right - left ) / / 2 if arr [ middle ] = = elem : if middle = = left + 1 : return middle else : return search _ recu...
[ 0.128994420170784, -0.17145593464374542, 0.7852495312690735, 1.0481181144714355, -0.8096938729286194, -0.2227383255958557, 0.42771971225738525, -1.1438164710998535, 0.5532569885253906, -0.02214309573173523, -0.5904781818389893, 0.4528563320636749, -0.6673299074172974, 0.8374066352844238, ...
def es _ font ( url ) : return ( ( url. path ( ) [ - 3 : ] = ='ttf') or ( url. scheme ( ) = ='data'and url. path ( ) [ : 4 ] = ='font') or ( url. path ( ) [ - 3 : ] = ='svg'and " font " in url. path ( ) ) )
[ -0.6746940016746521, 0.42347294092178345, 0.5224353075027466, 0.3922264575958252, 0.012638173997402191, -1.1116325855255127, -0.05661025643348694, 0.2544100880622864, 1.0207128524780273, 0.016445958986878395, 0.2678506672382355, 0.24765673279762268, 0.9290298223495483, 0.1161179468035698, ...
def _ get _ invalid _ fields ( self, actual _ request ) : invalid _ fields = [ ] for field in actual _ request. keys ( ) : if field not in self. db _ fields : invalid _ fields. append ( field ) self. invalid _ fields = sorted ( invalid _ fields )
[ -1.3318734169006348, 0.2744815945625305, 0.33805638551712036, -0.08866686373949051, 0.45177656412124634, 0.5164844393730164, -0.463370680809021, -0.330718457698822, -0.37396949529647827, 0.09190405905246735, -0.4230406880378723, 0.025133246555924416, -0.6244247555732727, -0.136972278356552...
def number _ map _ to _ sorted _ list ( map ) : return [ v [ 0 ] for v in sorted ( map. items ( ), key = lambda kv : ( - kv [ 1 ], kv [ 0 ] ) ) ]
[ -0.8555294871330261, -1.2677605152130127, 0.6046000719070435, 0.48552340269088745, -0.0945395678281784, 1.0927538871765137, -0.6818385124206543, 0.17085407674312592, 0.27838730812072754, 0.7365657091140747, -0.5934765338897705, -0.16843155026435852, 0.19538381695747375, 0.24921445548534393...
def route _ view ( request, pk = none ) : polyline = [ [ [ ] ] ] all _ routes = bikeroute. objects. all ( ) # list of routes used for selection if pk : bike _ route = get _ object _ or _ 404 ( all _ routes, pk = pk ) polyline = bike _ route. polyline polyline = json. loads ( polyline ) # convert string to a list templa...
[ -0.7885774374008179, -0.4197942912578583, 0.5069239735603333, -0.3969244360923767, -0.32508477568626404, -0.32380232214927673, -0.14649023115634918, 0.48193803429603577, 0.22635188698768616, 0.2536894381046295, 0.10312794893980026, -0.02228572964668274, 0.3314151465892792, -0.0220974385738...
def initialize ( ) : # connecting to our database db. connect ( ) # creating our safe tables for entries db. create _ tables ( [ entry ], safe = true )
[ 0.8753183484077454, 0.6507703065872192, 0.1779405176639557, 0.739594042301178, 1.2499275207519531, 0.5335990190505981, -0.04890419542789459, 0.7851008176803589, -0.8105366826057434, -0.06622347235679626, -1.0342040061950684, 0.059006962925195694, 0.16960017383098602, 0.9048318862915039, ...
def produce ( self, y : mltypes. datasettype, y _ pred : mltypes. datasettype = none, model : mltypes. modeltype = none, x : mltypes. datasettype = none, * * kwargs, ) - > dict [ str, artifact ] : # calculate the predictions if needed : y _ pred = self. _ calculate _ predictions ( y _ pred = y _ pred, model = model, x ...
[ -0.002593840705230832, 0.29751846194267273, 0.6447722911834717, -0.44273659586906433, -0.22923870384693146, -0.3519429564476013, 0.23799686133861542, -0.09965130686759949, -0.04091044142842293, -0.280627965927124, 0.1027757078409195, 1.078214168548584, 1.4087536334991455, -0.03559917211532...
def send _ custom _ event ( self, namespace, name, payload ) : event = proto. event ( ) event. header. namespace = namespace event. header. name = name event. payload = json. dumps ( payload ). encode ('utf - 8') self. send _ event ( event )
[ 0.32884132862091064, -0.28382617235183716, 0.39990273118019104, -0.18649162352085114, -1.0737937688827515, -0.13661371171474457, -1.5494048595428467, -0.5177263021469116, 0.23009195923805237, 0.1405848115682602, -1.0278651714324951, 0.9444558620452881, 0.28051671385765076, 0.15923817455768...
def _ set _ frequency ( self ) : delta _ time = date. fromordinal ( int ( np. max ( self. date ) ) ). year - \ date. fromordinal ( int ( np. min ( self. date ) ) ). year + 1 num _ orig = self. orig. nonzero ( ) [ 0 ]. size if num _ orig > 0 : ens _ size = self. event _ id. size / num _ orig else : ens _ size = 1 self. ...
[ -0.11719739437103271, 0.3198983073234558, 0.6395158171653748, 0.32691267132759094, 0.04104115813970566, -0.17334941029548645, 0.679360568523407, 0.9163422584533691, -0.34900984168052673, -0.476552814245224, 0.4532301127910614, 0.6018800139427185, 0.3001897633075714, 0.741677463054657, 0....
def docs _ for _ object ( *, api _ node : doc _ generator _ visitor. apitreenode, parser _ config : config. parserconfig, extra _ docs : optional [ dict [ int, str ] ] = none, search _ hints : bool = true, page _ builder _ classes : optional [ pagebuilderdict ] = none, ) - > base _ page. pageinfo : if page _ builder _ ...
[ -0.6129545569419861, 0.17531977593898773, 0.7102457284927368, -0.41649872064590454, 0.5408033132553101, 0.2170211672782898, -0.15379738807678223, -0.6735655069351196, 0.37207189202308655, -0.4910000264644623, 0.1247362345457077, 0.06191331893205643, 0.5829038619995117, -0.11653195321559906...
def projectpoint ( self, p ) : imgpt, _ = cv2. projectpoints ( np. array ( [ p [ : 3 ] ] ), self. rvec, self. t, self. k, distcoeffs = self. dist ) # [ ex, ey ] # condition dans la sgmf ex, ey = imgpt [ 0 ] [ 0 ] [ 0 ], imgpt [ 0 ] [ 0 ] [ 1 ] if 0 < ex < self. w [ 0 ] - 1 and 0 < ey < self. w [ 1 ] - 1 : return np. ar...
[ -0.4402996301651001, -0.4896432161331177, 0.6531846523284912, 0.010503606870770454, -0.41582411527633667, 0.548349916934967, -0.5594019293785095, 0.1357841044664383, 0.5322405695915222, 1.3788877725601196, 0.765142560005188, -0.3548583984375, -1.9795624017715454, -0.5640305876731873, 0.0...
def _ addmarkup ( self, namespace, nodename, parent, content, update = 0 ) : # we have to wrap the content to make sure there isn't more # then one root node. wrappedcontent = " < wrap > " + content + " < / wrap > " doc = xmlfragment ( wrappedcontent ) # if we're updating we remove all the existing children of the node...
[ -0.385440856218338, 0.48838478326797485, 0.7017224431037903, -0.4690669775009155, -0.8939288258552551, -0.35757583379745483, -0.594538152217865, 0.26815783977508545, 0.5338589549064636, 0.13395999372005463, 1.4200947284698486, -0.2538934350013733, -0.5703536868095398, -0.23995429277420044,...
def test _ cant _ delete _ driver _ invalid _ id ( self ) : json _ response = api _ call ( self, " delete ",'/ driver / delete ', dict ( id = 102030 ), 200, true ) self. assertequal ( json _ response [ " status _ code " ], 404 ) self. assertequal ( json _ response [ " message " ], " driver not found " ) json _ response...
[ -0.6927465200424194, -0.6642553210258484, 0.7012124061584473, 0.23452302813529968, 0.5453171133995056, 0.11366931349039078, -0.9940156936645508, 0.9007479548454285, 0.6175697445869446, 0.03386136144399643, -0.3828956186771393, 0.00035736968857236207, -0.6311105489730835, 0.6589123010635376...
def cal _ g ( h, r ) : g = np. zeros ( r. size ) if h. ndim = = 1 : for i, dr in enumerate ( r ) : dh = h - np. roll ( h, dr ) g [ i ] = np. mean ( dh * * 2 ) else : for i, dr in enumerate ( r ) : dh = h - np. roll ( h, dr, axis = 1 ) g [ i ] = np. mean ( dh * * 2 ) return g
[ -0.5913015007972717, 1.0101537704467773, 0.6261864304542542, 0.426488995552063, 0.13952377438545227, 0.4463721215724945, 0.8413895964622498, -0.013201475143432617, -0.6850871443748474, 1.1126251220703125, 0.008504340425133705, 0.7965136170387268, -0.3705153465270996, 1.0183887481689453, ...
def testgetvaluesforquerywithpartialunknowntaginreturntags ( self ) : objectid = uuid4 ( ) securetagvalueapi ( self. user ). set ( { objectid : { u'username / tag': 12 } } ) rundataimporthandler ( self. client. url ) self. store. commit ( ) with login ( u'username ', uuid4 ( ), self. transact ) as session : result = yi...
[ -0.01053114514797926, -0.07622082531452179, 0.5124503374099731, -0.17312654852867126, 0.45390215516090393, 0.3459409177303314, -0.5012650489807129, -0.6924389600753784, -0.3896667957305908, -1.1924293041229248, -0.937113881111145, -0.24973468482494354, -0.14369913935661316, 0.0330745950341...
def getcurrentcontext ( self ) : pass
[ -0.39506712555885315, -1.7646082639694214, 0.5812322497367859, 1.019187092781067, -0.048096880316734314, 0.32944804430007935, 0.9053285121917725, -0.4892510175704956, -0.005249440670013428, -0.5513954758644104, 0.060593754053115845, 0.6639822125434875, -0.7965053915977478, -0.3537789881229...
def sample ( self, n _ samples ) : randz = torch. randn ( size = ( n _ samples, self. z _ dim ) ) im _ means = self. decoder ( randz ) sampled _ ims = torch. bernoulli ( im _ means ) # sampled _ ims, im _ means = none, none # raise notimplementederror ( ) return sampled _ ims, im _ means
[ -0.6648567914962769, -0.4507456123828888, 0.3625045716762543, -0.0029788275714963675, -0.3755674660205841, -0.5319076776504517, 0.1593940705060959, -0.24194170534610748, 1.0443228483200073, -0.08814848959445953, -0.008501795120537281, 0.20313240587711334, 0.20568729937076569, 0.84195053577...
def successful _ payment _ callback ( update, context ) : # do something after successfully receiving payment? update. message. reply _ text ( " спасибо за покупку! " ) context. bot. send _ message ( chat _ id = 476800499, text = f " user data : { update. effective _ chat }, \ norder info : { context. user _ data } " )...
[ 0.6529298424720764, -0.5585811138153076, 0.5382512211799622, -0.16230395436286926, -0.7654706239700317, 0.011579584330320358, -0.14308910071849823, -0.08311864733695984, 0.34812554717063904, 0.6574562191963196, 0.009987015277147293, 0.27952271699905396, 0.019121943041682243, -0.37381538748...
def test _ readback _ mode _ on ( self ) : receiver = streamingbodyreceiver ( ) d = deferred ( ) receiver. finished = d receiver. content _ length = 5 fd = receiver. _ fd receiver. datareceived ('hello') why = failure ( responsedone ('done') ) receiver. connectionlost ( why ) self. assertequal ( d. result,'hello') self...
[ 0.3534713685512543, -0.13352929055690765, 0.791857898235321, -0.6963839530944824, 0.4175843298435211, 0.5537604093551636, -0.20743604004383087, -0.32213452458381653, -0.06667660921812057, -1.0604509115219116, -0.502601146697998, -0.09811554104089737, -0.6501972079277039, 0.2142482995986938...
def authorize ( self ) : return redirect ( self. service. get _ authorize _ url ( scope ='public _ profile, email ', response _ type ='code ', redirect _ uri = self. get _ callback _ url ( ) ) )
[ -0.1405450701713562, 0.4300227761268616, 0.4153030216693878, 1.061309814453125, 0.4226624369621277, -0.20780956745147705, 0.7960417866706848, 0.21617338061332703, 0.13913601636886597, -0.7238037586212158, 0.616867184638977, 1.541298508644104, -0.3337831199169159, -0.3624444305896759, 0.4...
def test _ validate _ partial _ invalid _ hostname ( is _ hostname _ valid, app _ context ) : is _ hostname _ valid. return _ value = false payload = { " engine " : " postgresql ", " parameters " : { " host " : " localhost ", " port " : none, " username " : " ", " password " : " ", " database " : " ", " query " : { }, ...
[ 0.5759225487709045, 0.658916711807251, 0.560802161693573, 0.4422241747379303, 0.37191569805145264, 0.5432903170585632, 0.12107017636299133, 0.4645172655582428, -1.2783722877502441, -0.7556564211845398, -0.44212421774864197, -0.05337047204375267, -0.4955945611000061, 0.2884025275707245, 0...
def parsetypedaction ( action ) : inoption = false commands, sep, option, optionstart = list ( ),'','', 0 commandlen = len ( action ) for k, i in enumerate ( action ) : # first letter of the option if i! ='' and not inoption : # set the start index of the option optionstart = k inoption = true # set the option delimite...
[ -0.4564967751502991, -0.45634230971336365, 0.9109463095664978, 0.1388358473777771, 0.5965316295623779, -0.5831233263015747, 0.3693563640117645, -0.8038330674171448, 0.38799774646759033, 1.305853247642517, -0.11368361115455627, 0.6156835556030273, -0.34498360753059387, 0.3298317790031433, ...
def add _ item ( self, item ) : results = [ ] if len ( self. items ) > = self. capacity : results. append ( {'item _ added': none,'message': message ('you don \'t have room for additional items.') } ) else : results. append ( {'item _ added': item,'message': message ('you pick up the { 0 }! '. format ( item. name ) ) }...
[ -0.9079285264015198, 0.47066938877105713, 0.6236767768859863, 0.035388413816690445, 0.6727888584136963, -0.2170811891555786, -0.47998979687690735, -0.5686099529266357, 0.42543092370033264, 0.02580149844288826, -0.5525347590446472, -0.9540165662765503, -0.39625653624534607, 0.44520944356918...
def _ _ getitem _ _ ( self, item ) : if item = = 0 : return self. x elif item = = 1 : return self. y elif item = = 2 : return self. z elif item = = 3 : return self. w else : raise indexerror ( " index out of range : vector 4d has x [ 0 ], y [ 1 ], z [ 2 ], and w [ 3 ] items. item calls greater " " than 3 not permitted ...
[ -0.4881380498409271, -0.3685168921947479, 0.8007095456123352, 0.5067164301872253, -0.32183924317359924, 0.9224576950073242, 0.7714033722877502, -1.246057391166687, 0.030310437083244324, -0.33903491497039795, 0.3450583219528198, -0.2039606124162674, -0.276220440864563, -0.9821093082427979, ...
def load _ map ( map _ filename ) : # todo buildingdict = digraph ( ) print ( " loading building map from file... " ) infile = open ( map _ filename,'r') found1stline = false while not found1stline : nextlinestr = infile. readline ( ) nextlinestr = nextlinestr. strip ( ) if nextlinestr [ 0 ] = ='#': continue else : fou...
[ -0.3307706117630005, -0.6474360227584839, 0.8989182710647583, -0.25599148869514465, -1.0243308544158936, 1.0222365856170654, 0.8348512053489685, 0.6225126385688782, -0.5396163463592529, -0.2983182370662689, 0.04820026457309723, -0.21367685496807098, -0.4629356861114502, -0.3063730895519256...
def test _ write _ offset _ binary ( ) : path = tempfile. mkstemp ( ) [ - 1 ] try : writer. write _ file ( path, b'abc ','wb') writer. write _ file ( path, b'def ','ab ', offset = 1 ) writer. write _ file ( path, b'ghi ','w + b ', offset = 2 ) writer. write _ file ( path, b'jkl ','a + b ', offset = 3 ) with open ( path...
[ -0.19216857850551605, -0.11997019499540329, 0.7153348922729492, -0.24745313823223114, 0.35814744234085083, 1.0023654699325562, 1.001637578010559, 0.1480415165424347, -0.43754130601882935, -0.06655222177505493, -0.4410680830478668, -0.5205954313278198, -0.11753533035516739, 0.08815228193998...
def _ wres ( parallel, progs, fresources = none, ensure _ mem = none ) : parallel = copy. deepcopy ( parallel ) parallel [ " progs " ] = progs if fresources : parallel [ " fresources " ] = fresources if ensure _ mem : parallel [ " ensure _ mem " ] = ensure _ mem return parallel
[ 0.3248360753059387, 0.35281869769096375, 0.376134991645813, -1.361854076385498, 0.00020860393124166876, -0.36149662733078003, -0.14091265201568604, 0.2480047196149826, 0.18043336272239685, 0.27655142545700073, 0.5110109448432922, 0.3732285797595978, -1.0063490867614746, -0.1981672942638397...
def get _ detail _ url ( recipe _ id ) : return reverse ('recipe : recipe - detail ', args = [ recipe _ id ] )
[ 0.5087330341339111, 0.8983094096183777, 0.32697173953056335, -0.17376188933849335, 0.7685605883598328, 0.12378565222024918, -0.2838137745857239, 1.4114333391189575, 0.09099932760000229, -0.27135148644447327, 0.36739346385002136, 0.875190794467926, 0.653825044631958, 0.555872917175293, -0...
def _ set _ name ( self, name, subtitle ) : if name is none : name = self. _ _ class _ _. _ _ name _ _ title = name if not subtitle else name +'-'+ subtitle self. setwindowtitle ( title ) self. setobjectname ( name ) # set the name in the gui. self. name = name
[ -0.30923157930374146, -0.8106595873832703, 0.43075674772262573, 0.10418135672807693, -0.587412416934967, -0.014452612027525902, -0.7709621787071228, -0.4300110638141632, -0.47376278042793274, 0.4121570289134979, -0.8848979473114014, 0.8054400086402893, 0.5950729846954346, 0.810599207878112...
def get _ default _ core _ threshold ( self, target ) : return query _ int _ attribute ( self, target, 0, nv _ ctrl _ gpu _ default _ core _ threshold )
[ -0.31733182072639465, 0.8515197038650513, 0.4483895003795624, 1.1288573741912842, 0.2551388442516327, -0.3129952549934387, 0.4323524236679077, -1.2845351696014404, -0.10822011530399323, -0.12137745320796967, -0.4759816527366638, -0.368705153465271, -1.708920955657959, 0.1002679318189621, ...
def synthetic _ data ( train _ data ) : x = np. asarray ( [ example [ 0 ]. numpy ( ) for example in train _ data ] ) y = [ example [ 1 ] for example in train _ data ] w, h, c = x. shape [ 1 ], x. shape [ 2 ], x. shape [ 3 ] smote = smote ( random _ state = 1000 ) x _ resampled, y _ resampled = smote. fit _ sample ( x. ...
[ 0.16364461183547974, -0.031738556921482086, 0.6686492562294006, 0.1755027025938034, -0.22686979174613953, -0.43255358934402466, -0.5785752534866333, 0.8324940204620361, -0.2835007607936859, 1.0819435119628906, -1.3882572650909424, 0.39197784662246704, 0.9394196271896362, -0.831393063068389...
def load _ csvs ( file _ names ) : df = pd. dataframe ( ) for each _ file in file _ names : new _ df = pd. read _ csv ( each _ file ) df = pd. concat ( [ df, new _ df ] ) return df
[ 0.08498945087194443, -0.0630936548113823, 0.5219210982322693, 0.42515864968299866, 0.3324805796146393, -0.006461992394179106, -0.3575533330440521, 0.703515350818634, -0.4885480999946594, -0.4000445306301117, 0.920772910118103, -0.383772075176239, -0.07741010189056396, 0.07829976081848145, ...