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 |
|---|---|---|---|---|---|---|
Convert all but the outer rows/columns back into lists of strings | def Z5_c(YKHO) -> x1iM[str]:
JhrZ = sorted(set((int(YRbF.imag) for YRbF in YKHO.tile)))
QGnf = sorted(set((int(YRbF.real) for YRbF in YKHO.tile)))
IA3S = QGnf[-1]
JRC0 = QGnf[1]
dCLF = JhrZ[-1]
LChT = JhrZ[1]
Aofo = [''.join(('#' if YKHO.tile[WKvO + 1j * LVAh] else '.' for WKvO in range(JRC0... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eK7y(YKHO) -> x1iM[str]:\n sWfS = []\n for rdlD in YKHO.tiles:\n zlZp = []\n for eL5z in rdlD:\n zlZp.append(str(eL5z))\n sWfS.append(''.join(zlZp))\n return sWfS",
"def I1FV(YKHO):\n return [rdlD[1:-1] for rdlD in YKHO.data[1:-1]]",
"def usx6(YKHO, PypT: List[Tu... | [
"0.62706155",
"0.6141588",
"0.6139036",
"0.6116373",
"0.60903555",
"0.6069135",
"0.59834963",
"0.58480436",
"0.58453107",
"0.5818919",
"0.57952845",
"0.5777887",
"0.5745512",
"0.5712667",
"0.56868005",
"0.566454",
"0.5662942",
"0.56593895",
"0.5657654",
"0.56457186",
"0.56414... | 0.0 | -1 |
Ran when the bot has connected to discord and is ready. | async def on_ready(YKHO) -> None:
bo34.info('Bot online')
await YKHO.startup_greeting() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def on_ready():\n print(f'{JyK9.user.name} has connected to Discord!')",
"async def on_ready(YKHO):\n print(f'{YKHO.bot.user.name} has connected to Discord!')",
"async def on_ready():\n print(f'{JyK9.user.name} has connected to Discord.')",
"async def on_ready(YKHO):\n if YKHO.running:\n ... | [
"0.86749643",
"0.8499521",
"0.8423054",
"0.8249751",
"0.823922",
"0.8195226",
"0.818236",
"0.8135956",
"0.8135233",
"0.8130573",
"0.809955",
"0.80492395",
"0.8029596",
"0.80002576",
"0.79745036",
"0.7946186",
"0.7917735",
"0.78389955",
"0.78328526",
"0.7825843",
"0.7825843",
... | 0.78684115 | 17 |
Test _is_new_json_file_generated with different situations. | def iTdP(YKHO, JBFK, Svq2):
IUlj = 'path/test.json'
JBFK.return_value = False
YKHO.assertFalse(X1Nz._is_new_json_file_generated(IUlj, None))
JBFK.return_value = True
YKHO.assertTrue(X1Nz._is_new_json_file_generated(IUlj, None))
R2X_ = 1000
Svq2.return_value = R2X_
YKHO.assertFalse(X1Nz._... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nrhG(YKHO):\n YKHO.save_main()\n P8oC = KcDH()\n P8oC.save()\n with open('file.json', 'r') as eHNT:\n vIwR = qQXR.load(eHNT)\n YKHO.assertTrue(vIwR is not None)\n Hy7s.remove('file.json')\n YKHO.load_main()",
"def hgv5(YKHO):\n Vo9x = {'test': 0}\n XN37.jsonfile_append(YKHO.... | [
"0.70575947",
"0.6908034",
"0.6817781",
"0.6526811",
"0.6487629",
"0.64600474",
"0.64034426",
"0.6351317",
"0.6321164",
"0.63197684",
"0.6318443",
"0.6316211",
"0.62844133",
"0.62702185",
"0.61856866",
"0.6175081",
"0.6154393",
"0.6141589",
"0.6132465",
"0.6128865",
"0.612844... | 0.77148795 | 0 |
Parse the response error code and return the related error type. | def hfK9(geh0):
xrpC = {400: XhQd, 401: Fx5K, 403: Ochu, 404: FJJi, 408: _Vsc, 429: yVXo, 500: M6rt, 503: iyP6}
try:
zs78 = geh0.json()
Ol8d = zs78['message']
Wxnj = zs78['code']
jGRS = int(zs78['status'])
if not jGRS in xrpC:
return gteG('{} - {}: {}'.format(... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def aqGw(YKHO, geh0):\n if geh0.get('status_code') in (403, 500, 503):\n return geh0.get('status_txt', 'UNKNOWN_ERROR')\n if geh0.get('status_code') == 200:\n return 'Unknown Error occurred. This could be due to invalid, malformed or rate-limited json'",
"def Y03z(Emd4, geh0):\n TBsA = geh... | [
"0.7505211",
"0.730732",
"0.7202267",
"0.7063476",
"0.70302457",
"0.7002261",
"0.6976985",
"0.68383825",
"0.6831371",
"0.6804864",
"0.67924464",
"0.6787669",
"0.675683",
"0.6719738",
"0.66425306",
"0.6617098",
"0.65860575",
"0.65831554",
"0.6574482",
"0.6566607",
"0.6553552",... | 0.6738779 | 13 |
Add two numbers together. | def H2v5(WKvO, LVAh):
G9jH.info('Added {first} and {second} to get {total}'.format(first=WKvO, second=LVAh, total=WKvO + LVAh)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def V6lN(_1qI, zDMu):\n Aofo = _1qI + zDMu\n return Aofo",
"def V6lN(WKvO, LVAh):\n epBp = WKvO + LVAh\n return epBp",
"def V6lN(_1qI, zDMu):\n H2v5 = zDMu + _1qI\n return H2v5",
"def H2v5(WKvO, LVAh):\n return int(WKvO) + int(LVAh)",
"def H2v5(B58t, XfrR):\n return B58t + XfrR",
... | [
"0.8415431",
"0.83613294",
"0.82720965",
"0.8266305",
"0.8236224",
"0.8200543",
"0.8179775",
"0.81358606",
"0.81358606",
"0.81225115",
"0.80879265",
"0.8057827",
"0.8057827",
"0.8057827",
"0.8057827",
"0.8057827",
"0.80366576",
"0.80353975",
"0.8031708",
"0.8026514",
"0.80258... | 0.0 | -1 |
Test creating recipe with tags | def xsEp(YKHO):
R9U6 = eo18(user=YKHO.user, name='Vegan')
GTT9 = eo18(user=YKHO.user, name='Dessert')
pB3N = {'title': 'Avocado lime cheesecake', 'tags': [R9U6.id, GTT9.id], 'time_minutes': 60, 'price': 20.0}
Ylbp = YKHO.client.post(tQ6t, pB3N)
YKHO.assertEqual(Ylbp.status_code, jGRS.HTTP_201_CREATE... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZQ0k(YKHO):\n R9U6 = ayqs(user=YKHO.user)\n GTT9 = ayqs(user=YKHO.user)\n pB3N = {'title': 'Sausages', 'tags': [R9U6.id, GTT9.id], 'time_minutes': 10, 'price': 5.0}\n bD7m = gxEw('recipe:recipe-list')\n Ylbp = YKHO.client.post(bD7m, pB3N)\n YKHO.assertEqual(Ylbp.status_code, jGRS.HTTP_201_CRE... | [
"0.8394875",
"0.83743906",
"0.8338097",
"0.8333908",
"0.83248657",
"0.8295931",
"0.8293075",
"0.8286255",
"0.82838273",
"0.828009",
"0.82714",
"0.82691216",
"0.82629526",
"0.8249101",
"0.8228768",
"0.822333",
"0.79692185",
"0.78645647",
"0.77285874",
"0.75258005",
"0.75195384... | 0.83058316 | 5 |
Test creating recipe with other's user tags | def _MZr(YKHO):
uDCI = lYUQ('other@dev.com', 'OtherPassword')
R9U6 = eo18(user=YKHO.user, name='Beef')
GTT9 = eo18(user=uDCI, name='Mutton')
pB3N = {'title': 'Meat stew', 'tags': [R9U6.id, GTT9.id], 'time_minutes': 60, 'price': 100}
Ylbp = YKHO.client.post(tQ6t, pB3N)
YKHO.assertEqual(Ylbp.statu... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZQ0k(YKHO):\n R9U6 = ayqs(user=YKHO.user)\n GTT9 = ayqs(user=YKHO.user)\n pB3N = {'title': 'Sausages', 'tags': [R9U6.id, GTT9.id], 'time_minutes': 10, 'price': 5.0}\n bD7m = gxEw('recipe:recipe-list')\n Ylbp = YKHO.client.post(bD7m, pB3N)\n YKHO.assertEqual(Ylbp.status_code, jGRS.HTTP_201_CRE... | [
"0.8128354",
"0.7979438",
"0.79559356",
"0.7948519",
"0.79444003",
"0.7922569",
"0.7914769",
"0.7912667",
"0.79123235",
"0.79077506",
"0.79073334",
"0.79008263",
"0.78889203",
"0.78744847",
"0.7845039",
"0.78374046",
"0.7646464",
"0.7557042",
"0.75271153",
"0.7402837",
"0.735... | 0.8613212 | 0 |
Test uploading an invalid image | def gopI(YKHO):
bD7m = xx5i(YKHO.recipe.id)
Ylbp = YKHO.client.post(bD7m, {'image': 'notimage'}, format='multipart')
YKHO.assertEqual(Ylbp.status_code, jGRS.HTTP_400_BAD_REQUEST) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zwC5(YKHO):\n bD7m = xx5i(YKHO.recipe.id)\n Ylbp = YKHO.client.post(bD7m, {'image': 'notimage'}, format='multipart')\n YKHO.assertEqual(Ylbp.status_code, jGRS.HTTP_400_BAD_REQUEST)",
"def Vt_3(YKHO):\n bD7m = nXsP(YKHO.recipe.id)\n Ylbp = YKHO.client.post(bD7m, {'image': 'not image'}, format='... | [
"0.8583424",
"0.8558244",
"0.85374063",
"0.8413656",
"0.8373553",
"0.83652174",
"0.8359964",
"0.83317864",
"0.8331326",
"0.8331326",
"0.83073425",
"0.8296584",
"0.8270422",
"0.8270132",
"0.82606834",
"0.8249335",
"0.820451",
"0.80751884",
"0.78633493",
"0.7782769",
"0.7782769... | 0.8360783 | 6 |
Returns list of probabilities associated with the sigma values given in sigvals. | def SsgR(rkIW=[1, 2, 3]):
return oyIN.array([1.0 - 2 * eQSh.norm.sf(KCHu) for KCHu in rkIW]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cq38(T6S7):\n flrn = [0 for wEf2 in range(0, max(T6S7))]\n kUYK = [wEf2 + 1 for wEf2 in range(0, max(T6S7))]\n for BWXx in T6S7:\n flrn[BWXx - 1] += 1\n flrn = [QTg7 / len(T6S7) for QTg7 in flrn]\n return (kUYK, flrn)",
"def GeT2(Y7fn, nEj5):\n BFeB = []\n for yGTL, wEsz in nEj5:\... | [
"0.66423625",
"0.63785213",
"0.6238721",
"0.5795247",
"0.5741198",
"0.56564987",
"0.5646803",
"0.56341565",
"0.55902356",
"0.55886894",
"0.55432034",
"0.5540176",
"0.55036014",
"0.54986066",
"0.5497783",
"0.5442476",
"0.5437453",
"0.54116386",
"0.54083854",
"0.5400376",
"0.53... | 0.8483829 | 0 |
Resets the sensobs objects | def ponW(YKHO):
for U6Nt in YKHO.sensobs:
U6Nt.reset() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Flko(YKHO):\n YKHO.N.fill(0)\n YKHO.S.fill(0)\n YKHO.V.fill(0)\n YKHO.num_episodes = 0",
"def SiRx(YKHO):\n for yCnv in YKHO.surflist:\n o4sw, V6IE, lWPh = yCnv\n o4sw.reset()",
"def SiRx(YKHO):\n H5R5 = Jipm.get_instance().get_scales()\n YKHO.controller.update_sim(vztu.S... | [
"0.6897717",
"0.68556297",
"0.68417335",
"0.6839053",
"0.6716184",
"0.6713747",
"0.6689073",
"0.6683587",
"0.6676253",
"0.66635376",
"0.66585356",
"0.6611762",
"0.6594575",
"0.6572114",
"0.6568843",
"0.6547784",
"0.65335464",
"0.6506824",
"0.6494933",
"0.6488503",
"0.6465082"... | 0.8238858 | 0 |
Returns a string representation of the instance | def zAg0(YKHO):
b5m0 = YKHO.__class__.__name__
cmPJ = YKHO.to_dict()
del cmPJ['__class__']
return '[{}] ({}) {}'.format(b5m0, YKHO.id, cmPJ) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gTzM(YKHO, KAOR):\n raise NotImplementedError",
"def zAg0(YKHO):\n return '<{} instance>'.format(type(YKHO).__name__)",
"def zAg0(YKHO):\n return YKHO.tostring()",
"def zAg0(YKHO):\n return repr(YKHO)",
"def zAg0(YKHO):\n return repr(YKHO)",
"def wHJl(YKHO):\n return YKHO.to_str()",... | [
"0.84627634",
"0.83538115",
"0.8312541",
"0.829831",
"0.829831",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"0.82934636",
"... | 0.0 | -1 |
Convert instance into dict format | def MNRr(YKHO):
cmPJ = {}
cmPJ.update(YKHO.__dict__)
cmPJ.update({'__class__': str(type(YKHO)).split('.')[-1].split("'")[0]})
cmPJ['created_at'] = YKHO.created_at.isoformat()
cmPJ['updated_at'] = YKHO.updated_at.isoformat()
if '_sa_instance_state' in cmPJ:
del cmPJ['_sa_instance_state']
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def OL85(YKHO):\n return YKHO.to_dict()",
"def MNRr(YKHO):\n fGC9 = lKKu(YKHO, dict_factory=Z0Ic)\n return fGC9",
"def MNRr(YKHO) -> dict:\n return lKKu(YKHO)",
"def qssR(YKHO):\n return YKHO.to_dict()",
"def qssR(YKHO):\n return YKHO.to_dict()",
"def qssR(YKHO):\n return YKHO.to_dic... | [
"0.7914745",
"0.7891879",
"0.78717077",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
"0.7832002",
... | 0.79295677 | 0 |
An id representing the guild. | def LRlk(YKHO):
return YKHO.msg.guild.id | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def jj4O(YKHO) -> h8nf[int]:\n return getattr(YKHO, QA7C, None)",
"def wo3S(lSCo):\n if isinstance(lSCo, Ows6):\n return lSCo.id\n LRlk = rzSR(lSCo)\n if LRlk is not None:\n return LRlk\n raise TypeError(f'`guild` can be `{Ows6.__name__}`, `int`, got {lSCo.__class__.__name__}; {lSCo!... | [
"0.8091941",
"0.7292697",
"0.7259645",
"0.69625115",
"0.69448394",
"0.69331604",
"0.69331604",
"0.6858706",
"0.68433166",
"0.6706782",
"0.65631783",
"0.6553771",
"0.6545139",
"0.6540785",
"0.6525382",
"0.64447045",
"0.641379",
"0.640373",
"0.63895047",
"0.63895047",
"0.638309... | 0.83484685 | 0 |
Sets the user's password always use this rather than directly | def G3s8(YKHO, Ud05):
YKHO.password = D2Lq(Ud05)
YKHO.save()
return YKHO | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zZft(YKHO, zN5h):\n YKHO.pwd = zN5h",
"def zZft(YKHO, zN5h):\n YKHO.pwd = zN5h",
"def m_qJ(YKHO, jTXt):\n YKHO._password = jTXt",
"def G3s8(YKHO, jTXt):\n D2Lq(jTXt)",
"def jTXt(YKHO, BWXx):\n if not BWXx:\n return\n YKHO._password = BWXx",
"def PnS7(YKHO, jTXt):\n YKHO.pa... | [
"0.8649518",
"0.85834587",
"0.8581139",
"0.8507244",
"0.84506756",
"0.8413941",
"0.8383121",
"0.83708924",
"0.8316505",
"0.8240084",
"0.8167417",
"0.81323254",
"0.81323254",
"0.81200784",
"0.8119123",
"0.8104945",
"0.80770475",
"0.80770475",
"0.80770475",
"0.80770475",
"0.807... | 0.0 | -1 |
Returns True if the user has the specified permission. This method queries all available auth backends, but returns immediately if any backend returns True. Thus, a user who has permission from a single auth backend is assumed to have permission in general. If an object is provided, permissions for this specific object... | def M1EP(YKHO, IuXB, YEnM=None):
if YKHO.is_active and YKHO.is_superuser:
return True
return b94L(YKHO, IuXB, YEnM) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def M1EP(YKHO, IuXB, YEnM=None):\n if YKHO.is_active and YKHO.is_superuser:\n return True\n return b94L(YKHO, IuXB, YEnM)",
"def M1EP(YKHO, IuXB, YEnM=None):\n if YKHO.is_active and YKHO.is_superuser:\n return True\n return b94L(YKHO, IuXB, YEnM)",
"def M1EP(YKHO, IuXB, YEnM=None):\n ... | [
"0.78675437",
"0.78675437",
"0.7863068",
"0.77214396",
"0.76916915",
"0.7684293",
"0.7684293",
"0.76718014",
"0.7473264",
"0.7408586",
"0.73891324",
"0.72865933",
"0.72543836",
"0.7213861",
"0.716215",
"0.71377033",
"0.7124807",
"0.69538313",
"0.69241923",
"0.69221973",
"0.68... | 0.7858558 | 3 |
Returns True if the user has any permissions in the given app label. Uses pretty much the same logic as has_perm, above. | def spO2(YKHO, tKz9):
if YKHO.is_active and YKHO.is_superuser:
return True
return Sd76(YKHO, tKz9) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def spO2(YKHO, tKz9):\n if YKHO.is_active and YKHO.is_superuser:\n return True\n return Sd76(YKHO, tKz9)",
"def spO2(YKHO, tKz9):\n if YKHO.is_active and YKHO.is_superuser:\n return True\n return Sd76(YKHO, tKz9)",
"def spO2(YKHO, tKz9):\n if YKHO.is_active and YKHO.is_superuser:\n... | [
"0.77198595",
"0.77198595",
"0.77198595",
"0.7683107",
"0.7602867",
"0.753523",
"0.753523",
"0.753523",
"0.753523",
"0.74990255",
"0.7492096",
"0.7450116",
"0.7450116",
"0.7450116",
"0.7450116",
"0.7450116",
"0.7439927",
"0.7408556",
"0.7384637",
"0.7377923",
"0.73541474",
... | 0.7651985 | 4 |
Returns a User object from an id (User.id). Django's equivalent takes request, but taking an id instead leaves it up to the developer to store the id in any way they want (session, signed cookie, etc.) | def TKWP(n10L):
if not n10L:
return fCU0()
return TkcJ().get_user(n10L) or fCU0() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bt8D(id: int) -> mv1M:\n return DQE7(mv1M, mv1M.id, id)",
"def bt8D(id):\n return mv1M.query.get(id)",
"def TKWP(Emd4, id):\n C3ST = Nc2H.query.filter_by(id=id).first()\n return Emd4.create_user_from_model(C3ST)",
"def bt8D(id):\n return 'do some magic!'",
"def TKWP(uJjO):\n CBIr = mv... | [
"0.81649053",
"0.7942749",
"0.78185767",
"0.7803889",
"0.7780645",
"0.7741238",
"0.77119976",
"0.76994914",
"0.76965714",
"0.76965714",
"0.7690197",
"0.7671432",
"0.76677954",
"0.764472",
"0.7636624",
"0.7593759",
"0.7590399",
"0.75588286",
"0.75443286",
"0.75392425",
"0.7538... | 0.7125831 | 93 |
Uses get() to return an document, or raises a Http404 exception if the document does not exist. cls may be a Document or QuerySet object. All other passed arguments and keyword arguments are used in the get() query. | def KevP(Emd4, *qIxc, **B2fa):
SR0I = gWcE(Emd4)
try:
return SR0I.get(*qIxc, **B2fa)
except (SR0I._document.DoesNotExist, sUXu):
from django.http import Http404
raise Http404('No %s matches the given query.' % SR0I._document._class_name) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NMoC(YKHO, **B2fa):\n id = None\n if 'id' in B2fa:\n id = B2fa['id']\n del B2fa['id']\n elif 'pk' in B2fa:\n id = B2fa['pk']\n del B2fa['pk']\n else:\n raise YKHO.model.DoesNotExist('You must provide an id to find')\n kXUa = siZ_.get_connection('default')\n ... | [
"0.72595906",
"0.7224911",
"0.67663985",
"0.6748246",
"0.6425127",
"0.63078797",
"0.6307357",
"0.63036805",
"0.62978655",
"0.62548655",
"0.61732197",
"0.61718404",
"0.61653894",
"0.61395",
"0.6058546",
"0.60489285",
"0.6022668",
"0.60001105",
"0.59967846",
"0.597988",
"0.5963... | 0.8128844 | 0 |
Converts the given number to a string. If it has only one digit, a leading zero so as it has always at least two digits. | def xXtp(YKHO, FGW3):
if int(FGW3) < 10:
return '0%s' % FGW3
else:
return str(FGW3) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tlJD(FGW3):\n if FGW3 < 10:\n return f'0{FGW3}'\n return str(FGW3)",
"def jlUU(FGW3: int):\n if FGW3 < 10:\n X_qS = '0' + str(FGW3)\n else:\n X_qS = str(FGW3)\n return X_qS",
"def gLHK(FGW3: int):\n if FGW3 < 10:\n X_qS = '00' + str(FGW3)\n elif FGW3 < 100:\... | [
"0.84035224",
"0.7836786",
"0.77574015",
"0.763682",
"0.7478352",
"0.7326388",
"0.7191596",
"0.71389633",
"0.70680416",
"0.7055696",
"0.7040921",
"0.70393074",
"0.70364344",
"0.6980078",
"0.69772875",
"0.6968025",
"0.69567466",
"0.69409835",
"0.6842966",
"0.683133",
"0.683061... | 0.77349645 | 3 |
Enable or disable the default mongod timeout when querying. | def vYBr(YKHO, etR_):
SR0I = YKHO.clone()
SR0I._timeout = etR_
return SR0I | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vYBr(YKHO):\n YKHO._query_timeout = Zyoo",
"def xoC3(vYBr):\n return None",
"def vYBr(YKHO, vYBr):\n YKHO._query = YKHO._query.execution_options(timeout=vYBr)\n return YKHO",
"def MUtU(YKHO, vYBr: Optional[float]) -> None:\n YKHO.connection.set_default_timeout(vYBr)",
"def Ernp(YKHO):\n ... | [
"0.6784751",
"0.6184316",
"0.60782",
"0.60179293",
"0.594761",
"0.5922316",
"0.5921375",
"0.5865901",
"0.58632314",
"0.5838726",
"0.5794751",
"0.57752526",
"0.5764435",
"0.5753788",
"0.5715236",
"0.56981623",
"0.5609448",
"0.5550443",
"0.55240613",
"0.5511591",
"0.5508028",
... | 0.56932265 | 16 |
Descriptor for instantiating a new QuerySet object when Document.objects is accessed. | def xtUD(YKHO, KAOR, qsJ6):
if KAOR is not None:
return YKHO
c2KC = qsJ6._meta.get('queryset_class', YKHO.default)
SR0I = c2KC(qsJ6, qsJ6._get_collection())
if YKHO.get_queryset:
Iupq = YKHO.get_queryset.func_code.co_argcount
if Iupq == 1:
SR0I = YKHO.get_queryset(SR0... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VVJ3(YKHO):\n if not hasattr(YKHO, '__objects'):\n YKHO.__objects = ZYvt(YKHO, YKHO._get_collection())\n return YKHO.__objects",
"def wc3e(YKHO):\n return ctuC(YKHO.model)",
"def wc3e(YKHO):\n return YKHO.get_queryset()",
"def wc3e(YKHO):\n return YKHO.get_queryset()",
"def k66M(Y... | [
"0.70456475",
"0.67878795",
"0.67592674",
"0.67209315",
"0.6677101",
"0.66088086",
"0.6569578",
"0.65299076",
"0.64994127",
"0.6489929",
"0.6464701",
"0.63939613",
"0.6388564",
"0.6361397",
"0.63422275",
"0.6291792",
"0.62552863",
"0.62091225",
"0.6190742",
"0.61634773",
"0.6... | 0.7113044 | 0 |
Iteration utilises a results cache which iterates the cursor in batches of ``ITER_CHUNK_SIZE``. If ``self._has_more`` the cursor hasn't been exhausted so cache then batch. Otherwise iterate the result_cache. | def Vs4Q(YKHO):
YKHO._iter = True
if YKHO._has_more:
return YKHO._iter_results()
return iter(YKHO._result_cache) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uMLU(YKHO):\n if YKHO._result_cache is None:\n YKHO._result_cache = []\n if YKHO._has_more:\n try:\n for YRbF in Ni9Y(OiTF):\n YKHO._result_cache.append(YKHO.next())\n except StopIteration:\n YKHO._has_more = False",
"def wh2M(YKHO):\n if YKH... | [
"0.73145896",
"0.7204628",
"0.6586133",
"0.65158546",
"0.64750624",
"0.6415769",
"0.6169436",
"0.61687034",
"0.6163824",
"0.6144915",
"0.61306167",
"0.6088145",
"0.6084768",
"0.6046661",
"0.59694755",
"0.5964619",
"0.5937116",
"0.5932645",
"0.59147197",
"0.59126425",
"0.59022... | 0.7110182 | 2 |
Provides the string representation of the QuerySet | def wHJl(YKHO):
if YKHO._iter:
return '.. queryset mid-iteration ..'
YKHO._populate_cache()
nPrm = YKHO._result_cache[:f46c + 1]
if len(nPrm) > f46c:
nPrm[-1] = '...(remaining elements truncated)...'
return repr(nPrm) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return YKHO._query",
"def zAg0(YKHO):\n vexM = []\n vexM.append(u'select')\n if YKHO._q['distinct']:\n vexM.append(u'distinct')\n if YKHO._q['select']:\n vexM += [SRYB for SRYB in YKHO._q['select']]\n else:\n vexM.append(u'*')\n if YKHO._q['where']:\n ... | [
"0.7202723",
"0.69771975",
"0.67394316",
"0.6735464",
"0.6604355",
"0.6599972",
"0.65878963",
"0.64863056",
"0.64452726",
"0.6443288",
"0.63762087",
"0.63572526",
"0.626172",
"0.6260618",
"0.6233271",
"0.6233231",
"0.6213533",
"0.62047464",
"0.6183564",
"0.6178807",
"0.617738... | 0.6389888 | 10 |
Convert to a non_caching queryset | def Nlgd(YKHO):
if YKHO._result_cache is not None:
raise hgoV('QuerySet already cached')
return YKHO.clone_into(_KH7(YKHO._document, YKHO._collection)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Nlgd(YKHO, *qIxc, **B2fa):\n SR0I = YKHO.get_query_set()\n Bong = getattr(SR0I, 'no_cache', None)\n if Bong:\n return Bong(*qIxc, **B2fa)\n return SR0I",
"def Ywqg(YKHO):\n SR0I = YKHO.clone()\n SR0I._none = True\n return SR0I",
"def UsmS(YKHO):\n SR0I = YKHO.clone()\n SR0... | [
"0.6587019",
"0.6528558",
"0.6403544",
"0.62623775",
"0.61909133",
"0.6128765",
"0.6127216",
"0.6108672",
"0.61078286",
"0.60828775",
"0.60784554",
"0.60490954",
"0.6024996",
"0.60087526",
"0.596148",
"0.5942945",
"0.5926462",
"0.5920776",
"0.5883624",
"0.5874775",
"0.5862418... | 0.62213385 | 4 |
Provides the string representation of the QuerySet | def wHJl(YKHO):
if YKHO._iter:
return '.. queryset mid-iteration ..'
nPrm = []
for YRbF in Ni9Y(f46c + 1):
try:
nPrm.append(YKHO.next())
except StopIteration:
break
if len(nPrm) > f46c:
nPrm[-1] = '...(remaining elements truncated)...'
YKHO.rew... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return YKHO._query",
"def zAg0(YKHO):\n vexM = []\n vexM.append(u'select')\n if YKHO._q['distinct']:\n vexM.append(u'distinct')\n if YKHO._q['select']:\n vexM += [SRYB for SRYB in YKHO._q['select']]\n else:\n vexM.append(u'*')\n if YKHO._q['where']:\n ... | [
"0.72025764",
"0.6976132",
"0.6738373",
"0.6735246",
"0.66052175",
"0.6601008",
"0.64853305",
"0.644383",
"0.6443825",
"0.63886654",
"0.63745946",
"0.6356524",
"0.62633014",
"0.6259184",
"0.62340075",
"0.62299955",
"0.6210098",
"0.6206465",
"0.61829346",
"0.6177707",
"0.61758... | 0.6586689 | 6 |
Ensure that the correct list of _subclasses (subclasses) is assembled. | def NW2J(YKHO):
class Animal(yQaM):
e5kH = {'allow_inheritance': True}
class Fish(rON5):
pass
class Guppy(r5iy):
pass
class Mammal(rON5):
pass
class Dog(IE8X):
pass
class Human(IE8X):
pass
YKHO.assertEqual(rON5._subclasses, ('Animal', 'An... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vb49(YKHO):\n\n class Animal(i_Aq):\n pass\n\n class Fish(rON5):\n pass\n\n class Guppy(r5iy):\n pass\n\n class Mammal(rON5):\n pass\n\n class Dog(IE8X):\n pass\n\n class Human(IE8X):\n pass\n YKHO.assertEqual(rON5._subclasses, ('Base.Animal', 'Bas... | [
"0.75141233",
"0.74155354",
"0.7151592",
"0.6652481",
"0.66435987",
"0.6582111",
"0.6574626",
"0.6541085",
"0.6526573",
"0.6358951",
"0.63530034",
"0.63275474",
"0.632191",
"0.6311259",
"0.6305945",
"0.62632287",
"0.62514466",
"0.62418795",
"0.62222373",
"0.6213408",
"0.61535... | 0.70001113 | 3 |
Ensure that subclassed documents don't override parents' collections | def I2Zy(YKHO):
class Drink(yQaM):
mWFP = NP6E()
e5kH = {'allow_inheritance': True}
class Drinker(yQaM):
Xx5Z = aRvp()
try:
qmLP.simplefilter('error')
class AcloholicDrink(_7Iu):
e5kH = {'collection': 'booze'}
except SyntaxWarning:
qmLP.simp... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def l73a(YKHO):\n if YKHO._document._meta.get('allow_inheritance') is True:\n YKHO._initial_query = {'_cls': YKHO._document._class_name}\n return YKHO",
"def LQ99(YKHO):\n\n class Comment(nIuE):\n hGN5 = NP6E()\n\n def lUkJ():\n\n class SpecialComment(jY1u):\n pass\n ... | [
"0.6985181",
"0.69428563",
"0.6933875",
"0.686705",
"0.67761993",
"0.6691288",
"0.6676159",
"0.66432565",
"0.6601804",
"0.64787143",
"0.645675",
"0.64546996",
"0.6286173",
"0.62837213",
"0.6266565",
"0.6226667",
"0.6132141",
"0.6109115",
"0.60772103",
"0.6028754",
"0.60273767... | 0.73361653 | 0 |
Test update on `EmbeddedDocumentField` fields | def CjaC(YKHO):
class Page(nIuE):
FTK0 = NP6E(verbose_name='Log message', required=True)
class Site(yQaM):
B2Dn = p17e(I0sS)
HAC5.drop_collection()
qpDA = HAC5(page=I0sS(log_message='Warning: Dummy message'))
qpDA.save()
qpDA = HAC5.objects.first()
qpDA.page.log_message = '... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def IsIF(YKHO):\n G6QD = SZ_z.DocumentFields({'foo@': 'bar'})\n YKHO.assertEqual('bar', G6QD['foo'])\n G6QD.update({'foo@': 'bbq'})\n YKHO.assertEqual('bbq', G6QD['foo'])",
"def IsIF(YKHO):\n G6QD = SZ_z.DocumentFields({'foo@': 'bar'})\n YKHO.assertEquals('bar', G6QD['foo'])\n G6QD.update({'... | [
"0.80263096",
"0.79285944",
"0.7768236",
"0.76480937",
"0.74768406",
"0.71592635",
"0.69594795",
"0.6882156",
"0.6729748",
"0.6715174",
"0.6705401",
"0.6697114",
"0.6669468",
"0.6664634",
"0.66611075",
"0.6648654",
"0.6631051",
"0.6629046",
"0.6618227",
"0.65969104",
"0.65857... | 0.7560681 | 4 |
Test update on `EmbeddedDocumentField` fields when db_field is other than default. | def e_Ih(YKHO):
class Page(nIuE):
FTK0 = NP6E(verbose_name='Log message', db_field='page_log_message', required=True)
class Site(yQaM):
B2Dn = p17e(I0sS)
HAC5.drop_collection()
qpDA = HAC5(page=I0sS(log_message='Warning: Dummy message'))
qpDA.save()
qpDA = HAC5.objects.first()
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VkVQ(YKHO):\n\n class HandleNoneFields(yQaM):\n LtjF = NP6E()\n mKZQ = rr2W()\n cTOQ = ce_b()\n RdFZ = Nvzg()\n MRZk.drop_collection()\n A97Q = MRZk()\n A97Q.str_fld = u'spam ham egg'\n A97Q.int_fld = 42\n A97Q.flt_fld = 4.2\n A97Q.com_dt_fld = qcWV.datetime.utc... | [
"0.70794326",
"0.68239176",
"0.66753864",
"0.6550703",
"0.6343936",
"0.63385403",
"0.6267887",
"0.6234543",
"0.6172995",
"0.6170889",
"0.6167502",
"0.61320245",
"0.60813516",
"0.60528255",
"0.6030027",
"0.60080147",
"0.59870267",
"0.5953699",
"0.593926",
"0.59335166",
"0.5859... | 0.7040233 | 1 |
Test update of `EmbeddedDocumentField` attached to a newly saved document. | def j_J9(YKHO):
class Page(nIuE):
FTK0 = NP6E(verbose_name='Log message', required=True)
class Site(yQaM):
B2Dn = p17e(I0sS)
HAC5.drop_collection()
qpDA = HAC5(page=I0sS(log_message='Warning: Dummy message'))
qpDA.save()
qpDA.page.log_message = 'Error: Dummy message'
qpDA.s... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YRnw(YKHO):\n\n class EmployeeDetails(nIuE):\n dQgj = NP6E()\n\n class Employee(YKHO.Person):\n Jm01 = rr2W()\n iQG7 = p17e(qq5u)\n YvUd = TjLA(name='Test Employee', age=50, salary=20000)\n YvUd.details = qq5u(position='Developer')\n YvUd.save()\n aomj = TjLA.objects.get(... | [
"0.79655623",
"0.7776593",
"0.7525465",
"0.75171095",
"0.73363364",
"0.7244305",
"0.7219187",
"0.70795023",
"0.6797544",
"0.677528",
"0.6698337",
"0.6652362",
"0.6646272",
"0.6624029",
"0.6601436",
"0.6576575",
"0.6573582",
"0.6480238",
"0.6451852",
"0.6442072",
"0.6441584",
... | 0.7662591 | 2 |
Ensure that invalid values cannot be assigned to int fields. | def EkRP(YKHO):
class Person(yQaM):
ZJe_ = rr2W(min_value=0, max_value=110)
a70H = nj3W()
a70H.age = 50
a70H.validate()
a70H.age = -1
YKHO.assertRaises(sUXu, a70H.validate)
a70H.age = 120
YKHO.assertRaises(sUXu, a70H.validate)
a70H.age = 'ten'
YKHO.assertRaises(sUXu, a70... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xzCw(YKHO):\n if YKHO.value is not None:\n if not isinstance(YKHO.value, jKi7.integer_types):\n raise TypeError('expected (one of): {0}, observed: {1}'.format(jKi7.integer_types, type(YKHO.value)))",
"def xzCw(YKHO):\n if YKHO.value is not None:\n if type(YKHO.value) not in jKi... | [
"0.72467065",
"0.7243073",
"0.69474995",
"0.69066507",
"0.6862464",
"0.67947006",
"0.6792517",
"0.6786423",
"0.6786423",
"0.6749542",
"0.67028165",
"0.6670143",
"0.6638973",
"0.6623278",
"0.66029656",
"0.6599274",
"0.65766823",
"0.65425754",
"0.6530925",
"0.65221107",
"0.6521... | 0.7008027 | 2 |
Ensure that dict field handles validation if provided a strict field type. | def Gnoa(YKHO):
class Simple(yQaM):
J8oL = hsub(field=rr2W())
oIQu.drop_collection()
tTpl = oIQu()
tTpl.mapping['someint'] = 1
tTpl.save()
def H7dc():
tTpl.mapping['somestring'] = 'abc'
tTpl.save()
YKHO.assertRaises(sUXu, H7dc)
oIQu.drop_collection() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xzCw(YKHO, BWXx):\n if not isinstance(BWXx, dict):\n YKHO.error('Only dictionaries may be used in a DictField')\n if s8aC(BWXx):\n tO9_ = 'Invalid dictionary key - documents must have only string keys'\n YKHO.error(tO9_)\n if ae62(BWXx):\n YKHO.error('Invalid dictionary key... | [
"0.7032156",
"0.6978162",
"0.6857539",
"0.6788287",
"0.673879",
"0.6727339",
"0.6653926",
"0.66275525",
"0.6564793",
"0.6562196",
"0.65613496",
"0.65310335",
"0.6524287",
"0.64975035",
"0.64843595",
"0.6461176",
"0.6453659",
"0.6449085",
"0.6446315",
"0.64111406",
"0.64109033... | 0.69451636 | 2 |
Ensure that the MapField can handle complex declared types. | def IO4j(YKHO):
class SettingBase(nIuE):
e5kH = {'allow_inheritance': True}
class StringSetting(nwoT):
BWXx = NP6E()
class IntegerSetting(nwoT):
BWXx = rr2W()
class Extensible(yQaM):
J8oL = PZya(p17e(nwoT))
TEkb.drop_collection()
tTpl = TEkb()
tTpl.mapping... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def CN_c(kINJ):\n return kINJ.message_type is not None and set(kINJ.message_type.fields_by_name.keys()) == {'key', 'value'}",
"def dkJz(YKHO):\n pass",
"def gGGj(YKHO):\n\n class Simple(yQaM):\n J8oL = PZya(rr2W())\n oIQu.drop_collection()\n tTpl = oIQu()\n tTpl.mapping['someint'] = 1\... | [
"0.64671344",
"0.62180316",
"0.61334753",
"0.6065747",
"0.6061408",
"0.6018862",
"0.6015898",
"0.5965463",
"0.59523827",
"0.5883756",
"0.5867731",
"0.5855719",
"0.5835727",
"0.58232373",
"0.580157",
"0.578809",
"0.57718545",
"0.5737686",
"0.5728874",
"0.5728358",
"0.57156634"... | 0.6940733 | 0 |
Ensure that a ListField properly dereferences generic references. | def Y1f8(YKHO):
class Link(yQaM):
leAC = NP6E()
class Post(yQaM):
leAC = NP6E()
class User(yQaM):
YXPh = aSlI(aRvp())
PRV_.drop_collection()
T97t.drop_collection()
mv1M.drop_collection()
iEVg = PRV_(title='Pitchfork')
iEVg.save()
WrNq = T97t(title='Behind t... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def HHgr(YKHO):\n\n class User(yQaM):\n pass\n\n class Comment(nIuE):\n hGN5 = NP6E()\n\n class BlogPost(yQaM):\n hGN5 = NP6E()\n Tj1O = aSlI(p17e(jY1u))\n dJ1p = aSlI(NP6E())\n i0gQ = aSlI(WHc2(mv1M))\n ngUu = aSlI(aRvp())\n m8z6 = YkQc(content='Went fo... | [
"0.6829387",
"0.6684259",
"0.6652216",
"0.6535843",
"0.6483349",
"0.64257693",
"0.6388549",
"0.6340243",
"0.6294894",
"0.6284418",
"0.6278721",
"0.6265835",
"0.6246984",
"0.61393577",
"0.61026204",
"0.60955113",
"0.6078312",
"0.60653865",
"0.606452",
"0.6039026",
"0.59743243"... | 0.6603407 | 3 |
Ensure that a ListField properly dereferences generic references and respects choices. | def m3yu(YKHO):
class Link(yQaM):
leAC = NP6E()
class Post(yQaM):
leAC = NP6E()
class User(yQaM):
YXPh = aSlI(aRvp(choices=(T97t,)))
PRV_.drop_collection()
T97t.drop_collection()
mv1M.drop_collection()
iEVg = PRV_(title='Pitchfork')
iEVg.save()
WrNq = T97t(... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xzCw(YKHO, BWXx):\n if not isinstance(BWXx, (list, tuple, ZYvt)) or isinstance(BWXx, exCv):\n YKHO.error('Only lists and tuples may be used in a list field')\n super(aSlI, YKHO).validate(BWXx)",
"def XyNd(YKHO):\n\n class Car(nIuE):\n mWFP = NP6E()\n\n class Dish(nIuE):\n pvZ... | [
"0.7045519",
"0.67454803",
"0.66345984",
"0.65355474",
"0.64125127",
"0.6409648",
"0.63878536",
"0.63667405",
"0.6270808",
"0.6208512",
"0.61945117",
"0.6182235",
"0.60773474",
"0.5987391",
"0.59820324",
"0.59268814",
"0.59188914",
"0.5912925",
"0.59071094",
"0.5820747",
"0.5... | 0.7131796 | 0 |
Ensure that a query using ``get`` returns at most one result. | def iGGx(YKHO):
YKHO.assertRaises(ws9Q, YKHO.Person.objects.get)
YKHO.assertRaises(YKHO.Person.DoesNotExist, YKHO.Person.objects.get)
pnOk = YKHO.Person(name='User A', age=20)
pnOk.save()
NjOZ = YKHO.Person(name='User B', age=30)
NjOZ.save()
YKHO.assertRaises(YkSz, YKHO.Person.objects.get)
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def UQKt(YKHO, *qIxc, **B2fa):\n try:\n return next(YKHO.query(*qIxc, **B2fa))\n except StopIteration:\n return None",
"def a0GJ(YKHO):\n Ylbp = YKHO[:2]\n if Ylbp is None:\n return None\n UXqs = str(YKHO._query) if YKHO._query else '<unspecified>'\n if len(Ylbp) == 0:\n ... | [
"0.6416775",
"0.619883",
"0.58942777",
"0.5771545",
"0.5770086",
"0.5751747",
"0.57287455",
"0.5703725",
"0.56536835",
"0.5641503",
"0.56324595",
"0.5622153",
"0.56076556",
"0.5591764",
"0.5576674",
"0.5556116",
"0.5556116",
"0.5538706",
"0.55385834",
"0.55317426",
"0.5526804... | 0.5095216 | 90 |
Ensure that the DictField can be updated. | def e_I9(YKHO):
class Club(yQaM):
DgAC = hsub()
KekI = eY7X()
KekI.members['John'] = dict(gender='M', age=13)
KekI.save()
eY7X.objects().update(set__members={'John': dict(gender='F', age=14)})
KekI = eY7X.objects().first()
YKHO.assertEqual(KekI.members['John']['gender'], 'F')
YK... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eFPu(YKHO, A97Q):\n S_aC = list(set(A97Q.keys()) - set(YKHO.get_fields()))\n if S_aC:\n return {'invalid_cause': 'no_such_fields', 'fields': S_aC}\n else:\n return True",
"def Gnoa(YKHO):\n\n class Simple(yQaM):\n J8oL = hsub(field=rr2W())\n oIQu.drop_collection()\n tTp... | [
"0.6922061",
"0.6659981",
"0.6440654",
"0.6405521",
"0.64045584",
"0.6388829",
"0.6321573",
"0.63096684",
"0.6307356",
"0.62946177",
"0.6263546",
"0.6216617",
"0.62147737",
"0.62147737",
"0.6184702",
"0.6172713",
"0.6125088",
"0.6108913",
"0.6087805",
"0.6057161",
"0.6049381"... | 0.64713806 | 2 |
Ensure that connections with different aliases may be registered. | def UwC7(YKHO):
sRgL('testdb', 'mongoenginetest2')
YKHO.assertRaises(ConnectionError, lxP0)
w2B8 = lxP0('testdb')
YKHO.assertTrue(isinstance(w2B8, DpgL.mongo_client.MongoClient))
NCls = GGod('testdb')
YKHO.assertTrue(isinstance(NCls, DpgL.database.Database))
YKHO.assertEqual(NCls.name, 'mong... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def doUt(YKHO):\n YKHO.failUnlessRaises(NotImplementedError, lambda: YKHO.handler.Alias(None, None))",
"def AVVA(YKHO):\n sRgL('testdb-2', 'mongoenginetest2')\n\n class A(yQaM):\n \"\"\"Uses default db_alias\n \"\"\"\n mWFP = NP6E()\n e5kH = {'allow_inheritance': True}\n\... | [
"0.6573241",
"0.64613074",
"0.6238448",
"0.61548036",
"0.6152838",
"0.6027933",
"0.6018265",
"0.6004393",
"0.59384793",
"0.57938164",
"0.5735249",
"0.572055",
"0.57178974",
"0.5714448",
"0.5692015",
"0.5668087",
"0.56464684",
"0.5642171",
"0.56230956",
"0.5618956",
"0.5599233... | 0.0 | -1 |
Creates a new restaurant and inserts it into the database. | def XrkW(Dokz):
c8SQ = MEn6(name=str(Dokz))
try:
cuiw.add(c8SQ)
cuiw.commit()
return
except:
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NauA(mWFP):\n rdJN = MEn6(name=mWFP)\n cuiw.add(rdJN)\n cuiw.commit()",
"def iVzf(id, mWFP, TdJL, UTX6, fopC, _UuI, qwnb):\n Mkmy = MEn6(id=id, name=mWFP, cuisine=TdJL, address=UTX6, longitude=fopC, latitude=_UuI, image_url=qwnb)\n NCls.session.add(Mkmy)\n NCls.session.commit()\n return ... | [
"0.8227336",
"0.81153953",
"0.74665284",
"0.7413182",
"0.7382473",
"0.7325353",
"0.7238363",
"0.69511455",
"0.69307464",
"0.6892276",
"0.68413985",
"0.6690828",
"0.6649477",
"0.6586734",
"0.6568678",
"0.6521175",
"0.64948976",
"0.6398378",
"0.63970643",
"0.6358018",
"0.634534... | 0.7320849 | 6 |
Calculate loss per epoch with given dataloader. | def XcGu(C3ST, JyoU, ilw4, W2ox, GT2U, Q8Ts=None, JTKU=None, IesV=None, begE=None, lrbt=None, Wcyi=None):
POHL, h58F = (0.0, 0)
exwG = len(JyoU)
vjTi = 0
begE = ht2j.device(begE) if begE is None else begE
for YRbF, (TNF5, HWOi) in enumerate(JyoU):
lrbt.update(1)
GPal = HWOi.size(0)
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MV3L(YKHO, JyoU, K0do, OPAs):\n mvEs = 0\n K0do.zero_grad()\n for bypm, fUYa in JyoU:\n bypm = JyoU.dataset.add_noise(bypm.cuda())\n hgOb = YKHO.net(bypm)\n N77f = OPAs(fUYa.cuda(), hgOb) / len(JyoU)\n N77f.backward()\n mvEs += N77f.detach().cpu()\n K0do.step()\n ... | [
"0.7215828",
"0.71777225",
"0.7109478",
"0.707171",
"0.7067024",
"0.7013543",
"0.6999182",
"0.69948673",
"0.68889076",
"0.6887576",
"0.6859309",
"0.6834737",
"0.6816801",
"0.67964447",
"0.6790995",
"0.6772768",
"0.6745439",
"0.6697665",
"0.66934067",
"0.6685748",
"0.6679109",... | 0.6821263 | 12 |
Sets the date_from of this AccountingHashExportExportSendRequest. | def ljfJ(YKHO, ljfJ):
if ljfJ is None:
raise ValueError('Invalid value for `date_from`, must not be `None`')
YKHO._date_from = ljfJ | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ljfJ(YKHO, ljfJ):\n YKHO._date_from = ljfJ",
"def f_eo(YKHO, f_eo):\n YKHO._from_date = f_eo",
"def f_eo(YKHO, f_eo):\n YKHO._from_date = f_eo",
"def ljfJ(YKHO):\n return YKHO._date_from",
"def QFwm(YKHO, QFwm):\n YKHO._usage_bill_from_date = QFwm",
"def lKBB(YKHO, jpfM, vnE3=None):\n ... | [
"0.78656524",
"0.7445698",
"0.7445698",
"0.62304527",
"0.60017425",
"0.58974516",
"0.58974516",
"0.58881444",
"0.5838286",
"0.5805602",
"0.57326674",
"0.57326674",
"0.57326674",
"0.55443776",
"0.55120766",
"0.54835093",
"0.54835093",
"0.54835093",
"0.54759073",
"0.54427606",
... | 0.7584189 | 1 |
Sets the date_to of this AccountingHashExportExportSendRequest. | def hg96(YKHO, hg96):
if hg96 is None:
raise ValueError('Invalid value for `date_to`, must not be `None`')
YKHO._date_to = hg96 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hg96(YKHO, hg96):\n YKHO._date_to = hg96",
"def NTec(YKHO, NTec):\n YKHO._to_date = NTec",
"def NTec(YKHO, NTec):\n YKHO._to_date = NTec",
"def Br5Q(YKHO, Br5Q):\n YKHO._to = Br5Q",
"def Br5Q(YKHO, Br5Q):\n YKHO._to = Br5Q",
"def Br5Q(YKHO, Br5Q):\n YKHO._to = Br5Q",
"def Br5Q(YKH... | [
"0.76954764",
"0.72286254",
"0.72286254",
"0.61350167",
"0.61350167",
"0.61350167",
"0.61350167",
"0.61015064",
"0.59499764",
"0.55645907",
"0.5539934",
"0.5481887",
"0.53826916",
"0.53546643",
"0.53546643",
"0.5347416",
"0.53438026",
"0.5301631",
"0.5255097",
"0.52315485",
"... | 0.7452096 | 1 |
Returns the string representation of the model | def gTzM(YKHO):
return CgYo.pformat(YKHO.to_dict()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__model)",
"def zAg0(YKHO):\n return str(YKHO.model)",
"def zAg0(YKHO):\n return YKHO.text",
"def zAg0(YKHO):\n oOUF = '-----------------------------------------------------------------------------------\\n'\n _2sc = YKHO.__class__.__name__\n oOUF += '\\t\\... | [
"0.86418265",
"0.85103965",
"0.7853324",
"0.77442306",
"0.7712258",
"0.76979405",
"0.765959",
"0.7637644",
"0.76218504",
"0.7607561",
"0.7606604",
"0.7606604",
"0.7606604",
"0.75990754",
"0.7585653",
"0.758149",
"0.7570811",
"0.7567585",
"0.75392604",
"0.75392604",
"0.7527967... | 0.0 | -1 |
Returns true if both objects are not equal | def Vdqg(YKHO, Elif):
return not YKHO == Elif | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO.__eq__(Elif)",
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif: object):\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif):\n if YKHO.__eq__(Elif):\n return False\n return True",
"def Vdqg(... | [
"0.8392633",
"0.8354901",
"0.82950056",
"0.8132309",
"0.81149805",
"0.8099986",
"0.809911",
"0.8097883",
"0.8097883",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8066694",
"0.80594814",
"0.805757",
... | 0.0 | -1 |
R""" Get the average acceptance ratio for volume changing moves. | def Rjjt(YKHO):
G_Si = YKHO.cpp_updater.getCounters(1)
return G_Si.getVolumeAcceptance() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NoVd(YKHO):\n if YKHO.total_swaps > 0:\n return float(YKHO.accepted_swaps) / float(YKHO.total_swaps)\n else:\n return 0.0",
"def An_a(YKHO):\n if YKHO.proposal_count > 0:\n return float(YKHO.acceptance_count) / float(YKHO.proposal_count)\n else:\n return float('nan')",... | [
"0.7069794",
"0.6926932",
"0.66996956",
"0.6649123",
"0.64397305",
"0.63334846",
"0.6302557",
"0.6284333",
"0.6264065",
"0.6262656",
"0.6198586",
"0.61826354",
"0.6179064",
"0.61291826",
"0.60493815",
"0.60493815",
"0.603791",
"0.6020828",
"0.6013008",
"0.60100764",
"0.600044... | 0.5975713 | 24 |
R""" Get the average acceptance ratio for log(V) changing moves. | def _rSC(YKHO):
G_Si = YKHO.cpp_updater.getCounters(1)
return G_Si.getLogVolumeAcceptance() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _mEE(BXon):\n B0DR = len(BXon)\n zoT6 = oyIN.min(oyIN.vstack((oyIN.zeros(B0DR), BXon.reshape(BXon.shape[0]))), axis=0)\n xD5p = zoT6.mean()\n SgQ6 = zoT6.std() / oyIN.sqrt(len(zoT6))\n BFeB = oyIN.exp(zoT6)\n yGTL = BFeB.mean()\n WTkW = BFeB.std() / oyIN.sqrt(len(BFeB))\n return (yGTL, ... | [
"0.6642171",
"0.62012154",
"0.6099025",
"0.60323316",
"0.5924007",
"0.59228617",
"0.5895168",
"0.58672774",
"0.5799335",
"0.57963324",
"0.57587826",
"0.5741285",
"0.5727077",
"0.57256526",
"0.57248276",
"0.5715663",
"0.5672897",
"0.56542915",
"0.5642864",
"0.56260324",
"0.560... | 0.0 | -1 |
R""" Get the average acceptance ratio for shear changing moves. | def kIdF(YKHO):
G_Si = YKHO.cpp_updater.getCounters(1)
return G_Si.getShearAcceptance()
G_Si = YKHO.cpp_updater.getCounters(1)
return G_Si.getShearAcceptance() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def An_a(YKHO):\n if YKHO.proposal_count > 0:\n return float(YKHO.acceptance_count) / float(YKHO.proposal_count)\n else:\n return float('nan')",
"def NoVd(YKHO):\n if YKHO.total_swaps > 0:\n return float(YKHO.accepted_swaps) / float(YKHO.total_swaps)\n else:\n return 0.0",... | [
"0.6797221",
"0.67431605",
"0.6342042",
"0.6329959",
"0.62926453",
"0.6292051",
"0.6273693",
"0.6257921",
"0.6245679",
"0.62392604",
"0.61416346",
"0.61343235",
"0.6113756",
"0.60972726",
"0.60784954",
"0.6072193",
"0.6054384",
"0.6038062",
"0.60189104",
"0.6008273",
"0.59960... | 0.59299785 | 35 |
Read a csv in pandas returns a pandas dataframe | def tFHO(VqRE, ZWCE):
jQ3Z = rLdf.read_csv(VqRE, names=ZWCE)
return jQ3Z | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LvsP(m6_J):\n JDhM(m6_J)\n qaEx = m6_J + '.csv'\n return rLdf.read_csv(qaEx)",
"def SYt4(okC2):\n jQ3Z = rLdf.read_csv(okC2)\n return jQ3Z",
"def CQF6(Jmpp: str) -> rLdf.DataFrame:\n return rLdf.read_csv(Jmpp, encoding='utf-8', delimiter=',')",
"def HND1(Ux0P: str) -> CwDs.DataFrame:\n ... | [
"0.8039984",
"0.7839099",
"0.77545685",
"0.77446294",
"0.76781577",
"0.7671499",
"0.76694304",
"0.7635434",
"0.7625068",
"0.7605448",
"0.7604805",
"0.75682056",
"0.75681347",
"0.7555838",
"0.75474966",
"0.75448793",
"0.7511597",
"0.7492581",
"0.74872977",
"0.74667877",
"0.741... | 0.69391084 | 77 |
Returns callable that returns iterator over elements for given sources. | def NdFx(c7pe, RnQN=Mc_f, TNrp=None, bNTp=None):
def Ch18():
return iter(bREi(c7pe, max_reader_threads=RnQN, read_counter=TNrp, element_counter=bNTp))
return Ch18 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def D6M8(aese: Sequence[Callable[[DataNested], None]], yTSU: Dict[str, DataNested]) -> None:\n zZcM: rvIV\n for JfyU, zZcM in zip(aese, yTSU.values()):\n JfyU(zZcM)",
"def P00P(FSYx: List[lambda s: object], KCHu: object) -> object:\n Ylbp = KCHu\n for FYKK in FSYx:\n Ylbp = FYKK(Ylbp)\n... | [
"0.6182883",
"0.60408366",
"0.6040563",
"0.60124904",
"0.59295106",
"0.58037436",
"0.5798195",
"0.571767",
"0.5630546",
"0.560964",
"0.55993384",
"0.559441",
"0.5585819",
"0.557859",
"0.5577372",
"0.5564299",
"0.55556375",
"0.5550019",
"0.5534142",
"0.5493833",
"0.5473722",
... | 0.7977909 | 0 |
Checks if the current record should be excluded from the target. | def Bu4c(AIu6: Dict[str, Any], pan_: str) -> None:
if pan_ in AIu6['exclude']:
raise ZcEY.DONT_INCLUDE | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Eprg(YKHO) -> bool:\n return YKHO._excluded",
"def H3P3(YKHO):\n return YKHO._tag == 'some_users_are_excluded'",
"def filter(YKHO, AIu6):\n return AIu6.name not in YKHO.__blacklist",
"def jiab(YKHO):\n return not YKHO.get_object().userstory_set.all()",
"def ilNo(YKHO):\n DUPd = nSqr.obje... | [
"0.6880027",
"0.63941544",
"0.63621837",
"0.63172174",
"0.62151825",
"0.619588",
"0.6156343",
"0.615617",
"0.6109033",
"0.61070615",
"0.6086304",
"0.6060047",
"0.60227954",
"0.6022368",
"0.60159343",
"0.60141957",
"0.60065156",
"0.5993417",
"0.59860617",
"0.5975009",
"0.59637... | 0.7323669 | 0 |
Take the real part of a set of vectors and normalize it. This is used for returning real eigenvectors even when the PETSc scalar type is complex. | def gpHF(M8d_, NPTA=False):
G1Hx = M8d_.shape[0] if NPTA else M8d_.shape[1]
M8d_ = oyIN.ascontiguousarray(M8d_.real)
for YRbF in range(G1Hx):
qJWj = (YRbF, Ellipsis) if NPTA else (Ellipsis, YRbF)
bVmN.nmlz(M8d_[qJWj], inplace=True)
return M8d_ | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NkkI(F_On):\n if len(oyIN.asarray(F_On).shape) == 1:\n return F_On / oyIN.linalg.norm(F_On)\n CkYf = oyIN.linalg.norm(F_On, axis=1)\n return F_On / CkYf[:, oyIN.newaxis]",
"def QFTF(Ohr5: list):\n lRRB = [LihS ** 2 for LihS in Ohr5]\n return PZyS(Pusg(seET.add, lRRB))",
"def NkkI(YKHO... | [
"0.69166464",
"0.6907976",
"0.681326",
"0.67428017",
"0.66783726",
"0.6597974",
"0.65580237",
"0.65490717",
"0.64381516",
"0.63867086",
"0.63867086",
"0.6370315",
"0.63459945",
"0.63429147",
"0.6303774",
"0.6292608",
"0.62310624",
"0.62045825",
"0.61852264",
"0.6174882",
"0.6... | 0.70839936 | 0 |
Retrieve a specified client credential. | def NMoC(YKHO, zb3C: str, id: str) -> dict[str, ImMB]:
return YKHO.client.get(YKHO._url(zb3C, id)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FCh8(YKHO, zb3C):\n return YKHO.db.clients.find_one({'_id': zb3C})",
"def outC(YKHO):\n mwuo = rLll(tenant_id=YKHO.tenant_id, client_id=YKHO.client_id, client_secret=YKHO.client_secret)\n return mwuo",
"def qOQU(YKHO, Ubkq):\n return XfyW.get_credential(Ubkq.tenant_id, Ubkq.credential_id)",
"... | [
"0.75609493",
"0.7232921",
"0.6947374",
"0.6913416",
"0.6820632",
"0.6749218",
"0.67428184",
"0.6717683",
"0.67057866",
"0.66310024",
"0.6550246",
"0.6514386",
"0.6502777",
"0.6494211",
"0.64855325",
"0.6471455",
"0.6460154",
"0.6451063",
"0.6441021",
"0.64331716",
"0.6423197... | 0.0 | -1 |
Test exception handling for bad inputs. | def bpAi(YKHO):
Mkmy = YKHO.runner.invoke(eLpg, ['test1', 'me', 'data/sample_triplets.jsonl'], input='1234\n1234\n')
assert Mkmy.exception is None
Mkmy = YKHO.runner.invoke(PTpj, ['lol'], input='me\n1234\ny\n')
assert isinstance(Mkmy.exception, q4_y)
Mkmy = YKHO.runner.invoke(PTpj, ['test1'], input=... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bpAi(YKHO):\n pass",
"def ssdO(YKHO):\n with YKHO.assertRaises(Exception):\n jXWM(123)\n with YKHO.assertRaises(Exception):\n Fho_(123)",
"def w_ae(YKHO):\n raise ValueError",
"def kltX(YKHO):\n YKHO.assertRaises(TypeError, Bguk.loads)\n YKHO.assertRaises(Bguk.Exception, B... | [
"0.7949484",
"0.7938724",
"0.7499448",
"0.7449214",
"0.74441516",
"0.7371164",
"0.7314044",
"0.72933894",
"0.72933894",
"0.7206381",
"0.7125206",
"0.71129566",
"0.7096975",
"0.7041206",
"0.70410323",
"0.70390534",
"0.703419",
"0.7034055",
"0.6998837",
"0.697994",
"0.69789004"... | 0.0 | -1 |
Return True if answer is a valid response to question, False if not. (question is expected to be the XFormsResponse object for the question) | def OyZr(ANfV, bAls):
if bAls.event.datatype == 'select':
try:
assert ANfV is not None
ANfV = int(ANfV)
assert ANfV >= 1 and ANfV <= len(bAls.event.choices)
return True
except (ValueError, AssertionError):
return False
else:
try... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SGVO(YKHO, bAls: Question) -> bool:\n return bAls.validate_answer(YKHO)",
"def OyZr(YKHO, ANfV: Answer) -> bool:\n raise NotImplementedError",
"def M6XB(bAls, ANfV):\n return bAls.answer == ANfV",
"def oa8M(YKHO, ANfV):\n w8ES = ANfV.get('response_type')\n if w8ES is None:\n return ... | [
"0.73421884",
"0.7305641",
"0.7210747",
"0.70708597",
"0.69441503",
"0.69441503",
"0.6828242",
"0.6822185",
"0.6761122",
"0.6730558",
"0.6701965",
"0.663875",
"0.6637387",
"0.6626277",
"0.6551475",
"0.6466548",
"0.6430076",
"0.6427315",
"0.6403516",
"0.63921684",
"0.63908863"... | 0.65949506 | 14 |
Computes the embedding of the input via an embedding layer and averages the embedding to obtain an average embedding | def hXr3(GhuM, oxCC):
g4y1 = X6a0(shape=GhuM)
rWrZ = z4o2(oxCC)(g4y1)
Y1nl = Zlsf(lambda WKvO: nMvt.sum(WKvO, axis=1), name='sum')(rWrZ)
YUWI = oxCC.vocab[Zovo].index
H3gw = Zlsf(lambda WKvO: nMvt.sum(nMvt.cast(nMvt.not_equal(WKvO, YUWI), 'float32'), axis=1, keepdims=True), name='sent_len')(g4y1)
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Eeea(wjQX, bySB, NArs):\n ZxnZ = ZylS.nn.embedding_lookup(wjQX, bySB)\n FZ_S = ZylS.expand_dims(ZylS.equal(bySB, NArs['pad_index']), axis=2)\n upAO = ZylS.where(FZ_S, ZylS.zeros_like(FZ_S, dtype=ZylS.float32), ZylS.ones_like(FZ_S, dtype=ZylS.float32))\n ZxnZ = ZylS.reduce_mean(ZylS.multiply(upAO, Z... | [
"0.7366832",
"0.71117854",
"0.7092837",
"0.6890206",
"0.68787396",
"0.6828554",
"0.6697428",
"0.6695492",
"0.6665745",
"0.66471064",
"0.6641601",
"0.65714335",
"0.6536399",
"0.65073943",
"0.642984",
"0.642316",
"0.636204",
"0.63187057",
"0.6309965",
"0.63000923",
"0.62963",
... | 0.74745005 | 0 |
Get the ID of the authentication source that this handler handles. | def lKmw(YKHO) -> R8aJ:
raise NotImplementedError() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cP1Y(YKHO) -> str:\n return YKHO.source_id",
"def cP1Y(YKHO):\n return YKHO._payload.get_source_id()",
"def UBGL(YKHO) -> str:\n return qe4Y.get(YKHO, 'source_id')",
"def cP1Y(YKHO):\n return zZ1q(YKHO._my_map['sourceId'])",
"def UBGL(YKHO):\n if YKHO.source is not None:\n return ... | [
"0.69211",
"0.68819547",
"0.68636596",
"0.6702338",
"0.66631883",
"0.66542447",
"0.66487724",
"0.6541224",
"0.65299374",
"0.65299374",
"0.65048474",
"0.64938813",
"0.64574796",
"0.6421638",
"0.64213914",
"0.64192826",
"0.6418047",
"0.6394178",
"0.63864416",
"0.6381523",
"0.63... | 0.7884887 | 0 |
Returns the initial world x, y coordinates of the given number of pegs in a given initial image, taken from a given camera position. Assumes camera is looking in the negative z direction. | def oJJT(YKHO):
_6KP = 'Peg position initialisation'
PHKE = []
eGU8 = []
uCAB = YKHO.img
L3hc = YKHO.peg_col
A_71 = YKHO.num_pegs
jz8n = YKHO.img_thres
yOrK = uCAB.shape[0:2]
yOrK = yOrK[::-1]
ACD6 = [YKHO.init_x, YKHO.init_y, YKHO.init_z]
Y_0O = YKHO.table_z + YKHO.peg_heigh... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def h1dL(exwG, ZHfW, hkak, XSj5='images/'):\n FaWX = XC5k.imread(Hy7s.path.join(XSj5, 'color_{}.png'.format(exwG)))\n TPao = XC5k.imread(Hy7s.path.join(XSj5, 'depth_{}.png'.format(exwG)), XC5k.IMREAD_UNCHANGED)\n hgjH = cX4W(FaWX, ZHfW)\n rb7a = TPao[int(hgjH[1]), int(hgjH[0])]\n return Yj0e(hgjH[0]... | [
"0.62691724",
"0.6009013",
"0.59770626",
"0.5973574",
"0.59053206",
"0.58681613",
"0.58417624",
"0.5814142",
"0.5789407",
"0.5769595",
"0.57346064",
"0.5702946",
"0.56923866",
"0.56844103",
"0.5663391",
"0.5636051",
"0.56345063",
"0.5621751",
"0.558693",
"0.5559862",
"0.55467... | 0.0 | -1 |
Initialize query message object. | def FIMM(YKHO, *, l633: Sequence[QueryItem]=None, **B2fa):
super().__init__(**B2fa)
YKHO.queries = l633 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, *qIxc, **c_sp):\n if qIxc or c_sp:\n super(IM36, YKHO).__init__(*qIxc, **c_sp)\n if YKHO.consumer is None:\n YKHO.consumer = ''\n if YKHO.start is None:\n YKHO.start = []\n if YKHO.goal is None:\n YKHO.goal = []\n if YKHO.goal_re... | [
"0.7635565",
"0.7489875",
"0.72178775",
"0.7105867",
"0.70839125",
"0.70839125",
"0.69211304",
"0.6823823",
"0.68144727",
"0.67525315",
"0.6742776",
"0.6742776",
"0.6703129",
"0.65656805",
"0.655075",
"0.65353835",
"0.64284074",
"0.64284074",
"0.6426618",
"0.6418934",
"0.6401... | 0.59635115 | 67 |
To pick a random value from a list. | def JbqO(D5g7):
D5g7 = eval(repr(D5g7))
f4hs = len(D5g7) - 1
clzY = ajWY(0, f4hs)
return D5g7[clzY] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NYnK(IqQl):\n hlel = tuKI.choice(IqQl)\n return hlel",
"def MkiW(YKHO, list):\n return tuKI.choice(list)",
"def Ddot(vC9B):\n if not vC9B:\n return None\n return vC9B[tuKI.randrange(len(vC9B))]",
"def UIrZ(YKHO) -> int:\n return Acvy(YKHO.my_list)",
"def lnM1(uAsi: list, mLGw: ... | [
"0.7965499",
"0.7851983",
"0.7799016",
"0.7742011",
"0.773849",
"0.771688",
"0.7710773",
"0.7688598",
"0.7591344",
"0.7568005",
"0.7538943",
"0.74427724",
"0.7435215",
"0.73828584",
"0.7326678",
"0.73207766",
"0.7247255",
"0.7207202",
"0.72047275",
"0.7180846",
"0.71754605",
... | 0.6791449 | 44 |
Convert a path specified using Unix path seperator into a platform path | def TrUB(pmON):
e35S = ''
for pG0V in pmON.split('/'):
if not pG0V:
e35S = Hy7s.sep
e35S = Hy7s.path.join(e35S, pG0V)
return e35S | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nTvx(pmON):\n return '/'.join(pmON.split('\\\\'))",
"def v3W7(CXKu):\n if CXKu == None:\n return None\n ouAn = str(CXKu).replace('\\\\', '/')\n return ouAn",
"def zR6r(U0tv):\n return str(U0tv.replace('\\\\', '/'))",
"def uN8q(pmON, Qb31=''):\n wdBY = '(?<![:/^a-zA-Z])([a-zA-Z]:[... | [
"0.78499895",
"0.77510446",
"0.7644771",
"0.7586295",
"0.74163723",
"0.73943794",
"0.73935616",
"0.7334795",
"0.725258",
"0.725258",
"0.71561545",
"0.7119756",
"0.71193963",
"0.704293",
"0.70209074",
"0.7011731",
"0.68994254",
"0.686548",
"0.68426055",
"0.6742871",
"0.6690564... | 0.0 | -1 |
Eliminate single number from string and return processed string. This is just helper to make call to string replace a bit more readable. | def sbbs(NPoT, DKJb):
return NPoT.replace(DKJb, '') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ev3m(GIN8):\n return ZbWC.sub('\\\\d+', '', GIN8)",
"def CptV(KCHu):\n if '-' in KCHu:\n KCHu = KCHu.replace('-', '')\n return KCHu.strip()",
"def mQGg(vIwR):\n return ZbWC.sub('\\\\D', '', vIwR)",
"def ev3m(YKHO, l5Ny):\n l5Ny = ZbWC.sub('[0-9]', '', l5Ny)\n return l5Ny",
"def... | [
"0.7492668",
"0.7291115",
"0.71869546",
"0.7126866",
"0.71009403",
"0.70552236",
"0.69204605",
"0.6862223",
"0.68566906",
"0.6799885",
"0.6776969",
"0.67468745",
"0.66998297",
"0.66998297",
"0.6682608",
"0.6625673",
"0.6609977",
"0.65647805",
"0.65438944",
"0.64736384",
"0.64... | 0.62732977 | 36 |
Go through all the boxes, and whenever there is a box with a value, eliminate this value from the values of all its peers. | def zJeh(hkxX):
vMy3 = [FlUN for FlUN in hkxX.keys() if len(hkxX[FlUN]) == 1]
for FlUN in vMy3:
Ko6S = hkxX[FlUN]
for jYLz in k5Tt[FlUN]:
zUz_(hkxX, jYLz, hkxX[jYLz].replace(Ko6S, ''))
return hkxX | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zJeh(hkxX):\n for Lves in qAH2(hkxX):\n for jYLz in iBIi.all_peers(Lves):\n hkxX = zUz_(hkxX, jYLz, hkxX[jYLz].replace(hkxX[Lves], ''))\n return hkxX",
"def zJeh(hkxX):\n vMy3 = [FlUN for FlUN in hkxX.keys() if len(hkxX[FlUN]) == 1]\n for FlUN in vMy3:\n AnMo = hkxX[FlUN]... | [
"0.8050001",
"0.79823416",
"0.7949503",
"0.79227084",
"0.7810061",
"0.7755604",
"0.77270633",
"0.76769596",
"0.7673013",
"0.764611",
"0.76384944",
"0.7627157",
"0.76108396",
"0.75385433",
"0.75301653",
"0.7521429",
"0.75007176",
"0.7494567",
"0.73963106",
"0.73508424",
"0.731... | 0.7586259 | 13 |
Go through all the units, and whenever there is a unit with a value that only fits in one box, assign the value to this box. | def rIvV(hkxX):
for PXGI in dzni:
for Ko6S in '123456789':
S5Zo = [FlUN for FlUN in PXGI if Ko6S in hkxX[FlUN]]
if len(S5Zo) == 1:
zUz_(hkxX, S5Zo[0], Ko6S)
return hkxX | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def qIMy(YKHO):\n for WKvO in range(9):\n for LVAh in range(9):\n exwG = YKHO.grid[WKvO][LVAh]\n if exwG != 0:\n YKHO._rows[LVAh].add(exwG)\n YKHO._columns[WKvO].add(exwG)\n YKHO._boxes[WKvO // 3][LVAh // 3].add(exwG)",
"def rIvV(hkxX):... | [
"0.67278117",
"0.60559636",
"0.60492986",
"0.6036982",
"0.587889",
"0.5845115",
"0.5843669",
"0.58301604",
"0.58271164",
"0.58036536",
"0.5752741",
"0.5698635",
"0.56834203",
"0.5674106",
"0.5638901",
"0.5622535",
"0.560375",
"0.5587851",
"0.5566135",
"0.55601674",
"0.5511417... | 0.536536 | 43 |
Iterate eliminate() and only_choice(). If at some point, there is a box with no available values, return False. If the sudoku is solved, return the sudoku. If after an iteration of both functions, the sudoku remains the same, return the sudoku. | def yimF(hkxX):
vMy3 = [FlUN for FlUN in hkxX.keys() if len(hkxX[FlUN]) == 1]
SGTU = False
while not SGTU:
sF3i = len([FlUN for FlUN in hkxX.keys() if len(hkxX[FlUN]) == 1])
hkxX = zJeh(hkxX)
hkxX = rIvV(hkxX)
hkxX = WqoA(hkxX)
cbJ8 = len([FlUN for FlUN in hkxX.keys()... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TgwQ(hkxX):\n hkxX = yimF(hkxX)\n if hkxX is False:\n return False\n if all((len(hkxX[KCHu]) == 1 for KCHu in oUSw)):\n return hkxX\n exwG, KCHu = min(((len(hkxX[KCHu]), KCHu) for KCHu in oUSw if len(hkxX[KCHu]) > 1))\n for BWXx in hkxX[KCHu]:\n dkel = hkxX.copy()\n d... | [
"0.7342017",
"0.7337624",
"0.73333204",
"0.7285762",
"0.721526",
"0.7201122",
"0.7167259",
"0.71657383",
"0.7161467",
"0.71602064",
"0.71347463",
"0.71319616",
"0.7106877",
"0.710357",
"0.70991266",
"0.70839906",
"0.7080131",
"0.70697445",
"0.7066466",
"0.70640326",
"0.704789... | 0.6583673 | 63 |
Sell shares of stock. | def ZBqQ():
if QePW.method == 'POST':
if len(QePW.form.get('stockname')) != 4:
return P88m('must provide 4-letter symbol')
DXkH = QePW.form.get('stockname')
DXkH = DXkH.upper()
if not QePW.form.get('quantity'):
return P88m('must provide number of shares')
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vLdO(YKHO, o61b, Z5kt):\n pass",
"def vLdO(YKHO):\n pass",
"def e4Ga(YKHO, q9zX, FGW3, RdoJ):\n pass",
"def D3VZ(YKHO):\n YKHO.txnumber = YKHO.txnumber + 1\n B__k = YKHO.portfolio.positions[YKHO.stockB].amount\n YKHO.order(YKHO.stockB, -1 * B__k)\n VjqK = YKHO.portfolio.positions[YKH... | [
"0.8072726",
"0.80631524",
"0.7693699",
"0.7502448",
"0.7384619",
"0.73099154",
"0.71875453",
"0.715517",
"0.7084526",
"0.7040975",
"0.70091456",
"0.6988881",
"0.69886714",
"0.695809",
"0.6924399",
"0.6924347",
"0.6921342",
"0.6840324",
"0.68282",
"0.6817779",
"0.6783763",
... | 0.66562355 | 32 |
Gets the group_id of this ProcessorStatusSnapshotDTO. The id of the parent process group to which the processor belongs. | def hE03(YKHO):
return YKHO._group_id | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def g5q5(YKHO):\n return YKHO._parent_group_id",
"def g5q5(YKHO):\n return YKHO._parent_group_id",
"def WM0R(YKHO):\n return J8uC.SBProcessInfo_GetGroupID(YKHO)",
"def e7pw(YKHO):\n return YKHO.group_id",
"def rfWX(YKHO):\n return YKHO.__group_id",
"def of7b(YKHO):\n return e0lz.checkRe... | [
"0.70997363",
"0.70997363",
"0.68701404",
"0.6705288",
"0.6671089",
"0.6549427",
"0.63121355",
"0.63121355",
"0.6299903",
"0.62630534",
"0.62000537",
"0.616251",
"0.616251",
"0.6113263",
"0.607845",
"0.606878",
"0.5955238",
"0.5955238",
"0.5955238",
"0.5951503",
"0.59148914",... | 0.67111564 | 3 |
Sets the group_id of this ProcessorStatusSnapshotDTO. The id of the parent process group to which the processor belongs. | def hE03(YKHO, hE03):
YKHO._group_id = hE03 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def g5q5(YKHO, g5q5):\n YKHO._parent_group_id = g5q5",
"def g5q5(YKHO, g5q5):\n YKHO._parent_group_id = g5q5",
"def oC6H(YKHO, hE03):\n if oyIN.isscalar(hE03):\n hE03 = hE03 * oyIN.ones(YKHO.n_trial, dtype=oyIN.int32)\n else:\n hE03 = YKHO._check_group_id(hE03)\n YKHO.group_id = jt... | [
"0.62001437",
"0.62001437",
"0.60619396",
"0.5977401",
"0.59354615",
"0.5875287",
"0.58576256",
"0.5789255",
"0.57755506",
"0.5745501",
"0.57237875",
"0.56516916",
"0.5636626",
"0.55840516",
"0.5553554",
"0.5553554",
"0.5553554",
"0.5553554",
"0.5553554",
"0.5553554",
"0.5552... | 0.6445827 | 0 |
Gets the name of this ProcessorStatusSnapshotDTO. The name of the prcessor. | def mWFP(YKHO):
return YKHO._name | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rxy2(YKHO) -> QMSQ:\n ...",
"def qoe8(YKHO) -> str:\n return YKHO._name_",
"def W0tD(YKHO):\n return YKHO._pipeline['name']",
"def IzcX(YKHO) -> str:\n return qe4Y.get(YKHO, 'snapshot_name')",
"def qoe8(YKHO) -> str:\n return YKHO.__class__.STATUSES[YKHO.status]",
"def qoe8(YKHO) -> st... | [
"0.6788759",
"0.63822085",
"0.6273392",
"0.60911256",
"0.60662335",
"0.60662335",
"0.5999216",
"0.597823",
"0.59634554",
"0.59623593",
"0.595684",
"0.59340024",
"0.59324163",
"0.59236526",
"0.5917537",
"0.5911145",
"0.5907136",
"0.58669513",
"0.58381516",
"0.5819374",
"0.5819... | 0.0 | -1 |
Gets the type of this ProcessorStatusSnapshotDTO. The type of the processor. | def type(YKHO):
return YKHO._type | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ou5b(YKHO):\n return YKHO._type_status",
"def th0h(YKHO) -> str:\n return qe4Y.get(YKHO, 'snapshot_type')",
"def FRul(YKHO):\n return YKHO.p_type",
"def type(YKHO):\n return YKHO.container['type']",
"def Dlsn(YKHO):\n return YKHO._type",
"def YwLH(YKHO):\n return YKHO._type",
"def... | [
"0.6563282",
"0.6243832",
"0.6127745",
"0.61199164",
"0.6114471",
"0.6102428",
"0.6102428",
"0.6085415",
"0.6085415",
"0.6050442",
"0.6050442",
"0.6050442",
"0.603362",
"0.60228217",
"0.60228217",
"0.60228217",
"0.60228217",
"0.60228217",
"0.60228217",
"0.60228217",
"0.595437... | 0.5910378 | 30 |
Gets the run_status of this ProcessorStatusSnapshotDTO. The state of the processor. | def duE9(YKHO):
return YKHO._run_status | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gBz1(YKHO, BMxt):\n try:\n NCls = uhih().connect()\n fQaP = NCls.get_pipeline(run_id=BMxt)\n duE9 = fQaP.get('run').get('status') or 'none'\n nPrm = qQXR.loads(fQaP.get('pipeline_runtime').get('workflow_manifest'))\n Ls_V = nPrm.get('status').get('startedAt')\n if L... | [
"0.6898596",
"0.657998",
"0.6252197",
"0.6235619",
"0.62316626",
"0.6213694",
"0.6213694",
"0.6213694",
"0.6212041",
"0.62096643",
"0.61869204",
"0.61869204",
"0.61466706",
"0.61466706",
"0.61466706",
"0.61157715",
"0.6113764",
"0.6111654",
"0.6093566",
"0.60829556",
"0.60794... | 0.7417402 | 0 |
Gets the execution_node of this ProcessorStatusSnapshotDTO. Indicates the node where the process will execute. | def Ad1h(YKHO):
return YKHO._execution_node | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VLTN(YKHO):\n return YKHO._node_status",
"def OwQA(YKHO) -> str:\n return qe4Y.get(YKHO, 'execution_state')",
"def IyQV(YKHO):\n if YKHO.is_active:\n return YKHO.deployment.get_active_node(YKHO.aws_type, YKHO.node_name)\n else:\n return YKHO.deployment.get_pending_node(YKHO.aws_ty... | [
"0.6038062",
"0.60364765",
"0.59853977",
"0.5948177",
"0.5909906",
"0.5904545",
"0.5847561",
"0.5796107",
"0.5775583",
"0.57588774",
"0.5748263",
"0.56948096",
"0.56906176",
"0.567142",
"0.5664326",
"0.5648805",
"0.5633353",
"0.5605284",
"0.5602831",
"0.5558543",
"0.5558543",... | 0.7900158 | 0 |
Gets the input of this ProcessorStatusSnapshotDTO. The count/size of flowfiles that have been accepted in the last 5 minutes. | def input(YKHO):
return YKHO._input | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rRSm(YKHO):\n return YKHO._flow_files_received",
"def hhFT(YKHO):\n return YKHO._flow_files_sent",
"def zNig(YKHO):\n return YKHO.getState()['size']",
"def zNig():\n return phWX.size()",
"def zNig(YKHO):\n return YKHO.queue['size']",
"def zNig(YKHO) -> int:\n return YKHO.stream_info... | [
"0.59229964",
"0.5844215",
"0.57399535",
"0.5739204",
"0.57285184",
"0.572676",
"0.55914927",
"0.5581387",
"0.556423",
"0.5533181",
"0.54761744",
"0.547522",
"0.54659796",
"0.5460376",
"0.54298496",
"0.5423814",
"0.54125273",
"0.5407201",
"0.5407201",
"0.53770655",
"0.5377065... | 0.0 | -1 |
Sets the input of this ProcessorStatusSnapshotDTO. The count/size of flowfiles that have been accepted in the last 5 minutes. | def input(YKHO, input):
YKHO._input = input | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sRhP(YKHO):\n YKHO.__set_state('processing')\n YKHO.size = yvY1.SERVICE_STORE[YKHO.status.service].config['job_size']",
"def z7JB(YKHO, BWXx):\n pass",
"def w8Lw(YKHO, qxeD, jGRS):\n YKHO._patch_value(qxeD, 'file_ingestion_status', jGRS)",
"def Baw8(Emd4):\n super().setUpClass()\n super... | [
"0.5227605",
"0.52135783",
"0.5175916",
"0.5116942",
"0.5115837",
"0.5077083",
"0.50546634",
"0.5046118",
"0.50365496",
"0.5014096",
"0.50108755",
"0.500484",
"0.49486",
"0.49408808",
"0.49332556",
"0.49175757",
"0.49175757",
"0.49175757",
"0.49175757",
"0.49175757",
"0.49170... | 0.0 | -1 |
Gets the tasks_duration_nanos of this ProcessorStatusSnapshotDTO. The number of nanoseconds that this Processor has spent running in the last 5 minutes | def tQxf(YKHO):
return YKHO._tasks_duration_nanos | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wnXA(YKHO):\n return YKHO._tasks_duration",
"def tQxf(YKHO, tQxf):\n YKHO._tasks_duration_nanos = tQxf",
"def EdTY(YKHO):\n return sum([Mkmy.duration for Mkmy in YKHO.run_info])",
"def EdTY(YKHO) -> int:\n return YKHO.execution_config.duration",
"def EdTY(YKHO):\n if oyIN.isnan(YKHO.star... | [
"0.719536",
"0.61978555",
"0.60780096",
"0.59331745",
"0.5856398",
"0.56163",
"0.5593072",
"0.55926806",
"0.5591608",
"0.5538918",
"0.5468453",
"0.54627055",
"0.5452994",
"0.5447886",
"0.54006076",
"0.5396307",
"0.5395873",
"0.539331",
"0.539331",
"0.539331",
"0.539331",
"0... | 0.78962654 | 0 |
Gets the tasks_duration of this ProcessorStatusSnapshotDTO. The total duration of all tasks for this connectable over the last 5 minutes. | def wnXA(YKHO):
return YKHO._tasks_duration | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tQxf(YKHO):\n return YKHO._tasks_duration_nanos",
"def EdTY(YKHO):\n return sum([Mkmy.duration for Mkmy in YKHO.run_info])",
"def EdTY(YKHO) -> int:\n return YKHO.execution_config.duration",
"def WbTE(YKHO, YPaw=1):\n if YKHO.position >= 0:\n xCjU = YKHO[YKHO.position + YPaw:]\n ... | [
"0.6834224",
"0.6143579",
"0.6022314",
"0.6000402",
"0.5779213",
"0.5651567",
"0.5651567",
"0.5624569",
"0.5614144",
"0.5587784",
"0.55830824",
"0.5579087",
"0.5564946",
"0.5564946",
"0.5564946",
"0.5564946",
"0.5564946",
"0.55443543",
"0.55427015",
"0.5533557",
"0.5518608",
... | 0.762766 | 0 |
Sets the tasks_duration of this ProcessorStatusSnapshotDTO. The total duration of all tasks for this connectable over the last 5 minutes. | def wnXA(YKHO, wnXA):
YKHO._tasks_duration = wnXA | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tQxf(YKHO, tQxf):\n YKHO._tasks_duration_nanos = tQxf",
"def wnXA(YKHO):\n return YKHO._tasks_duration",
"def tQxf(YKHO):\n return YKHO._tasks_duration_nanos",
"def kDRY(YKHO, kDRY):\n YKHO._duration_seconds = kDRY",
"def WbTE(YKHO, WbTE):\n YKHO._duration = WbTE",
"def WbTE(YKHO, WbTE... | [
"0.67896885",
"0.62244123",
"0.5482425",
"0.53713274",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5222024",
"0.5206402",
"0.51842105",
"0.5096501",
"0.49930573",
"0.49930573",
"0.4986167",
"0.4969875... | 0.79596 | 0 |
Gets the active_thread_count of this ProcessorStatusSnapshotDTO. The number of threads currently executing in the processor. | def jd9z(YKHO):
return YKHO._active_thread_count | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bkyN(YKHO):\n return J8uC.SBProcess_GetNumThreads(YKHO)",
"def HyLP(YKHO):\n return YKHO._platform_impl.get_process_num_threads()",
"def OoLq(YKHO):\n YKHO.__resizeLock.acquire()\n try:\n return len(YKHO.__threads)\n finally:\n YKHO.__resizeLock.release()",
"def OoLq(YKHO):\n... | [
"0.68333125",
"0.6635196",
"0.6562968",
"0.65343946",
"0.6479985",
"0.64515406",
"0.64515406",
"0.64515406",
"0.64427197",
"0.64383465",
"0.6419047",
"0.634707",
"0.6268274",
"0.62383735",
"0.6221313",
"0.6208453",
"0.61920387",
"0.6155998",
"0.6134599",
"0.60874385",
"0.6087... | 0.77788216 | 0 |
Sets the active_thread_count of this ProcessorStatusSnapshotDTO. The number of threads currently executing in the processor. | def jd9z(YKHO, jd9z):
YKHO._active_thread_count = jd9z | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def jd9z(YKHO):\n return YKHO._active_thread_count",
"def jd9z(YKHO):\n return YKHO._active_thread_count",
"def BWRa(YKHO):\n Esm4.activeCount += 1",
"def fwuu(YKHO, QJnz):\n YKHO._api.LITE_set_cpu_threads_number(YKHO._network, QJnz)",
"def DM1Q(YKHO, DM1Q):\n YKHO._active_remote_port_count ... | [
"0.63909817",
"0.63909817",
"0.5927164",
"0.5657314",
"0.5611587",
"0.5609029",
"0.5542621",
"0.55332994",
"0.54356647",
"0.54356647",
"0.5346903",
"0.52968305",
"0.52962774",
"0.5287171",
"0.52709115",
"0.52658033",
"0.522667",
"0.5212542",
"0.5190669",
"0.5184558",
"0.51573... | 0.7679324 | 0 |
Gets the terminated_thread_count of this ProcessorStatusSnapshotDTO. The number of threads currently terminated for the processor. | def ioha(YKHO):
return YKHO._terminated_thread_count | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def OoLq(YKHO):\n YKHO.__resizeLock.acquire()\n try:\n return len(YKHO.__threads)\n finally:\n YKHO.__resizeLock.release()",
"def OoLq(YKHO):\n YKHO.__resizeLock.acquire()\n try:\n return len(YKHO.__threads)\n finally:\n YKHO.__resizeLock.release()",
"def bkyN(YKHO... | [
"0.62858427",
"0.62210846",
"0.6181566",
"0.5937501",
"0.5853119",
"0.5840211",
"0.5840211",
"0.57743585",
"0.5738845",
"0.56927264",
"0.5539565",
"0.55263597",
"0.5516997",
"0.538893",
"0.535496",
"0.53290623",
"0.5248842",
"0.524718",
"0.52306604",
"0.52199143",
"0.5163024"... | 0.75108683 | 0 |
Returns the string representation of the model | def gTzM(YKHO):
return EyO9(YKHO.to_dict()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__model)",
"def zAg0(YKHO):\n return str(YKHO.model)",
"def zAg0(YKHO):\n return YKHO.text",
"def zAg0(YKHO):\n oOUF = '-----------------------------------------------------------------------------------\\n'\n _2sc = YKHO.__class__.__name__\n oOUF += '\\t\\... | [
"0.86418265",
"0.85103965",
"0.7853324",
"0.77442306",
"0.7712258",
"0.76979405",
"0.765959",
"0.7637644",
"0.76218504",
"0.7607561",
"0.7606604",
"0.7606604",
"0.7606604",
"0.75990754",
"0.7585653",
"0.758149",
"0.7570811",
"0.7567585",
"0.75392604",
"0.75392604",
"0.7527967... | 0.0 | -1 |
Returns true if both objects are not equal | def Vdqg(YKHO, Elif):
return not YKHO == Elif | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO.__eq__(Elif)",
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif: object):\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif):\n if YKHO.__eq__(Elif):\n return False\n return True",
"def Vdqg(... | [
"0.8392633",
"0.8354901",
"0.82950056",
"0.8132309",
"0.81149805",
"0.8099986",
"0.809911",
"0.8097883",
"0.8097883",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8066694",
"0.80594814",
"0.805757",
... | 0.0 | -1 |
Returns a UNet model compiled with focal loss | def x5jI(GhuM, jTqs):
g4y1 = X6a0(GhuM)
j2cC = yHwh(64, 3, activation='relu', padding='same', kernel_initializer='he_normal')(g4y1)
j2cC = yHwh(64, 3, activation='relu', padding='same', kernel_initializer='he_normal')(j2cC)
HXYP = BzBX(pool_size=(2, 2))(j2cC)
I7zk = yHwh(128, 3, activation='relu', p... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def qJba(YKHO):\n hnFq = YKHO.s.PATCH_SIZE\n if YKHO.s.VARIABLE_PATCH_SIZE:\n hnFq = (None, None, None)\n if YKHO.s.NR_DIM == 2:\n hnFq = hnFq[1:]\n if YKHO.s.USE_LA_INPUT:\n hnFq += (2,)\n else:\n hnFq += (1,)\n C3ST = prOL(hnFq, YKHO.s.NR_DIM, dropout=YKHO.s.DROPOUT,... | [
"0.693564",
"0.6431453",
"0.639257",
"0.6233923",
"0.62096316",
"0.6167181",
"0.6157735",
"0.6146038",
"0.612699",
"0.61128044",
"0.60677975",
"0.6055751",
"0.6047253",
"0.6015258",
"0.59984964",
"0.59917694",
"0.5991718",
"0.5967892",
"0.5965819",
"0.59631073",
"0.59544843",... | 0.7232255 | 0 |
Calculate the cumulative distribution function at each point. | def wcmX(iVRZ: NDArrayFloat) -> mV7i:
return AbB8(oyIN.sort(iVRZ), iVRZ, side='right') / len(iVRZ) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FQed(YKHO):\n wjRY = 0.0\n for YRbF in range(0, YKHO.tick_count):\n Yqag = YKHO.get_x_value_from_index(YRbF)\n Q7Be = YKHO.shape_function(Yqag)\n zgiu.validate_real_number_is_positive_or_zero(Q7Be)\n wjRY += Q7Be\n YKHO.cumulative_function.append(wjRY)",
"def GvK6(YKH... | [
"0.7985106",
"0.75023425",
"0.736071",
"0.7188023",
"0.7056282",
"0.7032315",
"0.6880811",
"0.67828953",
"0.67827743",
"0.6779135",
"0.6752341",
"0.6731727",
"0.67084163",
"0.67038274",
"0.66620165",
"0.6627354",
"0.66241133",
"0.6620891",
"0.65895206",
"0.6578036",
"0.655590... | 0.67380977 | 11 |
r""" Returns the number of pores of the specified labels | def nrnJ(YKHO, Crrw='all', Tuqy='or'):
Eafu = YKHO._get_indices(labels=Crrw, mode=Tuqy, element='pore')
Kr7U = oyIN.shape(Eafu)[0]
return Kr7U | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def r8Bx(Crrw):\n JbQV = {}\n for vC9B in Crrw:\n if not JbQV.__contains__(vC9B):\n JbQV[vC9B] = 1\n else:\n JbQV[vC9B] += 1\n return JbQV",
"def svPB(YKHO):\n return len(YKHO._labels)",
"def yMkk(YKHO):\n return len(YKHO._labels)",
"def TBqt(Crrw):\n exw... | [
"0.75753546",
"0.7540017",
"0.75070244",
"0.7432191",
"0.73554033",
"0.73234576",
"0.73211837",
"0.7314065",
"0.73082024",
"0.7221665",
"0.7221665",
"0.72004926",
"0.7161412",
"0.71128356",
"0.7002734",
"0.6928876",
"0.6917831",
"0.6886732",
"0.6862441",
"0.6851196",
"0.68387... | 0.7761269 | 0 |
Test serialization using JSON. | def bQrG():
Gt_N = {'name': 'Abraham Lincoln', 'birth_year': 1809, 'nicknames': ['Honest Abe', 'Abe'], 'facts': {'Born In': 'Kentucky', 'Died In': 'Washington D.C.', 'Greatest Speech': T3LT}}
oAiD = qQXR.dumps(Gt_N)
qQXR.loads(oAiD) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fjiE(YKHO):\n YKHO.save_and_check('json')",
"def fjiE(YKHO):\n YKHO.save_and_check('json')",
"def QoPi(YKHO):\n YKHO._TestReadSerialized(YKHO._serializer, YKHO._json_dict)",
"def QoPi(YKHO):\n YKHO._TestReadSerialized(YKHO._serializer, YKHO._json_dict)",
"def FCYx(YKHO):\n nMY2 = qQXR.du... | [
"0.80497193",
"0.80497193",
"0.7774263",
"0.7774263",
"0.77213573",
"0.77151537",
"0.76433676",
"0.7482355",
"0.74366707",
"0.74352854",
"0.7388384",
"0.73873335",
"0.735484",
"0.732241",
"0.7311674",
"0.7280073",
"0.7215265",
"0.7197996",
"0.7181588",
"0.7175276",
"0.7140437... | 0.0 | -1 |
Test serialization using SimpleJSON. | def gmCw():
Gt_N = {'name': 'Abraham Lincoln', 'birth_year': 1809, 'nicknames': ['Honest Abe', 'Abe'], 'facts': {'Born In': 'Kentucky', 'Died In': 'Washington D.C.', 'Greatest Speech': T3LT}}
oAiD = HjBM.dumps(Gt_N)
HjBM.loads(oAiD) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def T4A1(YKHO):\n try:\n import simplejson\n except ImportError:\n return YKHO.skipTest('simplejson is missing: ignore')\n YKHO._check_expected_best('simplejson')\n try:\n simplejson.loads = iVqE\n simplejson.dumps = ATlr\n qgzx(NCp0)\n _WV2, uTfY = NCp0.get_ha... | [
"0.7526743",
"0.7474806",
"0.7474806",
"0.7372599",
"0.7284768",
"0.7284768",
"0.7208637",
"0.7159742",
"0.71420455",
"0.7025453",
"0.6979857",
"0.6947587",
"0.6890235",
"0.6834258",
"0.68312556",
"0.6823122",
"0.6799127",
"0.6772946",
"0.67525184",
"0.6743901",
"0.67348033",... | 0.6984732 | 10 |
Validate the column names to ensure no reserved words are used. | def AU_I(Kiac):
f1P0 = open(Hy7s.path.join(Hy7s.path.dirname(xAKo), 'redshift_reserve_words.txt'), 'r').readlines()
f1P0 = [Mkmy.strip().lower() for Mkmy in f1P0]
Kiac.columns = [WKvO.lower() for WKvO in Kiac.columns]
for fvDH in Kiac.columns:
try:
assert fvDH not in f1P0
exc... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def T02Q(ZLJ_):\n RqJi = []\n RqJi = [Z9rn for Z9rn in ZLJ_ if Z9rn in wzF7]\n if len(RqJi) > 0:\n raise BSol('Redshift reserved words: f{invalid_df_col_names}')",
"def tbZm(YKHO):\n Ltot = {'label'}\n if not Ltot.issubset(YKHO.df.columns):\n raise Exception('Missing columns, require... | [
"0.7783089",
"0.73328817",
"0.7289173",
"0.72434103",
"0.72269744",
"0.72123957",
"0.7062462",
"0.7038857",
"0.6945975",
"0.69151014",
"0.68522143",
"0.67942715",
"0.6759397",
"0.67025083",
"0.66899514",
"0.66715544",
"0.66386783",
"0.6609556",
"0.6570537",
"0.6560317",
"0.65... | 0.77909446 | 0 |
r""" Fills the input Tensor with values drawn from the normal | def NclY(vhpA, JBMS=0.0, M1Jx=1.0):
with _uqo.no_grad():
if vhpA.is_local:
return _uqo.normal(mean=JBMS, std=M1Jx, size=vhpA.shape, out=vhpA)
else:
return _uqo.normal(mean=JBMS, std=M1Jx, size=vhpA.shape, out=vhpA, placement=vhpA.placement, sbp=vhpA.sbp) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QZoP(PU1l: tf.Tensor) -> ZylS.Tensor:\n return PU1l",
"def pffD(ROpF, **B2fa):\n return ZylS.cast(aevO.StochasticTensor(oxOY.MultivariateNormalDiag(ZylS.zeros(ROpF), ZylS.ones(ROpF), **B2fa)), ZylS.float32)",
"def idFg(CK9p):\n return ZylS.layers.batch_normalization(CK9p)",
"def JjUQ(vhpA, WTkW,... | [
"0.7102345",
"0.6695007",
"0.6467741",
"0.64589596",
"0.63935727",
"0.62226295",
"0.6212342",
"0.6207185",
"0.61856437",
"0.6175886",
"0.6175886",
"0.6175886",
"0.61493635",
"0.61379135",
"0.6134666",
"0.6131272",
"0.61230105",
"0.6110139",
"0.609328",
"0.6093026",
"0.6075876... | 0.64719266 | 2 |
r""" Fills the input `Tensor` with a (semi) orthogonal matrix, as described in `Exact solutions to the nonlinear dynamics of learning in deep linear neural networks` Saxe, A. et al. (2013). The input tensor must have at least 2 dimensions, and for tensors with more than 2 dimensions the trailing dimensions are flattene... | def a1vI(vhpA, mb4J=1.0):
with _uqo.no_grad():
return vhpA.orthogonal_(mb4J) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vPyM(a1PO: int, exwG: int, vhpA: torch.Tensor) -> ht2j.Tensor:\n WKvO = vhpA.transpose(1, 2)\n return WKvO.view(a1PO * exwG, *WKvO.size()[2:])",
"def _4I8(YKHO, FRUf):\n kvqa = FRUf.shape.ndims\n if kvqa < 2:\n raise ValueError('Input tensor must have at least rank 2.Shape = %s' % FRUf.sha... | [
"0.6364076",
"0.6301998",
"0.63004565",
"0.62837297",
"0.62380147",
"0.61953217",
"0.6152364",
"0.60595316",
"0.6058882",
"0.6028577",
"0.5966984",
"0.5961591",
"0.592322",
"0.5869357",
"0.58503443",
"0.58062977",
"0.57552314",
"0.5751522",
"0.5746948",
"0.5746948",
"0.574694... | 0.5285611 | 76 |
starts empty linked list | def FIMM(YKHO):
YKHO.head = None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sjQ6():\n return _sfu()",
"def FIMM(YKHO, W8qs=None):\n YKHO.sentinel = DhlT()\n YKHO.sentinel.next = YKHO.sentinel\n YKHO.sentinel.prev = YKHO.sentinel\n if W8qs is not None:\n for nPrm in W8qs:\n YKHO.add_back(nPrm)",
"def CQul(YKHO, nPrm):\n if YKHO.start_node is None... | [
"0.73935944",
"0.7315331",
"0.70612866",
"0.7037693",
"0.69472873",
"0.6933862",
"0.69093513",
"0.68806785",
"0.68650717",
"0.68521506",
"0.68521506",
"0.68521506",
"0.6834501",
"0.6810901",
"0.6810901",
"0.6810901",
"0.6781781",
"0.67614836",
"0.67536664",
"0.6752464",
"0.67... | 0.6832873 | 13 |
Takes a walk, represented by a 3D Tensor with shape (batch_size, walk_length, embedding_length), and computes its embedding using a simple additive models. | def DEAy(id0L):
Ep8u, T5sU = (ZylS.shape(id0L)[0], ZylS.shape(id0L)[2])
IiZI = ZylS.transpose(id0L, perm=[1, 0, 2])
MuED = ZylS.zeros((Ep8u, T5sU), dtype=id0L.dtype)
kcP0 = ZylS.scan(lambda WKvO, LVAh: WKvO + LVAh, IiZI, initializer=MuED)
return ZylS.concat(values=[ZylS.expand_dims(MuED, 0), kcP0], ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def l3jA(id0L):\n Ep8u, T5sU = (ZylS.shape(id0L)[0], ZylS.shape(id0L)[2])\n\n def XP5J(WKvO, LVAh):\n return WKvO * LVAh\n\n def I0EE(WKvO, LVAh):\n rNVT, k0sw = ZylS.split(value=WKvO, num_or_size_splits=2, axis=1)\n zkXe, pnTu = ZylS.split(value=LVAh, num_or_size_splits=2, axis=1)\n ... | [
"0.6782476",
"0.63637835",
"0.63134253",
"0.62953144",
"0.626212",
"0.6198239",
"0.61624163",
"0.6133519",
"0.6094446",
"0.60913384",
"0.6081048",
"0.60516965",
"0.6048321",
"0.60306007",
"0.6014318",
"0.59951884",
"0.59856397",
"0.5979534",
"0.5972927",
"0.59582525",
"0.5948... | 0.6943481 | 0 |
Return the skeleton with all values normalized to 1. | def VYfJ(Bjf9):
return oyIN.where(Bjf9 > 0, 1, 0) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def iC99(WKvO):\n WKvO -= WKvO.min(1, keepdim=True)[0]\n WKvO /= WKvO.max(1, keepdim=True)[0]\n WKvO = (WKvO - 0.5) * 2\n return WKvO",
"def Elie(YKHO):\n return YKHO / YKHO.iloc[1]",
"def ljSO(YKHO):\n ljSO = Q1Kq()\n ljSO.add_vertices(YKHO.skeleton_points(1))\n for D70y in YKHO.edges_... | [
"0.63807815",
"0.63560677",
"0.63125443",
"0.610147",
"0.60788447",
"0.6077681",
"0.60677785",
"0.6042894",
"0.6036926",
"0.600795",
"0.5934409",
"0.5933088",
"0.59026664",
"0.5901537",
"0.5892546",
"0.5881126",
"0.58475256",
"0.5811213",
"0.57997245",
"0.57835835",
"0.577503... | 0.68787587 | 0 |
Return the bias potential after changes are applied. | def nrOS(YKHO, CKaQ):
BWXx = YKHO.reac_init.get(YKHO.mc.atoms, CKaQ)
return YKHO.get_bias_potential(BWXx) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oug5(YKHO):\n return YKHO._bias",
"def fthx(YKHO):\n return YKHO.getGlobalVariableByName('bias')",
"def fthx(YKHO):\n return YKHO.getGlobalVariableByName('bias')",
"def oug5(YKHO):\n return YKHO.loaded[YKHO.model_name]['elmo_softmax_b']",
"def klBM(YKHO):\n R9Vg = YKHO.m[YKHO._gm] * YKHO... | [
"0.7575611",
"0.73699296",
"0.73699296",
"0.7254316",
"0.72494674",
"0.7138802",
"0.71158093",
"0.7023411",
"0.6981438",
"0.69476706",
"0.68855983",
"0.6691003",
"0.6685798",
"0.6675362",
"0.66613656",
"0.66303074",
"0.6616963",
"0.6582192",
"0.6565589",
"0.654642",
"0.654426... | 0.67198294 | 11 |
Update the navigation property shared in users. Update the navigation property shared in users. | def WTgY(YKHO, uJjO, rsux, TBsA, **B2fa):
Emd4 = B2fa.pop('cls', None)
KVtY = {401: lhwm, 404: llBy, 409: DKDz}
KVtY.update(B2fa.pop('error_map', {}))
m5r4 = B2fa.pop('content_type', 'application/json')
Hhz4 = 'application/json'
bD7m = YKHO.update_shared.metadata['url']
wiSa = {'user-id': YK... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hyh_(YKHO):\n YKHO.collection.update_relations(YKHO)",
"def QdZT(YKHO, CfnU):\n for g_7i in CfnU.users:\n if g_7i not in YKHO.users:\n YKHO.add_user(g_7i)\n else:\n pmt5 = YKHO.users[YKHO.users.index(g_7i)]\n if g_7i.goals:\n pmt5.goals.upda... | [
"0.60267323",
"0.5848056",
"0.5808453",
"0.5405543",
"0.5266376",
"0.52648187",
"0.52621603",
"0.5241686",
"0.523133",
"0.5205424",
"0.5191833",
"0.5182403",
"0.5071669",
"0.50621593",
"0.49792072",
"0.4978703",
"0.4978444",
"0.4953699",
"0.49454507",
"0.49355894",
"0.4928248... | 0.46109232 | 88 |
Update the navigation property rubrics in education. Update the navigation property rubrics in education. | async def update_rubric(YKHO, QEla: str, id: Optional[str]=None, qL1h: Optional[datetime.datetime]=None, JBZA: Optional['models.MicrosoftGraphEducationItemBody']=None, qQNS: Optional[str]=None, Yw5Q: Optional[Dict[str, object]]=None, zqJH: Optional[datetime.datetime]=None, bctv: Optional[List['models.MicrosoftGraphRubr... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hyh_(YKHO):\n YKHO.collection.update_relations(YKHO)",
"def hSsa(YKHO, hSsa):\n YKHO._education = hSsa",
"def mCzJ(YKHO, IrAr):\n YKHO.profile.level_of_education = IrAr\n YKHO.profile.save()",
"def zFJw(YKHO, Ql2Z: str, GTfO: List[str]) -> None:\n for fAgD in YKHO.rubrics:\n if fAgD... | [
"0.5410694",
"0.5295471",
"0.5230464",
"0.51889044",
"0.502151",
"0.48595953",
"0.47178897",
"0.4682752",
"0.46431202",
"0.45976177",
"0.45771733",
"0.4568601",
"0.45685828",
"0.45415592",
"0.45360166",
"0.4523422",
"0.44996405",
"0.44942716",
"0.44732487",
"0.44664925",
"0.4... | 0.56854236 | 0 |
Create new navigation property ref to schools for education. Create new navigation property ref to schools for education. | async def create_ref_school(YKHO, TBsA: Dict[str, object], **B2fa) -> cuzp[str, object]:
Emd4 = B2fa.pop('cls', None)
KVtY = {404: llBy, 409: DKDz}
KVtY.update(B2fa.pop('error_map', {}))
m5r4 = B2fa.pop('content_type', 'application/json')
Hhz4 = 'application/json'
bD7m = YKHO.create_ref_school.m... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def create_school(YKHO, id: Optional[str]=None, JBZA: Optional[str]=None, qQNS: Optional[str]=None, JLbE: Optional[Union[str, 'models.MicrosoftGraphEducationExternalSource']]=None, Kizg: Optional[str]=None, UTX6: Optional['models.MicrosoftGraphPhysicalAddress']=None, WhG7: Optional[str]=None, B08B: Optional[... | [
"0.55500275",
"0.54399866",
"0.5323564",
"0.52918875",
"0.5184997",
"0.5167108",
"0.5156407",
"0.5140673",
"0.51321095",
"0.5078561",
"0.50622207",
"0.5048769",
"0.4977427",
"0.4959772",
"0.49379662",
"0.49027127",
"0.48665264",
"0.48617762",
"0.48429188",
"0.48379758",
"0.47... | 0.45008397 | 37 |
Generates a simple 8 char random password | def FbI1():
gZgb = 'abcdefghijklmnopqrstuvwxyz'
QIV9 = gZgb.upper()
w3x3 = 8
d4Wd = []
for YRbF in range(w3x3 // 3):
d4Wd.append(gZgb[tuKI.randrange(len(gZgb))])
d4Wd.append(QIV9[tuKI.randrange(len(QIV9))])
d4Wd.append(str(tuKI.randrange(10)))
for YRbF in range(w3x3 - len... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ikbr():\n return ''.join((jxbx().choice(tcl1 + BHGE) for bGrB in range(8)))",
"def BSw2():\n return ''.join((tuKI.choice(vIwR.ascii_uppercase + vIwR.digits) for WKvO in range(8)))",
"def ikbr(YKHO):\n gLiZ = 'abcdefghijkmnpqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ23456789'\n zNig = 8\n return ''.jo... | [
"0.92077744",
"0.90725327",
"0.8930199",
"0.89168876",
"0.8859421",
"0.8828989",
"0.87368685",
"0.86428076",
"0.8627924",
"0.8618213",
"0.8594219",
"0.85833895",
"0.85769355",
"0.8575894",
"0.8574226",
"0.8548021",
"0.85385275",
"0.85149366",
"0.8501559",
"0.84950465",
"0.849... | 0.81910974 | 37 |
Returns the indexes of minima | def yArs(c0yN: Charts, KnxT=4):
bS0K = dict()
for QdZ9 in c0yN.close:
bS0K[QdZ9] = []
for OWrz in range(0, c0yN.max_len - KnxT):
if PVcr(OWrz, c0yN, QdZ9, offset=KnxT):
or8S = HEtC(OWrz, c0yN, QdZ9)
if oyIN.min(c0yN.low[QdZ9][or8S - KnxT:or8S]) >= c0yN... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FPhD(WKvO):\n ycBG = oyIN.sign(oyIN.diff(WKvO)[:-1]) + oyIN.sign(oyIN.diff(WKvO[::-1])[:-1][::-1])\n ycBG = oyIN.nonzero(ycBG < 0)[0] + 1\n e6I6 = []\n if WKvO[0] < WKvO[1]:\n e6I6.append(0)\n [e6I6.append(YRbF) for YRbF in ycBG]\n if WKvO[-1] < WKvO[-2]:\n e6I6.append(WKvO.size... | [
"0.75369364",
"0.73946935",
"0.69552827",
"0.686502",
"0.6815535",
"0.6760886",
"0.67315614",
"0.6630751",
"0.65817803",
"0.65187633",
"0.6474566",
"0.64061755",
"0.6388079",
"0.63818514",
"0.6375775",
"0.63655883",
"0.6361886",
"0.6344492",
"0.6317752",
"0.6309756",
"0.62596... | 0.59578466 | 48 |
Dropout for sparse tensors. | def zSpM(WKvO, sMyr, ZqPb):
FzVw = sMyr
FzVw += ZylS.random_uniform(ZqPb)
Vwv8 = ZylS.cast(ZylS.floor(FzVw), dtype=ZylS.bool)
TYvy = ZylS.sparse_retain(WKvO, Vwv8)
return TYvy * (1.0 / sMyr) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def T7wl(YKHO, EcVT, sMyr, f3d9):\n ZqPb = [f3d9]\n FzVw = sMyr\n FzVw += ZylS.random_uniform(ZqPb)\n Vwv8 = ZylS.cast(ZylS.floor(FzVw), dtype=ZylS.bool)\n TYvy = ZylS.sparse_retain(EcVT, Vwv8)\n return TYvy * ZylS.div(1.0, sMyr)",
"def zSpM(WKvO, TyPQ, ZqPb):\n sMyr = 1 - TyPQ\n FzVw = s... | [
"0.7382417",
"0.726438",
"0.7114191",
"0.70389307",
"0.7024962",
"0.7023379",
"0.7023041",
"0.7004472",
"0.67157906",
"0.67041975",
"0.66202587",
"0.6614333",
"0.660913",
"0.65604466",
"0.6547719",
"0.6497466",
"0.6334189",
"0.62255627",
"0.6209014",
"0.6101226",
"0.60906714"... | 0.704376 | 4 |
Clear the screen of the terminal for the UI | def yPVe():
Hy7s.system('cls' if Hy7s.name == 'nt' else 'clear')
return | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def yPVe():\n Hy7s.system('clear')",
"def yPVe():\n Hy7s.system('clear')",
"def yPVe():\n Hy7s.system('cls')",
"def yPVe():\n print('\\x1b[H\\x1b[J')",
"def Y6_N(YKHO):\n Hy7s.system('cls')",
"def DWiR():\n Hy7s.system('clear')",
"def yPVe(YKHO):\n HwRy.stdout.write('\\x1b[2J')\n ... | [
"0.9002189",
"0.89394754",
"0.89025503",
"0.88646257",
"0.88462806",
"0.88388485",
"0.8837744",
"0.8814389",
"0.8811217",
"0.8804971",
"0.8785133",
"0.8727044",
"0.86909187",
"0.86909187",
"0.86909187",
"0.86909187",
"0.86891097",
"0.8650518",
"0.86500394",
"0.8642027",
"0.86... | 0.87186676 | 12 |