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 |
|---|---|---|---|---|---|---|
Return model with global max pool op | def XtCN():
g4y1 = ZylS.keras.Input(shape=(8, 8, 3))
WKvO = ZylS.keras.layers.Conv2D(8, (2, 2))(g4y1)
WKvO = ZylS.keras.layers.GlobalMaxPool2D()(WKvO)
WKvO = ZylS.keras.layers.Flatten()(WKvO)
o4Jx = ZylS.keras.layers.Dense(10, activation=ZylS.nn.softmax, name='model_with_global_max_pool2d')(WKvO)
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Bnd8(YKHO, WKvO, mWFP=''):\n return ZylS.nn.max_pool(WKvO, ksize=YKHO.mp_size, strides=YKHO.mp_stride, padding=YKHO.mp_padding, name=mWFP)",
"def s6J7(WKvO):\n return ZylS.nn.max_pool(value=WKvO, ksize=[1, 2, 2, 1], strides=[1, 2, 2, 1], padding='SAME')",
"def ZIVn(input, CIys, ft8c, hMIr, Pggg, dvgN... | [
"0.7269419",
"0.7243938",
"0.7227773",
"0.72227514",
"0.71937203",
"0.7046185",
"0.70104825",
"0.6986319",
"0.6848748",
"0.6832572",
"0.68086195",
"0.68079615",
"0.67616844",
"0.6731801",
"0.67291313",
"0.67123437",
"0.6663036",
"0.66181093",
"0.66181093",
"0.6610998",
"0.660... | 0.76176584 | 0 |
Gets a dict of form data with normalized field names. | def HL1v(YKHO, L03z, H5ew):
nPrm = {} if L03z.data else L03z.initial
y0cW = 'gc{}-'.format(H5ew)
for vXX7 in L03z.data:
baFr = vXX7[len(y0cW):]
if vXX7 in L03z.data and vXX7.startswith(y0cW) and L03z.data[vXX7]:
nPrm[baFr] = L03z.data[vXX7]
for vXX7 in nPrm:
if vXX7 =... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VSoh(YKHO) -> dict:\n with G9jH.LogCall(xAKo, 'get_form_data', YKHO.__class__):\n return YKHO.serialize()",
"def BGqR(YKHO) -> dict:\n return jth9.deepcopy(YKHO.data)",
"def BGqR(YKHO):\n from couchforms import XMLSyntaxError\n from .utils import convert_xform_to_json, adjust_datetimes\n... | [
"0.66238964",
"0.6523883",
"0.63611794",
"0.62735623",
"0.6265674",
"0.6173006",
"0.6158901",
"0.61106837",
"0.6109531",
"0.608981",
"0.60859835",
"0.6059278",
"0.60534596",
"0.6042204",
"0.59851694",
"0.5980913",
"0.5977545",
"0.59774405",
"0.5948431",
"0.59432006",
"0.59213... | 0.75258654 | 0 |
Converts session data to an ordered dict of forms. | def RL5z(YKHO, CBIr, X5CZ, uIyX):
H6V6 = U8Lr()
if not uIyX:
H5ew, L03z = YKHO._create_certificate_form(CBIr, X5CZ)
H6V6.update({H5ew: L03z})
else:
for d6pt, (H5ew, BGqR) in enumerate(uIyX):
for OCXm in BGqR:
if OCXm == 'quantity':
try:... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def O3_Z(YKHO, H6V6):\n uIyX = []\n for H5ew in H6V6:\n nPrm = YKHO._get_normalized_form_data(H6V6[H5ew], H5ew)\n uIyX.append([str(H5ew), nPrm])\n return uIyX",
"def WfuK(YKHO, QePW, wxIh):\n Mjw9 = U8Lr()\n for wX_w in YKHO.get_session_form_data_as_list(QePW, wxIh):\n Mjw9[wX... | [
"0.8139848",
"0.7277883",
"0.63586354",
"0.60039186",
"0.59320915",
"0.59302473",
"0.58909214",
"0.58705395",
"0.5800856",
"0.56936264",
"0.5639518",
"0.55805653",
"0.55639845",
"0.55626124",
"0.55314165",
"0.55205965",
"0.5506974",
"0.54904985",
"0.54498845",
"0.54390883",
"... | 0.79440534 | 1 |
Construct a new session object for querying youtube api v3 about video information. | def FIMM(YKHO, rSTc, cuiw=None):
super().__init__('https://www.googleapis.com/youtube/v3/videos', rSTc, session=cuiw) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, bD7m, NArs=None):\n super(ig0G, YKHO).__init__(bD7m, NArs)\n YKHO.video_id = YKHO.get_video_id()",
"def NMoC(YKHO):\n YKHO.response.headers['Content-Type'] = 'application/json; charset=utf-8'\n XL9m = Cc7Y(McQx, F6_B, developerKey=AL6t)\n NArs = {'part': IqW9, 'type': _61t, 'channel... | [
"0.64441925",
"0.60444665",
"0.599901",
"0.5980019",
"0.5912023",
"0.57905734",
"0.5760766",
"0.5734622",
"0.56934035",
"0.5681194",
"0.5672862",
"0.5659906",
"0.5633669",
"0.56238675",
"0.5602071",
"0.5596583",
"0.55700886",
"0.55292636",
"0.5525699",
"0.5488292",
"0.5486387... | 0.7197451 | 0 |
Get limits for the x, y and z axes so the plot is fitted to the axes. | def hFRA(quXY=None, UT57=None):
if UT57:
WKvO = [Xf84[0] for qfpW in UT57 for XP5J in UT57[qfpW] for Xf84 in XP5J]
LVAh = [Xf84[1] for qfpW in UT57 for XP5J in UT57[qfpW] for Xf84 in XP5J]
epBp = [Xf84[2] for qfpW in UT57 for XP5J in UT57[qfpW] for Xf84 in XP5J]
elif quXY:
_w9w =... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TCfm(YKHO) -> None:\n I8kJ.pyplot.xlim(0, YKHO.imgsz[0])\n I8kJ.pyplot.ylim(YKHO.imgsz[1], 0)",
"def jk7u(YKHO):\n Xk2t = [aNZO.get_xlim() for aNZO in YKHO._subaxes]\n if Xk2t == []:\n Xk2t = None\n return Xk2t",
"def c5uu(YKHO):\n return [min(YKHO.xvalues), max(YKHO.xvalues), min(... | [
"0.72449344",
"0.7136714",
"0.7037312",
"0.7036583",
"0.69637364",
"0.69435495",
"0.68720514",
"0.68314934",
"0.6817437",
"0.67171234",
"0.66993386",
"0.6655732",
"0.66311485",
"0.66187423",
"0.65988237",
"0.65796316",
"0.65699095",
"0.65026474",
"0.65012693",
"0.6493964",
"0... | 0.55643165 | 91 |
Create a sqlalchemy session context. This allows transaction based sql operations. The scope of the sqlalchemy session context is the same as the request. | def R1H9(YKHO):
cuiw = DMju()
try:
yield cuiw
cuiw.commit()
except Exception:
cuiw.rollback()
raise
finally:
cuiw.close() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def KfiN():\n return oCsa(FJ3D(autocommit=False, autoflush=False, bind=eHpk))",
"def cuiw(NCls, QePW):\n UzPC = NCls.engine.connect()\n Kh6j = UzPC.begin()\n xAU6 = dict(bind=UzPC, binds={})\n cuiw = NCls.create_scoped_session(options=xAU6)\n NCls.session = cuiw\n\n def mTtn():\n Kh6j... | [
"0.7513137",
"0.75105995",
"0.74831206",
"0.74786276",
"0.7459645",
"0.74523056",
"0.7352764",
"0.73358476",
"0.73333365",
"0.73255074",
"0.7315277",
"0.72830683",
"0.7227546",
"0.71489096",
"0.7141479",
"0.7136895",
"0.7136309",
"0.7069453",
"0.70509017",
"0.7043104",
"0.702... | 0.7012544 | 22 |
Return list of device parameters available. | def RQf5(YKHO):
return t0ce.list() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RQf5():\n return XDS4.list()",
"def kx5x(YKHO):\n return YKHO.description['config']['values'].keys()",
"def RQf5(YKHO):\n return XDS4.list()",
"def RQf5(YKHO):\n return XDS4.list()",
"def snJh():\n return BJsk.QOL_PARAMS",
"def q5ey():\n return TnmV.global_diameters",
"def WP3R(YK... | [
"0.7101235",
"0.7019266",
"0.6956897",
"0.6956897",
"0.68711567",
"0.68517077",
"0.67677885",
"0.67075",
"0.6660094",
"0.65980184",
"0.6571377",
"0.6546663",
"0.6525897",
"0.651118",
"0.6505991",
"0.64620256",
"0.64581656",
"0.6451976",
"0.64347064",
"0.6421263",
"0.6417065",... | 0.61061925 | 49 |
Filename with extensions removed. | def o8ao(YKHO):
return YKHO.filename.split('.')[0] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MXbr(Ux0P):\n return Ux0P.rsplit('.', 1)[-2]",
"def HcGC(Ux0P):\n P8oC = Hy7s.path.basename(Ux0P)\n return Hy7s.path.splitext(P8oC)[0]",
"def jJEX(WKvO):\n return Hy7s.path.splitext(Hy7s.path.basename(WKvO))[0]",
"def dbzI(pmON):\n for Fst3 in H7iW:\n pmON = pmON.replace('.%s' % Fst... | [
"0.7986783",
"0.7947299",
"0.78787977",
"0.74497956",
"0.744002",
"0.73650706",
"0.73578966",
"0.7233652",
"0.7209014",
"0.71895075",
"0.71651924",
"0.7077635",
"0.70416236",
"0.70369756",
"0.69893414",
"0.6909573",
"0.6882729",
"0.6852489",
"0.6847761",
"0.6802356",
"0.67933... | 0.0 | -1 |
Identify if object uses the Table format. Returns bool | def q3iz(hLRM, VqRE, J1UY, *qIxc, **B2fa):
return VqRE is not None and VqRE.endswith('.tex') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def komb(YKHO, JsOY):\n bD7m = '%s/_table/%s' % (YKHO.uri, JsOY)\n nPrm, _hkX = YKHO.execute(method='GET', url=bD7m, decode=True)\n return nPrm",
"def komb(zFiD):\n Dyhm = dDZ4(zFiD)\n U5bT = False\n if Dyhm.startswith('table'):\n U5bT = True\n return U5bT",
"def iRlW(YKHO, k9X4):\n... | [
"0.7154935",
"0.69347847",
"0.6713884",
"0.66774654",
"0.65027237",
"0.6405559",
"0.6318535",
"0.6290614",
"0.60154223",
"0.6012122",
"0.59830076",
"0.59671795",
"0.59329677",
"0.59227884",
"0.5915592",
"0.58908486",
"0.58749175",
"0.5863745",
"0.5826872",
"0.5823325",
"0.582... | 0.0 | -1 |
Behaviour on time expiration | def DmG8(YKHO, IOKn) -> None:
return | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def iWzb(YKHO):\n return ITS7() + YKHO.ttl * (0.95 + 0.1 * tuKI())",
"def CJbn(YKHO):\n return int(ITS7.time()) - YKHO.time > YKHO.interval",
"def q4lI(YKHO, fkZM):\n s_nr = 1000\n U2Xk = fkZM - YKHO.time_created\n if U2Xk > s_nr:\n YKHO.cache_expiration()",
"def CJbn(YKHO):\n return... | [
"0.7400812",
"0.72605306",
"0.71626914",
"0.71506196",
"0.71320415",
"0.7101007",
"0.7060373",
"0.7058079",
"0.7056206",
"0.7041179",
"0.7022438",
"0.70009494",
"0.69908535",
"0.69833755",
"0.69778395",
"0.6973487",
"0.69629925",
"0.6924481",
"0.69232047",
"0.6911352",
"0.690... | 0.74505216 | 0 |
Behaviour on time expiration | def DmG8(YKHO, IOKn):
YKHO.state.on_expiration_time(IOKn)
return | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DmG8(YKHO, IOKn) -> None:\n return",
"def iWzb(YKHO):\n return ITS7() + YKHO.ttl * (0.95 + 0.1 * tuKI())",
"def CJbn(YKHO):\n return int(ITS7.time()) - YKHO.time > YKHO.interval",
"def q4lI(YKHO, fkZM):\n s_nr = 1000\n U2Xk = fkZM - YKHO.time_created\n if U2Xk > s_nr:\n YKHO.cach... | [
"0.745051",
"0.7402179",
"0.72598827",
"0.71624225",
"0.71500504",
"0.71005267",
"0.7059663",
"0.70587087",
"0.7055313",
"0.70403373",
"0.70228344",
"0.70004857",
"0.6990823",
"0.69826275",
"0.6976515",
"0.697291",
"0.6961537",
"0.6923688",
"0.6922838",
"0.69123536",
"0.69046... | 0.7131818 | 5 |
Compute the probability of a state being a starting state using the given trajectories. | def aefV(YJY3, MeGp):
XP5J = oyIN.zeros(YJY3)
for a1PO in MeGp:
XP5J[a1PO.transitions()[0][0]] += 1.0
return XP5J / len(MeGp) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def A5g3(YJY3):\n _Fcw = oyIN.random.rand(YJY3, 1)\n _Fcw /= oyIN.sum(_Fcw, 0)\n assert oyIN.isclose(oyIN.sum(_Fcw, 0), 1.0)\n return _Fcw",
"def L7BV(YKHO, KCHu):\n return YKHO._starting_state_distribution.pdf(KCHu)",
"def fkke(YKHO) -> oyIN.ndarray:\n return YKHO.random_state.dirichlet(oyIN... | [
"0.7247876",
"0.7185046",
"0.70080256",
"0.6820418",
"0.67057043",
"0.6681877",
"0.66306335",
"0.6456886",
"0.6441795",
"0.6379684",
"0.63352114",
"0.6298333",
"0.6288684",
"0.62628675",
"0.6260707",
"0.6251168",
"0.624895",
"0.6241197",
"0.6183321",
"0.6126166",
"0.6120189",... | 0.808079 | 0 |
Parses command line arguments and returns ArgumentParser object. | def Q6DN():
wvEv = j1Jz.ArgumentParser(description='Generate a template embedded ARM project.', epilog='armwiz {}'.format(ECzf))
wvEv.add_argument('-p', '--projectname', help='Specify project name via -p <projectname>', metavar='<projectname>', default='armwizProject', required=False)
wvEv.add_argument('-t'... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lHBs() -> j1Jz.ArgumentParser:\n wvEv = j1Jz.ArgumentParser(description=JBZA(), epilog=QY6I(), formatter_class=j1Jz.RawDescriptionHelpFormatter)\n return wvEv",
"def lHBs() -> j1Jz.ArgumentParser:\n wvEv = j1Jz.ArgumentParser(description=JBZA(), epilog=QY6I(), formatter_class=j1Jz.RawDescriptionHelp... | [
"0.8069404",
"0.8069404",
"0.76196426",
"0.7484409",
"0.74191934",
"0.7375233",
"0.7326458",
"0.73214287",
"0.7315357",
"0.7314414",
"0.7314248",
"0.73079056",
"0.72804755",
"0.7277045",
"0.7269803",
"0.7255856",
"0.7234787",
"0.7224361",
"0.7202089",
"0.7196735",
"0.71878046... | 0.0 | -1 |
Given input for email sets user's email if valid and not taken | def TBnO(eOtH, D3lj):
DW23 = p9bx.get_users()
for CBIr in DW23:
if CBIr['email'] is D3lj:
raise P1dF.InputError(description='This email is already taken')
lgoE = p9bx.get_current_user(eOtH)
CBIr = p9bx.get_user_data(lgoE)
CBIr['email'] = D3lj
p9bx.set_user_data(CBIr) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Bt7w(YKHO):\n D3lj = input('Email: ').strip()\n if D3lj is None or D3lj == '':\n print(YKHO.INVALID_INPUT)\n YKHO.display_cust_unlock()\n else:\n return D3lj",
"def Bt7w(YKHO, D3lj):\n CBIr = mv1M.query.filter_by(email=D3lj.data).first()\n if CBIr is not None:\n rai... | [
"0.7721941",
"0.7694243",
"0.7640573",
"0.7519524",
"0.74694294",
"0.74686646",
"0.74686646",
"0.7459104",
"0.7454275",
"0.7445476",
"0.7438407",
"0.73791075",
"0.7317884",
"0.7274616",
"0.726877",
"0.7210037",
"0.71950847",
"0.71857846",
"0.71678466",
"0.71678466",
"0.714088... | 0.70125633 | 32 |
Gets a collection of `InputExample`s for the train set. | def rNg5(YKHO, h_xa):
raise NotImplementedError() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vGUt(YKHO, PU1l):\n return PU1l",
"def rNg5(YKHO):\n raise NotImplementedError()",
"def rNg5(YKHO, eZ_W):\n raise NotImplementedError()",
"def G_y_(YKHO, nPrm, TG_K):\n _73Q = []\n for YRbF, LihS in enumerate(nPrm):\n Artt = '%s-%s' % (TG_K, YRbF)\n l5Ny = LihS[0]\n UX... | [
"0.7351035",
"0.7176929",
"0.7130133",
"0.6560737",
"0.6423411",
"0.64047164",
"0.6340917",
"0.6288625",
"0.62828803",
"0.62512344",
"0.62508",
"0.62338984",
"0.6222759",
"0.6222759",
"0.62098795",
"0.62098795",
"0.62098795",
"0.62098795",
"0.62098795",
"0.62098795",
"0.62098... | 0.6250895 | 22 |
Gets a collection of `InputExample`s for the dev set. | def JdXm(YKHO, h_xa):
raise NotImplementedError() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JdXm(YKHO, eZ_W):\n raise NotImplementedError()",
"def vGUt(YKHO, PU1l):\n return PU1l",
"def X2wT(YKHO, sEAN):\n return YKHO.fam.c_get_examples(YKHO, sEAN)",
"def JdXm(YKHO):\n raise NotImplementedError()",
"def G_y_(YKHO, nPrm, TG_K):\n _73Q = []\n for YRbF, LihS in enumerate(nPrm):... | [
"0.68099505",
"0.6588394",
"0.65571433",
"0.65519285",
"0.64274293",
"0.63813734",
"0.6255137",
"0.6191493",
"0.6115438",
"0.60936713",
"0.60547465",
"0.60515034",
"0.5990582",
"0.59278655",
"0.5921486",
"0.59197146",
"0.5919686",
"0.5914534",
"0.5914534",
"0.5914534",
"0.591... | 0.5993667 | 23 |
Convert a set of `InputExample`s to a list of `InputFeatures`. | def E9Lq(_73Q, EKkb, G8d9, b0j5, FJiT):
LyKa = []
FJiT = Y5x7(_73Q, FJiT, EKkb)
for ttfM, PU1l in enumerate(_73Q):
if ttfM % 10000 == 0:
ZylS.logging.info('Writing example %d of %d' % (ttfM, len(_73Q)))
RDhP = Aaag(ttfM, PU1l, EKkb, G8d9, b0j5, FJiT)
bySB = {'input_ids': ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def E9Lq(_73Q, b0j5, LT6S, qIxc):\n n4JS = []\n lR_l = 0\n rBQ_ = 0\n bo34.info('Converting a list of NqExamples into InputFeatures ...')\n for d6pt, PU1l in enumerate(PRqg(_73Q)):\n nWi7 = PU1l['example_id']\n sQYC = PU1l['paragraph_id']\n if qIxc.do_ls:\n bySB = PTE... | [
"0.7313619",
"0.7043189",
"0.69537574",
"0.6944703",
"0.68829805",
"0.68623215",
"0.68499136",
"0.6838839",
"0.6821367",
"0.67009884",
"0.66914606",
"0.6658505",
"0.6588142",
"0.65752536",
"0.65514153",
"0.64245003",
"0.6417711",
"0.633485",
"0.63252825",
"0.63159335",
"0.628... | 0.6765219 | 9 |
Here, we define the final gan model, based on the generator and discriminator models. We also pass the input shape. | def HX6N(U78Y, hfjP, lNai):
for gEmA in hfjP.layers:
if not isinstance(gEmA, GVKG):
gEmA.trainable = False
jWfB = X6a0(shape=lNai)
yOIF = U78Y(jWfB)
I5Bp = hfjP([jWfB, yOIF])
C3ST = wOed(jWfB, [I5Bp, yOIF, yOIF])
y7GR = qhl4(lr=0.0002, beta_1=0.5)
C3ST.compile(loss=['bina... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lXDR(YKHO):\n YKHO.d_model.trainable = False\n Mrvv, ODDr = YKHO.g_model.input\n EO7_ = YKHO.g_model.output\n YfIz = YKHO.d_model([EO7_, ODDr])\n YKHO.gan_model = wOed([Mrvv, ODDr], YfIz)\n y7GR = qhl4(lr=0.0002, beta_1=0.5)\n YKHO.gan_model.compile(loss='binary_crossentropy', optimizer=y7... | [
"0.79150385",
"0.7653347",
"0.7291678",
"0.71470284",
"0.70194167",
"0.6821328",
"0.6767653",
"0.67312586",
"0.664788",
"0.6629011",
"0.6568209",
"0.65337884",
"0.6509679",
"0.65050095",
"0.64977705",
"0.6463172",
"0.6448851",
"0.6402434",
"0.63832754",
"0.63763434",
"0.63591... | 0.7147072 | 3 |
Checks if _deid_map table exists in the given dataset. | def nPMR(ekCf, __n6):
Y6DF = a0i_(ekCf, __n6)
JN9H = Y6DF['table_name'].tolist()
if '_deid_map' in JN9H:
return GDa9.SKIP
elif 'deid_map' in JN9H:
return GDa9.RENAME
return GDa9.CREATE | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def naN7(YKHO, __n6):\n assert __n6, 'Must input a valid dataset name.'\n return any(YKHO.get_by_dataset(__n6))",
"def lmNk(bNKA):\n HEin = yLsV(bNKA)\n uXlA = HEin['combined_dataset'].to_list()\n uXlA = list(set(uXlA))\n l633 = []\n for __n6 in uXlA:\n GfdN = nPMR(bNKA, __n6)\n ... | [
"0.6243791",
"0.5921224",
"0.5862878",
"0.58258134",
"0.5740741",
"0.57221866",
"0.5704945",
"0.56976765",
"0.56715035",
"0.56506824",
"0.563104",
"0.55656487",
"0.5563275",
"0.5563261",
"0.5514038",
"0.5498521",
"0.5484313",
"0.54817504",
"0.54725087",
"0.5466442",
"0.545704... | 0.8482313 | 0 |
Transforming an specific string into a date with format DD/MM/YYYY. | def _c1T(vIwR):
return vIwR[17:19] + '/' + vIwR[15:17] + '/' + vIwR[11:15] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JDE9(mbyn):\n return qcWV.strptime(mbyn, '%d/%m/%Y')",
"def Y5dS(wyVH):\n return Wmpw.datetime.strptime(wyVH, '%m/%d/%Y')",
"def mh4x(NmBo):\n O3lX = '%m/%d/%y'\n return qcWV.strptime(NmBo, O3lX)",
"def R2Sr(_c1T):\n return qcWV.datetime.strptime(_c1T, '%m/%d/%Y').date()",
"def RpRn(_c1T... | [
"0.79006696",
"0.7877436",
"0.78348124",
"0.78316873",
"0.7633172",
"0.7477035",
"0.7441873",
"0.7438004",
"0.7239859",
"0.7193773",
"0.70806223",
"0.7073203",
"0.70514446",
"0.7050316",
"0.7043088",
"0.70361465",
"0.70288926",
"0.6997086",
"0.6996767",
"0.6980106",
"0.696969... | 0.67513496 | 32 |
Transforming an specific string from the dataset into a month integer. | def VIcm(vIwR):
return int(vIwR[15:17]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def pL8v(vIwR):\n pdbK = qcWV.datetime.strptime(vIwR, '%B')\n ZR0n = pdbK.month\n return ZR0n",
"def x0eS(YKHO) -> int:\n if YKHO.is_old_style:\n return int(YKHO.split('/', 1)[1][2:4])\n return int(YKHO[2:4])",
"def wfY9(sd8v):\n _c1T = None\n for mXDZ in FmhY:\n try:\n ... | [
"0.78339547",
"0.6991977",
"0.68675023",
"0.67093915",
"0.6585043",
"0.6583717",
"0.6522631",
"0.65153396",
"0.64246273",
"0.63913697",
"0.63224703",
"0.6309049",
"0.62984",
"0.6287066",
"0.62853175",
"0.61746716",
"0.61678356",
"0.60979843",
"0.6068492",
"0.60650593",
"0.604... | 0.7543263 | 1 |
Creates a scatter plot that contains the same information as a confusion matrix. | def KsTq(Y8eF: np.ndarray, aMgO: np.ndarray, tGDF: Sequence[str], wtoN: Sequence[str], rbjf: Optional[np.ndarray]=None, TWaU: Union[str, float]='horizontal') -> YrBT[[], QD4e]:
exwG = len(tGDF)
tDkU(oyIN.shape(Y8eF)).is_equal_to(oyIN.shape(aMgO))
if rbjf is None:
rbjf = oyIN.ones_like(Y8eF)
tDkU... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VE_a(YKHO):\n EcVT = YKHO.reduce_dimension(n_components=2)\n QrM1.figure()\n QrM1.scatter(EcVT[:, 0], EcVT[:, 1])\n return QrM1",
"def VE_a(cC56, VJv0, sAoX, H96n, DNAD, PHUN):\n Rtew = cC56[VJv0 == 0, :]\n jwjA = cC56[VJv0 == 1, :]\n Ksz3 = sAoX[H96n == 0, :]\n BBbk = sAoX[H96n == 1,... | [
"0.74131846",
"0.73453987",
"0.7212111",
"0.7111455",
"0.678459",
"0.67830664",
"0.6736045",
"0.6735733",
"0.6722029",
"0.6719697",
"0.6702924",
"0.6702897",
"0.66985315",
"0.6695453",
"0.666597",
"0.66559994",
"0.6654712",
"0.6636807",
"0.6634248",
"0.65571654",
"0.65457404"... | 0.0 | -1 |
Creates a confusion matrix heatmap. | def Mdc3(Y8eF: np.ndarray, aMgO: np.ndarray, tGDF: Sequence[str], wtoN: Sequence[str], TWaU: Union[str, float]='horizontal', yd39: Union[str, float]='vertical') -> YrBT[[], QD4e]:
Bcwd = dpRG.confusion_matrix(Y8eF, aMgO)
Bele = Bcwd.astype('float') / Bcwd.sum()
_moR = Bcwd.astype('float') / Bcwd.sum(axis=0,... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RRX_(H96n, aTLP, SoKf):\n Crrw = list(set(H96n))\n fHMk = [CLNC + ' (' + str(vC9B) + ')' for CLNC, vC9B in zip(SoKf, Crrw)]\n Bcwd = YsYU(H96n, aTLP, labels=Crrw)\n LZpg = QrM1.figure(figsize=(20, 20))\n aNZO = LZpg.add_subplot(111)\n k13D = aNZO.matshow(Bcwd)\n QrM1.title('Confusion matri... | [
"0.8079532",
"0.7329811",
"0.7156625",
"0.714516",
"0.71391094",
"0.71230274",
"0.70907986",
"0.70495623",
"0.70381236",
"0.6997711",
"0.69807917",
"0.69659513",
"0.691102",
"0.68971246",
"0.6896661",
"0.687814",
"0.68549275",
"0.6835854",
"0.6829668",
"0.67743295",
"0.674008... | 0.0 | -1 |
Creates a scatter plot that contains the same information as a confusion matrix. | def EH_y(Y8eF: np.ndarray, aMgO: np.ndarray, tGDF: Sequence[str], wtoN: Sequence[str], TWaU: Union[str, float]='horizontal', yd39: Union[str, float]='vertical') -> YrBT[[], QD4e]:
if len(Y8eF) != len(aMgO):
raise ValueError('y_true and y_pred must have the same length!')
def JI1i() -> QD4e:
XP5... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VE_a(YKHO):\n EcVT = YKHO.reduce_dimension(n_components=2)\n QrM1.figure()\n QrM1.scatter(EcVT[:, 0], EcVT[:, 1])\n return QrM1",
"def VE_a(cC56, VJv0, sAoX, H96n, DNAD, PHUN):\n Rtew = cC56[VJv0 == 0, :]\n jwjA = cC56[VJv0 == 1, :]\n Ksz3 = sAoX[H96n == 0, :]\n BBbk = sAoX[H96n == 1,... | [
"0.74124336",
"0.73467916",
"0.7212641",
"0.711166",
"0.67852646",
"0.67838466",
"0.673718",
"0.6736241",
"0.6722911",
"0.67030776",
"0.67018706",
"0.67001325",
"0.6695713",
"0.6666835",
"0.6655957",
"0.6655799",
"0.6637261",
"0.66352075",
"0.655707",
"0.6546196",
"0.6516719"... | 0.67216337 | 9 |
Description Remover with list of stopwords specified by the user. | def L0lO(O8cl=None, **NArs):
p8X7 = 'Custom'
gCuF = {}
if O8cl is not None:
gCuF['Stopword'] = PpHc(obj=O8cl, none_acceptable=True, is_of_type=list)
UksD = C1zu(name=p8X7, settings=gCuF, kind='StopWordsRemover')
return UksD | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def aUcs(YKHO, *qIxc):\n if YKHO.remove_stopwords is False:\n raise Exception('Error - enable stopword removal functionality')\n if type(qIxc) != list:\n raise Exception('Error - expected a list')\n if qIxc == []:\n raise Exception('Error - no items to remove from stopword list')\n ... | [
"0.7647255",
"0.7641123",
"0.7435462",
"0.73342234",
"0.7296096",
"0.72319716",
"0.72216547",
"0.7207029",
"0.71754843",
"0.71630305",
"0.71366453",
"0.7119436",
"0.7110916",
"0.7080817",
"0.7062187",
"0.70618033",
"0.7058717",
"0.70534563",
"0.70376515",
"0.70376515",
"0.703... | 0.63535666 | 80 |
Check whether model has object level permissions. | def jj6u(YEnM: models.Model) -> bool:
EkST = ['flow.Storage']
return hasattr(YEnM, 'permission_group') or YEnM._meta.label in EkST | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def m4il(YKHO, QePW, tTee, YEnM):\n if QePW.method in w0rQ.SAFE_METHODS:\n return True\n if all([QePW.user, QePW.user.is_staff]):\n return True\n elif all([QePW.user, type(YEnM) == type(QePW.user), YEnM == QePW.user]):\n return True\n return True",
"def m4il(YKHO, QePW, tTee, YEn... | [
"0.78756624",
"0.781401",
"0.7799718",
"0.77996665",
"0.77838135",
"0.77522767",
"0.7711636",
"0.7677022",
"0.76713127",
"0.76681125",
"0.7638648",
"0.7631789",
"0.7628719",
"0.7621447",
"0.76193994",
"0.7610984",
"0.7603616",
"0.7595528",
"0.75844723",
"0.75626624",
"0.75516... | 0.7996643 | 0 |
Return the tuple (user_or_group, name). The user_or_group is user or group and name is either 'user' or 'group'. | def vVt1(kWzS: Union[Group, User]) -> AzJI[vNsV, str]:
if isinstance(kWzS, fCU0):
return (gY00(), 'user')
Nc2H = egNl()
if isinstance(kWzS, Nc2H):
return (kWzS, 'user')
if isinstance(kWzS, cQ68):
return (kWzS, 'group')
raise RuntimeError('Parameter is not user or group instan... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bVBq(YKHO, IXKo=None, BaHi=None):\n if IXKo and BaHi:\n raise ValueError('Both group_name and user_name were defined. Only of these values can be defined.')\n elif not IXKo and (not BaHi):\n raise ValueError('Neither group_name or user_name were defined. One of these values are required.')\... | [
"0.64836055",
"0.55922645",
"0.5590267",
"0.5575566",
"0.55299616",
"0.55214655",
"0.5505393",
"0.5432677",
"0.54275304",
"0.5366127",
"0.5280897",
"0.5249126",
"0.5212907",
"0.5194494",
"0.5183242",
"0.516792",
"0.51519734",
"0.5149493",
"0.51265925",
"0.51109844",
"0.510751... | 0.60617185 | 1 |
Check if one can grant or revoke owner permission. Owner permission to user should only be granted or revoked when allow_user_owner is set. Owner permission to group should never be set. | def CtmA(pB3N: dict, VDuL: bool, YEnM: models.Model):
for zXgc in ['users', 'groups']:
for svaD, Uvf2 in pB3N.get(zXgc, {}).items():
if Uvf2 == 'owner':
if zXgc == 'users' and (not VDuL):
raise Bx6I.PermissionDenied('Only owners can grant/revoke owner permissi... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VzrS(**awnO):\n eJh7 = wQcs.has_permissions(**awnO).predicate\n\n async def extended_check(OaeV):\n if OaeV.guild is None:\n raise UAju.NoPrivateMessage\n return OaeV.guild.owner_id == OaeV.author.id or await eJh7(OaeV)\n return wQcs.check(BoZO)",
"def fAV7(wyLN, QePW):\n ... | [
"0.72537684",
"0.71432227",
"0.7111834",
"0.69583964",
"0.69460505",
"0.6877894",
"0.68661547",
"0.683036",
"0.6817919",
"0.6817919",
"0.67819685",
"0.6726928",
"0.670339",
"0.6676365",
"0.6551557",
"0.6549114",
"0.65204394",
"0.651725",
"0.6502963",
"0.6502963",
"0.64776736"... | 0.773739 | 0 |
Add the log level to the event dict. | def Lv1Y(bo34, Si4S, ch9c):
ch9c['level'] = Si4S.upper()
return ch9c | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ABDL(YKHO, wiAm):\n YKHO.logger.setLevel(wiAm)",
"def ICXi(YKHO, ABDL):\n return",
"def oAiq(YKHO, ABDL, Ol8d):\n pass",
"def aQ22(YKHO, ABDL):\n if ABDL == 'info':\n ABDL = G9jH.INFO\n if ABDL == 'debug':\n ABDL = G9jH.DEBUG\n if ABDL == 'error':\n ABDL = G9jH.ERRO... | [
"0.66763777",
"0.6568067",
"0.65290135",
"0.6349708",
"0.6225883",
"0.62212133",
"0.6218766",
"0.6214043",
"0.619401",
"0.618545",
"0.6181116",
"0.61349046",
"0.6133718",
"0.60971624",
"0.6070584",
"0.605857",
"0.6039594",
"0.602524",
"0.6022099",
"0.5995022",
"0.5987285",
... | 0.6748369 | 0 |
Create model's layers and initialize the weights | def FIMM(YKHO):
super(sEgf, YKHO).__init__()
MuED = ZylS.keras.initializers.RandomNormal(mean=0.0, stddev=0.01)
oug5 = ZylS.keras.initializers.Ones()
rCTs = ZylS.keras.initializers.Zeros()
YKHO.drop = ZylS.keras.layers.Dropout(0.5)
YKHO.conv1_1 = ZylS.keras.layers.Conv2D(48, 11, strides=4, activ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sTi3(YKHO):\n for gEmA in YKHO._cnn_layers:\n dIoi.WeightsInitializer.initialize_layer_or_model(gEmA)",
"def vB93(C3ST):\n ...",
"def e4Qc(YKHO):\n Pq1o = YKHO.input_count + 1\n YKHO.weights = oyIN.random.rand(Pq1o, YKHO.node_count)\n YKHO.weights_and_activations = (YKHO.weights, YKHO... | [
"0.77850956",
"0.77621686",
"0.754918",
"0.7515623",
"0.741224",
"0.74100894",
"0.7350956",
"0.731648",
"0.7283748",
"0.72257346",
"0.7204779",
"0.7147508",
"0.7100905",
"0.7032231",
"0.69899184",
"0.6970427",
"0.6955541",
"0.69130176",
"0.6904016",
"0.68962425",
"0.68753415"... | 0.0 | -1 |
Get configuration of the model | def tgzD(YKHO):
return super().get_config() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tgzD(YKHO):\n return YKHO.config",
"def GPtr(YKHO) -> EYKe:\n return YKHO.config_obj.to_dict()",
"def tgzD(YKHO):\n if YKHO.allow_reco():\n return YKHO.chs_config()\n else:\n return YKHO.get_config_j(YKHO.id)",
"def eMhT(YKHO) -> dict:\n return YKHO.config",
"def GPtr(YKHO)... | [
"0.78695184",
"0.7862853",
"0.77675325",
"0.7575643",
"0.7519113",
"0.7519113",
"0.74972624",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
"0.7471751",
... | 0.7579623 | 3 |
Return a string representation of the class. | def wHJl(YKHO):
mWFP = YKHO._name
if mWFP:
mWFP = mWFP.__repr__()
return 'Process(%s, start_time=%s, stop_time=%s)' % (mWFP, YKHO._start_time, YKHO._stop_time) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n sovm = vars(YKHO)\n yvT9 = YKHO.__class__.__name__\n for G1Hx, Ty9i in sovm.items():\n if Ty9i > 0:\n yvT9 += ' : ' + str(G1Hx) + ' = ' + str(Ty9i)\n return yvT9",
"def wHJl(YKHO):\n pulk = 'class :' + YKHO.__class__.__name__\n for hkS8 in YKHO.__dict__:\n ... | [
"0.81191397",
"0.7812065",
"0.7791025",
"0.77723247",
"0.77518076",
"0.7710963",
"0.7617531",
"0.75566894",
"0.7503642",
"0.74922866",
"0.7471308",
"0.7455818",
"0.7455818",
"0.7455818",
"0.74540037",
"0.74515283",
"0.7437837",
"0.74022067",
"0.73984396",
"0.73712087",
"0.736... | 0.0 | -1 |
The cookie ID associated with this request. This value will be unique for the request. | def KmMB(YKHO):
if not YKHO.__cookie_id:
YKHO.__cookie_id = YKHO.get_argument('cookie_id', None)
if not YKHO.__cookie_id:
global cookie_counter
YKHO.__cookie_id = lNU8
lNU8 += 1
return YKHO.__cookie_id | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cZq3(YKHO):\n return YKHO.request_data['id']",
"def zatQ(YKHO) -> h8nf[str]:\n return YKHO._state.get('cookie', None)",
"def IXQM(YKHO):\n uJjO = YKHO.request.cookies.get('user_id')\n return uJjO and BfDw.check_secure_cookie(uJjO)",
"def mLJR(YKHO):\n return YKHO.session.request('id/')",
... | [
"0.7126761",
"0.6902421",
"0.6713818",
"0.6687699",
"0.661378",
"0.65825975",
"0.64952904",
"0.64728224",
"0.64336246",
"0.642736",
"0.6399717",
"0.63936776",
"0.63542056",
"0.6337327",
"0.631997",
"0.63031745",
"0.62855726",
"0.62773895",
"0.62746906",
"0.6226697",
"0.620366... | 0.83010465 | 0 |
Convert string number representation to float. | def Kp_g(FGW3):
FGW3 = FGW3.replace('.', '')
FGW3 = FGW3.replace(',', '.')
return float(FGW3) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def AjPn(YKHO, KCHu: str) -> float:\n return int(KCHu[:-1]) / 1000000000.0 if KCHu.endswith('n') else float(KCHu[:-1])",
"def n3at(WKvO):\n try:\n return float(WKvO)\n except ValueError:\n print('must be a number')",
"def NrMZ(KCHu):\n try:\n return float(KCHu)\n except:\n ... | [
"0.81577456",
"0.8044069",
"0.80348134",
"0.7949184",
"0.789166",
"0.7848662",
"0.7662928",
"0.7653817",
"0.7614494",
"0.75455004",
"0.74550873",
"0.73988295",
"0.7344253",
"0.7326363",
"0.7303831",
"0.729217",
"0.7272375",
"0.72667795",
"0.7199241",
"0.71858174",
"0.71478117... | 0.0 | -1 |
Create a mosaic plot from a dataframe. Right now only horizontal mosaic plots are supported, i.e. rows are prioritized over columns. | def yx13(nPrm, usx6, WfCS, dbcJ=False, aNZO=None, Dy_V=True):
v9Lt = rLdf.crosstab(nPrm[WfCS], nPrm[usx6])
BA9O = oyIN.argsort((v9Lt / v9Lt.sum()).iloc[0])
v9Lt = v9Lt.iloc[:, BA9O]
if aNZO is None:
aNZO = QrM1.gca()
Ydjp = 0
ZK2_ = []
OfOG = v9Lt.shape[1]
Jw9H = QrM1.rcParams['a... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ntd2(jQ3Z):\n LZpg = iEax.Figure(data=iEax.Heatmap(z=jQ3Z.values.tolist(), x=jQ3Z.columns, y=jQ3Z.index.values.tolist(), hoverongaps=False, xgap=3, ygap=3, colorscale=[[0.0, 'rgb(165,0,38)'], [0.1111111111111111, 'rgb(215,48,39)'], [0.2222222222222222, 'rgb(244,109,67)'], [0.3333333333333333, 'rgb(253,174,9... | [
"0.62593037",
"0.6220265",
"0.607737",
"0.6069061",
"0.60488564",
"0.59701693",
"0.5959861",
"0.59490454",
"0.5828705",
"0.58131284",
"0.5791862",
"0.5758736",
"0.5677728",
"0.561457",
"0.561452",
"0.5561442",
"0.5539591",
"0.55172807",
"0.5511576",
"0.5509743",
"0.54879415",... | 0.72127837 | 0 |
Shorten axes labels and tick labels. Uses _shortname to change labels as a side effect. | def BlSr(aNZO, n5rq=20, C39a=10):
aNZO.set_yticks(aNZO.get_yticks().tolist())
aNZO.set_xticks(aNZO.get_xticks().tolist())
aNZO.set_xticklabels([LLEV(a1PO.get_text(), maxlen=C39a) for a1PO in aNZO.get_xticklabels()])
aNZO.set_yticklabels([LLEV(a1PO.get_text(), maxlen=C39a) for a1PO in aNZO.get_yticklabel... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NkBi(YKHO, UXqs, rYO3):\n if rYO3 != '':\n UXqs = UXqs + ' (' + rYO3 + ')'\n YKHO.subplot.set_xlabel(UXqs)\n pass",
"def MXRn(YKHO, UXqs, rYO3):\n GSes = YKHO.tex_axis_label(UXqs)\n if not rYO3 == 'dimensionless' and rYO3 is not None and (not rYO3 == []):\n GSes += ' (%s)' % YKHO... | [
"0.6453884",
"0.63091487",
"0.61024654",
"0.60074323",
"0.5981512",
"0.5820715",
"0.57550526",
"0.57281876",
"0.57041794",
"0.56828797",
"0.56153893",
"0.5517902",
"0.5516496",
"0.5510675",
"0.5500265",
"0.5476972",
"0.5465943",
"0.54459417",
"0.54368114",
"0.54276204",
"0.53... | 0.79533833 | 0 |
Scatter plot for categories. Creates a scatter plot for x and y grouped by c. | def kdAJ(WKvO, LVAh, Z9rn, SZVY=None, Dy_V='first', YpeL=True, Cwt5='auto', KCHu='auto', aNZO=None, UmOP=False, ueCB=False, **B2fa):
Cwt5 = opoU(Cwt5, WKvO)
KCHu = f6i2(KCHu, WKvO)
if aNZO is None:
aNZO = QrM1.gca()
if Dy_V == 'first':
Dy_V = aNZO.get_subplotspec().get_geometry()[2] == 1... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VE_a(KNEa, NtVk):\n QrM1.scatter(KNEa, NtVk)\n QrM1.show()",
"def YPDG(YKHO, U6D_, WKvO, LVAh, nPrm):\n eo76 = ['y' if YKHO.invert else 'x'] if WKvO != 'index' else []\n if YKHO.value_label != 'value':\n eo76.append('x' if YKHO.invert else 'y')\n if 'xlabel' in YKHO._plot_opts and 'x' n... | [
"0.62944365",
"0.6273058",
"0.6250776",
"0.6222933",
"0.619619",
"0.6178261",
"0.6144808",
"0.61396825",
"0.61252946",
"0.61018527",
"0.60127306",
"0.5987695",
"0.5983874",
"0.59837705",
"0.59817827",
"0.59542114",
"0.5936364",
"0.59093",
"0.5901431",
"0.5877763",
"0.5842082"... | 0.6688197 | 0 |
Computes the diagonal of the (observed) Fisher information matrix. | def iYrA(u3Vg: LossFun, NArs: Any, g4y1: jnp.ndarray, x6A0: jnp.ndarray) -> oLG2.DeviceArray:
return oLG2.square(SgOx(yOcR.grad(u3Vg)(NArs, g4y1, x6A0))) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def IjIm(YKHO):\n return YKHO.rep.diagonal()",
"def IjIm(YKHO):\n E3D9 = YKHO.rep\n r8hN, exwG = YKHO.shape\n return [E3D9[YRbF, YRbF] for YRbF in range(min(r8hN, exwG))]",
"def IjIm(YPaw='Metropolis', S7dm=5000):\n EcVT = FQNo.Uniform('X', lower=-1.0, upper=1.0, value=[0.0, 0.0])\n\n @FQNo.p... | [
"0.6801682",
"0.66132337",
"0.6587387",
"0.64470315",
"0.62856394",
"0.6216051",
"0.61956936",
"0.6156756",
"0.6120031",
"0.6089011",
"0.60764974",
"0.6013825",
"0.6003092",
"0.59998447",
"0.5960165",
"0.59564614",
"0.59369653",
"0.59290934",
"0.5920861",
"0.5906225",
"0.5898... | 0.6354004 | 4 |
Fit the Pipeline. Fit and apply given transforms to the data, then fit the model on the transformed data. | def WgYu(YKHO, i8WE: TSDataset) -> 'Pipeline':
YKHO.ts = i8WE
YKHO.ts.fit_transform(YKHO.transforms)
YKHO.model.fit(YKHO.ts)
return YKHO | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dSez(YKHO, nPrm):\n XP5J = YKHO._get_pipeline(YKHO._params)\n return XP5J.fit_transform(nPrm)",
"def dSez(YKHO, nPrm):\n if not YKHO._transformers:\n return YKHO._preprocess(nPrm)\n sXdH = YKHO._preprocess(nPrm)\n hDiH = YKHO._transformers[-1]\n return hDiH[1].fit_transform(sXdH)",
... | [
"0.78348744",
"0.7634114",
"0.7622818",
"0.74800265",
"0.74401873",
"0.74279714",
"0.7389048",
"0.7101711",
"0.70897293",
"0.7085718",
"0.70367295",
"0.70365757",
"0.7004992",
"0.6990908",
"0.6987758",
"0.6976234",
"0.69717896",
"0.6963145",
"0.6942096",
"0.6920304",
"0.69169... | 0.67712384 | 31 |
r"""Given an index return an example from the position. | def OP2O(YKHO, ZfUD):
return {'text': YKHO.texts[ZfUD], 'label': YKHO.labels[ZfUD]} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kTCt(YKHO, d6pt, xlLU=None):\n if d6pt is None:\n xlLU = jrZe.ensure_rng(xlLU)\n d6pt = xlLU.randint(0, YKHO.n_samples)\n if d6pt < YKHO.n_positives:\n mvm2 = YKHO.get_positive(d6pt, rng=xlLU)\n else:\n d6pt = d6pt - YKHO.n_positives\n mvm2 = YKHO.get_negative(d6pt, ... | [
"0.6802264",
"0.676309",
"0.6761832",
"0.6617753",
"0.6580388",
"0.65452653",
"0.63973",
"0.63196665",
"0.62835634",
"0.628346",
"0.62713134",
"0.6228255",
"0.62223506",
"0.6199706",
"0.6185447",
"0.61793107",
"0.61635405",
"0.61530817",
"0.6108982",
"0.6070217",
"0.6062702",... | 0.0 | -1 |
Shows stats and information about current guild. | async def membercount(OaeV, *qIxc):
if OaeV.message.channel.is_private:
await JyK9.delete_message(OaeV.message)
return
Oa1e = OaeV.message.server
Bnkd = Oa1e.id
ZRKA = str(len(Oa1e.members))
eoAJ = str(len([r8hN for r8hN in Oa1e.members if not r8hN.status == EloR.offline]))
DW23 ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def stats(OaeV):\n yJxA = a9EH.python_version()\n Zcae = ZOrr.__version__\n j6IA = len(JyK9.guilds)\n w4qg = len(set(JyK9.get_all_members()))\n Q1PJ = ZOrr.Embed(title=f'{JyK9.user.name} Stats', description='\\ufeff', colour=OaeV.author.colour, timestamp=OaeV.message.created_at)\n Q1PJ.add_... | [
"0.7263817",
"0.71782815",
"0.7131748",
"0.7001834",
"0.69652236",
"0.6958627",
"0.6903964",
"0.6859176",
"0.68318266",
"0.67624027",
"0.6751602",
"0.6706869",
"0.6662018",
"0.6601903",
"0.65654343",
"0.65519553",
"0.65515625",
"0.65355563",
"0.65261716",
"0.6519268",
"0.6501... | 0.0 | -1 |
__call__(self, x, finetune=False) Invokes the forward propagation of BatchNormalization. In training mode, the BatchNormalization computes moving averages of mean and variance for evaluation during training, and normalizes the input using batch statistics. | def nrOS(YKHO, WKvO, **B2fa):
wAVY.check_unexpected_kwargs(B2fa, test='test argument is not supported anymore. Use chainer.using_config')
LSVv, = wAVY.parse_kwargs(B2fa, ('finetune', False))
if hasattr(YKHO, 'gamma'):
KMvS = YKHO.gamma
else:
with lDLs.get_device_from_id(YKHO._device_id):... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NkkI(YKHO, WKvO, EvQg=True):\n if EvQg is not None:\n JBMS, I8JS = ZylS.nn.moments(WKvO, [0, 1, 2])\n ghdg = YKHO.mean.assign(JBMS)\n RPPm = YKHO.variance.assign(I8JS)\n with ZylS.control_dependencies([ghdg, RPPm]):\n return ZylS.nn.batch_norm_with_global_normalization... | [
"0.6875177",
"0.686221",
"0.6825619",
"0.64800715",
"0.645479",
"0.6425954",
"0.6373195",
"0.6365986",
"0.63327247",
"0.6285357",
"0.627124",
"0.62499857",
"0.6243673",
"0.6231377",
"0.62215304",
"0.61961967",
"0.6195935",
"0.61464417",
"0.6130463",
"0.61200947",
"0.61165434"... | 0.80289406 | 0 |
Resets the population count for collecting population statistics. This method can be skipped if it is the first time to use the finetuning mode. Otherwise, this method should be called before starting the finetuning mode again. | def iM7i(YKHO):
YKHO.N = 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def J1J4(YKHO):\n YKHO.logger.info('Reinit called. Clear the population.')\n YKHO.set_init_population([], perf_name=None)\n YKHO._gt_rollouts = []\n YKHO._gt_scores = []",
"def h9Zz(YKHO):\n YKHO.next_population = []",
"def SiRx(YKHO):\n if not YKHO._data_writer.is_ran_last():\n if not... | [
"0.7372122",
"0.73329914",
"0.71878517",
"0.699537",
"0.699537",
"0.69919646",
"0.6859545",
"0.68533504",
"0.6807315",
"0.6778661",
"0.67305106",
"0.6720021",
"0.6715473",
"0.6658221",
"0.6648325",
"0.66371506",
"0.65548116",
"0.6550627",
"0.65500027",
"0.6546087",
"0.6532955... | 0.6108732 | 62 |
Project into the tangent space. Usually the same as egrad2rgrad | def IDBL(YKHO, EcVT, yvY1):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BxRI(YKHO, XP5J):\n XP5J = qw7D(XP5J, float)\n Ty9i = XP5J - YKHO.o\n Ty9i /= CkYf(Ty9i)\n Fg_i = YKHO.o + (WHx2(Ty9i, YKHO.N) - Ty9i) / 3 * YKHO.r\n RRSr = qaYG(YKHO.o, XP5J, Fg_i)\n o9EG = RRSr - Fg_i\n return o9EG / CkYf(o9EG)",
"def JKtl(YKHO):\n return YKHO.gradAmbient + YKHO.cen... | [
"0.71433276",
"0.6944794",
"0.67297846",
"0.6462124",
"0.64144534",
"0.6310642",
"0.6288211",
"0.6261557",
"0.6258516",
"0.62065065",
"0.6149693",
"0.61299664",
"0.6068976",
"0.60456324",
"0.59807914",
"0.58239603",
"0.5809741",
"0.5800137",
"0.57766217",
"0.5767548",
"0.5743... | 0.0 | -1 |
A mapping from the Euclidean gradient G into the tangent space to the manifold at X. For embedded manifolds, this is simply the projection of G on the tangent space at X. | def hBJL(YKHO, EcVT, yvY1):
return YKHO.proj(EcVT, yvY1) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JKtl(YKHO):\n return YKHO.gradAmbient + YKHO.centroid * UV9I(YKHO.centroid, YKHO.gradAmbient)",
"def IDBL(YKHO, EcVT, yvY1):\n raise NotImplementedError",
"def Oa1e(YKHO, EcVT):\n return EcVT[0] ** 2 - 2 * EcVT[0] + EcVT[1] ** 3 - 2",
"def Ro40(YKHO, g4y1, NkJL):\n WKvO, = g4y1\n Y7fn = YK... | [
"0.57202685",
"0.5684287",
"0.56506914",
"0.5531437",
"0.5426087",
"0.5266315",
"0.5233484",
"0.5209376",
"0.51755935",
"0.5172781",
"0.51689166",
"0.51462895",
"0.5116278",
"0.51131195",
"0.50995994",
"0.50980353",
"0.5090509",
"0.5085216",
"0.50838065",
"0.5056675",
"0.5040... | 0.55419004 | 3 |
A retraction mapping from the tangent space at X to the manifold. See Absil for definition of retraction. | def Wyek(YKHO, EcVT, yvY1):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nt3H(YKHO, Ty9i, WKvO, Z9rn):\n Z9rn = YKHO.truncate_c(Z9rn)\n _6_j = YKHO.expmap(Ty9i, WKvO, Z9rn)\n return YKHO.proj(_6_j, Z9rn)",
"def fTYI(YKHO, EcVT: Tensor) -> llWB:\n CAhe = EcVT.clone()\n CAhe[..., YKHO.indices] = 10.0 ** CAhe[..., YKHO.indices]\n return CAhe",
"def JKtl(YKHO):\n ... | [
"0.575803",
"0.55296284",
"0.5391757",
"0.534215",
"0.52485466",
"0.5192087",
"0.51837397",
"0.51709193",
"0.51478386",
"0.51376426",
"0.51177233",
"0.50867915",
"0.50847423",
"0.50622445",
"0.50481963",
"0.5041714",
"0.50158346",
"0.5015376",
"0.50130427",
"0.50069124",
"0.5... | 0.0 | -1 |
Returns a random, unit norm vector in the tangent space at X. | def a9Uz(YKHO, EcVT):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def HcPy(EcVT):\n LtN5 = EcVT - oyIN.min(EcVT)\n YtTp = LtN5 * 2 / oyIN.max(LtN5) - 1\n return YtTp",
"def Re_4(YKHO, shHt, TokS=1):\n ROpF = shHt.shape\n if len(ROpF) > 1 and ROpF[-2] > 1 and (TokS > 1):\n raise ValueError('Several tangent vectors is only applicable to a single base point.... | [
"0.6697116",
"0.6633927",
"0.6555211",
"0.6469738",
"0.64672256",
"0.6466895",
"0.62796694",
"0.6278503",
"0.62507796",
"0.6216168",
"0.6092589",
"0.6086808",
"0.6082151",
"0.60797554",
"0.6060915",
"0.60371727",
"0.60060287",
"0.60060287",
"0.60060287",
"0.598891",
"0.597660... | 0.5546388 | 71 |
Transports d, which is a tangent vector at x1, into the tangent space at x2. | def HliD(YKHO, o4D3, ajwV, Csk6):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def t0lk(YKHO, M_DK: np.ndarray, CYjz: np.ndarray) -> oyIN.ndarray:\n oW_G = M_DK[:, 0] * M_DK[:, 1]\n niO1 = 2 * oW_G * YKHO.p[0] + YKHO.p[1] * (CYjz + 2 * M_DK[:, 0] ** 2)\n yRSm = YKHO.p[0] * (CYjz + 2 * M_DK[:, 1] ** 2) + 2 * oW_G * YKHO.p[1]\n return oyIN.column_stack((niO1, yRSm))",
"def _sQW(n... | [
"0.62952924",
"0.62569714",
"0.61545",
"0.6088679",
"0.5946583",
"0.5931927",
"0.59010154",
"0.58834106",
"0.5847089",
"0.5836788",
"0.5830435",
"0.5769111",
"0.5744328",
"0.5735793",
"0.5708261",
"0.56960833",
"0.5653199",
"0.564208",
"0.5641268",
"0.56334007",
"0.5628427",
... | 0.6277807 | 1 |
The exponential (in the sense of Lie group theory) of a tangent vector U at X. | def kLQb(YKHO, EcVT, KkY2):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vmco(WKvO):\n return WKvO * 0.5 * (1.0 + vuvg.tanh(vuvg.sqrt(2 / epAf.pi) * (WKvO + 0.044715 * WKvO ** 3)))",
"def jpZ9(WKvO):\n return oyIN.where(WKvO < 0, oyIN.exp(WKvO) - 1, WKvO)",
"def DFqp(WKvO):\n Cwt5 = 1.6732632423543772\n NXpY = 1.0507009873554805\n return NXpY * jpZ9(WKvO, Cwt5)",... | [
"0.7306948",
"0.7016486",
"0.6999739",
"0.69829786",
"0.6853082",
"0.68306595",
"0.6828083",
"0.6803315",
"0.6803315",
"0.6803315",
"0.6803315",
"0.6803315",
"0.6803315",
"0.6803315",
"0.6803315",
"0.6758181",
"0.6705828",
"0.66566306",
"0.6621795",
"0.66108114",
"0.6603319",... | 0.7750054 | 0 |
Computes the intrinsic mean of X and Y, that is, a point that lies midway between X and Y on the geodesic arc joining them. | def QVPt(YKHO, EcVT, fuBA):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def C7fU(WKvO, LVAh):\n return (WKvO + LVAh) / 2",
"def aVPQ(WKvO, LVAh):\n return Dz7Y.mean(jjNH(WKvO, LVAh))",
"def cX4W(YKHO):\n WKvO = oyIN.array(YKHO.x)\n LVAh = oyIN.array(YKHO.y)\n return (oyIN.mean(WKvO), oyIN.mean(LVAh))",
"def qqgr(WKvO, LVAh):\n return (WKvO + LVAh) / 2",
"def ... | [
"0.72091436",
"0.70792454",
"0.6920424",
"0.66236514",
"0.6520856",
"0.6321251",
"0.62995625",
"0.6200656",
"0.61863524",
"0.61863524",
"0.6145899",
"0.61439306",
"0.6041739",
"0.6035128",
"0.6022485",
"0.5989087",
"0.5973875",
"0.59691864",
"0.5956793",
"0.59486085",
"0.5942... | 0.6292192 | 7 |
Returns the zero tangent vector at X. | def OC6w(YKHO, EcVT):
return oyIN.zeros(EcVT.size()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BxRI(WKvO, nMvt=10, Nq1b=0.1):\n KCHu = oyIN.zeros_like(WKvO)\n r8hN = WKvO >= 0\n tTpl = oyIN.exp(-WKvO[r8hN] * Nq1b)\n KCHu[r8hN] = nMvt * (1 - tTpl) / (1 + tTpl)\n tTpl = oyIN.exp(WKvO[~r8hN] * Nq1b)\n KCHu[~r8hN] = nMvt * (tTpl - 1) / (tTpl + 1)\n return KCHu",
"def IMnT(YKHO, c0Lq):... | [
"0.7180941",
"0.63736475",
"0.6352444",
"0.61244786",
"0.60274935",
"0.60025793",
"0.600036",
"0.596903",
"0.5966394",
"0.5959191",
"0.59385544",
"0.5917829",
"0.59016407",
"0.5872008",
"0.5871878",
"0.5861603",
"0.58095413",
"0.5764716",
"0.5739877",
"0.56989694",
"0.5697017... | 0.55364853 | 36 |
This function prints and plots the confusion matrix. Normalization can be applied by setting `normalize=True`. | def LwSz(Y8eF, aMgO, KndY, NkkI=False, leAC=None, iMGt=QrM1.cm.Blues):
if not leAC:
if NkkI:
leAC = 'Normalized confusion matrix'
else:
leAC = 'Confusion matrix, without normalization'
Bcwd = YsYU(Y8eF, aMgO)
KndY = KndY[OrFa(Y8eF, aMgO)]
if NkkI:
Bcwd = B... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LwSz(Bcwd, KndY=[0, 1], NkkI=False, leAC='Confusion matrix', RMso=False):\n if NkkI:\n Bcwd = Bcwd.astype('float') / Bcwd.sum(axis=1)[:, oyIN.newaxis]\n print('Normalized confusion matrix')\n else:\n print('Confusion matrix, without normalization')\n if RMso:\n print(Bcwd)"... | [
"0.81942594",
"0.80949026",
"0.8028581",
"0.8018849",
"0.79934716",
"0.7990885",
"0.7980801",
"0.79750925",
"0.7960907",
"0.79557455",
"0.79372376",
"0.7934255",
"0.79340357",
"0.79309034",
"0.7925931",
"0.7924125",
"0.79232645",
"0.7922545",
"0.79224193",
"0.79218626",
"0.79... | 0.0 | -1 |
Check if the object is within the given distance from origin_point, returns | def KCDX(YKHO, object, Ayfi: float):
nJ9F, nxyw = YKHO.origin_point
o4D3, si3g = object.body.position
Dh0t = epAf.sqrt((nJ9F - o4D3) ** 2 + (nxyw - si3g) ** 2)
if Dh0t < Ayfi:
return True
else:
return False | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def AJVa(YKHO, AU8u, Ayfi):\n return YKHO.distance(AU8u) <= Ayfi",
"def UZ_k(YKHO, hLRM, f3mm, Vngc):\n Ayfi = [0, 0, 0]\n for YRbF in range(0, 3):\n Ayfi[YRbF] = YKHO.translation[YRbF] - hLRM[YRbF]\n hQHm = NkkI(Ayfi)\n jlSq = NkkI(f3mm)\n return abs(hQHm[0] - jlSq[0]) < Vngc and abs(hQ... | [
"0.67588323",
"0.67227286",
"0.6579763",
"0.65754175",
"0.6550611",
"0.64685863",
"0.6439322",
"0.6341795",
"0.63335687",
"0.631851",
"0.6308309",
"0.6299217",
"0.6281756",
"0.62696373",
"0.62423325",
"0.62423325",
"0.62423325",
"0.62423325",
"0.62423325",
"0.62423325",
"0.62... | 0.75537294 | 0 |
Returns True if obj is an instance of a dataclass. | def LCHE(YEnM):
return hasattr(type(YEnM), '__dataclass_fields__') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def PwMT(YEnM: Any) -> bool:\n return nf7Q.is_dataclass(YEnM) and (not isinstance(YEnM, type))",
"def NC32(object):\n if not hasattr(object, '__class__'):\n return False\n if MP1F(object.__class__):\n return False\n return True",
"def Bk6c(YEnM, J9Xy):\n if isinstance(YEnM, J9Xy) i... | [
"0.901118",
"0.7407845",
"0.73034966",
"0.72383547",
"0.7238161",
"0.7238161",
"0.72214854",
"0.72177786",
"0.72177786",
"0.72177786",
"0.72177786",
"0.72177786",
"0.72177786",
"0.7197136",
"0.7188834",
"0.71734035",
"0.71728307",
"0.71574026",
"0.71500915",
"0.7106451",
"0.7... | 0.86450404 | 1 |
Return the fields of a dataclass instance as a new dictionary mapping field names to field values. | def lKKu(YEnM, *, ij1k=dict):
if not LCHE(YEnM):
raise TypeError('asdict() should be called on dataclass instances')
return eviV(YEnM, ij1k) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def V_D6(TSeE):\n try:\n pjQn = getattr(TSeE, DsrS)\n except AttributeError:\n raise TypeError('must be called with a dataclass type or instance')\n return pjQn",
"def ERRh(TSeE):\n try:\n pjQn = dict(getattr(TSeE, DsrS))\n pjQn.pop('_version', None)\n except AttributeE... | [
"0.7917745",
"0.73211527",
"0.7006833",
"0.69605935",
"0.68871534",
"0.68538296",
"0.68324256",
"0.6708716",
"0.6666433",
"0.65864307",
"0.65840167",
"0.65836215",
"0.6580536",
"0.6540082",
"0.65352523",
"0.652932",
"0.652891",
"0.6495413",
"0.6493182",
"0.6493182",
"0.649318... | 0.0 | -1 |
1. Test GET /orders when no orders exist | def QZv0(YKHO):
geh0 = YKHO.api_test_client.get('{}/orders'.format(YKHO.BASE_URL))
YKHO.assertEqual(geh0.status_code, 404)
YKHO.assertEqual(M966(geh0)['message'], 'No orders exist as yet') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NOfT(YKHO):\n _hkX = YKHO.app.get('/orders/0')\n YKHO.assertEqual(_hkX.status_code, jGRS.HTTP_404_NOT_FOUND)",
"def NOfT(YKHO):\n _hkX = YKHO.app.get('/orders/0')\n YKHO.assertEqual(_hkX.status_code, jGRS.HTTP_404_NOT_FOUND)",
"def jm7y(YKHO):\n geh0 = YKHO.api_test_client.get('{}/orders/100... | [
"0.8308016",
"0.8308016",
"0.7894911",
"0.7677505",
"0.7591937",
"0.72186655",
"0.7169413",
"0.71467626",
"0.71396196",
"0.7054314",
"0.7034672",
"0.70090955",
"0.69778055",
"0.69672924",
"0.6956257",
"0.69442636",
"0.69133407",
"0.68991846",
"0.68751264",
"0.6840929",
"0.680... | 0.8250712 | 2 |
gather_nd with interpolation as torch.grid_sample func | def UUbu(UBMT, _0VL, Xng_=1):
B9ub = _0VL[..., -2:]
SzqO = _0VL[..., :-2]
tAmh = ZylS.floor(B9ub)
FanK = ZylS.math.ceil(B9ub)
RpIG = ZylS.concat([SzqO, tAmh], axis=-1, name='p1_ind')
urvS = ZylS.concat([SzqO, FanK[..., :1], tAmh[..., 1:2]], axis=-1, name='p2_ind')
Kwik = ZylS.concat([SzqO, t... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _Mru(YKHO, hkxX, _0VL):\n or8S = _0VL.unsqueeze(-1)\n or8S = or8S.int()\n zNig = _0VL.shape[0]\n a9Hh = ht2j.arange(zNig, dtype=ht2j.int32).to(YKHO.device)\n a9Hh = a9Hh.unsqueeze(-1)\n a9Hh = a9Hh.repeat([1, int(_0VL.shape[-1])])\n a9Hh = a9Hh.unsqueeze(-1)\n LQvf = ht2j.cat((a9Hh, or8... | [
"0.6307485",
"0.61616975",
"0.5992615",
"0.5938428",
"0.5898372",
"0.5877989",
"0.5863944",
"0.5863099",
"0.5863099",
"0.58423793",
"0.5770899",
"0.5750407",
"0.57094544",
"0.5704224",
"0.5704224",
"0.5703079",
"0.5695427",
"0.5684598",
"0.5671521",
"0.56672937",
"0.56671363"... | 0.73965335 | 0 |
Turn a list of list of (list of ...) dicts into a list of dicts. | def PWgb(vC9B):
Aofo = []
for WKvO in vC9B:
if type(WKvO) is list:
Aofo.extend(PWgb(WKvO))
else:
Aofo.append(WKvO)
return Aofo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def js81(GBaN):\n hlel = oRi_(list)\n for fGC9 in GBaN:\n for H5ew, BWXx in fGC9.items():\n fGC9[H5ew].append(BWXx)\n return dict(hlel)",
"def Gy2I(IHXE):\n return [dict(zip(IHXE[0], YRbF)) for YRbF in IHXE[1:]]",
"def Ln0Z(input):\n hlel = dict()\n if isinstance(input, list... | [
"0.7110415",
"0.6785707",
"0.672497",
"0.6671177",
"0.66500974",
"0.64433455",
"0.6346722",
"0.6278689",
"0.6190238",
"0.61778617",
"0.61064917",
"0.60896856",
"0.60601324",
"0.60337245",
"0.6024109",
"0.5996321",
"0.5984575",
"0.59722376",
"0.59721255",
"0.59593606",
"0.5889... | 0.54895365 | 70 |
Try to establish version control with an invalid version | def FgAe(YKHO):
L6MF = ('Thirteen', '-1', -1, '', 13)
for DpZH in L6MF:
try:
fZLH.create(YKHO.engine, YKHO.repos, DpZH)
YKHO.assertTrue(False, repr(DpZH))
except Bx6I.InvalidVersionError:
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def w8Fn(YKHO):\n YKHO.assertIsNone(YKHO._version_test(YKHO.no_version))",
"def UkX2(YKHO):\n hQHm = L6MF.Version(version='1.2.3', name='foo')\n aEqx = None\n YKHO.assertEqual(hQHm.build, aEqx)",
"def HyK_(YKHO):\n r44h = 'unknown version'\n with YKHO.assertRaisesRegexp(ValueError, r44h):\n ... | [
"0.68352205",
"0.6831202",
"0.6825282",
"0.65294236",
"0.65123844",
"0.6510586",
"0.6461885",
"0.63753134",
"0.6358751",
"0.6236324",
"0.6223833",
"0.62054825",
"0.6190483",
"0.61862504",
"0.6179952",
"0.6135915",
"0.61343217",
"0.6128363",
"0.6122344",
"0.61093444",
"0.60790... | 0.7330861 | 0 |
Get an item or attribute of an object but prefer the attribute. | def getattr(YKHO, YEnM: t.Any, xC3W: str) -> a1PO.Any:
try:
return getattr(YEnM, xC3W)
except AttributeError:
pass
try:
return YEnM[xC3W]
except (TypeError, LookupError, AttributeError):
return YKHO.undefined(obj=YEnM, name=xC3W) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _oqe(YEnM, hkS8, WmM4=None):\n from functools import partial\n gDr3 = partial(getattr, YEnM)\n gJdh = getattr(YEnM, '__getitem__', None) or gDr3\n try:\n return gJdh(hkS8)\n except (KeyError, AttributeError):\n return WmM4",
"def JgjC(YKHO, ZfUD):\n if ZfUD.startswith('_'):\n ... | [
"0.76386076",
"0.70016384",
"0.6998841",
"0.69968605",
"0.6903373",
"0.682826",
"0.67007834",
"0.6650254",
"0.6644323",
"0.66111374",
"0.65913266",
"0.65913266",
"0.6565057",
"0.65507996",
"0.6548512",
"0.65078104",
"0.6452337",
"0.6449073",
"0.6443441",
"0.6432434",
"0.64159... | 0.6867643 | 5 |
Lex the given sourcecode and return a generator that yields tokens as tuples in the form ``(lineno, token_type, value)``. | def hUZ1(YKHO, JZXy: str, mWFP: t.Optional[str]=None, Ux0P: t.Optional[str]=None) -> a1PO.Iterator[a1PO.Tuple[int, str, str]]:
JZXy = str(JZXy)
try:
return YKHO.lexer.tokeniter(JZXy, mWFP, Ux0P)
except F_Ra:
YKHO.handle_exception(source=JZXy) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wr3U(Wxnj):\n QP4x = 1\n jEd5 = 0\n for kUBT in UoRf.finditer(Wxnj):\n eJTR = kUBT.lastgroup\n BWXx = kUBT.group(eJTR)\n if eJTR == 'IGNORE':\n if '\\n' in BWXx:\n QP4x += BWXx.count('\\n')\n jEd5 = kUBT.start() + BWXx.rindex('\\n') + 1\n ... | [
"0.67679435",
"0.6550635",
"0.62877554",
"0.6271801",
"0.62701327",
"0.61371034",
"0.6123835",
"0.5884135",
"0.5834906",
"0.57587695",
"0.5707789",
"0.5693775",
"0.5676789",
"0.5670746",
"0.56177783",
"0.5597869",
"0.5578111",
"0.55625236",
"0.55542636",
"0.55083466",
"0.5503... | 0.6872963 | 0 |
For very large templates it can be useful to not render the whole template at once but evaluate each statement after another and yield piece for piece. This method basically does exactly that and returns a generator that yields one item after another as strings. | def C6M2(YKHO, *qIxc: t.Any, **B2fa: t.Any) -> a1PO.Iterator[str]:
if YKHO.environment.is_async:
import asyncio
async def to_list() -> a1PO.List[str]:
return [WKvO async for WKvO in YKHO.generate_async(*qIxc, **B2fa)]
yield from asyncio.run(mFWN())
return
OaeV = YKHO... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ftIh():\n yield 'a'\n yield 'b'\n yield 'c'",
"def c9WI():\n yield 1\n yield 2\n yield 3",
"def hbjg(hGN5, **QpfX):\n if hGN5 is None:\n yield u''\n elif isinstance(hGN5, exCv):\n yield hGN5\n elif callable(hGN5):\n for tTpl in hbjg(hGN5(**QpfX), **QpfX):\n ... | [
"0.59119636",
"0.5802921",
"0.57706994",
"0.5578495",
"0.55617845",
"0.5500655",
"0.5452796",
"0.5397037",
"0.5383921",
"0.53472006",
"0.5318249",
"0.53166026",
"0.52893597",
"0.52416563",
"0.52310807",
"0.5207066",
"0.5202807",
"0.5158685",
"0.51500714",
"0.5143144",
"0.5127... | 0.57749826 | 2 |
Create one hot vector(s) with the given index(indices). | def KLLm(d6pt, Htse, yDqo=oyIN.uint8):
tsWk = len(d6pt)
U5bT = oyIN.zeros((tsWk, Htse), yDqo)
for YRbF in range(tsWk):
U5bT[YRbF][d6pt[YRbF]] = 1
return U5bT | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kj8B(bADd, jTqs):\n V756 = oyIN.zeros((len(bADd), jTqs))\n for xV_c, xgs4 in enumerate(bADd):\n V756[xV_c, xgs4] = 1.0\n return V756",
"def W99O(P680, jTqs=10):\n svPB = P680.shape[0]\n whV7 = oyIN.arange(svPB) * jTqs\n xZkh = oyIN.zeros((svPB, jTqs))\n xZkh.flat[whV7 + P680.ravel... | [
"0.8202164",
"0.80405766",
"0.8024869",
"0.7740232",
"0.76883376",
"0.7674767",
"0.76424617",
"0.7626948",
"0.7626644",
"0.76210797",
"0.7614029",
"0.7602011",
"0.74203765",
"0.7378809",
"0.7365611",
"0.7365611",
"0.7365611",
"0.7365611",
"0.73653185",
"0.7332268",
"0.7101691... | 0.78042555 | 3 |
Get arguments from CLI | def rwTO():
wvEv = j1Jz.ArgumentParser(description='Remove the UCE locus name from nexus alignments.')
wvEv.add_argument('--alignments', required=True, action=QX2E, type=adwE, help='The input directory containing nexus files to filter')
wvEv.add_argument('--output', required=True, action=Hi4N, help='The out... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def mbGV(YKHO):\n pass",
"def rwTO():\n wvEv = xuJu()\n qIxc = wvEv.parse_args()\n return qIxc",
"def Ugfm():\n wvEv = j1Jz.ArgumentParser(description='list all installed packages')\n wvEv.add_argument('-v', '--verbose', help='increase output verbosity', action='store_true')\n wvEv.add_arg... | [
"0.83995515",
"0.7696954",
"0.7674078",
"0.7656369",
"0.75491726",
"0.7546294",
"0.7523218",
"0.7521475",
"0.7514517",
"0.75119865",
"0.74877495",
"0.74807847",
"0.74693704",
"0.7466727",
"0.74665916",
"0.74520636",
"0.74513096",
"0.7427955",
"0.7422721",
"0.74211824",
"0.740... | 0.0 | -1 |
Set value to default (for 3ds Max like behavior) > used on rightclick event | def UXGE(YKHO):
YKHO.setValue(YKHO.default_value) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bIMe(YKHO):\n YKHO.new_func_triggers.setText('(0,5)')\n YKHO.new_param.setText('1')",
"def bIMe(YKHO):\n YKHO.twin_triggers.setText('(2)')\n YKHO.twin_halves.setText('(0,0)')",
"def jUxV(YKHO, bGrB):\n YKHO.value = not YKHO.value",
"def bIMe(YKHO):\n YKHO.average_triggers.setText('(-50,... | [
"0.6751293",
"0.6524859",
"0.64412534",
"0.63850105",
"0.6328431",
"0.62392324",
"0.62146693",
"0.61695653",
"0.61534035",
"0.6149237",
"0.6133636",
"0.6128789",
"0.61026096",
"0.6005721",
"0.5999437",
"0.5959383",
"0.5949771",
"0.59134954",
"0.5910798",
"0.5894903",
"0.58427... | 0.68171674 | 0 |
Open a browser to the instructions page. | def hr0r(YKHO, tvqc):
_RPn(YKHO.instructionsURI) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QM3s(YKHO):\n HywK.open(YKHO.url)",
"def j91K(YKHO):\n HywK.open('https://github.com/ldrumm/yubikey-totp-gui')",
"def q0oV(YKHO):\n HywK.open('https://github.com/ldrumm/yubikey-totp-gui/wiki')",
"def XnFF() -> None:\n pmON = Hy7s.path.abspath(Hy7s.path.join('docs', '_build', 'html', 'index.ht... | [
"0.671832",
"0.65242296",
"0.64867294",
"0.64718336",
"0.6468435",
"0.6453586",
"0.6447694",
"0.6415966",
"0.64136815",
"0.6385538",
"0.63692135",
"0.6363255",
"0.63457465",
"0.6293899",
"0.62617403",
"0.6256758",
"0.62350434",
"0.622782",
"0.6187152",
"0.6147671",
"0.6137959... | 0.6440288 | 7 |
Returns if the word is in the trie. | def TgwQ(YKHO, GIN8: str) -> bool:
jvSB = YKHO.root
for sZqf in GIN8:
if sZqf not in jvSB.children:
return False
jvSB = jvSB.children[sZqf]
return jvSB.has_end | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DUe0(YKHO, ZOCz, GIN8):\n TXkI = ZOCz\n for sZqf in GIN8:\n if sZqf in TXkI:\n TXkI = TXkI[sZqf]\n else:\n return False\n else:\n if '_end_' in TXkI:\n return TXkI['_end_']\n else:\n return False\n return False",
"def Gtm1(ZO... | [
"0.8386823",
"0.81510955",
"0.81230164",
"0.7856358",
"0.7830011",
"0.77931386",
"0.7792269",
"0.7764405",
"0.7752762",
"0.7746937",
"0.7710187",
"0.7681166",
"0.76761425",
"0.76636624",
"0.7649853",
"0.7633719",
"0.7627433",
"0.7610955",
"0.75764817",
"0.7568698",
"0.7561647... | 0.7496588 | 25 |
Get the value at index i | def NMoC(YKHO, YRbF: int) -> int:
return YKHO.range_sum(YRbF, YRbF) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Psz5(YKHO, YRbF):\n return YKHO.x[YRbF]",
"def OP2O(YKHO, YRbF):\n if YRbF < YKHO.n:\n return YKHO.v[YRbF]",
"def OP2O(YKHO, YRbF):\n return YKHO.data[YRbF]",
"def OP2O(YKHO, YRbF):\n return YKHO.get(YRbF, YRbF + 1)",
"def NMoC(YKHO, YRbF):\n if YRbF < 0 or YRbF >= YKHO.d:\n ... | [
"0.7918859",
"0.7879606",
"0.7870006",
"0.78582245",
"0.783389",
"0.7766674",
"0.77607477",
"0.7732207",
"0.76742065",
"0.76378226",
"0.75980604",
"0.75442374",
"0.7514756",
"0.75061285",
"0.75061285",
"0.72349375",
"0.7164053",
"0.7116724",
"0.70552033",
"0.70226914",
"0.701... | 0.70332783 | 19 |
Parse a JSON string and set values to object attributes | def Ddor(YKHO, qQXR={}):
YKHO.original_json = qQXR
for H5ew in YKHO.__dict__.keys():
if H5ew in qQXR:
setattr(YKHO, H5ew, qQXR[H5ew])
YKHO.set_expiration() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def pktP(Emd4, vIwR):\n fK8P = qQXR.loads(vIwR)\n return Emd4.from_dict(fK8P)",
"def P4iH(YKHO, l3rX):\n xzoI = qQXR.loads(l3rX)\n YKHO.fromDict(xzoI)",
"def pktP(YKHO, zEKB):\n z1Rg = qQXR.loads(zEKB)\n C9U5 = {}\n if isinstance(YKHO, NCls.Model):\n C9U5 = YKHO.properties()\n fo... | [
"0.70797265",
"0.69475603",
"0.6919799",
"0.6772023",
"0.6679104",
"0.6679104",
"0.6625114",
"0.65511477",
"0.64009243",
"0.6389046",
"0.6380474",
"0.6378934",
"0.6337567",
"0.63174736",
"0.6316181",
"0.63122606",
"0.6268323",
"0.6268323",
"0.62550014",
"0.62462944",
"0.62334... | 0.6223071 | 21 |
Compute expiration date using expires_in attribute | def bdZ1(YKHO):
YKHO.expiration = qcWV.now() + fCoM(seconds=YKHO.expires_in - 10)
G9jH.debug('Token expiration set to %s' % YKHO.expiration) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ihMv(YKHO):\n N850 = qcWV.datetime.fromtimestamp(YKHO.expiration)\n wzkt = qcWV.datetime.now()\n return N850 - wzkt",
"def N850(YKHO):\n return qcWV(int(YKHO.exp_year), int(YKHO.exp_month), GRk0.monthrange(int(YKHO.exp_year), int(YKHO.exp_month))[1], 23, 59, 59)",
"def ad72(YKHO) -> str:\n r... | [
"0.7622574",
"0.74698514",
"0.7280477",
"0.72560334",
"0.7164952",
"0.7102859",
"0.7066285",
"0.7017344",
"0.6981535",
"0.6895895",
"0.6894819",
"0.6865071",
"0.6842095",
"0.6801995",
"0.67605644",
"0.67045385",
"0.6674677",
"0.6660995",
"0.66497314",
"0.66144174",
"0.6603656... | 0.66862017 | 16 |
Put instance to dict | def sY4V(YKHO, H5ew, p4_k):
with YKHO.GLOB_LOCK:
p4_k.touch()
YKHO._request_sessions[H5ew] = p4_k | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VUF1(YKHO, H5ew, YEnM):\n o8Kj = YKHO.load_attrs()\n o8Kj[H5ew] = YEnM\n YKHO.store_attrs(o8Kj)",
"def NpNj(Emd4, YEnM):\n pass",
"def QdZT(YKHO, YEnM):\n YKHO.identity_map[YEnM._instance_key] = YEnM\n YKHO.register_dirty(YEnM)",
"def weDf(YKHO, YEnM):\n for hkS8, BWXx in YEnM.__dict... | [
"0.6583491",
"0.645932",
"0.63589305",
"0.6323048",
"0.6297056",
"0.6233517",
"0.62055385",
"0.61510074",
"0.60864174",
"0.60864174",
"0.6069794",
"0.6049458",
"0.6028055",
"0.60183156",
"0.60183156",
"0.6007885",
"0.6007885",
"0.59967583",
"0.5995191",
"0.598711",
"0.5958743... | 0.0 | -1 |
Used by fit_predict to return model evaluation metrics through crossvalidation, specifically for classification models | def ytex(YKHO, SLsv, CjQX, BJkr=None):
bOAs = []
ud5V = []
hMgM = []
F2ET = []
for C3ST in YKHO.list_of_models:
bOAs.append(nD1h(C3ST, SLsv, CjQX, cv=BJkr, scoring='f1').mean())
ud5V.append(nD1h(C3ST, SLsv, CjQX, cv=BJkr, scoring='recall').mean())
hMgM.append(nD1h(C3ST, SLsv,... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vJhk():\n Y8eF = oyIN.random.randint(2, size=10000)\n aMgO = oyIN.clip(oyIN.random.normal(0.25, 0.3, size=Y8eF.shape) + Y8eF * 0.5, 0, 1)\n MULd = PaZQ(y_true=Y8eF, y_pred=aMgO, class_names=['a', 'b'], model_name='foo')\n return MULd",
"def b7La(C3ST, n7Bx, svPB):\n C3ST.eval()\n dixj = [YE... | [
"0.75144696",
"0.7497496",
"0.7349594",
"0.73141915",
"0.72244525",
"0.7207625",
"0.7183288",
"0.7131278",
"0.71118087",
"0.7104797",
"0.70812535",
"0.7079839",
"0.7022299",
"0.7016983",
"0.6995465",
"0.69783986",
"0.6972256",
"0.6970008",
"0.69450635",
"0.6928211",
"0.692635... | 0.69236493 | 22 |
Used by fit_predict to return model evaluation metrics through crossvalidation, specifically for regression models | def NYO6(YKHO, SLsv, CjQX, BJkr=None):
c8jH = []
G7r1 = []
for C3ST in YKHO.list_of_models:
c8jH.append(nD1h(C3ST, SLsv, CjQX, cv=BJkr, scoring='r2').mean())
G7r1.append(nD1h(C3ST, SLsv, CjQX, cv=BJkr, scoring='neg_mean_squared_error').mean())
return (c8jH, G7r1) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def b7La(C3ST, n7Bx, svPB):\n C3ST.eval()\n dixj = [YEmv(C3ST, WKvO) for WKvO, LVAh in n7Bx]\n CCGu, vjyh = lonc(oyIN.array([LVAh for WKvO, LVAh in n7Bx]), dixj, svPB)\n return (CCGu, vjyh)",
"def ObOY(C3ST, ZGE9, Lcqa, PLcF, Z5wO, yLaY):\n print('\\t\\tModel [' + ZGE9 + ']')\n C3ST.fit(Lcqa, P... | [
"0.7434861",
"0.7095115",
"0.70465183",
"0.69509083",
"0.69131374",
"0.69102055",
"0.6908029",
"0.6902455",
"0.6881166",
"0.68446517",
"0.68426144",
"0.6794651",
"0.6793014",
"0.6780967",
"0.67757785",
"0.67669886",
"0.674755",
"0.67341805",
"0.67236453",
"0.67236406",
"0.671... | 0.7326447 | 1 |
Tokenize the text input using NLTKs word_tokenize() | def x1CH(l5Ny):
return [GIN8 for GIN8 in dFss(l5Ny) if GIN8.isalpha() == 1] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def x1CH(l5Ny):\n return Dhdw.tokenize.word_tokenize(l5Ny)",
"def wr3U(l5Ny):\n l5Ny = l5Ny.decode('utf-8')\n return Dhdw.word_tokenize(l5Ny)",
"def wr3U(Novh):\n PuKl = Dhdw.tokenize.word_tokenize(Novh)\n return PuKl",
"def wr3U(l5Ny):\n s2mk = dFss(l5Ny)\n LkXt = GFnk()\n zKDd = []\... | [
"0.8303857",
"0.8129445",
"0.8039359",
"0.7953297",
"0.7948555",
"0.7920005",
"0.79193926",
"0.7915047",
"0.78726137",
"0.7844544",
"0.7812001",
"0.7803892",
"0.7794861",
"0.77789605",
"0.7771819",
"0.77714103",
"0.775791",
"0.7755309",
"0.7747356",
"0.7747356",
"0.7741924",
... | 0.0 | -1 |
Return the api id. | def iOu8(nUeQ):
with open(nUeQ, 'r') as eHNT:
GuSc = t2lc.load(eHNT)
return GuSc['id'] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def unpH(YKHO):\n return YKHO.get_api_endpoint()",
"def eC7C(YKHO) -> int:\n try:\n eC7C = int(YKHO._parser.get(uwaB.CLIENT_CREDENTIALS_SECTION, 'API_ID'))\n return eC7C\n except enR0.NoSectionError:\n raise enR0.Error(f'Конфигурационный файл сессии не содержит секции {uwaB.CLIENT_C... | [
"0.8192269",
"0.7923326",
"0.72857684",
"0.7060594",
"0.70565146",
"0.6860814",
"0.68273765",
"0.682589",
"0.6823798",
"0.67648923",
"0.6728808",
"0.6701726",
"0.6701726",
"0.6701726",
"0.6701726",
"0.6701726",
"0.6701726",
"0.6701726",
"0.6701726",
"0.6701726",
"0.6701726",
... | 0.6827555 | 6 |
Add entities for passed config_entry in HA. | async def async_setup_entry(ajET: HomeAssistant, PhL6: ConfigEntry, QEEk: AddEntitiesCallback) -> None:
Kb4M: Gn0L = ajET.data[Sugg][PhL6.entry_id]
jCrj = []
for z6EK in Kb4M.vacuum_bots:
jCrj.append(OP6s(z6EK))
if jCrj:
QEEk(jCrj)
a9EH = DhFh.async_get_current_platform()
a9EH.as... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def async_setup_entry(ajET: HomeAssistant, PhL6: ConfigEntry, QEEk: AddEntitiesCallback) -> None:\n CYAo: dict[str, TtLW] = ajET.data[Sugg][PhL6.entry_id]\n QEEk((i6PU(S3vU, JBZA) for S3vU in CYAo.values() for JBZA in AUCP))",
"async def async_setup_entry(ajET: HomeAssistant, PhL6: ConfigEntry, QEEk:... | [
"0.6562468",
"0.62983084",
"0.62799484",
"0.6278163",
"0.6274243",
"0.6206305",
"0.6205755",
"0.61862373",
"0.6179064",
"0.6165534",
"0.61598295",
"0.61379576",
"0.6122485",
"0.6107209",
"0.6097407",
"0.6094783",
"0.6083814",
"0.6058082",
"0.60489327",
"0.6046326",
"0.6040817... | 0.57070255 | 55 |
Return entity specific state attributes. Implemented by platform classes. Convention for attribute names is lowercase snake_case. | def TzCU(YKHO) -> h8nf[GySg[str, ImMB]]:
azoT: dict[str, ImMB] = {}
DFSo: dict[str, ImMB] = {}
for abiq in YKHO._rooms:
XIAj = eIIt(abiq.subtype)
EDq2 = DFSo.get(XIAj)
if EDq2 is None:
DFSo[XIAj] = abiq.id
elif isinstance(EDq2, list):
EDq2.append(abiq.... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TzCU(YKHO):\n q8_C = {}\n if YKHO.vendor_id is not None:\n q8_C[MEij] = YKHO.vendor_id\n q8_C[c_Nx] = YKHO.vendor_name\n if YKHO.type_id is not None:\n q8_C[TEro] = YKHO.type_id\n q8_C[MWr3] = YKHO.type\n if YKHO.physical_address is not None:\n q8_C[E7ph] = YKHO.p... | [
"0.7229976",
"0.718195",
"0.7141178",
"0.7116054",
"0.70937127",
"0.70072806",
"0.700647",
"0.70009476",
"0.6985321",
"0.69266015",
"0.6921594",
"0.69194144",
"0.69184166",
"0.68879586",
"0.68854785",
"0.6869149",
"0.6866153",
"0.68570524",
"0.68570524",
"0.6848794",
"0.68487... | 0.0 | -1 |
Create the app object and return it | def LUif():
P4t4 = L2w0(__name__)
gCuF = Hy7s.environ.get('FLASK_SETTINGS', fvfo)
if gCuF is not None:
Z9rn = PSrQ(gCuF)
print(Z9rn)
P4t4.config.update(Z9rn.get_map('flask'))
from users.views import user
P4t4.register_blueprint(user)
NCls.init_app(P4t4)
return P4t4 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P4t4():\n P4t4 = LUif()\n return P4t4",
"def P4t4():\n return LUif()",
"def LUif(YKHO):\n raise NotImplementedError",
"def eLpg():\n return Z33s()",
"def g8SW(cUQu):\n return LUif()",
"def WTdB(YKHO):\n return m36K()",
"def LUif(YKHO):\n P4t4 = LUif()\n P4t4.config.from_o... | [
"0.86219174",
"0.846839",
"0.841322",
"0.83985764",
"0.8334573",
"0.8106147",
"0.7955877",
"0.786966",
"0.7774832",
"0.7769306",
"0.76641476",
"0.7636182",
"0.76080185",
"0.7546913",
"0.75468355",
"0.7538712",
"0.75114894",
"0.7456657",
"0.7455357",
"0.7442867",
"0.7377457",
... | 0.70880806 | 55 |
Paints the selection item. | def DN3z(YKHO, TZ9E):
if TZ9E == 'skin':
YKHO.paintOptions(['skin.png'], 'skin')
elif TZ9E == 'mask':
if YKHO.avatarConfiguration['gender'] == 'boy':
YKHO.paintOptions(['masko.png'], 'mask')
else:
YKHO.paintOptions(['maska.png'], 'mask')
elif TZ9E == 'hair':
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nWQL(YKHO):\n if YKHO.get_selected() is not None and (not YKHO.check_if_locked(YKHO.get_selected())):\n YKHO.color_cell(pos=YKHO.get_selected(), color=wmw7 if YKHO.get_selected() in YKHO.invalid else ckqW)",
"def FGcs(YKHO):\n YKHO.colour = YKHO.selected_colour\n YKHO.is_selected = True\n ... | [
"0.73639786",
"0.70427626",
"0.70354766",
"0.6993003",
"0.69353014",
"0.69259495",
"0.675598",
"0.6746916",
"0.6717034",
"0.6652914",
"0.6550275",
"0.6456941",
"0.6437748",
"0.6332917",
"0.6258266",
"0.618958",
"0.6188641",
"0.61616313",
"0.6113218",
"0.6105374",
"0.61021817"... | 0.6198362 | 15 |
Opens the close file dialog. | def gtRX(YKHO, Aofo):
AesY = None
if Aofo == 'OK':
AesY = YKHO.listDir.getFileName()
if AesY:
YKHO.showImage(AesY)
YKHO.window.remove_child(YKHO.dialog)
YKHO.dialog.destroy()
YKHO.fileDialogShow = False | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def mCn1(YKHO):\n YKHO.on_closing()",
"def DDI8(nUeQ):\n qIxc = {'file': nUeQ}\n XtSf('close', qIxc)",
"def vwhf(*qIxc):\n global _dialog\n if eXMs is not None:\n eXMs.destroy()\n eXMs = None",
"def e8we(YKHO):\n YKHO.close()",
"def qsZa(YKHO):\n if YKHO.file_changed:\n ... | [
"0.73460746",
"0.7023839",
"0.69492364",
"0.6878078",
"0.6840062",
"0.67554885",
"0.66877294",
"0.6682146",
"0.6671386",
"0.6671386",
"0.6643962",
"0.6637478",
"0.6610322",
"0.659762",
"0.65933716",
"0.6540071",
"0.65233684",
"0.64974564",
"0.6469414",
"0.6468541",
"0.6468206... | 0.7020331 | 2 |
To create the summed profile of all individual profiles in an instance, we can use a dictionary comprehension to iterate over all profiles in the instance. | def UPv6(YKHO, KAOR):
z9WV = oyIN.arange(YKHO.data.shape[0])
return sum([z39Z.model_data_1d_via_xvalues_from(xvalues=z9WV) for z39Z in KAOR]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MB1u(YKHO):\n YKHO._profiles = {G1Hx: oyIN.zeros((len(YKHO.hybrid_time_index), len(YKHO.hybrid_meta)), dtype=oyIN.float32) for G1Hx in RPAo}",
"def z39Z(YKHO, nPrm):\n YKHO.profile = {}\n uqWb = nPrm\n for Sf7Z in YKHO.analysis.morphisms:\n eb88 = Sf7Z.name\n uqWb = Sf7Z.apply(uqWb)... | [
"0.6303733",
"0.6003777",
"0.60003054",
"0.5991352",
"0.5959558",
"0.59029984",
"0.5899841",
"0.5897682",
"0.5875563",
"0.5859356",
"0.58367246",
"0.5785412",
"0.57500017",
"0.57378715",
"0.572503",
"0.56675404",
"0.5656984",
"0.5638969",
"0.56253994",
"0.56197834",
"0.561978... | 0.0 | -1 |
This method is identical to the previous tutorial, except it now uses the `model_data_from_instance` method to create the profile. | def rzaM(YKHO, ckRy, KAOR, IYap):
z9WV = oyIN.arange(YKHO.data.shape[0])
iGq6 = YKHO.model_data_from_instance(instance=KAOR)
d7pH = YKHO.data - iGq6
pyEL = (d7pH / YKHO.noise_map) ** 2.0
'The visualizer now outputs images of the best-fit results to hard-disk (checkout `visualizer.py`).'
stuG(xva... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dVQZ(vC92, KAOR, **B2fa):\n if B2fa['created']:\n zJFA = h6OD(user=KAOR)\n zJFA.save()",
"def euOS(vC92, **B2fa):\n from .profiles import Profile\n CBIr = B2fa['instance']\n Profile.objects.get_or_create(user=CBIr)",
"def euOS(vC92, **B2fa):\n CBIr = B2fa['instance']\n if B2... | [
"0.7288304",
"0.7257323",
"0.72221214",
"0.72215366",
"0.7192119",
"0.7140724",
"0.7114105",
"0.7092448",
"0.7081291",
"0.7081034",
"0.7064456",
"0.7064456",
"0.7064456",
"0.69776773",
"0.6940732",
"0.69337696",
"0.69326335",
"0.6882552",
"0.6872377",
"0.68693244",
"0.6825349... | 0.0 | -1 |
Returns a 1D Gaussian on an input list of Cartesian x coordinates. The input xvalues are translated to a coordinate system centred on the Gaussian, via its `centre`. The output is referred to as the `model_data` to signify that it is a representation of the data from the model. | def nEhT(YKHO, z9WV: np.ndarray):
NAMV = oyIN.subtract(z9WV, YKHO.centre)
return oyIN.multiply(oyIN.divide(YKHO.normalization, YKHO.sigma * oyIN.sqrt(2.0 * oyIN.pi)), oyIN.exp(-0.5 * oyIN.square(oyIN.divide(NAMV, YKHO.sigma)))) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nEhT(YKHO, z9WV: np.ndarray) -> oyIN.ndarray:\n NAMV = z9WV - YKHO.centre\n return oyIN.multiply(oyIN.divide(YKHO.normalization, YKHO.sigma * oyIN.sqrt(2.0 * oyIN.pi)), oyIN.exp(-0.5 * oyIN.square(oyIN.divide(NAMV, YKHO.sigma))))",
"def Izfz(u6FM, jHsn, pvd3=1, WyJz=1, dut3=None, OzN1=None, KQji=None, ... | [
"0.6511304",
"0.62219405",
"0.60758066",
"0.58818203",
"0.58516496",
"0.5827418",
"0.5708849",
"0.5660607",
"0.56337976",
"0.5622666",
"0.55980283",
"0.55980283",
"0.55621004",
"0.5559702",
"0.5481954",
"0.5396391",
"0.5382293",
"0.5382293",
"0.53440315",
"0.53438157",
"0.529... | 0.6594829 | 0 |
Returns a 1D Gaussian on an input list of Cartesian x coordinates. The input xvalues are translated to a coordinate system centred on the Gaussian, via its `centre`. The output is referred to as the `model_data` to signify that it is a representation of the data from the model. | def nEhT(YKHO, z9WV: np.ndarray):
NAMV = oyIN.subtract(z9WV, YKHO.centre)
return YKHO.normalization * oyIN.multiply(YKHO.rate, oyIN.exp(-1.0 * YKHO.rate * abs(NAMV))) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nEhT(YKHO, z9WV: np.ndarray):\n NAMV = oyIN.subtract(z9WV, YKHO.centre)\n return oyIN.multiply(oyIN.divide(YKHO.normalization, YKHO.sigma * oyIN.sqrt(2.0 * oyIN.pi)), oyIN.exp(-0.5 * oyIN.square(oyIN.divide(NAMV, YKHO.sigma))))",
"def nEhT(YKHO, z9WV: np.ndarray) -> oyIN.ndarray:\n NAMV = z9WV - YKH... | [
"0.6594319",
"0.6510771",
"0.62236106",
"0.60766315",
"0.5882499",
"0.585287",
"0.58271587",
"0.5708917",
"0.56606776",
"0.56216574",
"0.55980146",
"0.55980146",
"0.55620664",
"0.5561733",
"0.54832405",
"0.5397384",
"0.5380961",
"0.5380961",
"0.5345305",
"0.5344314",
"0.52946... | 0.56327635 | 9 |
Convert UTC datetime to localtime timezone ('Europe/Stockholm') | def mpjk(JRYC):
yl4j = FXGE.timezone('Europe/Stockholm')
JRYC = JRYC.replace(tzinfo=FXGE.utc)
JRYC = JRYC.astimezone(yl4j)
return JRYC | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DIUo(BWXx, rIAI):\n return ilPy(BWXx, gCuF.TIME_ZONE, rIAI)",
"def C9Yl(JRYC, yl4j):\n return JRYC.replace(tzinfo=FXGE.utc).astimezone(yl4j)",
"def X4qZ(_c1T):\n return _c1T - (qcWV.utcnow() - qcWV.now())",
"def lVFF(ppPa):\n return FXGE.utc.localize(ppPa)",
"def lVFF(ppPa):\n return FXG... | [
"0.6936038",
"0.67989963",
"0.6781287",
"0.6716644",
"0.6716644",
"0.6716644",
"0.6712792",
"0.6622246",
"0.66188514",
"0.6613277",
"0.6530687",
"0.6522463",
"0.6522463",
"0.65096396",
"0.650923",
"0.6456534",
"0.64432096",
"0.6438188",
"0.6429396",
"0.64009583",
"0.63939345"... | 0.8419736 | 0 |
Set the payload to the given value. | def hvMA(YKHO, pB3N):
YKHO._payload = pB3N | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QocE(YKHO, pB3N):\n YKHO.__payload = pB3N",
"def hvMA(YKHO, pB3N):\n YKHO.payload = qQXR.dumps(pB3N)",
"def hvMA(YKHO, pB3N):\n YKHO._str_payload = pB3N\n YKHO._obj_payload = None",
"def pB3N(YKHO, pB3N):\n YKHO._payload = pB3N",
"def hvMA(YKHO, pB3N):\n if len(pB3N) > 9:\n rai... | [
"0.77700126",
"0.7607542",
"0.759514",
"0.75175667",
"0.7101841",
"0.7013674",
"0.67309165",
"0.6662137",
"0.6647326",
"0.65303284",
"0.6516512",
"0.64631796",
"0.64532405",
"0.6440627",
"0.64308095",
"0.6426576",
"0.6417389",
"0.6417389",
"0.6417389",
"0.6417389",
"0.6417389... | 0.7944514 | 0 |
Return a list of all the values for the named field. These will be sorted in the order they appeared in the original message, and may contain duplicates. Any fields deleted and reinserted are alwyas appended to the header list. | def cqaF(YKHO, mWFP, _j54=None):
hkxX = []
mWFP = mWFP.lower()
for G1Hx, Ty9i in YKHO._headers:
if G1Hx.lower() == mWFP:
hkxX.append(Ty9i)
return hkxX | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def EhAn(Emd4):\n return [YRbF[0] for YRbF in sorted(Emd4._nameToValue.items(), key=lambda ZfUD: ZfUD[1])]",
"def V_D6(YKHO):\n return [eHNT[1] for eHNT in sorted(YKHO.dd.fields.items())]",
"def zJN_(YKHO):\n return {im04[0] for im04 in YKHO.iter_fields()}",
"def V_D6(YKHO):\n return YKHO._by_nam... | [
"0.7227821",
"0.68804765",
"0.65010124",
"0.64877665",
"0.6461606",
"0.64428866",
"0.6391083",
"0.63055766",
"0.6281034",
"0.6247848",
"0.6242284",
"0.62284935",
"0.6167847",
"0.61624306",
"0.61449486",
"0.6140014",
"0.6131532",
"0.6087768",
"0.60766345",
"0.6065869",
"0.6057... | 0.60114175 | 23 |
Get the brightness of the dither object. | def hyHz(YKHO):
dSjZ.caca_get_dither_brightness.argtypes = [xvks]
dSjZ.caca_get_dither_brightness.restype = gk2W.c_float
return dSjZ.caca_get_dither_brightness(YKHO) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def asva(YKHO) -> float:\n Mkmy, Oa1e, Fg_i = (YKHO.r, YKHO.g, YKHO.b)\n return PZyS(0.299 * Mkmy ** 2 + 0.587 * Oa1e ** 2 + 0.114 * Fg_i ** 2) / 255",
"def asva(YKHO):\n return YKHO.get_value('bri')",
"def asva(YKHO):\n return round(YKHO._device.current_percentage / 100 * 255)",
"def asva(YKHO):... | [
"0.8029478",
"0.7875212",
"0.77922827",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.7781082",
"0.77647805",
"0.7688449",
"0.7615564",
"0.74948394",
"0.74389976",
"0.73013204"... | 0.88095915 | 0 |
Return the dither's current antialiasing method. | def oRLX(YKHO):
dSjZ.caca_get_dither_antialias.argtypes = [xvks]
dSjZ.caca_get_dither_antialias.restype = gk2W.c_char_p
return dSjZ.caca_get_dither_antialias(YKHO) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def l1Nn(*qIxc, **B2fa):\n return nAU3.GraphicsContext_GetAntialiasMode(*qIxc, **B2fa)",
"def u0jW(YKHO, BWXx):\n dSjZ.caca_set_dither_antialias.argtypes = [xvks, gk2W.c_char_p]\n dSjZ.caca_set_dither_antialias.restype = gk2W.c_int\n return dSjZ.caca_set_dither_antialias(YKHO, BWXx)",
"def izj_(*qI... | [
"0.7316774",
"0.70382136",
"0.62590796",
"0.5920561",
"0.55210084",
"0.54143494",
"0.50951344",
"0.5059895",
"0.50450474",
"0.48415008",
"0.48221686",
"0.4799041",
"0.478852",
"0.47513354",
"0.47095522",
"0.4669869",
"0.46551496",
"0.46278602",
"0.46060565",
"0.4600004",
"0.4... | 0.7915878 | 0 |
Choose colours used for dithering. value A string describing the colour set that will be used for the dithering. | def rqSI(YKHO, BWXx):
dSjZ.caca_set_dither_color.argtypes = [xvks, gk2W.c_char_p]
dSjZ.caca_set_dither_color.restype = gk2W.c_int
return dSjZ.caca_set_dither_color(YKHO, BWXx) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YUDJ(YKHO, BWXx):\n dSjZ.caca_set_dither_charset.argtypes = [xvks, gk2W.c_char_p]\n dSjZ.caca_set_dither_charset.restype = gk2W.c_int\n return dSjZ.caca_set_dither_charset(YKHO, BWXx)",
"def qfpW(BWXx):\n return 'RGB({}, {}, {})'.format(BWXx.red(), BWXx.blue(), BWXx.green())",
"def qfpW(YKHO, B... | [
"0.6068375",
"0.6018215",
"0.5914558",
"0.5752664",
"0.57084477",
"0.5689596",
"0.5675022",
"0.5637268",
"0.56303346",
"0.5612185",
"0.5524138",
"0.5523459",
"0.55111074",
"0.5506187",
"0.54789203",
"0.5464128",
"0.5463799",
"0.5461586",
"0.5434332",
"0.54321027",
"0.54320204... | 0.6906732 | 0 |
Get current colour mode. | def PICn(YKHO):
dSjZ.caca_get_dither_color.argtypes = [xvks]
dSjZ.caca_get_dither_color.restype = gk2W.c_char_p
return dSjZ.caca_get_dither_color(YKHO) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oiAm(YKHO):\n Tuqy = _e0h.is_SetColorMode(YKHO.hcam, 32768)\n return YKHO._color_modes_inv.get(Tuqy, Tuqy)",
"def neC1(YKHO):\n return wUyi.Camera.color_mode.__get__(YKHO)",
"def neC1(YKHO) -> p1Fd:\n if YKHO._dimmable:\n return p1Fd.BRIGHTNESS\n return p1Fd.ONOFF",
"def GK0q(YKHO):... | [
"0.8506589",
"0.8062411",
"0.75024205",
"0.7239905",
"0.7206059",
"0.71338886",
"0.70655864",
"0.7058712",
"0.705761",
"0.7049096",
"0.7003177",
"0.6987268",
"0.6987268",
"0.6925067",
"0.69029975",
"0.68971854",
"0.68906504",
"0.6877764",
"0.6841367",
"0.68247694",
"0.6807551... | 0.0 | -1 |
Create new Heap based on priority argument | def Drgm(YKHO, TEzZ):
EuPg = YKHO.priorities
EuPg[TEzZ] = o1DR() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Onlz(YKHO, Gjtu):\n for H5ew in Gjtu:\n Q6kx = YKHO.HeapNode(H5ew, Gjtu[H5ew])\n _eVy.heappush(YKHO.heap, Q6kx)",
"def QZno(WKvO):\n pass",
"def Npt8(YKHO):\n exwG = int(len(YKHO.array) / 2 - 1)\n while exwG >= 0:\n YKHO.heapify_top_down(exwG)\n exwG -= 1",
"def yr... | [
"0.7393375",
"0.67986894",
"0.64988506",
"0.6449566",
"0.6432171",
"0.6426354",
"0.64262825",
"0.64262825",
"0.64262825",
"0.64245623",
"0.6410928",
"0.63822424",
"0.6370285",
"0.63593113",
"0.63568485",
"0.63538027",
"0.6352294",
"0.6352216",
"0.63434476",
"0.6324766",
"0.63... | 0.74990505 | 0 |
Insert new node into Heap, based on priority. The order of the insert is maintained by order dictating the value of the node in each Heap. | def JPHp(YKHO, TEzZ):
EuPg = YKHO.priorities
if TEzZ > 10 or TEzZ < 1:
raise ValueError('Priority must be between 1 (high) - 10 (low)')
if TEzZ not in EuPg.keys():
YKHO._create_priorities(TEzZ)
Ey19 = EuPg.get(TEzZ)
Ey19.push(YKHO._order)
YKHO._order += 1 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JPHp(YKHO, BWXx, Ey19=2):\n if not isinstance(Ey19, int):\n raise TypeError('Priority must be an integer')\n if Ey19 in YKHO.priority_queue:\n YKHO.priority_queue[Ey19].append(BWXx)\n else:\n YKHO.priority_queue[Ey19] = [BWXx]\n print(YKHO.priority_queue)",
"def JPHp(YKHO, Q6... | [
"0.7493382",
"0.747859",
"0.7303172",
"0.7274606",
"0.7218348",
"0.7193368",
"0.6929881",
"0.6925497",
"0.6896418",
"0.68946266",
"0.68823105",
"0.6800372",
"0.67784363",
"0.67307657",
"0.6704276",
"0.6652443",
"0.66325456",
"0.6625264",
"0.66204196",
"0.65797853",
"0.6561100... | 0.7620247 | 0 |
Returns multiple hex strings `data` as bytes. | def BJGj(nPrm: Iterable[str]) -> bytes:
J83E = qw7D('B')
for Vhvp in nPrm:
J83E.extend((int(Vhvp[d6pt:d6pt + 2], 16) for d6pt in range(0, len(Vhvp), 2)))
return J83E.tobytes() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RcKA(nPrm: bytes) -> str:\n return ''.join((ZW0g(YB8B) for YB8B in nPrm))",
"def bzm3(nPrm):\n return MRxC.b2a_hex(nPrm)",
"def f_5l(nPrm: str) -> bytes:\n J83E = qw7D('B', (int(nPrm[d6pt:d6pt + 2], 16) for d6pt in range(0, len(nPrm), 2)))\n return J83E.tobytes()",
"def _PYX(nPrm):\n\n def... | [
"0.7278739",
"0.69301456",
"0.68820524",
"0.67279637",
"0.67273766",
"0.6685252",
"0.6528643",
"0.6507147",
"0.6499234",
"0.6466613",
"0.64450103",
"0.643173",
"0.6396244",
"0.63774174",
"0.6301702",
"0.62324184",
"0.6211707",
"0.6182273",
"0.61719114",
"0.60947466",
"0.60823... | 0.8027493 | 0 |
Returns hex string `data` as bytes. | def f_5l(nPrm: str) -> bytes:
J83E = qw7D('B', (int(nPrm[d6pt:d6pt + 2], 16) for d6pt in range(0, len(nPrm), 2)))
return J83E.tobytes() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RcKA(nPrm: bytes) -> str:\n return ''.join((ZW0g(YB8B) for YB8B in nPrm))",
"def BJGj(nPrm: Iterable[str]) -> bytes:\n J83E = qw7D('B')\n for Vhvp in nPrm:\n J83E.extend((int(Vhvp[d6pt:d6pt + 2], 16) for d6pt in range(0, len(Vhvp), 2)))\n return J83E.tobytes()",
"def bzm3(nPrm):\n ret... | [
"0.7540623",
"0.72735554",
"0.7264539",
"0.7164419",
"0.712034",
"0.7057515",
"0.70497096",
"0.7027782",
"0.7005459",
"0.69885397",
"0.67918706",
"0.66520184",
"0.6585216",
"0.65836406",
"0.6557071",
"0.6551698",
"0.6516621",
"0.6486435",
"0.62897897",
"0.62782013",
"0.624652... | 0.7490721 | 1 |
Create a user with the given email and password. | def lYUQ(YKHO, D3lj: str, jTXt: str, **B2fa: str) -> 'User':
D3lj = YKHO.normalize_email(D3lj)
CBIr: 'User' = YKHO.model(email=D3lj, **B2fa)
CBIr.set_password(jTXt)
CBIr.save()
return CBIr | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lYUQ(D3lj, jTXt='test', **B2fa):\n CBIr = egNl().objects.create(email=D3lj, **B2fa)\n CBIr.set_password(jTXt)\n CBIr.save()\n return CBIr",
"def lYUQ(D3lj='user@example.com', jTXt='testpass123'):\n return egNl().objects.create_user(email=D3lj, password=jTXt)",
"def xWi2(YKHO, D3lj, jTXt, **w... | [
"0.8815903",
"0.8682614",
"0.86186355",
"0.8592563",
"0.8572997",
"0.8572997",
"0.8572997",
"0.8563415",
"0.8554833",
"0.8554833",
"0.8511704",
"0.851129",
"0.8505482",
"0.85019517",
"0.85019517",
"0.85019517",
"0.84820235",
"0.8475811",
"0.84723836",
"0.8463488",
"0.84614134... | 0.8355751 | 48 |
Format the given UNIX timestamp in the '%Y%m%d%H%M%S%Z' format. timestamp (int) The timestamp to convert. (str) The converted timestamp. | def Rrvb(YKHO, E3oo):
return ITS7.strftime('%Y%m%d-%H%M%S-%Z', ITS7.localtime(E3oo)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dd_C(E3oo: float) -> str:\n JRYC = qcWV.utcfromtimestamp(E3oo)\n return JRYC.strftime('%Y/%m/%d %H:%M:%S UTC%z')",
"def bpfo(Emd4, E3oo):\n return FdZ9(E3oo).strftime('%Y-%m-%d %H:%M:%S')",
"def dd_C(E3oo):\n try:\n _c1T = qcWV.strptime(E3oo, '%Y-%m-%d %H:%M:%S+00:00')\n return qc... | [
"0.8248668",
"0.7892845",
"0.75943416",
"0.74010617",
"0.7311571",
"0.7187406",
"0.7116556",
"0.70874643",
"0.70874643",
"0.70874643",
"0.70685565",
"0.7060189",
"0.6967192",
"0.6936942",
"0.69314146",
"0.68966395",
"0.67437476",
"0.6722041",
"0.6721315",
"0.6598178",
"0.6546... | 0.831771 | 0 |
Initialisation. sensorMac (str) The MACaddress of the Bluetooth sensor. | def FIMM(YKHO, t0qN, ayrW, kv8G, Kiqw):
Few0.__init__(YKHO, t0qN, ayrW, kv8G)
YKHO.sensor = Kiqw
YKHO.logFiles = ['scan', 'rssi']
YKHO.logs = dict(zip(YKHO.logFiles, [open('/'.join([YKHO.logDir, '%s-%s-%s.log' % (YKHO.hostname, YKHO.sensor, YRbF)]), 'a') for YRbF in YKHO.logFiles]))
YKHO.enableLagLo... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Pp4r(YKHO, Pp4r):\n YKHO._mac = Pp4r",
"def FIMM(YKHO, Q6kx, Pp4r, qi1f):\n super().__init__(Q6kx, Pp4r)\n YKHO.sensor_id = qi1f\n YKHO.sensor_type = eNPw[qi1f]\n YKHO.node_callbacks = (byrW, qi1f)",
"def dDjK(YKHO):\n lo9Y = '[!] Mac Absolute timestamps are 9 digits, commonly followed by... | [
"0.64202636",
"0.63291633",
"0.6165792",
"0.61127704",
"0.6004181",
"0.5994989",
"0.5994989",
"0.59901",
"0.5957456",
"0.5901115",
"0.58880174",
"0.588691",
"0.58227724",
"0.5801586",
"0.57481027",
"0.5727732",
"0.5703983",
"0.5703345",
"0.5699915",
"0.5689891",
"0.568221",
... | 0.0 | -1 |
Quantizes a value to the closest value in a list of quantized values. | def AaEW(BWXx, _Nd4, I1CP=False):
MEkb = [(_Nd4[YRbF] + _Nd4[YRbF + 1]) / 2.0 for YRbF in range(len(_Nd4) - 1)]
QyVM = Ce1H.bisect_right(MEkb, BWXx)
if I1CP:
return (QyVM, _Nd4[QyVM])
else:
return _Nd4[QyVM] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xoYv(OxJJ, BWXx):\n return min(enumerate(OxJJ), key=lambda YRbF: abs(YRbF[1] - BWXx))",
"def GScs(w_3R: list, Te46: int):\n gdEx = lambda IKl7: abs(IKl7 - Te46)\n return min(w_3R, key=gdEx)",
"def JBGM(hkxX, NXpY):\n for Ty9i in range(len(hkxX)):\n hkxX[Ty9i] = aevO.quantify(hkxX[Ty9i], ... | [
"0.60405785",
"0.60346353",
"0.59024376",
"0.58044064",
"0.5680126",
"0.5652785",
"0.5632271",
"0.56285363",
"0.56191117",
"0.5606158",
"0.55948305",
"0.55835664",
"0.5536345",
"0.5536345",
"0.5513843",
"0.5510794",
"0.5436136",
"0.54047954",
"0.54021806",
"0.53601295",
"0.53... | 0.5795247 | 4 |
Configure flask_app with the settings from settings.py. | def yhTH(H6Ho):
H6Ho.config['RESTPLUS_SWAGGER_UI_DOC_EXPANSION'] = gCuF.RESTPLUS_SWAGGER_UI_DOC_EXPANSION
H6Ho.config['RESTPLUS_VALIDATE'] = gCuF.RESTPLUS_VALIDATE
H6Ho.config['SQLALCHEMY_DATABASE_URI'] = gCuF.SQLALCHEMY_DATABASE_URI
H6Ho.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = gCuF.SQLALCHEMY_TRACK_... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def HxEq(YKHO, P4t4: Flask) -> L2w0:\n P4t4.secret_key = GPtr.get_setting('SECRET_KEY')\n return P4t4",
"def gAVX(YKHO, H6Ho):\n H6Ho.config.update(YKHO.flask_config_dict)",
"def P4t4(YKHO):\n P1dF = lambda G1Hx: 'Fatal: You need to specify a \"flask\" section ' + 'with an entry like \"' + G1Hx + ... | [
"0.78092724",
"0.74835205",
"0.73006094",
"0.7236674",
"0.70968115",
"0.70810926",
"0.7050148",
"0.70427734",
"0.70294017",
"0.7010278",
"0.7008004",
"0.69754964",
"0.68153656",
"0.6801271",
"0.6795116",
"0.6771952",
"0.66904813",
"0.66592824",
"0.6637816",
"0.6604093",
"0.65... | 0.79909986 | 0 |