text
stringlengths
25
2.19k
embedding
listlengths
768
768
def compute _ bond _ distance ( position1 : np. ndarray, position2 : np. ndarray ) - > float : return np. sqrt ( np. sum ( ( position1 - position2 ) * * 2 ) )
[ 0.21853667497634888, -0.682172417640686, 0.5634872913360596, 0.5962483882904053, 0.0066277445293962955, 1.1600096225738525, -0.687821626663208, 0.34499362111091614, -0.00008168641215888783, 0.7090466022491455, -0.06217995658516884, 0.4667770564556122, -1.0562608242034912, -0.52367705106735...
def energy _ levels ( input _ file, units ='ev ', verbose = true, write = none ) : levels, homos = read _ energy _ levels ( input _ file, units ) if levels. shape [ 0 ] = = 1 : i = homos [ 0 ] homo = levels [ 0 ] [ i ] lumo = levels [ 0 ] [ i + 1 ] out = f " " " \ ev │ index │ energy │ lumo │ { i + 1 : > 3 } │ { lumo :...
[ 0.061366382986307144, -0.7550246715545654, 0.7584054470062256, -0.09654518216848373, -0.14088092744350433, 0.765317976474762, 0.3606208562850952, 0.37919071316719055, -0.6980491280555725, -0.21256676316261292, -0.07246245443820953, -0.3964100182056427, -0.5958127975463867, -0.1518255621194...
def runsimulation ( net, num _ excitory, num _ inhibitory, t, ib ) : v1 = np. zeros ( [ t, num _ excitory ] ) v2 = np. zeros ( [ t, num _ inhibitory ] ) u1 = np. zeros ( [ t, num _ excitory ] ) u2 = np. zeros ( [ t, num _ inhibitory ] ) # simulate for t in xrange ( t ) : net. layer [ 0 ]. i = np. zeros ( num _ excitory...
[ -0.2623669505119324, 0.6387577652931213, 0.8845826983451843, 0.3488500714302063, 0.8468040227890015, -0.03776711970567703, -0.21285103261470795, -0.20180444419384003, -0.22520790994167328, 1.0740478038787842, -0.277769535779953, -0.27025389671325684, -1.0358200073242188, -0.828056752681732...
def evaluate ( self, grid _ points = none ) : # this method sets self. grid points and verifies it # naivekde does not convert the bw to a scalar, since a vector is # allowed too. super ( ). evaluate ( grid _ points, bw _ to _ scalar = false ) # create zeros on the grid points evaluated = np. zeros ( self. grid _ point...
[ 0.4221961200237274, 0.17355917394161224, 0.7107257843017578, 0.21539951860904694, 0.4341076910495758, -1.120008111000061, -0.6231229305267334, 0.5025683045387268, -0.43413326144218445, 0.1600581556558609, 1.085450291633606, -0.12304620444774628, -0.4865652620792389, 1.0153679847717285, -...
def decode _ one _ step _ forward ( self, encoder _ outputs : torch. tensor, mask : torch. tensor, decoder _ cur _ inputs : torch. tensor, decoder _ state : torch. tensor ) - > tuple [ torch. tensor, torch. tensor ] : context, _ = self. attn ( encoder _ outputs = encoder _ outputs, mask = mask, decoder _ state = decode...
[ -0.5593593716621399, -1.1253360509872437, 0.3498910665512085, 0.35247671604156494, -0.664770781993866, -0.6808003187179565, 0.3901018500328064, 0.031424589455127716, 0.1326177716255188, -0.7215725183486938, 0.2891463041305542, 0.44125744700431824, 0.8426401615142822, -0.0547298789024353, ...
def set _ fill _ encoding _ ds ( ds ) : for varname in ds. variables : set _ fill _ encoding _ da ( ds [ varname ] ) return ds
[ -0.891830325126648, 0.858184814453125, 0.27337223291397095, -0.4210800528526306, -0.33023127913475037, -0.08946934342384338, 0.418112188577652, -0.3731085956096649, 0.5080103874206543, -0.8293371796607971, -0.05563371628522873, 0.5564482808113098, 1.3280514478683472, 1.2053184509277344, ...
def material _ data ( self, material _ data ) : self. _ material _ data = material _ data
[ -0.14483584463596344, -0.6937528252601624, -0.10119947791099548, -0.11200540512800217, -0.15507858991622925, 1.9150341749191284, -0.5211899876594543, 1.2382570505142212, -0.2682666480541229, -0.39785611629486084, 0.27040883898735046, 0.41191795468330383, -0.306264191865921, 0.8505380749702...
def get _ ranked _ per _ class _ names ( self, top _ k = none ) : if self. _ ranked _ per _ class _ names is none and self. _ features is not none : self. _ ranked _ per _ class _ names = _ sort _ feature _ list _ multiclass ( self. _ features, self. _ per _ class _ rank ) if self. _ ranked _ per _ class _ names is not...
[ -0.7392681837081909, -0.17842082679271698, 0.8967821002006531, 0.5732848644256592, 0.24089403450489044, 0.27670812606811523, -0.10917753726243973, 0.34807074069976807, 0.3255236744880676, 0.02955589070916176, -0.07540431618690491, -0.0882592424750328, 0.27555593848228455, 0.756279885768890...
def folderstats ( folderpath, hash _ name = none, microseconds = false, absolute _ paths = false, exclude = none, filter _ extension = none, follow _ links = false, ignore _ hidden = false, parent = true ) : columns = ['id ','path ','name ','extension ','size ','atime ','mtime ','ctime ','folder ','num _ files ','depth...
[ 0.468260794878006, 0.6846649646759033, 0.8134276866912842, 0.20393937826156616, -0.6001002788543701, -0.2681505084037781, 0.38622015714645386, -0.3615836799144745, -0.5396754145622253, -0.6660232543945312, 0.29187503457069397, 0.029988765716552734, 0.36954742670059204, 0.2734178900718689, ...
def generate _ yolo _ custom _ cfg ( self ) : # 1 ) edit cfg file print ( " generating. cfg file for { } classes ". format ( self. n _ classes ) ) # print ( " classes number : { } " ) # edit subdivision, max _ batches, classes and filters on configuration file # max batches 2000 * class, but a minimum of 6000 max _ bat...
[ 0.007143506780266762, -0.22826343774795532, 0.9389922618865967, -0.024285562336444855, -0.37229353189468384, -0.2726680338382721, 0.9684177041053772, 0.27187642455101013, -1.0775668621063232, 0.019180571660399437, -0.3637760579586029, -0.024150310084223747, 0.8059959411621094, 1.0977280139...
def all _ possible _ forms _ for ( word : text ) - > sequence [ word ] : pass
[ -0.819550633430481, -0.0534844696521759, 0.4772297143936157, 0.9356940984725952, -0.247837096452713, 0.3889363706111908, -0.48120784759521484, 0.0008127774344757199, 0.002935646567493677, -0.9696303009986877, -1.4029942750930786, -0.13715359568595886, -0.09168992936611176, 1.30857300758361...
def get _ boundary _ cell _ count ( plate _ dims, exclude _ outer = 1 ) : boundary _ cell _ count = 2 * ( plate _ dims [ 0 ] + plate _ dims [ 1 ] - 2 ) if exclude _ outer = = 2 : boundary _ cell _ count + = 2 * ( plate _ dims [ 0 ] - 2 + plate _ dims [ 1 ] - 2 - 2 ) return boundary _ cell _ count
[ -0.22057399153709412, 0.0898948535323143, 0.9117640852928162, 0.8303260207176208, -0.4823177456855774, 0.4128253161907196, 0.3325158655643463, 0.487435519695282, -0.629761278629303, -0.505316972732544, -0.21103434264659882, 1.0119991302490234, -0.44876983761787415, 0.021615393459796906, ...
def bytesize ( self, * args, * * kwargs ) : # real signature unknown pass
[ 0.23239673674106598, 0.19604234397411346, 0.44908636808395386, 0.499871164560318, 1.0310120582580566, -0.30849558115005493, 0.38429296016693115, 0.03431426361203194, -0.26844146847724915, -0.590616762638092, -0.890697717666626, 0.21555423736572266, -0.6474089026451111, 0.6532294750213623, ...
def deletemenuitem ( rest _ id, menu _ id ) : menuitemobj = session. query ( menuitem ). filter _ by ( id = menu _ id ). one ( ) restobj = session. query ( restaurant ). filter _ by ( id = rest _ id ). one ( ) if restobj. user _ id! = login _ session ['user _ id'] : flash ('you are not authorized to delete this menu it...
[ -0.0904771015048027, -0.43395957350730896, 0.6703649759292603, 2.0302350521087646, -0.19933176040649414, 0.5398370623588562, -0.43464112281799316, 0.6077898740768433, 0.2966603636741638, -0.8648156523704529, 0.4763943552970886, 0.12131410837173462, -0.7622821927070618, 0.11337579786777496,...
def test _ equality _ nocheckextra ( ) : test _ obj = uvtest ( ) test _ obj2 = test _ obj. copy ( ) test _ obj2. optional _ int1 = 4 assert test _ obj. _ _ eq _ _ ( test _ obj2, check _ extra = false )
[ -0.3349851965904236, -0.0907176285982132, 0.356042742729187, 0.94356769323349, -0.2304241806268692, 0.9050280451774597, 0.3512240946292877, 0.3614150285720825, 0.8552882671356201, -0.08713415265083313, -0.8741294145584106, -0.38707706332206726, -0.6261918544769287, -0.4226359724998474, -...
def read _ requrls ( i ) : with open ('requested _ parenturls. csv ','ru') as urls _ file : reader = csv. reader ( urls _ file ) lines = list ( reader ) url = lines [ i ] print " generating subpages for base url ", i + 1, "... " return url
[ -0.537014901638031, 0.23920002579689026, 0.5657817125320435, 0.1772930920124054, -0.017323564738035202, 0.9341817498207092, -0.022794654592871666, 0.43986400961875916, -0.6125219464302063, -0.8758465051651001, 0.876939058303833, -0.1555018275976181, 0.18837326765060425, -0.6096212863922119...
def icon ( self ) : try : return pficon. icon _ from _ element ( element = self. _ title, browser = self. browser ) except nosuchelementexception : return none
[ -0.013670633547008038, -0.0597337931394577, 0.3530702292919159, 0.9152176380157471, -0.10085862129926682, -0.25785109400749207, 0.23389384150505066, 0.28263378143310547, -0.021388325840234756, -0.2817850410938263, -0.006820101756602526, -0.63890540599823, -0.24515970051288605, -0.983527779...
def get _ output _ dimensions ( aff : np. ndarray, vol _ or _ shape : union [ np. ndarray, iterable [ float ] ] ) : corners = get _ transformed _ corners ( aff, vol _ or _ shape, zeroindex = true ) # + 1 to avoid fencepost error dims = np. max ( corners, axis = 0 ) - np. min ( corners, axis = 0 ) + 1 dims = ceil _ to _...
[ 0.05068095400929451, -0.06653416156768799, 0.5058546662330627, -0.12396709620952606, 0.12961040437221527, -1.3003076314926147, 0.1354394257068634, -0.4865734279155731, 0.0595218762755394, 0.7636672854423523, 0.18082784116268158, -0.36342328786849976, 0.43413519859313965, -0.100113488733768...
def get _ split _ lines ( ) - > list [ list [ list [ str ] ] ] : lines = [ ] # [ [ [ entry, message ], [ entry, message ] ], # [ [ entry, message ], [ entry, message ] ], etc. ] for line in readlines ( ) [ 1 : ] : start, stop = line. strip ( eol ). split ( delimeter ) start = start. split ( message _ delim ) stop = sto...
[ -0.4474804103374481, -0.3691825866699219, 0.5705179572105408, -0.10138973593711853, -0.062457576394081116, -0.060100484639406204, 0.2439572662115097, 0.5900667309761047, 0.049536220729351044, 0.2214728593826294, 0.3538048565387726, -0.06627754867076874, 0.09495372325181961, 0.3385139703750...
def _ _ deepcopy _ _ ( self, memo ) : cls = self. _ _ class _ _ new = cls. _ _ new _ _ ( cls ) memo [ id ( self ) ] = new new. patterns = deepcopy ( self. patterns ) new. datasets = ordereddict ( ) for k, ds in self. datasets. items ( ) : # deepcopy new. datasets [ k ] = {'xticks': deepcopy ( ds ['xticks'] ),'labels': ...
[ 0.13305723667144775, 0.4271644055843353, 0.7149941325187683, -0.3593943119049072, -0.7500343322753906, 0.044492073357105255, 0.8339916467666626, -0.4919991195201874, 0.16374792158603668, -0.399803102016449, -0.23291806876659393, 0.893922746181488, 0.6250109076499939, -0.32360851764678955, ...
def getddgiocnumber ( ) : andor _ solis. getddgiocnumber. restype = ctypes. c _ uint numberpulses = ctypes. c _ ulong ( ) result = andor _ solis. getddgiocnumber ( ctypes. byref ( numberpulses ) ) check _ status ( result ) return int ( numberpulses. value )
[ -0.6522518396377563, 1.2759835720062256, 0.5863166451454163, 0.18678539991378784, -0.42413005232810974, -0.7152555584907532, 0.8928542733192444, 0.03165744990110397, 0.21131393313407898, -0.9533604383468628, -0.32869091629981995, 0.10262817144393921, 0.2743546962738037, -0.5539252161979675...
def hosts _ links ( self, from _ host, to _ host, limit _ links = 2500, skip _ links = 0, sort _ links = " from _ pubdate _ desc, from _ rank10 _ desc " ) : data = self. _ request ('/ api / inbound ', locals ( ) ) return result ( json. loads ( data ) )
[ -0.9772958755493164, 0.05276098847389221, 0.435397207736969, -0.1779203712940216, 0.20104937255382538, 0.10688672959804535, -1.151689887046814, 0.38327738642692566, -1.3070170879364014, -0.17685410380363464, -0.08577217161655426, 2.0910582542419434, -0.5296694040298462, -0.4461095333099365...
def loginrequired ( cls = none, * * login _ args ) : return classdecorator ( login _ required, cls = cls, * * login _ args )
[ -2.0182912349700928, -0.4539778232574463, 0.5415477156639099, 0.3802597224712372, 0.14894644916057587, 0.4899666905403137, -0.4575693607330322, 0.42209649085998535, 1.0177708864212036, -0.06633109599351883, -0.5870705246925354, 0.7948436141014099, 0.6406307816505432, 0.013148295693099499, ...
def build _ argparser ( ) : parser = argumentparser ( ) parser. add _ argument ( " - m ", " - - model ", required = true, type = str, help = " path to an xml file with a trained model. " ) parser. add _ argument ( " - i ", " - - input ", required = true, type = str, help = " path to image or video file " ) parser. add ...
[ 0.003529373789206147, -0.6277944445610046, 0.7454981207847595, 0.13986465334892273, -0.2026553601026535, 0.1037132740020752, -0.25480297207832336, 0.2023760825395584, -0.3626672327518463, -0.5092858076095581, -0.06843014061450958, 0.8717694878578186, -0.5257908701896667, 0.5667344927787781...
async def async _ setup _ entry ( hass : homeassistant, config _ entry : configentry, async _ add _ entities : addentitiescallback, ) - > none : coordinator : plugwisedataupdatecoordinator = hass. data [ domain ] [ config _ entry. entry _ id ] entities : list [ plugwisenumberentity ] = [ ] for device _ id, device in co...
[ 0.03936098515987396, -0.05102906376123428, 0.35447049140930176, -0.525307834148407, 0.9638567566871643, -0.3486489951610565, -0.06082302704453468, 0.4786874055862427, 0.8078060150146484, 0.610572338104248, 0.0029104433488100767, -0.03343793377280235, 0.6324107050895691, 0.43326714634895325...
def get _ random _ opinion _ different ( op ) : if isinstance ( op, opinion ) : while true : r = get _ random _ opinion ( ) if r! = op : # print > > sys. stderr, " random opinion generated : " + repr ( r ) return r else : raise exception ( " opinion object expected " )
[ -0.6346561908721924, -0.6390530467033386, 0.5277771949768066, 0.43455415964126587, -0.41028162837028503, 0.8177038431167603, 0.5640972852706909, -0.626322329044342, 1.0805845260620117, -0.19140419363975525, -0.14320358633995056, 0.09157881885766983, -1.0593005418777466, -0.7221384048461914...
def waituntiltarget ( self ) : logging. info ( " % s : waiting until target reached ", self. name ) # counter - need it to check if it's the first loop i = 0 while true : # read once self. serial. write ( self. address + " vol \ r " ) resp1 = self. read ( 15 ) if " : " in resp1 and i = = 0 : raise pumperror ( " % s : n...
[ -0.39591652154922485, -0.9680055379867554, 0.5686813592910767, -0.7210390567779541, 0.8137706518173218, 0.4356001019477844, -0.2804974913597107, -0.706731915473938, -0.310416042804718, -0.7064810991287231, 0.7751044034957886, 0.036897893995046616, -0.6223620176315308, -0.601513147354126, ...
def get _ print _ output ( funkcja ) : # tworzymu bufor w pamieci do przechowywania # wartosci string memory _ buffer = io. stringio ( ) # przekierowujemy standardowy output do buforu with redirect _ stdout ( memory _ buffer ) : # wywołujemy funkcje przekazana w argumencie funkcja ( ) # zwracamy string z zawartoscia na...
[ 0.14279073476791382, -0.371271014213562, 0.3496941030025482, -0.28765931725502014, -0.5771368741989136, -0.18887777626514435, 1.0928071737289429, -0.9461694359779358, -0.6733584403991699, -0.847222626209259, 0.06712544709444046, 0.37286242842674255, -0.015346630476415157, -0.26590484380722...
def _ make _ vrt _ element ( vrt _ width, vrt _ height, vrt _ transform, vrt _ crs, vrt _ bands, relative _ to _ vrt = none ) : # needed, but since we can get from other inputs calculate to save space vrt _ bounds = boundingbox ( vrt _ transform. c, vrt _ transform. f + vrt _ transform. e * vrt _ height, vrt _ transfor...
[ 0.25571301579475403, 0.054974522441625595, 0.6752510070800781, -0.45359569787979126, -0.617045521736145, 0.014273175969719887, 0.32562217116355896, -1.1788383722305298, 0.10625766217708588, 0.1116400882601738, -0.04805154353380203, -0.2566836178302765, 0.1721532642841339, -0.53436362743377...
def test _ api _ video _ initiate _ upload _ by _ playlist _ instructor ( self ) : user = factories. userfactory ( ) playlist = factories. playlistfactory ( ) factories. playlistaccessfactory ( role = models. instructor, playlist = playlist, user = user ) video = factories. videofactory ( id = " 27a23f52 - 3379 - 46a2 ...
[ 0.055170975625514984, -0.09605670720338821, 0.7263977527618408, 0.0558517649769783, 0.3721928894519806, 0.4551948010921478, 0.2881197929382324, 0.06427624821662903, 0.35328906774520874, 0.19095273315906525, -0.9712736010551453, 0.7283616065979004, -0.18749018013477325, -0.1941175013780594,...
def createlowvoltagenode ( self, reqfile ) - > lowvoltagenodecreationresp : files = {'inpfile': reqfile. read ( ) } res = requests. post ( self. lowvoltagenodecreationurl, files = files ) operationresult : lowvoltagenodecreationresp = { " issuccess " : false,'status': res. status _ code,'message':'unable to create low ...
[ -0.8451391458511353, -0.28701305389404297, 0.78214430809021, -0.5045468211174011, 0.7209446430206299, 0.2657504677772522, -0.5571745038032532, -0.5108180046081543, -0.345645010471344, -0.19355888664722443, 0.1108427494764328, 0.43641147017478943, -1.4020428657531738, 0.09136893600225449, ...
def get _ expenses ( self ) : return self. database
[ -0.4209561049938202, 0.058192964643239975, 0.2851655185222626, -0.12276607751846313, -0.005713671445846558, 0.017598753795027733, -0.6612646579742432, 0.6474007964134216, 0.4046061038970947, 0.08450809866189957, -0.3580860197544098, -0.028586968779563904, -0.7469968199729919, -0.0954499244...
def isin ( self, isin ) : self. _ isin = isin
[ -0.2234380841255188, -1.2053120136260986, 0.39251458644866943, 0.8892831802368164, 0.15959309041500092, 1.4196206331253052, 0.09071668982505798, 1.7336921691894531, -0.41766083240509033, -0.7498928904533386, -1.1944079399108887, 0.6504172086715698, -0.3558344542980194, -0.7627689838409424,...
def test ( path, overwrite _ baseline = false ) : try : paths = [ os. path. join ( path, f ) for f in os. listdir ( path ) ] except oserror : paths = [ path ] with eyeswrapper ( overwrite _ baseline = overwrite _ baseline ) as eyes _ wrapper : for path in paths : match _ window ( eyes _ wrapper. eyes, path )
[ -0.3323563039302826, 0.2328425943851471, 0.5981398820877075, 0.5352804660797119, -0.013713095337152481, 0.159297376871109, 0.9418784976005554, -0.4538109302520752, 0.6381661295890808, -0.21469052135944366, 0.44234228134155273, -0.029157808050513268, -0.44689688086509705, 0.709288477897644,...
def test _ subscription _ api _ with _ reducing _ subscribed _ ticket ( self ) : self. test _ subscription _ api _ with _ paid _ event ( ) data = { " event _ id " : self. event. id, " user _ id " : self. user _ id, " no _ of _ tickets " : - 2, " card _ number " : 5039303342356004, " expiry _ year " : 2022, " expiry _ m...
[ 1.3331784009933472, -0.44228655099868774, 1.1113168001174927, 0.6026186347007751, 0.5592069625854492, 0.7136443257331848, -0.6764169931411743, -0.2208268791437149, 0.08553077280521393, -0.8625096678733826, -0.7391836643218994, 0.2944033741950989, 0.005652214400470257, 0.5187167525291443, ...
def eval _ orders ( board, orders ) : contests = [ ] for order in orders : # in case a player has no orders if order = = [ ] : orders. remove ( [ ] ) for ter in board : for player in orders : for order in player : territory = order [ 0 ] contender = order [ 2 ] bid = order [ 1 ] if ter. name = = territory. name : if te...
[ -0.07869510352611542, -0.41111621260643005, 0.702510416507721, -0.18843457102775574, -0.13223202526569366, -0.14952492713928223, 0.33670300245285034, -0.41646769642829895, 0.3964739441871643, 0.44769948720932007, 0.31901612877845764, -0.03911815956234932, 0.24852797389030457, 0.09449294954...
def infertensorrepresentationsfromschema ( schema : schema _ pb2. schema ) - > dict [ str, schema _ pb2. tensorrepresentation ] : if _ shoulduselegacylogic ( schema ) : infer _ func = _ legacyinfertensorrepresentationfromschema else : infer _ func = _ infertensorrepresentationfromschema return infer _ func ( schema )
[ -0.6391666531562805, 0.18557921051979065, 0.4474180340766907, -0.048005349934101105, -0.8473047614097595, -0.7850757241249084, 0.25560954213142395, 0.23924744129180908, -0.11812161654233932, 0.3053327798843384, -0.6199496388435364, -0.1051938459277153, 0.3493627607822418, 0.490422248840332...
def test _ valid _ inputs ( self ) : valid _ values = ( ('0 ', 0 ), ('123 ', 123 ), ('000123 ', 123 ), ('1 ', 1 ), ) for value, result in valid _ values : self. assertequal ( get _ int _ or _ 404 ( value ), result )
[ -0.7027372121810913, 0.13143014907836914, 0.44855988025665283, 0.1183692216873169, 0.9776336550712585, 0.31717950105667114, 0.16944503784179688, 0.03749935328960419, 0.30918237566947937, -1.1482927799224854, 0.05462268739938736, -0.5357033014297485, -0.4200488328933716, 0.32612600922584534...
def append ( self, data : any ) - > none : self. _ size + = 1 node = node ( data = data ) if self. _ root is none : self. _ root = node return actual = self. _ root while actual. next _ node is not none : actual = actual. next _ node actual. next _ node = node
[ -0.2837876081466675, 0.9072152376174927, 0.45190152525901794, -0.3509771525859833, -0.6238589286804199, 0.0102000180631876, -0.21604251861572266, 0.0674324780702591, 0.9859769940376282, -0.47178128361701965, -0.7783762812614441, 1.0465607643127441, -0.8347535133361816, 1.1470385789871216, ...
def randomstring ( stringlength = 10 ) : letters = string. ascii _ lowercase return''. join ( random. choice ( letters ) for i in range ( stringlength ) )
[ 0.3034032881259918, -0.6329405307769775, 0.061176467686891556, -1.4916069507598877, 0.5626897215843201, 0.7341783046722412, -0.6367138028144836, -0.46008434891700745, 0.6844822764396667, 0.056194234639406204, -0.005000228527933359, 0.4858928322792053, -1.4045629501342773, -1.15293240547180...
def rds _ set ( self ) - > optional [ pulumi. input [ bool ] ] : return pulumi. get ( self, " rds _ set " )
[ 0.11718801409006119, 1.336288571357727, 0.5638414025306702, -0.6029492616653442, 0.760776937007904, 1.0678796768188477, -0.8569177389144897, -0.8524836897850037, 0.5167878270149231, 0.3739357590675354, -0.04838893190026283, 1.1867815256118774, -1.0061124563217163, -0.8826256990432739, -1...
def _ _ del _ _ ( self ) : os. close ( self. mmap _ file )
[ 0.6248496174812317, -1.9697973728179932, 0.5966037511825562, -1.3654839992523193, -0.4990164041519165, 1.3296457529067993, 0.21858133375644684, 0.577582061290741, 0.21286137402057648, -1.2097609043121338, 1.1476922035217285, -0.3729797899723053, -0.011109823361039162, 0.09235147386789322, ...
def target _ template _ member _ id ( self ) : return self. _ target _ template _ member _ id
[ 0.26296466588974, -1.0783872604370117, 0.21200111508369446, -0.2616111636161804, 0.1434313803911209, 0.8315638899803162, 0.04719359055161476, 0.37567201256752014, 0.47561928629875183, -0.46812304854393005, -0.16992369294166565, 1.2977396249771118, -0.48218247294425964, -0.5498297810554504,...
def list _ kadastrale _ afdelingen ( self ) : def creator ( ) : gemeentes = self. list _ gemeenten ( ) res = [ ] for g in gemeentes : res + = self. list _ kadastrale _ afdelingen _ by _ gemeente ( g ) return res if self. caches [ " permanent " ]. is _ configured : key = " list _ afdelingen _ rest " afdelingen = self. c...
[ -0.23274894058704376, 0.12405315041542053, 0.33157268166542053, 0.5357908010482788, -0.983814001083374, -0.1312832087278366, -0.7602648138999939, -0.24047376215457916, 0.42428675293922424, 0.27904677391052246, 0.5893336534500122, -0.4070999324321747, 0.6041839122772217, 0.9766567945480347,...
def get _ book ( func ) : def wrapper ( * args, * * kwargs ) : try : book = kwargs ['book'] if isinstance ( book, int ) : kwargs ['book'] = book. objects. get ( pk = book ) except keyerror : # print ( func. _ _ name _ _, " get _ book called but no book keyword provided! " ) book = args [ 0 ] if isinstance ( book, int )...
[ -1.1990206241607666, 0.2467837780714035, 0.6893466711044312, 1.0342047214508057, -0.07407619059085846, 0.6843357682228088, -0.23656435310840607, -0.13259218633174896, -0.3124508857727051, 0.2914969027042389, 0.6176560521125793, -0.09874764829874039, 0.32906386256217957, 0.6608400344848633,...
def from _ ccd ( cls, array _ electrons, quadrant _ letter, parallel _ size = 2068, serial _ size = 2072, exposure _ info = none, ) : if quadrant _ letter = = " b " or quadrant _ letter = = " c " : return cls. left ( array _ electrons = array _ electrons [ 0 : parallel _ size, 0 : serial _ size ], exposure _ info = exp...
[ 0.636343777179718, -0.49698516726493835, 0.5980638861656189, -0.6948622465133667, -0.26128679513931274, -0.34932443499565125, -0.4905637800693512, -0.3470169007778168, 0.8001238107681274, -0.19965285062789917, 0.02368009462952614, 0.964885413646698, 0.529500424861908, -0.03325972706079483,...
def pdf ( self, x ) : if not isinstance ( x, np. ndarray ) : raise typeerror ( " x must be a numpy. ndarray " ) d = x. shape [ 0 ] if len ( x. shape )! = 2 or x. shape! = ( d, 1 ) : raise valueerror ( " x must have the shape ( { d }, 1 ) ". format ( d ) ) mean = self. mean [ 0 ] cov = self. cov # print ( mean, " \ n ",...
[ -0.3369167149066925, -0.12274516373872757, 0.604978084564209, 0.029433047398924828, -0.6431499719619751, 0.2334248572587967, 0.27230581641197205, -0.0953143909573555, 0.7544547319412231, 0.17539694905281067, 0.4917854964733124, 0.2445565164089203, -0.2085934579372406, 0.009846414439380169,...
def warp _ grid ( self, grid _ dict, mask = true, ret = false, replace = true ) : if isinstance ( grid _ dict, dict ) : pass elif isinstance ( grid _ dict, str ) : with open ( grid _ dict,'r') as f : grid _ dict = json. load ( f ) elif none in [ self. k _ center, self. warp _ grid _ spacing, self. warp _ grid _ dist, s...
[ 0.09115748852491379, 0.9750703573226929, 0.6883359551429749, -0.29253682494163513, 0.32991278171539307, -0.13826797902584076, 0.2863805592060089, 0.2697382867336273, -0.206919863820076, 0.40052148699760437, -0.042290668934583664, 0.3883897364139557, 0.3161436915397644, -0.05712765455245972...
def init ( cls, alpha : jaxarray, beta : jaxarray, sigma : optional [ jaxarray ] = none ) - > " carma " : sigma = jnp. ones ( ( ) ) if sigma is none else sigma alpha = jnp. atleast _ 1d ( alpha ) beta = jnp. atleast _ 1d ( beta ) assert alpha. ndim = = 1 assert beta. ndim = = 1 p = alpha. shape [ 0 ] assert beta. shape...
[ 0.05065681040287018, -0.2974463999271393, 0.7831577658653259, 0.3900400400161743, 0.33713623881340027, -1.2139387130737305, -0.16796617209911346, 0.3651805818080902, -0.29431241750717163, 0.3711569309234619, 0.03379785269498825, 0.47393733263015747, 0.22744350135326385, -0.2011557221412658...
def init _ sess ( ) : engine = create _ engine ('mysql + mysqldb : / / { } : { } @ localhost : 3306 / { } '. format ( sys. argv [ 1 ], sys. argv [ 2 ], sys. argv [ 3 ] ) ) session = sessionmaker ( bind = engine ) session = session ( ) return ( engine, session )
[ -0.47020602226257324, -0.9177206158638, 0.7335711121559143, 0.21422575414180756, 0.10219773650169373, -0.05261727049946785, -0.12325379252433777, -0.09508343786001205, -0.15665175020694733, -0.19223566353321075, -0.837431788444519, 0.7060125470161438, 0.1640286147594452, 0.4369371235370636...
def prepare ( self ) : print'in prepare... ', self. request
[ -0.8314603567123413, -0.9044181108474731, 0.24494488537311554, 0.6436352133750916, 0.19487695395946503, 0.05625331401824951, 0.20131948590278625, -0.5032172799110413, 0.36970457434654236, -0.7682913541793823, 0.14787906408309937, 1.0340065956115723, -0.2185383439064026, 0.6036040186882019,...
def retrive _ id _ spec ( ) : id _ spec _ dict = { } specs _ url ='https : / / moeobrazovanie. ru / specialities _ vuz /'r = requests. get ( specs _ url ) soup = beautifulsoup ( r. text,'html. parser') # going through all specializations from the webpage for spec in soup. find _ all ( " a " ) : if spec. get ('class') =...
[ -0.7110338807106018, -0.6247804760932922, 0.8379929661750793, -0.6074872612953186, -0.20944993197917938, -0.40076562762260437, 0.04079492390155792, 0.2409800887107849, 0.37044256925582886, 0.7236177325248718, -1.1907426118850708, 0.4582313001155853, 0.6134670376777649, 0.47004008293151855,...
def setup ( self ) : self. _ create _ tree ( )
[ 0.5489965677261353, 0.5848909020423889, 0.23990944027900696, -0.40209728479385376, 1.3133490085601807, 0.0950363427400589, 0.6170226335525513, 0.16127753257751465, 0.17747926712036133, 0.12870781123638153, -0.028571194037795067, -0.059222254902124405, -0.1887282282114029, 1.118442654609680...
def fromstring ( cls, * args, * * kwargs ) : # real signature unknown pass
[ 0.5508580207824707, -1.3793206214904785, 0.27897676825523376, 0.543546199798584, -0.1690645068883896, -0.08427036553621292, 0.17931723594665527, 0.11327286809682846, 0.4309666156768799, -0.5292060971260071, -1.1443837881088257, -0.20998436212539673, -0.06152719631791115, -0.133732467889785...
def load _ posts ( target : generator ) - > generator : post _ tags : dict [ str, list [ str ] ] = { } while true : post = yield if post. attrib [ " posttypeid " ] not in { " 1 ", " 2 " } : pass post _ id = post. attrib [ " id " ] parent _ id : optional [ int ] try : parent _ id = int ( post. get ( " parentid " ) ) exc...
[ -0.3934573531150818, 0.4025716483592987, 0.7844198942184448, -0.3472866714000702, 0.08883591741323471, -0.25708532333374023, -0.4237753450870514, -0.38989272713661194, -0.8146272897720337, -0.307986319065094, -0.3759753108024597, -0.13526391983032227, 0.2333364188671112, 0.703191339969635,...
def test _ add _ agent _ requirement ( self ) : pass
[ -0.7661409974098206, -0.8962932825088501, 0.4691019654273987, 0.9317073822021484, 0.41558748483657837, 1.2752113342285156, -0.14341594278812408, 0.006691547576338053, 0.7734568119049072, -0.5673164129257202, -0.4107450246810913, -0.11492274701595306, -0.18546301126480103, 0.890952348709106...
def compute _ loss ( model, imgs, labels ) : logits, probabilities = model ( imgs ) predictions = torch. argmax ( probabilities, dim = 1 ) tp = torch. sum ( predictions = = labels ) return loss _ func ( logits, labels ), tp
[ -0.9221465587615967, -0.4647238552570343, 0.22873516380786896, 0.39015913009643555, 0.019687017425894737, -0.5912342071533203, -0.3477155268192291, 0.4453025758266449, -0.2736053466796875, 0.8299222588539124, 0.14153951406478882, -0.5259976387023926, 0.8748061656951904, -0.1137632951140403...
def findunsortedsubarray _ sort ( self, nums : list [ int ] ) - > int : expected = list ( sorted ( nums ) ) i = 0 while i < len ( nums ) and nums [ i ] = = expected [ i ] : i + = 1 j = len ( nums ) - 1 while j > = i and nums [ j ] = = expected [ j ] : j - = 1 return j - i + 1
[ -0.15254884958267212, 0.3187045753002167, 0.6659746766090393, 0.07586169242858887, -0.4676581919193268, 0.11168704926967621, 1.6482899188995361, 0.20970158278942108, 0.4502555727958679, -0.6147382855415344, -0.6285215616226196, 0.7209718227386475, -1.0312793254852295, 0.5931796431541443, ...
def get _ storage _ id _ in _ area ( scenario, area, area _ type = none ) : grid = scenario. state. get _ grid ( ) loadzone _ set = area _ to _ loadzone ( scenario. info [ " grid _ model " ], area, area _ type = area _ type ) loadzone _ id _ set = { grid. zone2id [ lz ] for lz in loadzone _ set if lz in grid. zone2id }...
[ -0.1758173704147339, -0.3151749074459076, 0.6840007901191711, 0.9684377908706665, -0.2874894142150879, 0.31584399938583374, 1.1588332653045654, -0.03941698372364044, 0.3611777722835541, 0.8380551338195801, 0.1932460367679596, 0.4342491626739502, -0.9242879152297974, 1.2928943634033203, 0...
def custom _ coin ( self, parent : coin, amt : uint64 ) : return coinwrapper ( parent. name ( ), self. puzzle _ hash ( ), amt, self. source )
[ 0.39191699028015137, -0.004387814085930586, 0.09884604066610336, -0.8206861019134521, -1.19744074344635, 0.11799346655607224, -0.38531285524368286, -0.38307106494903564, -0.20082005858421326, -0.2736962139606476, -0.29069727659225464, 0.9960289001464844, 0.26377785205841064, -0.47418975830...
def load _ image _ into _ numpy _ array ( path ) : return np. array ( image. open ( path ) )
[ -1.042569875717163, -1.0895766019821167, 0.0946151614189148, -1.3377116918563843, 0.07631263881921768, -0.2676919996738434, -0.08575541526079178, -0.337532103061676, -0.49545541405677795, 0.5692065358161926, -0.029198672622442245, 0.8523720502853394, -0.06523365527391434, 0.214340656995773...
def test _ sum _ start ( self ) : self. assertequal ( sum ( [ 1, 2, 3 ], 10 ), 16 )
[ 0.465371310710907, -0.06947251409292221, 0.43273404240608215, 0.3601704239845276, 1.3956313133239746, 0.6697474718093872, 0.8140049576759338, -0.007231247145682573, 0.6108422875404358, 0.12397342920303345, -1.384212851524353, -0.0518936812877655, -0.10272783786058426, -0.23590891063213348,...
def my _ print ( self ) : if self. _ _ size = = 0 : print ( ) copy = self. _ _ position [ : ] print ( " { } ". format ('\ n'* copy [ 1 ] ), end = " " ) for x in range ( self. _ _ size ) : print ( " { } { } ". format ('' * copy [ 0 ],'#'* self. _ _ size ) )
[ -0.07834631204605103, -0.777229905128479, 0.7576723098754883, -0.31261909008026123, -0.29513368010520935, 0.22803431749343872, -0.45172587037086487, -0.40197768807411194, -0.22640222311019897, -0.25035130977630615, 0.3236209452152252, 1.0526106357574463, -0.29790833592414856, 0.27675858139...
def checkstale ( self, utcnow ) : stale _ edge = [ ] # loop through every token and their edges and check to # see how long they have been in the graph for token in self. graph : for neighbor, values in self. graph [ token ]. items ( ) : if utcnow. timestamp ( ) - values [ 1 ] > 1. 5 : stale _ edge. append ( [ token, n...
[ -0.46816447377204895, -0.8964703679084778, 0.5488539934158325, -0.07048036903142929, -0.4460834562778473, -0.3773471415042877, -0.8296279311180115, 0.30367204546928406, -0.12576425075531006, 1.352033019065857, -0.45737528800964355, 0.47143301367759705, -0.6758448481559753, 0.77349257469177...
def setkey ( self, key, value ) : self. _ config [ key ] = value
[ -0.9573258757591248, 0.20622752606868744, 0.08399973809719086, -0.009789478033781052, -0.529511034488678, 0.6233635544776917, -1.028388261795044, 0.3175697922706604, -0.8551945090293884, 1.4118200540542603, -0.9920201897621155, 0.06409849226474762, 0.1153925433754921, 0.6911208629608154, ...
def fit _ model ( x, y ) : # create cross - validation sets from the training data cv _ sets = shufflesplit ( x. shape [ 0 ], n _ iter = 10, test _ size = 0. 20, random _ state = 0 ) # create a decision tree regressor object regressor = decisiontreeregressor ( ) params = {'max _ depth': [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ...
[ 0.3489183187484741, 1.107095718383789, 0.7372104525566101, 0.706721305847168, 0.6974165439605713, -0.34273430705070496, -0.36326855421066284, -0.09113404154777527, -0.923052191734314, 0.43946778774261475, 0.308938205242157, 0.4390967786312103, -0.49941301345825195, -0.14304155111312866, ...
def framechange ( self, pos, rot = r ( ) ) : pose _ in _ base _ frame = self. _ frame * self. _ pose self. _ frame = pose ( pos, rot ) self. _ frame _ inv = self. _ frame. inverse ( ) self. _ pose = self. _ frame _ inv * pose _ in _ base _ frame
[ -0.8132282495498657, -0.11972910910844803, 0.4622248113155365, 0.2682866156101227, -0.32513171434402466, -0.8042539358139038, 0.11855359375476837, 0.34907421469688416, -0.1727975457906723, -0.04277004301548004, -1.5458735227584839, -0.09552440047264099, -0.5430285334587097, -0.457905739545...
def acl6pktsnat64rate ( self ) : try : return self. _ acl6pktsnat64rate except exception as e : raise e
[ 0.3152521848678589, -0.03181600570678711, 0.020166601985692978, 0.33853858709335327, -0.6099641919136047, -0.020808020606637, -1.0030274391174316, -0.7256276607513428, 0.49659237265586853, 0.014593294821679592, 0.3758610785007477, -0.32588961720466614, 0.6351296901702881, -0.31444290280342...
def _ _ port _ update _ ui ( self, value ) : if self. _ _ ui _ update : for output in self. selected _ outputs : output. ui. port = value
[ -0.4150405824184418, -1.1508454084396362, 0.46793678402900696, -0.3411971628665924, -0.28279876708984375, -0.008226852864027023, 1.1454683542251587, -0.9816358685493469, 0.18990370631217957, 0.10536464303731918, 0.1978417932987213, -0.3557010591030121, -0.750490128993988, 0.395119965076446...
def create _ segment ( self, name, width, length ) : if name in self. _ segments : raise prgaapierror ( " wire segment named'{ }'is already created ". format ( name ) ) return self. _ segments. setdefault ( name, segment ( name, width, length ) )
[ -0.6537114381790161, -0.2089233696460724, 0.18736319243907928, -0.4144335687160492, 0.906609833240509, 0.2539532780647278, -0.6209149956703186, -1.427331566810608, 0.5084590911865234, 0.11493851244449615, -0.9548023343086243, -0.46504005789756775, -1.2604937553405762, 0.3828480839729309, ...
def transform ( self, x, mask = none, preimpute _ transform = true, noise _ transform = true ) : returns = dict ( ) n = x. shape [ 0 ] p = x. shape [ 1 ] x _ = np. copy ( x ) if mask is not none : # is it a tuple with true and spiked mask? mask _ spike _ true = true if len ( mask ) = = 2 else false # add noise, if requ...
[ -0.8589561581611633, 0.27867910265922546, 1.121140480041504, -0.3013463616371155, -0.47756847739219666, -0.38283365964889526, -0.035617806017398834, -0.16912271082401276, -0.11464963853359222, 0.7350199818611145, -0.9854316115379333, -0.12183840572834015, 0.10813567787408829, 0.50492185354...
def authenticate ( username ) : scope ='user - top - read'token = util. prompt _ for _ user _ token ( username, scope ) if not token : print ( " can't get token for ", username ) exit ( 1 ) sp = spotipy. spotify ( auth = token ) sp. trace = false return sp
[ -1.1487404108047485, -0.38641080260276794, 0.3193444013595581, 0.07484041899442673, -0.558421790599823, 0.2360345423221588, 0.36821678280830383, -0.3337870240211487, 0.606222927570343, -0.36315029859542847, -0.11965303122997284, 0.19427677989006042, -0.673848569393158, -1.404358148574829, ...
def pdb ( pdb _ id, resource = " pdb ", identifier = none, save = false ) : # check if resource argument is valid resources = [ " pdb ", " entry ", " pubmed ", " assembly ", " branched _ entity ", " nonpolymer _ entity ", " polymer _ entity ", " uniprot ", " branched _ entity _ instance ", " polymer _ entity _ instance...
[ -0.34728482365608215, -0.7445642948150635, 0.8927222490310669, 0.259946346282959, 0.5257386565208435, 0.47160041332244873, 0.15209399163722992, -0.3914361000061035, -0.14929983019828796, -0.13321946561336517, -0.16059744358062744, 0.5109610557556152, -0.7487667798995972, -0.108676552772521...
def half ( window, key ) : half _ width = resolution. width / / 2 third _ width = resolution. width / / 3 half _ height = resolution. height / / 2 third _ height = resolution. height / / 3 left = 0 right = half _ width top = 0 bottom = half _ height if key in ( " up, down " ) : if window. height! = half _ height : wind...
[ -0.4474795162677765, -0.39664754271507263, 1.0514804124832153, 0.027067968621850014, -0.6539549231529236, -0.0855596587061882, 0.5900957584381104, -0.23958073556423187, -0.2971176207065582, 0.7263286709785461, -0.3915722966194153, -0.6080045104026794, -1.2389366626739502, 0.745656907558441...
def ensure _ lib _ for _ cpt ( self, libraries, cpt ) : libname = cpt. attributes. get ('eaglexml _ library ','openjson') if libname in self. libcache : return self. libcache [ libname ] lib = g. library ( libname ) lib. packages = g. packages ( ) lib. symbols = g. symbols ( ) lib. devicesets = g. devicesets ( ) librar...
[ -0.1474580019712448, -0.6733852624893188, 0.25905653834342957, -1.1831414699554443, 0.11682244390249252, 0.7041604518890381, -0.5356506705284119, -0.807526707649231, 0.07758019119501114, -0.14210210740566254, 0.07947532832622528, -0.6196292638778687, -0.7231939435005188, -0.327807396650314...
def do _ update _ all ( self, * * kwargs ) : # pylint : disable = unused - argument _ error _ code = 0 _ msg ='' for _ node in self. tree. all _ nodes ( ) : try : _ error _ code, _ debug _ msg = self. do _ update ( _ node. identifier ) _ msg = _ msg + _ debug _ msg +'\ n'except attributeerror : _ error _ code = 1 _ msg...
[ -0.5019609928131104, -0.2671663165092468, 0.8523039221763611, -0.14469802379608154, 0.720409095287323, -0.4828898310661316, 0.17131857573986053, 0.5401692986488342, -0.9257197380065918, 1.0571212768554688, -0.3045746088027954, 0.2870038151741028, -0.6989085078239441, 0.5726096034049988, ...
def _ mgui _ set _ max _ height ( self, value : int ) - > none : self. _ qwidget. setmaximumheight ( value ) self. _ qwidget. resize ( self. _ qwidget. sizehint ( ) )
[ 0.22225214540958405, 0.7065896391868591, 0.34397202730178833, 0.4496484100818634, -0.3686637878417969, 0.8134022355079651, -0.11142756789922714, -0.27875393629074097, 0.09604287892580032, 0.37082934379577637, -0.7749055027961731, -0.3681449294090271, 0.05957099795341492, 0.2493027895689010...
def test _ fully _ booked ( self ) : event = baker. make _ recipe ('booking. future _ ev') resp = self. _ get _ fully _ booked ( self. user, event ) self. assertin ( event. name, str ( resp. content ) ) poleclass = baker. make _ recipe ('booking. future _ pc') resp = self. _ get _ fully _ booked ( self. user, poleclass...
[ -0.221038356423378, 0.5190666317939758, 0.5572950839996338, 1.439366340637207, -0.5024899244308472, 0.5028234720230103, -0.2084277868270874, 0.617190957069397, -0.6292855143547058, -0.43524327874183655, -0.6459959149360657, -0.7416609525680542, -0.08319161087274551, 0.5985021591186523, 1...
def get ( resource _ name : str, id : pulumi. input [ str ], opts : optional [ pulumi. resourceoptions ] = none, authed : optional [ pulumi. input [ bool ] ] = none, dataphin : optional [ pulumi. input [ str ] ] = none, dataphin _ count : optional [ pulumi. input [ str ] ] = none, instance _ num : optional [ pulumi. in...
[ -0.33772924542427063, 0.05541108176112175, 0.7798235416412354, -1.5157803297042847, -0.25356078147888184, 0.6948169469833374, -0.2855928838253021, 0.7067697644233704, 0.9152745008468628, 0.13968881964683533, 0.036545149981975555, 1.14291250705719, -0.6142944693565369, -0.5231805443763733, ...
def compute _ statistical _ power ( results, threshold = none, method ='dlnz') : # determine which grid axis corresponds to'n'axis = list ( results ['grid']. keys ( ) ). index ('n') # determine the upper / lower threshold thresholds = {'daic': 6,'dbic': 6,'dlnz': 3,'p': 0. 05,'logp': - 1. 3 } if method not in threshold...
[ 0.2520917057991028, 0.406258225440979, 0.5427643060684204, 0.6036712527275085, -0.27037352323532104, -0.9024522304534912, 0.3781263530254364, -0.3727211058139801, -0.11762411147356033, 0.236636221408844, 0.5550793409347534, -0.23385854065418243, -0.3631329834461212, 0.17844954133033752, ...
def _ _ init _ _ ( self, gameinfo : gameinfo ) : self. gameinfo = gameinfo self. playershands : " dict [ str, list [ card ] ] " = { } self. order : " list [ str ] " = [ ] self. currplayerindex = 0 self. lastmove : " list [ card ] " = [ ] self. winorder : " list [ str ] " = [ ] self. state : gamestate = gamestate. setup...
[ -0.5075768828392029, -0.1100369393825531, 1.0253140926361084, -0.18038032948970795, -0.4340069591999054, 0.04370681568980217, -0.08268827944993973, -0.04815130680799484, -0.1663142293691635, 0.14909954369068146, 0.1448645442724228, -0.4831427335739136, 0.3947010934352875, 0.243168771266937...
def numt ( where ) : tt = 0 for i in range ( len ( where ) ) : if where [ i ] = ='t': tt = tt + 1 return tt
[ -0.5058873891830444, -0.22907492518424988, 0.6743419170379639, -0.7150423526763916, -0.25664862990379333, -0.6211420893669128, -0.0551302507519722, 0.37792134284973145, -0.09150045365095139, 1.1225463151931763, -0.8281306028366089, -0.8860958814620972, 0.08497704565525055, -0.4801580607891...
def _ maybeunpackarchive ( self, smaybearchive, fnonfatal = false ) : def unpackfilter ( smember ) : # type : ( string ) - > bool " " " skips debug info. " " " slower = smember. lower ( ) ; if slower. endswith ( '. pdb') : return false ; return true ; asmembers = utils. unpackfile ( smaybearchive, self. sscratchpath, r...
[ -0.12539725005626678, 0.3701666593551636, 0.7763704061508179, 0.30644816160202026, -0.15021516382694244, -0.06465477496385574, 0.11132237315177917, 0.2195863574743271, 0.2318165898323059, -0.2879990339279175, -0.05214550346136093, -0.5099092721939087, -0.3266163170337677, 0.539070963859558...
def rectify ( self, a ) : return a % self. mod
[ 0.04222932830452919, -0.35311394929885864, 0.270635187625885, -1.1064478158950806, -0.02060798928141594, 0.03497118875384331, 0.41665998101234436, 0.4004070460796356, 1.6268885135650635, -0.6902775168418884, 0.6136015057563782, 0.608250081539154, -0.42113858461380005, 0.456531822681427, ...
async def update _ teacher _ application ( self, teacher _ id : int, txt _ id : int, vc _ id : int ) - > none : mycursor, db = await the _ database ( ) await mycursor. execute ('''update teacherapplication set channel _ open ='yes ', txt _ id = % s, vc _ id = % s where teacher _ id = % s'' ', ( txt _ id, vc _ id, teach...
[ -0.6653167009353638, -0.9875479340553284, 0.4912024140357971, -0.3585392236709595, -0.5374866724014282, 0.7376697659492493, -0.27325326204299927, 0.641447901725769, -0.6952623128890991, 1.7264294624328613, 0.1809442639350891, 0.9797916412353516, -1.1069434881210327, 0.5684829354286194, -...
def remove _ dc _ offset ( y ) : return y - np. mean ( y )
[ -0.0480102114379406, -0.2822544276714325, 0.5526488423347473, -0.9001701474189758, -1.3633124828338623, 1.1742334365844727, 1.205578088760376, -0.48486796021461487, 0.9711577892303467, 0.2906152307987213, 0.18282504379749298, 0.15622146427631378, 0.0871046930551529, -0.3007913827896118, ...
def residue _ data _ extract ( data _ file ) : bdat = { } chain ='' data _ lines = open ( data _ file,'ru') count = 0 for line in data _ lines : # ignore comment lines ( beginning with a'#') or blank lines if not comment. match ( line ) : words = line. split ( ) count + = 1 # check number of columns of data if len ( wo...
[ 0.6815890073776245, -0.5048283338546753, 0.6594678163528442, -1.3142495155334473, 0.1486821323633194, -0.6798800826072693, 0.18419314920902252, 0.2045036107301712, -0.9055671095848083, 0.043161265552043915, -0.48487919569015503, -0.31109127402305603, -0.6486528515815735, -0.117570959031581...
def _ _ validate _ tag _ index ( self, index ) : if index < 0 : index + = self. tag _ cnt if index < 0 or index > = self. tag _ cnt : raise indexerror ( " tag index out of range " ) return index
[ -0.24514146149158478, 0.0679503008723259, 0.5364585518836975, -0.5352655053138733, 0.44634971022605896, 0.8180586099624634, 0.10969619452953339, -0.3614034950733185, -0.5150068998336792, -0.5925431251525879, 0.7158814072608948, -0.2644273638725281, -0.03989389166235924, -0.1761955171823501...
def isaddressaligned ( self, addr : int ) - > bool : cachelinesize = self. program _ cache _ line _ size _ log \ if self. _ isdataaddress ( addr ) \ else self. landlord _ cache _ line _ size _ log return ( addr % 2 * * self. program _ cache _ line _ size _ log ) = = 0
[ -0.2982511520385742, -0.18408945202827454, 0.5995364785194397, 0.20479170978069305, -0.6986183524131775, 0.3981170654296875, -0.038501136004924774, -0.011770831421017647, 1.2311192750930786, -0.5912002325057983, 0.26240307092666626, 0.810627818107605, -0.14105257391929626, 1.30773258209228...
def _ mgui _ set _ height ( self, value : int ) - > none : self. _ qwidget. resize ( self. _ qwidget. width ( ), value )
[ 0.2141132354736328, 1.252516269683838, 0.37848854064941406, -0.04835409298539162, -0.18464921414852142, 1.1217197179794312, 0.32712072134017944, -0.7423060536384583, -0.29765331745147705, -0.1299716830253601, -0.8283668756484985, -0.6969823837280273, -0.29349079728126526, 0.483253121376037...
def power _ on ( self ) : result = self. manager. api. query ( ). servers ( self. id ). action. post ( { " action " : " poweron " } ) return result
[ -0.5719985961914062, -0.3492814600467682, 0.6095570921897888, 0.39550095796585083, 0.7992458343505859, -0.39115992188453674, -1.0705722570419312, 0.6278278827667236, 0.07116527110338211, 0.4895654022693634, -1.2470570802688599, 0.906167209148407, -1.6900010108947754, 0.1849619299173355, ...
def create _ screen _ components ( self ) - > none : # put things in rows to organize gadgets. r = 0 # select a file label label ( self. scrollframe. viewport, text ='select options to open / modify images from'' the menu bar at the top ', font = " arial 15 bold " ). grid ( row = r, column = 0, sticky = w ) r + = 1 # c...
[ -0.8096204996109009, 0.021354198455810547, 0.6918767690658569, -0.6420260071754456, 0.33400478959083557, -0.1676892191171646, 0.350018709897995, -1.1849546432495117, 0.24564209580421448, -0.4045097827911377, 0.25775566697120667, -0.16995404660701752, 0.6873726844787598, 1.0247468948364258,...
def code _ length ( self ) : return sum ( len ( opcode ) for opcode in self. code )
[ 0.5467419624328613, 0.6833952069282532, 0.46719253063201904, -0.24490560591220856, 0.6925015449523926, 0.3165435492992401, 0.36038461327552795, 0.5956043601036072, 0.9709033966064453, -0.03190789744257927, -0.7805210947990417, -0.2191731333732605, -0.5868404507637024, 0.381259560585022, ...
def delete _ listing ( ) : if'user _ id'in session : user _ id = session. get ('user _ id') user _ produce _ listing _ id = request. form. get ( " listing " ) produce = produce. query. filter ( produce. prod _ id = = user _ produce _ listing _ id ). first ( ) db. session. delete ( produce ) db. session. commit ( ) flas...
[ -0.43278801441192627, 0.07526275515556335, 0.5785842537879944, 1.4195793867111206, -0.13131381571292877, -0.4588700830936432, 0.9817408323287964, 0.9958388805389404, 0.5848996043205261, -0.22640076279640198, 0.04037050902843475, -0.03617463260889053, 0.4235161244869232, -0.0486178360879421...
def filter _ quick ( self, mindur = 0, minamp = - 90, minfreq = 0, maxfreq = 24000 ) : out = [ ] minamp = db2amp ( minamp ) for p in self. partials : if ( p. duration > mindur and p. meanamp > minamp and ( minfreq < = p. meanfreq < maxfreq ) ) : out. append ( p ) return spectrum ( out )
[ 0.06500059366226196, -0.4478050768375397, 0.6460728049278259, 0.20915909111499786, -1.1161407232284546, 0.15218578279018402, -0.8687503933906555, -0.29354968667030334, 0.4341113567352295, -0.3228411376476288, 0.3402557969093323, 0.8803828358650208, -0.9815296530723572, -0.13955910503864288...
def _ split _ string ( s, delim, escape ='\ \') : ret = [ ] current = [ ] itr = iter ( s ) for ch in itr : if ch = = escape : try : current. append ( next ( itr ) ) except stopiteration : current. append ( escape ) elif ch = = delim : # split! ( add current to the list and reset it ) ret. append (''. join ( current ) )...
[ -0.48111996054649353, 0.44749462604522705, 0.48584669828414917, 0.26283490657806396, -0.5266361236572266, -0.8051601648330688, -1.1067190170288086, 0.7422696352005005, -0.0007984292460605502, 0.8308948874473572, 0.16634416580200195, 0.4229971766471863, -0.6722930073738098, -1.2377547025680...
async def send _ message _ out ( self, msg : message ) : await self. _ _ q _ out. put _ async ( msg )
[ -0.31776949763298035, 1.372687578201294, 0.23010359704494476, -0.15478776395320892, 0.12240096181631088, -0.4275311231613159, 0.16676804423332214, 0.044593580067157745, -0.5565539598464966, -0.279461532831192, 0.26566413044929504, 0.5347357988357544, -0.4911139905452728, 0.5809676647186279...
def evaluation ( self, detections, output _ dir ) : if " annos " not in self. _ kitti _ infos [ 0 ] : return none gt _ annos = [ info [ " annos " ] for info in self. _ kitti _ infos ] dt _ annos = self. convert _ detection _ to _ kitti _ annos ( detections ) # firstly convert standard detection to kitti - format dt ann...
[ -0.5965411067008972, -0.6143915057182312, 0.5517416000366211, -0.19751378893852234, -0.1455773562192917, -0.19040422141551971, 0.0630887821316719, -0.29653602838516235, -0.775823175907135, 0.2387578785419464, -0.43774351477622986, 0.4737376570701599, 0.9717473387718201, 0.3804878890514374,...
def get _ menu ( self, model, path ) : return [ ]
[ -1.9774435758590698, -0.7341054677963257, 0.32564952969551086, 1.3369258642196655, 0.5512723326683044, -0.03294720500707626, -0.4492908716201782, 0.3589458167552948, -0.24643248319625854, -0.21614721417427063, -0.8852918148040771, -0.341799259185791, -0.064981609582901, 0.5331571102142334,...
def bfs ( self, maze, goal ) : # you fill this in frontier = [ ] visited = [ ] path = { } path [ maze ] = [ ] # # initial state's path frontier. append ( maze ) while len ( frontier )! = 0 : node = frontier. pop ( 0 ) # current node visited. append ( node ) path [ node ]. append ( node. location ) # since the current n...
[ 0.11453907936811447, 0.007973713800311089, 0.8013163208961487, 1.464424729347229, -0.3945019543170929, -0.6707203984260559, 0.13194815814495087, 0.7407369613647461, 0.18712088465690613, -0.0030397942755371332, -0.15030744671821594, -0.5049141049385071, -0.37739959359169006, 0.5486778020858...