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 |
|---|---|---|---|---|---|---|
Retrieve a list of Activities. | def vdS6(YKHO, **B2fa) -> x1iM[nmsT]:
dCYV = []
for oxFy in YKHO._value:
rxHD = nmsT(client=YKHO._client, json=oxFy)
rxHD.refresh()
dCYV.append(rxHD)
return dCYV | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FnFi(YKHO):\n return YKHO._activities_list",
"def zn9O(YKHO):\n return YKHO._activities_list",
"def Byyz(YKHO):\n dCYV = YKHO.cur.execute('SELECT activity, time, date_added FROM Activities').fetchall()\n return dCYV",
"def nZ2i(YKHO):\n return LeZt.Activity.objects.all().order_by('name')",... | [
"0.77017677",
"0.76571566",
"0.7584255",
"0.74848115",
"0.73981696",
"0.737654",
"0.7187773",
"0.7068592",
"0.6919586",
"0.68897706",
"0.6862527",
"0.6734417",
"0.6717355",
"0.6682258",
"0.6563082",
"0.65551835",
"0.64516544",
"0.63997674",
"0.6300992",
"0.6296515",
"0.626855... | 0.6993219 | 8 |
Return a list of ScopeFilter objects currently configured on the property. | def a3iw(YKHO) -> x1iM[iOAp]:
return iOAp.parse_options(YKHO._options) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uC2a(YKHO):\n return YKHO._scopes",
"def uC2a(YKHO):\n if YKHO.__scopes is not None:\n return YKHO.__scopes\n return YKHO.__common_info.scopes",
"def HgZ9(YKHO):\n return [G1Hx for G1Hx, KCHu in jjoq.scope_choices() if G1Hx in YKHO.scopes]",
"def uC2a(YKHO):\n return YKHO.__scopes",... | [
"0.69128203",
"0.69096106",
"0.6863977",
"0.68410534",
"0.6813862",
"0.6805539",
"0.6805539",
"0.6779327",
"0.67763",
"0.6730845",
"0.6728594",
"0.6673124",
"0.66675913",
"0.6626623",
"0.6608332",
"0.6570499",
"0.65345436",
"0.6510257",
"0.6510257",
"0.6510257",
"0.6495875",
... | 0.7912792 | 0 |
Returns the value to which the specified key is mapped, or 1 if this map contains no mapping for the key | def NMoC(YKHO, H5ew: int) -> int:
oQ6W = YKHO.hashKey(H5ew)
for _pUq in YKHO.table[oQ6W]:
re3S, E3cm = _pUq
if H5ew == re3S:
return E3cm
return -1 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NMoC(YKHO, H5ew: int) -> int:\n if H5ew in YKHO.hashmap:\n return YKHO.hashmap[H5ew]\n else:\n return -1",
"def NMoC(YKHO, H5ew: int) -> int:\n return YKHO.hash_map.get(H5ew, -1)",
"def NMoC(YKHO, H5ew: int) -> int:\n or8S = YKHO.hashf(H5ew)\n DpUl = YKHO.map[or8S]\n while D... | [
"0.7848849",
"0.7574012",
"0.7532174",
"0.7470112",
"0.74620366",
"0.7428508",
"0.7401826",
"0.73957235",
"0.7342702",
"0.7308801",
"0.72534305",
"0.72431225",
"0.72268313",
"0.7183607",
"0.7170011",
"0.7141611",
"0.7087551",
"0.7038966",
"0.69596636",
"0.68357366",
"0.675836... | 0.7172246 | 14 |
Returns the value to which the specified key is mapped, or 1 if this map contains no mapping for the key | def NMoC(YKHO, H5ew: int) -> int:
oQ6W = H5ew % YKHO.tableSize
for _pUq in YKHO.table[oQ6W]:
re3S, yz6B = _pUq
if re3S == H5ew:
return yz6B
return -1 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NMoC(YKHO, H5ew: int) -> int:\n if H5ew in YKHO.hashmap:\n return YKHO.hashmap[H5ew]\n else:\n return -1",
"def NMoC(YKHO, H5ew: int) -> int:\n return YKHO.hash_map.get(H5ew, -1)",
"def NMoC(YKHO, H5ew: int) -> int:\n or8S = YKHO.hashf(H5ew)\n DpUl = YKHO.map[or8S]\n while D... | [
"0.7848849",
"0.7574012",
"0.7532174",
"0.7470112",
"0.74620366",
"0.7428508",
"0.7401826",
"0.73957235",
"0.7342702",
"0.7308801",
"0.72534305",
"0.72431225",
"0.72268313",
"0.7183607",
"0.7172246",
"0.7170011",
"0.7141611",
"0.7087551",
"0.7038966",
"0.68357366",
"0.6758367... | 0.69596636 | 19 |
Function takes elements from any list and converts them into integers Return list | def mXcU(e8q7):
exwG = 0
while exwG < len(e8q7):
e8q7[exwG] = int(e8q7[exwG])
exwG += 1
return e8q7 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gXtX(fUYa: Iterable) -> list[int]:\n return XqC_(int, fUYa)",
"def gXtX(fUYa: Iterable) -> list[int]:\n return XqC_(int, fUYa)",
"def ilAg(vC9B):\n return [K4Ei(KCHu) for KCHu in vC9B]",
"def GTL1(nwEZ):\n S06t = []\n for yv6U in nwEZ:\n S06t.append(kuFU(yv6U))\n return S06t",
... | [
"0.8147173",
"0.8147173",
"0.7944421",
"0.7827162",
"0.77981746",
"0.7786449",
"0.7721005",
"0.769339",
"0.76386744",
"0.76291776",
"0.7513039",
"0.7500027",
"0.74897456",
"0.7445398",
"0.7433728",
"0.7428307",
"0.73179823",
"0.72949743",
"0.72777146",
"0.71969247",
"0.717698... | 0.7689837 | 8 |
Tests that a search returns No Title for the reference. LitTrisum7 (16) broken 11/18/2021 | def SFTD(YKHO):
L03z = YKHO.form
L03z.enter_value('accids', 'J:43743')
L03z.click_search()
usGy = YKHO.driver.find_element(Q71O.ID, 'resultsTable')
tyNF = TQJD(usGy)
tn8e = tyNF.get_cell(1, 6)
YKHO.assertEqual(tn8e.text, 'Genetic Variants and Strains of the Laboratory Mouse') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Rupu(YKHO):\n pass",
"def C7tB(YKHO):\n ChVl = YKHO.driver.find_element_by_id('query')\n ChVl.send_keys('Nothing to be found')\n YKHO.driver.find_element_by_tag_name('button').click()\n ZTct = YKHO.driver.find_element_by_tag_name('h4').text\n YKHO.assertEqual('No books found for this search... | [
"0.720151",
"0.71435905",
"0.6761809",
"0.6755138",
"0.67310673",
"0.67290694",
"0.6713691",
"0.66604054",
"0.66267115",
"0.66089225",
"0.6606697",
"0.65190125",
"0.65018535",
"0.6495477",
"0.6490887",
"0.64900273",
"0.6475713",
"0.6464909",
"0.64535326",
"0.6424635",
"0.6416... | 0.74155146 | 0 |
Computes the precision for the specified values of k | def vjyh(hlel, pan_, hz5a=(1,)):
Gq8e = max(hz5a)
Ep8u = pan_.size(0)
bGrB, nvEb = hlel.topk(Gq8e, 1, True, True)
nvEb = nvEb.t()
gXXc = nvEb.eq(pan_.view(1, -1).expand_as(nvEb))
Ylbp = []
for G1Hx in hz5a:
R2Dg = gXXc[:G1Hx].view(-1).float().sum(0)
Ylbp.append(R2Dg.mul_(100.... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rhd_(u5Ef, G1Hx):\n return len(u5Ef) / G1Hx",
"def sEak(Mkmy, G1Hx):\n assert G1Hx >= 1\n Mkmy = oyIN.asarray(Mkmy)[:G1Hx]\n return oyIN.mean(Mkmy)",
"def sEak(YKHO, G1Hx):\n fdMZ = YKHO.pred_rankings.rdd.map(lambda SjLr: (SjLr[2], SjLr[1]))\n Wbxz = rRQi(fdMZ)\n return Wbxz.precisionA... | [
"0.8003211",
"0.79748034",
"0.79735845",
"0.7941222",
"0.78642285",
"0.7803938",
"0.7707779",
"0.7621563",
"0.7593218",
"0.75612706",
"0.752028",
"0.7430132",
"0.74122673",
"0.7375894",
"0.7374447",
"0.7321427",
"0.7254542",
"0.7236769",
"0.72279894",
"0.7204469",
"0.7137302"... | 0.0 | -1 |
Convenience wrapper to create Numpy arrays with a np.int32 dtype. | def dF6N(*qIxc, **B2fa):
return oyIN.array(*qIxc, dtype=oyIN.int32, **B2fa) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TBtm():\n return qw7D.array(str('i'))",
"def TBtm():\n return qw7D.array(str('i'))",
"def UIlU(YKHO, len=None) -> XTiz.array:\n if len is None:\n len = YKHO.readInt32()\n if YKHO._pos + len > YKHO._len:\n YKHO._replenish(len)\n he6J = XTiz.zeros((len,), dtype=XTiz.int32)\n f... | [
"0.70361704",
"0.70361704",
"0.6777619",
"0.6744585",
"0.64246356",
"0.63839966",
"0.62932396",
"0.6190391",
"0.6190391",
"0.6179937",
"0.6164075",
"0.6132975",
"0.60775787",
"0.60642684",
"0.6057039",
"0.6057039",
"0.6043114",
"0.60307384",
"0.6007878",
"0.5871993",
"0.57908... | 0.8116675 | 0 |
Convenience wrapper to create Numpy arrays with a np.int64 dtype. | def iwHC(*qIxc, **B2fa):
return oyIN.array(*qIxc, dtype=oyIN.int64, **B2fa) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TBtm():\n return qw7D.array(str('i'))",
"def TBtm():\n return qw7D.array(str('i'))",
"def bgHW(wEf2):\n return oyIN.int(wEf2)",
"def s7hy(ezWE: NumpyIndexT) -> hSuy:\n yDqo = ezWE.dtype\n if yDqo.kind == 'i' and yDqo != oyIN.int64:\n return ezWE.astype(oyIN.int64)\n elif yDqo.kin... | [
"0.70532185",
"0.70532185",
"0.66952807",
"0.65411156",
"0.64443105",
"0.6441103",
"0.62913424",
"0.6271179",
"0.6193027",
"0.6013543",
"0.59833395",
"0.58950716",
"0.58560294",
"0.58471435",
"0.5823796",
"0.5819441",
"0.57847875",
"0.57734317",
"0.5672512",
"0.5672512",
"0.5... | 0.7679253 | 0 |
Convenience wrapper to create Numpy arrays with a np.bool dtype. | def Yjcp(*qIxc, **B2fa):
return oyIN.array(*qIxc, dtype=bool, **B2fa) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eRwN(YKHO: Array, /) -> bool:\n if YKHO._array.ndim != 0:\n raise TypeError('bool is only allowed on arrays with 0 dimensions')\n Ylbp = YKHO._array.__bool__()\n return Ylbp",
"def m9YJ(YEnM):\n return isinstance(YEnM, XTiz.bool_)",
"def dJKc(YKHO, mWFP):\n return YKHO.m_bool_array[mW... | [
"0.7148544",
"0.67213887",
"0.6578051",
"0.6481483",
"0.63701624",
"0.6342584",
"0.6207697",
"0.61416197",
"0.61362237",
"0.6056622",
"0.60073805",
"0.600533",
"0.5920754",
"0.5915522",
"0.5912131",
"0.587332",
"0.58606154",
"0.58474207",
"0.5847196",
"0.5832303",
"0.5816498"... | 0.87148404 | 0 |
Return charge current request max. | def opgA(YKHO) -> int:
return YKHO._vehicle_data.get('charge_state', {}).get('charge_current_request_max') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wRBD(YKHO):\n return YKHO._chargeMax",
"def C1Bx(YKHO):\n return YKHO._next_max_charge",
"def IosJ(YKHO) -> int:\n return YKHO._vehicle_data.get('charge_state', {}).get('charge_current_request')",
"def PVzI(YKHO):\n return YKHO._next_max_discharge",
"def WSHr(YKHO) -> int:\n return YKHO.... | [
"0.8265315",
"0.7880474",
"0.7302206",
"0.727642",
"0.7133463",
"0.7055043",
"0.6983788",
"0.69473696",
"0.69162524",
"0.6874458",
"0.6841228",
"0.68331176",
"0.68228287",
"0.68190616",
"0.6730639",
"0.67255485",
"0.6694728",
"0.6674588",
"0.6674588",
"0.66587824",
"0.6649693... | 0.89949256 | 0 |
Return charge limit soc max. | def WSHr(YKHO) -> int:
return YKHO._vehicle_data.get('charge_state', {}).get('charge_limit_soc_max') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wRBD(YKHO):\n return YKHO._chargeMax",
"def C1Bx(YKHO):\n return YKHO._next_max_charge",
"def r5Sc(YKHO) -> int:\n return YKHO._vehicle_data.get('charge_state', {}).get('charge_limit_soc')",
"def opgA(YKHO) -> int:\n return YKHO._vehicle_data.get('charge_state', {}).get('charge_current_reques... | [
"0.83567405",
"0.78704774",
"0.7726977",
"0.7416552",
"0.7226042",
"0.7193395",
"0.71610624",
"0.71439356",
"0.7137278",
"0.7093408",
"0.70916945",
"0.704795",
"0.704795",
"0.70368254",
"0.7035283",
"0.70335853",
"0.70165646",
"0.6984544",
"0.6960442",
"0.69547886",
"0.695478... | 0.8593461 | 0 |
Return charge cable connection. | def pZAo(YKHO) -> str:
return YKHO._vehicle_data.get('charge_state', {}).get('conn_charge_cable') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def J0FT():\n from fw.cable_control import ChargingCable\n EqBn = ChargingCable()\n yield EqBn\n EqBn.connect()",
"def ndPi(YKHO):\n return YKHO._cable_car",
"def UzPC():\n return STt_()",
"def WJkG(YKHO):\n return YKHO._charge",
"def EJ08(YKHO):\n if not YKHO.connection:\n r... | [
"0.69364",
"0.681861",
"0.63535804",
"0.633391",
"0.62902516",
"0.62831205",
"0.6220554",
"0.61605126",
"0.6152143",
"0.61285114",
"0.60568595",
"0.6041572",
"0.6016972",
"0.6000699",
"0.5986896",
"0.59850365",
"0.59623915",
"0.5917658",
"0.59134305",
"0.59099025",
"0.5878993... | 0.80541587 | 0 |
Return car frunk is closed. Returns | def OT4G(YKHO) -> bool:
geh0 = YKHO._vehicle_data.get('vehicle_state', {}).get('ft')
return geh0 == 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SEEh(_0gM):\n return SpQe(_0gM) == _0gM",
"def jXkb(YKHO) -> bool:\n ...",
"def WRTf(YKHO):\n ...",
"def WRTf(YKHO):\n pass",
"def EBEL(YKHO):\n return YKHO.cdate != ''",
"def SEEh(YKHO):\n return YKHO.status == LTBJ",
"def SEEh(YKHO) -> bool | None:\n S0MI.info('Processing is_... | [
"0.75601476",
"0.72373915",
"0.7143693",
"0.6998579",
"0.6796452",
"0.6795287",
"0.67908883",
"0.67400855",
"0.6734656",
"0.6724836",
"0.6716118",
"0.6704979",
"0.6694178",
"0.66898596",
"0.6689261",
"0.666825",
"0.6666786",
"0.66458976",
"0.6643997",
"0.66282785",
"0.6628278... | 0.7680974 | 0 |
Return car trunk is closed. Returns | def hygx(YKHO) -> bool:
geh0 = YKHO._vehicle_data.get('vehicle_state', {}).get('rt')
return geh0 == 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def jXkb(YKHO) -> bool:\n ...",
"def SEEh(YKHO):\n raise NotImplementedError",
"def WRTf(YKHO):\n ...",
"def WRTf(YKHO):\n pass",
"def SEEh(YKHO):\n return None",
"def OT4G(YKHO) -> bool:\n geh0 = YKHO._vehicle_data.get('vehicle_state', {}).get('ft')\n return geh0 == 0",
"def SEEh(... | [
"0.7106831",
"0.70981574",
"0.7090858",
"0.70483345",
"0.7026049",
"0.7022465",
"0.70005953",
"0.69883764",
"0.6966724",
"0.6894767",
"0.6892569",
"0.6892469",
"0.68443656",
"0.6842041",
"0.6842041",
"0.6835711",
"0.68215114",
"0.68116623",
"0.6798529",
"0.6798529",
"0.678955... | 0.7397743 | 0 |
Return if car has rear (second row) heated seats. Returns | def TDDT(YKHO) -> int:
return YKHO._car.get('vehicle_config', {}).get('rear_seat_heaters') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bW16(q36t, rdlD, fvDH):\n ihVD = False\n YRbF = 0\n while True:\n YRbF += 1\n if fvDH + YRbF >= q36t.shape[1]:\n break\n if q36t[rdlD, fvDH + YRbF] != AtY1:\n ihVD = q36t[rdlD, fvDH + YRbF] == kmoU\n break\n return ihVD",
"def x0DU(q36t, rdlD,... | [
"0.60563946",
"0.59846395",
"0.59700096",
"0.59663564",
"0.59536934",
"0.58651555",
"0.5846973",
"0.577147",
"0.5765963",
"0.5753232",
"0.57381016",
"0.5723048",
"0.5717724",
"0.5682057",
"0.5656583",
"0.56529856",
"0.55997354",
"0.55990434",
"0.5581458",
"0.5564735",
"0.5542... | 0.63325304 | 0 |
Return tire pressure sensor for front left tire. | def PuiI(YKHO) -> float:
return YKHO._vehicle_data.get('vehicle_state', {}).get('tpms_pressure_fl') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Snjs(nPrm):\n return round(nPrm['status']['tirePressure']['frontLeftTirePressurePsi'])",
"def kIVY(nPrm):\n return round(nPrm['status']['tirePressure']['rearLeftTirePressurePsi'])",
"def k4o0(nPrm):\n return round(nPrm['status']['tirePressure']['frontRightTirePressurePsi'])",
"def CJ2p(R8g3):\n ... | [
"0.7851046",
"0.7509724",
"0.7351179",
"0.6871374",
"0.6752997",
"0.6682612",
"0.66106725",
"0.65546095",
"0.654701",
"0.6544125",
"0.653287",
"0.64858294",
"0.6384681",
"0.6372746",
"0.6308545",
"0.6306044",
"0.6194587",
"0.6180239",
"0.6180239",
"0.6180239",
"0.6180239",
... | 0.5635205 | 69 |
Return tire pressure sensor for front right tire. | def fFmM(YKHO) -> float:
return YKHO._vehicle_data.get('vehicle_state', {}).get('tpms_pressure_fr') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def k4o0(nPrm):\n return round(nPrm['status']['tirePressure']['frontRightTirePressurePsi'])",
"def Snjs(nPrm):\n return round(nPrm['status']['tirePressure']['frontLeftTirePressurePsi'])",
"def CJ2p(R8g3):\n return z1KK.press * R8g3",
"def kIVY(nPrm):\n return round(nPrm['status']['tirePressure'][... | [
"0.7672259",
"0.7425541",
"0.72695833",
"0.71726084",
"0.71627504",
"0.70999056",
"0.68055123",
"0.67780364",
"0.67448884",
"0.6714898",
"0.66579336",
"0.6633783",
"0.65279967",
"0.65168226",
"0.6462362",
"0.645688",
"0.6425457",
"0.6386967",
"0.6386967",
"0.6386967",
"0.6386... | 0.58455575 | 66 |
Return tire pressure sensor for rear left tire. | def za0K(YKHO) -> float:
return YKHO._vehicle_data.get('vehicle_state', {}).get('tpms_pressure_rl') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kIVY(nPrm):\n return round(nPrm['status']['tirePressure']['rearLeftTirePressurePsi'])",
"def v4_l(nPrm):\n return round(nPrm['status']['tirePressure']['rearRightTirePressurePsi'])",
"def CJ2p(R8g3):\n return z1KK.press * R8g3",
"def Snjs(nPrm):\n return round(nPrm['status']['tirePressure']['f... | [
"0.78897464",
"0.732964",
"0.7217211",
"0.7203469",
"0.6998029",
"0.6626931",
"0.66000533",
"0.65602463",
"0.646634",
"0.6380087",
"0.63749754",
"0.63588727",
"0.6337177",
"0.63237333",
"0.630103",
"0.62655896",
"0.62655896",
"0.62655896",
"0.62655896",
"0.62085634",
"0.62003... | 0.6621557 | 6 |
Return tire pressure sensor for rear right tire. | def F8GL(YKHO) -> float:
return YKHO._vehicle_data.get('vehicle_state', {}).get('tpms_pressure_rr') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def v4_l(nPrm):\n return round(nPrm['status']['tirePressure']['rearRightTirePressurePsi'])",
"def CJ2p(R8g3):\n return z1KK.press * R8g3",
"def kIVY(nPrm):\n return round(nPrm['status']['tirePressure']['rearLeftTirePressurePsi'])",
"def k4o0(nPrm):\n return round(nPrm['status']['tirePressure']['f... | [
"0.7916733",
"0.7530138",
"0.74616104",
"0.7431977",
"0.6876582",
"0.6734581",
"0.66998965",
"0.66690975",
"0.66369534",
"0.6626809",
"0.6587884",
"0.6587741",
"0.6561849",
"0.6510437",
"0.6480685",
"0.64765704",
"0.64565235",
"0.6432967",
"0.6416508",
"0.63972175",
"0.638042... | 0.6654703 | 8 |
Return active route latitude. | def BHOO(YKHO) -> h8nf[int]:
if 'active_route_energy_at_arrival' in YKHO._vehicle_data.get('drive_state', {}):
return YKHO._vehicle_data.get('drive_state', {}).get('active_route_energy_at_arrival')
return None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def faBV(YKHO) -> h8nf[float]:\n if 'active_route_latitude' in YKHO._vehicle_data.get('drive_state', {}):\n return YKHO._vehicle_data.get('drive_state', {}).get('active_route_latitude')\n return None",
"def _UuI(YKHO):\n return YKHO._vehicle.location.get('latitude')",
"def _UuI(YKHO):\n retu... | [
"0.84672266",
"0.7330489",
"0.72300136",
"0.7194163",
"0.7190799",
"0.718705",
"0.71488196",
"0.7147087",
"0.7070363",
"0.6995495",
"0.6995495",
"0.6995495",
"0.6995495",
"0.69921637",
"0.6983399",
"0.69827926",
"0.6977776",
"0.6976181",
"0.69298553",
"0.69277567",
"0.6926617... | 0.0 | -1 |
Return active route latitude. | def faBV(YKHO) -> h8nf[float]:
if 'active_route_latitude' in YKHO._vehicle_data.get('drive_state', {}):
return YKHO._vehicle_data.get('drive_state', {}).get('active_route_latitude')
return None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _UuI(YKHO):\n return YKHO._vehicle.location.get('latitude')",
"def _UuI(YKHO):\n return YKHO._gps.latitude",
"def TujQ(YKHO):\n return YKHO.latitude",
"def vdjT(YKHO) -> AzJI[h8nf[float], h8nf[float]]:\n QnmL = None\n Swre = None\n if YKHO.active_route_longitude and YKHO.active_route_la... | [
"0.7326578",
"0.72252256",
"0.71888465",
"0.7187339",
"0.7186757",
"0.7145012",
"0.7142562",
"0.7065638",
"0.69915",
"0.69915",
"0.69915",
"0.69915",
"0.6986382",
"0.69791514",
"0.69781804",
"0.6973735",
"0.69720876",
"0.6924306",
"0.69221395",
"0.69221383",
"0.69177765",
"... | 0.84677047 | 0 |
Return active route longitude. | def TO13(YKHO) -> h8nf[float]:
if 'active_route_longitude' in YKHO._vehicle_data.get('drive_state', {}):
return YKHO._vehicle_data.get('drive_state', {}).get('active_route_longitude')
return None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fopC(YKHO):\n return YKHO._vehicle.location.get('longitude')",
"def vdjT(YKHO) -> AzJI[h8nf[float], h8nf[float]]:\n QnmL = None\n Swre = None\n if YKHO.active_route_longitude and YKHO.active_route_latitude:\n QnmL = YKHO.active_route_latitude\n Swre = YKHO.active_route_longitude\n ... | [
"0.77292836",
"0.7636826",
"0.7635775",
"0.75625485",
"0.755764",
"0.7476066",
"0.745687",
"0.73974323",
"0.73953646",
"0.7394849",
"0.73931247",
"0.73931247",
"0.73931247",
"0.73859406",
"0.73830456",
"0.7371528",
"0.7347309",
"0.73202604",
"0.73084927",
"0.72871345",
"0.727... | 0.84566826 | 0 |
Return active route latitude. | def a4rc(YKHO) -> h8nf[float]:
if 'active_route_miles_to_arrival' in YKHO._vehicle_data.get('drive_state', {}):
return YKHO._vehicle_data.get('drive_state', {}).get('active_route_miles_to_arrival')
return None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def faBV(YKHO) -> h8nf[float]:\n if 'active_route_latitude' in YKHO._vehicle_data.get('drive_state', {}):\n return YKHO._vehicle_data.get('drive_state', {}).get('active_route_latitude')\n return None",
"def _UuI(YKHO):\n return YKHO._vehicle.location.get('latitude')",
"def _UuI(YKHO):\n retu... | [
"0.84672266",
"0.7330489",
"0.72300136",
"0.7194163",
"0.7190799",
"0.718705",
"0.71488196",
"0.7147087",
"0.7070363",
"0.6995495",
"0.6995495",
"0.6995495",
"0.6995495",
"0.69921637",
"0.6983399",
"0.69827926",
"0.6977776",
"0.6976181",
"0.69298553",
"0.69277567",
"0.6926617... | 0.6052887 | 72 |
Return if peak charging is enabled for scheduled departure. | def rrAS(YKHO) -> bool:
return YKHO._vehicle_data.get('charge_state', {}).get('off_peak_charging_enabled') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def y1aZ(YKHO) -> bool:\n return YKHO.current_charging_amperage_limit > 0",
"def xVsP(YKHO) -> bool:\n return Diuw.get(YKHO._vehicle_data.get('charge_state', {}).get('off_peak_charging_times'))",
"def b4tL(YKHO) -> bool:\n return YKHO._vehicle_data.get('charge_state', {}).get('scheduled_charging_pendi... | [
"0.708074",
"0.6780938",
"0.65170974",
"0.641044",
"0.641044",
"0.641044",
"0.63970387",
"0.6291543",
"0.6159331",
"0.6118228",
"0.60477936",
"0.60024244",
"0.5996569",
"0.59783447",
"0.59763503",
"0.59653765",
"0.5959171",
"0.5934472",
"0.5925335",
"0.5912325",
"0.5900049",
... | 0.71706676 | 0 |
Return end of off peak hours in minutes after midnight for scheduled departure. | def VeJV(YKHO) -> int:
return YKHO._vehicle_data.get('charge_state', {}).get('off_peak_hours_end_time') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dxaC(YKHO):\n return YKHO.guess_starttime() + F_6O",
"def d1bR(YKHO) -> h8nf['outputs.TimeResponse']:\n return qe4Y.get(YKHO, 'off_peak_start_time')",
"def AId9(YKHO) -> h8nf[int]:\n return qe4Y.get(YKHO, 'off_peak_minutes_to_wait_on_disconnect')",
"def _nCm(YKHO) -> qcWV:\n return YKHO.peak_... | [
"0.6807021",
"0.6537455",
"0.6411115",
"0.63873243",
"0.6347011",
"0.63416547",
"0.6292027",
"0.6265805",
"0.6223648",
"0.6166319",
"0.6111502",
"0.59987223",
"0.5913747",
"0.5873868",
"0.58576226",
"0.58295894",
"0.58210146",
"0.5813199",
"0.58117366",
"0.58072555",
"0.58072... | 0.76121074 | 0 |
Return if preconditioning is enabled for scheduled departure. | def GWRK(YKHO) -> bool:
return YKHO._vehicle_data.get('charge_state', {}).get('preconditioning_enabled') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zEKy(YKHO) -> bool:\n return Diuw.get(YKHO._vehicle_data.get('charge_state', {}).get('preconditioning_times'))",
"def uZIp(YKHO):\n return YKHO._acquiring_event.is_set()",
"def wezY(YKHO) -> bool:\n return qe4Y.get(YKHO, 'preemptible')",
"def R7n8(YKHO):\n return True if YKHO._timePlan else F... | [
"0.7093109",
"0.64206886",
"0.6330044",
"0.6321499",
"0.6220149",
"0.6198343",
"0.6193938",
"0.61291647",
"0.61257637",
"0.61257637",
"0.61257637",
"0.61091536",
"0.60865116",
"0.60771453",
"0.60574615",
"0.60564977",
"0.6052917",
"0.6052917",
"0.6052917",
"0.6003182",
"0.600... | 0.7549049 | 0 |
Return 'Off', 'DepartBy', or 'StartAt' for schedule disabled, scheduled departure, and scheduled charging respectively. | def HBpJ(YKHO) -> str:
return YKHO._vehicle_data.get('charge_state', {}).get('scheduled_charging_mode') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lr3r(YKHO):\n return YKHO._schedule_status",
"def zwpN(YKHO):\n return YKHO._schedule_type",
"def zwpN(YKHO):\n return YKHO._schedule_type",
"def VP89(YKHO, b6Gq):\n l5Ny = ''\n if b6Gq.type & 1:\n l5Ny = 'Every Day'\n elif b6Gq.type & 2:\n if b6Gq.week != 0:\n ... | [
"0.59360963",
"0.5894676",
"0.5894676",
"0.58518213",
"0.57412803",
"0.5703972",
"0.5543835",
"0.5525707",
"0.54763967",
"0.545802",
"0.54405385",
"0.5427057",
"0.53815347",
"0.52431035",
"0.5241397",
"0.5241397",
"0.5210138",
"0.5207873",
"0.5203556",
"0.5203556",
"0.5188963... | 0.637709 | 0 |
Return if scheduled charging is pending. | def b4tL(YKHO) -> bool:
return YKHO._vehicle_data.get('charge_state', {}).get('scheduled_charging_pending') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wF5u(YKHO):\n return YKHO.status == YKHO.STATUS_PENDING",
"def HBpJ(YKHO) -> str:\n return YKHO._vehicle_data.get('charge_state', {}).get('scheduled_charging_mode')",
"def wF5u(YKHO):\n return YKHO._state in ['queued', 'starting']",
"def wF5u(YKHO):\n return YKHO._tag == 'pending'",
"def ug... | [
"0.7025192",
"0.6979803",
"0.68248636",
"0.6815304",
"0.6785223",
"0.6722301",
"0.667176",
"0.6671171",
"0.663343",
"0.66157484",
"0.65898424",
"0.6480804",
"0.6474299",
"0.64404196",
"0.64139783",
"0.64014983",
"0.64014983",
"0.64014983",
"0.63947135",
"0.6387003",
"0.635517... | 0.8730341 | 0 |
Return the scheduled charging start time. | def DjPW(YKHO) -> int:
return YKHO._vehicle_data.get('charge_state', {}).get('scheduled_charging_start_time_app') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def jSV8(YKHO):\n return YKHO.global_start_time",
"def jSV8(YKHO):\n return YKHO._clock.start",
"def jSV8(YKHO):\n return YKHO._clock.start",
"def SWox(YKHO) -> qcWV:\n return YKHO.timer_start_time",
"def jSV8(YKHO):\n return YKHO.start",
"def jSV8(YKHO):\n return YKHO.start_time",
"d... | [
"0.7544567",
"0.75042564",
"0.75042564",
"0.7471276",
"0.7380906",
"0.7372428",
"0.737131",
"0.733078",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"0.7280889",
"... | 0.7647348 | 0 |
Get current latitude and longitude. | def dnxa(YKHO) -> AzJI[h8nf[float], h8nf[float]]:
QnmL = None
Swre = None
if YKHO.native_location_supported:
Swre = YKHO.native_longitude
QnmL = YKHO.native_latitude
else:
Swre = YKHO.longitude
QnmL = YKHO.latitude
return (QnmL, Swre) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hbd3(YKHO):\n if YKHO.ip_address is not None:\n return YKHO.gis.lat_lon(YKHO.ip_address)",
"def VylB(YKHO):\n return (YKHO._fix.latitude, YKHO._fix.longitude)",
"def TujQ(YKHO):\n return YKHO._lat",
"def m9co(YKHO):\n return YKHO.latitude",
"def Iuzb(YKHO):\n return (YKHO.lon, YKH... | [
"0.7667713",
"0.76624286",
"0.76071614",
"0.75357276",
"0.74895525",
"0.7453614",
"0.73935634",
"0.7325741",
"0.7280753",
"0.7277879",
"0.7263254",
"0.72443485",
"0.7237673",
"0.7233354",
"0.7233354",
"0.71821386",
"0.7172584",
"0.7152134",
"0.7149677",
"0.71454054",
"0.71197... | 0.7183758 | 15 |
Send command to open charge port door. | async def charge_port_door_open(YKHO) -> None:
nPrm = await YKHO._send_command('CHARGE_PORT_DOOR_OPEN')
if nPrm and nPrm['response']['result'] is True:
NArs = {'charge_port_door_open': True}
YKHO._vehicle_data['charge_state'].update(NArs) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Zfno(YKHO, oUZx):\n YKHO.serial.write(YKHO._cr_lf(oUZx))",
"def Vy1e(YKHO):\n begE = PbGh(mac_address=YKHO.mac_address, manager=YKHO.manager)\n try:\n begE.connect()\n if begE.is_connected():\n begE.services_resolved()\n begE.write_characteristic(YKHO.door_charact... | [
"0.6390048",
"0.62967646",
"0.625568",
"0.62514395",
"0.6237082",
"0.6214847",
"0.61614466",
"0.60484326",
"0.6038006",
"0.60307",
"0.60261935",
"0.6022651",
"0.60168713",
"0.5921378",
"0.5916887",
"0.5909863",
"0.59080607",
"0.5894665",
"0.5890133",
"0.58759576",
"0.58754766... | 0.7383204 | 0 |
Function log_to_linear converts a logarithmic derivative to a linear derivative. | def kxB9(aaLs, azkn, leFL, P8oC=None):
if P8oC is None:
return EjJO * oyIN.exp(azkn - aaLs)
else:
return EjJO * P8oC ** (azkn - aaLs) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kxB9(sCcT):\n HiTP = oyIN.exp((sCcT - 1.0) * 5.70378)\n yCJi = HiTP * 1000.0\n return yCJi",
"def QHou(aaLs, leFL, P8oC=None):\n if P8oC is None:\n return leFL / oyIN.exp(aaLs)\n else:\n return leFL / (P8oC ** aaLs * epAf.log(P8oC))",
"def u7Cg(WKvO, LVAh):\n ijbV = oyIN.log... | [
"0.7498668",
"0.7456726",
"0.7438957",
"0.73801076",
"0.6983239",
"0.6795242",
"0.6694871",
"0.6591605",
"0.6559263",
"0.6495811",
"0.6383959",
"0.63751596",
"0.6336693",
"0.632973",
"0.63136595",
"0.61562234",
"0.6145453",
"0.61320823",
"0.6117486",
"0.6051435",
"0.60410887"... | 0.7867519 | 0 |
Initialise the pytorch LSTM layer. | def FIMM(YKHO, C9YJ, PZrB, JOnb, LHth, pYXf, wjbX, a6Jb, Lul6, JuDp, kWW_, vVUO, GGee, Crdv, tsWk, Gzv5, begE):
super().__init__()
YKHO.device = begE
YKHO.non_seq_emb_layers = U78l.ModuleList([U78l.Embedding(WKvO, LVAh) for WKvO, LVAh in C9YJ])
YKHO.seq_emb_layers = U78l.ModuleList([U78l.Embedding(WKvO,... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, KTQ3, wjbX):\n super().__init__()\n YKHO.embeddings = KTQ3\n YKHO.lstm = U78l.LSTM(input_size=wjbX, hidden_size=wjbX, num_layers=1, batch_first=True)",
"def FIMM(YKHO, KTQ3, wjbX):\n super().__init__()\n YKHO.embeddings = KTQ3\n YKHO.lstm = U78l.LSTM(input_size=wjbX, hidden_size=... | [
"0.77287084",
"0.7722154",
"0.76400554",
"0.7600388",
"0.7504953",
"0.73760414",
"0.73754585",
"0.7364214",
"0.7357796",
"0.73571545",
"0.7347382",
"0.7314215",
"0.72907436",
"0.7289766",
"0.7282379",
"0.72783715",
"0.7266365",
"0.72627467",
"0.72605",
"0.7259786",
"0.724642"... | 0.0 | -1 |
Generate slices to select groups of the given sizes within a list/matrix | def SuPp(moMn):
YRbF = 0
for uOe2 in moMn:
yield (YRbF, YRbF + uOe2)
YRbF += uOe2 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Qrt_(DumB, wXl7):\n YRbF = 0\n for uOe2 in wXl7:\n yield DumB[YRbF:YRbF + uOe2]\n YRbF += uOe2",
"def Yl3E(yv6U, zNig):\n TKeT = []\n for YRbF in range(0, len(yv6U), zNig):\n TKeT.append(yv6U[YRbF:YRbF + zNig])\n return TKeT",
"def hCgc(YIPF, Ya2q, _LFN, mZyh=l1bY):\n ... | [
"0.70901406",
"0.6802396",
"0.67626804",
"0.6724413",
"0.66997015",
"0.66854566",
"0.66469",
"0.65981853",
"0.6537837",
"0.6441593",
"0.6396058",
"0.6365191",
"0.6344155",
"0.6335367",
"0.6332432",
"0.6328311",
"0.63092",
"0.630687",
"0.6302877",
"0.62964624",
"0.62242657",
... | 0.68362904 | 1 |
Write a function that reverses a string. The input string is given as an array of characters s. Do not return anything, modify s inplace instead. | def Zke2(KCHu: List[str]) -> None:
ZOdY = len(KCHu)
KCHu[:ZOdY:1] = KCHu[ZOdY::-1] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Zke2(YKHO, KCHu: List[str]) -> None:\n tm40 = len(KCHu) - 1\n YRbF = 0\n while YRbF < tm40:\n Z9rn = KCHu[YRbF]\n KCHu[YRbF] = KCHu[tm40]\n KCHu[tm40] = Z9rn\n YRbF = YRbF + 1\n tm40 = tm40 - 1\n return",
"def gxEw(KCHu):\n o5Dc = ''\n for Npgh in KCHu:\n ... | [
"0.80854756",
"0.7967835",
"0.7946924",
"0.79432875",
"0.7925467",
"0.7925467",
"0.7893422",
"0.7851922",
"0.783379",
"0.7833136",
"0.7805377",
"0.77425534",
"0.77372104",
"0.77107257",
"0.76954526",
"0.76938146",
"0.7669585",
"0.7664524",
"0.7660909",
"0.7659171",
"0.7658913... | 0.7470191 | 48 |
Load a model from file | def jPIX(SkYi):
eHNT = open(SkYi).readlines()
C3ST = []
for WKvO in eHNT:
if WKvO.strip() == '' or WKvO.startswith('#'):
continue
WKvO = WKvO.strip()
Bh4N, DsKD = WKvO.split(':', 1)
ygLf, tO2L, MZio = Bh4N.split(' ', 2)
j3sY, jW55, llaI = DsKD.split(' ', 2... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uyMl(Ux0P):\n pass",
"def uyMl(Ux0P):\n raise NotImplementedError()",
"def uyMl(Ux0P: str):\n return tyeH(Ux0P)",
"def uyMl(ytgA: str):\n raise NotImplementedError",
"def uyMl(YKHO, WJHQ):\n raise NotImplementedError",
"def uyMl(YKHO, gIsw):\n raise NotImplementedError",
"def tyeH... | [
"0.90093666",
"0.87906426",
"0.868857",
"0.861218",
"0.86027074",
"0.8545427",
"0.85316163",
"0.84897023",
"0.84010994",
"0.84007406",
"0.84007406",
"0.84007406",
"0.83040154",
"0.8303529",
"0.8299032",
"0.827979",
"0.82186764",
"0.819761",
"0.81872016",
"0.8173998",
"0.81510... | 0.0 | -1 |
Ensure a valid IOB sequence. | def gzLj(TZ9E, XVAW):
if TZ9E in jr1U:
TZ9E = jr1U[0]
else:
TZ9E, UXqs = (TZ9E[0], TZ9E[1:])
if TZ9E in p1BZ or XVAW in jr1U or XVAW[1:] != UXqs:
TZ9E = p1BZ[0]
else:
TZ9E = Pujn[0]
TZ9E += UXqs
return TZ9E | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nVcQ(YKHO):\n assert all((WKvO in type(YKHO).valid_tokens for WKvO in YKHO.sequence)), '%s is not a valid sequence(%s)' % (YKHO.sequence, type(YKHO).valid_tokens)",
"def ubTl(YKHO):\n for Z9rn in YKHO.Cseq:\n if Z9rn not in 'ACGURYSWKMBDHVNacgu':\n YKHO.error = 'Used Cseq -> %s <- is ... | [
"0.66042835",
"0.6593798",
"0.64772475",
"0.64281994",
"0.63045675",
"0.62682414",
"0.6239059",
"0.60122466",
"0.5985162",
"0.59795505",
"0.5938942",
"0.5912963",
"0.58881205",
"0.58121395",
"0.58006626",
"0.57904285",
"0.57761425",
"0.57402384",
"0.57323116",
"0.5722136",
"0... | 0.0 | -1 |
Evaluate the score of the current state of board. This is used by the AI to evaluate the moves. The White player will try to maximise this score and the Black player will minimise this. | def SviG(YKHO):
p1kx = YKHO.whiteCount - YKHO.blackCount + (YKHO.whiteKings - YKHO.blackKings) * 0.5
return p1kx | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def b7La(YKHO):\n YimI = YKHO.board_state.game_state()\n if YimI == c7is.GameState.CHECKMATE:\n return -99999 if YKHO.board_state.white_to_move else 99999\n elif YimI == c7is.GameState.STALEMATE or YimI == c7is.GameState.INSUFFICIENT_MATERIAL:\n return 0\n else:\n E9cM = YKHO.board... | [
"0.78034383",
"0.77279395",
"0.7600502",
"0.73077834",
"0.73072577",
"0.7281911",
"0.7277922",
"0.723112",
"0.72103006",
"0.7184541",
"0.71760356",
"0.71541095",
"0.70770687",
"0.7039415",
"0.70366526",
"0.7036637",
"0.70247227",
"0.70046043",
"0.69657964",
"0.6963169",
"0.69... | 0.686294 | 34 |
Displays a profile page with the requested user | def NMoC(YKHO, NtEF):
return TvZl('auth/profile.html', user=mv1M.get_by_username(NtEF)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QyAW():\n return TvZl('user_profile_page.html')",
"def YxIp():\n CBIr = mv1M.query.get_or_404(Oa1e.user.id)\n return TvZl('/user/profile.html', user=CBIr)",
"def SGll():\n return TvZl('user_profile_page.html')",
"def inpR(qv1X, BaHi):\n _DWX = Iofl(mv1M, username=BaHi)\n BFpK.get_profil... | [
"0.87766784",
"0.8596274",
"0.8493086",
"0.84919167",
"0.8406736",
"0.83165485",
"0.83062613",
"0.8281549",
"0.8266483",
"0.8224784",
"0.8209223",
"0.81350076",
"0.81221724",
"0.81100297",
"0.81070876",
"0.8068704",
"0.80394495",
"0.8021067",
"0.7998451",
"0.7990145",
"0.7982... | 0.771836 | 51 |
Return label for given model/field from cts_forms app If no field exists, we expect it's a filter field like `create_date_end', strip underscores for display | def QtqY(BWXx, d7pR):
try:
C3ST = XLL2.get_model('cts_forms', BWXx)
Jyyj = C3ST._meta.get_field(d7pR)
except Q9cx:
return hOcI.get(d7pR, d7pR.replace('_', ' '))
return hOcI.get(Jyyj.name, Jyyj.verbose_name) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DeTJ(QpfX, Jyyj, YEnM=None):\n tTee = QpfX['view']\n return tTee.lookup_field_label(QpfX, Jyyj, YEnM)",
"def DeTJ(QpfX, Jyyj, YEnM=None):\n tTee = QpfX['view']\n return tTee.lookup_field_label(QpfX, Jyyj, YEnM)",
"def UXqs(Jyyj):\n if 'long_name' in Jyyj.attrs:\n return Jyyj.long_name... | [
"0.7463746",
"0.742785",
"0.6847667",
"0.6800901",
"0.6774244",
"0.6707949",
"0.6693763",
"0.64879066",
"0.64326656",
"0.63911146",
"0.6374436",
"0.63633955",
"0.6347035",
"0.63326454",
"0.6314945",
"0.63070166",
"0.6305372",
"0.6305372",
"0.62764704",
"0.624784",
"0.6241707"... | 0.75636333 | 0 |
Write the current image as a PNG to the path `pth`. | def DKkL(YKHO, SXRB):
LNo8 = YKHO.bitmap.ConvertToImage()
Xn71 = hnIv.new('RGB', (LNo8.GetWidth(), LNo8.GetHeight()))
Xn71.frombytes(bytes(LNo8.GetData()))
YKHO.compute.write_image(Xn71, SXRB) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def C2IV(SXRB, qw7D):\n hnIv.fromarray(qw7D).save(SXRB)",
"def KfPp(pmON, LNo8):\n hiw8.imwrite(pmON, LNo8)",
"def KfPp(LNo8, pmON):\n MVjK.WriteImage(LNo8, pmON)",
"def WJhd(QrM1, AGPF):\n Hy7s.makedirs('./img', exist_ok=True)\n QrM1.savefig(f'./img/filetype_freq_table_{AGPF}.png')",
"def F... | [
"0.6621028",
"0.6531019",
"0.6335116",
"0.6253184",
"0.6182631",
"0.6176999",
"0.61110127",
"0.60992664",
"0.60787255",
"0.6077451",
"0.6051178",
"0.6037803",
"0.60326505",
"0.6012975",
"0.60109895",
"0.59950626",
"0.5993095",
"0.59919316",
"0.59681004",
"0.596244",
"0.595210... | 0.74797714 | 0 |
Check if field (as string) is matching any of the patterns in the list. | def H1Hr(Emd4, Jyyj, b6H_):
if b6H_ is True:
return True
for XP5J in b6H_:
if ZbWC.search(XP5J, QMSQ(Jyyj), flags=ZbWC.IGNORECASE):
return True
return False | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def UV7r(AIu6, b6H_):\n return any(map(lambda WKvO: WKvO.search(AIu6), b6H_))",
"def hHld(vGaq, b6H_):\n for mXDZ in b6H_:\n if vGaq.matches(mXDZ):\n return True\n return False",
"def zrFY(pmON, xBfL):\n return any((jlVJ.fnmatchcase(pmON, mXDZ) for mXDZ in xBfL))",
"def hHld(vIw... | [
"0.7455437",
"0.68592167",
"0.68173975",
"0.6751715",
"0.67027324",
"0.6638934",
"0.6603253",
"0.6597179",
"0.6543751",
"0.65137506",
"0.6464359",
"0.6415074",
"0.6414931",
"0.6378612",
"0.6377003",
"0.6371236",
"0.63526356",
"0.63243484",
"0.63214326",
"0.63136417",
"0.63006... | 0.7742495 | 0 |
Empties all pending items in a queue and returns them in a list. | def wUZB(gGq6):
Aofo = []
gGq6.put('STOP')
for YRbF in iter(gGq6.get, 'STOP'):
Aofo.append(YRbF)
return Aofo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lJu4(YKHO):\n return list(YKHO.queue)",
"def VwEg(vexM):\n U5bT = []\n while True:\n try:\n U5bT.append(vexM.get_nowait())\n except gGq6.Empty:\n break\n return U5bT",
"def Frt_(YKHO):\n return YKHO.redis_queue.flushall()",
"def cRcL(gGq6):\n if gGq6:... | [
"0.72378343",
"0.71170026",
"0.7112144",
"0.70692366",
"0.7063911",
"0.70329916",
"0.7007242",
"0.69768465",
"0.6941544",
"0.6933764",
"0.6933764",
"0.68728507",
"0.6865059",
"0.6839765",
"0.6829676",
"0.6822016",
"0.6794951",
"0.6783053",
"0.6745695",
"0.67417413",
"0.673771... | 0.6160498 | 66 |
Remove characters from names that IDA doesn't like | def DhAv(mWFP):
mWFP = mWFP.replace('!', '_')
mWFP = mWFP.replace('@', '_')
return mWFP | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BPZN(mWFP):\n return ''.join((Z9rn for Z9rn in mWFP.lower() if Z9rn in vIwR.ascii_lowercase))",
"def NkkI(mWFP):\n return ZbWC.sub('[^a-z0-9]', '', mWFP.lower())",
"def mPaR(mWFP):\n KXjL = Z8gi\n mWFP = mWFP.lower().replace(' ', '_')\n return filter(lambda hcXw: hcXw in KXjL, mWFP)",
"def... | [
"0.7944727",
"0.7605746",
"0.76004255",
"0.7582826",
"0.7551867",
"0.7536801",
"0.75148433",
"0.74827474",
"0.74804044",
"0.7477848",
"0.74757206",
"0.74486125",
"0.73925656",
"0.73795635",
"0.73732764",
"0.73686904",
"0.736413",
"0.73301864",
"0.73293644",
"0.73267657",
"0.7... | 0.7331012 | 17 |
Initial starting point for Beta, uses size of image to set limits, initial beta is set to the min beta | def M0wc(Xn71, oXaw=0.25, JyfR=5):
JMvN = max(Xn71.shape[0] / (JyfR + 1.0) ** 0.5, Xn71.shape[1] / (JyfR + 1.0) ** 0.5)
elmQ = min(oXaw * (JyfR + 1.0) ** 0.5, JMvN)
return [elmQ, elmQ] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def qp7v(YKHO):\n YKHO.beta = YKHO.beta_scale * 2 * oyIN.log(YKHO.ndim * YKHO.number_design_points * oyIN.square(oyIN.pi) * oyIN.square(YKHO.iteration + 1) / (6 * YKHO.delta))",
"def vHuH(YKHO):\n YKHO.epsilon = max(YKHO.min_epsilon, YKHO.epsilon - (YKHO.max_epsilon - YKHO.min_epsilon) * YKHO.epsilon_decay... | [
"0.691234",
"0.6687982",
"0.64398587",
"0.643445",
"0.64136606",
"0.6352139",
"0.6318139",
"0.6297229",
"0.6240619",
"0.6217378",
"0.61705744",
"0.60920113",
"0.60807467",
"0.60793215",
"0.607148",
"0.60687506",
"0.6066726",
"0.6041783",
"0.60195756",
"0.6017952",
"0.6016829"... | 0.71110547 | 0 |
Generate the n x k matrix of basis functions(k) for each pixel(n) | def Lm8V(UqYS, JyfR, Mkmy, idx7):
W1md = []
for U78l in range(JyfR):
for cpvk in oyIN.arange(-1 * U78l, U78l + 1):
if U78l % 2 == 0 and cpvk % 2 == 0 or (U78l % 2 == 1 and cpvk % 2 == 1):
PgcV = uulx.polarDimBasis(U78l, cpvk, beta=UqYS)
W1md.append(uulx.comput... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zXBT(exwG):\n SxVy = []\n for YRbF in Ni9Y(0, exwG - 1):\n SxVy += [uQiN(YRbF, exwG)]\n for r845 in Ni9Y(0, exwG - 1):\n for G1Hx in Ni9Y(r845 + 1, exwG):\n P6bq = IDBL(G1Hx, r845, exwG) + IDBL(r845, G1Hx, exwG)\n Ty9i = 1j * (IDBL(G1Hx, r845, exwG) - IDBL(r845, G1H... | [
"0.66472393",
"0.6417357",
"0.63603985",
"0.6348653",
"0.63110596",
"0.62744427",
"0.6272634",
"0.62427276",
"0.6209776",
"0.62008554",
"0.6185384",
"0.61662495",
"0.6157302",
"0.6138922",
"0.61348456",
"0.61004037",
"0.60944015",
"0.6054251",
"0.60254717",
"0.60254717",
"0.6... | 0.0 | -1 |
Generate the n x k matrix of basis functions(k) for each pixel(n) | def MRi3(UqYS, JyfR, ydZk, OhBR):
W1md = []
for WKvO in range(JyfR[0]):
for LVAh in range(JyfR[1]):
PgcV = uulx.dimBasis2d(WKvO, LVAh, beta=UqYS)
W1md.append(uulx.computeBasis2d(PgcV, ydZk, OhBR).flatten())
ut3e = oyIN.array(W1md)
return ut3e.transpose() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zXBT(exwG):\n SxVy = []\n for YRbF in Ni9Y(0, exwG - 1):\n SxVy += [uQiN(YRbF, exwG)]\n for r845 in Ni9Y(0, exwG - 1):\n for G1Hx in Ni9Y(r845 + 1, exwG):\n P6bq = IDBL(G1Hx, r845, exwG) + IDBL(r845, G1Hx, exwG)\n Ty9i = 1j * (IDBL(G1Hx, r845, exwG) - IDBL(r845, G1H... | [
"0.66472393",
"0.6417357",
"0.63603985",
"0.6348653",
"0.63110596",
"0.62744427",
"0.6272634",
"0.62427276",
"0.6209776",
"0.6185384",
"0.61662495",
"0.6157302",
"0.6138922",
"0.61348456",
"0.61004037",
"0.60944015",
"0.6054251",
"0.60254717",
"0.60254717",
"0.60013807",
"0.5... | 0.62008554 | 9 |
Creates a hook to evaluate a linear model on top of an SSL embedding. | def FIMM(YKHO, b0Ix: float, Au0z: Optional[torch.Tensor]=None, **B2fa: Any) -> None:
super().__init__(**B2fa)
YKHO.weight_decay = 0.0001
YKHO.learning_rate = b0Ix
YKHO.train_metrics: x1iM[d_mb] = [P9Xm(), I1xy(), QEbV()] if YKHO.num_classes == 2 else [QEbV()]
YKHO.val_metrics: x1iM[d_mb] = [P9Xm(), ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XS8u(Csk6, BOxD=None, ZM6q=25, wqL3=False, NKcE='sample', ovGo=1, TVTK=5, VxE8=None, xzCw=True):\n\n def OQzj(CErl, qtWj, Bugx, vauY):\n CErl.log('info', 'Checking training...')\n if xzCw:\n N77f = sum(CErl.validate_model().pack())\n CErl.log('info', 'Valid loss: %g' % N7... | [
"0.6211056",
"0.5902418",
"0.5777568",
"0.5708836",
"0.56722176",
"0.5654829",
"0.5590083",
"0.5535785",
"0.5474588",
"0.5428112",
"0.5401919",
"0.5382003",
"0.53733796",
"0.5357593",
"0.53535706",
"0.5321278",
"0.53184336",
"0.5303821",
"0.5262827",
"0.52368677",
"0.5219112"... | 0.0 | -1 |
Forward pass and MLP loss computation for the linear head only. Representations from the encoder are frozen and detach from computation graph for this loss computation. Returns crossentropy loss for the input batch. | def qVvx(YKHO, Wc9F: BatchType, T9l5: pl.LightningModule, LT6S: bool) -> Kt_s:
Wc9F = Wc9F[tI5D.LINEAR_HEAD] if isinstance(Wc9F, dict) else Wc9F
WKvO, LVAh = YKHO.to_device(Wc9F, T9l5.device)
with ht2j.no_grad():
S2xu = YKHO.get_representations(T9l5, WKvO)
S2xu = S2xu.detach()
assert isinsta... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GT2U(YKHO, NArs, Wc9F):\n EcVT, (VUzz, j4l8), yzQ0 = Wc9F\n zseD, RUIi = YKHO.apply_fun(NArs, EcVT)\n qET2 = oyIN.sum(((zseD - VUzz) ** 2).squeeze() * yzQ0)\n return qET2",
"def KVH6(YKHO, WKvO, LVAh):\n YKHO.logits = WKvO\n YKHO.labels = LVAh\n RsfQ = oyIN.max(YKHO.logits, axis=1).resha... | [
"0.67402065",
"0.6669648",
"0.6561705",
"0.65206015",
"0.6487822",
"0.64499617",
"0.64262784",
"0.6415926",
"0.6343409",
"0.62949353",
"0.6276263",
"0.6276263",
"0.62756914",
"0.62750167",
"0.62736154",
"0.62692857",
"0.6259217",
"0.6239315",
"0.6232419",
"0.6227349",
"0.6227... | 0.588145 | 99 |
Initialize attributes of the Pet class | def FIMM(YKHO, GtU2, RUFN):
super().__init__(GtU2, RUFN) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(Ro_8, *, ZJe_: Optional[pulumi.Input[int]]=None, hxjC: Optional[pulumi.Input['PetArgs']]=None):\n if ZJe_ is not None:\n qe4Y.set(Ro_8, 'age', ZJe_)\n if hxjC is not None:\n qe4Y.set(Ro_8, 'pet', hxjC)",
"def FIMM(YKHO, aD6s=None):\n YKHO._pet_factory = aD6s",
"def FIMM(YKHO, aD... | [
"0.71455705",
"0.70850784",
"0.70012975",
"0.69938344",
"0.6771323",
"0.66445667",
"0.66278493",
"0.66229415",
"0.6560391",
"0.6555724",
"0.6538749",
"0.6506262",
"0.6490931",
"0.6489315",
"0.6481513",
"0.6472904",
"0.6465509",
"0.6444355",
"0.6429676",
"0.63923997",
"0.63765... | 0.73645234 | 5 |
Inverse CDF of normal distribution | def GjtZ(XP5J, yGTL=0.0, UkX0=1.0):
if yGTL == 0.0 and UkX0 == 1.0:
return epAf.sqrt(2) * qod4(2 * XP5J - 1)
else:
return yGTL + epAf.sqrt(UkX0) * GjtZ(XP5J) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def K1u2(YKHO, YzER=None):\n return epAf.sqrt(-2.0 * YKHO.sigma * YKHO.sigma * epAf.log(1.0 - YzER))",
"def qVfE(YKHO, EcVT):\n ROaS = EcVT.shape[1]\n for BIM6 in range(ROaS):\n WKvO = EcVT[:, BIM6]\n if not YKHO.use_inverse_qt:\n WKvO = 0.5 + 0.5 * tVah(WKvO / oyIN.sqrt(2.0)) i... | [
"0.7906314",
"0.7391093",
"0.7220931",
"0.7038415",
"0.6992182",
"0.6961231",
"0.6804961",
"0.67960453",
"0.6794223",
"0.6793628",
"0.67795885",
"0.6753188",
"0.674474",
"0.6736447",
"0.67249244",
"0.6720289",
"0.6652402",
"0.66378146",
"0.6628221",
"0.66218716",
"0.660756",
... | 0.62534785 | 44 |
Per specification, all selects will contain all conjunctive (AND) or all disjunctive (OR). This function finds that out with the whole WHERE string and returns a lambda with that type of check, or None if does not exist. | def An7r(YKHO, aTLP: str):
khtY = all
net2 = []
aTLP = ''.join((Z9rn for Z9rn in aTLP if Z9rn not in ')( '))
YKHO.to_print = aTLP
if 'or' in aTLP:
khtY = any
net2 = aTLP.split('or')
elif 'and' in aTLP:
khtY = all
net2 = aTLP.split('and')
elif ',' in aTLP:
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def qJWj(Q3Ge):\n pass",
"def PHUf(DpUl, xU0C, _7zC, DEbI, y0cW=None, Qemi=False):\n TpjG = []\n k2EK = Qe_F(DpUl, _7zC, xU0C, prefix=y0cW, aggregate=Qemi)\n k2EK = ' AND '.join(k2EK)\n if len(k2EK) > 0:\n k2EK = '(%s)' % k2EK\n TpjG.append(k2EK)\n TpjG += Qe_F(DpUl, DEbI, xU0C, p... | [
"0.68154085",
"0.6389073",
"0.6198039",
"0.60651094",
"0.598538",
"0.59312415",
"0.5914772",
"0.59110296",
"0.5900508",
"0.5860942",
"0.58523905",
"0.5840231",
"0.5814994",
"0.57896143",
"0.57754064",
"0.57632875",
"0.5731775",
"0.5688251",
"0.5641657",
"0.5619682",
"0.557631... | 0.0 | -1 |
Return the name of running mod input | def hEap():
HBP2 = Hy7s.path.basename(Rp8I())
if HBP2.lower().endswith('.py'):
HBP2 = HBP2[:-3]
return HBP2 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dvBq(YKHO) -> qe4Y.Input[str]:\n return qe4Y.get(YKHO, 'input_name')",
"def dvBq(YKHO) -> qe4Y.Input[str]:\n return qe4Y.get(YKHO, 'input_name')",
"def ZUM3(YKHO):\n return YKHO.mod_name",
"def QRiV():\n qP5v = HwRy.argv[0].split('/')[-1]\n if len(HwRy.argv) < 2:\n print('\\nUsage: ... | [
"0.6773796",
"0.6773796",
"0.6760691",
"0.65444005",
"0.6535387",
"0.6421863",
"0.6407256",
"0.64063543",
"0.6389588",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.63376385",
"0.... | 0.7784041 | 0 |
Creates and saves a user with a given email and password | def xWi2(YKHO, D3lj, jTXt, **wdCM):
if not D3lj:
raise ValueError('The Email must be set')
D3lj = YKHO.normalize_email(D3lj)
CBIr = YKHO.model(email=D3lj, **wdCM)
CBIr.set_password(jTXt)
CBIr.save(using=YKHO._db)
return CBIr | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xWi2(YKHO, D3lj, jTXt, **wdCM):\n if not D3lj:\n raise ValueError('The email must be set')\n D3lj = YKHO.normalize_email(D3lj)\n CBIr = YKHO.model(email=D3lj, **wdCM)\n CBIr.set_password(jTXt)\n CBIr.save()",
"def lYUQ(D3lj, jTXt):\n XN37.create_user(D3lj, jTXt)",
"def lYUQ(D3lj, j... | [
"0.87037265",
"0.85164136",
"0.84418267",
"0.8411588",
"0.8368814",
"0.8327648",
"0.83252126",
"0.83196145",
"0.83090556",
"0.8305928",
"0.83029234",
"0.83002573",
"0.8285182",
"0.8274384",
"0.8273565",
"0.8271248",
"0.8267961",
"0.8265104",
"0.8258562",
"0.8258562",
"0.82585... | 0.8189048 | 76 |
Destructively modify list so that it no longer contains any elements which equal element. | def LnXF(list, U6D_):
r845 = 0
for YRbF in range(len(list)):
if list[YRbF] != U6D_:
list[r845] = list[YRbF]
r845 = r845 + 1
del list[r845:] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uDvH(yv6U):\n s43C = []\n SVA7 = None\n for U6D_ in yv6U:\n if U6D_ != SVA7:\n s43C.append(U6D_)\n SVA7 = U6D_\n return s43C",
"def sHC1(YKHO, list):\n return set((ZfUD for ZfUD in list))",
"def RVij(YKHO, SART):\n KtEk = set()\n IdXh = [WKvO for WKvO in SA... | [
"0.713224",
"0.7031715",
"0.6947216",
"0.68062466",
"0.6803353",
"0.6741117",
"0.67345536",
"0.6712297",
"0.6663615",
"0.6640557",
"0.66334313",
"0.6628565",
"0.660675",
"0.6597924",
"0.6586346",
"0.658156",
"0.6564059",
"0.655685",
"0.6551821",
"0.65304303",
"0.65048414",
... | 0.6785532 | 5 |
Destructively modify list so that it no longer contains contiguous repetitions of the same element. | def ye1B(list):
u54L = len(list)
r845 = 1
if u54L <= 1:
return
AOBR = list[0]
for YRbF in range(1, u54L):
if list[YRbF] != AOBR:
AOBR = list[YRbF]
list[r845] = AOBR
r845 = r845 + 1
del list[r845:] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RVij(YKHO, SART):\n KtEk = set()\n IdXh = [WKvO for WKvO in SART if WKvO not in KtEk and (not KtEk.add(WKvO))]\n return IdXh",
"def R7qR(WKvO, list):\n list.append(WKvO)\n del list[0]\n return list",
"def iNYw(IqQl):\n S06t = []\n S06t.extend((YRbF for YRbF in IqQl if YRbF not in S0... | [
"0.70460075",
"0.6841304",
"0.66865075",
"0.6428163",
"0.631516",
"0.63106424",
"0.6296659",
"0.62810576",
"0.62781",
"0.6277389",
"0.6256844",
"0.62553775",
"0.62238353",
"0.6206947",
"0.6199723",
"0.6194138",
"0.61825275",
"0.61793876",
"0.6172206",
"0.61682636",
"0.6160775... | 0.6921777 | 1 |
Open and read the given json file, and save the data in attributes. The json is read directly as Python code, not through a lib. | def PSj2(YKHO, Ux0P):
with open(Ux0P, 'r') as eHNT:
zgjV = eval(eHNT.read())
YKHO.menu_text = zgjV['menu_text']
YKHO.new_game_text = zgjV['new_game_text']
YKHO.starting_node = zgjV['starting_node']
YKHO.continue_text = zgjV['continue_text']
YKHO.quit_text = zgjV['quit_text'] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cQeh(YKHO, nUeQ):\n pass",
"def PSj2(Emd4, Ux0P, **B2fa):\n with open(Ux0P, 'r') as eHNT:\n yIVm = qQXR.load(eHNT)\n return Emd4.from_dict(yIVm)",
"def GvL1(IznC: str) -> dict:\n with open(f'./data/json/{IznC}.json', 'r') as Ga6V:\n return qQXR.load(Ga6V)",
"def pktP(YKHO, bpNo)... | [
"0.71205574",
"0.7111356",
"0.6940118",
"0.68836236",
"0.6868519",
"0.6859174",
"0.6842583",
"0.6764991",
"0.67264336",
"0.6722308",
"0.6719047",
"0.67131",
"0.6711593",
"0.67072254",
"0.6702473",
"0.6699151",
"0.66832083",
"0.66742784",
"0.6664353",
"0.6656077",
"0.6650142",... | 0.6857047 | 6 |
Return list of parameters that are tracked by the cockpit. | def cvxD(YKHO):
if isinstance(YKHO.tproblem, WlpP):
return [XP5J for XP5J in YKHO.tproblem.net.parameters() if XP5J.requires_grad]
else:
C3ST, bGrB = YKHO.tproblem
return [XP5J for XP5J in C3ST.parameters() if XP5J.requires_grad] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SGPK(YKHO):\n return []",
"def xmhH():\n return []",
"def SGPK(YKHO):\n return list(YKHO.__dict__.keys())",
"def mI5I(YKHO):\n return []",
"def NArs(YKHO):\n return []",
"def W6RH(YKHO):\n return []",
"def uLgQ(YKHO):\n return list(YKHO._parameterDict.keys())",
"def NArs(YKHO... | [
"0.76897496",
"0.76865214",
"0.7651795",
"0.76181406",
"0.74689347",
"0.74490136",
"0.74461436",
"0.7404677",
"0.7404677",
"0.7404677",
"0.73973024",
"0.73921144",
"0.73921144",
"0.73921144",
"0.73921144",
"0.73921144",
"0.73516184",
"0.73476166",
"0.73476166",
"0.7314408",
"... | 0.68077403 | 97 |
Handle multiple occurrences of ``BatchGradTransforms`` by combining them. | def ghhp(Emd4, YBcr):
Ymkf = [tTpl for tTpl in YBcr if isinstance(tTpl, _wwx)]
zniC = [tTpl for tTpl in YBcr if not isinstance(tTpl, _wwx)]
om3o = zniC
if Ymkf:
om3o.append(Emd4._merge_batch_grad_transforms(Ymkf))
return om3o | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hXNg(QrbC):\n Ymkf = [a1PO._transforms for a1PO in QrbC]\n ctTK = []\n for a1PO in Ymkf:\n for H5ew, BWXx in a1PO.items():\n ctTK.append((H5ew, BWXx))\n TzaK = {q2Xo[0] for q2Xo in ctTK}\n Jb7O = {}\n for H5ew in TzaK:\n ZZSa = [q2Xo[1] for q2Xo in ctTK if q2Xo[0] == ... | [
"0.74116355",
"0.7320592",
"0.6070225",
"0.57561994",
"0.5727273",
"0.5653022",
"0.56512254",
"0.5640762",
"0.5561012",
"0.5552677",
"0.5520815",
"0.55072993",
"0.54882634",
"0.5475459",
"0.54641724",
"0.54453045",
"0.5435793",
"0.5423255",
"0.54114145",
"0.5406499",
"0.54048... | 0.7887031 | 0 |
Set the value of the MyDocs input for this Choreo. ((optional, boolean) Enter "true" to return resources for the requesting user only. The default is "false" (returns all account resources).) | def NoCs(YKHO, BWXx):
super(dWj0, YKHO)._set_input('MyDocs', BWXx) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def docs(YKHO, OaeV: Context):\n Ol8d = '**Docs:** {0.docs}'.format(YKHO)\n await OaeV.send(Ol8d)",
"def uw_k(YKHO, IyyC, X9mD=False):\n if YKHO._checkAttr(IyyC, throw=X9mD, update=False, **IyyC):\n YKHO.update(IyyC)\n return True\n return False",
"def ghly(YKHO, OGmZ, Gl_g=True... | [
"0.5080463",
"0.4879141",
"0.4866719",
"0.48605043",
"0.47289285",
"0.47232327",
"0.47192392",
"0.47022855",
"0.47017705",
"0.47009978",
"0.47009978",
"0.46846494",
"0.46814927",
"0.46809354",
"0.46777964",
"0.46539226",
"0.4611268",
"0.46076733",
"0.4592523",
"0.4592373",
"0... | 0.69990945 | 0 |
Retrieve the value for the "Response" output from this Choreo execution. ((xml) The response from the Google Documents API.) | def _O3m(YKHO):
return YKHO._output.get('Response', None) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def EbXM(YKHO):\n return YKHO._response",
"def EbXM(YKHO):\n return YKHO.response",
"def geh0(YKHO):\n return jC2S(YKHO.resource, YKHO.tag.find(ptaa('response')))",
"def geh0(YKHO):\n return YKHO._response",
"def geh0(YKHO):\n return YKHO._response",
"def geh0(YKHO) -> h8nf[str]:\n retu... | [
"0.70926714",
"0.6981153",
"0.68312645",
"0.67708707",
"0.67708707",
"0.674506",
"0.674506",
"0.6729061",
"0.6729061",
"0.66682285",
"0.6666834",
"0.6651729",
"0.6649922",
"0.66185546",
"0.65195966",
"0.649583",
"0.649583",
"0.64384973",
"0.63319683",
"0.62996006",
"0.6208548... | 0.77802783 | 0 |
Make a quick set of greedy surveys This is a convienence function to generate a list of survey objects that can be used with rubin_sim.scheduler.schedulers.Core_scheduler. To ensure we are robust against changes in the sims_featureScheduler codebase, all kwargs are explicitly set. | def vtR9(UGeA=32, Ueky=2, PXqY=30.0, KUnM=['r', 'i', 'z', 'y'], g7sK=[-80.0, 80.0], y1Vp=60.0, WV7U=76.0, H33i=30.0, uUMN='DD', jo6G=3.0, r9kd=0.75, VCMv=3.0, hB7L=3.0, buwA=-1.0, k9oZ=None):
K3Fp = {'block_size': 1, 'smoothing_kernel': None, 'seed': 42, 'camera': 'LSST', 'dither': True, 'survey_name': 'greedy'}
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vtR9(UGeA, Ueky=1):\n qryJ = h8pP(nside=UGeA)\n loV2 = hcGr(qryJ)\n KUnM = ['r', 'i', 'z', 'y']\n LN4V = []\n for Aj36 in KUnM:\n bJFh = []\n bJFh.append(PgcV.M5_diff_basis_function(filtername=Aj36, nside=UGeA))\n bJFh.append(PgcV.Target_map_basis_function(filtername=Aj36, t... | [
"0.70317304",
"0.64642",
"0.6071159",
"0.5569374",
"0.55636954",
"0.5556956",
"0.5531302",
"0.5511014",
"0.54932946",
"0.54695326",
"0.54661614",
"0.5309683",
"0.52430886",
"0.5232786",
"0.523037",
"0.52263355",
"0.52096295",
"0.5188243",
"0.5167428",
"0.5103774",
"0.5071779"... | 0.6800298 | 1 |
Performs Spectral Normalization on a weight tensor. Specifically it divides the weight tensor by its largest singular value. This is intended to stabilize GAN training, by making the discriminator satisfy a local 1Lipschitz constraint. Based on [Spectral Normalization for Generative Adversarial Networks][sngan] | def mB51(_mSQ, C00Q=1, afrB=None, a2Ig=False):
e31C = _mSQ.shape.as_list()
yAAV = ZylS.reshape(_mSQ, [-1, e31C[-1]])
P6bq = ZylS.get_variable('u', [1, e31C[-1]], initializer=ZylS.truncated_normal_initializer(), trainable=False)
w8Fi = P6bq
for bGrB in range(C00Q):
m07n = QdrQ(ZylS.matmul(w8F... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XoQd(YKHO):\n YKHO.weight /= YKHO.weight.sum()",
"def UTgb(XcU5, KCHu):\n UI67 = UbCs(1e-05)\n ow3g = vhpA.sqrt((XcU5 * XcU5).sum(axis=0, keepdims=True) + UI67)\n kDob = ow3g * KCHu\n return XcU5 / kDob",
"def NkkI(YKHO) -> None:\n if YKHO.norm is not None:\n yIVc = YKHO.w.abs().su... | [
"0.6663901",
"0.6524157",
"0.64342046",
"0.64289254",
"0.6376084",
"0.627508",
"0.6213969",
"0.621032",
"0.62068903",
"0.61452943",
"0.61310107",
"0.6104571",
"0.6088345",
"0.6084124",
"0.60804",
"0.6038588",
"0.6032734",
"0.603067",
"0.603067",
"0.6030572",
"0.6012251",
"0... | 0.63497555 | 5 |
Creates a spectral normalized (SN) convolutional layer. | def F_fT(CK9p, EDoJ, ri6P=3, hHqT=3, ozc1=1, ioxB=1, MDNr=1, afrB=None, mWFP='snconv2d'):
with ZylS.variable_scope(mWFP):
yzQ0 = ZylS.get_variable('w', [ri6P, hHqT, CK9p.get_shape()[-1], EDoJ], initializer=ZylS.contrib.layers.xavier_initializer())
K9z4 = mB51(yzQ0, num_iters=MDNr, update_collection=... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TyOk(RMvl: int, KOdv: int, ZT17: int=1, _0fC: int=1, dvgN: int=0, oug5: bool=False):\n yIp6 = U78l.Conv1d(RMvl, KOdv, ZT17, stride=_0fC, padding=dvgN, bias=oug5)\n U78l.init.kaiming_normal_(yIp6.weight)\n if oug5:\n yIp6.bias.data.zero_()\n return SNDs(yIp6)",
"def nNv3(YKHO, o4sw):\n i... | [
"0.6107967",
"0.61023074",
"0.6090263",
"0.59479725",
"0.5911482",
"0.5892666",
"0.58465636",
"0.5784381",
"0.57274973",
"0.572288",
"0.57102156",
"0.56594616",
"0.56488717",
"0.56104946",
"0.5603946",
"0.5594676",
"0.55872345",
"0.55733234",
"0.55733234",
"0.5567193",
"0.556... | 0.6385432 | 0 |
Get a command line parser. | def EpPs():
wvEv = B4X0.ArgumentParser(description=__doc__)
wvEv.add_argument('--skip-git', dest='run_git', action='store_false', default=True, help='Skip creating a new git commit.')
wvEv.add_argument('builddir', help='Input path to the compiled locale messages.')
wvEv.add_argument('sourcedir', nargs='... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def EpPs():\n return wQcs.set_parser(collected=fo8A.collect())",
"def EpPs():\n wvEv = B4X0.ArgumentParser(description=__doc__)\n return wvEv",
"def wvEv():\n return EpPs()",
"def EpPs():\n p_z1 = _Fei.build_manager()\n JZXy = _Fei.build_command_line_source(prog='prospector', description=No... | [
"0.80788916",
"0.79840004",
"0.76778644",
"0.7596108",
"0.7582669",
"0.7575743",
"0.7568218",
"0.7558888",
"0.7545465",
"0.75264424",
"0.74633646",
"0.7452418",
"0.7449176",
"0.74282485",
"0.74177897",
"0.739733",
"0.73960656",
"0.73476595",
"0.7347562",
"0.73399675",
"0.7329... | 0.7392367 | 17 |
Fires bullet if there are not too many on screen | def Hy9P(WFC2, tJm0, Vjhr, C7MP):
if len(WFC2) < tJm0.bullets_allowed:
jbub = GBVa(Vjhr, tJm0, C7MP)
WFC2.add(jbub) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def s2E3(YKHO):\n if len(YKHO.bullets) < YKHO.settings.bullets_allowed:\n jbub = GBVa(YKHO)\n YKHO.bullets.add(jbub)\n YKHO.shot_sound.play()",
"def s2E3(YKHO):\n if len(YKHO.bullets) < YKHO.settings.bullet_limit:\n jbub = GBVa(YKHO)\n YKHO.bullets.add(jbub)",
"def s2E3... | [
"0.7890488",
"0.78820056",
"0.7838855",
"0.7832414",
"0.78201425",
"0.7783652",
"0.7783652",
"0.7783652",
"0.7725851",
"0.77121794",
"0.762831",
"0.75900674",
"0.75898504",
"0.75724447",
"0.7529853",
"0.75115246",
"0.7509927",
"0.74839675",
"0.7471714",
"0.7274176",
"0.725188... | 0.72679394 | 20 |
Responds to if fleet has reached the edge of the screen | def YSO3(SaI9, tJm0):
for oeTy in SaI9.sprites():
if oeTy.check_edges():
kS1e(SaI9, tJm0)
break | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hDQs(pKYF):\n return pKYF.position.x < 70 or pKYF.position.x > VE0p.window_width - 70 or pKYF.position.y < 70 or (pKYF.position.y > VE0p.window_height - 70)",
"def nMi8(YKHO):\n for JjEH in YKHO.enemies.sprites():\n if JjEH.check_edges():\n YKHO._change_fleet_direction()\n ... | [
"0.657199",
"0.6533241",
"0.647415",
"0.6458707",
"0.6447462",
"0.63846195",
"0.63506687",
"0.63338655",
"0.63289374",
"0.63210714",
"0.6267404",
"0.6232145",
"0.623177",
"0.623177",
"0.623177",
"0.623177",
"0.6221546",
"0.6156832",
"0.6050834",
"0.6030781",
"0.5998176",
"0... | 0.0 | -1 |
Check if fleet is on edge, then update position entire fleet | def bOBM(SaI9, tJm0, C7MP, WFC2, eQSh, Vjhr, y1e_):
YSO3(SaI9, tJm0)
SaI9.update()
if a9eO.sprite.spritecollideany(C7MP, SaI9):
GR2R(eQSh, SaI9, WFC2, tJm0, C7MP, Vjhr, y1e_)
Cshs(eQSh, SaI9, WFC2, tJm0, C7MP, Vjhr, y1e_) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nMi8(YKHO):\n for x0Pt in YKHO.eggs.sprites():\n if x0Pt.check_edges():\n YKHO._change_fleet_direction()\n break",
"def nMi8(YKHO):\n for JjEH in YKHO.enemies.sprites():\n if JjEH.check_edges():\n YKHO._change_fleet_direction()\n break",
"def ... | [
"0.6759842",
"0.6718548",
"0.66625375",
"0.6638225",
"0.6638225",
"0.6638225",
"0.6638225",
"0.6579399",
"0.65762",
"0.657149",
"0.6538958",
"0.6533057",
"0.65089494",
"0.6449728",
"0.6386404",
"0.6374636",
"0.6288521",
"0.6248287",
"0.6224577",
"0.61712295",
"0.6155155",
"... | 0.0 | -1 |
Sets the login_failures of this Credential. | def _PGo(YKHO, _PGo):
YKHO._login_failures = _PGo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GyM2(YKHO, GyM2):\n YKHO._login_failures_reset = GyM2",
"def nTGR(YKHO, nTGR: float):\n YKHO._login_failed_count = nTGR",
"def iKmY(YKHO, iKmY):\n YKHO._failure_count = iKmY",
"def b2P6(YKHO, b2P6):\n YKHO._fail_count = b2P6",
"def A8ir(YKHO, A8ir):\n YKHO._first_login_failure = A8ir",
... | [
"0.79241544",
"0.70524687",
"0.6151412",
"0.6055146",
"0.5948509",
"0.58969957",
"0.58137786",
"0.58137786",
"0.5798181",
"0.5763238",
"0.56636",
"0.56514096",
"0.56361276",
"0.5563256",
"0.55561376",
"0.55426085",
"0.55426085",
"0.5526896",
"0.54668254",
"0.54668254",
"0.546... | 0.8403356 | 0 |
Sets the credential_type of this Credential. | def uG3u(YKHO, uG3u):
BbPm = ['PASSWORD', 'API_KEY', 'JWT']
if uG3u not in BbPm:
raise ValueError('Invalid value for `credential_type` ({0}), must be one of {1}'.format(uG3u, BbPm))
YKHO._credential_type = uG3u | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uG3u(YKHO, uG3u):\n BbPm = [AVmo]\n YKHO._credential_type = uG3u",
"def uG3u(YKHO) -> h8nf[qe4Y.Input['AuthConfigCredentialType']]:\n return qe4Y.get(YKHO, 'credential_type')",
"def mwuo(YKHO, mwuo):\n YKHO._credential = mwuo",
"def mwuo(YKHO, mwuo):\n YKHO._credential = mwuo",
"def uG3u... | [
"0.8790203",
"0.6861484",
"0.65959543",
"0.65959543",
"0.65611416",
"0.65208995",
"0.635435",
"0.635435",
"0.6315654",
"0.62820417",
"0.627848",
"0.627848",
"0.62321126",
"0.6224325",
"0.6193402",
"0.6173936",
"0.6173936",
"0.6173936",
"0.6173936",
"0.6173936",
"0.61706245",
... | 0.8712072 | 1 |
Sets the modified_by of this Credential. | def YgMu(YKHO, YgMu):
YKHO._modified_by = YgMu | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dFAY(YKHO, YgMu):\n try:\n from zcrmsdk.src.com.zoho.crm.api.users import User\n except Exception:\n from ..users import User\n if YgMu is not None and (not isinstance(YgMu, User)):\n raise pDrJ(Byma.DATA_TYPE_ERROR, 'KEY: modified_by EXPECTED TYPE: User', None, None)\n YKHO.__... | [
"0.8573429",
"0.7339412",
"0.7246319",
"0.7246319",
"0.7246319",
"0.7246319",
"0.7198944",
"0.7166896",
"0.7071641",
"0.69487846",
"0.68787706",
"0.682962",
"0.68056387",
"0.67045814",
"0.67008525",
"0.66728806",
"0.6657306",
"0.66360146",
"0.66360146",
"0.66360146",
"0.66360... | 0.8467215 | 2 |
Sets the created_on of this Credential. | def i0wi(YKHO, i0wi):
YKHO._created_on = i0wi | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def i0wi(YKHO, i0wi):\n if YKHO.local_vars_configuration.client_side_validation and i0wi is None:\n raise ValueError('Invalid value for `created_on`, must not be `None`')\n YKHO._created_on = i0wi",
"def zACL(YKHO, _EYN):\n YKHO.created = _EYN",
"def kpUr(YKHO, BWXx):\n setattr(YKHO, YKHO.CR... | [
"0.70342684",
"0.6987795",
"0.6970085",
"0.68934655",
"0.686945",
"0.67137134",
"0.6705012",
"0.66576475",
"0.66461205",
"0.66461205",
"0.66461205",
"0.66461205",
"0.66461205",
"0.66461205",
"0.66461205",
"0.66461205",
"0.66461205",
"0.66334283",
"0.65894866",
"0.6585182",
"0... | 0.77289534 | 0 |
Sets the created_by of this Credential. | def tC0c(YKHO, tC0c):
YKHO._created_by = tC0c | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def taPz(YKHO, tC0c):\n try:\n from zcrmsdk.src.com.zoho.crm.api.users import User\n except Exception:\n from ..users import User\n if tC0c is not None and (not isinstance(tC0c, User)):\n raise pDrJ(Byma.DATA_TYPE_ERROR, 'KEY: created_by EXPECTED TYPE: User', None, None)\n YKHO.__c... | [
"0.82729125",
"0.82729125",
"0.7814887",
"0.7643128",
"0.7643128",
"0.73983824",
"0.72850746",
"0.72850746",
"0.72850746",
"0.72850746",
"0.72850746",
"0.72850746",
"0.7258147",
"0.6993374",
"0.6929865",
"0.6929865",
"0.6921744",
"0.68884695",
"0.68884695",
"0.68884695",
"0.6... | 0.82124716 | 3 |
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.83920443",
"0.83544874",
"0.8294375",
"0.8131804",
"0.8114275",
"0.8099284",
"0.8098424",
"0.8097017",
"0.8097017",
"0.80916125",
"0.80916125",
"0.80916125",
"0.80916125",
"0.8084362",
"0.8084362",
"0.8084362",
"0.8084362",
"0.8084362",
"0.80659354",
"0.805918",
"0.8056744... | 0.0 | -1 |
Define a prior and a posterior weight distribution. We assume both to be standard normal iid. | def AXNx(YKHO):
Wz_y = []
hf6Q = []
Z60O = []
ORcf = []
with ZylS.name_scope('encoder_layer_weights'):
for YRbF in range(1, YKHO.length_encoder):
_qKk, F1RG = (YKHO.n_encoder[YRbF - 1], YKHO.n_encoder[YRbF])
print(_qKk, F1RG)
_qKk += 1
with Zyl... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, yXjA: int, uwTF: int, N2bm: float, yp__: float, mIk9: float, Apgb, rYSA):\n super().__init__()\n YKHO.weight_mu = U78l.Parameter(ht2j.Tensor(uwTF, yXjA).normal_(Apgb, 0.1))\n YKHO.weight_rho = U78l.Parameter(ht2j.Tensor(uwTF, yXjA).normal_(rYSA, 0.1))\n YKHO.weight_sampler = qBae(YKHO.we... | [
"0.654267",
"0.65165496",
"0.64708203",
"0.6418337",
"0.6275472",
"0.6221096",
"0.6190465",
"0.60869235",
"0.60056204",
"0.59958225",
"0.5972386",
"0.5956675",
"0.59287673",
"0.5925605",
"0.59225667",
"0.591936",
"0.591035",
"0.5884866",
"0.58710426",
"0.58706635",
"0.5850448... | 0.0 | -1 |
KL[q || p] returns the KLdivergence between the prior p and the variational posterior q. | def q1hk(YKHO, d64L, BaxI, Az3N, dd44):
tsC6 = d64L
zcZh = BaxI
g2zq = Az3N
wApK = dd44
return 0.5 * ZylS.reduce_sum(wApK - zcZh + ZylS.square(tsC6 - g2zq) / ZylS.exp(wApK) + ZylS.exp(zcZh - wApK) - 1) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dzAH(XP5J, vexM):\n return XP5J * RKD7(XP5J / vexM) + (1.0 - XP5J) * RKD7((1.0 - XP5J) / (1.0 - vexM))",
"def PlVk(V6IE, T8ck):\n _hZ2 = 1e-05\n V6IE = V6IE + _hZ2\n T8ck = T8ck + _hZ2\n scUA = oyIN.sum(V6IE * oyIN.log(V6IE / T8ck))\n return scUA",
"def dzAH(XP5J: np.ndarray, vexM: np.nda... | [
"0.83894134",
"0.82100546",
"0.8099761",
"0.80273366",
"0.7961082",
"0.79489684",
"0.774717",
"0.7727043",
"0.76981384",
"0.76806307",
"0.76715004",
"0.7636328",
"0.7559664",
"0.7519278",
"0.7512637",
"0.74325603",
"0.7411719",
"0.7411719",
"0.7383462",
"0.7362469",
"0.733095... | 0.0 | -1 |
d_kl(q(z|x)||p(z)) returns the KLdivergence between the prior p and the variational posterior q. | def d8Y5(YKHO):
return -ZylS.reduce_mean(ZylS.reduce_mean(0.5 * ZylS.reduce_sum(1.0 + 2.0 * YKHO.z_log_sigma - ZylS.square(YKHO.z_mu) - ZylS.exp(2.0 * YKHO.z_log_sigma), [-1]), [0])) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dzAH(XP5J, vexM):\n return XP5J * RKD7(XP5J / vexM) + (1.0 - XP5J) * RKD7((1.0 - XP5J) / (1.0 - vexM))",
"def dzAH(XP5J, vexM):\n XP5J = XP5J.astype(float)\n vexM = vexM.astype(float)\n bISY = oyIN.sum(oyIN.where(XP5J != 0, XP5J * oyIN.log2(XP5J / vexM), 0))\n return bISY",
"def dzAH(XP5J, v... | [
"0.8056928",
"0.7811533",
"0.77650326",
"0.76262116",
"0.74340624",
"0.7308097",
"0.72874486",
"0.7249003",
"0.7236282",
"0.71987057",
"0.71780217",
"0.7162141",
"0.7135776",
"0.7107759",
"0.710438",
"0.70904243",
"0.70861554",
"0.7077481",
"0.7077481",
"0.7056372",
"0.705637... | 0.0 | -1 |
Returns the negative ELBOW, which allows us to minimize instead of maximize. | def P1nW(YKHO):
Ep8u = ZylS.cast(ZylS.shape(YKHO.X)[0], 'float32')
bISY = YKHO.get_kl_multi()
y4NN = YKHO.get_ell()
ILSz = ZylS.reduce_mean(y4NN)
NbCL = bISY - ZylS.reduce_sum(y4NN) * ZylS.cast(YKHO.N, 'float32') / Ep8u
return (NbCL, bISY, ILSz) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kpjN(YKHO):\n return YKHO.spec / (1 - YKHO.sens)",
"def dwOP(YKHO, WKvO):\n Ep8u = WKvO.size(0)\n r8hN, Ty9i = YKHO.enc.encode(WKvO)\n epBp = Oa8f.sample_gaussian(r8hN, Ty9i)\n cbeJ = YKHO.dec.decode(epBp)\n ETu_ = Oa8f.log_bernoulli_with_logits(WKvO, cbeJ)\n ETu_ = ht2j.mean(ETu_)\n ... | [
"0.5893489",
"0.58793724",
"0.5839707",
"0.5807845",
"0.57936615",
"0.57848275",
"0.5764878",
"0.57464516",
"0.5715918",
"0.56859034",
"0.5683561",
"0.5678208",
"0.5676012",
"0.5673908",
"0.5672646",
"0.56692976",
"0.5651249",
"0.56476784",
"0.56401515",
"0.5615813",
"0.56066... | 0.0 | -1 |
Tests whether the internal is_py2_stdlib_module function (called by the sys.modules scrubbing functions) is reliable. | def l7Wu(YKHO):
f1H5 = [hjJR, BfDw]
YKHO.assertTrue(not any([hjJR.is_py2_stdlib_module(yR_P) for yR_P in f1H5]))
g_Hq = [HwRy, gbPf, jth9, TI0e]
if BfDw.PY2:
for yR_P in g_Hq:
if hasattr(yR_P, '__file__'):
print(yR_P.__file__, file=HwRy.stderr)
YKHO.assertTrue... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def WRiO(yR_P, Nx7B):\n ufV6 = HwRy.path\n Pxdw = Hy7s.path.dirname(wVCK.__file__)\n HwRy.path = [Pxdw]\n if 'darwin' in a9EH.system().lower():\n for pmON in ufV6:\n if 'site-packages' not in pmON:\n HwRy.path.append(pmON)\n if 'csv' in str(yR_P):\n return Tru... | [
"0.7191141",
"0.667335",
"0.65433955",
"0.64605045",
"0.6398001",
"0.6383775",
"0.6273882",
"0.6126075",
"0.59659934",
"0.59147465",
"0.58591986",
"0.5815212",
"0.5808324",
"0.57688874",
"0.576137",
"0.57515645",
"0.57163197",
"0.56942207",
"0.5684979",
"0.56815284",
"0.56549... | 0.83897275 | 0 |
Return a generator of all leaf symbols. Useful for when you want to inspect when the symbols come from. No deduplication even if the symbols has duplicates. | def ZcCm(YKHO) -> iu5r[wZLS]:
for d7pR in YKHO.arguments:
if isinstance(d7pR, Q7od):
yield from d7pR.leaf_symbols() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def S6TB(YKHO):\n return (Ty9i for Ty9i in YKHO.node_gen if Ty9i.is_leaf)",
"def YUht(YKHO) -> bDy6[str]:\n if YKHO.symbol in {'(name)', ':'}:\n yield YWvJ(str, YKHO.value)\n elif YKHO.symbol in ('//', '/'):\n if YKHO._items[-1].symbol in {'(name)', '*', ':', '..', '.', '[', 'self', 'child... | [
"0.7019398",
"0.70003414",
"0.6689931",
"0.6602757",
"0.6523117",
"0.64317834",
"0.62822914",
"0.62651485",
"0.6224306",
"0.61262614",
"0.60816914",
"0.6067854",
"0.6053529",
"0.60215974",
"0.5988311",
"0.5952909",
"0.59525424",
"0.5941632",
"0.59375983",
"0.59276545",
"0.592... | 0.8142303 | 0 |
Sample a batch of experiences. | def bbDh(YKHO, Ep8u):
k52S = [tuKI.randint(0, len(YKHO._storage) - 1) for bGrB in range(Ep8u)]
k52S = [tuKI.randint(0, len(YKHO._storage) - 1) for bGrB in range(Ep8u)]
ME7d = [YKHO._storage[or8S] for or8S in k52S]
return ME7d | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XO44(YKHO):\n pass",
"def cQJh(YKHO):\n Wc9F = []\n for YRbF in Ni9Y(YKHO.minibatch_size):\n Wc9F.append(YKHO.experiences[qukk(0, len(YKHO.experiences))])\n return oyIN.asarray(Wc9F)",
"def mvm2(YKHO, Ep8u=64):\n return tuKI.sample(YKHO.memory, Ep8u)",
"def UVgs(YKHO):\n Ep8u = m... | [
"0.78110474",
"0.7638188",
"0.71348554",
"0.708761",
"0.7063213",
"0.70081747",
"0.69747835",
"0.6946321",
"0.69079083",
"0.68765277",
"0.68173116",
"0.67345333",
"0.6733207",
"0.67210984",
"0.6699259",
"0.66791505",
"0.6635271",
"0.66320235",
"0.66320235",
"0.66273504",
"0.6... | 0.0 | -1 |
Sample a batch of experiences. | def bbDh(YKHO, Ep8u):
k52S = [tuKI.randint(0, len(YKHO._storage) - 1) for bGrB in range(Ep8u)]
k52S = [tuKI.randint(0, len(YKHO._storage) - 1) for bGrB in range(Ep8u)]
ME7d = [YKHO._storage[or8S] for or8S in k52S]
return ME7d | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XO44(YKHO):\n pass",
"def cQJh(YKHO):\n Wc9F = []\n for YRbF in Ni9Y(YKHO.minibatch_size):\n Wc9F.append(YKHO.experiences[qukk(0, len(YKHO.experiences))])\n return oyIN.asarray(Wc9F)",
"def mvm2(YKHO, Ep8u=64):\n return tuKI.sample(YKHO.memory, Ep8u)",
"def UVgs(YKHO):\n Ep8u = m... | [
"0.78110725",
"0.7638219",
"0.7134891",
"0.7087627",
"0.70632595",
"0.70081973",
"0.6974804",
"0.6946372",
"0.69079775",
"0.6876572",
"0.68173546",
"0.6734587",
"0.6733261",
"0.6721151",
"0.66993093",
"0.667918",
"0.663532",
"0.6632073",
"0.6632073",
"0.6627353",
"0.6627353",... | 0.0 | -1 |
Serves up the home page | def _MNe():
return WsL5.render_template('index.html', **globals()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kZiy():\n return TvZl('homepage.html')",
"def kZiy():\n return TvZl('home.html')",
"def kZiy():\n return TvZl('index.html')",
"def kZiy():\n print('route-/home')\n return TvZl('index.html', title='Home Page', year=qcWV.now().year)",
"def C_QL():\n return TvZl('home.html')",
"def kZi... | [
"0.81892866",
"0.81651354",
"0.8146009",
"0.8142494",
"0.8086806",
"0.80672956",
"0.80125356",
"0.7983545",
"0.7978545",
"0.7975516",
"0.79671115",
"0.79575944",
"0.795113",
"0.7950454",
"0.79408383",
"0.7932674",
"0.7931006",
"0.79274523",
"0.79261076",
"0.7922729",
"0.79227... | 0.0 | -1 |
Determine 3D coordinates of rupture bounds | def S9HO(YKHO, sGyP):
if isinstance(YKHO, (wQdj, gsvL)):
VlCc = [0, 1, 3, 2, 0]
k_Cy = sGyP.surface.corner_lons[VlCc]
LD1b = sGyP.surface.corner_lats[VlCc]
fz7m = sGyP.surface.corner_depths[VlCc]
elif isinstance(YKHO, (jTgS, z3JM)):
rR8k = sGyP.surface.mesh
zDLE, ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def WLz6(YKHO):\n return [xxZq(YKHO._bounds.x0, YKHO._bounds.y0, YKHO._depth), xxZq(YKHO._bounds.x0, YKHO._bounds.y1, YKHO._depth), xxZq(YKHO._bounds.x1, YKHO._bounds.y1, YKHO._depth), xxZq(YKHO._bounds.x1, YKHO._bounds.y0, YKHO._depth)]",
"def UoHf(YKHO):\n return YKHO._bounds3D",
"def X7zS(YKHO):\n ... | [
"0.74622303",
"0.7285784",
"0.69172496",
"0.6813049",
"0.6663451",
"0.6599565",
"0.6567299",
"0.6522375",
"0.6517367",
"0.6469959",
"0.6443222",
"0.63843626",
"0.6336341",
"0.63142323",
"0.62985504",
"0.6297979",
"0.6294514",
"0.6279162",
"0.6232503",
"0.6231984",
"0.621464",... | 0.6580861 | 6 |
Checks the buffered data is not overlapped. Checks the data written by hardware in this period does not overlap with data to be dumped in the last period. Period 0 1 2 3 4 | def It0t(YKHO):
if YKHO._last_last_page_count is not None:
IIDB = YKHO._current_page_count - YKHO._last_last_page_count
G9jH.info('buffered_pages: 0x%x, max: 0x%x', IIDB, YKHO._adump.MAX_DUMP_PAGES)
if IIDB > YKHO._adump.MAX_DUMP_PAGES:
raise XCcH('Bufferred pages %s more than pa... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def IPtk(HasU):\n HCFJ = oyIN.diff(HasU.events[:, 0])\n KnxT = int((HasU.tmax - HasU.tmin) * HasU.info['sfreq'])\n return HCFJ.min() < KnxT",
"def hqA6(YKHO, _owh):\n pass",
"def bXzr(YKHO):\n YKHO.log_time(start=YKHO.start_before, end=YKHO.start_inside, pause=119)\n x9QY = YKHO.use_checkover... | [
"0.60924",
"0.6022828",
"0.5719427",
"0.56806463",
"0.5619647",
"0.5558665",
"0.55095065",
"0.5504151",
"0.5495382",
"0.5481129",
"0.54699403",
"0.54646605",
"0.54415584",
"0.5428743",
"0.5364743",
"0.5317434",
"0.5302065",
"0.52962923",
"0.5282396",
"0.5261509",
"0.5244811",... | 0.6827812 | 0 |
Set input to the neuron. | def Zz_l(YKHO, _Q_Z):
if isinstance(_Q_Z, float):
_Q_Z = oyIN.ones((YKHO.n_points,)) * _Q_Z
assert len(_Q_Z) >= YKHO.n_points
YKHO.ext_current = _Q_Z | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def AZse(YKHO, UnuI):\n if YKHO.node_type == o7DN.INPUT_NODE:\n YKHO.inputValue = UnuI\n YKHO.outputValue = UnuI",
"def AZse(YKHO, **qIxc):\n YKHO.inputWasSet = True\n YKHO.inputNode.setOutput(**qIxc)",
"def Zz_l(YKHO, input):\n pass",
"def Zz_l(YKHO, input):\n pass",
"def Zz_l... | [
"0.7890628",
"0.77149963",
"0.76798093",
"0.76798093",
"0.76798093",
"0.76798093",
"0.74248946",
"0.73063666",
"0.7295206",
"0.7246378",
"0.719531",
"0.719531",
"0.719531",
"0.7071615",
"0.70496845",
"0.6993885",
"0.6966268",
"0.6913806",
"0.6899966",
"0.6870218",
"0.6862961"... | 0.0 | -1 |
This code is taken from lecture slide. Determine the start and end pointer and pass it to quick_sort_aux function. | def rzJZ(YKHO, qw7D: ArrayList[Tuple]) -> None:
yKcO = 0
Os4s = len(qw7D) - 1
YKHO.quick_sort_aux(qw7D, yKcO, Os4s) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DRu6(YKHO, qw7D: ArrayList[Tuple], yKcO: int, Os4s: int) -> None:\n if yKcO < Os4s:\n zXil = YKHO.partition(qw7D, yKcO, Os4s)\n YKHO.quick_sort_aux(qw7D, yKcO, zXil - 1)\n YKHO.quick_sort_aux(qw7D, zXil + 1, Os4s)",
"def rNe0(ezWE, yKcO, Os4s):\n if yKcO >= Os4s:\n return\n ... | [
"0.85239834",
"0.8397058",
"0.8035328",
"0.79574454",
"0.76734483",
"0.76043653",
"0.75396013",
"0.75089246",
"0.7462629",
"0.74396455",
"0.7400226",
"0.7396715",
"0.73923814",
"0.7365484",
"0.7293797",
"0.72642875",
"0.72389704",
"0.7224654",
"0.72076994",
"0.720221",
"0.719... | 0.6876082 | 50 |
Function to split and shuffle a dataset into train, validation and test splits. | def FJfc(nPrm, Crrw, iOSb=0.8, Lb_h=0.0, X6Jp=0.0):
def p06G(jRjU, qVzR, u31v, DDy2):
W_Q_ = jRjU.shape[0]
tShU = int(W_Q_ * u31v)
dy20 = Acvy(DDy2, size=tShU, replace=False)
Rqh2 = list(set(DDy2) - set(dy20))
return (jRjU[dy20], qVzR[dy20], dy20, Rqh2)
lWPh = nPrm
a... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bHtP(__n6, NI2E=0.2, igb0=123):\n __n6 = oyIN.asarray(__n6)\n eAYh = len(__n6)\n NI2E = int(eAYh * NI2E) if isinstance(NI2E, float) else NI2E\n print('Total number of samples: {}'.format(eAYh))\n print('Test data size: {}'.format(NI2E))\n if igb0:\n oyIN.random.seed(igb0)\n jp5x = o... | [
"0.8143381",
"0.79736245",
"0.78905344",
"0.78033024",
"0.77139306",
"0.7710111",
"0.7695237",
"0.76858187",
"0.76597613",
"0.76566184",
"0.7611821",
"0.7607117",
"0.7596017",
"0.75937533",
"0.75430715",
"0.75245935",
"0.7471585",
"0.746444",
"0.74332887",
"0.7424551",
"0.741... | 0.0 | -1 |
Return a dictionary built from the combination of defaults, kwargs, and the attributes of the given object. | def lhy8(YEnM, jeGQ, **B2fa):
zTi3 = dSic(YEnM)
HkzR = Gclg.copy()
HkzR.update(zTi3)
HkzR.update(B2fa)
for d7pR in jeGQ:
if d7pR not in HkzR:
raise ValueError('Please provide ' + str(d7pR))
return HkzR | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vhLG(YEnM, bPmE):\n return dict([[YRbF[0], getattr(YEnM, YRbF[0])] for YRbF in bPmE.defaults if isinstance(YRbF, list) or isinstance(YRbF, tuple)])",
"def mnws(YEnM, a5Jp):\n U5bT = {}\n if len(a5Jp) > 0:\n for hkS8 in a5Jp:\n U5bT[hkS8] = getattr(YEnM, hkS8)\n return U5bT",
"... | [
"0.7033132",
"0.68756944",
"0.68366826",
"0.67161566",
"0.6622328",
"0.6615357",
"0.6615357",
"0.6598574",
"0.6551214",
"0.65313756",
"0.6526623",
"0.65159214",
"0.6438833",
"0.641337",
"0.63982993",
"0.63627017",
"0.63149",
"0.63136387",
"0.629699",
"0.62740535",
"0.6260343"... | 0.0 | -1 |
Returns the url to access a particular link instance. | def hlzF(YKHO):
return Rmd_('link-detail', args=[str(YKHO.id)]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sMPI(YKHO) -> str:\n return YKHO._link_url",
"def HYjU(YKHO):\n return YKHO.link",
"def HYjU(YKHO):\n return YKHO.link",
"def HYjU(YKHO):\n return YKHO.link",
"def HYjU(YKHO):\n return YKHO.link",
"def LvtP(YEnM):\n return YEnM.get_absolute_url()",
"def HYjU(YKHO):\n return YKH... | [
"0.76843274",
"0.7653154",
"0.7653154",
"0.7653154",
"0.7653154",
"0.7563872",
"0.7512564",
"0.7512564",
"0.7435195",
"0.73729825",
"0.73729825",
"0.7314321",
"0.73093337",
"0.71466815",
"0.71466815",
"0.71466815",
"0.707116",
"0.7060731",
"0.70600593",
"0.70413405",
"0.70413... | 0.64364505 | 81 |
Given a window_idx corresponding to a split_idx, return the data up to that split value starting from the split_idx 1 value. | def Y8lN(YKHO, BLRE, OyT4=True):
AA_C = YKHO.splits[BLRE]
if BLRE == 0:
NxrV = YKHO.full_df[:AA_C]
else:
Dvh2 = YKHO.splits[BLRE - 1]
NxrV = YKHO.full_df[Dvh2:AA_C]
if OyT4:
bySB, Crrw = YKHO.split_df(NxrV, YKHO.column_mapping['target'])
return (bySB, Crrw)
el... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QYk_(YKHO, BLRE):\n return YKHO.splits[BLRE]",
"def bIR8(nPrm, lpha):\n oeNL = len(nPrm) / 2\n return",
"def HUgD(YKHO, KnxT: int=None):\n nPrm, HnP_, KnxT = YKHO.bulk_data_for_moving_window(YKHO.data, window=KnxT)\n yvT9 = []\n d6pt = []\n for r845 in range(HnP_):\n yvT9.append... | [
"0.7154172",
"0.6303416",
"0.6264585",
"0.6231959",
"0.6075455",
"0.6056075",
"0.60388964",
"0.6010381",
"0.6010253",
"0.6001723",
"0.59578687",
"0.59578687",
"0.59557736",
"0.59123534",
"0.5884719",
"0.583411",
"0.5796506",
"0.5744285",
"0.5744002",
"0.5744002",
"0.5735343",... | 0.6885389 | 1 |
Splits the features from labels in a dataframe, returns both | def Zv6i(jQ3Z, aQda):
return (jQ3Z.drop(aQda, axis=1), jQ3Z[aQda]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LZIJ(LMLK, ksLb, aLVi):\n return (LMLK.loc[:, (LMLK.columns != ksLb) & (LMLK.columns != aLVi)], LMLK[ksLb])",
"def mxNV(bOBl):\n return (bOBl[bOBl.columns[:-1]], bOBl[bOBl.columns[-1]])",
"def klGW(KxLt, jQ3Z, lpha):\n V22M = [rdlD.text for YRbF, rdlD in jQ3Z.iterrows()]\n if lpha == 'train':\n... | [
"0.7619091",
"0.74669355",
"0.7282185",
"0.70919365",
"0.6871121",
"0.6840568",
"0.67863137",
"0.6758272",
"0.6624591",
"0.6582845",
"0.6532063",
"0.6503599",
"0.6464577",
"0.64530766",
"0.64310586",
"0.64310586",
"0.6426724",
"0.64081466",
"0.63711",
"0.6364006",
"0.6322768"... | 0.66163576 | 9 |
Test client is able to process a valid request This test passes when each sent request returns a status code of 200 and no errors are raised | def qq2P(YKHO):
YKHO.assertEqual(YKHO.client.send_request(9), (200, 255))
YKHO.assertEqual(YKHO.client.send_request('3'), (200, 255)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ieOq(YKHO):\n assert YKHO.response.status_code == 201",
"def kKne(YKHO):\n bD7m = 'https://httpstat.us/200'\n Aofo = y7BL(bD7m)\n YKHO.assertEqual(Aofo, 200)",
"def XD9p(YKHO):\n QePW = ZrWc.Request.blank('/')\n geh0 = QePW.get_response(YKHO.app)\n YKHO.assertEqual(200, geh0.status_int... | [
"0.73920876",
"0.7249727",
"0.7227641",
"0.7227641",
"0.7202423",
"0.72014797",
"0.7065957",
"0.699465",
"0.6908071",
"0.6882146",
"0.68721884",
"0.68576866",
"0.68574613",
"0.68200237",
"0.6812045",
"0.6800179",
"0.67950547",
"0.6789304",
"0.6770858",
"0.6760393",
"0.6746650... | 0.6533318 | 82 |
Test client is able to handle a request containing invalid input This test passes when each sent request returns a value of None | def Wx94(YKHO):
YKHO.assertEqual(YKHO.client.send_request('nine'), None)
YKHO.assertEqual(YKHO.client.send_request(-3), None) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def EJ4H(YKHO):\n yAhP = VNUm()\n yAhP.add_error('some_param', 'some_message')\n Sa43 = PgXk()\n geh0 = Sa43.execute(yAhP)\n YKHO.assertFalse(geh0)\n YKHO.assertEqual(geh0.type, FAd6.PARAMETERS_ERROR)\n YKHO.assertEqual(geh0.message, 'some_param: some_message')",
"def yCvN():\n eiwY()\n ... | [
"0.7340461",
"0.7294322",
"0.7220884",
"0.71580184",
"0.7027112",
"0.702644",
"0.6996915",
"0.69812167",
"0.69723916",
"0.69690555",
"0.6915619",
"0.69149196",
"0.6911015",
"0.68844867",
"0.6855118",
"0.68537015",
"0.6819048",
"0.6815734",
"0.6800169",
"0.67997515",
"0.675438... | 0.77190566 | 0 |
The first demand measurement at midnight is missing on the first date returned, so we back up to the previous day. | def NYMB(yKcO: datetime, Sm0u: Optional[int]=1) -> qcWV:
return yKcO - fCoM(days=Sm0u) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FxRR(YKHO):\n return",
"def LAdW(YKHO, x0eS, CjKC, ROt1):\n _c1T = qcWV.datetime(2001, x0eS, CjKC)\n d6pt = oyIN.where(YKHO.demand.index.to_pydatetime() == _c1T)[0][0] - 1\n tyeH = YKHO.getPredLoad(d6pt, ROt1)\n return tyeH",
"def DDfq(WZsM):\n try:\n Ylbp = min(WZsM.payment_date).... | [
"0.6019959",
"0.6018244",
"0.5786379",
"0.5590969",
"0.5571123",
"0.5562986",
"0.55605155",
"0.54727256",
"0.5431459",
"0.5423571",
"0.5423023",
"0.5423023",
"0.5385681",
"0.53467774",
"0.5344118",
"0.53301686",
"0.52847534",
"0.5281675",
"0.5280297",
"0.52706265",
"0.5237922... | 0.0 | -1 |
Centroid an image weighted sum of pixels | def TYc5(_avc):
VXjJ = _avc.copy()
VXjJ[VXjJ < 0] = 0.0
FXpT, rMH_ = oyIN.indices(VXjJ.shape)
i9Rn = oyIN.nansum(VXjJ)
Wjb0 = oyIN.dot(oyIN.ravel(FXpT), oyIN.ravel(VXjJ)) / i9Rn
KQji = oyIN.dot(oyIN.ravel(rMH_), oyIN.ravel(VXjJ)) / i9Rn
return (Wjb0, KQji) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def e6ux(y5bX, _mSQ):\n return XTiz.dot(XTiz.transpose(y5bX), _mSQ) / sum(_mSQ)",
"def Q1RL(YKHO):\n pass",
"def e6ux(VXjJ):\n VXjJ = oyIN.asanyarray(VXjJ)\n KEH4 = tuple(range(VXjJ.ndim))\n eKGI = []\n for YRbF in KEH4:\n YT0d = tuple((WKvO for WKvO in KEH4 if WKvO != YRbF))\n ... | [
"0.7371301",
"0.7274707",
"0.71434474",
"0.70023096",
"0.6982254",
"0.69705653",
"0.6883716",
"0.68371236",
"0.68268317",
"0.6825898",
"0.6776963",
"0.67755514",
"0.67315054",
"0.670762",
"0.6697903",
"0.65781885",
"0.65709823",
"0.65458494",
"0.654456",
"0.65310705",
"0.6513... | 0.6917965 | 6 |
Gets string representing the channel, e.g. Amazon bucket and keyname that could be used for upload. Needed mainly in diagnostics purposes | def kzmQ(YKHO):
return YKHO.__swift.getUploadPath() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YwkQ(YKHO) -> str:\n return YKHO._data[GDa9.CHANNEL_KEY]",
"def R5yJ(YKHO) -> str:\n return YKHO._values.get('channel_name')",
"def R5yJ(YKHO) -> qe4Y.Output[h8nf[str]]:\n return qe4Y.get(YKHO, 'channel_name')",
"def YwkQ(YKHO) -> str:\n return YKHO._channel",
"def R5yJ(YKHO):\n return Y... | [
"0.78780824",
"0.77808803",
"0.7584837",
"0.74490327",
"0.7421408",
"0.7267135",
"0.7267135",
"0.7201589",
"0.7124316",
"0.7120075",
"0.71028364",
"0.70399714",
"0.693971",
"0.6918623",
"0.6858965",
"0.6831488",
"0.6797767",
"0.6769613",
"0.6751177",
"0.6748665",
"0.6748665",... | 0.0 | -1 |
r""" number of input features + dimension of network inputs | def VQNc(YKHO) -> int:
return YKHO.in_features + YKHO.input_dim | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def qepc(YKHO):\n return len(YKHO.inputs)",
"def dA2M(YKHO):\n Sqw_ = YKHO.n_task_dims\n Sqw_ *= 2 if YKHO.calc_acc else 3\n if YKHO.use_covar:\n Sqw_ += Sqw_ ** 2\n return Sqw_",
"def eHp6(YKHO) -> int:\n return YKHO.module.input_size",
"def ROaS(YKHO):\n return YKHO.shape[0]",
... | [
"0.7514312",
"0.74698627",
"0.7467261",
"0.7413311",
"0.7413311",
"0.7384302",
"0.73582214",
"0.73324245",
"0.7318032",
"0.7307722",
"0.7220399",
"0.7209612",
"0.7197247",
"0.7179161",
"0.7168117",
"0.7167294",
"0.7158848",
"0.71510565",
"0.7146942",
"0.71117127",
"0.7106968"... | 0.82999 | 0 |