text
stringlengths
25
2.19k
embedding
listlengths
768
768
def hybrid _ forward ( self, f, x, * args ) : h, c = args [ 0 ], args [ 1 ] f _ t = ( self. w _ f ( x ) + self. u _ f ( h ) ). sigmoid ( ) i _ t = ( self. w _ i ( x ) + self. u _ i ( h ) ). sigmoid ( ) o _ t = ( self. w _ o ( x ) + self. u _ o ( h ) ). sigmoid ( ) c _ tilde _ t = ( self. w _ c ( x ) + self. u _ c ( h )...
[ 0.3843546211719513, 0.02679257281124592, 0.6495581865310669, 0.3701261579990387, 0.1487199366092682, 0.7911893725395203, 0.6939066052436829, 0.42599794268608093, -0.8316987156867981, -0.4288823902606964, -0.13876324892044067, 0.2184877097606659, 0.6050041317939758, -0.33104613423347473, ...
def test _ hawkessumexpkern _ fit ( self ) : sto _ seed = 179312 n _ nodes = 2 events, baseline, adjacency = test. get _ train _ data ( self. decays, n _ nodes = n _ nodes, n _ decays = self. n _ decays ) start = 0. 01 initial _ adjacency _ error = \ test. estimation _ error ( start * np. ones ( ( n _ nodes, n _ nodes ...
[ 0.6725899577140808, 0.18841852247714996, 0.9344158172607422, 0.34300336241722107, -0.027620786800980568, 0.29813066124916077, -0.4679844081401825, 0.2845376431941986, -0.20443159341812134, 0.2826686203479767, -0.4822116792201996, 0.7764424085617065, -0.4490583837032318, 0.5870828032493591,...
def do _ create ( self, args ) : arg = args. split ( ) if len ( arg ) = = 0 : print ( " * * class name missing * * " ) elif not arg [ 0 ] in posi : print ( " * * class doesn't exist * * " ) else : clase = arg [ 0 ] modelito = dictclass [ clase ] ( ) modelito. save ( ) print ( modelito. id )
[ -0.8669109344482422, 0.0053227609023451805, 0.8876950144767761, 0.6503264904022217, 1.1444460153579712, 1.086668848991394, -0.43073102831840515, 0.030378762632608414, -0.9468603730201721, 0.5351958274841309, -0.4619884788990021, -1.141042947769165, -0.11302132904529572, 0.23503191769123077...
def interpret _ one _ statement ( tokens, variables ) : if is _ valid ( tokens, variables ) : sum _ of _ values = 0 # iterate over the entire statement by operator - operand pairs for i in range ( 1, len ( tokens ) - 1, 2 ) : operand = tokens [ i + 1 ] operator = tokens [ i ] # convert variable name to its value if ope...
[ -0.3936467170715332, 0.26743200421333313, 0.7348835468292236, -0.8630322813987732, -0.8172560930252075, -0.7721071839332581, -0.4203520119190216, 0.11678921431303024, -0.058802999556064606, 0.28017324209213257, 0.24554145336151123, -0.4971736669540405, -0.15339818596839905, 0.2332857698202...
def add _ dict _ event ( self, event _ dict ) : eventstring ='' for kvpair in event _ dict : if re. search ( r " \ s ", str ( event _ dict [ kvpair ] ) ) : eventstring + ='' + kvpair +'= "'+ str ( event _ dict [ kvpair ] ) +'"'else : eventstring + ='' + kvpair +'='+ str ( event _ dict [ kvpair ] ) eventstring = eventst...
[ -0.23597735166549683, -0.46043306589126587, 0.7628280520439148, -1.0870814323425293, -0.26482534408569336, 0.3524633049964905, -0.7979391813278198, 0.5524969100952148, 0.5842732191085815, 0.4191400110721588, 0.6713061928749084, 0.15724138915538788, -0.03875752538442612, 1.0578278303146362,...
def compute _ bbox _ area ( bbox ) : xmin, ymin, xmax, ymax = tuple ( bbox ) boxarea = ( xmax - xmin ) * ( ymax - ymin ) return float ( boxarea )
[ -0.4675309956073761, 0.14972691237926483, 0.649089515209198, -0.14521704614162445, 0.4289507269859314, -0.22751031816005707, -0.5940250754356384, -0.376312255859375, 0.035662226378917694, 0.19224561750888824, 0.35410648584365845, 0.12877115607261658, -0.2203628271818161, 0.4338796734809875...
def setupclass ( cls ) : app. debug = false # set up the test database app. config ['sqlalchemy _ database _ uri'] = database _ uri
[ 0.2923860251903534, 0.2361646592617035, 0.2683882415294647, 0.35114896297454834, 1.4135279655456543, 0.47955429553985596, 0.3121207058429718, 0.7537302374839783, 0.09075307846069336, -0.06722355633974075, 0.07554668933153152, -0.5919686555862427, -0.3626677691936493, 0.9918816089630127, ...
def font _ color ( self ) : return self. _ font _ color
[ 0.38059768080711365, -0.47922611236572266, 0.2225773185491562, 0.08162582665681839, 0.2705095708370209, 0.17695699632167816, 0.5590479373931885, 0.3988473117351532, 0.4940449893474579, -0.815593421459198, 0.10603377223014832, 1.329999566078186, 0.3946608901023865, 0.45733168721199036, -0...
def _ send ( self, cmd, timeout = 1, retry = 0 ) : _ log. debug ( " executing command. % s ", cmd ) for t in range ( 0, retry + 1 ) : # invalid to send command while another is running # ( except for reset system ) assert not self. running _ cmd or isinstance ( cmd, resetsystem ) # hack, need to clean this up. not all ...
[ -0.7056970000267029, -0.05163656547665596, 0.7460653781890869, 0.3869445323944092, 0.28877902030944824, -0.40439310669898987, 0.46261510252952576, -1.1316587924957275, 0.5793841481208801, -0.08719934523105621, 0.39925694465637207, -0.21034523844718933, -0.809933066368103, 0.209354177117347...
def transform _ image ( img, hom ) : if hom. shape [ 0 ] = = 3 : img _ transform = cv2. warpperspective else : img _ transform = cv2. warpaffine img = img _ transform ( np. asarray ( img ), hom, img. size, flags = cv2. inter _ linear ) img = pil. image. fromarray ( img ) return img
[ 0.18327119946479797, -0.06399542838335037, 0.6259594559669495, 0.7158886790275574, -0.01988166943192482, -0.02876596339046955, -0.7392244338989258, 0.5646440982818604, 0.5306038856506348, -0.010011621750891209, 0.3463328182697296, 0.4965020716190338, 0.25538086891174316, -0.348466992378234...
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 remaining _ balance ( self, remaining _ balance ) : self. _ remaining _ balance = remaining _ balance
[ 0.6407838463783264, -1.0409212112426758, 0.18526726961135864, 0.8663356304168701, 0.13471932709217072, 1.7080353498458862, -0.36943167448043823, -0.37029868364334106, 0.4377424120903015, -0.5110424160957336, -1.2069045305252075, -1.103143334388733, -1.075992226600647, 0.7032647132873535, ...
def main ( ) : # parse the yaml file with open ('test _ images. yml') as config _ file : config _ data = yaml. load ( config _ file ) script _ path = config _ data ['script _ path'] image _ dir = config _ data ['image _ path'] azi = config _ data ['azi'] alt = config _ data ['alt'] fov = config _ data ['fov'] latstart ...
[ -0.07922336459159851, 0.07947137951850891, 0.8609561920166016, 0.09326478838920593, 0.5413789749145508, 0.07338810712099075, 1.2265418767929077, 0.09778840094804764, -0.2944316267967224, -0.003929357044398785, -0.39214980602264404, 0.698627769947052, 1.018493890762329, 0.9834258556365967, ...
def combinedreport ( id, interval, tree ) : mytype = tree ['anc'] [ id ] mynewtype = [ ] x = 0 for i in range ( 0, len ( mytype ), 2 ) : mynewtype. append ( mytype [ i ] ) remapped = np. nan _ to _ num ( mynewtype ) for i in months [ interval ] : x + = remapped [ i ] a = x / 3. 00 # start of comparison report bit of th...
[ 0.533603310585022, -0.7160395979881287, 0.8212973475456238, -0.5146973133087158, 0.40393346548080444, 0.337790310382843, 0.502282440662384, -0.005250667221844196, -0.04510996863245964, -0.30463576316833496, 0.3149360716342926, 0.08907210826873779, -0.9451935887336731, 0.6071667075157166, ...
def set _ geometry ( self, center = none, diam = none, corners = none ) : compute = self. compute if corners : ulr, uli, lrr, lri = corners compute. center = ( ( ulr + lrr ) / 2, ( uli + lri ) / 2 ) ulx, uly = compute. pixel _ from _ coords ( ulr, uli ) lrx, lry = compute. pixel _ from _ coords ( lrr, lri ) compute. di...
[ 0.16734495759010315, -0.13394668698310852, 0.6131057143211365, -0.13270965218544006, -0.1295909285545349, -0.5296556949615479, -0.33768230676651, 0.9316396713256836, 0.6464164853096008, -0.01765427179634571, 0.13653619587421417, 0.7193261384963989, 0.77497398853302, 0.27300116419792175, ...
def test _ regrow _ fodder ( self ) : self. cell. f _ max = 10 self. cell. regrow _ fodder ( ) assert self. cell. fodder _ in _ cell = = 10
[ -0.3202354311943054, 1.6817437410354614, 0.36571595072746277, 0.4576270580291748, 1.108237862586975, -1.136511206626892, 0.08418919146060944, 0.1624363660812378, 0.11794780194759369, -0.6935418844223022, -0.6897478699684143, 0.01094334851950407, 0.16857552528381348, 0.33237940073013306, ...
def authors _ by _ popularity ( ) : query ='''select authors. name, count ( log. id ) as views from authors, articles, log where log. path like'/ article /'| | articles. slug and articles. author = authors. id group by authors. id order by views desc ;'''r = execute _ query ( query ) result = " ". join ( result % ( nam...
[ 0.35212695598602295, 0.3160693049430847, 0.5002063512802124, 0.23889218270778656, -0.5467575788497925, -1.0959833860397339, 0.10916908830404282, 0.5292225480079651, -0.361250638961792, 0.4820299744606018, 1.0538697242736816, 0.346016526222229, 0.6889152526855469, 0.23027558624744415, -0....
def tell _ me _ about ( cls, voice _ transcript, skill ) : tags = cls. _ extract _ tags ( voice _ transcript, skill ['tags'] ) for tag in tags : reg _ ex = re. search ( tag +'( [ a - za - z ] + ) ', voice _ transcript ) try : if reg _ ex : topic = reg _ ex. group ( 1 ) response = cls. _ decoded _ wiki _ response ( topi...
[ 0.22531673312187195, -1.319213628768921, 0.5093069076538086, -0.05889249965548515, 0.4703179597854614, -0.7468367218971252, -1.036476731300354, -0.12398813664913177, -0.6634441018104553, 0.25758758187294006, -0.19927018880844116, -0.27259352803230286, -0.017427770420908928, -0.176204845309...
def get _ contacts ( filename ) : names = [ ] emails = [ ] with open ( filename, mode ='r ', encoding ='utf - 8') as contacts _ file : for a _ contact in contacts _ file : names. append ( a _ contact. split ( ) [ 0 ] ) emails. append ( a _ contact. split ( ) [ 1 ] ) return names, emails
[ -0.6373286843299866, -1.8404895067214966, 0.5722348093986511, -0.7818964123725891, -0.24074654281139374, 0.2784710228443146, -0.3344804048538208, 0.6602864265441895, -0.4127815365791321, 0.6470568776130676, -0.4931265115737915, 0.019367046654224396, -0.11844529956579208, 0.0896165221929550...
def knightlist ( x, y, int1, int2 ) : return [ ( x + int1, y + int2 ), ( x - int1, y + int2 ), ( x + int1, y - int2 ), ( x - int1, y - int2 ), ( x + int2, y + int1 ), ( x - int2, y + int1 ), ( x + int2, y - int1 ), ( x - int2, y - int1 ) ]
[ -0.9679831266403198, -0.5176172852516174, 0.6056605577468872, -0.5546177625656128, -0.312844842672348, 0.18951871991157532, -1.010732889175415, -0.9296987056732178, 0.3660697638988495, 0.8501760959625244, -1.0153703689575195, -0.6346406936645508, -0.07688824832439423, -0.4055010676383972, ...
def generate _ forecast ( data, model, start = none, end = none, resolution = none, params = none ) : if isinstance ( data, pd. series ) or ( isinstance ( data, pd. dataframe ) and len ( data. columns ) = = 1 ) : return generate _ forecast _ from _ ci ( data, model, start, end, resolution, params ) else : return genera...
[ -0.06289754062891006, 0.07872551679611206, 0.4565184414386749, 1.3785479068756104, -0.3773638606071472, -0.6606821417808533, 0.07217540591955185, 0.0698532983660698, -0.30914032459259033, -0.8361499309539795, -0.3946942389011383, 0.10220891982316971, -0.8086514472961426, -0.103774569928646...
def _ _ init _ _ ( self, bus _ number = 1, db = " config " ) : self. db = filedb. filedb ( db = db ) self. forward _ a = int ( self. db. get ( " forward _ a ", default _ value = 1 ) ) self. forward _ b = int ( self. db. get ( " forward _ b ", default _ value = 0 ) ) self. left _ wheel = l298n. motor ( self. motor _ in1...
[ 0.25567129254341125, -0.05835990980267525, 0.7868105173110962, -0.1551515907049179, 0.9821954965591431, 0.10862275958061218, 0.4539004862308502, 0.705462634563446, -0.32233887910842896, -0.39136749505996704, -0.07477086037397385, -0.3662390410900116, -0.771126389503479, 1.1061512231826782,...
def delmin ( self ) : temp _ val = self. heaplist [ 1 ] self. heaplist [ 1 ] = self. heaplist [ self. currentsize ] self. currentsize = self. currentsize - 1 self. heaplist. pop ( ) self. percdown ( 1 ) return temp _ val
[ 0.42011189460754395, -0.7920919060707092, 0.5587503910064697, -0.06367773562669754, -1.7118746042251587, 0.4879979193210602, -0.17125573754310608, -0.33921509981155396, 0.2354595959186554, -0.3995952904224396, 0.16343992948532104, 0.40430524945259094, -1.9666553735733032, 0.557090640068054...
def batch _ evaluation ( self, samples, labels ) : # place data on the corresponding device samples = samples. to ( self. device ) labels = labels. to ( self. device ) # forwarding outputs = self. model ( samples ) # ipdb. set _ trasce ( ) loss = 0. 0 # self. criterion ( outputs, labels ) self. test _ loss + = loss ret...
[ -0.07881329208612442, -0.6846438050270081, 0.19841629266738892, -0.6743996739387512, 0.5221030116081238, 0.3792497217655182, 0.20577333867549896, 0.1545269936323166, -0.5737572312355042, -0.14058533310890198, 0.1518787443637848, 0.2011713832616806, -0.8199324607849121, 0.00807917583733797,...
def get _ previous _ id ( self, callback = none ) : self. eval _ js ('table. getsiblingid ( undefined, " previous " ) ; ', callback = callback )
[ 0.6902744770050049, 1.088423490524292, 0.7151585221290588, 0.9263822436332703, -0.09411502629518509, -0.8651365041732788, 1.4378132820129395, -0.41213560104370117, 0.16982275247573853, 0.1353335678577423, -0.36643075942993164, 0.4823799133300781, -0.8029621243476868, 0.7976410388946533, ...
def _ tf1 _ ( self, xmin = neg _ infinity, xmax = pos _ infinity, npars = 0, * args ) : # if not hasattr ( self,'_ wo1') : self. _ wo1 = _ wo1 _ ( self ) if not self. _ wo1 : self. _ wo1 = _ wo1 _ ( self ) # if hasattr ( self,'xmin') : xmin = max ( xmin, self. xmin ( ) ) if hasattr ( self,'xmax') : xmax = min ( xmax, s...
[ -0.7956253886222839, 0.15415449440479279, 0.5626450777053833, -0.12730106711387634, -0.21531203389167786, -0.6447860598564148, 0.4427200257778168, -0.6568189859390259, -0.458055317401886, 0.10918979346752167, -0.607353150844574, 0.6141092777252197, 0.19991973042488098, -0.31115636229515076...
def server _ directory _ path ( self ) - > str : return os. path. join ( self. _ package _ storage, " { } ~ { } ". format ( self. _ extension _ uid, self. _ extension _ version ) )
[ -0.14255622029304504, -0.999045193195343, 0.4873981475830078, 0.18811461329460144, -0.15470421314239502, 1.08888840675354, 0.6354962587356567, 0.06351441890001297, 0.7867438793182373, -0.10251346230506897, -0.18842259049415588, 0.9081999659538269, -0.592805802822113, 0.1431138664484024, ...
def links ( self ) - > querychain : assert self. registered _ links is not none, " no links registered " session = object _ session ( self ) def query ( link : registeredlink ) - >'query [ base ]': column = getattr ( link. cls, link. attribute ) q = session. query ( link. cls ) if column. property. uselist : q = q. fil...
[ -0.9506142139434814, 0.47641074657440186, 0.40722113847732544, -0.11615290492773056, 1.2901618480682373, -0.4796800911426544, 0.28535759449005127, -0.29474779963493347, 0.1878281533718109, -1.3077502250671387, -0.021291499957442284, 0.44839563965797424, -0.23123253881931305, 0.231098219752...
def deletedevicetype ( self, typeid ) : devicetypeurl = apiclient. devicetypeurl % ( self. host, typeid ) r = requests. delete ( devicetypeurl, auth = self. credentials, verify = self. verify ) status = r. status _ code if status = = 204 : self. logger. debug ( " device type was successfully deleted " ) return true eli...
[ -1.6383740901947021, 0.3031230866909027, 0.8952882289886475, 0.6751284599304199, -0.12825672328472137, -0.012896131724119186, 0.3739018440246582, -0.7446618676185608, 0.431967556476593, 0.4360693693161011, -0.28960120677948, 0.2411820888519287, -1.4727133512496948, 0.45710518956184387, 1...
def ls ( projectname ) : db = get _ db _ access ( ) if projectname not in db. projectls ( ) : print " the given project doesn't exist " else : print " list of all datasets in a project named ", projectname for name, version, timestamp in db. ls ( projectname ) : print'{ 0 : { width } } '. format ( name, width = 25 ), p...
[ -0.14595377445220947, 0.6601276993751526, 0.4428619146347046, -0.48770806193351746, -0.2385166734457016, 0.2080865353345871, -0.625777542591095, 0.19212178885936737, 0.04890812933444977, 0.03812116011977196, 0.49139928817749023, 0.8567285537719727, 0.05386233702301979, 0.8033131957054138, ...
def test _ video _ is _ related _ through _ admin ( self ) : login = self. client. login ( username ='admin ', password ='admin') self. asserttrue ( login ) response = self. client. post ('/ admin / tests / famousperson / add / ', self. post _ data ) self. assert _ ( response. status _ code in [ 200, 302 ] ) response =...
[ 0.4117438495159149, 0.9926195740699768, 0.7001608610153198, 1.1536986827850342, 0.5617730617523193, 0.9749286770820618, 0.09018518030643463, -0.2266055941581726, 0.9364905953407288, -0.35052919387817383, -0.7420660257339478, 1.2305158376693726, -0.2493465095758438, 0.8109901547431946, -0...
def get _ youtube _ video _ id ( url ) : regex _ yt = r'^ ( (? : https? : )? \ / \ / )? ( (? i ) (? : www | m ) \. )? ( (? : youtube \. com | youtu. be ) )'\ r'( \ / (? : [ \ w \ - ] + \? v = | embed \ / | v \ / )? ) ( [ \ w \ - ] + ) ( \ s + )? $'search _ result = re. search ( regex _ yt, url ) if search _ result and ...
[ -0.030181214213371277, -1.0290415287017822, 0.8411910533905029, 0.54667729139328, -0.11787581443786621, -0.21165885031223297, 0.9053404331207275, -0.04214820638298988, 0.5676965117454529, 0.1802089959383011, -0.6411123871803284, 0.6469000577926636, -0.7901017069816589, 0.7747341394424438, ...
def verify _ input ( self ) : # 1 ) make sure you don't have snptables on mm level for name, t in self. name2snptable. items ( ) : assert ( len ( t ) = = len ( t. drop _ duplicates ( subset = ['scaffold ','position'] ) ) )
[ 0.1561785340309143, 0.2642692029476166, 0.4327394664287567, 0.933605968952179, -0.057106781750917435, 1.3339653015136719, 0.48323988914489746, -0.3113158643245697, 0.35610225796699524, -0.31460070610046387, -1.2370953559875488, 0.1725030541419983, -0.053491756319999695, 0.896350085735321, ...
def memory ( self ) : # size _ of _ char = 1 # size _ of _ int = 4 size _ of _ real = 4 # size _ of _ complex = 2 * size _ of _ real # size _ of _ dielobj = size _ of _ int + 31 * size _ of _ real + 2 * 16 * size _ of _ char # size _ of _ source = 9 * size _ of _ int + 5 * size _ of _ real + 6 * 16 * size _ of _ char #...
[ -0.20940779149532318, 0.42114078998565674, 0.9723861813545227, 0.3155377209186554, -0.48454105854034424, -0.28504663705825806, 1.3524328470230103, -0.8929950594902039, 0.02336200885474682, -0.15401922166347504, -0.1636490523815155, 0.4177325665950775, -0.022112974897027016, 0.8471317291259...
def l _ matrix ( c, rho, fi, th ) : a = c / rho n1 = cos ( fi ) * sin ( th ) n2 = sin ( fi ) * sin ( th ) n3 = cos ( th ) n = np. array ( ( n1, n2, n3 ) ) a11 = a [ 0, 0 ] a12 = a [ 0, 1 ] a13 = a [ 0, 2 ] a16 = a [ 0, 5 ] a22 = a [ 1, 1 ] a23 = a [ 1, 2 ] a26 = a [ 1, 5 ] a33 = a [ 2, 2 ] a36 = a [ 2, 5 ] a44 = a [ 3,...
[ 0.5068998336791992, -0.6128062605857849, 0.998222827911377, -0.9530985355377197, 0.38963866233825684, -0.012540672905743122, 0.8890988230705261, 0.06721260398626328, -0.048579439520835876, 0.2115027904510498, -0.7328839302062988, -0.808862566947937, 0.21481166779994965, 0.11713287979364395...
def make _ exception _ message ( exc ) : if str ( exc ) : return'% s : % s'% ( exc. _ _ class _ _. _ _ name _ _, exc ) else : return'% s'% ( exc. _ _ class _ _. _ _ name _ _ )
[ -0.4326620101928711, -0.35566261410713196, 0.5491707921028137, -0.8601014018058777, -0.35059642791748047, 0.16231662034988403, -0.11800645291805267, -0.13492858409881592, 0.8024122714996338, 0.5133669972419739, 0.21742568910121918, 0.6670863628387451, 0.49257585406303406, 0.105454109609127...
def intervalsfromlines ( lines ) : for filename, filelineno, line in lines : if filelineno > = 4 : s, a, t = line. strip ( ). split ( ',') [ 1 : ] if any ( x = ='rest'for x in ( s, a, t ) ) : # this should always yield just one interval or no intervals. intv = tuple ( x for x in ( s, a, t ) if x! ='rest') assert len ( ...
[ -0.2860775887966156, -0.7974440455436707, 0.47449031472206116, 0.02308056131005287, -0.10996758192777634, 0.2167091816663742, -0.261379212141037, -0.5661277174949646, -0.49802473187446594, -0.10325101017951965, 0.28033456206321716, -0.8715540170669556, -0.021102266386151314, -0.16949656605...
def kawasaki _ sweep ( self ) : for _ in range ( self. _ x * self. _ y ) : self. kawasaki _ step ( ) return self. _ spins
[ -0.753613293170929, 0.29853343963623047, 0.3375045359134674, 0.6422241926193237, -0.4673609137535095, 0.15726639330387115, 0.533875048160553, -0.43013352155685425, -0.04700489342212677, 0.09165378659963608, -0.30672022700309753, -0.021349094808101654, 0.11720278859138489, 0.230362713336944...
def font _ size ( self, font _ size ) : self. _ font _ size = font _ size
[ 0.20522867143154144, -0.06011684238910675, -0.2227647751569748, -0.25489628314971924, -0.6216172575950623, -0.006524118594825268, 0.33026087284088135, 0.6946671605110168, 0.39888525009155273, -1.1037440299987793, -0.7257130146026611, 0.06333263963460922, 0.050942935049533844, 0.37213343381...
def device ( self, ) : return self. plm. device
[ 0.48456770181655884, -0.3229816257953644, 0.23908205330371857, 0.6959444880485535, 0.20626749098300934, 1.3193730115890503, 1.2324254512786865, -0.4842492640018463, 0.6768175363540649, -2.1753299236297607, 0.49883413314819336, 1.569799780845642, -0.4765148162841797, -1.0610271692276, -0....
def business _ activity _ type _ id ( self, business _ activity _ type _ id ) : self. _ business _ activity _ type _ id = business _ activity _ type _ id
[ 0.573707103729248, -0.9388216733932495, -0.11997809261083603, 1.2130781412124634, 0.7660667300224304, 0.635144054889679, 1.3433833122253418, 0.4980102479457855, 0.30087247490882874, 0.15318439900875092, -0.43863898515701294, 1.2433983087539673, -1.1575558185577393, 0.06172763183712959, 0...
def just _ close ( client _ handler ) : client _ handler. http _ send ( h11. connectionclosed ( ) )
[ 0.2618981897830963, -0.8749107122421265, 0.33589476346969604, -0.1069861352443695, -0.16208015382289886, 0.9010072350502014, -0.08996295183897018, -0.18311065435409546, -1.2149513959884644, -0.10787718743085861, 0.18702055513858795, -0.702870786190033, 0.08227897435426712, 0.66671782732009...
def type _ meta ( class _ or _ object, prefix = " class : " ) : if hasattr ( class _ or _ object, " _ _ mro _ _ " ) : return { prefix + c. _ _ module _ _ + ". " + c. _ _ name _ _ for c in class _ or _ object. _ _ mro _ _ if c. _ _ module _ _ not in ( " builtins ", " _ _ builtin _ _ " ) } if hasattr ( class _ or _ objec...
[ -0.2871532142162323, 0.012121569365262985, 0.8977515697479248, 0.017956480383872986, 0.06584437191486359, -0.5511160492897034, 0.30957064032554626, -0.6824160218238831, 0.2646431624889374, 0.5790345668792725, 0.12438154965639114, 0.9485752582550049, 0.9660765528678894, 0.16201311349868774,...
def _ _ neg _ _ ( self ) : res = matrix ( self. m, self. n ) for i in range ( self. m ) : for j in range ( self. n ) : val = - self [ i, j ] res [ i, j ] = val return res
[ -1.1514185667037964, -0.38038837909698486, 0.4408847391605377, -0.10287195444107056, 0.009326727129518986, 0.14927414059638977, 0.23159180581569672, 0.21825143694877625, -0.2576448917388916, -0.6756482124328613, 0.12041348963975906, -0.03161830082535744, -0.6337447762489319, 0.358558475971...
def test _ example _ input _ two _ clone _ close _ entity ( self, ucc _ smartx _ selenium _ helper, ucc _ smartx _ rest _ helper, add _ input _ two ) : input _ page = inputpage ( ucc _ smartx _ selenium _ helper, ucc _ smartx _ rest _ helper ) input _ page. table. clone _ row ( " dummy _ input _ two " ) self. assert _ ...
[ -0.14065203070640564, 0.24344933032989502, 0.714809238910675, 1.0495887994766235, -0.14941217005252838, 1.129824161529541, -0.1871541291475296, -0.614428699016571, 0.3232742249965668, 0.2824667990207672, 0.41817376017570496, 0.19421003758907318, 0.1612260639667511, 0.10155829042196274, 0...
def _ deploy _ downloaded ( self, archive _ path, basedir ) : cmd _ exec = none pkg = self. sysconfig. get _ packager ( ) if pkg = = osutil. pkg _ yum : cmd _ exec ='sudo yum localinstall enablerepo = epel - y % s'% util. escape _ shell ( archive _ path ) elif pkg = = osutil. pkg _ apt : cmd _ exec ='sudo dpkg - i % s'...
[ -0.03547344356775284, -0.7015895247459412, 0.7873515486717224, -0.5261442065238953, 0.47650760412216187, 0.506923496723175, 0.6707158088684082, 0.8300614953041077, 0.240387961268425, 0.5236129760742188, 0.23467113077640533, -0.20241643488407135, 0.19748462736606598, 0.8655612468719482, -...
def is _ locked ( self ) - > bool : return self. _ vehicle _ data. get ( " vehicle _ state ", { } ). get ( " locked " )
[ -1.1649497747421265, -0.3035636842250824, 0.38264527916908264, 0.12772279977798462, 0.8541275858879089, -0.21708282828330994, -0.8019573092460632, -0.45510703325271606, 0.5675719380378723, 0.4052550196647644, -0.14845010638237, 0.2814505696296692, -0.1798161268234253, -0.6716678738594055, ...
def size ( self, path ) : # type : ( str ) - > int raise notimplementederror
[ -0.5911719799041748, 0.5615355372428894, 0.557266891002655, -0.30925649404525757, -0.5430402755737305, 0.6325308680534363, 0.7823816537857056, 0.050154488533735275, 0.12227378785610199, -0.40074142813682556, -0.46749937534332275, -0.4321826100349426, -0.08770986646413803, -0.07781627774238...
def findprevious ( self, inputevent ) : lastquery = find. getlastquery ( ) if lastquery : lastquery. searchbackwards = true lastquery. startattop = false self. find ( lastquery ) else : orca. showfindgui ( )
[ -0.0000899381484487094, 0.4262188673019409, 0.7294142246246338, -0.5390087962150574, -0.020723354071378708, 0.1417570263147354, 1.2811558246612549, -1.0546207427978516, 0.1469210684299469, 0.05769796669483185, 0.6716593503952026, -0.16564404964447021, -1.0329468250274658, 1.161963105201721...
def write _ len ( self ) - > int : return dec _ read _ size
[ 0.2902129590511322, 0.35701197385787964, 0.46692633628845215, -0.5862002372741699, 0.9437093138694763, 0.08743999153375626, 0.9244189262390137, 0.4354323744773865, -0.32493534684181213, -0.7195165157318115, 0.2034890204668045, -0.5031992793083191, -0.039906781166791916, -0.545977771282196,...
def nco _ phase _ offs ( self ) : if self. module. device : self. _ settings. nco _ phase _ offs = self. module. device. sequencers [ self. sequencer _ number ]. get ( f " nco _ phase _ offs " ) return self. _ settings. nco _ phase _ offs
[ -0.49508926272392273, -0.3338302969932556, 0.3703881800174713, 0.33387747406959534, -0.3478710651397705, 0.9231164455413818, 0.5953806638717651, -0.18424737453460693, 0.528306245803833, 0.41734904050827026, -0.810136079788208, -0.5103400945663452, -0.8917142748832703, 0.27267956733703613, ...
def get _ outfile _ extension ( self ) : if self. _ _ separator = = ',': return'csv'elif self. _ _ separator = ='\ t': return'tsv'else : self. logger. warning ( f " don't know what to do with the extension'{ self. _ _ separator }'" ) self. logger. warning ( " defaulting to csv " ) return'csv '
[ 0.5010027289390564, 0.2272884100675583, 0.6380751132965088, 0.082856185734272, -0.7022331953048706, 0.07296115159988403, -0.8511804342269897, 0.2281530350446701, -0.2234203815460205, -0.2661161422729492, 0.5944713354110718, -0.23933136463165283, 0.020445436239242554, 0.06294123828411102, ...
def source _ image _ link ( self, image _ id ) : return self. image _ info [ image _ id ] [ " path " ]
[ -0.4388391375541687, -0.310006707906723, 0.12210541218519211, -0.5817869901657104, 0.376335084438324, 0.04513898119330406, 0.13129658997058868, 0.29606005549430847, 0.307671457529068, -0.010153754614293575, 0.19823847711086273, 0.48485618829727173, -0.12437634915113449, 0.8693298101425171,...
def guess _ style ( self ) : og = self. get _ original _ gravity ( ) fg = self. get _ final _ gravity ( ) abv = self. get _ abv ( ) ibu = self. get _ ibu ( ) ebc = self. get _ ebc ( ) return beerstyle. objects. filter ( original _ gravity _ min _ _ lte = og, original _ gravity _ max _ _ gte = og, final _ gravity _ min ...
[ -0.32929638028144836, -0.9998592734336853, 0.5951206684112549, 1.003919005393982, -0.45578673481941223, 0.06993843615055084, 0.07583439350128174, -0.14028596878051758, -1.1604570150375366, 0.1453188806772232, 0.1149519681930542, -0.07149311155080795, -0.8818359971046448, -0.116671413183212...
def connect ( cls, url, loop ) : log. info ( " connecting to cache at % s ", url ) url = urllib. parse. urlsplit ( url ) connection = yield from asyncio _ redis. connection. create ( host = url. hostname, port = url. port, db = int ( url. path. split ( " / " ) [ 1 ] ), loop = loop, encoder = asyncio _ redis. encoders. ...
[ -1.1655782461166382, 0.43363019824028015, 0.47057607769966125, -0.13469524681568146, -0.49902844429016113, -0.21802456676959991, -0.8887850046157837, -0.08235839009284973, -0.2593911588191986, 0.45592862367630005, -0.4624055325984955, -0.06833437830209732, -0.4502737820148468, 0.1874742358...
def jsoniter ( files, bulk = true ) : for f in files : doc = transformdoc ( loadjson ( f ), filename = f, bulk = bulk ) yield doc
[ -0.9024248719215393, -0.7478113174438477, 0.6479398608207703, -0.7327701449394226, -0.5089415311813354, -0.3775218725204468, -0.16880519688129425, -0.0093312319368124, -1.149923324584961, 0.39459168910980225, 0.13853217661380768, -0.41724464297294617, 0.25778520107269287, 0.203451558947563...
def makeaction ( self, action : int ) : actiontuple = self. possibleactions [ action ] self. state. setpegvalue ( actiontuple, self. playerturn ) # update boardstate # remove action from possibleactions self. possibleactions. pop ( action ) self. lastaction = self. state. getpegnode ( actiontuple ) # print ( type ( sel...
[ -1.1187465190887451, -0.42550310492515564, 0.36849096417427063, -0.7637589573860168, 0.3224993944168091, 0.11143256723880768, 0.6456210613250732, 0.7378348112106323, 0.6961711645126343, 0.4423505961894989, -0.35278454422950745, 0.2154749482870102, -0.07726700603961945, -0.7681836485862732,...
def _ _ init _ _ ( self, domain : domain ) : super ( ). _ _ init _ _ ( domain, " v1 " ) self. _ contents : optional [ contentlist ] = none self. _ content _ and _ approvals : optional [ contentandapprovalslist ] = none self. _ legacy _ contents : optional [ legacycontentlist ] = none
[ -0.42783603072166443, 0.6517292857170105, 0.23957158625125885, 0.07037360221147537, -0.4476124942302704, -0.17700831592082977, -0.5722854733467102, 0.10558898001909256, 0.23566077649593353, -0.05710212141275406, -0.47164419293403625, 0.7510608434677124, -0.0656510591506958, 0.7370532155036...
def test _ list _ integer _ max _ length _ 3 _ nistxml _ sv _ iv _ list _ integer _ max _ length _ 4 _ 3 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / list / integer / schema + instance / nistschema - sv - iv - list - integer - maxlength - 4. xsd ", instance = " nistdata / list / ...
[ -0.5039001107215881, 0.19555789232254028, 0.22377359867095947, 0.4491004943847656, -0.49082931876182556, 0.26662901043891907, -0.8664002418518066, 0.31753966212272644, 1.3313026428222656, 0.6022759079933167, -0.9316647052764893, -0.7356386184692383, -0.5764369964599609, 0.1937112659215927,...
def get _ default _ device ( ) : if torch. cuda. is _ available ( ) : return torch. device ('cuda') else : return torch. device ('cpu')
[ -0.0459948368370533, 0.5662578344345093, 0.38085904717445374, 1.3104459047317505, 0.930755615234375, 0.013874547556042671, 0.20688560605049133, 0.20740559697151184, -0.4750150144100189, -0.7195696830749512, 0.6425321698188782, 0.48390060663223267, -0.35068029165267944, 0.10883031785488129,...
def test _ atomic _ base64 _ binary _ min _ length _ 1 _ nistxml _ sv _ iv _ atomic _ base64 _ binary _ min _ length _ 2 _ 5 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / base64binary / schema + instance / nistschema - sv - iv - atomic - base64binary - minlength - 2. xsd ...
[ 0.2008005678653717, -0.6615422964096069, 0.4162786900997162, 1.1169235706329346, -0.25123512744903564, -0.052278585731983185, 0.2181699573993683, -0.5611051321029663, -0.47867849469184875, 0.2191218137741089, -0.8389755487442017, 0.47610023617744446, -0.5714306831359863, 0.4639121890068054...
def log2 ( x ) : try : if x. val < = 0 : raise valueerror ('math domain error') return variable ( x. name, np. log2 ( x. val ), { k : v * np. log2 ( np. exp ( 1 ) ) / x. val for ( k, v ) in x. der. items ( ) }, false ) except attributeerror : if x < = 0 : raise valueerror ('math domain error') return np. log2 ( x )
[ 0.20831075310707092, -0.3647577464580536, 0.46740734577178955, 0.15381976962089539, -1.489945411682129, 0.08851564675569534, -1.147284984588623, -0.8373730182647705, -0.2405296266078949, -0.5286686420440674, 0.09346311539411545, 1.0685235261917114, 0.7123715877532959, 0.027165131643414497,...
def createlist ( n ) : m = [ ] for i in range ( n ) : num = int ( input ( " enter num : " ) ) m. append ( num ) return m
[ -1.0157567262649536, -0.4350390136241913, 0.4325423538684845, 0.523610532283783, 0.17304183542728424, 0.7376227974891663, 0.27668654918670654, -0.5093916058540344, 0.09810201823711395, -0.8640857934951782, -1.1760035753250122, -0.23258666694164276, -0.22247633337974548, 0.7870129942893982,...
def pytest _ sessionfinish ( session, exitstatus ) : if exitstatus! = pytest. exitcode. tests _ failed : return failure _ rate = ( 100. 0 * session. testsfailed ) / session. testscollected if failure _ rate < = acceptable _ failure _ rate : session. exitstatus = 0
[ -0.022259199991822243, -0.3212805688381195, 0.2307668775320053, -0.15030008554458618, 0.3657386302947998, 0.6473492980003357, -0.1479424089193344, -0.3407399356365204, 0.30643975734710693, 0.5974012017250061, -0.09306278079748154, -0.3472585082054138, 0.038799747824668884, 0.17294479906558...
def transform ( self, r = none, t = none, s = 1 ) : if r is none : r = np. identity ( 3 ) if t is none : t = np. array ( [ 0, 0, 0 ] ) # compute the inverse transform r _ inv = r. t t _ inv = - 1 * np. dot ( r _ inv, t ) / s s _ inv = 1 / s for cam in self. cameras : r _ new = np. dot ( cam. r, r _ inv ) t _ new = ( np...
[ 0.03547851741313934, -0.476676344871521, 0.5570318102836609, 0.7576613426208496, 0.1512957066297531, -0.2623938322067261, 0.1754612922668457, 1.0292128324508667, 0.5484546422958374, 0.5209944844245911, -1.2649891376495361, -0.12290126830339432, 0.07426358014345169, -0.21727454662322998, ...
def tell ( self, arg : secret, valuetype : type ) - > bool :
[ -0.7572162747383118, 0.32251158356666565, 0.3013083338737488, 0.6173871755599976, 0.9877772331237793, 0.4026413559913635, -1.1437612771987915, -0.4697806239128113, -0.3017003536224365, 0.35396453738212585, -0.1747479885816574, 0.5853336453437805, -0.4690663814544678, -0.03437436372041702, ...
def compress ( src, dest, verbose, level = 6, extra _ params = [ ] ) : cmd = get _ compress _ cmd ( src, dest, verbose ) + extra _ params if verbose : printv ('compressing'+ src +'- >'+ dest ) printv ('cmd :'+''. join ( cmd ) ) abort _ if ( level < 1 or level > 9,'illegal compression level % d, should ∈ [ 1, 9 ]'% leve...
[ 0.5327895283699036, 0.5310305953025818, 0.9373975396156311, 0.45404893159866333, 0.09408193826675415, 0.07211292535066605, 0.11047402769327164, -0.27484768629074097, -0.6642091274261475, 0.22598978877067566, 0.10226611793041229, 0.5978116989135742, -0.1510365605354309, 0.5379117131233215, ...
def test _ atomic _ base64 _ binary _ max _ length _ nistxml _ sv _ iv _ atomic _ base64 _ binary _ max _ length _ 1 _ 3 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / base64binary / schema + instance / nistschema - sv - iv - atomic - base64binary - maxlength - 1. xsd ", i...
[ 0.20070022344589233, 0.13606379926204681, 0.34113767743110657, 1.315798044204712, -0.017996307462453842, 0.32683610916137695, -0.20722486078739166, 0.05118042975664139, 0.5014877319335938, 0.6081858277320862, -0.3453114628791809, -0.1866672933101654, -0.6554144620895386, -0.035208545625209...
def get _ seat _ heater _ status ( self, seat _ id : int ) - > int : seat _ id = f " seat _ heater _ { seat _ id _ map [ seat _ id ] } " if self. data _ available : return self. _ vehicle _ data. get ( " climate _ state ", { } ). get ( seat _ id ) return none
[ -0.3416425287723541, -1.1017273664474487, 0.4723849892616272, -0.3395511507987976, -0.026499301195144653, -0.4044497013092041, -1.330761432647705, -0.007176428567618132, -0.321993887424469, 0.4119051694869995, 0.022314250469207764, 0.658897876739502, 0.26280876994132996, 1.345617413520813,...
def snmp _ get ( self, snmp _ ver, system _ name, mib _ name = none, mib _ index = none, mib _ value = none, oid _ string = none, communityname = none, snmp _ timeout = 60, username = none, authkey = none, privkey = none, authprotocol = none, privprotocol = none, custom _ mib _ paths = none, load _ mib _ modules = none...
[ 0.014873857609927654, -0.8927504420280457, 0.5841757655143738, 0.16897132992744446, -0.45437735319137573, -0.9560334086418152, -0.1442919820547104, 0.029704919084906578, 0.4099160134792328, 0.3321603834629059, -0.2631045877933502, 0.20469751954078674, -1.4581578969955444, -0.51481091976165...
def billing _ city _ name ( self ) : return self. _ billing _ city _ name
[ 0.3101367950439453, -0.14403094351291656, 0.44430676102638245, 0.25248968601226807, -1.0755342245101929, 1.5469285249710083, 0.12156565487384796, 0.15569953620433807, 0.04092114791274071, -0.3729557693004608, -0.4235326945781708, -0.5148441791534424, 0.4304642975330353, 0.6785673499107361,...
def delete _ ( self, path : str, rev : int ) - > dict : return self. _ http. delete ( path, rev = rev )
[ -0.17063242197036743, -0.243181973695755, 0.6140973567962646, -0.5282090306282043, -0.7332134246826172, -0.3875066637992859, 0.016600919887423515, 0.234003946185112, -1.0664639472961426, 0.3310462236404419, -0.17557097971439362, 0.49920570850372314, -0.5959258079528809, -1.5291298627853394...
def validation _ errors ( self ) : try : self. full _ clean ( ) return { } except validationerror, e : if hasattr ( e,'message _ dict') : return e. message _ dict return { non _ field _ errors : e. messages }
[ -0.852647066116333, -0.09747409075498581, 0.36658403277397156, -0.2523880898952484, -0.8446493744850159, -0.029631497338414192, 0.04591088369488716, -0.4506341218948364, -0.33522194623947144, 0.2501838505268097, -0.8827371001243591, -0.4597511887550354, 0.04755905270576477, 1.1482803821563...
def _ dec _ value _ ref ( self ) : value _ id = backend. jheaps _ aheaphandle _ get _ value ( self. _ handle ) _ dec _ ref ( _ id _ to _ obj ( value _ id ) )
[ 0.7309803366661072, -0.07839789241552353, 0.43859001994132996, -0.8841356039047241, 0.4611791670322418, -0.19932568073272705, 0.4241516888141632, -0.28077298402786255, -0.49819856882095337, 0.4226941764354706, 1.0216166973114014, 0.787408173084259, 0.37386253476142883, 0.3503571152687073, ...
def run _ multi _ person _ detection ( self ) : peopleresult = [ ] output = self. net. forward ( ) keypoint _ id = 0 frame _ copy _ 2 = self. framecopy for part in range ( self. npoints ) : probmap = output [ 0, part, :, : ] probmap = cv2. resize ( probmap, ( frame _ copy _ 2. shape [ 1 ], frame _ copy _ 2. shape [ 0 ]...
[ -0.6053190231323242, -0.6888488531112671, 0.7566707134246826, 1.099250316619873, -0.3511043190956116, -0.5529260635375977, 0.33105888962745667, 0.20432086288928986, 0.1424911767244339, -0.6024207472801208, -0.5825584530830383, -0.48235079646110535, -0.36850738525390625, 1.2326865196228027,...
def user _ signin ( self, data ) : data _ check = self. signin _ data _ validator ( data ) existing _ user = self. check _ user _ email ( data ['email'] ) if data _ check = = true and existing _ user! = none : if logged _ user. get ('user') = = existing _ user ['username'] : api. abort ( 409, " you : { } are already lo...
[ -0.784246027469635, -0.6529129147529602, 0.901015043258667, 0.9274856448173523, -0.17926371097564697, 0.44246020913124084, -0.2620803415775299, 0.52192223072052, -0.041638702154159546, 0.3666156828403473, -0.1833985447883606, 0.6399953961372375, -0.11071164906024933, -0.5805591940879822, ...
def get _ house _ detail ( self, html ) : if " i'm not a robot " in html : raise exc. captchaerror ( url ) data = { " errors " : dict ( ) } soup = self. get _ soup ( html ) # header part, bedroom, bathroom, sqft header = soup. find ( " header ", class _ = " zsg - content - header addr " ) if header is none : raise exc....
[ -0.3431883752346039, 0.08233890682458878, 0.7927986979484558, -0.24489349126815796, -0.015741413459181786, 0.029596485197544098, 0.08434482663869858, -0.03843604028224945, -0.5306744575500488, -0.805046558380127, -0.3469081521034241, 0.397358775138855, 0.6012044548988342, 0.971385180950164...
def subtract ( self, subpath : str, permissions : list [ list [ str ] ], identities : list [ dict ], rev : int ) - > dict : payload = self. _ payload ( permissions, identities, " subtract " ) return self. _ http. patch ( [ self. segment, subpath ], payload, rev = rev )
[ -1.1018245220184326, -0.14344178140163422, 0.6978124380111694, 0.1468162089586258, 0.061474237591028214, 0.7012339234352112, 0.27034562826156616, 0.5778711438179016, -0.20727097988128662, -0.2078624814748764, -0.3474297821521759, 0.22172911465168, -1.237884759902954, -1.5671576261520386, ...
def poison _ p ( pi, _ lambda, k, m, v ) : if _ lambda < = float ( " - inf " ) and pi < = float ( " - inf " ) and m < = float ( " - inf " ) and v < = float ( " - inf " ) : p = 1. 0 elif _ lambda > 20 and m > 0 : p1 = calp ( pi, _ lambda, k ) p2 = calpnor ( m, v, k ) p = max ( p1, p2 ) else : p = calp ( pi, _ lambda, k ...
[ 0.4013427793979645, -0.31981733441352844, 0.5919947028160095, -0.30742642283439636, -0.19301263988018036, 0.024295488372445107, -0.5620166063308716, 0.5745913982391357, 0.006580409128218889, 0.6678223013877869, 0.06974183768033981, -0.7441123723983765, -0.48212867975234985, -0.059006746858...
def max ( arg0 : iterable [ any ] | any, * args : any ) - > any : if not args : if not isinstance ( arg0, iterable ) : raise typeerror ('expect more than one items to compare max') return symbolicexpression. max ( * list ( arg0 ) ) lst = list ( arg0 ) if isinstance ( arg0, iterable ) else [ arg0 ] + list ( args ) symbo...
[ -0.022041305899620056, -0.04298296943306923, 0.4600624442100525, 1.026362419128418, 0.8236877918243408, -0.44814714789390564, -0.237894669175148, 0.6560053825378418, 0.07944110780954361, 0.2835826873779297, -0.45345237851142883, 0.7294092178344727, -0.11572850495576859, 1.1965233087539673,...
def test _ atomic _ hex _ binary _ max _ length _ 2 _ nistxml _ sv _ iv _ atomic _ hex _ binary _ max _ length _ 3 _ 1 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / hexbinary / schema + instance / nistschema - sv - iv - atomic - hexbinary - maxlength - 3. xsd ", instance ...
[ 0.052389804273843765, 0.30525898933410645, 0.45067504048347473, 1.2661734819412231, -0.13505971431732178, 1.0072979927062988, -1.0795769691467285, 0.5715146064758301, 0.44218677282333374, 0.7212403416633606, -0.458676278591156, -0.32163113355636597, 0.11717942357063293, -0.1429652273654937...
def test _ vendors ( self ) : expected = dict ( ) expected ['win32'] = " ms " expected ['darwin'] = " intel " expected ['linux'] = " gnu " # only check os that are supported, custom toolchains may well work as # may other os for k in expected. keys ( ) : if sys. platform. startswith ( k ) : self. assertequal ( expected...
[ -0.6695271730422974, -0.12423688918352127, 0.2810427248477936, 0.13111533224582672, -0.12748737633228302, 0.5695031881332397, -0.02408681809902191, -0.08220376074314117, 0.31365010142326355, 0.009421152994036674, -0.47324928641319275, 0.28804531693458557, -0.24665436148643494, 1.0897589921...
def solution ( number _ unique _ partitions : int = 5000 ) - > int | none : for number _ to _ partition in range ( 1, num _ primes ) : if len ( partition ( number _ to _ partition ) ) > number _ unique _ partitions : return number _ to _ partition return none
[ -0.2314027100801468, 0.7394843697547913, 0.5011465549468994, -0.5207917094230652, -0.32525235414505005, -1.1134552955627441, 0.6357083320617676, -0.014505144208669662, 0.8683498501777649, -0.2999195456504822, -0.3309420943260193, -0.3027819097042084, -0.41544342041015625, -0.59776616096496...
def test _ atomic _ language _ max _ length _ 2 _ nistxml _ sv _ iv _ atomic _ language _ max _ length _ 3 _ 4 ( mode, save _ output, output _ format ) : assert _ bindings ( schema = " nistdata / atomic / language / schema + instance / nistschema - sv - iv - atomic - language - maxlength - 3. xsd ", instance = " nistda...
[ 0.6345037221908569, -0.06576068699359894, 0.3347945511341095, 0.5041667819023132, -0.3063277304172516, 0.3237219750881195, -0.7978178858757019, -0.042882226407527924, 0.3924174904823303, 0.7919884324073792, -0.40603676438331604, -0.2136264443397522, 0.03169770911335945, -0.3095044195652008...
def masked _ object _ name ( self, masked _ object _ name ) : self. _ masked _ object _ name = masked _ object _ name
[ 0.2007196694612503, -1.3192200660705566, 0.34780120849609375, 0.8739413022994995, -0.6033037304878235, 1.077778935432434, 1.231423020362854, -0.4730200469493866, -0.13545046746730804, 0.4961591064929962, -1.5681426525115967, -0.5053824782371521, 0.812362551689148, -0.6344795227050781, -0...
def interfaceversion ( self ) : return self. interfaceversion & 255
[ -0.5403409004211426, 0.06302011013031006, 0.37244993448257446, 0.8281221985816956, -0.3685866892337799, 1.7734557390213013, 0.8082923889160156, -0.7595285773277283, 0.2063896805047989, 0.08679351955652237, -1.0819731950759888, -0.20890535414218903, -1.0723233222961426, -0.13503088057041168...
async def download _ one ( self, session, semaphore, cc ) : try : async with semaphore : # asyncio. semaphore limits the max of concurrences image = await self. get _ flag ( session, cc ) except aiohttp. web. httpnotfound : msg ='not found'except exception as exc : raise fetchexception ( cc ) from exc else : self. save...
[ 0.35257405042648315, 0.009083208627998829, 0.5856961011886597, -0.04049953073263168, 0.16600729525089264, -0.1454651802778244, -0.25321677327156067, 0.034806959331035614, 0.6332334280014038, 0.19315974414348602, 0.22856207191944122, -0.13206657767295837, -0.1878679394721985, 1.003711938858...
def fit ( self, x, y ) : # encode all categorical cols by default if self. cols is none : self. cols = [ col for col in x if str ( x [ col ]. dtype ) = ='object'] # check columns are in x for col in self. cols : if col not in x : raise valueerror ('column \'' + col +'\'not in x') # encode each element of each column se...
[ 0.048642974346876144, -0.01763707399368286, 0.5703590512275696, 0.4396152198314667, -0.04798956587910652, -0.10377317667007446, -0.19051119685173035, -0.2729867100715637, -0.2357538938522339, -0.3787442445755005, -0.809679388999939, 0.8264545798301697, 0.39001956582069397, -0.2370084524154...
def enabled ( self ) : return self. _ get _ attribute ( self. _ sdm _ att _ map [ " enabled " ] )
[ -0.21999649703502655, -0.024115238338708878, 0.3578920364379883, 0.7282647490501404, 0.172404482960701, 0.34074294567108154, 0.45492756366729736, 0.8225968480110168, 0.901613175868988, -0.6949777007102966, -0.463753879070282, 0.12149861454963684, -0.04158219322562218, -0.3733685314655304, ...
def update ( self, json _ path ) : with open ( json _ path ) as f : params = json. load ( f ) self. _ _ dict _ _. update ( params )
[ -1.269307017326355, -1.5007390975952148, 0.3010726273059845, -1.1954468488693237, -0.5966850519180298, 0.46893998980522156, -0.3117104768753052, 0.31153640151023865, -0.47156843543052673, 1.168778896331787, -0.5607784986495972, 0.1990293264389038, 0.02170722186565399, 0.6855105757713318, ...
def get _ map _ points _ and _ kps _ for _ matches ( last _ kf _ index, matches ) : # get all map points observed in last kf _, pts _ 3d, associated _ kp _ indices, _ = map _ points. get _ by _ observation ( last _ kf _ index ) # get all map points observed by last kf # get indices of map points which were found again ...
[ -0.5716597437858582, -0.8040420413017273, 0.7285955548286438, 0.1922648549079895, -0.4101438820362091, 0.12031638622283936, 0.13358981907367706, 0.3047701120376587, 0.2313203066587448, 0.9072355031967163, 0.417924165725708, 0.16163504123687744, 0.09691926836967468, -0.3814754784107208, 0...
async def image ( self, ctx : context, url : str ) - > none : self. embeds [ ctx. author ]. embed. set _ image ( url = url ) await ctx. send ( " embeds image updated. " )
[ -0.7647966742515564, 0.2736290693283081, 0.3803042471408844, 0.4033239483833313, -0.009010061621665955, 0.71221923828125, -0.5182775259017944, 0.7425334453582764, 0.02215554565191269, 0.4125925600528717, -0.7235140800476074, 1.5221143960952759, -0.23888736963272095, 0.07200173288583755, ...
def visualize _ metric ( self, *, interpolation = none, num _ samples = num _ interpolation _ samples, write _ figs = false, points _ fraction = 1. 0, random _ seed = 0 ) : if points _ fraction < 1. 0 : if points _ fraction < 0 : raise valueerror ( f " can't visualize a fraction { points _ fraction } less than 0 " ) nu...
[ -0.136847585439682, 0.7768745422363281, 0.5716349482536316, 0.08750231564044952, -0.24208086729049683, 0.13804864883422852, 0.8933038711547852, 0.4627293348312378, 0.2036481648683548, -0.43474888801574707, 1.2690656185150146, 0.10231533646583557, 0.9128116369247437, -0.37649232149124146, ...
def create _ next _ packet ( self ) : is _ last _ packet = self. index + 8 > = len ( self. data ) data = self. data [ self. index : self. index + 8 ] channel _ number = self. channel _ number | ( ( self. seq _ num & 0x03 ) < < 5 ) | ( 0x80 if is _ last _ packet else 0x00 ) return sendbursttransferpacket ( channel _ num...
[ -0.02996145561337471, 0.8761138916015625, 0.6671202182769775, -0.25131282210350037, -0.30602580308914185, -0.26708561182022095, -0.3687768578529358, -1.4271502494812012, 1.437089443206787, -0.33872535824775696, -0.31331124901771545, 0.9681410789489746, -1.0779763460159302, -0.2254472076892...
def test _ not _ activated _ mo _ admin _ users ( self ) : # create already activated go admin goadmin = self. create _ django _ user ( self. users _ credentials ['goadmin'] ) mo = memberorganisation. objects. all ( ). first ( ) memberorganisationuser. objects. create ( user = goadmin, organization = mo, is _ admin = t...
[ -0.4889315962791443, 0.195604145526886, 0.34830576181411743, 0.04077766090631485, 0.015558384358882904, 0.7560696601867676, -0.21585460007190704, -0.6165023446083069, -0.10111629217863083, 0.1826758235692978, -0.7751398682594299, 0.9484327435493469, -0.458343505859375, 0.5788565874099731, ...
def test _ airplane _ mode _ disables _ ble ( self ) : ble _ state _ error _ msg = " bluetooth le state not ok { }. expected { } got { } " # enable ble always available ( effectively enabling bt in location ) self. scn _ ad. adb. shell ( " settings put global ble _ scan _ always _ enabled 1 " ) self. scn _ ad. droid. b...
[ -0.06542879343032837, 0.08652950823307037, 0.8114564418792725, -0.13678646087646484, -0.06080180034041405, 1.0875229835510254, -0.11547039449214935, 0.6041281223297119, -0.16044694185256958, -0.10653134435415268, -0.4132078289985657, -0.5118091106414795, -0.39269229769706726, -0.0280099045...
def check _ solver ( self, kwargs _ lens, kwargs _ ps, tolerance ) : # todo : make this part of the pointsource class ra _ image _ list, dec _ image _ list = self. multiband. image _ positions ( kwargs _ ps = kwargs _ ps, kwargs _ lens = kwargs _ lens ) source _ x, source _ y = self. lensmodel. ray _ shooting ( ra _ im...
[ -0.37779444456100464, 0.13779310882091522, 0.7639145851135254, -0.0706137865781784, 0.07425328344106674, 0.017514480277895927, -0.6153889298439026, 0.08964736014604568, 0.5556967854499817, 0.7729724645614624, -0.38088810443878174, -0.5270214676856995, -0.647858738899231, 0.3821559548377991...
def update ( self ) : # type : ( ) - > generator [ none, none, none ] old _ content = self. _ content self. _ content = { } # 1. clear the content try : yield # 2. actually update the cache self. _ last _ ts = time. time ( ) # 3. cache was updated successfully except exception : # restore old data self. _ content = old...
[ -0.6891026496887207, 0.21051178872585297, 0.6672390699386597, -0.41437003016471863, -0.8525572419166565, -0.5289480090141296, -1.4366563558578491, -0.15167006850242615, -0.5159178972244263, 0.7304955124855042, 0.07224531471729279, 0.09822003543376923, -0.17874960601329803, -0.5785300731658...
def handlewebservice ( request ) : jsonobj = json. loads ( request. body ) first _ name = jsonobj ['params'] ['walletuser'] ['firstname'] # using first _ name to test different error codes success = ( first _ name. startswith ('success') ) if success : # possible success status codes : # success, success _ account _ al...
[ 0.032263003289699554, -0.6407170295715332, 0.8655053377151489, -0.022541776299476624, -0.05597861111164093, 0.3118024170398712, 0.10751475393772125, -0.209603950381279, 0.8730204105377197, 0.3826744556427002, -0.15768025815486908, 0.31462642550468445, -0.5736473798751831, 0.848575592041015...
def get _ global _ link _ angular _ geometric _ jacobian _ function ( self, link : str, n : int = 1, numpy _ output : bool = false, ) - > cs. function : return self. make _ function ( " ja ", link, self. get _ global _ link _ angular _ geometric _ jacobian, n = n, numpy _ output = numpy _ output, )
[ -0.1971626728773117, 0.2685483992099762, 0.28728994727134705, 0.46445581316947937, -0.1798449009656906, -0.24986758828163147, 1.3067538738250732, -0.913125216960907, -0.174103245139122, -0.12009069323539734, -0.14912837743759155, 1.4680389165878296, 0.30622825026512146, -0.525717556476593,...