query
stringlengths
10
3.6k
document
stringlengths
19
61.4k
metadata
dict
negatives
listlengths
0
101
negative_scores
listlengths
0
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Create an empty table in the DynamoDB if the table does not exist.
def nar2(GTA_: str, **uuvw) -> str: try: x0hE = iVGz.client('dynamodb', **uuvw) _hkX = x0hE.describe_table(TableName=GTA_) RKD7.info('Table %s exists', GTA_) return _hkX['Table']['TableArn'] except Exception as err: pass o8Kj = [{'AttributeName': 'Target', 'AttributeT...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def A5X0(YKHO) -> slhS.Table:\n tyNF = YKHO.client.create_table(table=slhS.Table(table_ref=YKHO._table_ref, schema=Ve9k), exists_ok=True)\n G9jH.info('table %s already exists.', tyNF.full_table_id)\n return tyNF", "def OTTF(YKHO):\n xDcj = \"SELECT name FROM sqlite_master WHERE type='table'\"\n di...
[ "0.78332", "0.7352531", "0.71206164", "0.70685697", "0.70066714", "0.69612384", "0.6952425", "0.69356537", "0.6883996", "0.6879083", "0.682278", "0.68166715", "0.6801798", "0.6799639", "0.6779128", "0.67211145", "0.6687819", "0.66622716", "0.66529375", "0.6627198", "0.6612539...
0.64774466
27
Check if the DynamoDB table name and ARN match the one this worker can access to.
def I897(GTA_: str, pLtd: str, **uuvw) -> bool: try: x0hE = iVGz.client('dynamodb', **uuvw) _hkX = x0hE.describe_table(TableName=GTA_) return pLtd == _hkX['Table']['TableArn'] except Exception: return False
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def DbzL(YKHO, p9bx: 'Database', tyNF: 'Table') -> bool:\n try:\n YKHO.raise_for_access(database=p9bx, table=tyNF)\n except O7rH:\n return False\n return True", "def oGgH(k9X4, pmON):\n KAOR = Zq4h(pmON)\n Fa0T = [YRbF for YRbF, r845 in KAOR.actual_list.items()]\n return True if k...
[ "0.6648616", "0.664646", "0.6236491", "0.61339897", "0.6014876", "0.59953076", "0.59050703", "0.590082", "0.5884405", "0.5883849", "0.58784", "0.5847266", "0.58449024", "0.5821709", "0.58160293", "0.5789704", "0.5788584", "0.578787", "0.57801837", "0.57801837", "0.5772849", ...
0.75424033
0
Creates a node_travel_data_dataset from a report file that contains node to node data.
def BwPm(YKHO, lO87, TfyK, g3dZ, GI1W): bo34.start_block('Getting node matricies from emme2') try: A8Pr = YKHO.get_node_travel_data_from_emme2(g3dZ, GI1W) finally: bo34.end_block() bo34.start_block('Writing data to cache') try: sWyl = lO87 + 1 odWf = zwpu().get_flt_st...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def sxOh():\n gnPz.make_dataset_dmoz(n_items=600, seed=0, category_parent='Top/Recreation/Travel', rawdir=Hy7s.environ['DMOZ_TRAVEL_RAW'], webdir=Hy7s.environ['DMOZ_TRAVEL_WEB'])", "def zb_n(YKHO):\n YKHO.node_df = _ger.remove_colons(rLdf.read_csv(YKHO.node_file, dtype=str))", "def aGny(YKHO, WJHQ):\n ...
[ "0.6267398", "0.607452", "0.5434764", "0.5416076", "0.5387189", "0.5334922", "0.53113014", "0.5284332", "0.52575076", "0.52191347", "0.52120376", "0.5207968", "0.51628476", "0.51583487", "0.5153315", "0.5151687", "0.51512146", "0.5121939", "0.51149356", "0.5089264", "0.508576...
0.0
-1
Convert string to lowercase and split into words (ignoring punctuation), returning list of words.
def wr3U(vIwR): return ZbWC.findall('([-0-9a-zA-Z_:.]+)', vIwR.lower())
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def wr3U(vIwR, cKm3=False):\n import re\n V22M = re.findall(\"([\\\\w'-+]+)\", vIwR)\n if cKm3 == True:\n _xFn = []\n for GIN8 in V22M:\n _xFn.append(GIN8.lower())\n V22M = _xFn\n return V22M", "def vGQR(l5Ny):\n wAJt = ZbWC.compile('\\\\W*')\n return [KCHu.lower...
[ "0.8042038", "0.7974325", "0.776855", "0.7766142", "0.77363193", "0.7717386", "0.76837456", "0.76837456", "0.76465976", "0.7609536", "0.7550939", "0.75411433", "0.7528677", "0.74150276", "0.7347552", "0.73395747", "0.73383474", "0.7327019", "0.72916055", "0.7281678", "0.72636...
0.6570511
80
Iterate through given lines iterator (file object or list of lines) and return ngram frequencies. The return value is a dict mapping the length of the ngram to a collections.Counter object of ngram tuple and number of times that ngram occurred. Returned dict includes ngrams of length min_length to max_length. Use this ...
def Y908(Nqlg, Lx0h=1, BcCR=4): def xKhZ(): jvSB = tuple(gGq6) for u54L in Fbjb: if len(jvSB) >= u54L: pCSA[u54L][jvSB[:u54L]] += 1 def hji6(): if not Nqlg: return False if isinstance(Nqlg[0], str): return False elif h...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Y908(Nqlg, Lx0h=2, BcCR=4):\n Fbjb = range(Lx0h, BcCR + 1)\n pCSA = {u54L: g760.Counter() for u54L in Fbjb}\n gGq6 = g760.deque(maxlen=BcCR)\n\n def xKhZ():\n jvSB = tuple(gGq6)\n for u54L in Fbjb:\n if len(jvSB) >= u54L:\n pCSA[u54L][jvSB[:u54L]] += 1\n f...
[ "0.7766693", "0.76237303", "0.7406177", "0.69358426", "0.68730116", "0.6734156", "0.67326486", "0.6726416", "0.6669463", "0.6612568", "0.6573241", "0.65125835", "0.6494842", "0.6393322", "0.63679165", "0.6347384", "0.63325644", "0.6315713", "0.62834036", "0.6272345", "0.62684...
0.7685103
1
Test writing a worksheet with a blank cell with A1 notation.
def q7TS(YKHO): YKHO.maxDiff = None Ga6V = kJm3() zxr_ = AFus() zxr_._set_filehandle(Ga6V) ZAgS = rbmW({'xf_index': 1}) zxr_.write_blank('A1', None) zxr_.write_blank('C2', None, ZAgS) zxr_.select() zxr_._assemble_xml_file() kLQb = tkvO('\n <?xml version="1.0" encod...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def oJUB(rrBf='class'):\n return zxr_.Worksheet()", "def KE9K():\n YPa5 = pMBr.Workbook()\n VTcd = YPa5.active\n return (YPa5, VTcd)", "def UeE1(hFFO):\n hFFO.write_data('example data')\n assert hFFO.get_cell(hFFO.get_last_row(), 1) == 'example data'", "def kJP6(Emd4):\n return hRvT", ...
[ "0.65056956", "0.6023879", "0.592566", "0.5538215", "0.541661", "0.53880835", "0.53878427", "0.53778607", "0.5357264", "0.5328206", "0.53248656", "0.5322365", "0.53071344", "0.53056407", "0.52638376", "0.52209544", "0.5220292", "0.5205103", "0.51705444", "0.51509935", "0.5115...
0.5693859
3
Apply ``pattern`` (contains no path elements) to the literal directory`` in dirname``. If pattern=='', this will filter for directories. This is a special case that happens when the user's glob expression ends with a slash (in which case we only want directories). It simpler
def CHqK(YKHO, TLI7, mXDZ, lok8): if isinstance(mXDZ, jKi7.text_type) and (not isinstance(TLI7, jKi7.text_type)): TLI7 = jKi7.u(TLI7, HwRy.getfilesystemencoding() or HwRy.getdefaultencoding()) if not dZ9B(mXDZ): if mXDZ == '': if YKHO.isdir(TLI7): return [(mXDZ, ())] ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def jijp(YKHO, TLI7, mXDZ):\n ZWCE = YKHO.listdir(TLI7)\n if mXDZ[0] != '.':\n ZWCE = filter(lambda WKvO: WKvO[0] != '.', ZWCE)\n return jlVJ.filter(ZWCE, mXDZ)", "def qDHI(YKHO, TLI7, Gaxu=jlVJ.fnmatch):\n return all((not Gaxu(TLI7, lvR3) for lvR3 in YKHO.DIRNAMES_IGNORE))", "def Zjko(mXDZ,...
[ "0.7031971", "0.63563937", "0.63221604", "0.6114686", "0.60291314", "0.586126", "0.56175154", "0.5606534", "0.55571413", "0.55419594", "0.55189985", "0.5481502", "0.54762524", "0.54157746", "0.5388686", "0.5349208", "0.53300697", "0.5323755", "0.5303234", "0.52869177", "0.526...
0.7079843
0
Make an absolute path relative to the project's settings module, which would usually be the project directory.
def uWKT(WQbV): Fg_i = Hy7s.path.dirname(Hy7s.path.normpath(HwRy.modules[gCuF.SETTINGS_MODULE].__file__)) XP5J = Hy7s.path.normpath(WQbV) return XP5J[len(Hy7s.path.commonprefix([Fg_i, XP5J])):]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Wbb_(XNWQ):\n return Hy7s.path.join(Odyn, XNWQ)", "def ulDt():\n tk5Y = xAKo\n if Hy7s.path.islink(tk5Y):\n tk5Y = Hy7s.path.realpath(tk5Y)\n AGPF = Hy7s.path.dirname(Hy7s.path.abspath(tk5Y))\n return Hy7s.path.normpath(Hy7s.path.join(AGPF, '../settings/'))", "def TdjZ():\n return ...
[ "0.6994914", "0.6861789", "0.68206686", "0.67363554", "0.6729323", "0.66554594", "0.65929604", "0.64809805", "0.64700395", "0.6413893", "0.6410303", "0.6409275", "0.6390963", "0.63387305", "0.63240653", "0.63193893", "0.63016665", "0.6249275", "0.62399876", "0.62395746", "0.6...
0.66545975
6
Given user_id, return the associated User object.
def GYAu(uJjO): return NCls.session.query(mv1M).filter(mv1M.id.__eq__(uJjO)).first()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def bt8D(uJjO):\n return mv1M.query.get(uJjO)", "def NMoC(YKHO, uJjO):\n return mv1M.get(uJjO)", "def B9ST(uJjO):\n return YJv1.query.filter_by(id=uJjO).first()", "def TKWP(YKHO, uJjO):\n mv1M = egNl()\n try:\n return mv1M.objects.get(pk=uJjO)\n except mv1M.DoesNotExist:\n ret...
[ "0.8471028", "0.8392188", "0.8368705", "0.82841843", "0.8246674", "0.82437944", "0.82432073", "0.8225815", "0.8178416", "0.8177145", "0.8177145", "0.8150649", "0.8150649", "0.8150649", "0.8150649", "0.7942101", "0.79078114", "0.7870632", "0.7846108", "0.78183013", "0.77843064...
0.0
-1
Computes an initial RNN `cell` state from an embedding, `z`.
def wgmL(VmPb, epBp, Ep8u, mWFP=None): cCgs = Mg7i.flatten(VmPb.state_size) return Mg7i.pack_sequence_as(VmPb.zero_state(batch_size=Ep8u, dtype=ZylS.float32), ZylS.split(ZylS.layers.dense(epBp, sum(cCgs), activation=ZylS.tanh, kernel_initializer=ZylS.random_normal_initializer(stddev=0.001), name=mWFP), cCgs, ax...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def wgmL(VmPb, epBp, mWFP=None):\n cCgs = pf_1.flatten(VmPb.state_size)\n return pf_1.pack_sequence_as(VmPb.zero_state(batch_size=epBp.shape[0], dtype=ZylS.float32), ZylS.split(ZylS.layers.dense(epBp, sum(cCgs), activation=ZylS.tanh, kernel_initializer=ZylS.random_normal_initializer(stddev=0.001), name=mWFP)...
[ "0.7778159", "0.66782403", "0.6639687", "0.6323766", "0.62861586", "0.62827575", "0.6076215", "0.6035616", "0.58656746", "0.5842477", "0.58285147", "0.57762134", "0.5755695", "0.5748854", "0.5725769", "0.5723767", "0.5715377", "0.5713987", "0.5699344", "0.5676472", "0.565383"...
0.7557485
1
Returns `sampling_probabiliy` if `sampling schedule` given or 0.
def ouY4(QjBU, LT6S): if not hasattr(QjBU, 'sampling_schedule') or not QjBU.sampling_schedule: return ZylS.convert_to_tensor(0.0, ZylS.float32) if not LT6S: ZylS.logging.warning('Setting non-training sampling schedule from %s:%f to constant:1.0.', QjBU.sampling_schedule, QjBU.sampling_rate) ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def QBMf(QjBU, LT6S):\n if not hasattr(QjBU, 'sampling_schedule') or not QjBU.sampling_schedule or (QjBU.sampling_schedule == 'constant' and QjBU.sampling_rate == 0):\n return ZylS.constant(0.0)\n if not LT6S:\n ZylS.logging.warning('Setting non-training sampling schedule from %s:%f to constant...
[ "0.75281113", "0.6158589", "0.56475234", "0.5506362", "0.5463649", "0.53641814", "0.53346133", "0.53075045", "0.529155", "0.52847636", "0.5239813", "0.52129424", "0.5210896", "0.5206099", "0.5200316", "0.51788247", "0.51734823", "0.51506543", "0.5149258", "0.5146269", "0.5130...
0.7540726
0
Returns copy of default HParams for LSTM models.
def ISV2(): MIeE = rvDU.get_default_hparams().values() MIeE.update({'conditional': True, 'dec_rnn_size': [512], 'dec_rnn_attn_len': 0, 'enc_rnn_size': [256], 'dropout_keep_prob': 1.0, 'sampling_schedule': 'constant', 'sampling_rate': 0.0}) return ZylS.contrib.training.HParams(**MIeE)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Noje():\n KbxR = QjBU.ModelHparams(model_name='imagenet_resnet_50', model_init='kaiming_normal', batchnorm_init='uniform')\n ey6f = QjBU.DatasetHparams(dataset_name='imagenet', batch_size=1024)\n I_JG = QjBU.TrainingHparams(optimizer_name='sgd', momentum=0.9, milestone_steps='30ep,60ep,80ep', lr=0.4, ...
[ "0.7121815", "0.6912936", "0.6796312", "0.67651266", "0.674475", "0.6689803", "0.6478555", "0.6453718", "0.6403915", "0.6392958", "0.6240745", "0.6156832", "0.61141986", "0.60967886", "0.6072733", "0.6033046", "0.59774673", "0.59519494", "0.59111404", "0.58422005", "0.5841381...
0.7443819
0
Enable default repository config dictionary to be overridden by the command before actually creating the repository. The default implementation of this method simply returns the provided repo_config dictionary without change
def _9I2(YKHO, _9I2, qIxc=None): return _9I2
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def THvi(YKHO, boHx):\n with boHx.config_writer() as GPtr:\n bD7m = 'https://' + str(YKHO.user.username) + ':' + str(YKHO.get_user_token()) + '@github.com/' + str(YKHO.user.username) + '/' + YKHO.repo + '.git'\n GPtr.set_value('remote \"origin\"', 'url', bD7m)\n GPtr.set_value('user', 'emai...
[ "0.6076892", "0.5936533", "0.5933565", "0.5812144", "0.5810799", "0.5783901", "0.57687515", "0.57294947", "0.5703187", "0.5655608", "0.5631813", "0.5623236", "0.5600907", "0.5593499", "0.5577123", "0.5569572", "0.55347794", "0.552615", "0.5501082", "0.5471231", "0.54603356", ...
0.7759282
0
Crossentropy of a list of sentences. sents the sentences.
def CqbS(YKHO, Eab6): return -1 * YKHO.log_prob(Eab6) / len(YKHO._count)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def CqbS(N6Z1, x6A0):\n NzrI = x6A0 * oyIN.log(N6Z1)\n return -oyIN.sum(NzrI) / N6Z1.shape[0]", "def Twap(ebmq, Crrw):\n Crrw = qw7D(Crrw)\n ebmq = qw7D(ebmq)\n Yxgk = 0.0\n for vC9B in Ni9Y(min(Crrw), max(Crrw) + 1):\n yCcW = ebmq[Crrw == vC9B]\n Yxgk += len(yCcW) * DdDW(yCcW)\n ...
[ "0.63199884", "0.62887913", "0.62633246", "0.6248736", "0.6227841", "0.6179794", "0.6158335", "0.6143799", "0.5968919", "0.5941275", "0.59310746", "0.59228873", "0.5916907", "0.5911883", "0.5880059", "0.5879798", "0.5852944", "0.5845872", "0.5842637", "0.58146435", "0.5803625...
0.70168126
0
Size of the vocabulary.
def cAlv(YKHO): return YKHO._V
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def bV1g(YKHO):\n return len(YKHO.vocab)", "def iq72(YKHO):\n return len(YKHO.vocab.keys())", "def jXxl(YKHO) -> int:\n return len(YKHO.vocabulary)", "def jXxl(YKHO):\n return len(YKHO.vocab)", "def jXxl(YKHO):\n return YKHO._vocab_size", "def jXxl(YKHO) -> int:\n return YKHO._vocab_siz...
[ "0.9080342", "0.89961356", "0.89005476", "0.87716883", "0.86572665", "0.8534608", "0.8355767", "0.8355767", "0.8272993", "0.79105496", "0.7892161", "0.7316217", "0.72474486", "0.72464186", "0.7225754", "0.72153354", "0.72153354", "0.71253175", "0.71154606", "0.7112191", "0.70...
0.0
-1
Create thank you card formatting.
def WECq(): eHMM = input("Enter the donor's full name > ") geg6 = Dyst() if eHMM == 'list': for mWFP in geg6: print(mWFP) WECq() Z5kt = float(input('Enter the donation amount > ')) for G1Hx, Ty9i in WRzd.items(): if G1Hx == eHMM: WRzd[eHMM] = Ty9i.appe...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def dSuz(YKHO):\n Aofo = '\\nDear {:s},\\n\\n\\tThank you so much for your generous donation of ${:,.2f}!\\n\\n\\tIt will be put to very good use.\\n\\n\\t\\tSincerely,\\n\\t\\t\\t- The Team'.format(YKHO.name, YKHO.getTotDonation())\n return Aofo", "def ko3h():\n UINi = 'Thank you for taking our survey'...
[ "0.6714933", "0.6290228", "0.6264921", "0.6252831", "0.6112954", "0.61038285", "0.5967447", "0.5930981", "0.57657087", "0.57619464", "0.57072455", "0.566569", "0.56309235", "0.56012315", "0.5592291", "0.5558542", "0.55507916", "0.55441356", "0.5475546", "0.5471788", "0.543972...
0.0
-1
the address to show as the sender of the email notification
def SDM0(YKHO): return YKHO._from
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def ofQZ(YKHO) -> qe4Y.Output[str]:\n return qe4Y.get(YKHO, 'notification_sender_email')", "def ofQZ(YKHO) -> h8nf[qe4Y.Input[str]]:\n return qe4Y.get(YKHO, 'notification_sender_email')", "def ofQZ(YKHO) -> h8nf[qe4Y.Input[str]]:\n return qe4Y.get(YKHO, 'notification_sender_email')", "def vC92(YKHO)...
[ "0.7993943", "0.7658004", "0.7658004", "0.7641934", "0.74163544", "0.7232537", "0.7122202", "0.6988078", "0.6966176", "0.6899789", "0.68558", "0.68278253", "0.68007463", "0.6710892", "0.6676652", "0.66606253", "0.66553193", "0.66553193", "0.66553193", "0.65977967", "0.6568808...
0.0
-1
return a string to use as the email subject
def fF_k(YKHO, vTGh): return 'PDR Notice: {0}: {1}'.format(vTGh.type, vTGh.title)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def LZJ7(YKHO):\n return YKHO.msg['Subject']", "def U4ZT(YKHO):\n return YKHO.mail.get('Subject')", "def U4ZT(YKHO):\n U4ZT = ZbWC.sub(cvFo, '', YKHO.header('Subject', ''))\n U4ZT = ZbWC.sub(AMr8, '', U4ZT)\n return U4ZT.strip()", "def U4ZT(YKHO):\n U4ZT = DWkG.render_to_string(YKHO.subject...
[ "0.77083737", "0.7681589", "0.7613188", "0.75145787", "0.739271", "0.7290039", "0.724725", "0.7246994", "0.7246994", "0.720084", "0.71955186", "0.71942306", "0.71035635", "0.7044783", "0.68648267", "0.6846961", "0.6749709", "0.6749709", "0.66384107", "0.6637172", "0.653773", ...
0.6565567
20
The index page loads properly
def Q9RF(YKHO): geh0 = YKHO.client.get('localhost:8000') YKHO.assertEqual(geh0.status_code, 200)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def d6pt():\n return TvZl('index.html')", "def d6pt(YKHO):\n return TvZl('main/index.html')", "def d6pt(YKHO):\n return TvZl('index.html')", "def d6pt():\n return TvZl('index.html')", "def d6pt():\n return TvZl('index.html')", "def d6pt(QePW):\n return _1tc(QePW, 'Toeic/index.html')", ...
[ "0.77705723", "0.77575684", "0.7744924", "0.7708801", "0.77013177", "0.76610607", "0.7607931", "0.7594131", "0.7594131", "0.7581622", "0.75676197", "0.75526613", "0.7537449", "0.7512531", "0.74702495", "0.74588037", "0.74572843", "0.74550045", "0.74550045", "0.74303985", "0.7...
0.0
-1
The index page failed to load properly
def Q9RF(YKHO): geh0 = YKHO.client.get('localhost:8000') YKHO.assertEqual(geh0.status_code, 404)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def d6pt(QePW):\n LmpD('Url not found')", "def d6pt(QePW):\n return _1tc(QePW, 'Toeic/index.html')", "def d6pt(QePW):\n return _1tc(QePW, 'templates/index.html')", "def d6pt(QePW):\n return _1tc(QePW, 'index.html', {})", "def d6pt():\n return TvZl('index.html')", "def d6pt():\n return (...
[ "0.7461771", "0.7218957", "0.71420294", "0.7099429", "0.70978034", "0.7021409", "0.702045", "0.6995833", "0.69725263", "0.6972494", "0.6957281", "0.6956326", "0.69275844", "0.6927515", "0.6900663", "0.6893014", "0.68795496", "0.6849336", "0.6849336", "0.6847266", "0.6846539",...
0.7007157
7
Try to load a filter that doesn't exists. Raise KeyError
def JwrG(): with trZe.raises(KeyError): AeVZ('xxx')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def f8yr(YKHO, *qIxc, **B2fa):\n raise NotImplementedError", "def fXWt(YKHO):\n Ylbp = i_fE(fid=42)\n YKHO.assertEqual(Ylbp.status_code, 204)", "def OP2O(YKHO, mWFP):\n with YKHO as KCHu:\n try:\n eHNT = KCHu._load_filter(mWFP)\n except TypeError:\n eHNT = [KCHu....
[ "0.6818634", "0.6033897", "0.5970713", "0.5970713", "0.5970713", "0.59297687", "0.58732855", "0.5816788", "0.5672889", "0.5632497", "0.56148005", "0.5531605", "0.55310416", "0.55075085", "0.5498569", "0.54910934", "0.5469215", "0.5430148", "0.54194194", "0.53625864", "0.53563...
0.58019894
8
Yields list of filepaths under the subdirectories of `directory` with extension `suffix`. For all subdirectories under `directory`, yields a list of filepaths that end with the extension `suffix` in that subdirectory.
def OTsP(AGPF, ZI14='.tsv'): for Kwmb in GkAb(AGPF).glob('**'): if Kwmb.is_dir(): yield [str(eHNT) for eHNT in Kwmb.glob('*') if eHNT.is_file() and eHNT.suffix == ZI14]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def ljgX(AGPF, ZI14, Ot59=False):\n RRlC = [Hy7s.path.abspath(pmON) for pmON in SC2F.glob(Hy7s.path.join(AGPF, '**', f'*{ZI14}'), recursive=True)]\n if Ot59:\n RRlC = [Hy7s.path.split(nUeQ)[-1] for nUeQ in RRlC]\n return RRlC", "def TbUP(AGPF='.', ZI14='.txt'):\n cfbQ = ZAda.get_all_files(AGPF...
[ "0.791146", "0.77924263", "0.7682826", "0.7656737", "0.7576378", "0.7419918", "0.73215914", "0.72767293", "0.7255881", "0.721375", "0.72120047", "0.7191495", "0.7191495", "0.7155071", "0.7121526", "0.7116399", "0.7089022", "0.7051373", "0.70456153", "0.70300376", "0.7021236",...
0.7954649
0
Return the name of the sensor.
def mWFP(YKHO): return YKHO._name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def mWFP(YKHO):\n return YKHO._sensor.name", "def _lKy(YKHO):\n return YKHO.data[1]", "def mWFP(YKHO):\n return YKHO.device.device_data[YKHO.device_id]['name'] + f' {YKHO._sensor_type}'", "def mWFP(YKHO):\n return f'{YKHO._name} {lc9R[YKHO.sensor][0]}'", "def mWFP(YKHO):\n return f'{YKHO._na...
[ "0.91896784", "0.9168378", "0.890185", "0.8770976", "0.8511273", "0.8479953", "0.844435", "0.8299758", "0.8186503", "0.8105667", "0.8079737", "0.8066149", "0.8049647", "0.7700968", "0.7612295", "0.7611456", "0.7600605", "0.7600605", "0.7600605", "0.75392073", "0.75166553", ...
0.0
-1
Return the device state attributes.
def upgy(YKHO): return YKHO._attributes
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def R1i3(YKHO):\n return YKHO.attributes", "def R1i3(YKHO):\n return YKHO._attributes", "def R1i3(YKHO):\n return YKHO._attrs", "def R1i3(YKHO):\n return YKHO.attr", "def R1i3(YKHO):\n return YKHO.attr", "def R1i3(YKHO):\n return YKHO._state_attrs", "def R1i3(YKHO):\n return YKHO._...
[ "0.93173087", "0.9245708", "0.92207897", "0.92147964", "0.92147964", "0.9210798", "0.9210798", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", "0.91909975", ...
0.7985119
71
r"""User friendly representation of the object.
def yLCI(YKHO): return VAZI.to_string(YKHO).format(name=YKHO.Name, args=YKHO._parameters_to_string(YKHO.__multi_layer_perceptron.get_params()))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def zAg0(YKHO):\n return str(YKHO.__dict__['_obj'])", "def zAg0(YKHO):\n return str(YKHO.obj)", "def zAg0(YKHO):\n return '<%s: %s>' % (YKHO.__class__, YKHO.describe())", "def zAg0(YKHO):\n return str(YKHO.__dict__)", "def zAg0(YKHO):\n return str(YKHO.__dict__)", "def zAg0(YKHO):\n ret...
[ "0.82825255", "0.81912386", "0.810611", "0.80742675", "0.80742675", "0.80413765", "0.78911436", "0.78572714", "0.78572714", "0.78572714", "0.78572714", "0.78572714", "0.7837256", "0.7837256", "0.7837256", "0.7837256", "0.7837256", "0.78282624", "0.78249973", "0.78185266", "0....
0.0
-1
Sets the value to the given default value, assuming the original value is not set or the default value is set to forced.
def QIbx(BWXx): return BWXx if BWXx and (not DHvX) else HyJ9
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def UXGE(YKHO):\n YKHO.setValue(YKHO.default_value)", "def HyJ9(YKHO, HyJ9):\n YKHO._default_value = HyJ9", "def HyJ9(YKHO, HyJ9):\n YKHO._default_value = HyJ9", "def HyJ9(YKHO, HyJ9):\n YKHO._default_value = HyJ9", "def WmM4(YKHO, BWXx):\n YKHO._default = BWXx\n return", "def WmM4(YKHO...
[ "0.8311482", "0.8117231", "0.8117231", "0.8117231", "0.7998342", "0.79761994", "0.7874169", "0.77663594", "0.7662838", "0.7625267", "0.75235516", "0.7425628", "0.74054205", "0.73071146", "0.72232527", "0.71844447", "0.7148473", "0.71359485", "0.7080375", "0.70489883", "0.6974...
0.8230975
1
Remove the tird dimension (i.e. sets the zaxis to zero) and thus flattens the points cloud. This does not mean the resulting point cloud is a 2dimensional vector but a 3dimensional with the last axis full of zeros
def kIxl(cEe2): KEU_ = jth9.deepcopy(cEe2) LTIa = oyIN.asarray(KEU_.points) LTIa[:, 2] = 0 KEU_.points = Phuy.utility.Vector3dVector(LTIa) return KEU_
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def bIA7(vhpA):\n return vhpA.unsqueeze(0).unsqueeze(-1)", "def d1K_(vhpA):\n return vhpA.unsqueeze(0).unsqueeze(-1)", "def SE5q(YKHO, CyDe):\n WW6E, bGrB = XC5k.projectPoints(CyDe, YKHO.rvec, YKHO.tvec, YKHO.K_new, 0)\n WW6E = oyIN.squeeze(WW6E)\n if len(WW6E.shape) == 1:\n WW6E = oyIN.e...
[ "0.5974419", "0.5905398", "0.58096266", "0.5758149", "0.57497466", "0.57208514", "0.57054377", "0.56797755", "0.55174094", "0.5481428", "0.54809904", "0.54264086", "0.54143924", "0.5393676", "0.53870916", "0.53707606", "0.53687346", "0.53685385", "0.5294432", "0.5291387", "0....
0.5753058
4
Converts center bounding boxes to axisaligned bounding boxes.
def qPht(oUSw): G7Pc = [] GW2s = len(oUSw) for YRbF in range(GW2s): FlUN = oUSw[YRbF:YRbF + 1] oM1k = oyIN.array(DpbD(FlUN[:, :3], FlUN[:, 3:6], FlUN[:, -1])[0].tolist()) G7Pc.append(Phuy.geometry.AxisAlignedBoundingBox(oM1k.min(axis=0), oM1k.max(axis=0))) return G7Pc
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def FV53(oUSw):\n wBZN, KDmU = (oUSw[:, 0], oUSw[:, 1])\n re6M, rwK9 = (oUSw[:, 2], oUSw[:, 3])\n JPqE = (re6M + wBZN) / 2.0\n fXzF = (rwK9 + KDmU) / 2.0\n TVTK = re6M - wBZN\n H2v2 = rwK9 - KDmU\n return oyIN.concatenate([JPqE[:, None], fXzF[:, None], TVTK[:, None], H2v2[:, None]], axis=1)", ...
[ "0.71829236", "0.6611403", "0.65913737", "0.64677095", "0.6335142", "0.6308932", "0.61048675", "0.60351735", "0.60151947", "0.6003721", "0.6003603", "0.59982824", "0.59853464", "0.5980196", "0.5978265", "0.5936955", "0.59293836", "0.5919537", "0.5886627", "0.5835288", "0.5819...
0.6872047
1
Project a PointCloud to the given mesh using ray to triangle intersections.
def QppY(oor4, JZXy, G_pu=2.0): Usad = oyIN.asarray(JZXy.points) hms5 = oyIN.asarray(JZXy.normals) YXoZ = jth9.deepcopy(Usad) VWex = oyIN.zeros_like(YXoZ) HXqP, yo0K, zAQQ = oor4.ray.intersects_location(ray_origins=VWex, ray_directions=YXoZ, multiple_hits=False) Usad = Usad[yo0K] hms5 = hms5...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def P50E(tH0x):\n LTIa = oyIN.asarray(tH0x)\n b7Ss = Zxt2.spatial.ConvexHull(LTIa)\n b7Ss = Zxt2.spatial.ConvexHull(LTIa[b7Ss.vertices])\n pLcG.transforms.counterclockwise_hull(b7Ss)\n iXlf = b7Ss.points\n y_PJ = b7Ss.simplices\n return (iXlf, y_PJ)", "def vuCY(YKHO, tH0x):\n assert isins...
[ "0.7014846", "0.6179631", "0.6064399", "0.5948731", "0.5759748", "0.57489985", "0.5709388", "0.5602244", "0.5573145", "0.55360425", "0.55358857", "0.54908615", "0.54837096", "0.5482978", "0.5412167", "0.5399386", "0.53236836", "0.5301536", "0.5293729", "0.52767736", "0.525783...
0.63287795
1
Return a board with all squares containing value as empty.
def nmIn(iBIi: Board, BWXx: int) -> yELo: return [[0 if Fyji is BWXx else Fyji for Fyji in rdlD] for rdlD in iBIi]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def hfkN():\n return [['', '', ''], ['', '', ''], ['', '', '']]", "def mWT0(YKHO):\n lsmZ = []\n for rdlD in range(YKHO._dim):\n for fvDH in range(YKHO._dim):\n if YKHO._board[rdlD][fvDH] == KAvf:\n lsmZ.append((rdlD, fvDH))\n return lsmZ", "def IsUO(zNig: 'board si...
[ "0.79396045", "0.78354114", "0.74031013", "0.73303336", "0.72390467", "0.722591", "0.7149222", "0.71464354", "0.71100205", "0.7065583", "0.699321", "0.6970096", "0.69450665", "0.6931441", "0.69139856", "0.69023085", "0.6821577", "0.6783795", "0.67821646", "0.67761326", "0.675...
0.7277781
4
Blocking arrays... via split and also, a reshape [(i, j, (s + (i,j) np.mod(s, (i,j)) np.mod(s, (i,j)))) for i in range(2,5) for j in range(2,5)] b0, b1 = rows, cols Blocksize x, y = b.shape padded array b.reshape((x//b0,b0,y//b1,b1)) b.reshape((x//b0,b0,y//b1,b1)).swapaxes(1,2).reshape(1,b0,b1) m,n = a.shape out = a.re...
def AG8_(): def Cs0s(jzdc, usx6=3, WfCS=4, UjZd=True, W1Td=-1): """ a variant on array_split requires a N*m array """ KCHu = oyIN.array(jzdc.shape) yzQ0 = oyIN.array([usx6, WfCS]) r8hN = divmod(KCHu, yzQ0) EZd9 = yzQ0 * r8hN[0] + yzQ0 * (r8hN[1] != 0) ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def GFMe():\n\n def XkN1(jzdc, Mkmy=3, gtI8=3, E6Qf=True):\n \"\"\"Block slice an array using a window of (rs, cs) size\n \"\"\"\n f3dD = jzdc.shape[0] // H0q3\n _tGS = jzdc.shape[1] // gtI8\n if E6Qf:\n iter = [(YRbF, r845) for YRbF, r845 in oyIN.ndindex(f3dD, _tGS...
[ "0.7044555", "0.6941713", "0.68102294", "0.67792046", "0.67261463", "0.6336276", "0.6234391", "0.60712695", "0.5970377", "0.5883539", "0.5874847", "0.58068275", "0.5793492", "0.5793492", "0.5793492", "0.5772601", "0.57716197", "0.57129985", "0.570474", "0.5699241", "0.5664132...
0.68124837
2
Retreives latest package version string for PyPI.
def FDk0(hxGQ: str, W1Sh: bool) -> str: GtGV = N5W9(hxGQ) DpZH = GtGV.get('info').get('version') if GtGV and GtGV.get('info') else None if W1Sh and DpZH and (not gpqf(DpZH)): DpZH = T4MF(GtGV) or DpZH return DpZH
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def zvqz():\n IJ4N, cbKy, KrIv, Po4F, TZ9E, Jdap = RoPu\n DpZH = '%s.%s' % (IJ4N, cbKy)\n if KrIv or Po4F:\n DpZH += '.%s' % KrIv\n if Po4F:\n DpZH += '.%s' % Po4F\n if TZ9E != 'final':\n DpZH += '%s%s' % ({'alpha': 'a', 'beta': 'b'}.get(TZ9E, TZ9E), Jdap)\n return Dp...
[ "0.77451783", "0.77166265", "0.7689727", "0.7634704", "0.73521453", "0.73501754", "0.731257", "0.7281777", "0.72800255", "0.72696275", "0.7181839", "0.7172458", "0.7126039", "0.70684385", "0.6930545", "0.6885785", "0.6878882", "0.68703336", "0.6849777", "0.68248194", "0.67762...
0.7421034
4
This function takes a subreddit and returns the number of subscribers if the subreddit is invalid, the function returns 0.
def zdW_(_5RM): bD7m = 'https://www.reddit.com/r/{}/about.json'.format(_5RM) MOPg = {'user-agent': 'request'} geh0 = G4JS.get(bD7m, headers=MOPg, allow_redirects=False) if str(geh0) != '<Response [200]>': return 0 zs78 = geh0.json() zbDt = zs78.get('data').get('subscribers') return z...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def zdW_(_5RM):\n import requests\n MOPg = {'User-Agent': 'Godfather'}\n vsuQ = requests.get('https://www.reddit.com/r/{}/about.json'.format(_5RM), headers=MOPg).json()\n try:\n HV_K = vsuQ.get('data').get('subscribers')\n if HV_K is None:\n raise TypeError\n return HV_K...
[ "0.87195814", "0.87137395", "0.87037545", "0.86576134", "0.8643708", "0.86220384", "0.8619205", "0.8612982", "0.86001855", "0.8577579", "0.8570017", "0.85211706", "0.8500416", "0.84798086", "0.8465369", "0.84581715", "0.8415392", "0.84138894", "0.83664346", "0.82155496", "0.7...
0.827763
19
update dst_tensor_type to be compatible with src_tensor_type when dimension mismatches
def bssu(YKHO, Q6kx, FlcU, _RnW, K9lI): q7rl = _RnW.sequence_type.elem_type.tensor_type if FDfP(_RnW) else _RnW.tensor_type t0GZ = K9lI.sequence_type.elem_type.tensor_type if FDfP(K9lI) else K9lI.tensor_type if q7rl.elem_type != t0GZ.elem_type: Lnes = Q6kx.name if Q6kx.name else Q6kx.op_type ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Pj7C(YKHO, gWg0):\n qIJ_ = dIo0(lambda WKvO, LVAh: WKvO * LVAh, YKHO.src_shape[:])\n QZfx = dIo0(lambda WKvO, LVAh: WKvO * LVAh, YKHO.dst_shape[:])\n YKHO.src_gm = gWg0.Tensor(YKHO.dtype, (qIJ_,), name='src_gm', scope=bWon.scope_gm)\n YKHO.dst_gm = gWg0.Tensor(YKHO.dtype, (QZfx,), name='dst_gm', sc...
[ "0.59902555", "0.59860665", "0.59860665", "0.59122276", "0.59013706", "0.59013706", "0.5831566", "0.5784696", "0.5733108", "0.56590044", "0.53470063", "0.5313553", "0.5312576", "0.5277822", "0.5256612", "0.51745135", "0.5168023", "0.51582646", "0.5114423", "0.5109479", "0.503...
0.7733749
0
Compute sigmoid of x.
def hSon(WKvO): KCHu = 1.0 / (1 + 1 / epAf.exp(WKvO)) return KCHu
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def m1Hg(YKHO, WKvO):\n return 1 / (1 + oyIN.exp(-WKvO))", "def m1Hg(YKHO, WKvO):\n return 1 / (1 + oyIN.exp(-WKvO))", "def m1Hg(WKvO):\n return 1 / (1 + kLQb(-WKvO))", "def m1Hg(WKvO):\n return 1 / (1 + kLQb(-WKvO))", "def m1Hg(WKvO):\n return 1 / (1 + oyIN.exp(-WKvO))", "def m1Hg(YKHO, W...
[ "0.90725386", "0.90725386", "0.90648764", "0.90648764", "0.9055216", "0.90471625", "0.902537", "0.9017071", "0.9017071", "0.90086645", "0.8996414", "0.8985635", "0.8978176", "0.8974883", "0.8962532", "0.8959142", "0.89552665", "0.8953469", "0.89519686", "0.8939145", "0.893833...
0.8461431
51
Compute the gradient (also called the slope or derivative) of the sigmoid function with respect to its input x. You can store the output of the sigmoid function into variables and then use it to calculate the gradient.
def NZml(WKvO): KCHu = 1.0 / (1 + 1 / oyIN.exp(WKvO)) oxOY = KCHu * (1 - KCHu) return oxOY
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def ICX2(Emd4, WKvO):\n LVAh = siRN.apply(WKvO)\n return oyIN.multiply(LVAh, 1 - LVAh)", "def efwP(WKvO):\n wEsz = m1Hg(WKvO)\n return oyIN.multiply(wEsz, 1 - wEsz)", "def efwP(YKHO, EcVT):\n SRYB = YKHO.sigmoid(EcVT)\n return SRYB * (1 - SRYB)", "def ICX2(Emd4, WKvO):\n return 1 - SEU8....
[ "0.8674491", "0.82187015", "0.7996314", "0.7830284", "0.780607", "0.77875787", "0.77572584", "0.7719716", "0.77135533", "0.76934177", "0.75490737", "0.7515985", "0.7515479", "0.7500251", "0.74777097", "0.74777097", "0.74744225", "0.7400065", "0.7387052", "0.73736554", "0.7322...
0.77772516
6
Saves grad on output of layer to compute covariance.
def w_RI(YKHO, VlDb, uGHv, pwN3): if VlDb.training: YKHO.state[VlDb]['gy'] = pwN3[0] * pwN3[0].size(0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def H3EA(YKHO, Ro40=None):\n if Ro40 is None:\n Ro40 = DDLl.ones_like(YKHO.output_value)\n WKvO, = YKHO.input_nodes[0].output_value\n return DDLl.exp(WKvO) * Ro40", "def H3EA(YKHO, Ro40=None):\n UnuI = YKHO.input_nodes[0].output_value\n if Ro40 is None:\n Ro40 = DDLl.ones_like(YKHO.o...
[ "0.5966475", "0.5960863", "0.5942509", "0.5858322", "0.584522", "0.5807888", "0.577789", "0.57539004", "0.57503796", "0.5716084", "0.5709692", "0.56874514", "0.56691617", "0.56539345", "0.56472534", "0.56472534", "0.5627406", "0.56250185", "0.5624605", "0.5620099", "0.5617088...
0.6770716
0
Min length of the password recovery question answer.
def kbxC(YKHO) -> h8nf[qe4Y.Input[int]]: return qe4Y.get(YKHO, 'question_min_length')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def OaGU(YKHO) -> qe4Y.Output[h8nf[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def OaGU(YKHO) -> h8nf[qe4Y.Input[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def OaGU(YKHO) -> h8nf[qe4Y.Input[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def kbxC(YKHO) -> qe4Y.Out...
[ "0.78962994", "0.7844596", "0.7844596", "0.7536869", "0.7471526", "0.71174407", "0.69288987", "0.67248994", "0.6636504", "0.6511056", "0.64749956", "0.6470365", "0.6469098", "0.6469098", "0.6468054", "0.6467145", "0.6437118", "0.6422552", "0.6415916", "0.6410899", "0.6353203"...
0.7574994
3
Min length of the password recovery question answer.
def kbxC(YKHO) -> h8nf[qe4Y.Input[int]]: return qe4Y.get(YKHO, 'question_min_length')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def OaGU(YKHO) -> qe4Y.Output[h8nf[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def OaGU(YKHO) -> h8nf[qe4Y.Input[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def OaGU(YKHO) -> h8nf[qe4Y.Input[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def kbxC(YKHO) -> qe4Y.Out...
[ "0.78962994", "0.7844596", "0.7844596", "0.7536869", "0.7471526", "0.71174407", "0.69288987", "0.67248994", "0.6636504", "0.6511056", "0.64749956", "0.6470365", "0.6469098", "0.6469098", "0.6468054", "0.6467145", "0.6437118", "0.6422552", "0.6415916", "0.6410899", "0.6353203"...
0.7574994
4
Min length of the password recovery question answer.
def kbxC(YKHO) -> qe4Y.Output[h8nf[int]]: return qe4Y.get(YKHO, 'question_min_length')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def OaGU(YKHO) -> qe4Y.Output[h8nf[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def OaGU(YKHO) -> h8nf[qe4Y.Input[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def OaGU(YKHO) -> h8nf[qe4Y.Input[int]]:\n return qe4Y.get(YKHO, 'password_min_length')", "def kbxC(YKHO) -> h8nf[qe4...
[ "0.7895626", "0.78438365", "0.78438365", "0.7575124", "0.7575124", "0.7470688", "0.71162", "0.6927574", "0.67236465", "0.6635173", "0.651104", "0.64766276", "0.64715344", "0.64695877", "0.64695877", "0.6466112", "0.6465993", "0.6438414", "0.6421231", "0.64174455", "0.6410547"...
0.75370866
5
Determine which other album to show and do so
def KCLE(YKHO): QOe9 = YKHO.ask_album.currentIndex() if QOe9: YKHO.parent().album = YKHO.parent().albums[QOe9 - 1] YKHO.parent().do_detail()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def YDb3(YKHO):\n for p6S0, xFfn in enumerate(YKHO.go_buttons):\n if YKHO.sender() == xFfn:\n YKHO.parent().album = YKHO.parent().albums[p6S0]\n break\n if not YKHO.parent().album:\n print('waaat')\n YKHO.parent().do_detail()", "def TYrI(TK2h):\n oSs6 = Fq6c()\n ...
[ "0.6516697", "0.64556766", "0.6376233", "0.6306249", "0.62252784", "0.61619085", "0.6018769", "0.59754944", "0.5951971", "0.59396625", "0.5870015", "0.5858398", "0.5823198", "0.5794692", "0.5775557", "0.574518", "0.5732002", "0.5726389", "0.5712765", "0.5657524", "0.5638212",...
0.8120705
0
create a horizontal line in the GUI
def wN2A(_AKB): WYo3 = IB0w.QHBoxLayout() L5qP = IB0w.QFrame(_AKB) L5qP.setFrameShape(IB0w.QFrame.HLine) WYo3.addWidget(L5qP) return WYo3
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def cbEp(YKHO):\n return YKHO.cv.create_line(0, 0, 0, 0, fill='', width=2, capstyle=cqfR.ROUND)", "def bYDk(YKHO, gigf, GN0K, Rjb4, ydZk, OhBR, RsfQ, suhQ):\n with gigf:\n gigf.set_line_width(20)\n gigf.set_stroke_color(YKHO._get_border_color())\n Eoj5(gigf, GN0K, Rjb4, RsfQ, suhQ, OhB...
[ "0.7532128", "0.74106574", "0.73367685", "0.7310195", "0.6893052", "0.68514603", "0.6803702", "0.67848283", "0.6635092", "0.65827453", "0.6571504", "0.65017474", "0.64765716", "0.64490736", "0.64359325", "0.6388449", "0.63609403", "0.6339876", "0.63207155", "0.63199294", "0.6...
0.67197096
8
convert list to np.ndarray, and get rid of the redundant dimension
def hP8t(YKHO, *qIxc): Aofo = [oyIN.array(ZfUD) for ZfUD in qIxc] if len(Aofo) == 1: return Aofo[0] return Aofo
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def WTDd(jzdc: List[tvm.nd.NDArray]) -> x1iM[oyIN.ndarray]:\n assert jzdc is not None, 'Empty result cannot be converted to numpy'\n return [WKvO.numpy() for WKvO in jzdc]", "def jHv0(vC9B):\n kvoN = max([len(Z9rn) for Z9rn in vC9B])\n R2LW = [oyIN.pad(Z9rn, (0, kvoN - len(Z9rn)), 'constant', constan...
[ "0.7250774", "0.716986", "0.66994196", "0.6626677", "0.6611562", "0.65863806", "0.6439985", "0.6414919", "0.6411515", "0.63630134", "0.6282977", "0.6279388", "0.6253245", "0.6252695", "0.623639", "0.6215656", "0.61880934", "0.6186437", "0.6174455", "0.60949725", "0.6084188", ...
0.0
-1
Iterator that yields a dictionary of (fieldname,value) pairs. Note that the order of field_names is important!
def JIg1(Ux0P, NSNj=None): if not NSNj: raise ValueError('No fields specified for nndb recs') def ulrI(eHNT): if len(eHNT) > 1 and eHNT[0] == '~' and (eHNT[-1] == '~'): eHNT = eHNT[1:-1] return eHNT with open(Ux0P, 'r', encoding='latin_1') as ehj4: for zFiD in eh...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Vs4Q(YKHO):\n for mWFP, Jyyj in YKHO.iterate_over_fields():\n yield (mWFP, Jyyj)", "def d_0I(YKHO):\n for mWFP, Jyyj in YKHO.fields.items():\n pFW3 = YKHO.renderers.get(mWFP)\n if pFW3:\n BWXx = pFW3(YKHO.instance)\n else:\n BWXx = getattr(YKHO.instance...
[ "0.76768583", "0.749205", "0.739067", "0.70374584", "0.700193", "0.6879514", "0.68233067", "0.67776036", "0.6755737", "0.6642557", "0.6623121", "0.6534925", "0.6439505", "0.6359051", "0.6329221", "0.63033336", "0.62856555", "0.6274696", "0.62669367", "0.62669367", "0.6229252"...
0.0
-1
Helper for numeric fields we accept a string, convert it using filt, and will return an empty string if there is a ValueError converting
def mLGw(KCHu, ulrI=float): if not KCHu: return '' try: return ulrI(KCHu) except ValueError: return ''
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def iK1K(b_xr):\n b_xr = '' if b_xr == None else b_xr\n b_xr = b_xr.rstrip(' ')\n b_xr = '%' if b_xr == '' else b_xr\n b_xr = b_xr.replace('*', '%')\n b_xr = b_xr.replace('?', '_')\n return b_xr", "def OmZY(YKHO, QePW, SR0I, fNjO):\n if fNjO.isnumeric():\n fNjO = fNjO.lstrip('0')\n ...
[ "0.6061323", "0.601796", "0.59811836", "0.59455", "0.5895617", "0.58516157", "0.58300596", "0.58300596", "0.58284104", "0.5781341", "0.5774522", "0.5716071", "0.5707122", "0.569037", "0.5650388", "0.5641815", "0.56386906", "0.5624196", "0.56159747", "0.5610727", "0.55907226",...
0.7619102
0
Removes common accent characters. Our goal is to brute force login mechanisms, and I work primary with companies deploying Englighlanguage systems. From my experience, user accounts tend to be created without special accented characters. This function tries to swap those out for standard Engligh alphabet.
def Gcqg(Novh): Novh = ZbWC.sub(u'[àáâãäå]', 'a', Novh) Novh = ZbWC.sub(u'[èéêë]', 'e', Novh) Novh = ZbWC.sub(u'[ìíîï]', 'i', Novh) Novh = ZbWC.sub(u'[òóôõö]', 'o', Novh) Novh = ZbWC.sub(u'[ùúûü]', 'u', Novh) Novh = ZbWC.sub(u'[ýÿ]', 'y', Novh) Novh = ZbWC.sub(u'[ß]', 'ss', Novh) Novh = ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def QDJq(l5Ny):\n l5Ny = zVCt.normalize('NFKD', l5Ny).encode('ascii', 'ignore').decode('utf-8', 'ignore')\n return l5Ny", "def QDJq(l5Ny):\n l5Ny = XKrx.unidecode(l5Ny)\n return l5Ny", "def mObG(l5Ny: str) -> str:\n return XKrx.unidecode(l5Ny)", "def dEDD(l5Ny):\n l5Ny = zVCt.normalize('NFD...
[ "0.77535427", "0.7742565", "0.74435186", "0.73979527", "0.72370094", "0.72368246", "0.7220512", "0.721693", "0.7189707", "0.71882826", "0.71610796", "0.7051085", "0.70348877", "0.7021435", "0.6984719", "0.6885377", "0.6850878", "0.68275577", "0.679215", "0.6745978", "0.672953...
0.74035364
3
Generate a presigned URL for an Amazon S3 object. This allows anyone who receives the presigned URL to retrieve the S3 object with an HTTP GET request. For sigv4 requests the region needs to be configured explicitly.
def jnbh(YKHO, eMpl, **B2fa): return YKHO.exec_command('presign %s' % eMpl, **B2fa)[0].strip()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def G3tP(l7rj, BfZj, N850=3600, jCrz=MxRZ['v4']):\n kZdy = iVGz.client('s3', aws_access_key_id=JBM6, aws_secret_access_key=HMsS, config=PSrQ(signature_version=jCrz), region_name=onQy)\n try:\n geh0 = kZdy.generate_presigned_url('get_object', Params={'Bucket': l7rj, 'Key': BfZj}, ExpiresIn=N850)\n ...
[ "0.7953014", "0.79265076", "0.79053384", "0.7835346", "0.7833449", "0.78153163", "0.78124297", "0.7635567", "0.75704265", "0.7564686", "0.7528726", "0.7367153", "0.735262", "0.72680277", "0.7183056", "0.70428884", "0.70288306", "0.7011211", "0.699134", "0.6941765", "0.6743638...
0.7042733
16
Return JSON formatted data of this user's disc collection.
def hqyT(uJjO): faa1 = cuiw.query(fGMw).filter_by(user_id=uJjO).all() return pz3A(users_discs=[YRbF.serialize for YRbF in faa1])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def qQXR(YKHO):\n return {'_id': YKHO._id, 'name': YKHO.name, 'description': YKHO.description}", "def qQXR(YKHO):\n LH4T = dict(arn=YKHO.arn, create_date=YKHO.create_date, id=YKHO.user_id, inline_policies=YKHO.inline_policies_json, inline_policies_count=len(YKHO.inline_policies_json), groups=YKHO.groups_js...
[ "0.64870137", "0.63441855", "0.63308936", "0.63222295", "0.6286649", "0.6267056", "0.6250742", "0.6203766", "0.6201961", "0.61703515", "0.6149133", "0.6118483", "0.61088485", "0.60965866", "0.6076712", "0.6064045", "0.60554826", "0.60545486", "0.6051538", "0.6048292", "0.6048...
0.7279737
0
Runs pending tasks continuously on a nonblocking thread
def azxP(YKHO, VOlW: int=1): DkQO = T6FA.Event() class ScheduleThread(T6FA.Thread): @classmethod def iXC1(Emd4): while not DkQO.is_set(): b6Gq.run_pending() ITS7.sleep(VOlW) vYZm = HO9z() vYZm.start() return DkQO
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def lKJC():\n while True:\n G9jH.info('Awaiting task ')\n yield from V7ok.sleep(5)\n lGbz.create_task(ijqk())", "def zzyv(YKHO):\n\n async def _fn():\n pass\n KS9L = V7ok.ensure_future(iEBR())\n YKHO.loop.run_until_complete(KS9L)", "async def _run(YKHO) -> None:\n whi...
[ "0.7055759", "0.65420634", "0.64478093", "0.64171076", "0.6366644", "0.6298646", "0.6287141", "0.6284914", "0.6270252", "0.6224393", "0.61659503", "0.61559355", "0.6088446", "0.6078359", "0.60452145", "0.6033116", "0.5989196", "0.5986055", "0.5977981", "0.59719944", "0.595873...
0.0
-1
Returns True if all CoronaCaseRaw records have the same update flag
def fNOM(YKHO) -> bool: if _jwh.objects.all().count() < 2: return True return not _jwh.objects.filter(update_flag=not YKHO.latest_flag()).exists()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def XLGg(YKHO):\n if not YKHO._is_persisted:\n return False\n LCgR = YKHO._primary_keys.keys()\n return all([not YKHO._values[G1Hx].changed for G1Hx in YKHO._primary_keys])", "def wfJ2(YKHO) -> bool:\n if _jwh.objects.all().count() == 0:\n return True\n return _jwh.objects.latest('da...
[ "0.66894835", "0.6673041", "0.66590273", "0.6592305", "0.6560511", "0.6421242", "0.6257609", "0.6138031", "0.61270374", "0.6066877", "0.59502846", "0.5928542", "0.5809718", "0.58069336", "0.58002204", "0.57952124", "0.57675093", "0.5730479", "0.571626", "0.5624509", "0.561578...
0.7360598
0
Returns True if the last update is older than the update interval
def j3y5(YKHO) -> bool: if _jwh.objects.all().count() == 0: return True mn17 = _jwh.objects.latest('date_received').date_received return rIAI.now() >= mn17 + rIAI.timedelta(seconds=YKHO.interval)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def eWZe(YKHO):\n wzkt = ITS7.time() / 60\n return YKHO.last_update_time_in_minutes + YKHO.timeout < wzkt", "def qMzq(YKHO):\n vHj7 = int(ITS7.time())\n Rx03 = YKHO.last_refresh\n if Rx03 is None:\n Rx03 = 0\n if vHj7 >= Rx03 + YKHO.refresh_rate:\n return True\n return False", ...
[ "0.8213379", "0.7783551", "0.76966345", "0.754631", "0.71432734", "0.7136276", "0.7052958", "0.6961989", "0.6930551", "0.69217616", "0.69099915", "0.67789745", "0.6764368", "0.6760651", "0.6737701", "0.6683879", "0.6671408", "0.66707635", "0.6663597", "0.6660849", "0.66307557...
0.7572731
3
Helper to create dict of dict lookup of bodyparts where the keys are animal names, and values are the bodypart names.
def Hsnk(YKHO, wk1d: bool, O8zj: list, cbfl: int, QrnJ: List[str], En0P: List[str], IJze: Optional[List[str]]=None, Jw9H: Optional[List[List[Tuple[int, int, int]]]]=None) -> cuzp[str, uLKX[x1iM[str], x1iM[AzJI]]]: a9cQ = {} if wk1d: for io6K in range(cbfl): a9cQ[O8zj[io6K]] = {} ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def QBPJ(YKHO, yfga: str, G9re: dict) -> str:\n for AHrt, AW1P in G9re.items():\n if yfga in [WKvO[:-2] for WKvO in AW1P['X_bps']]:\n return AHrt", "def W32x(YKHO, XPr_, s5l8):\n print('start the measuring....')\n rC22 = {}\n ig2H = YKHO.find_shoulders_point(XPr_, s5l8)\n akyn = ...
[ "0.5984602", "0.5896634", "0.5682988", "0.55576694", "0.5467315", "0.52992886", "0.5201111", "0.51629925", "0.51294166", "0.50887316", "0.50546557", "0.503882", "0.50180286", "0.5008302", "0.5003173", "0.49873012", "0.49000075", "0.48616034", "0.48295596", "0.47882527", "0.47...
0.6127154
0
Helper to extract poseestimation data field names (x, y, p)
def rhRA(YKHO): YKHO.x_cols, YKHO.y_cols, YKHO.p_cols = ([], [], []) for vI3f in YKHO.body_parts_lst: YKHO.x_cols.append(f'{vI3f}_x') YKHO.y_cols.append(f'{vI3f}_y') YKHO.p_cols.append(f'{vI3f}_p')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def TnMw(nPrm):\n return nPrm['train'][nPrm['train'].keys()[0]].attrs.keys()", "def I347(YKHO):\n n6Z7 = []\n for Mzf9 in YKHO.parameters:\n n6Z7.append(Mzf9.name)\n return n6Z7", "def TnMw(oxOY):\n gEmA = oxOY.GetLayer(0)\n pIr7 = gEmA.GetLayerDefn()\n NSNj = [pIr7.GetFieldDefn(YRb...
[ "0.6025627", "0.5988987", "0.59218544", "0.5856788", "0.57522917", "0.562954", "0.558819", "0.5568189", "0.5453333", "0.5448768", "0.5431835", "0.53945845", "0.5388422", "0.53556734", "0.53473955", "0.5345145", "0.5311912", "0.5311605", "0.52883357", "0.52782464", "0.5267301"...
0.56039864
6
Check if hashed password matches actual password
def sNjs(YKHO, jTXt): return z8jj(YKHO.password_hash, jTXt)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def pcP9(jTXt: str, Nzyw: str) -> bool:\n return jf1V.verify(jTXt, Nzyw)", "def k0jf(jTXt, kg40):\n return N7bY.verify(jTXt, kg40)", "def sNjs(YKHO, jTXt):\n return z8jj(YKHO.password_hash, jTXt)", "def sNjs(jTXt, vhgk):\n cgqW = qzFd(jTXt)\n return FXSn.compare_digest(cgqW, vhgk)", "def Evf...
[ "0.81750333", "0.81654465", "0.81029165", "0.8091229", "0.80758476", "0.8071933", "0.8042396", "0.8026053", "0.79251105", "0.7912885", "0.79124117", "0.79056114", "0.7889633", "0.78833985", "0.7860269", "0.7850504", "0.78410155", "0.7839047", "0.7839047", "0.78045964", "0.779...
0.76697767
46
Traverses tree in preorder and verifies height of each node Returns true if every node has expect height Returns false if atleast one node is incorrect
def iW6n(tk5Y): if tk5Y: iW6n(tk5Y.left) iW6n(tk5Y.right) return tk5Y.height == xglF(tk5Y) return True
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Xgvr(YKHO):\n NXAT = 0\n Z_fq = 0\n OnWS = FOOe\n for bGrB in range(OnWS):\n DCgT = YKHO.new_handler()\n U5bT = iW6n(DCgT.root)\n if U5bT:\n NXAT += 1\n else:\n Z_fq += 1\n YKHO.assertEqual(Z_fq, 0, msg=f'{aFRU.FAIL}\\n\\t[-]\\tFrom state: Fail...
[ "0.6680275", "0.65864444", "0.65601474", "0.6270879", "0.62389755", "0.62281585", "0.61722094", "0.61460066", "0.61392397", "0.6065554", "0.60437363", "0.6042118", "0.6026869", "0.60099787", "0.5976662", "0.5965726", "0.593939", "0.592292", "0.5920807", "0.58926094", "0.58888...
0.70629925
0
Checks if tree is balanced or not Returns true if height balanced Returns false if height imbalanced
def Uxn0(tk5Y): if tk5Y is None: return True xIS6 = xglF(tk5Y.left) On75 = xglF(tk5Y.right) if abs(xIS6 - On75) <= 1 and Uxn0(tk5Y.left) and Uxn0(tk5Y.right): return True return False
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def RTY9(YKHO):\n\n def x8h4(Q6kx):\n \"\"\"Calculate the height of a node\"\"\"\n if not Q6kx:\n return 0\n return 1 + max(x8h4(Q6kx.left), x8h4(Q6kx.right))\n\n def b8bL(Q6kx):\n \"\"\"Check if the subtree at a node is balanced\"\"\"\n if not Q6kx:\n ...
[ "0.8425228", "0.8303599", "0.8302438", "0.8217135", "0.8031821", "0.780561", "0.7685592", "0.76572603", "0.75342387", "0.7519281", "0.748162", "0.7410565", "0.73462856", "0.730783", "0.72945046", "0.72067404", "0.7027153", "0.7022535", "0.6817595", "0.6789149", "0.6781895", ...
0.74815655
11
Prove that two Notification objects with the same property values test positive for value equality.
def j8oC(YKHO) -> None: YKHO.assertTrue(YKHO.notification1 == YKHO.notification1copy) YKHO.assertTrue(YKHO.notification1.__eq__(YKHO.notification1copy))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def rbYS(YKHO) -> None:\n YKHO.assertTrue(YKHO.notification1 != YKHO.notification2)\n YKHO.assertTrue(YKHO.notification1.__ne__(YKHO.notification2))", "def xa14(YKHO, Elif):\n if not isinstance(Elif, JbaM):\n return False\n return YKHO.__dict__ == Elif.__dict__", "def xa14(YKHO, Elif):\n ...
[ "0.6988211", "0.68660295", "0.6748611", "0.6716937", "0.65949726", "0.65529287", "0.6509838", "0.650151", "0.6484305", "0.64724743", "0.6457099", "0.6448794", "0.6401077", "0.6396683", "0.6276237", "0.627536", "0.62672424", "0.6239117", "0.62343514", "0.6234087", "0.6187606",...
0.75300014
0
Prove that two Notification objects with different property values test negative for value equality.
def rbYS(YKHO) -> None: YKHO.assertTrue(YKHO.notification1 != YKHO.notification2) YKHO.assertTrue(YKHO.notification1.__ne__(YKHO.notification2))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Vdqg(YKHO, Elif):\n if not isinstance(Elif, iRFl):\n return True\n return YKHO.to_dict() != Elif.to_dict()", "def j8oC(YKHO) -> None:\n YKHO.assertTrue(YKHO.notification1 == YKHO.notification1copy)\n YKHO.assertTrue(YKHO.notification1.__eq__(YKHO.notification1copy))", "def Vdqg(YKHO, Eli...
[ "0.6934573", "0.6677259", "0.6648972", "0.6601794", "0.6574288", "0.6523762", "0.6503337", "0.64917", "0.6483832", "0.64643085", "0.6464235", "0.64552236", "0.6451011", "0.6403636", "0.6390452", "0.63723147", "0.63492185", "0.6345239", "0.63294274", "0.6302741", "0.6297948", ...
0.7507516
0
Returns a string representation of this `User`.
def zAg0(YKHO): if YKHO.username == None: return 'User does not exist' return YKHO.username
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def wHJl(YKHO):\n return '<User user_id={} email={} first_name={} last_name={}>'.format(YKHO.user_id, YKHO.email, YKHO.first_name, YKHO.last_name)", "def wHJl(YKHO):\n return '<User user_id={} email={} first_name={} last_name={}>'.format(YKHO.user_id, YKHO.email, YKHO.first_name, YKHO.last_name)", "def z...
[ "0.807587", "0.80175275", "0.801447", "0.79293287", "0.7875355", "0.78561157", "0.78483564", "0.78414685", "0.78234303", "0.78002495", "0.78002495", "0.78002495", "0.78002495", "0.78002495", "0.7788562", "0.77748036", "0.776768", "0.7739328", "0.7732555", "0.7702289", "0.7689...
0.0
-1
get a single random Color(), with Optional search filter. search='green' will return 'seagreen', 'bluegreen', etc... default to choice() of full list
def pph3(TgwQ=None): if TgwQ: Z9rn = Acvy(xsP0(TgwQ)) else: Z9rn = Acvy(THSG.values()) return Z9rn
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def pph3():\n return tuKI.choice(Jw9H)", "def pph3():\n Z9rn = Jw9H[tuKI.randint(0, len(Jw9H) - 1)]\n return Z9rn[1]", "def yTL5():\n Mkmy = tuKI(0.0, 1.0)\n Oa1e = tuKI(0.0, 1.0)\n Fg_i = tuKI(0.0, 1.0)\n return he6J(Mkmy, Oa1e, Fg_i)", "def MP1f(F4JO, **B2fa):\n qfpW = None\n U8d...
[ "0.7828161", "0.7101347", "0.6983416", "0.68592376", "0.68395984", "0.682875", "0.6788761", "0.6756461", "0.6727346", "0.66549015", "0.65790653", "0.65230834", "0.6502881", "0.6501694", "0.64567745", "0.64503694", "0.6394078", "0.63786966", "0.6367497", "0.6328744", "0.627898...
0.8793763
0
Method returns list of tensors, each padded to the maximum sizes.
def CvZ5(kdmR): SzEO = max([a1PO.size() for a1PO in kdmR]) Htse = len(SzEO) kP_q = [0] * Htse gCeI = [] for vhpA in kdmR: YKzn = vhpA.size() Z6gW = [r8hN - Z9rn for r8hN, Z9rn in zip(SzEO, YKzn)][::-1] I6Dw = list(Hs6x.chain(*zip(kP_q, Z6gW))) Q85e = hVLt(input=vhpA, ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def xIS8(cRc2, dvgN):\n gQqX = [len(i8WE) for i8WE in cRc2]\n x_5g = max(gQqX)\n cRc2 = [i8WE + (x_5g - len(i8WE)) * [dvgN] for i8WE in cRc2]\n cRc2 = ht2j.stack([ht2j.stack(a1PO) for a1PO in cRc2], dim=0)\n return (gQqX, cRc2)", "def Dt8l(UHhk, C7vt, eusk=None, yDqo=ht2j.float, begE=begE):\n i...
[ "0.6568602", "0.65321517", "0.6462504", "0.62620044", "0.6200474", "0.61139965", "0.60738915", "0.59749", "0.59554935", "0.59504473", "0.59285945", "0.5923103", "0.59209514", "0.59153044", "0.58639157", "0.5852632", "0.5851008", "0.5824605", "0.5817472", "0.5816678", "0.57965...
0.77216774
0
This functions takes in a dictionary (in the format produces by count_ngrams) and returns a list of all ngrans with only 1 occurence. That is, this function should return a list of all ngrams with a count of 1.
def Xnjd(wLXN): u_9I = [] for H5ew in wLXN: if wLXN[H5ew] == 1: u_9I.append(H5ew) return u_9I
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def huz3(YKHO) -> cuzp[str, x1iM[str]]:\n assert YKHO.count_map is not None, 'count map is not initialized'\n Ylbp: cuzp[str, x1iM[str]] = {}\n for aWuw in YKHO.model:\n aWuw: str = YWvJ(str, aWuw)\n soQM = YKHO.get_n_minus_1_grams(aWuw)\n if soQM not in Ylbp:\n Ylbp[soQM] ...
[ "0.6369713", "0.63470906", "0.6224723", "0.60623735", "0.5921012", "0.5906852", "0.5892622", "0.5873671", "0.5852892", "0.58415467", "0.58371246", "0.5830862", "0.58222735", "0.5820353", "0.58199775", "0.58168", "0.5812914", "0.5811192", "0.57994276", "0.5795974", "0.5786719"...
0.7746788
0
Retorna o maximo da arvore.
def vIpd(YKHO, KOdv): if KOdv is not None: while KOdv.getDireito() is not None: KOdv = KOdv.getDireito() return KOdv
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def qfB5(YKHO):\n return YKHO.max[-1]", "def max(YKHO):\n return YKHO.get_first()", "def ZWqN(YKHO):\n return YKHO._maximum", "def max(YKHO):\n return max(YKHO)", "def qfB5(YKHO):\n return YKHO._max", "def max(YKHO):\n return YKHO.__max", "def qfB5(YKHO):\n jvSB = YKHO\n while j...
[ "0.7582067", "0.74340934", "0.73207396", "0.7315176", "0.73005927", "0.72842276", "0.72722745", "0.72563034", "0.72509384", "0.7247525", "0.7237018", "0.7237018", "0.71889913", "0.7042969", "0.7042969", "0.7023191", "0.7015256", "0.7014414", "0.7003582", "0.69608223", "0.6926...
0.6564374
48
Calculates the recall score for the given predictions and targets
def aijD(_0VL, x6A0, BVNj=False): x6A0 = x6A0.view(-1, 1).expand_as(_0VL) yht1 = (x6A0 == _0VL).nonzero() if BVNj: return ((x6A0 == _0VL) * 1.0).sum(dim=-1).view(-1, 1) else: if len(yht1) == 0: return 0 AOzf = (x6A0 == _0VL).nonzero().size(0) / x6A0.size(0) re...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def AOzf(Y8eF, aMgO):\n HRJ_ = wXuO(Y8eF, aMgO)\n FYKK = Rw7j(Y8eF, aMgO)\n AOzf = HRJ_ / (HRJ_ + FYKK)\n return AOzf", "def Uw2c(Y8eF, aMgO):\n return ((Y8eF == 1) * (aMgO == 1)).sum() / (Y8eF == 1).sum()", "def kwZA(x6A0, aTLP):\n Vb19 = x6A0 * aTLP\n buwT = float(oyIN.sum(Vb19))\n c5...
[ "0.7847959", "0.782655", "0.7775863", "0.7767832", "0.7674932", "0.7657287", "0.76307416", "0.76001775", "0.7585204", "0.7585204", "0.7585204", "0.7585204", "0.7585204", "0.7585204", "0.7576374", "0.7573859", "0.75712955", "0.75712955", "0.75712955", "0.75712955", "0.75712955...
0.0
-1
Compares experiment_protocol with a sample's existing_protocols and updates the latter if the former includes any new entry. Returns a twoelement tuple, the first is existing_protocols (which may or may not have been updated) and the second is a bool indicating whether exisiting_protocols has been updated. Note that th...
def Wj8C(WLEE, ZM0A, xmTg): if not 'protocol' in ZM0A: return (WLEE, False) wxxj = False for jBc5 in ZM0A['protocol']: WolH = jBc5.get('text', '') WolH = Dpf4.extract_protocol_text(WolH) if not jBc5.get('accession', '').strip() or not WolH: continue fWn5 =...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def sGz2(YKHO):\n assert YKHO.skill_config.protocols == {YKHO.new_protocol_id}", "def sGz2(YKHO):\n assert YKHO.connection_config.protocols == {YKHO.new_protocol_id}", "def sGz2(YKHO):\n assert YKHO.agent_config.protocols == {YKHO.new_protocol_id}", "def j1H0(YKHO):\n assert YKHO.connection_confi...
[ "0.68441445", "0.662825", "0.654732", "0.63229084", "0.59339184", "0.5549929", "0.5232425", "0.49213052", "0.48436552", "0.47408885", "0.4596059", "0.45489705", "0.45324323", "0.45182005", "0.45156923", "0.45120403", "0.44836906", "0.44828472", "0.44730458", "0.44484085", "0....
0.8691778
0
Checks if we raise for invalid file
def CNuU(YKHO): with YKHO.assertRaises(uRlK.error.URLError): bGrB = dR_h.XMLSchema('does-not-exist.xsd')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def UtdG(YKHO, nUeQ):\n try:\n bGrB = open(f'{nUeQ}')\n except FileNotFoundError:\n raise ValueError", "def pP2J():\n with trZe.raises(ValueError):\n GSyo._valid_file(xAKo)", "def yRS_(YKHO):\n YKHO.assertRaises(JPHO.checkFile('blah', 'write'))", "def NlXE(YKHO):\n jQJk = ...
[ "0.7723395", "0.771441", "0.7641303", "0.7419019", "0.72511405", "0.72382116", "0.72248256", "0.7204487", "0.71709114", "0.7066717", "0.6948508", "0.6927076", "0.6906801", "0.69052106", "0.68919927", "0.6847416", "0.68408287", "0.6816975", "0.6795222", "0.67581224", "0.675617...
0.64506507
67
Returns an iterable of all existing values.
def _Xaq(YKHO): return (BWXx.value for BWXx in YKHO.address.values() if BWXx.value)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def dRIB(YKHO):\n hkxX = YKHO.values\n if hkxX is not None:\n yield from hkxX", "def zuNK(YKHO):\n return iter((TI8K.value for TI8K in YKHO.keyvaluepair_set.all()))", "def hkxX(YKHO):\n return iter(YKHO.data)", "def zuNK(YKHO):\n for H5ew in YKHO:\n yield YKHO[H5ew]", "def Vs4Q...
[ "0.7680097", "0.7456033", "0.7353448", "0.7230936", "0.72280574", "0.7195895", "0.718528", "0.718528", "0.70745444", "0.70325255", "0.7031438", "0.7030463", "0.6954274", "0.69410163", "0.6929653", "0.6907549", "0.6886268", "0.68512386", "0.68274033", "0.6805858", "0.6783038",...
0.6399886
71
Copy, optionally modifying default value and metadata. Clones the contents of this object into a new instance of the same class, and then modifies the cloned copy using the specified ``default_value`` and ``metadata``. Returns the cloned object as the result. Note that subclasses can change the signature of this method...
def i3ak(YKHO, HyJ9=d2Yk, **yIVm): if 'parent' not in yIVm: yIVm['parent'] = YKHO BdN0 = YKHO.__class__.__new__(YKHO.__class__) TDnD = BdN0.__dict__ TDnD.update(YKHO.__dict__) if 'editor' in TDnD: del TDnD['editor'] if '_metadata' in TDnD: BdN0._metadata = BdN0._metadata....
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def i3ak(YKHO, HyJ9=RVJO, **yIVm):\n if 'parent' not in yIVm:\n yIVm['parent'] = YKHO\n BdN0 = YKHO.__class__.__new__(YKHO.__class__)\n TDnD = BdN0.__dict__\n TDnD.update(YKHO.__dict__)\n if 'editor' in TDnD:\n del TDnD['editor']\n if '_metadata' in TDnD:\n BdN0._metadata = B...
[ "0.774457", "0.68166023", "0.6498648", "0.63609046", "0.63004106", "0.6077415", "0.607255", "0.60448724", "0.6036745", "0.6031173", "0.60226095", "0.59748334", "0.5968414", "0.5945458", "0.59096646", "0.5887997", "0.58826303", "0.5873086", "0.5872704", "0.5830916", "0.5812570...
0.780865
0
Renders the about page.
def vsuQ(): return TvZl('about.html', title='About', year=qcWV.now().year, message='Your application description page.')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def vsuQ():\n return TvZl('about.html', title='About')", "def vsuQ():\n return TvZl('about_page.html', title='About')", "def vsuQ():\n return TvZl('about.html')", "def wZMb(YKHO):\n LgJI()", "def vsuQ():\n return TvZl('about.html', title='About', year=qcWV.now().year, message='about page.')"...
[ "0.85650355", "0.85034525", "0.84489655", "0.84044397", "0.8394454", "0.82935613", "0.82680845", "0.8243358", "0.8239194", "0.8224137", "0.82079816", "0.8204868", "0.8173699", "0.8172736", "0.80967313", "0.80501616", "0.80501616", "0.80501616", "0.80501616", "0.80501616", "0....
0.82709616
14
Renders the about page.
def nPrm(): return TvZl('data.html', title='Data', year=qcWV.now().year, message='Your application description page.')
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def vsuQ():\n return TvZl('about.html', title='About')", "def vsuQ():\n return TvZl('about_page.html', title='About')", "def vsuQ():\n return TvZl('about.html')", "def wZMb(YKHO):\n LgJI()", "def vsuQ():\n return TvZl('about.html', title='About', year=qcWV.now().year, message='about page.')"...
[ "0.85650355", "0.85034525", "0.84489655", "0.84044397", "0.8394454", "0.82935613", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82709616", "0.82680845",...
0.0
-1
Determines if an int x is a prime number or not.
def yaeE(WKvO): for r8hN in range(WKvO + 1): if r8hN != 0 and WKvO % r8hN == 0 and (r8hN != 1) and (WKvO != r8hN): return 'not prime' return 'prime'
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def T1qg(WKvO: int) -> bool:\n if WKvO < 2:\n return False\n if WKvO != 2 and WKvO % 2 == 0:\n return False\n for YRbF in range(3, WKvO // 2 + 1):\n if WKvO % YRbF == 0:\n return False\n return True", "def T1qg(WKvO):\n if WKvO < 2:\n return False\n for YR...
[ "0.8480145", "0.8293388", "0.8290251", "0.82423574", "0.8180706", "0.8097356", "0.80540764", "0.78323036", "0.7805404", "0.7762871", "0.76003283", "0.75857645", "0.7568783", "0.7463921", "0.7440969", "0.7424653", "0.7423773", "0.74233747", "0.7395108", "0.7384322", "0.7377971...
0.75968647
11
Determines if an int x is a prime number or not.
def MqvC(WKvO): for r8hN in range(WKvO + 1): if r8hN != 0 and WKvO % r8hN == 0 and (r8hN != 1) and (WKvO != r8hN): return 'not prime' return 'prime'
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def T1qg(WKvO: int) -> bool:\n if WKvO < 2:\n return False\n if WKvO != 2 and WKvO % 2 == 0:\n return False\n for YRbF in range(3, WKvO // 2 + 1):\n if WKvO % YRbF == 0:\n return False\n return True", "def T1qg(WKvO):\n if WKvO < 2:\n return False\n for YR...
[ "0.8480729", "0.82941467", "0.8290313", "0.8243459", "0.81811863", "0.80978733", "0.8054325", "0.7832635", "0.7806493", "0.7763111", "0.76008236", "0.7597179", "0.7587864", "0.757078", "0.7465418", "0.7442046", "0.7425363", "0.7424314", "0.7424235", "0.73969686", "0.7385942",...
0.7138134
44
This method saves annotation into a csvfile in the same directory
def v2Du(YKHO): if YKHO.mediaPlayer.state() == fvrL.PlayingState: YKHO.play_video() if YKHO.filename != None and YKHO.videoOpened: with open(YKHO.filename.replace('.mp4', '.csv'), 'w', newline='\n') as nUeQ: WJI9 = m6_J.writer(nUeQ) WJI9.writerow(['Time (ms)', 'Engagement...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def ERXd(YKHO) -> None:\n with open(YKHO.output_file_path, mode='w', newline='') as z36O:\n Mau6 = ['id', 'created_time', 'text']\n WJI9 = m6_J.DictWriter(z36O, fieldnames=Mau6)\n WJI9.writeheader()\n for Mau6 in YKHO.unique_tweets:\n try:\n WJI9.writerow(Ma...
[ "0.6945995", "0.6937179", "0.68908644", "0.6860856", "0.65973026", "0.65519875", "0.65171546", "0.6457847", "0.6428661", "0.6413525", "0.6413456", "0.6391844", "0.63836735", "0.63752145", "0.6344004", "0.6326677", "0.63209873", "0.6318571", "0.6298519", "0.62709415", "0.62699...
0.6813499
4
Format a number as friendly text, using common suffixes.
def i_Y3(FGW3, P8oC=1000, phJ9=0, ZI14='', OtqY=['', 'k', 'M', 'G', 'T', 'P', 'E', 'Z', 'Y']): from math import log, pow FJj_ = pow(10, phJ9) alOa = int(log(FGW3 * FJj_, P8oC)) naF9 = OtqY[alOa] if phJ9: KqlN = P8oC * alOa - phJ9 LWsi = str(FGW3)[:-KqlN] if FGW3[-KqlN] >= '5'...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def PQtn(YKHO, mLGw):\n vexM, VlDb = divmod(mLGw, 10)\n ZI14 = 'th' if vexM == 1 else YKHO.SUFFIX_DICT[VlDb]\n return f'{mLGw}{ZI14}'", "def eY98(FGW3):\n if FGW3 >= 1000 and FGW3 % 1000 == 0:\n return '%dk' % (FGW3 / 1000)\n else:\n return str(FGW3)", "def EG6h(mLGw):\n if mLGw...
[ "0.73528206", "0.69220096", "0.6893715", "0.6804232", "0.6795552", "0.6726488", "0.67208004", "0.66632074", "0.66446525", "0.65580165", "0.6546304", "0.6543475", "0.6506433", "0.6493464", "0.6483691", "0.64778715", "0.6362081", "0.6361462", "0.63492554", "0.6343249", "0.63406...
0.6698062
7
Forward computation of GP.
def KVH6(YKHO, WKvO): saqM = YKHO.mean_module(WKvO) ZZ2i = YKHO.covar_module(WKvO) return nSCh.distributions.MultivariateNormal(saqM, ZZ2i)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def KVH6(YKHO):\n YKHO.img_gen, YKHO.loss_reg, YKHO.parsav = YKHO.net_G(YKHO.input_P1, YKHO.input_P2, YKHO.input_BP1, YKHO.input_BP2, YKHO.input_SPL1, YKHO.input_SPL2)", "def W65V(YKHO):\n YKHO.gpf_core.eval()\n YKHO.likelihood.eval()\n return dJZO(YKHO.gpf_core, YKHO.options)", "def VoEF(YKHO):\n ...
[ "0.6641747", "0.6309967", "0.63030976", "0.622077", "0.61742026", "0.6147103", "0.6127859", "0.61094767", "0.6096206", "0.6092889", "0.60687995", "0.6052195", "0.60382044", "0.60378325", "0.6030578", "0.60295", "0.6021014", "0.6021014", "0.6018379", "0.60169804", "0.6001252",...
0.0
-1
Returns JSON for all categories
def SBNV(): cuiw = GhOX() LeZt = cuiw.query(qZuN).all() return pz3A(Categories=[Z9rn.serialize for Z9rn in LeZt])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def LH1I():\n return pz3A({'success': True, 'categories': mptU()})", "def y1ft():\n LeZt = N3tc()\n return pz3A(categories=[YRbF.serialize for YRbF in LeZt])", "def LQuW():\n try:\n Aofo = {'success': True, 'categories': LH1I()}\n return pz3A(Aofo)\n except Exception as exp:\n ...
[ "0.883001", "0.87606895", "0.8601942", "0.84640163", "0.84018344", "0.8397013", "0.8302538", "0.8235731", "0.81908923", "0.8152214", "0.8121078", "0.80614334", "0.8042234", "0.7812972", "0.7791831", "0.77038896", "0.7676202", "0.7607384", "0.7600428", "0.75892025", "0.7482158...
0.82008773
8
Shows JSON for all items in a category
def jnwe(VMw8): cuiw = GhOX() DumB = cuiw.query(kLxY).filter_by(category_id=VMw8) return pz3A(Items=[YRbF.serialize for YRbF in DumB])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Bf03(Ghho):\n Ghho = cuiw.query(eorc).filter_by(name=Ghho.replace('-', ' ')).one()\n UxbL = cuiw.query(QKm6).filter_by(category_id=Ghho.id).order_by(QKm6.name).all()\n return pz3A(category=[Ghho.serialize], items=[UxbL.serialize for UxbL in UxbL])", "def YsNi():\n DumB = NCls.getAllItems()\n r...
[ "0.83080703", "0.81895965", "0.77496374", "0.76800567", "0.76319146", "0.7613438", "0.75003475", "0.7458236", "0.7440922", "0.7435839", "0.74264675", "0.74047023", "0.73924065", "0.7299701", "0.72801924", "0.7247489", "0.7237604", "0.7204417", "0.71837586", "0.71017206", "0.7...
0.81000423
2
Edit an existing category
def Icd6(VMw8): if 'username' not in sGQh: return vKnz(nKyW('showLogin')) cuiw = GhOX() UsRV = cuiw.query(qZuN).filter_by(id=VMw8).one() if UsRV.user_id != sGQh['user_id']: return "<script>function myFunction() {alert('You are not authorized to edit this category.');}</script><body onloa...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Icd6(VMw8):\n UsRV = cuiw.query(qZuN).filter_by(id=VMw8).one()\n if UsRV.user_id != sGQh['user_id']:\n Dwep('You are not authorized to edit this Category. Please create your own Category in order to edit.')\n return vKnz(nKyW('showallCategories'))\n if QePW.method == 'POST':\n...
[ "0.77615225", "0.75865394", "0.7484915", "0.7453175", "0.73973197", "0.7290662", "0.7286859", "0.7284251", "0.72604495", "0.72559184", "0.7247768", "0.71632946", "0.7159087", "0.70904016", "0.7089819", "0.6985697", "0.6944363", "0.6929335", "0.6913795", "0.67967993", "0.67933...
0.6911405
19
Add a new experience to memory.
def H2v5(YKHO, QTBn, XeOP, vOGg, rxHc, _ins): tTpl = YKHO.experience(QTBn, XeOP, vOGg, rxHc, _ins) YKHO.memory.append(tTpl)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def wOcu(YKHO, QTBn, XeOP, vOGg, rxHc, _ins):\n tTpl = YKHO.experience(QTBn, XeOP, vOGg, rxHc, _ins, YKHO.max_priority)\n YKHO.memory.append(tTpl)", "def H2v5(YKHO, QTBn, XeOP, vOGg, rxHc, _ins):\n GsKL = XlZM(QTBn, XeOP, vOGg, rxHc, _ins)\n YKHO.memory.append(GsKL)", "def H2v5(YKHO, GsKL):\n YK...
[ "0.79568833", "0.79042006", "0.78795445", "0.7577913", "0.7570969", "0.74478436", "0.7361023", "0.72697705", "0.721816", "0.71451885", "0.7106998", "0.7101183", "0.69837016", "0.68905056", "0.68842727", "0.6755663", "0.6712557", "0.6677425", "0.64961654", "0.6488678", "0.6486...
0.71984994
14
Return the current size of internal memory.
def szAg(YKHO): return len(YKHO.memory)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def R8e4(YKHO) -> int:\n return len(YKHO.mem)", "def R8e4(YKHO):\n return YKHO.bf.memory()", "def ZGo4(YKHO):\n return YKHO.xlist('get-memsize')[1][0] * 1024", "def zNig(YKHO):\n zNig = 0\n zNig += YKHO.data.size * HwRy.getsizeof(YKHO.data)\n return zNig / 1024.0 / 1024.0 / 1024.0", "def ...
[ "0.8573752", "0.82169205", "0.8200361", "0.8087402", "0.8021614", "0.7890747", "0.78219426", "0.78017354", "0.77905464", "0.7758844", "0.77559924", "0.77559924", "0.775519", "0.77544576", "0.7733221", "0.7732168", "0.7720068", "0.77145016", "0.77092093", "0.77077913", "0.7697...
0.75127405
51
A utility function for TensorFlow that maps a grayscale image to a matplotlib colormap for use with TensorBoard image summaries. By default it will normalize the input value to the range 0..1 before mapping to a grayscale colormap.
def pAsL(BWXx, MynD=None, n4wC=None, iMGt=None): MynD = ZylS.reduce_min(BWXx) if MynD is None else MynD n4wC = ZylS.reduce_max(BWXx) if n4wC is None else n4wC BWXx = (BWXx - MynD) / (n4wC - MynD) BWXx = ZylS.squeeze(BWXx) _0VL = ZylS.to_int32(ZylS.round(BWXx * 255)) Bcwd = I8kJ.cm.get_cmap(iMGt ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def dS8V(Uiyh, iMGt=QrM1.get_cmap('seismic')):\n assert Uiyh.dtype == oyIN.uint8, 'must be np.uint8 image'\n if Uiyh.ndim == 3:\n Uiyh = Uiyh.squeeze(-1)\n vg0C = QrM1.cm.ScalarMappable(cmap=iMGt)\n W8dc = vg0C.to_rgba(oyIN.linspace(0, 1, 256))[:, 0:3]\n W8dc = (W8dc * 255.0).astype(oyIN.uint...
[ "0.7350804", "0.7083321", "0.6716462", "0.64663", "0.63197374", "0.62252384", "0.61969936", "0.61429065", "0.613792", "0.6119485", "0.6119485", "0.61130005", "0.6089074", "0.608681", "0.60644525", "0.6055049", "0.6055049", "0.6030544", "0.5985494", "0.59728986", "0.5951735", ...
0.66580176
3
This function prints and plots the confusion matrix.
def LwSz(A3RF, IpIH, NkkI=True, PXob=True, leAC=None, iMGt=QrM1.cm.Blues, aNZO=None): if PXob: assert NkkI is True, 'If you only want to see the absolute values, set normalize=False and show_absolute_values_additionally=False.' A3RF, IpIH = E_XH(A3RF, IpIH) assert set(A3RF.unique()) == set(IpIH.uniq...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def LwSz(YKHO):\n pTn1 = beib.from_learner(YKHO.learn)\n pTn1.plot_confusion_matrix()", "def zd4X(YKHO):\n gAeH.heatmap(YKHO.conf_matrix, annot=True)\n QrM1.plot(label='Accuracy')\n QrM1.plot(label='Error')\n QrM1.figtext(0, 0, 'Accuracy: {}\\nError: {}\\nRecall: {}\\nPrecision: {}'.format(YKHO...
[ "0.80894613", "0.80770946", "0.79976976", "0.7946727", "0.7921785", "0.78448296", "0.7833224", "0.7781221", "0.7775631", "0.77574563", "0.77061635", "0.77016985", "0.7692213", "0.76785815", "0.76588994", "0.7641414", "0.7622791", "0.7611233", "0.7610989", "0.7598244", "0.7587...
0.0
-1
Create and initialize a Food instance at a random location.
def FIMM(YKHO): YKHO.size = 16 YKHO.color = pgBE YKHO.pos = YKHO.spawn()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def z7eR(YKHO):\n YKHO.penup()\n YKHO.shape('circle')\n YKHO.color('green')\n YKHO.x_cordinates = tuKI.randint(-210, 210)\n YKHO.y_cordinates = tuKI.randint(-210, 210)\n YKHO.goto(YKHO.x_cordinates, YKHO.y_cordinates)\n print(f'This Is Food {YKHO.x_cordinates} and {YKHO.y_cordinates}')", "de...
[ "0.7258518", "0.72439694", "0.7177458", "0.6774872", "0.65232736", "0.6334905", "0.63251776", "0.6026828", "0.60096884", "0.59833336", "0.59739894", "0.59222424", "0.58326286", "0.58295906", "0.5782747", "0.57608205", "0.57145053", "0.5702807", "0.56994814", "0.56994814", "0....
0.0
-1
Checks if the snake has collided with food.
def fMy9(y45w, Ptl6): SzMi = y45w.get_corners() TeVK, VkCh = Ptl6.pos for BHsk in SzMi: if TeVK <= BHsk[0] <= TeVK + Ptl6.size and VkCh <= BHsk[1] <= VkCh + Ptl6.size: return True return False
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def hX1k(EX77, iBIi):\n if EX77.snake[-1][0] >= len(iBIi.board[0]) or EX77.snake[-1][1] >= len(iBIi.board) or EX77.snake[-1][0] < 0 or (EX77.snake[-1][1] < 0):\n return True\n else:\n for YRbF in EX77.snake[:-1]:\n if YRbF[:-1] == EX77.snake[-1][:-1]:\n return True\n ...
[ "0.673648", "0.665959", "0.655808", "0.64771265", "0.64431435", "0.6432231", "0.6321876", "0.6310432", "0.622189", "0.62033993", "0.6196929", "0.6122961", "0.61153966", "0.6104553", "0.61036026", "0.6100859", "0.60873884", "0.6083682", "0.6077472", "0.60522324", "0.6039057", ...
0.7127346
0
Sends a 401 response that enables basic auth
def NLCy(): return oGir('Could not verify your access level for that URL.\nYou have to login with proper credentials', 401, {'WWW-Authenticate': 'Basic realm="Login Required"'})
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def NLCy():\n return oGir('Not Authorized', 401, {'WWW-Authenticate': 'Basic realm=\"api\"'})", "def NLCy():\n return oGir('', 401, {'WWW-Authenticate': 'Basic realm=\"Login Required\"'})", "def NLCy():\n return oGir('You have to login with proper credentials', 401, {'WWW-Authenticate': 'Basic realm=\...
[ "0.8093736", "0.80926424", "0.7958403", "0.7852648", "0.7843114", "0.7824419", "0.776624", "0.7754693", "0.774767", "0.774767", "0.774767", "0.774767", "0.774767", "0.774767", "0.774767", "0.774767", "0.771945", "0.7667712", "0.7664151", "0.76493174", "0.76140213", "0.76131...
0.7810746
21
return the minimum node in the current tree and its parent
def zebL(tk5Y, _AKB): if tk5Y.left: return zebL(tk5Y.left, tk5Y) else: return [_AKB, tk5Y]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def Rr1k(YKHO):\n ZbOB = YKHO\n while ZbOB.hasLeftChild():\n ZbOB = ZbOB.leftChild\n return ZbOB", "def min(YKHO) -> 'Node':\n jvSB = YKHO\n while jvSB.left is not None:\n jvSB = jvSB.left\n return jvSB", "def XcNI(YKHO) -> i8DB:\n Q6kx = YKHO.root\n while True:\n i...
[ "0.8434743", "0.8419657", "0.8370293", "0.8337083", "0.8336324", "0.81882983", "0.8024447", "0.7963267", "0.7945418", "0.7922297", "0.78959215", "0.7886263", "0.78434896", "0.7841628", "0.780715", "0.7804364", "0.7801873", "0.78014004", "0.7779413", "0.77767795", "0.7775762",...
0.7795441
18
Sets the weights of the network.
def sNuA(YKHO, _mSQ): YKHO.model.set_weights(_mSQ)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def sNuA(YKHO, _mSQ):\n YKHO.weights = _mSQ", "def sNuA(YKHO, _mSQ):\n YKHO._weights = _mSQ\n YKHO.normalize_weights()", "def pOke(YKHO, yzQ0):\n raise NotImplementedError", "def sNuA(YKHO, _mSQ):\n YKHO._cnn_model.set_weights(_mSQ)", "def L1EB(YKHO, _mSQ):\n YKHO.weights = _mSQ.reshape(Y...
[ "0.8667217", "0.83887863", "0.83845794", "0.8323693", "0.8274516", "0.8186342", "0.81543875", "0.8146573", "0.8072383", "0.7974805", "0.7818139", "0.77234143", "0.76913023", "0.76769984", "0.7662948", "0.7629317", "0.7611106", "0.750819", "0.74728924", "0.7452836", "0.7426908...
0.8471266
1
Returns the last known robot state.
def QTBn(YKHO): return YKHO._state
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def o_r0(YKHO):\n return YKHO._simstate", "def GBfH(YKHO):\n return tuple([fQxG.getState() for fQxG in YKHO.states.robots])", "def c0mt(YKHO):\n return YKHO.nextYs[-1]", "def bGIA(YKHO):\n yKcO = YKHO.design.first_unassigned_site\n return YKHO.target.padded_encoding[yKcO:yKcO + 2 * YKHO._env_c...
[ "0.77621424", "0.6890938", "0.67844445", "0.67405826", "0.6702575", "0.6570389", "0.6570389", "0.6567205", "0.6562156", "0.6549177", "0.6381263", "0.63676935", "0.6361479", "0.6324109", "0.631558", "0.6298601", "0.628945", "0.627949", "0.6241313", "0.6239475", "0.6225606", ...
0.0
-1
The function that calculates the area of the circle.
def GagE(r1VO): f0tD = epAf.pi * r1VO ** 2 print('Area of a circle with a radius of', r1VO, 'is', format(f0tD, '.3f'))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def f0tD(YKHO):\n yX2h = YKHO.radius * YKHO.radius * epAf.pi\n return yX2h", "def yX2h(FV9o):\n return mM0K * FV9o.radius * FV9o.radius", "def LA4l(r1VO):\n return r1VO", "def f0tD(YKHO):\n return YKHO.radius * YKHO.radius * epAf.pi", "def f0tD(YKHO):\n return YKHO.__radius ** 2 * epAf.pi...
[ "0.8587596", "0.848864", "0.8409465", "0.8229764", "0.81595844", "0.81477517", "0.81477517", "0.81258476", "0.8081637", "0.80605143", "0.8060146", "0.8006663", "0.79962665", "0.79309183", "0.7910182", "0.79089034", "0.79089034", "0.7886087", "0.78828156", "0.7881819", "0.7879...
0.75572926
31
Test posting question with a meetup that does not exist
def Xahs(YKHO): YKHO.is_authenticated() geh0 = YKHO.post_with_invalid_meetup() YKHO.assertEqual(geh0.status_code, jGRS.HTTP_404_NOT_FOUND)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def UXc_(YKHO):\n NT__ = YKHO.get_access_token(l5P9, rTui)\n Ylbp = YKHO.client().post('/api/v2/meetups/3/questions', headers=YKHO.get_authentication_headers(NT__), data=qQXR.dumps(K0Sb))\n _6Yp = qQXR.loads(Ylbp.data.decode('UTF-8'))\n YKHO.assertEqual(Ylbp.status_code, 404)\n YKHO.assertEqual(_6Yp...
[ "0.79283535", "0.78844965", "0.7780807", "0.74110353", "0.70628846", "0.6910175", "0.68341684", "0.6688663", "0.65296674", "0.64422226", "0.6441639", "0.6358516", "0.6309955", "0.63084716", "0.630011", "0.6247281", "0.6233546", "0.618738", "0.6132114", "0.61253196", "0.611113...
0.70985174
4
Apply nametoSMILES followed by SMILEStoname in order to get the most common synonym.
def Sowd(mWFP: str) -> str: return yHxB.get_name(_4Pu.get_smiles(mWFP))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def E3w1(BeKe, UglV, fEbr=None):\n E3w1 = IYn5(BeKe, UglV)\n Rlk1 = 0\n if fEbr:\n Rlk1 = IYn5(BeKe, fEbr)\n return max(E3w1, Rlk1)", "def bFHh(mnjh):\n return wHLx.to_smiles(wHLx.from_smiles(mnjh))", "def ZKLx(GIN8, oIwh, oeNL, max=20):\n PVn9 = []\n UHFx = 0\n UyRf = WnSJ.synse...
[ "0.5567552", "0.54505587", "0.5430771", "0.5407319", "0.5357292", "0.52925265", "0.52693975", "0.5251148", "0.52120805", "0.5211241", "0.5204867", "0.5151238", "0.5089193", "0.5075725", "0.50606203", "0.5030442", "0.50104207", "0.5007268", "0.4992866", "0.49832612", "0.490626...
0.57638913
0
Given the method, returns the sparsity of individual layers as a dict. It ensures that the noncustom layers have a total parameter count as the one with uniform sparsities. In other words for the layers which are not in the custom_sparsity_map the following equation should be satisfied. eps (p_1 N_1 + p_2 N_2) = (1 def...
def q2EJ(yR_P, InLe, NRfx: float=1.0): oGem = {} f3bG = 0 for tTpl, (mWFP, upAO) in enumerate(yR_P.named_parameters()): if tTpl == 0: continue if 'bias' in mWFP: continue if 'bn' in mWFP: continue begE = upAO.device oGem[mWFP] = ht2...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def xVj0():\n lsKL = oyIN.array([[0, 2, 0], [1, 0, 1]])\n assert Yh4i.calc_layer_sparsity(lsKL) == 3 / 6, 'correct sparsity value'\n lsKL = oyIN.array([[0, 0, 0], [1, 0, 1]])\n assert abs(Yh4i.calc_layer_sparsity(lsKL) - 4 / 6) < 10 ** (-8), 'correct sparsity value'\n assert Yh4i.calc_layer_sparsity...
[ "0.6673358", "0.64702046", "0.61595726", "0.59427774", "0.59129184", "0.5850378", "0.5764688", "0.5719997", "0.5428686", "0.5256658", "0.5217889", "0.5098781", "0.5084118", "0.50652313", "0.5055327", "0.49596298", "0.49549872", "0.49484617", "0.49153554", "0.49078938", "0.490...
0.5546462
8
Returns True if there are no elements in the queue. Otherwise it returns False.
def FBfn(YKHO) -> bool: bool = YKHO.da.is_empty() return bool
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def A4KR(YKHO):\n if len(YKHO.queue) >= 1:\n return False\n else:\n return True", "def FBfn(YKHO):\n return YKHO.queue == []", "def lsmZ(YKHO):\n return YKHO.queue == []", "def FBfn(YKHO):\n return len(YKHO.the_queue) == 0", "def A4KR(YKHO):\n return 0 == len(YKHO.queue)", ...
[ "0.87986565", "0.8726819", "0.8704334", "0.86796826", "0.8668438", "0.8637949", "0.86193", "0.861574", "0.861574", "0.8607098", "0.86000097", "0.85499406", "0.85468006", "0.85262203", "0.8524336", "0.8516299", "0.8516299", "0.84909976", "0.84512603", "0.83862245", "0.8368072"...
0.0
-1
Returns the number of elements currently in the queue.
def zNig(YKHO) -> int: zNig = YKHO.da.length() return zNig
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def zNig(YKHO):\n return len(YKHO.queue)", "def zNig(YKHO):\n return len(YKHO.queue)", "def zNig(YKHO):\n return len(YKHO.__queue)", "def zNig(YKHO):\n return len(YKHO.queue)", "def zNig(YKHO):\n return len(YKHO.queue)", "def zNig(YKHO):\n return len(YKHO.queue)", "def zNig(YKHO):\n ...
[ "0.8237019", "0.8237019", "0.82012993", "0.81914973", "0.81914973", "0.81914973", "0.81914973", "0.81080407", "0.809926", "0.8027969", "0.7825087", "0.7792135", "0.77872556", "0.76787645", "0.76511407", "0.7644449", "0.75612724", "0.7561232", "0.7561232", "0.7537529", "0.7491...
0.0
-1
The name of the ticket has to be alphanumericonly, and space allowed only if its nit the first or last character R4.1
def dtFC(YKHO, *bGrB): YKHO.open(NKRf + '/logout') YKHO.open(NKRf + '/login') YKHO.type('#email', 'test_frontend@test.com') YKHO.type('#password', 'Test_frontend@') YKHO.click('input[type="submit"]') YKHO.open(NKRf) YKHO.type('#name_sell', ' invalid ') YKHO.type('#price_sell', '100') ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def rN5e(YKHO):\n str = ksDJ.objects.create_ticket_str(prefix='PGTIOU')\n YKHO.assertTrue(ZbWC.search('^PGTIOU-[0-9]{10,}-[a-zA-Z0-9]{32}$', str))", "def SREd(YKHO):\n mWFP = YKHO.cleaned_data['name']\n if not ZbWC.match('[\\\\w{4}\\\\s*]+', mWFP) or len(mWFP) < 4:\n iaxi('no_name')\n retur...
[ "0.6576218", "0.64795166", "0.63711756", "0.63362515", "0.63227195", "0.6286395", "0.6153223", "0.6123057", "0.60411745", "0.5988169", "0.59772235", "0.59566253", "0.5947071", "0.5926102", "0.59047323", "0.5888616", "0.58557814", "0.5835133", "0.58285314", "0.58118176", "0.58...
0.710681
0
The quantity of the tickets has to be more than 0, and less than or equal to 100. R4.3
def tLTY(YKHO, *bGrB): YKHO.open(NKRf + '/logout') YKHO.open(NKRf + '/login') YKHO.type('#email', 'test_frontend@test.com') YKHO.type('#password', 'Test_frontend@') YKHO.click('input[type="submit"]') YKHO.open(NKRf) YKHO.type('#name_sell', 'ticketname') YKHO.type('#quantity_sell', '-1') ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def fbA4(YKHO):\n FIL5 = YKHO._uncertain_demand.excess_stock\n _l9b = sum([int(ZfUD) for ZfUD in YKHO._data_set.values()]) // len(YKHO._data_set)\n I8JS = [ZfUD - _l9b for ZfUD in YKHO._data_set.values()]\n ee6l = pow(sum([pow(r845, 2) for r845 in I8JS]) / len(YKHO._data_set), 0.5)\n sQRI = lambda W...
[ "0.6076991", "0.5975765", "0.5935471", "0.5926505", "0.5924432", "0.585127", "0.5844957", "0.57967985", "0.5774268", "0.575084", "0.57310635", "0.57255524", "0.5691946", "0.56739944", "0.5643781", "0.56285113", "0.56178635", "0.5608882", "0.55876267", "0.55841124", "0.5579207...
0.6294424
0
The price has to be of range [10,100] R4.4
def NTRQ(YKHO, *bGrB): YKHO.open(NKRf + '/logout') YKHO.open(NKRf + '/login') YKHO.type('#email', 'test_frontend@test.com') YKHO.type('#password', 'Test_frontend@') YKHO.click('input[type="submit"]') YKHO.open(NKRf) YKHO.type('#name_sell', 'testticket') YKHO.type('#quantity_sell', '1') ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def N_Zi():\n return js4S(1.0, 350.0)", "def qNIk(YKHO):\n hI0L = YKHO.price\n XeOP = YKHO.action\n zCj1 = 5\n if XeOP == 'RESIDENTIAL_SALE':\n return hI0L * 12 * zCj1\n if hI0L >= 10000:\n return hI0L * 0.7\n elif hI0L < 10000 & hI0L >= 5000:\n return hI0L * 0.55\n e...
[ "0.7284983", "0.69276345", "0.6759089", "0.6723851", "0.66512525", "0.66477984", "0.66477984", "0.64932793", "0.64932793", "0.6424603", "0.64102423", "0.6408866", "0.6307366", "0.628541", "0.62727803", "0.62725234", "0.62712115", "0.62647533", "0.6254314", "0.62294394", "0.62...
0.6222976
20
Convert a date or time string into an arrow object in UTC
def LIiN(jmHs, yl4j='US/Pacific'): a1PO = None try: a1PO = LgWF.get(jmHs) if len(jmHs.split('+')) == 1: a1PO = a1PO.replace(tzinfo=yl4j) except LgWF.parser.ParserError: GQJo = eCDK.Calendar() GgvZ = GQJo.parse(jmHs) if GgvZ[1] == 0: raise Value...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def KCz9(tUMc, rIAI):\n MvAv = wvEv.parse(tUMc)\n mz4v = FXGE.timezone(rIAI)\n eGZQ = mz4v.localize(MvAv)\n Ihgv = FXGE.utc.normalize(eGZQ)\n return Ihgv", "def CHus(h5YN) -> JRYC.datetime:\n return bifY.parse_date(h5YN)", "def Y0Wo(cTyu):\n ZCQF = LgWF.get(cTyu)\n Elpc = ZCQF.to('local...
[ "0.6379972", "0.63689584", "0.63480586", "0.6195369", "0.6145286", "0.61293244", "0.6017762", "0.60128754", "0.60054386", "0.6003779", "0.59517395", "0.5862127", "0.5833879", "0.57739145", "0.5755738", "0.57443655", "0.57159567", "0.5673042", "0.565728", "0.56556016", "0.5600...
0.60133666
7
Convert a given time interval (e.g. '5m') into the number of seconds in that interval
def wbKR(jmHs): GQJo = eCDK.Calendar() GgvZ = GQJo.parseDT(jmHs, sourceTime=qcWV.min) if GgvZ[1] == 0: raise ValueError('Could not understand time {time}'.format(time=jmHs)) return (GgvZ[0] - qcWV.min).total_seconds()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def eckt(VOlW):\n if type(VOlW) is str:\n rJBd = VOlW.split(' ')\n try:\n C6wh = int(rJBd[0]) * tnKw[rJBd[1]]\n except KeyError:\n raise ValueError('Valid time scales are: {}'.format(list(tnKw.keys())))\n except ValueError:\n raise ValueError(\"\\n ...
[ "0.77735597", "0.6997003", "0.69709396", "0.6849573", "0.6816949", "0.6771826", "0.6753928", "0.67522997", "0.67239225", "0.6712131", "0.66843265", "0.6681593", "0.6676878", "0.6674106", "0.6672589", "0.66631174", "0.6643966", "0.6628711", "0.6628501", "0.6617979", "0.6617979...
0.6691363
10
Close connection to SUMO
def tBIc(YKHO): By1I.close()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def zml5(YKHO):\n print('closing connection...')\n YKHO.s.close()\n quit()", "def DDI8(YKHO):\n YKHO.connection = None", "def ngVb(YKHO):\n YKHO.session.close()", "def DDI8(YKHO):\n YKHO.connection.close()", "def DDI8(YKHO):\n YKHO._connection.close()", "def ngVb(YKHO):\n YKHO.con...
[ "0.7795134", "0.7469527", "0.74574894", "0.74283755", "0.7342986", "0.7335586", "0.7326172", "0.7304553", "0.7279674", "0.7279674", "0.7235826", "0.7233592", "0.72099066", "0.71759844", "0.7118848", "0.7098822", "0.70972496", "0.70972496", "0.70972496", "0.70972496", "0.70972...
0.0
-1