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 |
|---|---|---|---|---|---|---|
Check if a stack has any elements. | def FBfn(YKHO):
return len(YKHO.original) == 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lsmZ(E5BI):\n return len(E5BI.elements) == 0",
"def A4KR(YKHO):\n return YKHO.stack == []",
"def FBfn(YKHO):\n return YKHO.stack == []",
"def FBfn(YKHO):\n return YKHO.stack == []",
"def FBfn(YKHO):\n return YKHO.stack == []",
"def FBfn(YKHO):\n return YKHO.stack == []",
"def FBfn... | [
"0.84833413",
"0.8062782",
"0.8053619",
"0.8010404",
"0.8010404",
"0.8010404",
"0.8004628",
"0.7996881",
"0.7996881",
"0.7957979",
"0.7957979",
"0.78459066",
"0.77751076",
"0.77751076",
"0.77433574",
"0.7709336",
"0.7703936",
"0.7673486",
"0.7627959",
"0.76231253",
"0.7596473... | 0.0 | -1 |
Perform a single timestep of computation in decoder LSTM | def YPaw(YKHO, WKvO, RGyR, qfB9, weRr, PHBW=None, R6ta=False):
QWkn, dDw6 = YKHO.decoder_lstm(WKvO, RGyR)
oQoT, xjpw = YUXX.dot_prod_attention(QWkn, qfB9, weRr, mask=PHBW)
k3oa = ht2j.tanh(YKHO.att_vec_linear(ht2j.cat([QWkn, oQoT], 1)))
k3oa = YKHO.dropout(k3oa)
if R6ta:
return ((QWkn, dDw6)... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YjYw(ITS7, YPNK, CswK, _jT8):\n R288 = YPNK\n BUMv = ITS7 >= Amsp\n Pt1K = ZylS.reduce_all(BUMv)\n with ZylS.name_scope('prepare_next_cell_state'):\n if YPNK is None:\n MCZZ = TIiT\n else:\n MCZZ = CswK\n with ZylS.name_scope('prepare_next_input'):\n if... | [
"0.6998444",
"0.6383692",
"0.63680035",
"0.6300501",
"0.62973076",
"0.6292891",
"0.6234048",
"0.6177197",
"0.61529464",
"0.61312354",
"0.6125464",
"0.6115213",
"0.61009836",
"0.6089895",
"0.60852385",
"0.60767895",
"0.60606974",
"0.6057954",
"0.60482216",
"0.6035165",
"0.6027... | 0.0 | -1 |
Post / Add a new question | def WzOi():
Xg_g = Zul5()
WbAn = QePW.get_json(force=True)
if 'question' not in WbAn.keys():
return uend.custom_response(400, 'Bad Request', "Request must contain 'question' data")
bAls = WbAn['question'].strip()
if len(bAls) == 0:
return uend.custom_response(400, 'Bad Request', 'Pro... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wWM5():\n if QePW.method == 'POST':\n if not QePW.form['question'] or not QePW.form['answer']:\n Dwep('question not added, invalid question/answer', 'error')\n return vKnz(nKyW('main.add_question'))\n vexM = Y4Gy(question=QePW.form['question'], answer=QePW.form['answer'])... | [
"0.7896681",
"0.7835216",
"0.7806824",
"0.779619",
"0.7731285",
"0.76669055",
"0.76479924",
"0.760507",
"0.7447298",
"0.7440744",
"0.7438193",
"0.7430449",
"0.7428961",
"0.7382436",
"0.7347284",
"0.73468924",
"0.73181635",
"0.7263628",
"0.72172016",
"0.7205693",
"0.71990013",... | 0.7920145 | 0 |
Add an answer to a specific question | def QgmR(JVBp):
Xg_g = Zul5()
WbAn = QePW.get_json(force=True)
if 'answer' not in WbAn.keys():
return uend.custom_response(400, 'Bad Request', "Request must contain 'answer' data")
ANfV = WbAn['answer'].strip()
if len(ANfV) == 0:
return uend.custom_response(400, 'Bad Request', 'Provi... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wWM5(YKHO, bAls, ANfV):\n K4YQ = Y4Gy(bAls, ANfV)\n YKHO.questions.append(K4YQ)",
"def wWM5(YKHO, bAls, ANfV):\n YKHO.questions.append(super(RoxL, YKHO).__init__(bAls, ANfV))",
"def Re9J(YKHO, bAls, ANfV):\n qwR4 = YKHO.find_question(bAls)\n if qwR4 == -1:\n return False\n YKHO.con... | [
"0.79363",
"0.7922325",
"0.7920315",
"0.78003496",
"0.7712739",
"0.76886106",
"0.766132",
"0.7656894",
"0.75973254",
"0.7546783",
"0.7504685",
"0.7428615",
"0.73755413",
"0.7331327",
"0.7315138",
"0.7273608",
"0.71981573",
"0.7193202",
"0.71455896",
"0.71140265",
"0.7060944",... | 0.6848266 | 29 |
Performs a `get_or_create` on a model with this ID | def lac1(YKHO):
z3tO = None
if YKHO.group_id:
z3tO = getattr(YKHO.group_id, 'model', None)
if not z3tO:
z3tO = YKHO.group_id.save_model()
jMBO = {'election_type': YKHO.election_type, 'election_title': YKHO.to_title(), 'election_subtype': YKHO.subtype, 'organisation': YKHO.organis... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cDO8(NCls: Session, C3ST, **B2fa):\n KAOR = NCls.query(C3ST).filter_by(**B2fa).first()\n if KAOR:\n return KAOR\n else:\n KAOR = C3ST(**B2fa)\n NCls.add(KAOR)\n NCls.commit()\n return KAOR",
"def cDO8(C3ST, **B2fa):\n P4t4.logger.info(f'Get of create object of {... | [
"0.7563124",
"0.7465618",
"0.73935723",
"0.72145134",
"0.7155469",
"0.7131056",
"0.7097445",
"0.7011607",
"0.700595",
"0.6934742",
"0.69171107",
"0.6879392",
"0.68528485",
"0.6833042",
"0.6828047",
"0.6809761",
"0.6778441",
"0.6763478",
"0.6763478",
"0.674709",
"0.6745807",
... | 0.0 | -1 |
Build a list of breadcrumbs leading up to and including the given local path. | def st2S(YKHO, pmON):
st2S = [{'url': yTbG(YKHO.base_url, YKHO._localfile_path), 'name': 'home'}]
st2S.extend(super(Njhl, YKHO).breadcrumbs(pmON, YKHO._localfile_path))
return st2S | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def st2S():\n NO3f = []\n for bTKY in Tw86.list_path(HmXT, zOGz) or []:\n NO3f += bTKY.dynamic_list\n return NO3f",
"def st2S(pmON):\n st2S = []\n bD7m = '/'\n for Q7me in pmON.strip('/').split('/'):\n if Q7me.endswith('.md'):\n bD7m += Q7me\n else:\n ... | [
"0.6745215",
"0.65295666",
"0.62933826",
"0.60657036",
"0.60657036",
"0.5866871",
"0.5823521",
"0.5813047",
"0.5759039",
"0.57573366",
"0.57396895",
"0.56182593",
"0.5617242",
"0.5611049",
"0.5599579",
"0.5550084",
"0.55399454",
"0.5492299",
"0.5465845",
"0.54356706",
"0.5425... | 0.68184006 | 0 |
Test to see if reponse data is gzipped | def WRIQ(YKHO, geh0):
if geh0.info().get('Content-Encoding') == 'gzip':
NRcB = kJm3(geh0.read())
eHNT = lGU7.GzipFile(fileobj=NRcB)
nPrm = eHNT.read()
else:
nPrm = geh0.read()
return nPrm | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P9BO(hGN5):\n if len(hGN5) > 3 and ord(hGN5[0:1]) == 31 and (ord(hGN5[1:2]) == 139) and (ord(hGN5[2:3]) == 8):\n return True\n return False",
"def suVM(YKHO):\n raise NotImplementedError()",
"def umqO(E8iq):\n return E8iq.contentEncoding and E8iq.contentEncoding.lower().endswith('gzip')"... | [
"0.7745478",
"0.76576173",
"0.7267386",
"0.7254477",
"0.7129719",
"0.70377624",
"0.69699687",
"0.69687426",
"0.68321484",
"0.68285996",
"0.6729022",
"0.67212266",
"0.6680248",
"0.66027594",
"0.6562535",
"0.6534827",
"0.6532934",
"0.65038466",
"0.6430091",
"0.6283189",
"0.6279... | 0.58099127 | 71 |
Randomly jitter points. jittering is per point. | def tj8F(YKHO, J1hN, WTkW=0.01, vJPk=0.05):
tjUW, ywwl, Nq1b = J1hN.shape
assert vJPk > 0
WLXc = oyIN.clip(WTkW * oyIN.random.randn(tjUW, ywwl, Nq1b), -1 * vJPk, vJPk)
WLXc += J1hN
return WLXc | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bHg_(YKHO, aM8h=1.0):\n for YFMp in YKHO.stars:\n YFMp.x += tuKI.uniform(-0.1, 0.1) * aM8h\n YFMp.y += tuKI.uniform(-0.1, 0.1) * aM8h",
"def bHg_(WKvO, Mkmy=0.1):\n return WKvO + oyIN.random.rand(*WKvO.shape) * oyIN.std(WKvO)[None, :] * Mkmy",
"def bHg_(VOlW, aM8h):\n return VOlW + V... | [
"0.75472695",
"0.7410611",
"0.7287109",
"0.694834",
"0.6911661",
"0.68838114",
"0.68357635",
"0.6556249",
"0.6437521",
"0.63828707",
"0.63305485",
"0.6319276",
"0.6313966",
"0.6290827",
"0.61949134",
"0.61942804",
"0.619288",
"0.6158329",
"0.6111379",
"0.6110583",
"0.6109834"... | 0.5933445 | 36 |
Get absolute path to resource, works for dev and for PyInstaller | def JFat(t_yv):
try:
XSj5 = HwRy._MEIPASS
except Exception:
XSj5 = Hy7s.path.abspath('.')
return Hy7s.path.join(XSj5, t_yv) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gZBG():\n return khtY.abspath(khtY.join(khtY.dirname(xAKo), 'resources') + khtY.sep)",
"def JFat(Qth0):\n if getattr(HwRy, 'frozen', None):\n ObT1 = HwRy._MEIPASS\n else:\n ObT1 = Hy7s.path.join(Hy7s.getcwd())\n return Hy7s.path.join(ObT1, Qth0)",
"def JFat(t_yv):\n try:\n ... | [
"0.86645055",
"0.8190357",
"0.8175001",
"0.8163073",
"0.80863976",
"0.80863976",
"0.80863976",
"0.80863976",
"0.8086095",
"0.80784917",
"0.8077746",
"0.8073863",
"0.8065137",
"0.80625504",
"0.80625504",
"0.80625504",
"0.80625504",
"0.80625504",
"0.80625504",
"0.80625504",
"0.... | 0.80456185 | 29 |
This function returns the loss defined by intersection over union | def Eztb(ZHfW: torch.Tensor, pan_: torch.Tensor):
oTE9, bGrB = ht2j.unbind(ZHfW, dim=3)
return OPAs(oTE9, pan_) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Gvnp(ptT_, bf9h):\n try:\n iQin = EIgG(ptT_, bf9h)\n b65I = iKn5(ptT_, bf9h)\n return iQin / b65I\n except:\n return 0",
"def Gvnp(nvEb, uxhZ):\n b65I = rSWe(nvEb).union(rSWe(uxhZ)).area\n C7_8 = rSWe(nvEb).intersection(rSWe(uxhZ)).area\n return C7_8 / b65I",
"def... | [
"0.66181016",
"0.65920633",
"0.6337373",
"0.62815803",
"0.6256324",
"0.61683077",
"0.61683077",
"0.61170787",
"0.60871017",
"0.60189617",
"0.60075164",
"0.5972248",
"0.59542537",
"0.59490114",
"0.5930817",
"0.5917034",
"0.5911579",
"0.59110796",
"0.59045523",
"0.59045523",
"0... | 0.0 | -1 |
Recursively update dict value | def DmV4(Csk6, QdZT):
for G1Hx, Ty9i in QdZT.items():
if isinstance(Ty9i, dict):
Csk6[G1Hx] = DmV4(Csk6.get(G1Hx, {}), Ty9i)
else:
Csk6[G1Hx] = Ty9i
return Csk6 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cM0y():\n bJN7 = dict(subdict=dict(to_update=1))\n Dbmo = dict(subdict=dict(to_update=2))\n C09e(bJN7, Dbmo)\n assert bJN7 == dict(subdict=dict(to_update=2))",
"def uMS1(Csk6, P6bq):\n for G1Hx, Ty9i in P6bq.items():\n if isinstance(Ty9i, g760.Mapping):\n Mkmy = uMS1(Csk6.get... | [
"0.76114696",
"0.7468123",
"0.74396944",
"0.74004203",
"0.73973596",
"0.72303593",
"0.7192698",
"0.71728057",
"0.7165057",
"0.7162737",
"0.71079814",
"0.7099859",
"0.708135",
"0.7028223",
"0.6967189",
"0.6904763",
"0.6875007",
"0.6869065",
"0.6812379",
"0.680806",
"0.67679554... | 0.65846163 | 33 |
This default evaluation function just returns the score of the state. The score is the same one displayed in the Pacman GUI. This evaluation function is meant for use with adversarial search agents (not reflex agents). | def fHT3(rfNN):
return rfNN.getScore() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fHT3(Ov5A):\n return Ov5A.getScore()",
"def fHT3(Ov5A):\n return Ov5A.getScore()",
"def fHT3(Ov5A):\n return Ov5A.getScore()",
"def b7La(YKHO, QTBn):\n iBIi, oyg0, YPaw = QTBn\n return phK_(oyg0, iBIi)",
"def fHT3(rfNN):\n return rfNN.getScore()",
"def fHT3(rfNN: GameState):\n re... | [
"0.8075455",
"0.8054519",
"0.8054519",
"0.79372096",
"0.76785314",
"0.766229",
"0.7643951",
"0.7635007",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
"0.7554659",
... | 0.7594506 | 9 |
Copy data from S3 buckets into Redshift staging tables using the queries in copy_table_queries | def Ua0J(DpUl, w2B8):
for xDcj in znyy:
DpUl.execute(xDcj)
w2B8.commit() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Ua0J(DpUl, w2B8):\n GPtr = enR0.ConfigParser()\n GPtr.read('dwh.cfg')\n for xDcj in AQXq:\n DpUl.execute(xDcj)\n w2B8.commit()\n ABwj = GPtr.get('S3', 'S3_BUCKET')\n sjXb = [('staging_visit', PObX), ('staging_demographics', IaF5), ('staging_oilprice', WD9b), ('staging_tempbystate',... | [
"0.7437398",
"0.731583",
"0.67585045",
"0.6734226",
"0.6733653",
"0.67059964",
"0.66777295",
"0.66690725",
"0.66421574",
"0.6628266",
"0.6548298",
"0.6547557",
"0.65437835",
"0.6538009",
"0.6524665",
"0.65168715",
"0.64748764",
"0.6463343",
"0.6447626",
"0.6443034",
"0.640063... | 0.6654115 | 8 |
Return data interim path, i.e. repobase/data/interim. Returns | def OyQC():
return Hy7s.path.join(slOJ(), 'interim') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def i0XC():\n i0XC = IvYx(gzes('data', 'miri_data.fits'))\n return i0XC",
"def s8df(YKHO, i0XC):\n return Hy7s.path.join(YKHO.get_path(YKHO.config['data']), i0XC)",
"def s8df():\n QHUq = RUFc(xAKo)\n return TLI7(QHUq)",
"def OyQC(YKHO):\n return YKHO.data_path",
"def GQhq(YKHO):\n pass... | [
"0.7116225",
"0.6573299",
"0.65455556",
"0.65329075",
"0.6366245",
"0.635866",
"0.6282201",
"0.6256524",
"0.62056774",
"0.61796135",
"0.61708635",
"0.61686313",
"0.61516285",
"0.6136734",
"0.6136734",
"0.6130287",
"0.612448",
"0.61149126",
"0.6105318",
"0.60938925",
"0.607780... | 0.7532336 | 0 |
Compute softmax values for each sets of scores in x. | def N93T(G1Hx):
dKQN = oyIN.exp(G1Hx - oyIN.max(G1Hx))
return dKQN / dKQN.sum(axis=0) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oSvh(WKvO):\n S2MS = []\n if oyIN.array(WKvO).ndim == 1:\n hrCc = oyIN.exp(WKvO)\n RmXN = oyIN.sum(hrCc)\n xzMv = hrCc / RmXN\n dzye = xzMv\n else:\n dzye = oyIN.exp(cCrA) / oyIN.sum(oyIN.exp(cCrA), axis=0)\n return dzye",
"def N93T(WKvO):\n j1LR = oyIN.exp(o... | [
"0.80113125",
"0.77607703",
"0.77607703",
"0.7687368",
"0.76707524",
"0.76605",
"0.76571554",
"0.76571554",
"0.76571554",
"0.76571554",
"0.76571554",
"0.76571554",
"0.76571554",
"0.76397043",
"0.762786",
"0.7551623",
"0.7532752",
"0.74565",
"0.73242354",
"0.73171765",
"0.7298... | 0.0 | -1 |
Pick a random point between lower and upper bound This function supports both int or list | def AZ3g(LSh8, CN9P):
if isinstance(LSh8, int) or isinstance(LSh8, float):
return tuKI.uniform(LSh8, CN9P)
if isinstance(LSh8, list):
assert len(LSh8) == len(CN9P), 'Random Point List Range Error'
return [tuKI.uniform(LSh8[YRbF], CN9P[YRbF]) for YRbF in range(len(LSh8))] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def qRtf():\n return (ajWY(0, 4), 2)",
"def qRtf():\n return (tuKI.randrange(100), tuKI.randrange(100))",
"def qRtf():\n return (tuKI.randrange(100), tuKI.randrange(100))",
"def qRtf():\n return (tuKI.randrange(100), tuKI.randrange(100))",
"def M_CK(yKcO, JCyR):\n return tuKI.randrange(yKcO,... | [
"0.73303664",
"0.722942",
"0.722942",
"0.722942",
"0.7207832",
"0.7207832",
"0.70652825",
"0.7061226",
"0.6994021",
"0.6925076",
"0.68933547",
"0.6867066",
"0.68370837",
"0.6834357",
"0.6770333",
"0.67684543",
"0.67681915",
"0.6751792",
"0.67467827",
"0.67381567",
"0.6731417"... | 0.80387604 | 0 |
Check if the code is running on Ipython notebook | def laio():
try:
_Fei = Zboo().config
if 'IPKernelApp' in _Fei:
return True
else:
return False
except NameError:
return False | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Qu0Q() -> bool:\n try:\n x6b6 = HwRy.modules['IPython']\n if 'IPKernelApp' not in x6b6.get_ipython().config:\n return False\n except:\n return False\n else:\n return True",
"def mDyP():\n return qhcZ() == 'jupyter'",
"def JPGf():\n JPGf = False\n if ... | [
"0.8799213",
"0.8774504",
"0.8732231",
"0.866299",
"0.8619772",
"0.8471671",
"0.83975226",
"0.83480054",
"0.83398587",
"0.8336256",
"0.8335387",
"0.83153886",
"0.8310176",
"0.8309741",
"0.8291788",
"0.82678175",
"0.8267496",
"0.8257912",
"0.82424355",
"0.81423914",
"0.8130367... | 0.84576106 | 6 |
Command line parser interface for automated WAM_ANNUAL_MAX and WAM_TREND CLI. | def QAF3():
yKcO = ITS7.perf_counter()
wvEv = j1Jz.ArgumentParser(description=f'WAM_ANNUAL_MAX&WAM_TREND ver. {BtDU}\n', add_help=True, epilog=TI0e.dedent(" Get Annual Max over a file collection\n and calculates the Sen's slope trend\n ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dCXb():\n wvEv = j1Jz.ArgumentParser(description='Bayesian neural networks demo.')\n uOe2 = wvEv.add_mutually_exclusive_group()\n uOe2.add_argument('--show', action='store_true', help='show the dataset')\n uOe2.add_argument('--mle', action='store_true', help='train a non-bayesian net using maximum ... | [
"0.63823605",
"0.6331848",
"0.63252777",
"0.6294569",
"0.6264542",
"0.62529874",
"0.62335324",
"0.62165844",
"0.6206931",
"0.61452633",
"0.610078",
"0.6092636",
"0.60811174",
"0.6074193",
"0.6069476",
"0.6068533",
"0.60616684",
"0.6059242",
"0.6051114",
"0.6029503",
"0.601679... | 0.6744463 | 0 |
Does the passed in user have permission to submit / view this form? | def SV11(YKHO, CBIr):
wbQo = getattr(gCuF, 'XFORMS_AUTHENTICATION_CHECKER', 'rapidsms_xforms.models.can_user_use_form')
if wbQo:
QH_H = fQIM(wbQo)
return QH_H(CBIr, YKHO)
return True | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dB_d(QePW):\n return not gCuF.REQUIRE_LOGIN or QePW.user.is_authenticated()",
"def qHTF(YKHO, QePW, tTee):\n from users.api import UserDetailAPI\n if QePW.method == 'POST':\n return True\n if QePW.user.is_superuser:\n return True\n if isinstance(tTee, UserDetailAPI):\n ret... | [
"0.7569066",
"0.73537165",
"0.72962993",
"0.7205644",
"0.71922743",
"0.7148008",
"0.7098168",
"0.7045947",
"0.7032",
"0.6967659",
"0.6966724",
"0.6966724",
"0.6944199",
"0.6937988",
"0.6915588",
"0.6915588",
"0.6915588",
"0.6915588",
"0.6915588",
"0.69064724",
"0.6905056",
... | 0.6794674 | 33 |
Returns the XForms type for the field type. | def j7hS(YKHO):
V724 = YKHO.lookup_type(YKHO.field_type)
if V724:
return V724['xforms_type']
else:
raise RuntimeError("Field type: '%s' not supported in XForms" % YKHO.field_type) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sVYR(YKHO):\n return YKHO._form_field_type",
"def sdgl(YKHO):\n return YKHO.field_type",
"def vF49(Jyyj):\n return Jyyj.field.widget.__class__.__name__",
"def vF49(YKHO):\n if isinstance(YKHO._field_type, exCv):\n if YKHO._field_type == 'self':\n YKHO._field_type = YKHO._cls... | [
"0.8031086",
"0.7962945",
"0.7711818",
"0.7506703",
"0.73960227",
"0.7393193",
"0.71798605",
"0.71798605",
"0.71034664",
"0.70275205",
"0.7005076",
"0.6908413",
"0.6900001",
"0.6733375",
"0.66822296",
"0.66822296",
"0.66822296",
"0.66602826",
"0.66315025",
"0.66315025",
"0.66... | 0.8618695 | 0 |
Returns a nicer version of our value, mostly just shortening decimals to be more sane. | def vsPj(YKHO):
if YKHO.field.type == URbA.TYPE_FLOAT:
return '%.2f' % YKHO.cleaned()
else:
return YKHO.value | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def str(wEf2):\n return format('%.12g', wEf2)",
"def zAg0(YKHO) -> str:\n return '${:,.2f}'.format(YKHO.val)",
"def YN4e(BWXx):\n if isinstance(BWXx, float):\n lOa8 = 1 if BWXx == 0.0 else abs(pBSp(PCK9(abs(BWXx))))\n if BWXx > 1 or lOa8 < 4:\n return str(BWXx)\n return... | [
"0.7688714",
"0.7595041",
"0.7548376",
"0.7365626",
"0.7309516",
"0.72806233",
"0.72594947",
"0.72198784",
"0.7217481",
"0.7065374",
"0.69824874",
"0.6973676",
"0.69687724",
"0.6966224",
"0.6877772",
"0.6842645",
"0.6822549",
"0.67821527",
"0.6755763",
"0.6751975",
"0.6744920... | 0.68207437 | 17 |
get a user by id | def TKWP(d0Qf):
cvWf = EfUA(UJAG, [d0Qf])
if cvWf:
Mkmy = cvWf[0]
return CBIr.User(Mkmy[0], Mkmy[1], Mkmy[2], Mkmy[3], Mkmy[4], Mkmy[5], Mkmy[6], Mkmy[7], Mkmy[8], Mkmy[9], Mkmy[10], Mkmy[11], Mkmy[12], Mkmy[13], Mkmy[14], Mkmy[15], Mkmy[16], Mkmy[17], Mkmy[18], Mkmy[19], Mkmy[20], Mkmy[21], Mkm... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def g971(id):\n return mv1M.query.get(int(id))",
"def bt8D(id):\n return mv1M.query.get(id)",
"def TKWP(YKHO, id):\n return YKHO._fetch_json('users/' + id)",
"def bt8D(id):\n Mkmy = G4JS.get(NKRf + '/user/' + str(id))\n CBIr = Mkmy.json()\n return CBIr",
"def ggdo(Emd4, id):\n CBIr = E... | [
"0.8751908",
"0.8736297",
"0.8709204",
"0.8641483",
"0.8600235",
"0.8600235",
"0.8596311",
"0.8538017",
"0.85294545",
"0.8513866",
"0.84968436",
"0.8460761",
"0.8413648",
"0.84076744",
"0.8406093",
"0.83995855",
"0.8384718",
"0.83739305",
"0.83667696",
"0.83415216",
"0.833474... | 0.0 | -1 |
Verify that the returned response contains the given messag and status_code | def G31m(YKHO) -> None:
im4P = 'Success'
jesx: cuzp = {}
JBvl = 200
with Rcys.app_context():
geh0 = G3KB(message=im4P, payload=jesx, status_code=JBvl)
nPrm = qQXR.loads(geh0.data)
YKHO.assertEqual(geh0.status_code, JBvl)
YKHO.assertEqual(nPrm.get('msg'), im4P) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NHkY(_hkX: Response, haEC: int=200):\n assert _hkX.status_code == haEC, 'Unexpected status %d (expected %d): %s' % (_hkX.status_code, haEC, getattr(_hkX, 'data', _hkX.content))",
"def j1x8(_hkX):\n return _hkX.status_code == 200",
"def knUd(YKHO, NKcE):\n nPrm = {'message': 'Test Message', 'code':... | [
"0.7664778",
"0.7516343",
"0.7499449",
"0.74875927",
"0.74348575",
"0.74234366",
"0.7406966",
"0.73312134",
"0.7330482",
"0.73104703",
"0.7272969",
"0.7231091",
"0.72178245",
"0.71864694",
"0.71690243",
"0.7142708",
"0.71375567",
"0.7127131",
"0.7127131",
"0.71050996",
"0.710... | 0.0 | -1 |
Get the integrated autocorrelation time for each dimension. | def Urb6(YKHO, **B2fa):
return yqdp(oyIN.mean(YKHO.get_value('coords'), axis=1), **B2fa) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nA2N(YKHO, nnVk=1):\n return rLdf.Series(YKHO.intensity_list).autocorr(lag=nnVk)",
"def yqdp(WKvO, Z9rn=5, yJiH=50, LpOW=False):\n WKvO = oyIN.atleast_1d(WKvO)\n if len(WKvO.shape) == 1:\n WKvO = WKvO[:, oyIN.newaxis, oyIN.newaxis]\n if len(WKvO.shape) == 2:\n WKvO = WKvO[:, :, oyIN... | [
"0.6536754",
"0.6468181",
"0.64046997",
"0.6316034",
"0.6269001",
"0.62399334",
"0.61858857",
"0.6131128",
"0.5986906",
"0.5937489",
"0.58611625",
"0.58502537",
"0.5804995",
"0.5772244",
"0.57298636",
"0.57282025",
"0.57022536",
"0.56502324",
"0.56495017",
"0.5644653",
"0.562... | 0.7923793 | 0 |
dump some json to a temporary file | def bFLq(YKHO, nPrm, z_es='/tmp/jamf_upload'):
YKHO.make_tmp_dir(z_es)
ZylS = Hy7s.path.join(z_es, f'jamf_upload_{str(qxeD.uuid4())}.json')
with open(ZylS, 'w') as ytgA:
qQXR.dump(nPrm, ytgA)
return ZylS | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uZJ1(YKHO, nPrm, nUeQ):\n mWFP, YBcr = Hy7s.path.splitext(nUeQ)\n _pmj = '{0}.tmp'.format(mWFP)\n with open(_pmj, 'w') as eHNT:\n qQXR.dump(nPrm, eHNT, indent=4)\n RDuA.copyfile(_pmj, nUeQ)\n Hy7s.remove(_pmj)",
"def O1mT(nPrm):\n with gbPf.NamedTemporaryFile(delete=False, mode='wb')... | [
"0.7634144",
"0.7440371",
"0.7217254",
"0.71567845",
"0.70602584",
"0.7053856",
"0.6980352",
"0.6956715",
"0.6950505",
"0.69240093",
"0.6905745",
"0.68947405",
"0.68720406",
"0.68210214",
"0.680494",
"0.6780151",
"0.6769948",
"0.67619777",
"0.6738435",
"0.67264694",
"0.671752... | 0.67588395 | 18 |
Returns the string representation of the model | def gTzM(YKHO):
import simplejson as qQXR
if jKi7.PY2:
import sys
U3hF(sys)
sys.setdefaultencoding('utf-8')
return qQXR.dumps(yInN(YKHO), ensure_ascii=False) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__model)",
"def zAg0(YKHO):\n return str(YKHO.model)",
"def zAg0(YKHO):\n return YKHO.text",
"def zAg0(YKHO):\n oOUF = '-----------------------------------------------------------------------------------\\n'\n _2sc = YKHO.__class__.__name__\n oOUF += '\\t\\... | [
"0.86418265",
"0.85103965",
"0.7853324",
"0.77442306",
"0.7712258",
"0.76979405",
"0.765959",
"0.7637644",
"0.76218504",
"0.7607561",
"0.7606604",
"0.7606604",
"0.7606604",
"0.75990754",
"0.7585653",
"0.758149",
"0.7570811",
"0.7567585",
"0.75392604",
"0.75392604",
"0.7527967... | 0.0 | -1 |
Returns true if both objects are not equal | def Vdqg(YKHO, Elif):
return not YKHO == Elif | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO.__eq__(Elif)",
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif: object):\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif):\n if YKHO.__eq__(Elif):\n return False\n return True",
"def Vdqg(... | [
"0.8392633",
"0.8354901",
"0.82950056",
"0.8132309",
"0.81149805",
"0.8099986",
"0.809911",
"0.8097883",
"0.8097883",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8066694",
"0.80594814",
"0.805757",
... | 0.0 | -1 |
Ensure that the given value is or could be a float. | def xzCw(YKHO, BWXx):
if not isinstance(BWXx, float):
try:
BWXx = float(BWXx)
except:
raise sUXu('%s could not be converted to float' % BWXx) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MWTW(BWXx):\n if not isinstance(BWXx, float):\n RKD7('User supplied not a float value.', 'MEDIUM', 'FAIL')\n eTsH(400, 'Validation Error on val_float')\n else:\n return True",
"def X02v(BWXx):\n if type(BWXx) is float:\n return BWXx\n try:\n FLrL = type(BWXx).__... | [
"0.8600155",
"0.8466423",
"0.8457441",
"0.8411819",
"0.83761233",
"0.82541376",
"0.825037",
"0.8246411",
"0.82253516",
"0.8198384",
"0.81587905",
"0.8119693",
"0.8118669",
"0.8103621",
"0.8103621",
"0.8103621",
"0.8103621",
"0.80245906",
"0.8001395",
"0.7998203",
"0.79926676"... | 0.8110563 | 13 |
Create a paginator for an operation. | def oL8A(YKHO, hTqE: str=None) -> NIbP:
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n pass",
"def oL8A(hTqE=None):\n p... | [
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"0.7726925",
"... | 0.76366186 | 38 |
Create and return the Flask application | def LUif():
P4t4 = L2w0(__name__)
P4t4.config.from_object(GPtr.config)
NCls.init_app(P4t4)
_ZMm.init_app(P4t4)
_ZMm.login_view = 'general.login'
from website.views import general
from website.views import account
P4t4.register_blueprint(general.mod)
P4t4.register_blueprint(account.mo... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LUif():\n kvcN = 'scaffolding'\n R5in = Hy7s.path.join(Hy7s.path.dirname(Hy7s.path.abspath(xAKo)), 'web/static')\n P4t4 = L2w0(kvcN, static_folder=R5in)\n yhTH(P4t4)\n zqKm(P4t4)\n YEWp(P4t4)\n hetx(P4t4)\n return P4t4",
"def LUif():\n P4t4 = L2w0(__name__)\n sSY8(P4t4)\n ret... | [
"0.857699",
"0.85618806",
"0.84721404",
"0.8447277",
"0.8430614",
"0.8399209",
"0.8347932",
"0.8334068",
"0.8320557",
"0.8317374",
"0.8316002",
"0.8310984",
"0.83048683",
"0.8303084",
"0.82573944",
"0.8235319",
"0.8230374",
"0.8230261",
"0.8219856",
"0.82147133",
"0.8213993",... | 0.7967834 | 70 |
Return gender of first deltager. Returns | def u7Ij(YKHO):
try:
mWFP = YKHO.data['deltagerRelation'][0]['deltager']['navne'][0]['navn']
except (KeyError, IndexError, TypeError):
mWFP = ''
return mWFP | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xVNR(YKHO):\n return YKHO.gender",
"def EE3v(YKHO):\n return lhy8.object.gender[YKHO.id]",
"def xVNR(YKHO):\n return YKHO.gender",
"def xVNR(YKHO):\n return YKHO.__gender",
"def EE3v(YKHO):\n return lhy8.house.gender[YKHO.id]",
"def EE3v(YKHO):\n return YKHO._gender",
"def EE3v(YK... | [
"0.7695844",
"0.7681755",
"0.7633254",
"0.75577754",
"0.75009364",
"0.7435866",
"0.7435866",
"0.72880536",
"0.71228963",
"0.7113026",
"0.70945525",
"0.70818245",
"0.7047221",
"0.69536257",
"0.69395286",
"0.6924825",
"0.6913588",
"0.6913372",
"0.68578833",
"0.6853791",
"0.6852... | 0.0 | -1 |
Return 'antal ansatte'. Taken as the first number from the 'intervalKodeAntalAnsatte' field from the nyesteAarsbeskaeftigelse. | def TywG(YKHO):
try:
BWXx = YKHO.data['virksomhedMetadata']['nyesteAarsbeskaeftigelse']['intervalKodeAntalAnsatte']
mSrU = c2KQ('\\d+', BWXx)
return int(mSrU[0])
except:
return JNix | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TywG(YKHO):\n try:\n BWXx = YKHO.data['_source']['Vrvirksomhed']['virksomhedMetadata']['nyesteAarsbeskaeftigelse']['intervalKodeAntalAnsatte']\n mSrU = c2KQ('\\\\d+', BWXx)\n return int(mSrU[0])\n except:\n return JNix",
"def rfqt(YKHO):\n return YKHO._aantalNogInTePlanne... | [
"0.82964605",
"0.6612502",
"0.59311724",
"0.59168893",
"0.58378637",
"0.57544816",
"0.5720621",
"0.56930774",
"0.56543976",
"0.5613578",
"0.5613192",
"0.56071347",
"0.5562551",
"0.554092",
"0.5505061",
"0.5489483",
"0.54846555",
"0.54835016",
"0.5477633",
"0.54523695",
"0.544... | 0.8495893 | 0 |
Check if a tag with id `tag_id` exists. If not, create it. | def qzvO(qw32):
if not qw32:
raise ValueError('Tag id must not be empty')
with GGod().transaction() as a1PO:
try:
a1PO.query(OhYN).filter(OhYN.id == qw32).one()
except ELJA:
TZ9E = OhYN()
TZ9E.id = qw32
TZ9E.color = tuKI.randrange(0, len(Jw... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ONvq(TZ9E):\n TZ9E = TZ9E.strip()\n nEeP = OhYN.query.filter_by(name=TZ9E).first()\n if not nEeP:\n b9Hm = OhYN(name=TZ9E)\n NCls.session.add(b9Hm)\n return b9Hm\n return nEeP",
"def DKo0(YKHO, RDp6: str, hLhr) -> bool:\n pass",
"def j1Gn(hLhr):\n hLhr = hLhr.strip()\... | [
"0.7284042",
"0.6824325",
"0.67141855",
"0.65161866",
"0.65041333",
"0.6406114",
"0.6295813",
"0.6255312",
"0.6229713",
"0.61869633",
"0.6185753",
"0.6123836",
"0.6090332",
"0.6058879",
"0.60527027",
"0.6037794",
"0.6035389",
"0.6013358",
"0.59489286",
"0.5938528",
"0.5937735... | 0.7234737 | 1 |
L2 distance between tensors true and pred. | def SDab(aJu6, nvEb):
return ZylS.reduce_sum(ZylS.square(aJu6 - nvEb)) / ZylS.to_float(ZylS.size(nvEb)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LJvU(aJu6, nvEb):\n return ZylS.reduce_sum(ZylS.square(aJu6 - nvEb)) / nvEb.shape.as_list()[0]",
"def y5qx(_ger: np.ndarray, nvEb: np.ndarray) -> float:\n assert _ger.ndim == nvEb.ndim == 2 and _ger.shape[1] == nvEb.shape[1]\n return azxD(nvEb, _ger, p=2)",
"def Zt3J(aJu6, nvEb):\n return ZylS.... | [
"0.7250446",
"0.65133977",
"0.6490485",
"0.6413527",
"0.6378822",
"0.63361394",
"0.6275484",
"0.6225887",
"0.62187153",
"0.6213883",
"0.6151596",
"0.61226445",
"0.61113185",
"0.60923606",
"0.6073805",
"0.60704666",
"0.5999457",
"0.59969014",
"0.5984713",
"0.59745127",
"0.5963... | 0.0 | -1 |
Set vesrion of artifact. This is the version we will build, upload and download. | def R2V2(YKHO, DpZH):
YKHO.version = DpZH | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DpZH(YKHO, DpZH):\n YKHO.asset_query_params['version'] = DpZH\n return YKHO",
"def fvEA(YKHO):\n YKHO.h5.attrs['version'] = BtDU\n YKHO.h5.attrs['full_version_record'] = qQXR.dumps(YKHO.full_version_record)\n YKHO.h5.attrs['package'] = 'sup3r'",
"def hSsD(YKHO):\n try:\n eHNT = nUe... | [
"0.6036092",
"0.60335445",
"0.5927748",
"0.5899895",
"0.58612657",
"0.58338577",
"0.58019257",
"0.57914734",
"0.57845205",
"0.5756993",
"0.57483965",
"0.5706369",
"0.5640741",
"0.5611098",
"0.55894697",
"0.55827665",
"0.55641234",
"0.55505806",
"0.55480754",
"0.5539934",
"0.5... | 0.5846818 | 5 |
Return elements that are unique to container a and items that are unique to container b among the union of a and b. | def cljO(jzdc, Fg_i):
def yHH9(jzdc, Fg_i):
return list(set(jzdc) & set(Fg_i))
def by6d(jzdc, Fg_i):
return list(set(jzdc) ^ set(Fg_i))
WH_7 = by6d(jzdc, Fg_i)
mTwa = yHH9(jzdc, WH_7)
wnXl = yHH9(Fg_i, WH_7)
return (mTwa, wnXl) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def b65I(jzdc, Fg_i):\n return list(set(jzdc) | set(Fg_i))",
"def b65I(jzdc, Fg_i):\n return list(set(jzdc) | set(Fg_i))",
"def b65I(jzdc, Fg_i):\n return list(set(jzdc) | set(Fg_i))",
"def b65I(jzdc, Fg_i):\n return list(set(jzdc) | set(Fg_i))",
"def b65I(jzdc, Fg_i):\n return list(set(jzdc... | [
"0.77745104",
"0.7745483",
"0.77269185",
"0.7704511",
"0.77027106",
"0.77027106",
"0.77027106",
"0.77027106",
"0.77027106",
"0.77027106",
"0.76277536",
"0.74470526",
"0.7291506",
"0.7172178",
"0.7140911",
"0.7101221",
"0.70912105",
"0.6958815",
"0.6957606",
"0.68194395",
"0.6... | 0.72676796 | 13 |
Add row to run tracker table using entries of param_dict. | def sg96(kpae, UL8P='output/param_table.csv', CZII=[], fNI0=None, ZAVR=True):
UL8P = GkAb(UL8P)
tEGs = UL8P.parents[0]
GkAb.mkdir(tEGs, exist_ok=True)
for H5ew in kpae:
kpae[H5ew] = str(kpae[H5ew])
ByBU, sX1N, TyXS, xGJv = UXpa(CZII, kpae, UL8P, fNI0)
if sX1N == 0 or not ZAVR:
Ty... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VYVK(YKHO, NArs):\n YKHO.records = {}\n for H5ew, BWXx in NArs.iteritems():\n YKHO.records[H5ew] = UQon(BWXx)",
"def ejCy(YKHO, tyNF: Table, **qIxc):\n G1Hx = qIxc.keys()\n Ty9i = qIxc.values()\n YKHO.c.execute(f'INSERT INTO {tyNF.name} ({','.join(G1Hx)}) VALUES ({','.join(list('?' * le... | [
"0.6548196",
"0.6377574",
"0.6224846",
"0.61031854",
"0.6092043",
"0.6087156",
"0.60848475",
"0.60815984",
"0.6012026",
"0.59636015",
"0.59540445",
"0.5895657",
"0.5881004",
"0.58730656",
"0.58131534",
"0.57318574",
"0.56924236",
"0.5682204",
"0.56805515",
"0.56793153",
"0.56... | 0.0 | -1 |
Returns the active argilla client. If Active client is None, initialize a default one. | def JUXs() -> GqbJ:
return Lio5.get() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def AblP(ODPQ: bool=True) -> uLKX['httpx.Client', 'AuthenticatedClient']:\n try:\n x0hE = JUXs().http_client\n if ODPQ:\n x0hE = x0hE.httpx\n return x0hE\n except Exception as e:\n raise RuntimeError(f'The `rg.active_client()` is not available or not respoding.') from t... | [
"0.73810315",
"0.70130664",
"0.6668761",
"0.6580241",
"0.64608586",
"0.6434655",
"0.63896614",
"0.6359948",
"0.6343024",
"0.6309641",
"0.630571",
"0.6305007",
"0.6288642",
"0.62564087",
"0.62513465",
"0.62435085",
"0.62431264",
"0.6224573",
"0.6223809",
"0.62103236",
"0.62012... | 0.85102654 | 0 |
Read a commaseparated values (csv) with associated hdf5 file into DataFrameArray. Also supports optionally iterating or breaking of the file into chunks. Additional help can be found in the online docs for | def HND1(qQv5, VWe_=',', TDw3=None, WBPg='infer', ZWCE=None, DfZ1=None, QTq5=None, MZMe=False, y0cW=None, yQmN=True, yDqo=None, eHpk=None, y3OZ=None, TkHw=None, kkhE=None, EHY6=False, XWwe=None, Tvw7=0, HN6s=None, GsD2=None, bvIc=True, ZGeY=True, PJWX=False, NdR6=True, J1kZ=False, raTS=False, sx8N=False, kes1=None, Zm3... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fQDM(YKHO, pmON: str, ztRo: int) -> rLdf.DataFrame:\n qyxr = '\\n The method is under developing. \\n The name or the arguments may differ from current version in the future update.\\n '\n qmLP.warn(qyxr, FutureWarning)\n ptET = ''\n hnjo = []\n for or8S, vC9B in enu... | [
"0.64315134",
"0.62433976",
"0.6206892",
"0.6116834",
"0.603041",
"0.6006472",
"0.5998259",
"0.5963952",
"0.59481883",
"0.5910498",
"0.58773005",
"0.5875663",
"0.58612096",
"0.5861199",
"0.5826789",
"0.58227",
"0.58138984",
"0.57674307",
"0.5765931",
"0.57578367",
"0.5742832"... | 0.69440335 | 0 |
Return the sample keys that denote a learning algorithm's targets These keys should be contained in the dictionary returned from __getitem__, and correspond to the keys that will be the targets to a neural network. | def PiM2(YKHO):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RH8N(YKHO, mvm2):\n return mvm2['target']",
"def RH8N(YKHO, mvm2, O0ro):\n return mvm2['target']",
"def RH8N(YKHO, mvm2, O0ro):\n return mvm2['target']",
"def RH8N(YKHO, mvm2, O0ro):\n return mvm2['target']",
"def YTuP(YKHO, gGnb):\n return {}",
"def x6A0(YKHO):\n return YKHO.trains... | [
"0.70533365",
"0.66484076",
"0.66484076",
"0.6625703",
"0.62038994",
"0.6135129",
"0.6075764",
"0.6033499",
"0.59901214",
"0.59301317",
"0.5904417",
"0.5869007",
"0.5782802",
"0.5764622",
"0.570783",
"0.5694453",
"0.56889546",
"0.56889546",
"0.568462",
"0.5681169",
"0.5661337... | 0.6542138 | 4 |
Initialies the SQLAlchemy app | def JawI(P4t4):
XHju.init_db(P4t4) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DbxN(Emd4):\n bo34.info('Initializing database')\n pths.init_app(P4t4)\n P4t4.app_context().push()\n pths.create_all()",
"def JawI(Emd4, P4t4):\n bo34.info('Initializing database')\n Emd4.app = P4t4\n NCls.init_app(P4t4)\n P4t4.app_context().push()\n NCls.create_all()",
"def JawI... | [
"0.8258911",
"0.81532556",
"0.81532556",
"0.81532556",
"0.81532556",
"0.8023361",
"0.7908556",
"0.78537923",
"0.7830822",
"0.7809931",
"0.77840835",
"0.7758547",
"0.76809",
"0.7635198",
"0.7635198",
"0.7635198",
"0.7635198",
"0.7635198",
"0.75887394",
"0.7536347",
"0.7533999"... | 0.7217698 | 43 |
Removes a order from the data store | def PTpj(YKHO):
bo34.info('Deleting order %s', YKHO.id)
NCls.session.delete(YKHO)
NCls.session.commit() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def H5zi(YKHO, T4Wy: Order):\n if T4Wy.id in YKHO.__order_dict:\n del YKHO.__order_dict[T4Wy.id]\n T4Wy.shelf = None\n bo34.info(': {}, removed order: {}'.format(YKHO.name, T4Wy))",
"def H5zi(YKHO, type, zJ7I):\n y7DO = YKHO.order_book[type]\n for d6pt, T4Wy in enumerate(y7DO):\n ... | [
"0.78055555",
"0.72355133",
"0.71599096",
"0.70515823",
"0.70338535",
"0.6982505",
"0.69489986",
"0.6941178",
"0.6886221",
"0.6876104",
"0.6863657",
"0.6812345",
"0.6690998",
"0.664129",
"0.6635934",
"0.65615255",
"0.6468549",
"0.6460339",
"0.6433029",
"0.64109695",
"0.638025... | 0.73465466 | 2 |
Returns all of the orders in the database | def all(Emd4):
bo34.info('Processing all orders')
return Emd4.query.all() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def KekM():\n iZNa = ja1s('orders')\n return iZNa",
"def DI5P(YKHO):\n return YKHO.db",
"def NMoC(YKHO):\n xDcj = 'SELECT id, address, total_price, order_status FROM `ORDER`'\n Ylbp = NEl6.execute_query(xDcj)\n Ylbp = list(Ylbp)\n zSny = []\n if Ylbp:\n for ZfUD in Ylbp:\n ... | [
"0.87534994",
"0.8459035",
"0.8154039",
"0.80213",
"0.79299915",
"0.7873908",
"0.7682096",
"0.76251155",
"0.7610418",
"0.75204057",
"0.75147945",
"0.7514035",
"0.7493824",
"0.73920393",
"0.7368919",
"0.73594755",
"0.7259109",
"0.71548",
"0.71180105",
"0.70850915",
"0.7084056"... | 0.84200484 | 2 |
Updates a order into the database | def xkzz(YKHO):
bo34.info('Saving %s', YKHO.id)
NCls.session.commit() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QdZT(YKHO):\n bo34.info('Updating order %s', YKHO.id)\n if not YKHO.id:\n raise nhVO('Update called with empty ID field')\n NCls.session.commit()",
"def VW_X(BgK2):\n for T4Wy in BgK2:\n VRlN(T4Wy)",
"def By4C(YKHO):\n pass",
"def XRZa(YKHO, T4Wy):\n RGYk = y8cn.base_uri\n... | [
"0.81186074",
"0.7781025",
"0.75937086",
"0.7476728",
"0.7409212",
"0.72461194",
"0.7181136",
"0.71790755",
"0.71540105",
"0.7037369",
"0.6941333",
"0.68600595",
"0.68514144",
"0.68514144",
"0.6816137",
"0.6816137",
"0.6816137",
"0.681563",
"0.6768777",
"0.6741252",
"0.672190... | 0.0 | -1 |
Determine min/max for x and y axis. Create Coordinate for each lat/long pair | def oAce(YKHO, W0Eb):
for dmxO in W0Eb:
_UuI = dmxO[0]
fopC = dmxO[1]
MnaQ = XvuT(fopC, _UuI)
if _UuI > YKHO._max_y:
YKHO._max_y = _UuI
if _UuI < YKHO._min_y:
YKHO._min_y = _UuI
if fopC > YKHO._max_x:
YKHO._max_x = fopC
if f... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fwnu(YKHO):\n ZarI = None\n lVg_ = None\n VrYd = None\n f1MF = None\n for LNo8 in YKHO.images:\n if ZarI is None:\n ZarI = LNo8.long\n elif LNo8.long < ZarI:\n ZarI = LNo8.long\n if lVg_ is None:\n lVg_ = LNo8.long\n elif LNo8.long > l... | [
"0.7321958",
"0.72264564",
"0.7070444",
"0.7010477",
"0.69525",
"0.69417214",
"0.6883348",
"0.6853397",
"0.6803165",
"0.6792247",
"0.6783203",
"0.6754407",
"0.67480904",
"0.6712101",
"0.6699378",
"0.6676925",
"0.66569275",
"0.66538703",
"0.66533947",
"0.66511244",
"0.6646634"... | 0.6348656 | 39 |
Updates or creates a Company's Questionnaire Answers for a given period | def m8z6(YKHO, QePW, _sei, a5Ef):
try:
if '-' in a5Ef:
DYP_ = ip5r.get_monthly_report(pk=_sei, period=a5Ef)
else:
DYP_ = ip5r.get_monthly_report(pk=_sei, report_id=a5Ef)
if DYP_ is None:
return LOnh.dispatch_failure(QePW, 'MISSING_MONTHLY_REPORTING_PREVIOU... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def V3ZF(YKHO):\n YKHO.data = [{'question': 1, 'answer': 100}]\n Z7D7._create_question_catagory()\n Z7D7._create_question(YKHO.company)\n u3tA = Z7D7._create_monthly_report(YKHO.company)\n Z7D7._post_with_args(YKHO.client, iSxz.QuestionnaireDetail, [YKHO.company.id, '2016-10'], YKHO.data)\n YKHO.... | [
"0.6231496",
"0.59213114",
"0.5600107",
"0.5576649",
"0.55410165",
"0.5506163",
"0.54920024",
"0.5405567",
"0.53860724",
"0.5371548",
"0.53652185",
"0.5352898",
"0.53476584",
"0.5341415",
"0.5339776",
"0.53187394",
"0.5316472",
"0.53153294",
"0.53051734",
"0.53026474",
"0.529... | 0.6158265 | 1 |
Change the position of the sprite and direction facing. | def QdZT(YKHO):
YKHO.center_x += YKHO.change_x
YKHO.center_y += YKHO.change_y
if YKHO.change_x < 0:
YKHO.texture = YKHO.textures[1]
elif YKHO.change_x > 0:
YKHO.texture = YKHO.textures[0]
if YKHO.left < 0:
YKHO.left = 0
elif YKHO.right > zMH2 - 1:
YKHO.right = zMH... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NLqC(YKHO):\n ehDb = YKHO.actor\n if ehDb is None:\n return\n if YKHO._updating:\n return\n WKvO = YKHO.x_position\n LVAh = YKHO.y_position\n epBp = YKHO.z_position\n if YKHO.position_in_3d:\n ehDb.position_coordinate.value = (WKvO, LVAh, epBp)\n else:\n ehDb... | [
"0.67491543",
"0.66095936",
"0.6580672",
"0.6541925",
"0.6395803",
"0.6387531",
"0.63831323",
"0.6375154",
"0.63643146",
"0.6336292",
"0.63262415",
"0.63154143",
"0.63110477",
"0.62795895",
"0.627488",
"0.62655085",
"0.6248815",
"0.622958",
"0.6225073",
"0.6211974",
"0.621095... | 0.6588652 | 2 |
Generate number sprites and places them on screen. | def AIx_(YKHO):
mLGw = KUXB()
while mLGw == YKHO.problem.answer:
mLGw = KUXB()
UkR9 = False
while not UkR9:
mLGw.center_x = tuKI.randrange(zMH2)
mLGw.center_y = tuKI.randrange(vkJL)
NCMZ = jIOH.check_for_collision_with_list(mLGw, YKHO.wall_list)
BXTX = jIOH.check_... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vbmc() -> int:\n pass",
"def sVYM(r8m5: int) -> int:\n pass",
"def Svnr(Dpo8, dgFk):\n pass",
"def PbOH(rGpw: int) -> None:\n pass",
"def PF9V(YKHO):\n j93S = gYGL(YKHO.x[0, 0] / YKHO.hw, 1 - YKHO.x[0, 1] / YKHO.hw, YKHO.shapes[0], c0=255, c1=0, c2=0, scale=YKHO.scale)\n Nqp_ = gYGL(Y... | [
"0.7093702",
"0.69465804",
"0.6427971",
"0.63483846",
"0.6335662",
"0.63352513",
"0.632799",
"0.63160264",
"0.62882966",
"0.62873346",
"0.628594",
"0.62685335",
"0.626739",
"0.62470555",
"0.62341404",
"0.62085307",
"0.6199067",
"0.61981046",
"0.6197568",
"0.616002",
"0.613887... | 0.0 | -1 |
Create the answer number sprite and place it on the screen. | def L8wY(YKHO):
mLGw = KUXB(YKHO.problem.answer)
UkR9 = False
while not UkR9:
mLGw.center_x = tuKI.randrange(zMH2)
mLGw.center_y = tuKI.randrange(vkJL)
NCMZ = jIOH.check_for_collision_with_list(mLGw, YKHO.wall_list)
BXTX = jIOH.check_for_collision_with_list(mLGw, YKHO.number)... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sVYM(r8m5: int) -> int:\n pass",
"def vbmc() -> int:\n pass",
"def jKW4(YKHO, oeNL):\n pass",
"def U8Ql(YKHO):\n m88U = 'NOTHING'\n if YKHO.type == 'I':\n if YKHO.tile.type == 'W' or YKHO.tile.type == 'P':\n m88U = f'{YKHO.tile.type} : {YKHO.tile.bonus} : {YKHO.tile.cost}... | [
"0.67858267",
"0.6728959",
"0.64338636",
"0.6355976",
"0.625066",
"0.6218705",
"0.6101672",
"0.60676914",
"0.59586275",
"0.5915567",
"0.58964515",
"0.58892405",
"0.58757997",
"0.5873945",
"0.5826624",
"0.5800644",
"0.5758179",
"0.5742936",
"0.5716211",
"0.5712717",
"0.5697292... | 0.6245767 | 5 |
Creates a circuit that performs a diffusion algorithm to the given qubits. | def SGcs(dWRx, mXtm=0):
nzPj = Rv0t(dWRx + mXtm, name='diffuser')
zOYc = [YRbF for YRbF in range(0, dWRx)]
Ga0J = [YRbF for YRbF in range(dWRx, dWRx + mXtm)]
nzPj.h(zOYc)
nzPj.x(zOYc)
nzPj.h(zOYc[-1])
if mXtm > 0:
nzPj.mct(zOYc[:-1], zOYc[-1], Ga0J, mode='basic')
else:
nz... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MBwh(Hswb):\n XP5J = sqRO.Program()\n if len(Hswb) == 1:\n XP5J.inst(C7Ls(Hswb[0]))\n XP5J.inst(Nk6w(Hswb[0]))\n XP5J.inst(C7Ls(Hswb[0]))\n else:\n XP5J.inst(map(EcVT, Hswb))\n XP5J.inst(C7Ls(Hswb[-1]))\n XP5J.inst(xZNm(-oyIN.pi)(Hswb[0]))\n XP5J += NS4... | [
"0.7027156",
"0.59235823",
"0.59096974",
"0.5897903",
"0.58768517",
"0.570136",
"0.56435466",
"0.5635051",
"0.5575757",
"0.55488473",
"0.5446975",
"0.54121",
"0.54097664",
"0.54006374",
"0.5399231",
"0.5387635",
"0.53815866",
"0.537707",
"0.5375536",
"0.53738505",
"0.53682905... | 0.57522845 | 5 |
Constructs a new instance. If k and theta are None, will use the default values for the dataset. | def FIMM(YKHO, G1Hx: Optional[int]=None, q7In: Optional[int]=None) -> None:
super().__init__()
YKHO.k = G1Hx
YKHO.theta = q7In | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, G1Hx, ZRAy, cB5N):\n YKHO._k = G1Hx\n YKHO._data_train = ZRAy\n YKHO._targets_train = cB5N",
"def FIMM(YKHO, G1Hx=None):\n YKHO._types = {'<unk>': Y69N()}\n YKHO.vocab_size = 0.0\n YKHO.token_num = 0.0\n if G1Hx == None:\n YKHO.k = 0.0055\n else:\n YKHO.k = G1... | [
"0.69613886",
"0.67201716",
"0.65862226",
"0.6543693",
"0.6540537",
"0.6522285",
"0.65102446",
"0.6441697",
"0.639121",
"0.6358828",
"0.6293206",
"0.62811714",
"0.6279696",
"0.62707573",
"0.6223318",
"0.62129056",
"0.62082195",
"0.6191185",
"0.61719656",
"0.61496466",
"0.6148... | 0.8112809 | 0 |
Normalize image to a mean of zero and a standard deviation of one. | def Ekx3(LNo8: np.ndarray) -> oyIN.ndarray:
LNo8 = (LNo8 - LNo8.mean()) / LNo8.std()
return LNo8.astype(oyIN.float32) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NkkI(VXjJ, JBMS, M1Jx):\n return (VXjJ - JBMS) / M1Jx",
"def NkkI(YKHO, VXjJ):\n return (VXjJ - oyIN.mean(VXjJ)) / oyIN.std(VXjJ)",
"def BtVk(YKHO, VXjJ):\n return (VXjJ - oyIN.mean(VXjJ)) / oyIN.std(VXjJ)",
"def NkkI(VXjJ):\n Aofo = VXjJ.astype(oyIN.float64)\n Aofo -= oyIN.mean(Aofo)\n ... | [
"0.8349486",
"0.8260074",
"0.8175249",
"0.8166454",
"0.8143752",
"0.81429666",
"0.8056137",
"0.7993004",
"0.7983414",
"0.79462165",
"0.7825104",
"0.78102005",
"0.77251166",
"0.76702714",
"0.7629339",
"0.7581662",
"0.75810045",
"0.757601",
"0.75686693",
"0.7565812",
"0.7560427... | 0.7679908 | 13 |
Convert the prediction matrix into a list of coordinates. NOTE plt.scatter uses the x, y system. Therefore any plots must be inverted by assigning x=c, y=r! | def pKzV(SppC: np.ndarray, N0ky: int=512, Q7Be: float=0.5) -> oyIN.ndarray:
if not SppC.ndim == 3:
raise ValueError('Matrix must have a shape of (r, c, 3).')
if not SppC.shape[2] == 3:
raise ValueError('Matrix must have a depth of 3.')
if not SppC.shape[0] == SppC.shape[1] and (not SppC.shap... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def c5T7(YKHO):\n pMBr, LECP = ([], [])\n for Mkmy, rdlD in enumerate(YKHO.grid):\n for Z9rn, fvDH in enumerate(rdlD):\n if fvDH > YKHO.occupied:\n pMBr.append(Z9rn)\n LECP.append(Mkmy)\n return (oyIN.array(pMBr) * YKHO.res + YKHO.cx, oyIN.array(LECP) * YKHO... | [
"0.6012842",
"0.5692912",
"0.56897426",
"0.56162256",
"0.561294",
"0.55924904",
"0.55919087",
"0.5493055",
"0.54811805",
"0.5479916",
"0.54729027",
"0.54646",
"0.54633546",
"0.545771",
"0.5428626",
"0.5388952",
"0.53763443",
"0.53726923",
"0.5365284",
"0.53592664",
"0.5355782... | 0.5256239 | 35 |
Returns a list of Category objects that are children of this category. | def xLeR(YKHO):
return qZuN.getChildTreeFromList((YKHO,), withRoot=False) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RbaF(YKHO):\n LeZt = qZuN.objects.filter(parent=YKHO.id)\n return LeZt",
"def RbaF(YKHO):\n if not hasattr(YKHO, '_children'):\n YKHO._children = qZuN.objects.filter(parent__exact=YKHO)\n return YKHO._children",
"def cg73(YKHO):\n return YKHO.accountcategory_set.order_by('order', 'nam... | [
"0.8589568",
"0.84152067",
"0.78976184",
"0.7589402",
"0.75610214",
"0.7478558",
"0.7389183",
"0.7387366",
"0.7237156",
"0.7209589",
"0.7143027",
"0.70785064",
"0.7072128",
"0.7013842",
"0.7013277",
"0.6862687",
"0.6857058",
"0.6818279",
"0.67961955",
"0.67961955",
"0.6767205... | 0.76463187 | 3 |
Return a list of Category objects that are children of this category including this category. | def ve4D(YKHO):
return qZuN.getChildTreeFromList((YKHO,)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RbaF(YKHO):\n LeZt = qZuN.objects.filter(parent=YKHO.id)\n return LeZt",
"def RbaF(YKHO):\n if not hasattr(YKHO, '_children'):\n YKHO._children = qZuN.objects.filter(parent__exact=YKHO)\n return YKHO._children",
"def cg73(YKHO):\n return YKHO.accountcategory_set.order_by('order', 'nam... | [
"0.86095625",
"0.8414639",
"0.7874478",
"0.7637058",
"0.758907",
"0.75761735",
"0.7502543",
"0.74793947",
"0.745787",
"0.7249309",
"0.7152295",
"0.7067774",
"0.7017161",
"0.6939588",
"0.69356734",
"0.6920698",
"0.68317217",
"0.68317217",
"0.68117136",
"0.67697406",
"0.6750028... | 0.0 | -1 |
Given a list of Category objects, this returns a list of all the Categories plus all the Categories' children, plus the childrens' children, etc. For example, if the 'Arts' Category is passed as a parameter, this function will return the ['Arts', 'Arts>Music', 'Arts>Music>Local' ...] objects. | def eDRi(YKHO, uTDW):
Aofo = []
if isinstance(uTDW, (list, tuple)):
if uTDW:
kCk2 = ["models.Q(path__exact='%s')" % QMSQ(Z9rn) for Z9rn in uTDW]
qIxc = eval('|'.join(kCk2))
Aofo = qZuN.objects.filter(qIxc)
return Aofo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LQuW(YKHO):\n return list(YKHO.category.get_descendants()) + [YKHO.category]",
"def LeZt(J_Es):\n return list(J_Es)",
"def nnH0(YKHO, LeZt, Vi0l=True):\n J_Es = []\n for ACia in LeZt:\n oHE7 = ACia.children.iterator()\n if Vi0l:\n J_Es.append(ACia)\n try:\n ... | [
"0.72635674",
"0.71364695",
"0.7094896",
"0.7090794",
"0.70212907",
"0.69844544",
"0.6891354",
"0.68581927",
"0.6853971",
"0.679381",
"0.67563635",
"0.66673714",
"0.6657564",
"0.66507834",
"0.6641737",
"0.66338843",
"0.6613494",
"0.66077375",
"0.66077375",
"0.65317065",
"0.65... | 0.6995941 | 5 |
Users with 'is_contributor' as True are considered as contributors. | def Xmrj():
NqOl(is_contributor=False, email='sample.notcontributor@example.org')
NqOl(is_contributor=True, email='sample.iscontributor@example.org')
assert mv1M.objects.count() == 2
assert mv1M.objects.contributors().count() == 1 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BKuk(CBIr):\n return CBIr.groups.filter(name='Contributor').exists() | CBIr.groups.filter(name='Worker').exists() | CBIr.groups.filter(name='Admin').exists()",
"def u4zn(YKHO):\n return YKHO.is_contributor or YKHO.is_superuser",
"def kpG6(YKHO):\n return YKHO.is_contributor or YKHO.is_beneficiary"... | [
"0.80972546",
"0.7592197",
"0.7349554",
"0.70942396",
"0.7089817",
"0.7088495",
"0.70709085",
"0.6985789",
"0.6582764",
"0.6387984",
"0.63492024",
"0.6263842",
"0.6214549",
"0.6154427",
"0.6143556",
"0.6068583",
"0.6025927",
"0.60142076",
"0.6011574",
"0.5937018",
"0.5930712"... | 0.66842854 | 8 |
Find and return the index of target in sequence xs | def kZXp(fUYa, pan_):
for YRbF in range(len(fUYa)):
if fUYa[YRbF] == pan_:
return YRbF
return -1 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eMqW(yv6U, pan_):\n d6pt = 0\n for YRbF in yv6U:\n d6pt += 1\n if pan_ == YRbF:\n return d6pt - 1\n return -1",
"def kS1Y(YKHO, pan_):\n for YRbF in range(len(YKHO)):\n if YKHO[YRbF][0] == pan_:\n return YRbF\n return None",
"def kS1Y(YKHO, pan_):\n... | [
"0.80231214",
"0.7955096",
"0.7812651",
"0.78053176",
"0.77531993",
"0.7677954",
"0.7605418",
"0.7588682",
"0.7584056",
"0.7566692",
"0.7559766",
"0.7553133",
"0.75495785",
"0.75326353",
"0.7504799",
"0.73282856",
"0.72713774",
"0.7251765",
"0.72279876",
"0.71605104",
"0.7132... | 0.8332912 | 0 |
Find and return the index of key in sequence xs | def esJy(fUYa, pan_):
Ae2G = 0
oVTz = len(fUYa)
while True:
if Ae2G == oVTz:
return -1
PK_R = (Ae2G + oVTz) // 2
gtkD = fUYa[PK_R]
if gtkD == pan_:
return PK_R
if gtkD < pan_:
Ae2G = PK_R + 1
else:
oVTz = PK_R | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def aQzf(UqER: Sequence[T], BWXx: S, H5ew: Key=_E99) -> h8nf[int]:\n for YRbF, U6D_ in enumerate(UqER):\n if H5ew(U6D_) == BWXx:\n return YRbF\n return None",
"def kS1Y(H5ew, aWuw, OiSp=None, sAKW=None):\n d6pt = 0\n for U6D_ in aWuw:\n BWXx = U6D_\n if sAKW:\n ... | [
"0.7733152",
"0.77051103",
"0.7699507",
"0.729783",
"0.7297633",
"0.725924",
"0.7254395",
"0.72252786",
"0.71903193",
"0.7185028",
"0.7165899",
"0.7140592",
"0.7131038",
"0.71182674",
"0.7071137",
"0.70164204",
"0.69933",
"0.6914662",
"0.6905327",
"0.68773186",
"0.6859047",
... | 0.0 | -1 |
Finalize a new connection | async def finalizer(YKHO):
await YKHO.connection.send('run stty rows 0\n', override=True)
await YKHO.connection.expect_prompt(override=True) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vNXD(YKHO):\n if YKHO._is_initialized:\n YKHO.logger.debug('Doing something')\n else:\n YKHO.logger.warning('Finalizing before initializing connection to {}'.format(YKHO.name))\n YKHO._is_initialized = False",
"def d1bZ(YKHO):\n pass",
"def VXwn(YKHO):\n if YKHO.__connected:\n ... | [
"0.77073413",
"0.7432252",
"0.7357213",
"0.73254365",
"0.7319839",
"0.7315902",
"0.7256685",
"0.7246503",
"0.724043",
"0.7230166",
"0.7230166",
"0.7230166",
"0.7225855",
"0.72240955",
"0.7222003",
"0.718425",
"0.718425",
"0.71759933",
"0.71532357",
"0.71456426",
"0.7115694",
... | 0.0 | -1 |
collate data in a batch | def X8fE(YKHO, Wc9F):
AIu6 = {}
for wvEv in YKHO.parsers:
ukNS = wvEv.collate(Wc9F)
if ukNS is not None:
AIu6.update(ukNS)
return AIu6 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BrM2(Wc9F):\n UrXw = []\n EKkb = []\n SvcU = []\n for V52X in Wc9F:\n EKkb.append(V52X[2])\n SvcU.append(V52X[1])\n for V52X in Wc9F:\n Z_gq = oyIN.pad(oyIN.array(V52X[0]), pad_width=(0, cYQt - V52X[1]), mode='constant', constant_values=0)\n UrXw.append(Z_gq)\n ret... | [
"0.75158554",
"0.75099504",
"0.749562",
"0.73083866",
"0.69763625",
"0.6966809",
"0.6958266",
"0.6955873",
"0.68839234",
"0.6869574",
"0.68609154",
"0.6860466",
"0.68453825",
"0.68449557",
"0.6840435",
"0.6813496",
"0.6810033",
"0.6791016",
"0.67687255",
"0.6740409",
"0.67254... | 0.6225869 | 73 |
list storage volume for this pool | def list(YKHO):
Crrw = list()
try:
Crrw.extend(YKHO._pool.listVolumes())
except N24X.libvirtError as e:
RKD7.exception(tTpl)
return tuple(Crrw) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def pvpL(QpfX):\n return qezE.get_all(QpfX)",
"def z6d2(YKHO):\n pmON = '/storage-systems/{system-id}/volumes'\n return YKHO._invoke('GET', pmON)",
"def z6d2(_63S):\n kMyc = AMX5(GDm5)\n WihU = OSlF.get_pool(kMyc, spec={'Name': _63S.pool_name})\n for bGrB, U34r in NykA(kMyc).filesystems(props... | [
"0.8001822",
"0.78688496",
"0.7844106",
"0.7597382",
"0.75331646",
"0.75236195",
"0.74393064",
"0.7362086",
"0.7280578",
"0.7218692",
"0.7209615",
"0.7190033",
"0.7169034",
"0.716865",
"0.71672606",
"0.71672606",
"0.71307564",
"0.7125492",
"0.7115691",
"0.7073337",
"0.6970877... | 0.65203655 | 60 |
Average contents of gradient buffers across MPI processes. | def czmn(yR_P):
if NUY7() == 1:
return
for XP5J in yR_P.parameters():
IwFc = XP5J.grad.numpy()
ChbV = YRuD(XP5J.grad)
IwFc[:] = ChbV[:] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oVg1():\n aDYX = 2\n CBmh = gbPf.mkstemp()[1]\n g2zq.spawn(BesT, args=(aDYX, CBmh), nprocs=aDYX, join=True)",
"def y44Y(YKHO, *qIxc):\n return tE_f.viterbi_combined_ss_sptr_pc_output_buffers_full_avg(YKHO, *qIxc)",
"def QuX3(YKHO, *qIxc):\n return tE_f.viterbi_combined_ss_sptr_pc_input_buffe... | [
"0.61790013",
"0.6146434",
"0.60976183",
"0.6082095",
"0.60695136",
"0.6044235",
"0.6036451",
"0.6026434",
"0.6023869",
"0.6022656",
"0.6018374",
"0.6016171",
"0.60139054",
"0.6006534",
"0.5999912",
"0.5999208",
"0.59952724",
"0.5994713",
"0.599236",
"0.5990616",
"0.59771204"... | 0.72367465 | 0 |
Convert spherical coordinates to cylindrical coordinates. | def tEPR(XP5J):
XP5J = oyIN.asarray(XP5J, dtype=float)
vexM = oyIN.empty_like(XP5J)
vexM[..., 0] = XP5J[..., 0] * oyIN.sin(XP5J[..., 1])
vexM[..., 1] = XP5J[..., 2]
vexM[..., 2] = XP5J[..., 0] * oyIN.cos(XP5J[..., 1])
return vexM | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def f7KR(WKvO, LVAh, epBp):\n Mkmy = PZyS(WKvO * WKvO + LVAh * LVAh)\n rVnq = t135(LVAh, WKvO)\n return (Mkmy, rVnq, epBp)",
"def dIOK(WKvO, LVAh, epBp):\n WKvO = WKvO\n oZuG = oyIN.sqrt(LVAh ** 2 + epBp ** 2)\n if epBp:\n q7In = oyIN.arctan(LVAh / epBp)\n else:\n q7In = 0\n ... | [
"0.7454026",
"0.6988516",
"0.692968",
"0.6820797",
"0.6788203",
"0.6717703",
"0.66565907",
"0.66376644",
"0.6569475",
"0.656619",
"0.6543184",
"0.6538566",
"0.6515941",
"0.65084946",
"0.6495785",
"0.6463924",
"0.6444014",
"0.64397025",
"0.6382167",
"0.6377375",
"0.6358632",
... | 0.6560416 | 10 |
Convert cylindrical coordinates to spherical coordinates. | def a33Q(XP5J):
XP5J = oyIN.asarray(XP5J, dtype=float)
vexM = oyIN.empty_like(XP5J)
vexM[..., 0] = oyIN.linalg.norm(XP5J[..., (0, 2)], axis=-1)
vexM[..., 1] = oyIN.arctan2(XP5J[..., 0], XP5J[..., 2])
vexM[..., 2] = XP5J[..., 1]
return vexM | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P5Ey(WKvO, LVAh, epBp):\n Mkmy = PZyS(WKvO * WKvO + LVAh * LVAh + epBp * epBp)\n if Mkmy == 0:\n return (0, 0, 0)\n q7In = D4LM(epBp / Mkmy)\n rVnq = t135(LVAh, WKvO)\n return (Mkmy, q7In, rVnq)",
"def YNIb(WKvO, LVAh, epBp):\n Mkmy = epAf.sqrt(WKvO * WKvO + LVAh * LVAh + epBp * epBp... | [
"0.7301034",
"0.72312677",
"0.7176393",
"0.7176393",
"0.71594477",
"0.7091836",
"0.70364386",
"0.7027061",
"0.6999865",
"0.6991605",
"0.69688714",
"0.6925757",
"0.6896712",
"0.68843675",
"0.68446505",
"0.6843488",
"0.6835714",
"0.6827493",
"0.68070817",
"0.6765993",
"0.673252... | 0.73556757 | 0 |
Identical to builtin `mean_squared_error`, added here as a custom func. | def Ax95(Y8eF, aMgO):
return DDLl.mean(ZylS.math.squared_difference(aMgO, Y8eF), axis=-1) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SDab(P1dF):\n return oyIN.average(P1dF ** 2)",
"def FSiB(P1dF):\n return oyIN.square(oyIN.average(P1dF))",
"def SDab(Y8eF, aMgO, **qIxc):\n return N3vq.metrics.mean_squared_error(Y8eF, aMgO, **qIxc)",
"def R7VQ(P1dF):\n return oyIN.average(P1dF)",
"def SDab(Y8eF, aMgO):\n hkHB = oyIN.mea... | [
"0.7665755",
"0.76110524",
"0.7438493",
"0.7174024",
"0.71090645",
"0.7102945",
"0.70948094",
"0.7094693",
"0.70736843",
"0.7069568",
"0.705866",
"0.7024347",
"0.7015855",
"0.6963878",
"0.6936704",
"0.6926275",
"0.6916539",
"0.68995965",
"0.6871159",
"0.68662375",
"0.6862507"... | 0.69951904 | 13 |
Set application location for this resource provider. | def qlij(YKHO, Hylu):
assert Hylu == '' or Hylu.startswith('/')
if Hylu == '/':
Hylu = ''
assert Hylu in ('', '/') or not Hylu.endswith('/')
YKHO.share_path = Hylu | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Fm6k(YKHO, Rci7):\n YKHO._do_infra._write_pid_value(YKHO._id, 1, 'URL', Rci7)",
"def YK7p(YKHO, Rci7):\n YKHO._location = Rci7",
"def QDqo(YKHO):\n zGKt = YKHO.find_parent(EfQI)\n if zGKt:\n pmON = zGKt.name + '.' + YKHO.name\n else:\n pmON = YKHO.name\n YKHO.location = YKHO... | [
"0.69726694",
"0.6189931",
"0.6168643",
"0.6122008",
"0.60070676",
"0.59990513",
"0.5983935",
"0.5983935",
"0.5972995",
"0.59657663",
"0.59152573",
"0.5900447",
"0.5900447",
"0.5900447",
"0.5900447",
"0.5900447",
"0.5855962",
"0.5855962",
"0.5855962",
"0.5855962",
"0.5855962"... | 0.0 | -1 |
Resizes image. This is a wrap of `cv2.resize()`. | def lmn5(LNo8, *qIxc, **B2fa):
if LNo8 is None:
return None
assert LNo8.ndim == 3 and LNo8.shape[2] in [1, 3]
LNo8 = XC5k.resize(LNo8, *qIxc, **B2fa)
if LNo8.ndim == 2:
return LNo8[:, :, oyIN.newaxis]
return LNo8 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GMoO(LNo8, zNig):\n return XC5k.resize(LNo8, zNig, interpolation=XC5k.INTER_AREA)",
"def wNzd(YKHO, LNo8):\n return XC5k.resize(LNo8, dsize=(YKHO.image_size[0], YKHO.image_size[1]), interpolation=XC5k.INTER_AREA)",
"def lmn5(YKHO, VXjJ, NXpY):\n H2v2, TVTK, xMux = VXjJ.shape\n C2f8 = int(H2v2 *... | [
"0.84044945",
"0.8326593",
"0.80928755",
"0.8047907",
"0.8012155",
"0.7974963",
"0.7917186",
"0.7916046",
"0.7894869",
"0.780301",
"0.777123",
"0.77424",
"0.7720465",
"0.7708539",
"0.7708467",
"0.76976514",
"0.7681145",
"0.7681145",
"0.7633154",
"0.7624091",
"0.7623795",
"0... | 0.7122461 | 71 |
Postprocesses image to pixel range [0, 255] with dtype `uint8`. | def sqqL(LNo8, kpLf=-1.0, JCoA=1.0, wH3T='NCHW'):
assert isinstance(LNo8, oyIN.ndarray)
LNo8 = LNo8.astype(oyIN.float64)
LNo8 = (LNo8 - kpLf) * 255 / (JCoA - kpLf)
LNo8 = oyIN.clip(LNo8 + 0.5, 0, 255).astype(oyIN.uint8)
wH3T = wH3T.upper()
if wH3T == 'NCHW':
assert LNo8.ndim == 4 and LNo... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MV6i(VXjJ):\n VXjJ = oyIN.resize(VXjJ, (3, VXjJ.shape[2], VXjJ.shape[3]))\n VXjJ[0, :] += 123.68\n VXjJ[1, :] += 116.779\n VXjJ[2, :] += 103.939\n VXjJ = oyIN.swapaxes(VXjJ, 0, 2)\n VXjJ = oyIN.swapaxes(VXjJ, 0, 1)\n VXjJ = oyIN.clip(VXjJ, 0, 255)\n return VXjJ.astype('uint8')",
"def ... | [
"0.7522228",
"0.72177356",
"0.7213236",
"0.70880425",
"0.708106",
"0.6953267",
"0.6851783",
"0.6832902",
"0.6826553",
"0.6736718",
"0.6711596",
"0.6700315",
"0.6659479",
"0.6657848",
"0.6604526",
"0.6603985",
"0.6597097",
"0.6574965",
"0.65740424",
"0.6533197",
"0.65014625",
... | 0.0 | -1 |
Split file name by the '.' and check the allowed extension | def XT0o(Ux0P):
return '.' in Ux0P and Ux0P.rsplit('.', 1)[1].lower() in y8cn.ALLOWED_EXTENSIONS | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def yKZI(Ux0P, z07C):\n if '.' not in Ux0P:\n raise ValueError('filename does not include extension')\n if Ux0P.rsplit('.', 1)[1].lower() not in vju9:\n raise ValueError('file extension is not valid')",
"def XT0o(Ux0P: str) -> str:\n return '.' in Ux0P and Ux0P.rsplit('.', 1)[1].lower() in... | [
"0.805506",
"0.8034381",
"0.7960838",
"0.7960838",
"0.79504424",
"0.79434174",
"0.79434174",
"0.789835",
"0.78924954",
"0.7885902",
"0.78827083",
"0.78827083",
"0.78827083",
"0.78827083",
"0.78827083",
"0.78827083",
"0.78827083",
"0.78827083",
"0.78827083",
"0.78827083",
"0.7... | 0.7838485 | 23 |
Determine the device class for this binary sensor. | async def _determine_device_class(YKHO):
YV4q = IywN.get(YKHO._zha_sensor_type)
if callable(YV4q):
YwkQ = YKHO.cluster_channels.get(YKHO._zha_sensor_type)
if YwkQ is None:
return None
return await YV4q(YwkQ)
return YV4q | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rM2U(YKHO):\n return YKHO.sensor_details[4]",
"def rM2U(YKHO):\n return YKHO._sensor.get(F6ct)",
"def rM2U(YKHO):\n return A53S",
"def rM2U(YKHO):\n return FBLU[YKHO.sensor_name][1]",
"def rM2U(YKHO):\n return YKHO._sensor_type",
"def rM2U(YKHO):\n return YKHO._sensor_type",
"def ... | [
"0.87712884",
"0.8758797",
"0.8672747",
"0.86343837",
"0.85992384",
"0.85992384",
"0.85992384",
"0.85992384",
"0.8523704",
"0.82111657",
"0.81877214",
"0.8176377",
"0.8044134",
"0.8035439",
"0.80273664",
"0.8027195",
"0.80260456",
"0.80249846",
"0.8005005",
"0.79802966",
"0.7... | 0.7761061 | 46 |
Return device class from component DEVICE_CLASSES. | def rM2U(YKHO) -> str:
return YKHO._device_class | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rM2U(YKHO):\n return YKHO._sensor.get(F6ct)",
"def rM2U(YKHO):\n return YKHO._handle('device_class')",
"def rM2U(YKHO) -> str:\n return YKHO._dev_cls",
"def rM2U(YKHO) -> str:\n return eeT9",
"def rM2U(YKHO):\n return YKHO.sensor_details[4]",
"def rM2U(YKHO):\n return eeT9",
"def ... | [
"0.8100123",
"0.80691385",
"0.7958922",
"0.7916598",
"0.7882912",
"0.7860349",
"0.78506404",
"0.7848833",
"0.78319913",
"0.77810794",
"0.77508235",
"0.77495414",
"0.7699499",
"0.76934224",
"0.76909626",
"0.76880074",
"0.76880074",
"0.76880074",
"0.76880074",
"0.76880074",
"0.... | 0.776746 | 10 |
Transform a sympy equation to be printed in word document. | def JDqe(cIT_, InF8=None):
MbAP = hkb5(cIT_, printer='presentation')
if InF8 is None:
ODye = '\n <math xmlns="http://www.w3.org/1998/Math/MathML">\n {}\n </math>\n '.format(MbAP)
else:
ODye = '\n <math xmlns="http://www.w3.org/1998/M... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ykcg(VN2L):\n return _svw(VN2L)",
"def _svw(YKHO, BZ29, nUeQ):\n Mkmy = G4JS.get('http://latex.codecogs.com/png.latex?\\\\dpi{300} \\\\huge ' + BZ29)\n eHNT = open(nUeQ, 'wb+')\n eHNT.write(Mkmy.content)\n eHNT.close()",
"def eMsG(YKHO):\n from sage.misc.latex import latex\n return lat... | [
"0.68583024",
"0.674785",
"0.67190343",
"0.6628617",
"0.6590984",
"0.6542089",
"0.6488262",
"0.63739306",
"0.63572544",
"0.6325758",
"0.6306177",
"0.6301953",
"0.620451",
"0.6181376",
"0.61701",
"0.6151854",
"0.6149255",
"0.6139948",
"0.6107024",
"0.6106579",
"0.6074383",
"... | 0.66536665 | 3 |
Instantiate the connection to the InfluxDB client. | def b8V_(KcEq='localhost', bIwZ=8086):
CBIr = 'hoshang'
jTXt = 'test'
_M9w = 'influxpy'
iquo = 'json'
x0hE = KmTz(KcEq, bIwZ, CBIr, jTXt, _M9w)
print('Create DataFrame')
Fg_i = Bc6b()
ezWE = oyIN.array([Fg_i])
Lgz5 = oyIN.delete(ezWE, 0)
u54L = len(Lgz5)
print(Lgz5)
Lgz5[... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO):\n YKHO.user = 'root'\n YKHO.password = 'root'\n YKHO.dbname = 'virturian'\n YKHO.host = 'localhost'\n YKHO.port = 8086\n YKHO.client = KmTz(YKHO.host, YKHO.port, YKHO.user, YKHO.password, YKHO.dbname)",
"def FIMM(YKHO, Nu1S: Dict[str, Any]):\n if not Nu1S:\n raise Valu... | [
"0.8476018",
"0.7902907",
"0.7857821",
"0.78333426",
"0.7779284",
"0.77431524",
"0.7619416",
"0.76117283",
"0.7479206",
"0.743896",
"0.721605",
"0.70892715",
"0.67663234",
"0.67205113",
"0.6653662",
"0.66401863",
"0.66",
"0.65688986",
"0.65198195",
"0.6442455",
"0.63207656",
... | 0.0 | -1 |
Return aliased field name. !!! warning "Deprecated" This method is deprecated could be removed without further warning. Please use [`get_backend_field()`][optimade.server.mappers.entries.BaseResourceMapper.get_backend_field]. | def WVcP(Emd4, Jyyj: str) -> str:
qmLP.warn('The `.alias_for(...)` method is deprecated, please use `.get_backend_field(...)`.', DeprecationWarning)
return Emd4.get_backend_field(Jyyj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def j1IA(Emd4, Jyyj: str) -> str:\n qmLP.warn('The `.alias_of(...)` method is deprecated, please use `.get_optimade_field(...)`.', DeprecationWarning)\n return Emd4.get_optimade_field(Jyyj)",
"def JLFP(Emd4, k_4P: str) -> str:\n lpha = k_4P.split('.')\n vbQv = dict(Emd4.all_aliases()).get(lpha[0], No... | [
"0.7996266",
"0.7832328",
"0.77077276",
"0.7115224",
"0.6747426",
"0.6732105",
"0.665234",
"0.665234",
"0.66469646",
"0.6645402",
"0.6639903",
"0.6610608",
"0.66073453",
"0.6567205",
"0.6537637",
"0.6537637",
"0.64374596",
"0.6425644",
"0.6417025",
"0.6414387",
"0.6396115",
... | 0.85594386 | 0 |
Return the corresponding OPTIMADE field name for the underlying database field, ready to be used to construct the OPTIMADEcompliant JSON response. Aliases are read from [`all_aliases()`][optimade.server.mappers.entries.BaseResourceMapper.all_aliases]. | def EbXW(Emd4, gG7e: str) -> str:
return {vbQv: wWvP for wWvP, vbQv in Emd4.all_aliases()}.get(gG7e, gG7e) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def mWFP(YKHO):\n return f'{YKHO.alias} Odometer'",
"def WVcP(Emd4, Jyyj: str) -> str:\n lpha = Jyyj.split('.')\n vbQv = dict(Emd4.all_aliases()).get(lpha[0], None)\n if vbQv is not None:\n return vbQv + ('.' + '.'.join(lpha[1:]) if len(lpha) > 1 else '')\n return Jyyj",
"def JLFP(Emd4, k... | [
"0.6874206",
"0.67474264",
"0.67273134",
"0.6694154",
"0.6488319",
"0.6315873",
"0.6298786",
"0.6251018",
"0.6251018",
"0.62192386",
"0.62041914",
"0.6195647",
"0.6138724",
"0.6094947",
"0.60653394",
"0.60592383",
"0.60542274",
"0.6053277",
"0.6048636",
"0.60419023",
"0.60419... | 0.6895902 | 0 |
Given key/value pair, query server and return first of returned parsed xml objects, or None if there is no match | def bgGN(N5z6, eOtH, H5ew, BWXx):
xDcj = N5z6 + '/object.xml?key=' + H5ew + '&value=' + BWXx
x0hE = xuMJ.OAuthClient(eOtH)
geh0 = x0hE.get(xDcj)
if geh0.status_code != 200:
raise Exception('Bad server response. Expected 200. Got %s' % geh0.status_code)
B9Ou = None
try:
B9Ou = QGp... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Z2VO(YKHO, Wpud, kvqp, AtOn, cntZ=True):\n ei4T = Wpud.find(kvqp)\n if ei4T is None:\n return None\n dfOq = []\n H5ew, BWXx = AtOn\n for object in ei4T.getchildren():\n Id_n = object.findtext(H5ew)\n if Id_n and (Id_n == BWXx or BWXx is None):\n if cntZ:\n ... | [
"0.6249804",
"0.6213349",
"0.61905813",
"0.60655004",
"0.60485846",
"0.59972334",
"0.5923994",
"0.5923086",
"0.58734477",
"0.5852081",
"0.5849842",
"0.5801907",
"0.57927364",
"0.5775728",
"0.57368827",
"0.5736414",
"0.57139134",
"0.56809986",
"0.5612557",
"0.5595993",
"0.5561... | 0.6519483 | 0 |
Returns number of bridges currently connected to self. | def JOTC(YKHO):
return len(YKHO.bridges) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NHn7(YKHO, AAbN):\n Fg_i = YFAJ(YKHO, AAbN)\n return YKHO.bridges.count(Fg_i)",
"def AhgJ(YKHO):\n return YKHO.graph.number_of_edges()",
"def v3QF(YKHO):\n return len(YKHO.connections)",
"def UHFx(YKHO):\n return len(YKHO.connected_positions)",
"def szAg(YKHO):\n return len(YKHO.bridg... | [
"0.72971183",
"0.7098299",
"0.70479417",
"0.6987841",
"0.6921739",
"0.691597",
"0.6894296",
"0.68649846",
"0.685667",
"0.670162",
"0.6682511",
"0.6661993",
"0.662791",
"0.6626481",
"0.6620541",
"0.6599671",
"0.65901846",
"0.65789944",
"0.65760803",
"0.6546246",
"0.6541388",
... | 0.84517944 | 0 |
Returns true if self intersects with other bridge. | def P10m(YKHO, Elif):
if Elif.orientation == YKHO.orientation:
return False
if YKHO.orientation == 1:
return Elif.island1.y > YKHO.island1.y and Elif.island1.y < YKHO.island2.y and (YKHO.island1.x > Elif.island1.x) and (YKHO.island1.x < Elif.island2.x)
else:
return YKHO.island1.y > E... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P10m(YKHO, Elif):\n return bool(YKHO.impl['intersects'](YKHO, Elif))",
"def XMlP(YKHO, Elif: object) -> bool:\n qI4s = YKHO.x1 <= Elif.x2 + 1 and YKHO.x2 >= Elif.x1 - 1 and (YKHO.y1 <= Elif.y2 + 1) and (YKHO.y2 >= Elif.y1 - 1)\n return qI4s",
"def jI2t(YKHO, Elif):\n if YKHO.intersects(Elif):\n... | [
"0.7886566",
"0.76807505",
"0.7637",
"0.7636324",
"0.76196235",
"0.7530332",
"0.7429105",
"0.7428741",
"0.72835773",
"0.7254647",
"0.7212896",
"0.7205088",
"0.7160741",
"0.7133496",
"0.7133496",
"0.71069026",
"0.70851415",
"0.70529515",
"0.70529515",
"0.7020547",
"0.7018045",... | 0.71750325 | 12 |
Returns True if all islands are complete (capacities are 0), returns False otherwise. | def gjTx(YKHO):
for lzzU in YKHO.island_list:
if not lzzU.complete:
return False
return True | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZZQq(YKHO):\n return all((YRbF != 0 for YRbF in YKHO.board.flatten()))",
"def ZZQq(YKHO) -> bool:\n VzA7, eJ14 = oyIN.where(YKHO.assignments_data == -1)\n return len(VzA7) == 0",
"def BvAk(YKHO):\n vllA = oyIN.sum([len(Ty9i) for bGrB, Ty9i in YKHO.getOrphanGroups().items()])\n kiHo = oyIN.su... | [
"0.7519932",
"0.6973891",
"0.68706113",
"0.68697494",
"0.6841008",
"0.683925",
"0.67655945",
"0.67266566",
"0.6698035",
"0.6686244",
"0.6668272",
"0.6627501",
"0.65772194",
"0.6543227",
"0.6487441",
"0.64727193",
"0.6446039",
"0.6420283",
"0.64053833",
"0.64005613",
"0.640056... | 0.82186544 | 0 |
Helper function to check status of grid. Checks each individual island. If an island has a larger capacity than available connections, the grid is incorrect. If an island has a smaller capacity than available connections, the grid is incomplete. Incorrect trumps incomplete. Returns 1 if incorrect, 0 if incomplete, 1 if... | def sf96(YKHO):
lKVu = {}
for eV_n in YKHO.bridges.bridge_list:
Fg_i = (eV_n.island1.x, eV_n.island1.y, eV_n.island2.x, eV_n.island2.y)
lKVu[Fg_i] = lKVu.get(Fg_i, 0) + 1
for BWz1 in lKVu.values():
if BWz1 > 2:
return -1
for lzzU in YKHO.islands.island_list:
S... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oPb6(iBIi):\n return 0 not in [iBIi[WKvO][LVAh] for WKvO, LVAh in CsJN]",
"def yOZO(YKHO):\n y7Lu = False\n for YRbF in range(4):\n for r845 in range(4):\n if r845 < 3 and YKHO.data[YRbF][r845] == YKHO.data[YRbF][r845 + 1] and (YKHO.data[YRbF][r845] != 0):\n y7Lu = T... | [
"0.68265176",
"0.6823222",
"0.6680579",
"0.6549989",
"0.6455198",
"0.6383597",
"0.6379733",
"0.63738537",
"0.63169295",
"0.6300435",
"0.6271796",
"0.62623745",
"0.6213272",
"0.6198306",
"0.61946326",
"0.6182701",
"0.6149819",
"0.61329985",
"0.6128821",
"0.61144835",
"0.611206... | 0.6222098 | 12 |
Turn a plaintext password into a hash for database storage. | def Veoc(Ud05: str) -> str:
return N7bY.hash(Ud05) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def a2tF(jTXt):\n return B8ni.hashpw(jTXt.encode('utf-8'), B8ni.gensalt())",
"def D2Lq(jTXt):\n return HBct.sha256(str.encode(jTXt)).hexdigest()",
"def qzFd(uxvb=''):\n jTXt = 0\n YRbF = 1\n for hcXw in uxvb:\n BWXx = ord(hcXw) << YRbF\n SdyP = BWXx >> 15\n BWXx &= 32767\n ... | [
"0.776673",
"0.7758526",
"0.7656249",
"0.7653019",
"0.765244",
"0.75893223",
"0.75852644",
"0.74971926",
"0.74929225",
"0.7466651",
"0.7466651",
"0.74607354",
"0.7445827",
"0.74456173",
"0.7441645",
"0.7417118",
"0.74130094",
"0.74078923",
"0.7397315",
"0.738067",
"0.73777515... | 0.72083306 | 62 |
Uses the animations configuration to load and parse a spritesheet. | def RDyG(YKHO, mWFP):
if mWFP not in YKHO.config['animations'].keys():
raise ValueError('Must provide the name of an existing animation configuration')
zTdJ = YKHO.config['animations'][mWFP]
qP20 = mXyq(paSb + zTdJ['filename'], size=zTdJ['size'], resize_to=zTdJ['scale_to'], starting_coords=zTdJ['sta... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def f8hO(VqRE, Ux0P, mawX, XVpZ=None, lGbz=True, VIPT=10):\n gugw = VRpK.load_image_file(VqRE, Ux0P)\n UHFx = gugw.get_width() / mawX.width\n return kjcW(gugw, mawX, UHFx, XVpZ, lGbz, VIPT)",
"def FKoR(Ux0P, VIPT=[], RcXH=100, oeNL=(0, 0), DWJ0=(0, 0, 0), NXpY=1, pAsL=(1, 1, 1, 1)):\n tTee.require_in... | [
"0.6703103",
"0.66709596",
"0.6563513",
"0.6546717",
"0.65309924",
"0.64939433",
"0.6467877",
"0.64667726",
"0.63901436",
"0.6387276",
"0.63440675",
"0.6302589",
"0.6298793",
"0.62831974",
"0.62700385",
"0.6265572",
"0.6229946",
"0.61420053",
"0.61165696",
"0.6105354",
"0.610... | 0.70304066 | 0 |
Log Errors caused by Updates. | def P1dF(JyK9, QdZT, P1dF):
bo34.warning('Update "%s" caused error "%s"', QdZT, P1dF) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P1dF(JyK9, QdZT, P1dF):\n bo34.warning('Error: \"%s\" caused error \"%s\"', QdZT, P1dF)\n bo34.setLevel(G9jH.DEBUG)",
"def rP1w(QdZT, QpfX):\n bo34.warning(f'Update \"{QdZT}\" caused error {QpfX.error}\"')",
"def P1dF(QdZT, QpfX):\n G9jH.error('Update \"%s\" caused error \"%s\"', QdZT, QpfX.err... | [
"0.7895395",
"0.788395",
"0.78750193",
"0.7873498",
"0.78300834",
"0.7790406",
"0.7785151",
"0.77837753",
"0.77837753",
"0.77837753",
"0.77837753",
"0.77837753",
"0.7781314",
"0.77660847",
"0.7746185",
"0.7746185",
"0.7746185",
"0.7746185",
"0.7746185",
"0.7746185",
"0.774618... | 0.75354177 | 75 |
Horizontally flip the given PIL Image. | def EXQN(VXjJ):
if not Qfi2(VXjJ):
raise TypeError('img should be PIL Image. Got {}'.format(type(VXjJ)))
return VXjJ.transpose(hnIv.FLIP_LEFT_RIGHT) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Hl5t(VXjJ):\n if not RDRa(VXjJ):\n raise TypeError(t_1q.format(type(VXjJ)))\n return VXjJ.transpose(YGpq)",
"def Hl5t(YKHO, Tz44, gb5P):\n VXjJ = Yw_3.Image(Tz44.data)\n VXjJ.horizontal_flip()\n T4M1 = VXjJ.execute_transforms(gb5P)\n return T4M1",
"def il8A(VXjJ):\n if not Qfi2(... | [
"0.8472074",
"0.7824385",
"0.7799562",
"0.7799562",
"0.7781026",
"0.7598562",
"0.7572767",
"0.7518076",
"0.75063026",
"0.74443066",
"0.7404436",
"0.73519427",
"0.73247385",
"0.729987",
"0.72885174",
"0.72612834",
"0.7233946",
"0.72118354",
"0.7197379",
"0.71954644",
"0.719007... | 0.7457507 | 10 |
Vertically flip the given PIL Image. | def il8A(VXjJ):
if not Qfi2(VXjJ):
raise TypeError('img should be PIL Image. Got {}'.format(type(VXjJ)))
return VXjJ.transpose(hnIv.FLIP_TOP_BOTTOM) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xPm2(VXjJ):\n if not RDRa(VXjJ):\n raise TypeError(t_1q.format(type(VXjJ)))\n return VXjJ.transpose(nv4g)",
"def xPm2(YKHO, Tz44, gb5P):\n VXjJ = Yw_3.Image(Tz44.data)\n VXjJ.vertical_flip()\n T4M1 = VXjJ.execute_transforms(gb5P)\n return T4M1",
"def mwd5(YKHO):\n YKHO.cv2_image... | [
"0.8557656",
"0.8076509",
"0.79829776",
"0.79804564",
"0.7853266",
"0.7700559",
"0.76852536",
"0.7623243",
"0.75245774",
"0.7418734",
"0.74095243",
"0.7397633",
"0.7386739",
"0.73433995",
"0.7333078",
"0.7318435",
"0.7309103",
"0.7309028",
"0.72922224",
"0.72912234",
"0.72881... | 0.8235912 | 2 |
Horizontally flip the given PIL Image. | def EXQN(VXjJ):
if not Qfi2(VXjJ):
raise TypeError('img should be PIL Image. Got {}'.format(type(VXjJ)))
return VXjJ.transpose(hnIv.FLIP_LEFT_RIGHT) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Hl5t(VXjJ):\n if not RDRa(VXjJ):\n raise TypeError(t_1q.format(type(VXjJ)))\n return VXjJ.transpose(YGpq)",
"def Hl5t(YKHO, Tz44, gb5P):\n VXjJ = Yw_3.Image(Tz44.data)\n VXjJ.horizontal_flip()\n T4M1 = VXjJ.execute_transforms(gb5P)\n return T4M1",
"def il8A(VXjJ):\n if not Qfi2(... | [
"0.84713465",
"0.7824768",
"0.7797967",
"0.7797967",
"0.7780622",
"0.7597435",
"0.75710785",
"0.751702",
"0.7504328",
"0.7442441",
"0.7404697",
"0.735035",
"0.73226225",
"0.729929",
"0.7286806",
"0.726035",
"0.72347635",
"0.721116",
"0.7197945",
"0.71951956",
"0.7189003",
"... | 0.74564666 | 10 |
Vertically flip the given PIL Image. | def il8A(VXjJ):
if not Qfi2(VXjJ):
raise TypeError('img should be PIL Image. Got {}'.format(type(VXjJ)))
return VXjJ.transpose(hnIv.FLIP_TOP_BOTTOM) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xPm2(VXjJ):\n if not RDRa(VXjJ):\n raise TypeError(t_1q.format(type(VXjJ)))\n return VXjJ.transpose(nv4g)",
"def xPm2(YKHO, Tz44, gb5P):\n VXjJ = Yw_3.Image(Tz44.data)\n VXjJ.vertical_flip()\n T4M1 = VXjJ.execute_transforms(gb5P)\n return T4M1",
"def mwd5(YKHO):\n YKHO.cv2_image... | [
"0.855748",
"0.8079085",
"0.7984333",
"0.7980446",
"0.7854281",
"0.77021796",
"0.7686674",
"0.7626213",
"0.7527344",
"0.7420833",
"0.7413142",
"0.73998284",
"0.73865783",
"0.7343921",
"0.7334641",
"0.7319346",
"0.73114645",
"0.7310191",
"0.7294711",
"0.72939116",
"0.7290285",... | 0.8236416 | 1 |
Takes a batch of experiences and returns a list of single experiences | def qmkO(Wc9F: torch.Tensor) -> x1iM[cuzp[str, ht2j.Tensor]]:
vwlo = Wc9F['reward']
C1UW = Wc9F['prev_state']
wspz = Wc9F['state']
xASv = Wc9F['action']
return [{'reward': Mkmy, 'prev_state': XP5J, 'state': KCHu, 'action': jzdc} for Mkmy, XP5J, KCHu, jzdc in zip(vwlo, C1UW, wspz, xASv)] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xg_e(wfZK):\n gGnb = [mvm2 for GsKL in wfZK for mvm2 in GsKL]\n XtiD = [qtWj for qtWj, bGrB in gGnb]\n Crrw = [UXqs for bGrB, UXqs in gGnb]\n return (XtiD, Crrw)",
"def ebrE():\n try:\n GsKL = NCls.Experience.find()\n except Exception as e:\n print('ERROR READING FILE:', tTpl)... | [
"0.6619464",
"0.65051705",
"0.64436376",
"0.62736875",
"0.6219627",
"0.6134721",
"0.6103065",
"0.60672915",
"0.6013541",
"0.5894517",
"0.58589596",
"0.58344185",
"0.58134496",
"0.5805696",
"0.5750308",
"0.5747613",
"0.5738004",
"0.57133096",
"0.5674961",
"0.56736815",
"0.5657... | 0.0 | -1 |
Test board values validation. | def kHGK(YKHO):
iBIi = oyIN.arange(4).reshape((2, 2))
YKHO.assertRaises(ValueError, EpyS, iBIi)
iBIi = oyIN.zeros([2, 2])
iBIi[0, 0] = -1
YKHO.assertRaises(ValueError, EpyS, iBIi)
iBIi = oyIN.ones([2, 2])
Aofo = EpyS(iBIi)
YKHO.assert_array_equal(Aofo, iBIi) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kIUt(YKHO):\n iBIi = oyIN.zeros([1, 1])\n YKHO.assertRaises(TypeError, EpyS, iBIi)\n iBIi = oyIN.zeros([0, 0])\n YKHO.assertRaises(TypeError, EpyS, iBIi)\n iBIi = oyIN.zeros([2, 0])\n YKHO.assertRaises(TypeError, EpyS, iBIi)\n iBIi = oyIN.zeros([0, 2])\n YKHO.assertRaises(TypeError, Epy... | [
"0.75290585",
"0.7513841",
"0.74210745",
"0.73411816",
"0.72389567",
"0.71903247",
"0.71443284",
"0.70968044",
"0.70808303",
"0.704431",
"0.70379436",
"0.70309365",
"0.7027078",
"0.69570506",
"0.69552565",
"0.69509417",
"0.6938646",
"0.69377697",
"0.6904927",
"0.6853547",
"0.... | 0.82762206 | 0 |
Get all dispositions that are in status 'disposed' and have a SIP. | def Pzmt(YKHO):
xDcj = dict(object_provides=ueIg.__identifier__, review_state='disposition-state-disposed')
YQs6 = YKHO.catalog.unrestrictedSearchResults(xDcj)
for ycAf in YQs6:
hMDX = ycAf.getObject()
if hMDX.is_scheduled_for_delivery():
yield hMDX | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def reJz(YKHO, lo9Y):\n return YKHO.get_observations(observation_question_status=['closed'], observation_finalisation_reason=lo9Y)",
"def r3YV(YKHO):\n return YKHO.filter(active=True)",
"def W0ev(YKHO):\n return [Ty9i for bGrB, Ty9i in YKHO._values_confirm_message.iteritems()]",
"def vWDH(YKHO):\n ... | [
"0.5656193",
"0.5150081",
"0.5107566",
"0.5094971",
"0.5027492",
"0.49887526",
"0.4985489",
"0.49586013",
"0.49479166",
"0.4945079",
"0.4919384",
"0.48843637",
"0.48508477",
"0.48481017",
"0.48384246",
"0.48246497",
"0.48236322",
"0.47841695",
"0.4783281",
"0.47809672",
"0.47... | 0.6931069 | 0 |
Returns True if this stock is bankrupt. | def lEVH(YKHO):
return sum(YKHO._last_values) / len(YKHO._last_values) < YKHO.BANKRUPCY_LIMIT | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ksW5(YKHO):\n return YKHO.available() > 0 or YKHO.unknown_stock",
"def epo2(BH3N):\n tRnr = BH3N.current_player()\n if tRnr.has_no_cash():\n jYXP(BH3N)",
"def TkvI(YKHO):\n return YKHO.pcs_in_stock > 0",
"def xv6Y(YKHO):\n _Y0l = YKHO.methods.presence_of_element_located(YKHO.OUT_OF_... | [
"0.7131585",
"0.6849792",
"0.6688761",
"0.6458738",
"0.6453136",
"0.6441299",
"0.64232856",
"0.6412049",
"0.6405676",
"0.6328595",
"0.62455934",
"0.6225942",
"0.6224603",
"0.61665463",
"0.6158152",
"0.6150055",
"0.6116332",
"0.6084692",
"0.6065303",
"0.6050594",
"0.6043768",
... | 0.76572466 | 0 |
Access a Windows registry key path. | def FIMM(YKHO, pmON, Nv8g=None, y4ha=False):
if Nv8g is None:
KkWy = pmON.split(Hy7s.path.sep)
YKHO._hkey_name = KkWy[0].upper()
pmON = Hy7s.path.join(*KkWy[1:])
Nv8g = getattr(ZsEo, YKHO._hkey_name, None)
if not isinstance(Nv8g, KvA9):
raise CJax("Couldn't find H... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZSJv(YKHO, uf9D):\n try:\n import _winreg\n except ImportError:\n return\n else:\n D70z = _winreg.HKEY_CURRENT_USER\n HlF_ = _winreg.HKEY_LOCAL_MACHINE\n try:\n MicQ = _winreg.QueryReflectionKey(HlF_)\n except NotImplemented:\n I1mm = _winreg.KEY_READ\n ... | [
"0.71381867",
"0.68613863",
"0.6630549",
"0.65764236",
"0.65246403",
"0.64952165",
"0.64312863",
"0.62525773",
"0.6241059",
"0.6210214",
"0.61686975",
"0.6163764",
"0.6096802",
"0.60606664",
"0.5995532",
"0.5993059",
"0.59663236",
"0.5961815",
"0.59575343",
"0.5955096",
"0.59... | 0.0 | -1 |
Iterate over all Keys and values under this Key Recursive if deep is set to True | def Vs4Q(YKHO):
for Q2PR in YKHO.enum_values():
yield _3Ta(*Q2PR)
for D__j in YKHO.enum_keys():
H5ew = YKHO.get_sub_key(D__j)
yield H5ew
if YKHO._deep:
with H5ew:
for ZfUD in H5ew:
yield ZfUD | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FXe4(Csk6, sjXb=()):\n if isinstance(Csk6, dict):\n for G1Hx, Ty9i in Csk6.iteritems():\n for im04 in FXe4(Ty9i, sjXb + (G1Hx,)):\n yield im04\n else:\n yield (sjXb, Csk6)",
"def xI2Z(YKHO, rb7a=0):\n sjXb = [[G1Hx] for G1Hx in YKHO.dict.keys()]\n for G1Hx ... | [
"0.6565961",
"0.6548997",
"0.65383697",
"0.6459616",
"0.63954306",
"0.63954306",
"0.6372228",
"0.6349714",
"0.63398665",
"0.63300925",
"0.6289519",
"0.6286524",
"0.6212716",
"0.6160255",
"0.61391723",
"0.61145276",
"0.61016023",
"0.6095685",
"0.60758215",
"0.60684544",
"0.603... | 0.59417087 | 23 |
data 1 and 2 in the format of tuples in list | def Z629(BZgl, X9Rj):
ry8G = {}
for WKvO, LVAh in BZgl:
if LVAh not in ry8G:
ry8G[LVAh] = [WKvO]
else:
ry8G[LVAh].append(WKvO)
Aofo = []
for LVAh, epBp in X9Rj:
if LVAh in ry8G:
for WKvO in ry8G[LVAh]:
Aofo.append((WKvO, LVAh, e... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hkxX(YKHO):\n vC9B = list()\n for tTpl in YKHO.__data_list:\n BWXx = tTpl.value\n vC9B.append(BWXx)\n return tuple(vC9B)",
"def eTEZ(YKHO, MOPg=[], nPrm=[], NeQN='Data'):\n eEZP = []\n tySv = g760.namedtuple(NeQN, MOPg)\n for DpUl in range(0, len(nPrm)):\n eEZP.append(t... | [
"0.6930815",
"0.6802443",
"0.67571676",
"0.675489",
"0.6715065",
"0.6646555",
"0.66406155",
"0.65987206",
"0.65759504",
"0.65647006",
"0.6536367",
"0.6536367",
"0.6481799",
"0.64651823",
"0.6460824",
"0.6447494",
"0.64378667",
"0.64272046",
"0.642382",
"0.6404798",
"0.6392673... | 0.0 | -1 |
Gets the graphics coordinates for the center of the cell at the given (row, col) position | def yafE(YKHO, dQgj):
WKvO = int(dQgj[1] * YKHO._cell_size[0] + YKHO._cell_size[0] / 2)
LVAh = int(dQgj[0] * YKHO._cell_size[1] + YKHO._cell_size[1] / 2)
return (WKvO, LVAh) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hhcg(YKHO, rdlD, fvDH):\n WKvO = fvDH * YKHO.resolution + 0.5 * YKHO.resolution + YKHO.origin_x\n LVAh = rdlD * YKHO.resolution + 0.5 * YKHO.resolution + YKHO.origin_y\n return (WKvO, LVAh)",
"def gZfx(rdlD, fvDH, RoH9, qn8i, dNbc, PX5t, HN6s, co3n):\n WKvO = RoH9 + 0.5 * dNbc + fvDH * dNbc\n ... | [
"0.82243675",
"0.8100807",
"0.7983279",
"0.79054284",
"0.7765745",
"0.7746778",
"0.7669831",
"0.7528593",
"0.75242436",
"0.7489879",
"0.72685814",
"0.7158643",
"0.7131331",
"0.70701593",
"0.7061747",
"0.7058224",
"0.702554",
"0.7015672",
"0.6995144",
"0.6993837",
"0.699334",
... | 0.7614415 | 7 |
Start the stopwatch, ignore if running. | def xQEZ(YKHO):
if not YKHO._running:
YKHO._start = ITS7.time() - YKHO._elapsedtime
YKHO._update()
YKHO._running = 1 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def K1qX(YKHO):\n if YKHO.running:\n YKHO.timer_stop()\n else:\n YKHO.timer_start()",
"def K1qX(YKHO):\n YKHO._running = not YKHO._running",
"def K1qX(YKHO, *qIxc):\n if not YKHO.is_timing:\n YKHO.is_timing = True\n YKHO.start_time = qcWV.now()\n YKHO.ids['start_s... | [
"0.74170667",
"0.70602083",
"0.68850005",
"0.6614999",
"0.6574768",
"0.65395033",
"0.6509612",
"0.6503862",
"0.6503862",
"0.6503862",
"0.6411134",
"0.6407949",
"0.63498956",
"0.6329514",
"0.6268679",
"0.62135416",
"0.61888427",
"0.6143592",
"0.61390775",
"0.6120136",
"0.61080... | 0.6088218 | 22 |
Returns the string representation of the Entity | def zAg0(YKHO):
return f"Entity('{YKHO.get_id()}')" | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__entities)",
"def zAg0(YKHO):\n KCHu = 'fireform.entity at {} {}\\n'.format(hex(id(YKHO)), '' if YKHO.alive else '(DEAD)')\n KCHu += ' data:\\n'\n for YRbF, r845 in YKHO.datum.items():\n if isinstance(YRbF, str) or not r845.has_name():\n KCHu +=... | [
"0.80455303",
"0.8020734",
"0.79928493",
"0.77594554",
"0.7651031",
"0.7612396",
"0.7466972",
"0.7238367",
"0.71784776",
"0.7153073",
"0.7124596",
"0.7091151",
"0.7062354",
"0.7034862",
"0.7034862",
"0.70096815",
"0.7000623",
"0.6991976",
"0.69738483",
"0.69675505",
"0.696755... | 0.7953349 | 3 |
returns representation of the Entity. (Same as __str__) | def wHJl(YKHO):
return str(YKHO) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__entities)",
"def zAg0(YKHO):\n KCHu = 'fireform.entity at {} {}\\n'.format(hex(id(YKHO)), '' if YKHO.alive else '(DEAD)')\n KCHu += ' data:\\n'\n for YRbF, r845 in YKHO.datum.items():\n if isinstance(YRbF, str) or not r845.has_name():\n KCHu +=... | [
"0.8257399",
"0.81905544",
"0.8078771",
"0.80169827",
"0.8000167",
"0.794607",
"0.78437513",
"0.78173435",
"0.7742364",
"0.7673369",
"0.7666972",
"0.76664865",
"0.7615434",
"0.759302",
"0.759302",
"0.7587398",
"0.7560148",
"0.7557069",
"0.7543349",
"0.75384235",
"0.7534808",
... | 0.0 | -1 |
returns string representation for Wall | def zAg0(YKHO):
return f"Wall('{YKHO.get_id()}')" | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return \"Wall('\" + YKHO.get_id() + \"')\"",
"def wHJl(YKHO):\n return \"Wall('\" + YKHO.get_id() + \"')\"",
"def zAg0(YKHO):\n Aofo = '.' + YKHO.n_cols * '_.'\n Aofo += '\\n'\n for YRbF in range(YKHO.n_rows):\n Aofo += '|'\n for r845 in range(YKHO.n_cols):\n ... | [
"0.76136285",
"0.7528314",
"0.66131777",
"0.6478971",
"0.64665955",
"0.64191747",
"0.6351062",
"0.6253535",
"0.6218709",
"0.62023926",
"0.62017804",
"0.6168459",
"0.61455244",
"0.6144527",
"0.61405057",
"0.6109605",
"0.6093533",
"0.6093533",
"0.60824007",
"0.6077702",
"0.6072... | 0.74982876 | 2 |