text stringlengths 25 2.19k | embedding listlengths 768 768 |
|---|---|
def task _ age _ limit ( self ) : return self. _ _ task _ age _ limit | [
-0.5196003913879395,
0.32095345854759216,
0.6718543171882629,
0.4642714560031891,
-0.16559109091758728,
1.9625341892242432,
1.008999228477478,
0.36435389518737793,
-0.609247088432312,
1.020946979522705,
-0.40558061003685,
0.11677105724811554,
0.592562735080719,
-0.07448502629995346,
-0.3... |
def test _ tag _ text ( ) : text ='foobarbaz binds foo.'indices = [ ] for span in ('foobarbaz ','foo') : tag _ start = " < % s > " % span tag _ close = " < / % s > " % span indices + = [ ( m. start ( ), m. start ( ) + len ( span ), span, tag _ start, tag _ close ) for m in re. finditer ( re. escape ( span ), text ) ] t... | [
0.29277685284614563,
0.09393639117479324,
0.4953291416168213,
0.09393886476755142,
-0.041267555207014084,
0.15760169923305511,
0.0647333636879921,
-0.017620349302887917,
-0.02683362364768982,
-0.16527029871940613,
-0.7192784547805786,
-0.06829724460840225,
-0.4758886992931366,
-0.271812677... |
def trigger ( lock ) : global queue while true : if len ( queue ) = = 3 : lock. acquire ( ) # consume from the queue one by one. print ( " * * * * * queue is full. pass to the models * * * * * " ) xtest, xtestlstm = consume ( ) queue. clear ( ) if len ( xtestlstm ) = = 2 : xnewlstm = np. array ( xtestlstm ) print ('lst... | [
0.006294747814536095,
-0.6588785648345947,
0.837103545665741,
0.36767154932022095,
-0.27940428256988525,
0.6452689170837402,
0.17926093935966492,
0.03781338781118393,
-0.27728188037872314,
0.07959285378456116,
-1.148603916168213,
0.9263820052146912,
0.2865602672100067,
0.21836461126804352,... |
def compute _ loss ( y, tx, w ) : e = ( y - tx. dot ( w ) ) return calculate _ mse ( e ) | [
0.3053009510040283,
-0.07464812695980072,
0.009022854268550873,
0.03291735053062439,
-0.8366655707359314,
-0.5151087641716003,
0.38325101137161255,
-0.44551023840904236,
0.13804344832897186,
0.5127492547035217,
-0.020966773852705956,
0.08801944553852081,
0.1893773376941681,
-0.179065674543... |
def _ _ init _ _ ( self, documents : list [ str ] ) : super ( ). _ _ init _ _ ( ) self. max _ depth = 0 self. json _ tree = self. create _ dict _ tree ( documents ) | [
-0.6884962916374207,
0.41590356826782227,
0.4804971516132355,
-0.14022846519947052,
-0.6698221564292908,
0.3977484107017517,
-0.44641557335853577,
0.21067841351032257,
-0.22509339451789856,
-0.009472725912928581,
-0.3486150801181793,
-0.5195071697235107,
-0.28870758414268494,
0.91943275928... |
def loadsent ( self, where = " ", what = " " ) : self. set _ defaultaddress ( ) self. account = self. kivy _ state. selected _ address | [
0.1625688076019287,
-0.22544097900390625,
0.11654780805110931,
-0.15001781284809113,
0.33595970273017883,
-1.1282919645309448,
-0.5259711742401123,
-0.12886539101600647,
0.9752953052520752,
0.5945793986320496,
-0.5571553111076355,
0.8538747429847717,
-0.465293824672699,
-0.4751148819923401... |
def pi _ bbp ( ) : # https : / / possiblywrong. wordpress. com / 2017 / 09 / 30 / digits - of - pi - and - python - generators / a, b = 0, 1 k = 0 while true : ak, bk = ( 120 * k * * 2 + 151 * k + 47, 512 * k * * 4 + 1024 * k * * 3 + 712 * k * * 2 + 194 * k + 15 ) a, b = ( 16 * a * bk + ak * b, b * bk ) digit, a = divm... | [
-0.3004806339740753,
-0.16786696016788483,
0.7652356028556824,
-0.47602877020835876,
-0.06956721097230911,
0.20521663129329681,
-0.4222634732723236,
-0.25204917788505554,
0.37236487865448,
0.008218557573854923,
-0.24154838919639587,
-0.29567381739616394,
-0.6094343066215515,
-0.56315249204... |
def detection _ error ( preds, labels ) : fpr, tpr, _ = roc _ curve ( labels, preds ) # get indexes of all tpr > = 95 % idxs = [ i for i, x in enumerate ( tpr ) if x > = 0. 95 ] # calc error for a given threshold ( i. e. idx ) _ detection _ error = lambda idx : 0. 5 * ( 1 - tpr [ idx ] ) + 0. 5 * fpr [ idx ] # return t... | [
-0.057932280004024506,
-0.8438063263893127,
0.40413638949394226,
0.13342279195785522,
-0.28350386023521423,
0.1706838607788086,
0.26886308193206787,
0.09675436466932297,
-0.6097730994224548,
0.02433563955128193,
0.16281317174434662,
0.33332929015159607,
-0.1635211557149887,
-0.268401771783... |
def destroy ( self ) : assert ( self. alive ) self. _ _ manager. refdestroyed ( self ) self. _ _ name = none self. _ _ obj = none self. _ _ manager = none | [
-0.029913658276200294,
-1.3970292806625366,
0.5166052579879761,
-0.6170011758804321,
0.5651628375053406,
0.3706313967704773,
0.33247485756874084,
-0.6083561778068542,
0.0916379764676094,
-0.4178069233894348,
-0.8818708658218384,
0.15940146148204803,
-1.0047739744186401,
0.474940687417984,
... |
def register _ extensions ( app ) : # assist. init _ app ( app, route ='/') return none | [
0.5287425518035889,
0.9212340116500854,
0.34749171137809753,
1.304465651512146,
0.7358567118644714,
0.07682880014181137,
-0.33817431330680847,
0.3071056604385376,
1.1762044429779053,
0.18708017468452454,
-1.2669336795806885,
0.08988422900438309,
0.24091149866580963,
-0.016231220215559006,
... |
def registermappingtype ( type ) : oc _ pythondictionary = lookupclass ('oc _ pythondictionary') oc _ pythondictionary. depythonifytable ( ). append ( type ) | [
-1.0637556314468384,
0.7337328195571899,
0.6816754341125488,
-0.8310744762420654,
0.49901285767555237,
-0.16739925742149353,
-0.5024105906486511,
-0.4142181873321533,
0.27872663736343384,
-0.28306713700294495,
-0.9262514114379883,
0.11989293247461319,
0.15050503611564636,
0.551908791065216... |
def _ _ str _ _ ( self ) - > str : return'node ( { } ) '. format ( self. yaml _ node ) | [
0.040658023208379745,
-1.4372389316558838,
0.31992703676223755,
-1.548763394355774,
0.1689087301492691,
-0.0452621765434742,
-0.6027011275291443,
0.8589139580726624,
-0.11944723129272461,
0.152937650680542,
0.7265494465827942,
1.6761201620101929,
0.8543345928192139,
0.3157583177089691,
0... |
def testupdatevaluesforquerieswithillegalquery ( self ) : queryitems = [ ( u'has fluiddb / about ', [ tagpathandvalue ( u'username / unknown ', 2600 ) ] ) ] valuesqueryschema = valuesqueryschema ( queryitems ) with login ( u'username ', uuid4 ( ), self. transact ) as session : deferred = self. facade. updatevaluesforqu... | [
-0.2503897547721863,
0.24595169723033905,
0.4767140746116638,
0.3936799466609955,
-0.34461599588394165,
0.7721182107925415,
-0.4911350905895233,
-0.31000468134880066,
0.14038534462451935,
-0.41592279076576233,
0.31220585107803345,
-0.41146320104599,
-0.22435623407363892,
0.8435667157173157... |
def load ( self, training _ data ) : self. training _ data = training _ data | [
-0.7758918404579163,
0.4079538583755493,
0.29385098814964294,
-0.26263949275016785,
0.022945554926991463,
0.9044563174247742,
-0.44975969195365906,
0.9617041349411011,
-0.3372746407985687,
-0.10797066241502762,
-1.0714069604873657,
0.17282406985759735,
0.14017999172210693,
-0.3125000894069... |
def _ _ len _ _ ( self ) : return sum ( [ len ( self. rocdata [ roc ] ) for roc in self. rocdata ] ) | [
0.6799980401992798,
0.01798238977789879,
0.31854599714279175,
-1.1894588470458984,
1.2322285175323486,
0.8278324604034424,
0.28083574771881104,
0.8841805458068848,
0.4015437662601471,
-0.3182543218135834,
-1.6207400560379028,
-0.6523224711418152,
0.5654284954071045,
-0.3179340958595276,
... |
def analyze ( self ) : logging. info ( " running analysis... " ) # sort instance data into layers for layer in self. _ layers : self. _ data [ layer ]. add _ expectations ( ) # run analysis on layers for noisedata in self. _ data. values ( ) : noisedata. fit _ noise _ model ( ) # collect spam coefficients for readout e... | [
0.3839244544506073,
-0.3540230691432953,
0.6489765644073486,
-0.4368983805179596,
0.9030444025993347,
-0.047978200018405914,
-0.1512148082256317,
-0.04605792462825775,
0.19363653659820557,
-0.15063036978244781,
-0.5951991677284241,
0.5967288613319397,
-0.19039605557918549,
0.94951689243316... |
def storebundle ( self, url, remotedirpath, remotestashprefix = " a ", username = none, password = none ) : try : ok = false fn = self. _ _ makebundlefilename ( self. _ _ basebundlefilename, remotestashprefix = remotestashprefix ) if url and url. startswith ( " sftp : / / " ) : sftpu = sftputil ( ) hostname = url [ 7 :... | [
-0.4445498585700989,
0.19331486523151398,
0.8060048222541809,
-0.2665680944919586,
-0.4978449046611786,
0.8146759867668152,
0.4939110279083252,
0.8366345167160034,
-0.32012253999710083,
-0.28807756304740906,
-0.7638536691665649,
-0.41954505443573,
-0.6979873776435852,
0.22466552257537842,
... |
def _ _ init _ _ ( self, amsn _ conversation, parent, contacts _ uid ) : raise notimplementederror | [
0.9154363870620728,
-0.6989127397537231,
0.33322957158088684,
0.26551440358161926,
-0.2356916218996048,
0.15349970757961273,
-0.1119941771030426,
-0.4377650022506714,
1.4519190788269043,
-0.6001741886138916,
-0.022646402940154076,
0.06420841813087463,
0.4224788546562195,
-0.000642903149127... |
def populate ( self ) - > none : response = requests. get ( self. _ _ link ) soup = beautifulsoup ( response. content,'html. parser') url _ sulfix = soup. find _ all ('script') [ - 1 ]. string. strip ( ). split ('\ n') [ 3 ]. strip ( ). split ( ) [ - 1 ]. replace ( "'", " " ). replace ( " ; ", " " ) pages = soup. find ... | [
-1.3673927783966064,
-0.059639595448970795,
0.49159201979637146,
-0.35529065132141113,
1.2433998584747314,
0.018727006390690804,
-0.5479817986488342,
0.5371466279029846,
0.6986707448959351,
-0.33933717012405396,
-0.03872452676296234,
-0.33558616042137146,
0.9922816157341003,
0.930014133453... |
def instance _ type ( self ) - > optional [ pulumi. input [ str ] ] : return pulumi. get ( self, " instance _ type " ) | [
0.5418314337730408,
0.4137004017829895,
0.4230610430240631,
0.10230772197246552,
0.9655666947364807,
1.841038703918457,
0.4095471501350403,
0.05124203488230705,
0.5660212635993958,
0.22112013399600983,
0.20022545754909515,
1.4152766466140747,
-1.046140193939209,
-0.9509137868881226,
0.21... |
def put ( self, request, pk = none ) : return response ( {'method':'put'} ) | [
-1.2512030601501465,
-0.13397589325904846,
0.27910125255584717,
-0.5269858837127686,
0.04192681610584259,
-0.21172277629375458,
0.3112906217575073,
-0.03951708599925041,
0.4353960454463959,
-0.38765767216682434,
-0.2589600682258606,
-0.7987450957298279,
-0.6477445363998413,
-0.353080689907... |
def custom _ oss _ bucket ( self ) - > optional [ pulumi. input [ str ] ] : return pulumi. get ( self, " custom _ oss _ bucket " ) | [
0.28429242968559265,
0.23373985290527344,
0.5652406811714172,
0.49279242753982544,
-0.19167231023311615,
0.9727676510810852,
0.495640367269516,
-0.3422764539718628,
0.5819640755653381,
-0.7928165197372437,
-0.03310734033584595,
0.8543910384178162,
0.6757092475891113,
-0.8269887566566467,
... |
def industry ( self, industry ) : self. _ industry = industry | [
-0.26063239574432373,
-0.33563539385795593,
-0.038223180919885635,
0.830755352973938,
0.43036630749702454,
1.4753800630569458,
0.4212125837802887,
0.6511597037315369,
-0.6643891334533691,
-0.1960526555776596,
-1.067376971244812,
-0.3616854250431061,
-0.4088604152202606,
-0.2374918758869171... |
def wrapper ( self, * args, * * kargs ) : perfwrapper. multiply ( test ) ( self, * args, * * kargs ) self. start _ replication ( self. input. clusters [ 0 ] [ 0 ], self. input. clusters [ 1 ] [ 0 ] ) self. collect _ stats ( ) | [
-0.13976560533046722,
0.130832701921463,
0.5543401837348938,
0.12752802670001984,
0.1385057270526886,
0.2972280979156494,
0.9328639507293701,
-0.29453131556510925,
0.24743172526359558,
-0.037488896399736404,
0.3719649314880371,
0.2057577222585678,
-0.10446291416883469,
-0.11353689432144165... |
def interp _ drop ( p1, p2, p3, eps ) : t = p1 [ 1 ] + ( p3 [ 1 ] - p1 [ 1 ] ) / ( p3 [ 0 ] - p1 [ 0 ] ) * ( p2 [ 0 ] - p1 [ 0 ] ) return abs ( t - p2 [ 1 ] ) < eps | [
-0.24400392174720764,
0.2531569004058838,
0.8793883323669434,
-0.49012336134910583,
-0.47152143716812134,
1.877992868423462,
-1.3181791305541992,
0.08307051658630371,
-0.8273000717163086,
1.1767785549163818,
0.2376149594783783,
-0.8577449917793274,
-0.8279998898506165,
-1.5490665435791016,... |
def user _ options ( self, string ) : if self. _ _ rop is not none : self. _ _ rop. parm ( " ar _ user _ options " ). set ( string ) | [
0.2392663061618805,
-0.2971086800098419,
0.5667281746864319,
0.44888609647750854,
0.6741941571235657,
0.6906288266181946,
1.1382040977478027,
-0.836814284324646,
0.6967988610267639,
-0.31515294313430786,
-0.2113635390996933,
0.6762353777885437,
-0.13438855111598969,
-0.9166406989097595,
... |
def _ _ load _ context _ data ( self ) : self. data = context _ registry | [
-0.3150414824485779,
0.17035162448883057,
0.26439037919044495,
-0.8007197976112366,
0.26882705092430115,
0.34117433428764343,
0.278482049703598,
-0.07375261932611465,
0.612534761428833,
0.1706998646259308,
-0.6442580223083496,
0.5882922410964966,
-0.33934321999549866,
-0.6129276752471924,
... |
def get _ bucket _ modes ( ) : result = list ( ) rop _ list = get _ rop _ list ( ) if rop _ list : parm _ template _ group = rop _ list [ 0 ]. parmtemplategroup ( ) parm _ tamplate _ name = " ar _ bucket _ scanning " parm _ template _ exist = parm _ template _ group. find ( parm _ tamplate _ name ) if parm _ template _... | [
-1.3878180980682373,
-0.3846835196018219,
0.675064742565155,
0.5444784760475159,
0.47005361318588257,
-0.13965006172657013,
-0.34102651476860046,
-0.1546698957681656,
-0.4508584141731262,
0.06539268046617508,
-0.6539687514305115,
-0.5628172159194946,
-0.28358498215675354,
0.139439433813095... |
def getalldmadata ( shape ) : arr = ( ctypes. c _ float * shape [ 0 ] * shape [ 1 ] ) ( ) size = ctypes. c _ ulong ( shape [ 0 ] * shape [ 1 ] ) pass | [
-0.41397184133529663,
0.4263432025909424,
0.6202436089515686,
-0.4425413906574249,
0.07385469228029251,
0.4790283739566803,
-0.5866004824638367,
-0.5465179085731506,
0.20536454021930695,
-0.2283007949590683,
-0.34868744015693665,
0.8538451790809631,
0.6822864413261414,
0.9649328589439392,
... |
def distancefrompoint ( nodes, pt ) : val = fn. distancefrompoint ( pt ) | [
0.7032521963119507,
-0.3922225832939148,
0.01918329857289791,
0.08952347934246063,
-0.4798227846622467,
0.40929585695266724,
-0.5695977807044983,
0.26569077372550964,
-0.5031466484069824,
0.6203194260597229,
0.21279945969581604,
0.21852484345436096,
0.07042326033115387,
-0.6239871978759766... |
def commit ( self ) - > none : self. _ _ conn. commit ( ) | [
-0.25838062167167664,
-0.5938331484794617,
0.5170889496803284,
0.5451593995094299,
1.1528769731521606,
0.6613845825195312,
0.7245151996612549,
0.9141644835472107,
-1.4294219017028809,
0.8347785472869873,
0.08650368452072144,
-0.2819902002811432,
-0.960141122341156,
-0.01086723804473877,
... |
def get _ gf _ family ( family _ name ) : results = [ ] url = " https : / / fonts. google. com / download? family = { } ". format ( family _ name. replace ( " ", " % 20 " ) ) has _ family = true if requests. get ( url ). status _ code = = 200 else false if not has _ family : yield none else : d = tempfile. mkdtemp ( ) ... | [
-0.0858604684472084,
0.05066030099987984,
0.7850928902626038,
-0.23536790907382965,
-0.015644140541553497,
-0.8568770289421082,
-0.2036522775888443,
-0.5460923314094543,
0.21111342310905457,
-0.2213137000799179,
-0.5976400375366211,
-0.5652461051940918,
0.04334146901965141,
0.7656185030937... |
def test _ replies ( self, * _ ) : parent = models. status ( content = " hi ", user = self. local _ user ) parent. save ( broadcast = false ) child = models. status ( content = " hello ", reply _ parent = parent, user = self. local _ user ) child. save ( broadcast = false ) sibling = models. review ( content = " hey ",... | [
0.4953359067440033,
-0.2543987035751343,
0.807031512260437,
-0.6647269129753113,
0.7755216360092163,
0.5162673592567444,
-0.09810783714056015,
-0.42141297459602356,
-0.09750112146139145,
-0.8588877320289612,
-0.6798346638679504,
0.16370543837547302,
-0.6227725744247437,
0.07897038757801056... |
def del _ track ( self, track _ level ) : del self. tracks [ track _ level ] | [
-0.019333146512508392,
-0.14247997105121613,
0.3486418128013611,
-0.3105842173099518,
-0.4008365869522095,
1.1245371103286743,
-0.5136998295783997,
0.3545028269290924,
-1.2599432468414307,
-0.23262332379817963,
0.28478455543518066,
0.5337597131729126,
-0.857744038105011,
0.5107001066207886... |
def add _ optional ( self, dependent, dependency ) : if dependent in self. graph and dependency in self. graph : self. add ( dependent, dependency ) | [
0.46336767077445984,
-0.10202859342098236,
0.5426271557807922,
0.6760233640670776,
-0.11012063175439835,
0.8416455388069153,
-0.42925894260406494,
-0.32750141620635986,
0.356663316488266,
0.18357910215854645,
0.00463569350540638,
0.46882641315460205,
-0.2262313961982727,
-0.014992479234933... |
def test _ log _ and _ exp ( self ) : n _ samples = self. n _ samples gs. random. seed ( 123 ) base _ point = self. beta. random _ point ( n _ samples = n _ samples, bound = 5 ) point = self. beta. random _ point ( n _ samples = n _ samples, bound = 5 ) log = self. metric. log ( point, base _ point, n _ steps = 500 ) e... | [
0.9760194420814514,
-0.3846796452999115,
0.4010426104068756,
0.3691312074661255,
0.1836376041173935,
0.7985660433769226,
0.5087903738021851,
-0.4710186719894409,
-0.31317368149757385,
-0.47945666313171387,
-0.14276222884655,
-0.41109272837638855,
-0.128143772482872,
0.2419051080942154,
0... |
def set _ attribute ( self, attribute : str, value : union [ scalartype, yaml. node ] ) - > none : start _ mark = streammark ('generated node ', 0, 0, 0 ) end _ mark = streammark ('generated node ', 0, 0, 0 ) if isinstance ( value, str ) : value _ node = yaml. scalarnode ('tag : yaml. org, 2002 : str ', value, start _ ... | [
-0.5297683477401733,
-0.17233261466026306,
0.6935886740684509,
-0.8954089879989624,
-0.19927646219730377,
-0.5091130137443542,
0.36071741580963135,
0.5708139538764954,
0.1204308494925499,
-0.073804572224617,
0.09225694090127945,
1.0753934383392334,
1.039141297340393,
0.6722809076309204,
... |
def flush _ to _ store ( self ) : self. _ store. save _ data ( self ) | [
-0.7166149616241455,
-0.06585082411766052,
0.21668173372745514,
-0.466647744178772,
0.4497603476047516,
1.2568166255950928,
0.3906356394290924,
0.009459404274821281,
0.0999840795993805,
-0.3121563792228699,
-1.071596622467041,
0.8855414390563965,
0.25859934091567993,
0.26597172021865845,
... |
def _ get _ area _ contribution ( self, migration _ matrix, effective _ area ) : contributions = migration _ matrix * effective _ area [..., np. newaxis ] return contributions | [
0.24148322641849518,
-0.49764159321784973,
0.3399374783039093,
-0.5894169807434082,
0.39574098587036133,
0.3648359477519989,
0.8949891924858093,
0.42732810974121094,
0.25514376163482666,
1.4447041749954224,
0.8822084665298462,
0.26116228103637695,
0.46245548129081726,
0.3501482605934143,
... |
def balance ( self ) : return sum ( map ( lambda x : x. amount, self. usable _ coins. values ( ) ) ) | [
-0.21903279423713684,
-0.1241060122847557,
0.5421099066734314,
-1.1618578433990479,
0.46887409687042236,
-0.22295668721199036,
-0.15768009424209595,
-0.5804818272590637,
-0.212922602891922,
0.7774186134338379,
-0.4046854078769684,
0.30874329805374146,
0.03366880118846893,
-0.11326391249895... |
def set _ cords ( self, new _ cords ) : self. _ _ y _ cord = new _ cords [ 1 ] self. _ _ x _ cord = new _ cords [ 0 ] | [
-1.024282693862915,
-1.4531993865966797,
0.4785010814666748,
-0.31845298409461975,
0.330554723739624,
-0.0817451924085617,
-0.5422900915145874,
-1.2669694423675537,
-0.48256391286849976,
0.33468300104141235,
-0.7689679861068726,
1.2550528049468994,
0.0981285572052002,
-0.03940432518720627,... |
def least _ squares ( y, tx ) : xtx = np. dot ( tx. t, tx ) xty = np. dot ( tx. t, y ) w = np. linalg. solve ( xtx, xty ) loss = compute _ mse _ loss ( y, tx, w ) return w, loss | [
0.2554492652416229,
-0.9731349349021912,
0.5798268914222717,
-0.9092516899108887,
-0.9492902159690857,
-1.1500706672668457,
-0.4791111350059509,
-0.5373114943504333,
0.3324812650680542,
0.924108624458313,
-0.28422486782073975,
0.32537856698036194,
0.6185359954833984,
-0.037611909210681915,... |
def list ( cls ) : return list ( cls. from _ server _ data ( item ) for item in pagination. unpaginate ( cls. _ path, { }, cls. _ client ) ) | [
-0.5723581910133362,
-1.076040506362915,
0.3460554778575897,
-0.5562092661857605,
0.5200157761573792,
-0.35572564601898193,
-0.6277537941932678,
0.44070228934288025,
0.3376022279262543,
-0.11205418407917023,
-0.8306328058242798,
0.36695370078086853,
0.4419095814228058,
0.3307492733001709,
... |
def smith _ minimax ( data, numwin = 1 ) : return smith _ minimax _ matrix ( data = data ) | [
-0.02110755443572998,
-0.520749032497406,
0.04594440758228302,
0.9056000709533691,
-1.004820704460144,
-0.8586037158966064,
0.012918185442686081,
-0.06785277277231216,
2.2015981674194336,
-0.3054691553115845,
-0.5934991240501404,
1.3109534978866577,
-0.9011366367340088,
-0.6593684554100037... |
def _ get _ items _ data ( self, category _ name ) : return [ self. _ dummy _ get _ item ( " % s : % s " % ( category _ name, x ) ) for x in range ( 0, 2 ) ] | [
-1.2247309684753418,
0.595360517501831,
0.48676183819770813,
-0.16871848702430725,
0.7701277136802673,
-0.14399351179599762,
-1.295106291770935,
-0.6091978549957275,
-0.7504319548606873,
0.19895607233047485,
-0.9202989339828491,
0.25511497259140015,
1.27256441116333,
-0.46418297290802,
-... |
def calc _ outcome _ score ( outcome ) : if outcome = ='human': return + 1 if outcome = ='ai': return - 1 return 0 | [
-1.2186830043792725,
-0.3433188796043396,
0.637172520160675,
0.03282838687300682,
-0.5682026743888855,
0.2324714958667755,
0.29687297344207764,
-0.08627965301275253,
-0.5544975996017456,
0.5865455269813538,
-0.0228856410831213,
-0.3474953770637512,
0.4378342032432556,
-0.39871957898139954,... |
def to _ triplets ( sampled _ hops, scale _ terms ) : triplets = [ ] triplet _ scale _ terms = [ ] for i, j in itertools. combinations ( np. arange ( 1, sampled _ hops. shape [ 1 ] ), 2 ) : triplet = sampled _ hops [ :, [ 0 ] + [ i, j ] ] triplet = triplet [ ( triplet [ :, 1 ]! = - 1 ) & ( triplet [ :, 2 ]! = - 1 ) ] t... | [
-0.3211453855037689,
-0.23407027125358582,
0.7798675298690796,
-0.05056380480527878,
-0.2670952379703522,
-0.18546155095100403,
-0.35122185945510864,
0.19150365889072418,
0.5152025818824768,
1.8712124824523926,
-0.5093710422515869,
-0.669365406036377,
0.4504072070121765,
-0.342175781726837... |
def notify ( self, event ) : if isinstance ( event, gamestartedevent ) : map = event. game. map self. place ( map. sectors [ map. startsectorindex ] ) elif isinstance ( event, charactermoverequest ) : self. move ( event. direction ) | [
0.033458441495895386,
-1.0861117839813232,
0.7053671479225159,
0.046557944267988205,
0.06409966945648193,
0.02997642382979393,
0.03710459917783737,
-0.2091853767633438,
0.8161769509315491,
-0.21434029936790466,
-0.1506759375333786,
-0.4347454905509949,
0.6895028352737427,
0.038098149001598... |
def insert ( self, word : str ) - > none : node = self. trie for w in word : if w not in node : node [ w ] = { } node = node [ w ] node ['#'] ='#'# mark this is the end of the inserted words | [
-0.30132168531417847,
1.3479468822479248,
0.4276520609855652,
-1.3938541412353516,
-0.06018597632646561,
0.33771222829818726,
0.38052836060523987,
0.8457467555999756,
-0.5637913942337036,
0.6393836736679077,
-0.7710566520690918,
-0.011442442424595356,
-1.7821857929229736,
0.859513700008392... |
def _ test _ statuses _ to _ count ( self ) - > list [ str ] : # pylint : disable = no - self - use return cast ( list [ str ], self. _ parameter ( " test _ result " ) ) | [
-0.20712913572788239,
-0.3723714053630829,
0.27421995997428894,
-0.532020092010498,
1.214064121246338,
0.31428882479667664,
0.25184839963912964,
0.4915238916873932,
0.6652002930641174,
0.2719508707523346,
-0.8665333986282349,
-0.255660742521286,
-0.05322854220867157,
0.5592506527900696,
... |
def reclassifyincident ( self, id, category, sub _ category ) : if utils. isinteger ( id ) : self. incidentbase. changeincidentclass ( int ( id ), category, sub _ category ) return | [
-0.24441085755825043,
-0.24799451231956482,
0.262408584356308,
0.3850867748260498,
0.8009301424026489,
-0.09045478701591492,
-0.20187197625637054,
0.3775399327278137,
0.07920883595943451,
-0.2792333960533142,
-0.14833661913871765,
1.4209035634994507,
0.30809924006462097,
-0.286377459764480... |
def image ( self, image ) : self. _ image = image | [
-0.9714787602424622,
0.19429531693458557,
-0.28041109442710876,
0.02675049565732479,
0.10528820008039474,
0.9716476798057556,
0.09259398281574249,
0.8450106382369995,
-0.7553514838218689,
-0.24964196979999542,
-0.049477286636829376,
0.1673218011856079,
-0.08873597532510757,
1.4589612483978... |
def add ( * args, * * kwargs ) : transactional = kwargs. pop ('transactional ', false ) queue _ name = kwargs. pop ('queue _ name ', _ default _ queue ) return task ( * args, * * kwargs ). add ( queue _ name = queue _ name, transactional = transactional ) | [
0.45965585112571716,
0.21508808434009552,
0.6654547452926636,
0.2649843096733093,
0.7225579619407654,
-0.2929365336894989,
-0.8653308153152466,
0.6454437375068665,
-0.3310534954071045,
0.9767199158668518,
-0.6554862856864929,
-0.21018710732460022,
0.28436073660850525,
0.20561783015727997,
... |
def loss _ function ( x _ hat, x, mu, log _ var ) : # 1. the reconstruction loss. # we regard the mnist as binary classification bce = f. binary _ cross _ entropy ( x _ hat, x, reduction ='sum') # 2. kl - divergence # d _ kl ( q ( z | x ) | | p ( z ) ) ; calculate in closed form as both dist. are gaussian # here we ass... | [
0.29332470893859863,
-0.13929249346256256,
0.5178776979446411,
0.04117339849472046,
-0.5756853222846985,
-0.593508243560791,
0.2276838719844818,
0.8606630563735962,
0.07810447365045547,
0.27143394947052,
-1.1802387237548828,
0.6982837915420532,
0.01254900824278593,
-0.2621350586414337,
0... |
def get _ weights ( self ) : weight _ lists = [ ] # create list for each weight w _ vector = self. weights [ 0 ] num _ weights = np. shape ( w _ vector ) for i in xrange ( num _ weights ) : weight _ lists. append ( [ ] ) # populate each list for w _ vector in self. weights : for i in xrange ( num _ weights ) : weight _... | [
-0.28591400384902954,
-0.07168975472450256,
0.40020516514778137,
0.3896130621433258,
1.0758140087127686,
0.06956566125154495,
0.19721169769763947,
0.06932730227708817,
0.1200559213757515,
0.3372478187084198,
-0.19151172041893005,
0.5129827857017517,
-0.3703438341617584,
1.0793101787567139,... |
def _ cue _ action ( self, tag ) : for action in self. _ script [ tag ] : action. execute ( self. _ cast ) | [
-1.0068289041519165,
-1.4595177173614502,
0.40110108256340027,
0.10291264951229095,
0.5681930184364319,
-0.6307008862495422,
0.498273104429245,
-0.8223844766616821,
0.059436168521642685,
1.4063211679458618,
-0.787855327129364,
1.2127808332443237,
0.2018616497516632,
1.0432530641555786,
0... |
def cond _ data _ monte _ carlo _ gen ( self, model, x, s, n ) : x _ in = x. copy ( ) cat _ va = [ ca for ca in s if ca in self. cat _ index ] # get categorical index s _ cu = [ cu for cu in s if cu not in self. cat _ index ] # get numerical index def get _ given _ data ( idx ) : val = np. array ( [ x [ idx ] ] ) val =... | [
-0.2594875693321228,
0.45574700832366943,
0.6855700016021729,
0.4472621977329254,
-0.7489305734634399,
0.23831449449062347,
-0.022611506283283234,
0.1095646545290947,
-0.3403985798358917,
0.17295463383197784,
-0.36982446908950806,
0.36622947454452515,
0.30336499214172363,
0.333668798208236... |
def geospatial _ array _ extract ( geo _ info, arr, x _ y ) : # unpack x and y coordinates x, y = x _ y # get georefference info to eventually calculate the offset : transform = geo _ info ['geotransform'] # print'transform ', transform xorigin = transform [ 0 ] yorigin = transform [ 3 ] # print'x, y origin ', xorigin,... | [
0.18822523951530457,
-0.9763506650924683,
0.6513587236404419,
-0.8077349066734314,
-0.7300369739532471,
0.33159732818603516,
-0.3669475317001343,
0.029419025406241417,
-0.024024363607168198,
0.4262966811656952,
0.3136988580226898,
0.6292266845703125,
-0.005664318799972534,
-0.0818595439195... |
def copy ( self ) : return deepcopy ( self ) # other = type ( self ) ( self. _ _ size ) # allows sub class objects to be copied into the same sub class # other. set _ value ( self. _ _ genome ) # return other | [
0.05847438797354698,
-0.7076644897460938,
1.0502220392227173,
0.5574175119400024,
-1.1043533086776733,
0.8646000623703003,
0.3197709918022156,
-1.0944099426269531,
0.40824398398399353,
-1.0363647937774658,
-0.5355953574180603,
1.1782293319702148,
-0.6755730509757996,
0.24447202682495117,
... |
def get _ context _ data ( self, * * kwargs ) : context = super ( ). get _ context _ data ( * * kwargs ) try : comp _ pk = int ( kwargs ['comp _ pk'] [ : 6 ] ) # afkappen voor de veiligheid comp = ( competitie. objects. exclude ( is _ afgesloten = true ). get ( pk = comp _ pk ) ) except ( valueerror, competitie. doesno... | [
-0.07291986793279648,
0.300978422164917,
0.8336620926856995,
0.2153603732585907,
-0.22344617545604706,
0.40569135546684265,
1.162437915802002,
-0.45695218443870544,
0.26034602522850037,
0.42128729820251465,
-0.2834527790546417,
0.26541832089424133,
-0.1084376871585846,
0.5542082190513611,
... |
def _ create _ argument _ values _ that _ must _ be _ files _ or _ dirs ( params ) : def grouper ( iterable, n, fillvalue = none ) : " collect data into fixed - length chunks or blocks " args = [ iter ( iterable ) ] * n return zip _ longest ( fillvalue = fillvalue, * args ) params = params. split ( ) regular _ files _ ... | [
-0.45229479670524597,
-0.06860910356044769,
0.7720738053321838,
-0.23001538217067719,
0.22166810929775238,
-0.25125670433044434,
1.0334241390228271,
0.1051344946026802,
-0.5162919759750366,
0.09210485219955444,
0.3395405411720276,
0.02188303880393505,
0.2762961983680725,
1.5858088731765747... |
def setuptranslator ( app ) : try : locale. setlocale ( locale. lc _ all,'' ) except locale. error : pass global lang lang = os. environ. get ('lc _ messages ','' ) if not lang : lang = os. environ. get ('lang ','' ) if not lang : try : lang = locale. getdefaultlocale ( ) [ 0 ] except valueerror : pass if not lang : la... | [
0.29267504811286926,
-0.6759915947914124,
0.8526909351348877,
-0.21388179063796997,
-0.36769869923591614,
-0.48314499855041504,
-0.026729414239525795,
0.036971818655729294,
0.08279594033956528,
-0.12388014793395996,
-0.5890676379203796,
-0.25020673871040344,
-0.4125710725784302,
0.59217697... |
def clear _ selected ( self ) : self. data = copy. deepcopy ( data. data ) self. ui. result _ label. settext ( " " ) for group in self. button _ groups : checked = group. checkedbutton ( ) if checked : group. setexclusive ( false ) checked. setchecked ( false ) group. setexclusive ( true ) | [
-0.2892661690711975,
-0.21609318256378174,
0.4803614616394043,
0.7096776366233826,
-0.24348054826259613,
0.5027101039886475,
0.5606138706207275,
-0.4971536695957184,
0.0950843021273613,
0.005244312342256308,
-0.21335601806640625,
0.8483225703239441,
-0.11132979393005371,
-0.355564773082733... |
def eval _ quick ( expr, store ) : # type : ( astnode, store ) - > value if isinstance ( expr, astnumber ) : return expr. num elif isinstance ( expr, asttrue ) : return true elif isinstance ( expr, astfalse ) : return false elif isinstance ( expr, astid ) : try : v = store [ expr. name ] check ( v, int ) # currently ca... | [
-0.3773967921733856,
-0.4400720000267029,
0.7391318082809448,
-0.035484667867422104,
-0.9659966826438904,
-0.32326143980026245,
0.5644446611404419,
-0.09401528537273407,
0.6772986054420471,
-0.3680758476257324,
0.13402485847473145,
0.10528520494699478,
-0.35702893137931824,
0.1246216669678... |
def _ _ init _ _ ( self, * args ) : _ topods. topods _ compound _ swiginit ( self, _ topods. new _ topods _ compound ( * args ) ) | [
-0.49844789505004883,
0.4971666634082794,
0.502422571182251,
0.5964316725730896,
0.14518851041793823,
0.2632213830947876,
0.5521318912506104,
-0.15998129546642303,
0.05475294217467308,
-0.28833457827568054,
-0.514938473701477,
-1.2386887073516846,
-0.2470097690820694,
0.38180476427078247,
... |
def to _ schema ( self ) : if not self. name or not self. process : raise valueerror ( " field is not registered with process " ) schema = { " name " : self. name, " type " : self. get _ field _ type ( ), } if self. required is not none : schema [ " required " ] = self. required if self. label is not none : schema [ " ... | [
-0.8332307934761047,
-0.39562803506851196,
0.49938154220581055,
-1.0869566202163696,
0.3394280970096588,
-0.10481524467468262,
-0.6679722666740417,
0.05709172785282135,
-0.10000824183225632,
0.5502733588218689,
-1.0962058305740356,
0.9943414330482483,
-0.032582368701696396,
-0.141391947865... |
def generate _ generic _ template ( specifics : dict, placeholders : dict, meta : dict = none ) - > dict : template = placeholders. copy ( ) for key, value in specifics. items ( ) : if notnull ( value ) : if key in ('source ','destination') : template [ key ] = value elif key = ='meta': if'meta'not in template. keys ( ... | [
-0.6432035565376282,
0.18855345249176025,
0.5691049098968506,
-1.212885856628418,
-1.0131349563598633,
-0.08483583480119705,
-1.7531410455703735,
1.1618735790252686,
-0.8745803236961365,
1.2461450099945068,
0.09180527925491333,
-0.29257988929748535,
0.7304234504699707,
-0.5991445183753967,... |
def plot _ default _ rate ( df, col, title, sector _ dict = none, ascending = true, bins = 25, cutoff = 0 ) : df _ grouped = df. groupby ( col ). agg ( {'loannr':'count ','default':'mean'} ) if cutoff = = 0 : if ascending : df _ plot = df _ grouped. sort _ values ('default ', ascending = ascending ) [ 1 : 6 ] df _ plot... | [
0.894346296787262,
1.243640661239624,
0.9888145327568054,
-0.5049350261688232,
0.386267751455307,
0.6821227073669434,
-0.003473436227068305,
-0.33190369606018066,
-0.40926456451416016,
0.22228547930717468,
1.2687000036239624,
0.6207822561264038,
-0.40831783413887024,
0.5339527130126953,
... |
def check _ project _ exists ( self, tenant ) : # check if project exists project = self. get _ tenant _ project ( tenant ) if project is none : # if project doesn't exist attempt to create it log. info ( " { } project not found on ams ". format ( tenant ) ) project = self. create _ tenant _ project ( tenant ) log. inf... | [
0.3079325258731842,
0.06570687144994736,
0.2130507528781891,
-0.29922378063201904,
0.7421753406524658,
0.6684456467628479,
-0.8665300607681274,
-0.6186617016792297,
0.8310548663139343,
0.8587257862091064,
1.1388431787490845,
-0.052899789065122604,
0.09672653675079346,
-0.7382494211196899,
... |
def contribute _ to _ class ( self, process, fields, name ) : # use order - preserving definition namespace ( _ _ dict _ _ ) to respect the # order of groupfield's fields definition. for field _ name in self. field _ group. _ _ dict _ _ : if field _ name. startswith ( " _ " ) : continue field = getattr ( self. field _ ... | [
-0.9477056264877319,
-0.13874125480651855,
0.5174914002418518,
-0.26564985513687134,
0.5490100383758545,
-0.1288703978061676,
0.6303213238716125,
-0.4281729459762573,
-0.7347292304039001,
-0.20721282064914703,
-1.1358342170715332,
-0.1986493021249771,
0.5124967694282532,
1.2152445316314697... |
def get _ popular _ authors ( ) : db = psycopg2. connect ( database = dbname ) c = db. cursor ( ) c. execute ( " " " select authors. name, count ( * ) as views from articles, authors, log where log. status ='200 ok'and log. path like'%'| | articles. slug | |'%'and articles. author = authors. id group by authors. name o... | [
0.2152557224035263,
0.07034025341272354,
0.4225851595401764,
0.4151507616043091,
-0.5014714002609253,
-0.9409571886062622,
0.2953125238418579,
0.6774927377700806,
-0.8060879111289978,
0.2508884370326996,
0.4703391194343567,
0.7744942903518677,
0.5796589255332947,
0.4327777326107025,
-0.3... |
def circle _ levelset ( shape, center, sqradius, scalerow = 1. 0 ) : grid = np. mgrid [ list ( map ( slice, shape ) ) ]. t - center phi = sqradius - np. sqrt ( np. sum ( ( grid. t ) * * 2, 0 ) ) u = np. float _ ( phi > 0 ) return u | [
0.31463712453842163,
-0.24455639719963074,
0.367534339427948,
-1.1935666799545288,
-0.20566236972808838,
-0.249809131026268,
-0.3165872097015381,
-0.06519731134176254,
-0.2485826313495636,
1.1305655241012573,
0.46361497044563293,
0.8739396929740906,
-0.6385032534599304,
0.20076271891593933... |
def init _ hidden ( self, batch _ size, use _ cuda = false ) : # the axes semantics are ( num _ layers, minibatch _ size, hidden _ dim ) # the tuple reprensents hidden cell and memory cell. hidden = [ autograd. variable ( torch. zeros ( self. n _ layers, batch _ size, self. hidden _ dim ), requires _ grad = false ), au... | [
0.2344682514667511,
0.23026227951049805,
0.7554249167442322,
0.5689411759376526,
0.13566738367080688,
-0.16296078264713287,
0.38373786211013794,
-0.5086097121238708,
-0.9214637279510498,
0.08857329189777374,
-0.7480881214141846,
0.176889568567276,
0.25575411319732666,
0.6479324698448181,
... |
def status _ context ( self, id : union [ status, idtype ] ) - > context : id = self. _ _ unpack _ id ( id ) return self. _ _ api _ request ('get ', f'/ api / v1 / statuses / { id } / context') | [
-0.78303462266922,
-0.3446016311645508,
0.11561838537454605,
0.28466275334358215,
-0.031046926975250244,
-0.5658198595046997,
-0.6499556303024292,
-0.5270370244979858,
1.2227119207382202,
0.04128149524331093,
-0.4036407470703125,
0.64571213722229,
0.1305825114250183,
-0.45515623688697815,
... |
def getbackground ( shape ) : arr = ( ctypes. c _ float * shape [ 0 ] * shape [ 1 ] ) ( ) size = ctypes. c _ ulong ( shape [ 0 ] * shape [ 1 ] ) pass | [
0.6257221102714539,
0.3196950852870941,
0.6765627264976501,
-0.17783762514591217,
0.5583651661872864,
-0.19734913110733032,
0.7709829807281494,
-0.6925891041755676,
0.3862047493457794,
0.5214178562164307,
-0.6883673667907715,
1.0970830917358398,
-0.34315764904022217,
0.2491481602191925,
... |
def split _ rand ( data, feature _ col, target _ col ) : xsplit = random. uniform ( min ( data [ feature _ col ] ), max ( data [ feature _ col ] ) ) target _ values = set ( data [ target _ col ] ) below = target _ values. pop ( ) above = target _ values. pop ( ) return {'split': xsplit,'below': below,'above': above } | [
-1.0143826007843018,
0.14666599035263062,
0.3315940499305725,
-0.8825186491012573,
-0.1186307743191719,
-0.14245188236236572,
-0.05247250944375992,
0.39682409167289734,
-0.7958506345748901,
0.5768561363220215,
-0.6071056723594666,
0.6408090591430664,
0.4795728921890259,
-0.939972460269928,... |
def _ unmarshaled _ dispatch ( self, request, dispatch _ method = none ) : if not request : # invalid request dictionary fault = fault ( - 32600,'request invalid - - no request data. ', config = self. json _ config ) _ logger. warning ( " invalid request : % s ", fault ) return fault. dump ( ) if isinstance ( request, ... | [
-0.5984178781509399,
0.11979145556688309,
0.8007066249847412,
0.2677820026874542,
-0.004122697748243809,
-0.6201291680335999,
-0.35922425985336304,
-0.11684887856245041,
1.08406400680542,
-0.5482457876205444,
-0.10039380937814713,
-0.5656641721725464,
0.3143008053302765,
0.9214662313461304... |
def add _ styles ( self, config, stylesheet _ type, base _ url ) : styles _ array = [ ] for stylesheet in self. config [ stylesheet _ type ] : stylesheet _ path = stylesheet ['path'] stylesheet _ url = base _ url + stylesheet _ path # check for ( optional ) media types. if'media _ attr'not in stylesheet or \ not styles... | [
-1.0480663776397705,
-0.9339392185211182,
0.4643988609313965,
0.004711551126092672,
0.7282670736312866,
0.5212732553482056,
-1.0523855686187744,
0.18789878487586975,
-0.0924152061343193,
0.4741806089878082,
0.36825016140937805,
-0.07879139482975006,
0.24393682181835175,
0.9487769603729248,... |
def security _ group _ id ( self ) - > optional [ pulumi. input [ str ] ] : return pulumi. get ( self, " security _ group _ id " ) | [
1.2123935222625732,
0.5544400215148926,
0.12781892716884613,
0.6098710894584656,
0.42306435108184814,
0.8720155358314514,
0.14764352142810822,
0.11583761125802994,
0.9640660881996155,
-0.4956502318382263,
-0.03956702724099159,
0.8782267570495605,
-0.7801914215087891,
-0.14232304692268372,
... |
def parse _ hgvs _ name ( hgvs _ name, genome, transcript = none, get _ transcript = lambda name : none, flank _ length = 30, normalize = true, lazy = false ) : hgvs = hgvsname ( hgvs _ name ) # determine transcript. if hgvs. kind = ='c'and not transcript : if '.'in hgvs. transcript and lazy : hgvs. transcript, version... | [
-0.0475015826523304,
-0.6009697914123535,
0.8344413638114929,
-0.3034902513027191,
-0.8626672625541687,
-0.3432888090610504,
-0.23894961178302765,
0.0790618509054184,
-0.5526248812675476,
0.7798800468444824,
-0.447868674993515,
0.6013475656509399,
-0.10281221568584442,
-0.3383098244667053,... |
def gaussian _ rbf _ features ( x, centers, widths ) : x, centers, widths = map ( np. asarray, ( x, centers, widths ) ) if widths. ndim = = 1 : widths = widths [ :, np. newaxis ] return np. exp ( - 0. 5 * ( ( x [ :, np. newaxis, : ] - centers ) / widths ) * * 2 ). sum ( - 1 ) | [
-0.07422742992639542,
-0.308039128780365,
0.4757600724697113,
-0.010114078409969807,
0.14869384467601776,
-0.5877432823181152,
0.18328815698623657,
0.4345529079437256,
0.9952049851417542,
0.15348589420318604,
-0.5039385557174683,
0.784360408782959,
-0.9501263499259949,
-0.14693774282932281... |
def _ insert _ function _ dec _ header ( line _ num ) : current _ buffer = vim. current. buffer line = current _ buffer [ line _ num - 1 ] # check for multi - line definitions temp _ line _ num = line _ num + 1 while line. endswith ( ", " ) : line + = " " + current _ buffer [ temp _ line _ num - 1 ]. lstrip ( ) temp _ ... | [
0.5267889499664307,
-0.3643513321876526,
1.229447364807129,
-0.39720800518989563,
0.22154247760772705,
-0.9253596067428589,
-0.09126170724630356,
0.49090126156806946,
-0.7323012351989746,
-0.07863005250692368,
-0.06864441186189651,
0.00851021520793438,
-0.035572126507759094,
0.008953230455... |
def sort ( container : sequence [ _ tt ] ) - > sequence [ _ tt ] : if len ( container ) < = 1 : return container else : x = random. choice ( container ) left = [ i for i in container if i < x ] mid = [ x ] * container. count ( x ) right = [ i for i in container if i > x ] return sort ( left ) + mid + sort ( right ) | [
-0.4162002503871918,
0.3843505084514618,
0.6057690382003784,
-0.1400272101163864,
-0.4089124798774719,
-0.08958709239959717,
0.42975887656211853,
-1.0358072519302368,
0.8816162347793579,
0.09302294254302979,
-0.6688805818557739,
-0.4404609799385071,
-0.18045198917388916,
0.6795793771743774... |
def apply _ rules ( row ) : if prefbias > suffbias : lemma = list ( reversed ( row [ 3 ] ) ) form = list ( reversed ( row [ 0 ] ) ) else : lemma = row [ 3 ] form = row [ 0 ] msd = row [ 2 ] if msd not in allprules and msd not in allsrules : return lemma = = form # haven't seen this inflection, so bail out base = [ " < ... | [
-0.18171322345733643,
0.016364077106118202,
0.7755268812179565,
0.029620161280035973,
0.07188265770673752,
-0.04734211787581444,
-0.777564525604248,
0.9227856993675232,
0.25683486461639404,
-0.01613691635429859,
0.058902252465486526,
0.2271217554807663,
-0.2236737161874771,
0.5907660126686... |
def dlldump ( self, dump _ dir = none, pid = none, base = none, regex = none ) : log. debug ( " executing volatility dlldump plugin on " " { 0 } ". format ( self. memdump ) ) results = [ ] self. _ _ config ( ) if dump _ dir : self. config. dump _ dir = dump _ dir cuckoo _ utils. create _ dir _ safe ( dump _ dir ) if pi... | [
-0.7168918251991272,
-0.4175008535385132,
0.7069235444068909,
-1.0306419134140015,
0.3133908212184906,
-0.6904401183128357,
-0.4947354793548584,
0.3027530908584595,
0.9228055477142334,
0.32542452216148376,
-0.2469087392091751,
0.7535513639450073,
-0.28846991062164307,
0.8484960198402405,
... |
def leap _ check ( x, y ) : # m = 0 if x % 4 = = 0 : if x % 100 = = 0 : if x % 400 = = 0 : m = mon _ leap [ y - 1 ] # leap = 1 # year is leap, follow mon _ leap else : m = mon _ days [ y - 1 ] # leap = 0 # leap is false, follow mon _ days else : m = mon _ leap [ y - 1 ] # leap = 1 # year is leap, follow mon _ leap else... | [
-0.23506319522857666,
-0.17709968984127045,
0.8170803189277649,
-0.2108728587627411,
-1.28683340549469,
0.8489899039268494,
-1.3551040887832642,
-1.1153644323349,
0.9566966891288757,
-0.16316698491573334,
1.0368026494979858,
1.0575252771377563,
-0.33139652013778687,
0.801655113697052,
0.... |
def test _ prompt _ consent _ parameter ( self, render _ patched ) : data = {'client _ id': self. client. client _ id,'response _ type': next ( self. client. response _ type _ values ( ) ),'redirect _ uri': self. client. default _ redirect _ uri,'scope':'openid email ','state': self. state,'prompt':'consent'} response ... | [
-0.5228869318962097,
-0.11823233962059021,
0.62711501121521,
0.053947869688272476,
0.4676412045955658,
0.3725300133228302,
0.5819934010505676,
-0.615954577922821,
0.7829731106758118,
0.02703797072172165,
-0.11282482743263245,
0.15227025747299194,
-0.21596816182136536,
-0.45508068799972534,... |
def name ( self, name ) : if self. _ configuration. client _ side _ validation and name is none : raise valueerror ( " invalid value for ` name `, must not be ` none ` " ) # noqa : e501 self. _ name = name | [
-0.08319582790136337,
0.15410380065441132,
0.11321046948432922,
-0.024616101756691933,
-0.5617722868919373,
0.49688851833343506,
0.4797031879425049,
-0.14567981660366058,
-0.14935068786144257,
1.038893699645996,
-1.1183747053146362,
-0.7430025339126587,
-0.17780815064907074,
0.411757290363... |
def is _ leaf ( self ) : return self. _ children is none | [
0.5157303214073181,
-0.35512620210647583,
0.49336984753608704,
0.1272791475057602,
0.7588321566581726,
0.6494163274765015,
-0.2792647182941437,
0.009693089872598648,
0.8552544116973877,
-1.0913574695587158,
-0.9258602261543274,
-0.06266799569129944,
-0.3143477141857147,
0.3691002428531647,... |
def _ get _ path ( self ) : path = fd. askopenfilename ( filetypes = ( ( " tsv files ", " *. tsv " ), ) ) is _ save = self. service. save _ path _ for _ file ( path = path ) if is _ save : self. upload _ title. configure ( text ='data has been uploaded') self. service. get _ data ( ) else : self. upload _ title. config... | [
-0.21125908195972443,
0.23120713233947754,
0.49981382489204407,
0.6428210735321045,
0.30695968866348267,
0.13364504277706146,
0.1633298546075821,
0.14151889085769653,
-1.0360609292984009,
0.07062773406505585,
0.38245680928230286,
-0.0187392495572567,
0.17937994003295898,
0.1287179738283157... |
def test _ list _ evaluaciones _ alumno _ curso _ admin ( self ) : self. client. force _ authenticate ( user = self. user _ admin ) curso _ 1 = self. curso _ 1. id anio _ lectivo _ 1 = self. anio _ lectivo _ 1. id evaluacion = self. evaluacion _ 1. id response = self. client. get ( f " / api / alumnos / curso / list / ... | [
0.7702348828315735,
-0.4966413974761963,
0.4228513836860657,
-0.21487049758434296,
0.4420725703239441,
0.9603474736213684,
-0.586999773979187,
0.26842591166496277,
-0.1070556566119194,
0.3285820484161377,
-0.23420880734920502,
1.5660173892974854,
-0.16319797933101654,
0.2838844656944275,
... |
def rehacer _ modificacion ( self ) : try : ruta _ ultima _ cancion, ultima _ accion = self. acciones _ deshechas. desapilar ( ) if ultima _ accion = = self. agregada : self. agregar _ cancion _ sin _ guardar ( ruta _ ultima _ cancion ) self. acciones _ tomadas. apilar ( ( ruta _ ultima _ cancion, self. agregada ) ) re... | [
-1.1088122129440308,
0.317096084356308,
0.9067133069038391,
0.6690773963928223,
0.5259997248649597,
-0.4398249089717865,
0.484346866607666,
0.5298390984535217,
0.5345439910888672,
0.5801591873168945,
0.2126827836036682,
-0.4515756070613861,
-0.5098336338996887,
0.1254379153251648,
1.5741... |
def _ run _ openmoc ( self ) : # run an eigenvalue calculation super ( plotspatialfluxestestharness, self ). _ run _ openmoc ( ) # specify energy groups for which to plot the spatial flux energy _ groups = [ 1, 3, 5, 7 ] # create a series of matplotlib figures / pil images for different # plotting parameters and append... | [
0.6003056168556213,
0.28531602025032043,
0.7216846346855164,
0.20949681103229523,
0.05895964056253433,
0.18035399913787842,
0.8744155764579773,
-0.07643593102693558,
-0.34722450375556946,
-0.9521211981773376,
0.24434328079223633,
0.21900880336761475,
0.48947304487228394,
0.6620748043060303... |
def getconnections ( self ) : return self. connectedto # return self. connectedto. keys ( ) | [
-1.7544499635696411,
-1.1148494482040405,
0.5493587851524353,
-0.02869371511042118,
0.1483173370361328,
-0.2500840425491333,
-0.7716646194458008,
-0.45722827315330505,
-0.5787862539291382,
0.09333718568086624,
-0.5724077224731445,
-0.8659538626670837,
-0.5237937569618225,
-0.03408754989504... |
def split _ expression ( expression, relation ) : sp _ exp = expression. split ( relation ) expr _ before = sp _ exp [ 0 ] expr _ after = sp _ exp [ 1 ] return expr _ before, expr _ after | [
-0.060545388609170914,
-0.33039557933807373,
0.5234801769256592,
-0.2570279538631439,
-0.2882702648639679,
-0.5065280795097351,
-0.11076556146144867,
1.3734816312789917,
0.4441053569316864,
0.548454225063324,
-0.32551947236061096,
0.5869478583335876,
-0.5486702919006348,
-0.955524563789367... |
def get _ name ( self ) : return self. name | [
-0.6760267615318298,
-1.3101738691329956,
0.39598309993743896,
-0.12174882739782333,
-0.4941951334476471,
0.554806649684906,
0.11127790808677673,
-0.3621368408203125,
-0.242742657661438,
0.14369943737983704,
-0.47305575013160706,
0.2884862720966339,
0.10772591084241867,
-0.2245897203683853... |
def print _ docker _ status ( self ) : if self. _ host _ type! = " docker " : logger. info ( " the host type is not docker " ) return print ( " - - - - - - docker status of all active workers - - - - - - " ) for wk in self. _ cur _ cluster. workers ( ) : print ( " worker ip : { } ". format ( wk. ip ( ) ) ) ret = wk. ru... | [
-0.15078707039356232,
-1.1444097757339478,
0.9388976693153381,
0.36776572465896606,
0.009446817450225353,
0.3146485388278961,
0.45803284645080566,
0.5285845994949341,
-0.8450255990028381,
-0.19282908737659454,
-0.32833898067474365,
1.1894636154174805,
0.05968291684985161,
1.045790553092956... |
def coaddm5analysis ( path, dbfile, runname, slair = false, wfdandddfs = false, nodithonly = false, bestdithonly = false, somedithonly = false, specifieddith = none, nside = 128, filterband ='r ', includedustextinction = false, saveunmaskedcoadddata = false, pixelradiusformasking = 5, cutoffyear = none, plotskymap = tr... | [
0.1275852620601654,
0.31035202741622925,
0.8526523113250732,
0.01096406951546669,
-1.0779321193695068,
0.22881777584552765,
0.9346120953559875,
0.22017474472522736,
0.029859792441129684,
0.23994341492652893,
0.8683407306671143,
0.12190902978181839,
0.13067938387393951,
1.0714116096496582,
... |
def blur _ gaussian ( im : np. ndarray, fac : float ) - > np. ndarray : fac = np. interp ( fac, [ 0. 0, 1. 0 ], [ 0. 0, 0. 1 ] ) dim _ max = max ( im. shape [ : 2 ] ) k = max ( 1, int ( fac * dim _ max ) ) k = k if k % 2 else k + 1 # dst = cv. blur ( src, ( i, i ) ) im _ dst = cv. gaussianblur ( im, ( k, k ), 0 ) retur... | [
0.2519191801548004,
0.07018484175205231,
0.6662426590919495,
0.9751589298248291,
-0.24661196768283844,
0.4989006221294403,
0.8848729729652405,
-0.3514017164707184,
0.4178764224052429,
0.322841078042984,
0.5644159913063049,
0.9864834547042847,
0.8515042066574097,
-0.2508007287979126,
0.42... |
def get _ filters ( ) : print ('hello! let \'s explore some us bikeshare data!') print ('-'* 45 ) # get user input for city ( chicago, new york city, washington ). hint : use a while loop to handle invalid inputs while true : print ('\ nfor which city would you like to see the data?') city = input ('please enter any on... | [
0.05043364688754082,
0.5032235980033875,
1.0031609535217285,
0.1484166979789734,
-0.8359701633453369,
0.8300173282623291,
0.3428150415420532,
-0.4159528613090515,
-0.6347697973251343,
-0.3517308235168457,
-0.17812834680080414,
1.389780044555664,
-0.7312217950820923,
0.7815724015235901,
0... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.