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 |
|---|---|---|---|---|---|---|
Find all points in a 2D image with ADU counts above a percentile threshold. | def DqJg(Z5Q9, **B2fa):
s_Vt = B2fa.get('perc', 99)
o7uO = oyIN.percentile(Z5Q9.flatten(), s_Vt)
y5bX = []
for rdlD in range(Z5Q9.shape[0]):
or8S = oyIN.where(Z5Q9[rdlD] >= o7uO)[0]
if len(or8S) != 0:
for fvDH in or8S:
y5bX.append([rdlD, fvDH])
y5bX = oyIN... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LEeu(Ti0O, o7bE, ekHH, cDK5):\n nPrm = [[Ti0O() for bGrB in range(ekHH)] for IaaG in range(cDK5)]\n cPRS = oyIN.array([VXlR(idxs=gGnb)[0] for gGnb in nPrm])\n return oyIN.percentile(cPRS, [XP5J * 100 for XP5J in o7bE])",
"def yArv(mJLf, CN9P, LSh8):\n import numpy as oyIN\n CN9P = oyIN.percent... | [
"0.6507445",
"0.6410663",
"0.63969666",
"0.6370799",
"0.6267533",
"0.6159115",
"0.61242104",
"0.5995779",
"0.5991462",
"0.5983083",
"0.5945081",
"0.5873221",
"0.58682704",
"0.586566",
"0.58475214",
"0.578314",
"0.57818705",
"0.57790273",
"0.5753828",
"0.57290125",
"0.57019156... | 0.5824189 | 15 |
Select a circle of discrete points centered around 'xc' and 'yc' within a given radius size, and within the square dimensions of the image size. | def Xr8z(**B2fa):
g0Hx, dlau = (B2fa.get('xc'), B2fa.get('yc'))
r1VO = B2fa.get('radius')
tpio = B2fa.get('dim', [oyIN.inf, oyIN.inf])
Opza = oyIN.arange(dlau - r1VO, dlau + r1VO + 1)
KQWz = oyIN.arange(g0Hx - r1VO, g0Hx + r1VO + 1)
GrEr = [list(M_DK) for M_DK in list(Hs6x.product(Opza, KQWz))]
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def e6fi(g0Hx, dlau, WKvO, LVAh):\n return oyIN.sqrt((WKvO - g0Hx) ** 2 + (LVAh - dlau) ** 2)",
"def FV9o(zNig, Mkmy):\n hgjH = zNig // 2\n Ew3d = oyIN.sqrt(2 * hgjH ** 2)\n WKvO, LVAh = oyIN.indices((zNig, zNig))\n qw7D = 1 - oyIN.abs(oyIN.hypot(WKvO - hgjH, LVAh - hgjH) / Mkmy)\n return qw7D.... | [
"0.80713475",
"0.7414954",
"0.7355315",
"0.73393446",
"0.7267131",
"0.7074237",
"0.70589244",
"0.703533",
"0.7025546",
"0.6964694",
"0.69534844",
"0.6939314",
"0.6916946",
"0.6912601",
"0.69090444",
"0.6886907",
"0.68421364",
"0.68242794",
"0.68018514",
"0.67838365",
"0.67805... | 0.79726183 | 1 |
Return number of unsolved vertices | def tM9g(YKHO):
return len(YKHO._reducedgraph.vertices) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JalI(YKHO):\n return len(list(YKHO.vertices()))",
"def PjD8(YKHO):\n return len(YKHO._vertices)",
"def PjD8(YKHO):\n return len(YKHO._vertices)",
"def MrQl(YKHO):\n return YKHO._n",
"def X7h0(YKHO):\n return len(YKHO.vertices)",
"def poMF(YKHO):\n return len(YKHO.vertices())",
"de... | [
"0.7124812",
"0.71159273",
"0.71159273",
"0.7070099",
"0.7059283",
"0.70441103",
"0.7010598",
"0.6988804",
"0.69356996",
"0.6930566",
"0.6902586",
"0.6859004",
"0.6820585",
"0.68173295",
"0.68138903",
"0.6804852",
"0.6802999",
"0.6789584",
"0.67679894",
"0.67621034",
"0.67492... | 0.5996913 | 83 |
Shorthand to retrieve arithmetic operations rooted in ``expr``. | def bht8(VN2L):
return TgwQ(VN2L, MAy8, 'all', 'dfs') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def x4Kj(YKHO, VN2L):\n try:\n return eval(VN2L)\n except:\n return None",
"def ymnj(YKHO, VN2L):\n rmc3 = {mWFP: getattr(YKHO, mWFP) for mWFP in YKHO.OPERATORS}\n YHK0 = BNqP(use_numpy=True, **rmc3)\n zHIw = LftB(symtable=YHK0)\n return zHIw.eval(VN2L)",
"def y9NY(VN2L):\n M... | [
"0.7907949",
"0.7574644",
"0.7474642",
"0.71633345",
"0.69207513",
"0.68742853",
"0.67416906",
"0.67401737",
"0.67401737",
"0.67282414",
"0.6714025",
"0.66959625",
"0.6685884",
"0.6644704",
"0.6641325",
"0.66224486",
"0.6617143",
"0.6599146",
"0.6546707",
"0.65143025",
"0.649... | 0.64273655 | 24 |
Returns the absolute path of a file | def SJOK(uRP3):
return pmON.join(pmON.dirname(xAKo), uRP3) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nUeQ(pmON):\n return Hy7s.path.abspath(pmON)",
"def ibch(YKHO, pmON):\n return Hy7s.path.join(YKHO.root_dir, pmON)",
"def BpbB(nUeQ):\n SOoY = Hy7s.path.abspath(Hy7s.path.expanduser(str(nUeQ)))\n return oAb3.Path(SOoY)",
"def _cEU(YKHO, nUeQ):\n return Hy7s.path.join(YKHO._path, nUeQ)",
... | [
"0.82685506",
"0.8158124",
"0.81216085",
"0.8096069",
"0.80884326",
"0.80837905",
"0.804579",
"0.79453385",
"0.79445684",
"0.78764427",
"0.78337073",
"0.78192586",
"0.7805268",
"0.77987355",
"0.77807677",
"0.7764872",
"0.7753881",
"0.7737618",
"0.7726394",
"0.7724446",
"0.772... | 0.0 | -1 |
Randomizes the answer choices | def v4S5(IqQl):
tuKI.shuffle(IqQl)
return IqQl | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rvr1(YKHO, input, FVvl, QIfy=1, vTdo=4):\n input = YKHO.formatter(input)\n mrPm = YKHO.sample_if(input, FVvl, 'True', QIfy) + YKHO.sample_if(input, FVvl, 'False', vTdo - QIfy)\n return YKHO.shuffle_and_stack_dicts_numerically(mrPm)",
"def FIMM(YKHO):\n for YRbF in Ni9Y(YKHO.questions_num):\n ... | [
"0.7562045",
"0.7430691",
"0.7391468",
"0.733912",
"0.733912",
"0.733912",
"0.733912",
"0.733912",
"0.721056",
"0.72081697",
"0.7142795",
"0.7099081",
"0.7067466",
"0.70380086",
"0.70060605",
"0.6974562",
"0.6885524",
"0.6866709",
"0.67647105",
"0.6760545",
"0.6727651",
"0.... | 0.70313424 | 14 |
return the teams of the users invoved in this project | def Hpcg(YKHO):
wjS6 = [CBIr.id for CBIr in YKHO.recruit_users.all()] + [CBIr.id for CBIr in YKHO.reviewer_users.all()]
return r2Kd.get_teams_from_user_ids(wjS6) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dZPi(YKHO):\n return [P6bq.username for P6bq in YKHO.get_team()]",
"def Kkyz(CBIr):\n umWR = r2Kd.objects.filter(T8ck(members=CBIr) | T8ck(leaders=CBIr)).distinct()\n return umWR.order_by('name')",
"def Hpcg(YKHO):\n bD7m = 'teams'\n Aofo = YKHO.get(bD7m)\n return Aofo['teams']",
"def G... | [
"0.7499433",
"0.73479396",
"0.73106587",
"0.7269572",
"0.7246466",
"0.7202419",
"0.7190738",
"0.70769936",
"0.70312184",
"0.699638",
"0.6974539",
"0.6941928",
"0.6867458",
"0.686431",
"0.6850163",
"0.6691076",
"0.6620189",
"0.6569786",
"0.65551203",
"0.65467906",
"0.6539195",... | 0.70376754 | 8 |
estimate final temperature, based on input current; the value of the heat convection coefficient is a parametric expression with respect to the springpitch & (el. current)^2 | def F5po(YKHO):
if not YKHO.s.pitchManual:
YKHO.s.pitch = YKHO.s.delta / YKHO.s.n
OGGA, = YKHO.s.hFunc(YKHO.s.pitch, YKHO.irms ** 2)[0]
Dcw8 = YKHO.s.tinf + YKHO.irms ** 2 * YKHO.s.rho / OGGA
YKHO.s.h = OGGA * 1000.0
YKHO.gui.LabelsTab.set(2, 1, '{0:05.1f}::{1:4.2f}'.format(Dcw8, OGGA * 1000... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def iYRB(ycBG):\n return (ycBG - 275.15) * 9 / 5 + 32",
"def CMHP(YKHO) -> float:\n return YKHO.component.temperature",
"def QdZT(YKHO):\n super().update()\n YKHO.temp = YKHO.final_temp + (YKHO.init_temp - YKHO.final_temp) * kLQb(-YKHO.cooling_rate * YKHO.time)",
"def ovGo(YKHO) -> float:\n ra... | [
"0.714786",
"0.6780246",
"0.6681874",
"0.6624265",
"0.6613499",
"0.6582763",
"0.6566233",
"0.6550441",
"0.6549334",
"0.654242",
"0.6518627",
"0.6496174",
"0.648162",
"0.64379644",
"0.64354235",
"0.6426562",
"0.63913614",
"0.6390088",
"0.63817894",
"0.6371001",
"0.6365029",
... | 0.0 | -1 |
Create a superuser and token for API calls. | def FCbF(YKHO):
YKHO.site1 = HAC5.objects.create(name='USWEST', slug='uswest')
YKHO.device_role1 = pxSZ.objects.create(name='Firewall', slug='firewall')
YKHO.platform1 = zR2c.objects.create(name='JunOS', slug='junos', napalm_driver='junos')
YKHO.onboarding_task4 = uT33.objects.create(ip_address='ntc123.... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Zp54():\n D3lj = 'test@test.test'\n jTXt = '123456'\n COmz = mv1M.objects.filter(email=D3lj).first()\n if not COmz:\n COmz = mv1M.objects.create_superuser(email=D3lj, password=jTXt, full_name='Test Superuser')\n pB3N = {'id': COmz.pk, 'exp': qcWV(year=2030, month=1, day=1)}\n e... | [
"0.7573019",
"0.74854577",
"0.704268",
"0.6914373",
"0.68110174",
"0.6762663",
"0.6716608",
"0.6666985",
"0.66449434",
"0.6634727",
"0.66304255",
"0.6628072",
"0.6625913",
"0.66038567",
"0.65782356",
"0.65693986",
"0.6568021",
"0.65676075",
"0.65667456",
"0.6537899",
"0.65291... | 0.0 | -1 |
Parse out command line args. | def hfK9(YKHO):
YKHO.parsed_args = YKHO.parser.parse_args(YKHO.args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Y8nX():\n wvEv = ugLM()\n return wvEv.parse_args()",
"def dCXb():\n return wvEv.parse_args()",
"def dCXb(YKHO):\n return YKHO.main_parser.parse_args()",
"def uvp4(YKHO, E0cB):\n from optparse import OptionParser\n e2h5 = 'usage: %prog [options]'\n wvEv = OptionParser(e2h5)\n xAU6,... | [
"0.7823169",
"0.7813537",
"0.7748836",
"0.7717876",
"0.76465213",
"0.7643367",
"0.76002365",
"0.758843",
"0.75499415",
"0.7528965",
"0.7501636",
"0.74855316",
"0.7462155",
"0.7439803",
"0.74388266",
"0.7430172",
"0.7388125",
"0.73867273",
"0.73799884",
"0.7379348",
"0.7378405... | 0.0 | -1 |
Generator that takes any number of iterables as arguments. It yields, one at a time, each of the elements of each iterable. It is similar to itertools.chain. | def l2ls(*qIxc):
for d7pR in qIxc:
for ZfUD in d7pR:
yield ZfUD | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eNCK(*ix7N):\n for OxJJ in ix7N:\n yield from OxJJ",
"def Xudm(ix7N):\n for OxJJ in ix7N:\n yield from OxJJ",
"def eNCK(*ix7N):\n for WhY1 in ix7N:\n with WhY1:\n for U6D_ in WhY1:\n yield U6D_",
"def DUma(*IrPK):\n for YRbF in IrPK:\n for... | [
"0.856621",
"0.84171486",
"0.81728154",
"0.78481144",
"0.782191",
"0.7754885",
"0.76757044",
"0.755863",
"0.75493824",
"0.73805666",
"0.7289659",
"0.7211774",
"0.71428114",
"0.70247287",
"0.7010341",
"0.6948293",
"0.6798271",
"0.67943025",
"0.6784589",
"0.67090726",
"0.669294... | 0.727894 | 11 |
Get user `user_id` answers to survey `survey_id` | def dRh_(YKHO, uJjO, YoOB):
_5c0 = 'survey_{}'.format(YoOB)
if not YKHO.__table_exists(_5c0):
raise RuntimeError('survey {} does not exist'.format(YoOB))
if uJjO is not None:
Pe9W = 'SELECT * FROM {} WHERE user_id=%s order by ts DESC'.format(_5c0)
return YKHO.__get(Pe9W, (uJjO,))
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def IBv_(QePW):\n if QePW.method == 'GET':\n uJjO = QePW.query_params.get('user_id', None)\n if uJjO is not None:\n h2IT = MPv1.objects.filter(user_id=uJjO)\n else:\n h2IT = MPv1.objects.all()\n ZMzz = Xvx6(h2IT, many=True)\n return oGir(ZMzz.data)",
"d... | [
"0.6996751",
"0.6430658",
"0.63948685",
"0.63712245",
"0.6233625",
"0.6217174",
"0.6122078",
"0.6093333",
"0.6013227",
"0.599051",
"0.5989075",
"0.59818894",
"0.59685016",
"0.59100395",
"0.5874847",
"0.5829927",
"0.58286816",
"0.5827037",
"0.5826878",
"0.5816379",
"0.57920486... | 0.63991606 | 2 |
Returns list of categories | def LH1I(YKHO) -> x1iM[qZuN]:
return YKHO.categories | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NMoC(YKHO):\n return LeZt",
"def LQuW(YKHO):\n LeZt = ''\n for YRbF in YKHO.category.all():\n LeZt += YRbF.name + ' '\n return LeZt",
"def zG33(YKHO):\n return YKHO.categoryList",
"def LQuW(YKHO):\n return YKHO.categories.all()",
"def LQuW(YKHO):\n return YKHO.categories.all... | [
"0.85274774",
"0.8499335",
"0.8471966",
"0.84682494",
"0.84682494",
"0.84677905",
"0.83814037",
"0.83510005",
"0.8310223",
"0.8309314",
"0.8271075",
"0.82636064",
"0.8261737",
"0.8250485",
"0.8186817",
"0.81834424",
"0.8133607",
"0.8127817",
"0.8119425",
"0.81165993",
"0.8084... | 0.80114657 | 24 |
Cleans the text of the tweet | def uwar(YKHO):
Mau6 = YKHO.text
Mau6 = Mau6.lower()
Mau6 = ZbWC.sub('((www.[^\\s]+)|(https?://[^\\s]+))', 'URL', Mau6)
Mau6 = ZbWC.sub('@[^\\s]+', 'AT_USER', Mau6)
Mau6 = ZbWC.sub('[\\s]+', ' ', Mau6)
Mau6 = ZbWC.sub('#([^\\s]+)', '\\1', Mau6)
return Mau6 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QrZ9(l5Ny):\n return biH0.PreprocessTweets(l5Ny).clean_text()",
"def rq7K(Mau6):\n Mau6.cleaning_log, Mau6.text_cleaned = QrZ9(Mau6.text_raw, tokenize=True)",
"def gq73(aWDa):\n aWDa = ZbWC.sub('@[^\\\\s]+', ' ', aWDa)\n aWDa = ZbWC.sub('http\\\\S+', ' ', aWDa)\n aWDa = ZbWC.sub('[\\\\W_]+\\... | [
"0.85745287",
"0.8466324",
"0.8286244",
"0.8239465",
"0.8147721",
"0.80712193",
"0.7974022",
"0.7945044",
"0.7867827",
"0.7860912",
"0.78576326",
"0.78480166",
"0.78021336",
"0.77505845",
"0.77384275",
"0.76710474",
"0.76222306",
"0.7601487",
"0.7499515",
"0.7402779",
"0.7365... | 0.71293527 | 45 |
Convert numeric row/col notation to an Excel cell reference string in A1 notation. | def HAp_(rdlD, fvDH, Scbb=False, eMfv=False):
Csk6 = fvDH // 26
r8hN = fvDH % 26
u9BC = ''
if Scbb:
Scbb = '$'
else:
Scbb = ''
if eMfv:
eMfv = '$'
else:
eMfv = ''
if Csk6 > 0:
u9BC = chr(ord('A') + Csk6 - 1)
yDfd = chr(ord('A') + r8hN)
retu... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xJvm(YKHO, rdlD: int, fvDH: int) -> str:\n V3xq = YKHO.row_col_to_ExcelCell(rdlD, fvDH)\n return YKHO.ExcelCell_to_A1(V3xq)",
"def Gp_C(YKHO, V3xq: ExcelCell) -> str:\n return f'{YKHO._su.int_to_excel_col(V3xq.col)}{V3xq.row}'",
"def fVQB(VmPb):\n xrrK = VmPb[-10:]\n return f'+1{xrrK}'",
"... | [
"0.698644",
"0.6928799",
"0.64700794",
"0.6148419",
"0.60457",
"0.596382",
"0.596051",
"0.5955598",
"0.58858925",
"0.5877187",
"0.57286304",
"0.5675273",
"0.56726557",
"0.5646076",
"0.5611692",
"0.5603779",
"0.558976",
"0.5572704",
"0.5569344",
"0.5563273",
"0.55311024",
"0... | 0.6479484 | 2 |
T.__new__(S, ...) > a new object with type S, a subtype of T | def fwuD(o4sw, *SPTI):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw):\n pass",
"def fwuD(YKHO, o4sw... | [
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497",
"0.74194497"... | 0.72122014 | 69 |
Creates an instance of this model from a dictionary | def rQfz(Emd4, cmPJ):
if cmPJ is None:
return None
Q3Vo = cmPJ.get('honorTierInfo')
szQf = cmPJ.get('numSecsToMoveAfter')
q2Vp = qRGs.models.cluster_config_proto_vault_cloud_tier_type.ClusterConfigProto_Vault_CloudTierType.from_dictionary(cmPJ.get('targetTierType')) if cmPJ.get('targetTierType')... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rQfz(Emd4, cmPJ):\n if cmPJ == None:\n return None\n else:\n mWFP = cmPJ.get('name')\n l8cJ = cmPJ.get('generic_id')\n Gsi3 = cmPJ.get('therauptic_uses')\n PALZ = cmPJ.get('search_score')\n return Emd4(mWFP, l8cJ, Gsi3, PALZ)",
"def rQfz(Emd4, cmPJ):\n if cm... | [
"0.83722425",
"0.8335738",
"0.8215464",
"0.8167521",
"0.8167521",
"0.81483614",
"0.8051766",
"0.80300796",
"0.8013641",
"0.79792094",
"0.79221934",
"0.7919166",
"0.79183745",
"0.79125935",
"0.7906434",
"0.79004663",
"0.78967476",
"0.7886129",
"0.78760797",
"0.78543913",
"0.78... | 0.0 | -1 |
Return the unit of measurement of this entity, if any. | def b82i(YKHO):
if YKHO.tahoma_device.uiclass == 'TemperatureSensor':
return hMVl
if YKHO.tahoma_device.uiclass == 'HumiditySensor':
return Pquj
if YKHO.tahoma_device.uiclass == 'LightSensor':
return 'lx'
return None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def b82i(YKHO):\n if YKHO._unit_of_measurement == None:\n return\n return YKHO._unit_of_measurement",
"def b82i(YKHO):\n return YKHO._unit",
"def b82i(YKHO):\n return YKHO._unit",
"def b82i(YKHO):\n return YKHO._unit",
"def b82i(YKHO):\n return YKHO._unit",
"def b82i(YKHO):\n ... | [
"0.8501415",
"0.848033",
"0.848033",
"0.848033",
"0.848033",
"0.848033",
"0.848033",
"0.848033",
"0.848033",
"0.848033",
"0.848033",
"0.84656703",
"0.8455879",
"0.8455879",
"0.8455879",
"0.8455879",
"0.8455879",
"0.8455879",
"0.8455879",
"0.8455879",
"0.8455879",
"0.8455879... | 0.77087003 | 89 |
Who can get at questions? | def qucA(YKHO):
DrTj = OZpC(YKHO.layer['portal'], 'portal_membership')
DrTj.getMemberById(NnY3).setMemberProperties(dict(accept=True))
Kh6j.commit()
B7yu = YKHO.getJson('http://nohost/plone/dept1/tut1/lec1/@@quizdb-sync', user=qmUQ)
i9wF = YKHO.getJson('http://nohost/plone/dept1/tut1/lec2/@@quizdb-s... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def bAls():\n return 'Sure.'",
"def tJx2(YKHO):\n print(bAls)",
"def Ab75(YKHO):\n return []",
"def it6l(YKHO):\n pass",
"def _v0z(YKHO):\n pass",
"def pMxF(YKHO):\n pass",
"def IBr6(YKHO, YRbF):\n pass",
"def tJx2(YKHO):\n print(bAls)",
"def o5Iu(YKHO):\n pass",
"def k... | [
"0.7480146",
"0.7103076",
"0.71011496",
"0.708584",
"0.7084729",
"0.7034257",
"0.69733536",
"0.6964211",
"0.6906493",
"0.6729444",
"0.6725396",
"0.6725396",
"0.6725396",
"0.6714854",
"0.6688995",
"0.66659236",
"0.66608936",
"0.66364586",
"0.6550728",
"0.65355146",
"0.64564574... | 0.0 | -1 |
Returns the rrule objects for this Job. | def iIuw(YKHO):
Gjtu = eval('rrule.%s' % YKHO.frequency)
return k7fX.rrule(Gjtu, dtstart=YKHO.last_run, **YKHO.get_params()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BX8i(YKHO) -> x1iM[c4EF]:\n return YKHO.__rules",
"def Ddaj(YKHO):\n return list(YKHO._rules)",
"def G1N2(YKHO) -> list:\n if not YKHO._rules:\n YKHO._rules = []\n return YKHO._rules",
"def Ddaj(YKHO):\n return YKHO._rules",
"def BX8i(YKHO):\n return YKHO.rules",
"def c_NS(YK... | [
"0.68155414",
"0.6716818",
"0.6707795",
"0.6583848",
"0.65736",
"0.6549813",
"0.64459956",
"0.641235",
"0.641235",
"0.641235",
"0.6361303",
"0.6351012",
"0.63277483",
"0.63082296",
"0.62777513",
"0.6270434",
"0.62703985",
"0.6188777",
"0.61740816",
"0.61586577",
"0.61541915",... | 0.5994433 | 32 |
Must return login HTML content returned by provider. | async def auth_html(YKHO):
raise NotImplementedError('Implement in subclass') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QyXo():\n return TvZl('login.html')",
"def MC83():\n return TvZl('strava/login.html')",
"def WrfV():\n return TvZl('login.html')",
"def RMV5():\n return TvZl('login.html')",
"def RMV5():\n return TvZl('login.html')",
"def RMV5():\n return TvZl('login.html')",
"def RMV5():\n ret... | [
"0.73292094",
"0.72740954",
"0.7263825",
"0.7248182",
"0.7248182",
"0.7248182",
"0.72162586",
"0.720562",
"0.71593803",
"0.71593803",
"0.7096379",
"0.7096379",
"0.7066379",
"0.70296395",
"0.70294774",
"0.7024717",
"0.7002957",
"0.6995185",
"0.69747686",
"0.69036895",
"0.68711... | 0.70715684 | 12 |
Return user with given ID from the User model used by this backend. This is called by django.contrib.auth.middleware. | def TKWP(YKHO, uJjO):
return YKHO.strategy.get_user(uJjO) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TKWP(Emd4, id):\n C3ST = Nc2H.query.filter_by(id=id).first()\n return Emd4.create_user_from_model(C3ST)",
"def TKWP(YKHO, uJjO):\n try:\n vCWU = egNl()\n return vCWU.objects.get(pk=uJjO)\n except vCWU.DoesNotExist:\n return None",
"def TKWP(YKHO, uJjO):\n try:\n r... | [
"0.8255026",
"0.8249634",
"0.82174015",
"0.81556416",
"0.81541055",
"0.81541055",
"0.81541055",
"0.81230813",
"0.81219834",
"0.80830693",
"0.8078815",
"0.8078815",
"0.8078815",
"0.8066439",
"0.80351317",
"0.8031775",
"0.8012183",
"0.79830825",
"0.7974381",
"0.79741144",
"0.79... | 0.7924058 | 25 |
Returns a client for a specific service. | def x0hE(zVa7, GPtr):
return iVGz.client(zVa7, aws_access_key_id=GPtr.aws_access_key_id, aws_secret_access_key=GPtr.aws_secret_access_key, region_name=GPtr.region) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def x0hE(YKHO, bSEa):\n return YKHO.default_session.client(bSEa)",
"def bxbw(zVa7: str):\n import boto3\n if Mi51 is None:\n anRG = {'aws_access_key_id': Hy7s.environ['AWS_ACCESS'], 'aws_secret_access_key': Hy7s.environ['AWS_SECRET']}\n else:\n anRG = Mi51\n x0hE = boto3.client(zVa7,... | [
"0.822846",
"0.7678202",
"0.7532741",
"0.7383238",
"0.735936",
"0.7329818",
"0.7256459",
"0.7101087",
"0.7040084",
"0.70288086",
"0.6954673",
"0.68672293",
"0.6849408",
"0.68255347",
"0.68137586",
"0.67921656",
"0.6760475",
"0.67478585",
"0.6727661",
"0.67245054",
"0.67244744... | 0.67126495 | 22 |
Returns a resource for a specific service. | def Eorv(zVa7, GPtr):
return iVGz.resource(zVa7, aws_access_key_id=GPtr.aws_access_key_id, aws_secret_access_key=GPtr.aws_secret_access_key, region_name=GPtr.region) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Eorv(YKHO, bSEa):\n return YKHO.default_session.resource(bSEa)",
"def Eorv(bSEa, *qIxc, **B2fa):\n return iVGz.resource(bSEa, *qIxc, endpoint_url=wIch(), **B2fa)",
"def NMoC(YKHO, BXZP):\n return YKHO._get(goXa % P8oC.getid(BXZP), xCfF)",
"def HeD1(YKHO, zVa7, y7GR=''):\n try:\n if not... | [
"0.8201662",
"0.75165224",
"0.7301992",
"0.7222592",
"0.7211684",
"0.71832246",
"0.714695",
"0.71436083",
"0.7134236",
"0.702267",
"0.7016112",
"0.69847894",
"0.6888938",
"0.6881219",
"0.6880577",
"0.68173105",
"0.67787725",
"0.67633694",
"0.67379516",
"0.6717986",
"0.6703538... | 0.7169386 | 6 |
set or create a new annotation collection | def pG_h(YKHO, mWFP):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XgyP(YKHO, XgyP):\n YKHO._annotations = XgyP",
"def oYda(YKHO, QePW, _sei=None):\n xUwc = YKHO.get_object()\n ZMzz = gTmN(data=QePW.data)\n ZMzz.is_valid(raise_exception=True)\n xUwc.annotation_fields.set(ZMzz.validated_data['annotation_fields'])\n return oGir(status=jGRS.HTTP_204_NO_CONTEN... | [
"0.6690157",
"0.6418308",
"0.64051986",
"0.6303786",
"0.62507665",
"0.6203157",
"0.6183691",
"0.618003",
"0.61441416",
"0.61213815",
"0.6112993",
"0.6107787",
"0.6073852",
"0.60378605",
"0.603427",
"0.5967954",
"0.59674376",
"0.59589744",
"0.58784807",
"0.58316064",
"0.582936... | 0.5383391 | 60 |
Return the labels as a pandas.DataFrame | def JvyS(YKHO, vc9U):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Crrw(YKHO):\n return YKHO.df_dat.label.to_numpy()",
"def Crrw(YKHO):\n return YKHO.df_dat.label.to_numpy()",
"def Crrw(YKHO):\n if YKHO.label_name is None:\n raise ValueError('label_name is None')\n return YKHO.df[YKHO.label_name]",
"def Te1x():\n jQ3Z = kuIA(drop_na=True)\n jQ3Z... | [
"0.73505956",
"0.73505956",
"0.7094925",
"0.70711386",
"0.6996946",
"0.6757112",
"0.6751309",
"0.67043954",
"0.67043954",
"0.669763",
"0.6680775",
"0.66133136",
"0.65517944",
"0.6538526",
"0.65334696",
"0.65012306",
"0.65012306",
"0.6496553",
"0.6493053",
"0.6482615",
"0.6430... | 0.0 | -1 |
Remove nongenerating symbols from the grammar. Nongenerating symbols are symbols, that don't generate sequence of terminals. For example never ending recursion. | def Ii2N(mIy_, LpaZ=False):
if LpaZ is False:
mIy_ = jth9(mIy_)
E5aB = mIy_.terminals.copy()
E5aB.add(BVxk)
c_NS = mIy_.rules.copy()
while True:
q8Qv = E5aB.copy()
for eD8c in c_NS.copy():
gOCE = eD8c.right
RV7P = True
for o61b in gOCE:
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SvYP(mIy_):\n NF4V = mIy_.productions()\n fIwj = [XP5J for XP5J in NF4V + xyQR(NF4V, NF4V) if XP5J.rhs()]\n return H2st(mIy_.start(), fIwj, mIy_.lexicon())",
"def LFW_(I381):\n j6Zh = uGLX(I381)\n NdUJ = [H5ew for H5ew, aDi_ in j6Zh.items() if Hptn.to_number(aDi_)]\n return RCEU(I381, NdUJ,... | [
"0.60890603",
"0.5997644",
"0.58983094",
"0.5895018",
"0.58694327",
"0.583196",
"0.5829339",
"0.57588077",
"0.5749042",
"0.56511104",
"0.5633902",
"0.5618583",
"0.5611786",
"0.55546206",
"0.5533014",
"0.5501082",
"0.54751694",
"0.54751694",
"0.54595846",
"0.5376678",
"0.53577... | 0.7238236 | 0 |
Initialize the class by seting up the client object. | def FIMM(YKHO, HiOC, rbzu=None, glmo=False, Ltc3=None):
dZTr = rbzu or YKHO.output_types
super(OZyL, YKHO).__init__(HiOC, dZTr, glmo, Ltc3) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, x0hE):\n YKHO.client = x0hE\n YKHO.initialize()",
"def Pntg(YKHO):\n YKHO.client = i9zE()",
"def FIMM(YKHO, x0hE) -> None:\n YKHO._client = x0hE",
"def FIMM(YKHO, x0hE) -> None:\n YKHO._client = x0hE",
"def FIMM(YKHO, x0hE):\n YKHO._client = x0hE",
"def FIMM(YKHO, x0hE):\... | [
"0.87315243",
"0.87246275",
"0.82593447",
"0.82593447",
"0.8256128",
"0.8256128",
"0.8256128",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80132294",
"0.79548633",
"0.7840935",
... | 0.0 | -1 |
Initialize the class by seting up the client object. | def FIMM(YKHO, HiOC, rbzu=None, glmo=False, Ltc3=None):
rbzu = rbzu or ['entrezgene']
super(e2Ez, YKHO).__init__(HiOC, rbzu, glmo, Ltc3) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, x0hE):\n YKHO.client = x0hE\n YKHO.initialize()",
"def Pntg(YKHO):\n YKHO.client = i9zE()",
"def FIMM(YKHO, x0hE) -> None:\n YKHO._client = x0hE",
"def FIMM(YKHO, x0hE) -> None:\n YKHO._client = x0hE",
"def FIMM(YKHO, x0hE):\n YKHO._client = x0hE",
"def FIMM(YKHO, x0hE):\... | [
"0.87315243",
"0.87246275",
"0.82593447",
"0.82593447",
"0.8256128",
"0.8256128",
"0.8256128",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80738443",
"0.80132294",
"0.79548633",
"0.7840935",
... | 0.0 | -1 |
adds number to the list of random numbers and removes oldest entry if list goes above 100 numbers | def PAwi(YKHO):
return | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def yMZb(mLGw, yokr):\n tuKI.seed(yokr)\n Z4a9 = []\n while len(Z4a9) != mLGw:\n JpKC = tuKI.randint(0, 99)\n if JpKC not in Z4a9:\n Z4a9.append(JpKC)\n return Z4a9",
"def t4rA():\n S06t = tuKI.sample(range(1, 10000), 500)\n return S06t",
"def YAfL():\n xO_2 = []\n... | [
"0.67964154",
"0.66963017",
"0.65984744",
"0.6504147",
"0.64679587",
"0.64013225",
"0.638055",
"0.6362986",
"0.62392557",
"0.61591184",
"0.6151852",
"0.6135479",
"0.6134915",
"0.60820174",
"0.608003",
"0.6065184",
"0.60622954",
"0.60493803",
"0.6047406",
"0.60338163",
"0.6024... | 0.0 | -1 |
Set up a Request object. | def FIMM(YKHO, KcEq, NKcE, pmON, qIxc=None, JbpM=None, MOPg=None, nPrm=None, uFHL='application/json'):
nMI4(qIxc)
YKHO.host_url = KcEq
YKHO.path = pmON
YKHO.path_pattern = pmON
YKHO.method = NKcE.lower()
YKHO.parameters = {'path': JbpM or {}, 'query': i_G_(qIxc or []), 'header': MOPg or {}, 'coo... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def C9HC(YKHO, QePW):\n pass",
"def E2Sy(YKHO, QePW, *qIxc, **B2fa):\n nNdW = YKHO.get_parser_context(QePW)\n return VNUm(QePW, parsers=YKHO.get_parsers(), authenticators=YKHO.get_authenticators(), negotiator=YKHO.get_content_negotiator(), parser_context=nNdW)",
"def E2Sy(YKHO, QePW, *qIxc, **B2fa):\n... | [
"0.82143027",
"0.768366",
"0.7664356",
"0.7457003",
"0.7198938",
"0.7161315",
"0.70195794",
"0.6938362",
"0.69191504",
"0.69191504",
"0.6889543",
"0.6866013",
"0.68236965",
"0.6812013",
"0.6801641",
"0.67550343",
"0.67307127",
"0.67186016",
"0.6714027",
"0.6703155",
"0.669918... | 0.0 | -1 |
Think about the triangle as a graph similar to a tree, with nodes as the numbers in the triangle, and edges connecting to "adjacent" numbers. From top down, we may treat their relationship as parents and children, where some nodes can have two parents, such as 5 in the given example (it has 3 and 4 as parents). Startin... | def fBpV(YKHO, tXIo):
if tXIo is None or len(tXIo) == 0:
return
if len(tXIo) == 1:
return tXIo[0][0]
for ABDL in Ni9Y(1, len(tXIo)):
WMDh = tXIo[ABDL]
fVcq = tXIo[ABDL - 1]
for d6pt in Ni9Y(len(WMDh)):
if d6pt == 0:
WMDh[d6pt] += fVcq[0]
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Qg10(tXIo):\n if len(tXIo) > 0:\n if len(tXIo[0]) > 0:\n TifC = [[0] * len(tXIo) for bGrB in range(2)]\n TifC[0][0] = tXIo[0][0]\n for YRbF in range(1, len(tXIo)):\n for r845 in range(len(tXIo[YRbF])):\n ZbOB = YRbF % 2\n ... | [
"0.7453428",
"0.71541905",
"0.71425384",
"0.7000231",
"0.6620342",
"0.6567512",
"0.6407052",
"0.63375956",
"0.6302782",
"0.6256032",
"0.6233501",
"0.62256736",
"0.62066084",
"0.6130995",
"0.6112844",
"0.61111957",
"0.5957145",
"0.5927272",
"0.5917805",
"0.5878188",
"0.5860109... | 0.8185047 | 0 |
Add a new node to the dot graph. | def SOk_(YKHO, oWrg, UXqs, _Cnz, bD7m=None, VXjJ=None):
o8Kj = dict()
o8Kj.update(_Cnz)
o8Kj.update({'label': UXqs})
if bD7m is not None:
o8Kj.update({'href': bD7m})
if VXjJ is not None:
o8Kj.update({'image': VXjJ})
YKHO.graph.add_node(B3pH.graphviz.Node(name=oWrg, **o8Kj)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def g5gD(YKHO, Q6kx):\n YKHO.graph[Q6kx]",
"def g5gD(YKHO, Q6kx):\n YKHO.nodes.append(Q6kx)",
"def g5gD(YKHO, Q6kx):\n YKHO.nodes.append(Q6kx)",
"def g5gD(YKHO, Q6kx):\n YKHO.nodes.append(Q6kx)",
"def g5gD(YKHO, Q6kx):\n YKHO._check_nodes([Q6kx])\n jHsn.DiGraph.add_node.im_func(YKHO, Q6kx... | [
"0.81269985",
"0.7907693",
"0.7854639",
"0.7854639",
"0.7838394",
"0.7838346",
"0.7653037",
"0.76092434",
"0.7604541",
"0.7590224",
"0.75617796",
"0.75617796",
"0.7554168",
"0.7511021",
"0.7505355",
"0.7482723",
"0.74404234",
"0.7425906",
"0.74159354",
"0.7407552",
"0.7397939... | 0.72263986 | 36 |
Write the resulting graph as .dot file. | def wDV_(YKHO, WmKM):
zZcM = F9aX.Source(YKHO.graph.to_string())
zZcM.engine = 'dot'
zZcM.save(WmKM) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ehAV(gIsw, pNZh):\n with open(gIsw, 'w') as ytgA:\n pNZh.write_dot(ytgA)",
"def grem(YKHO, *, pmON: typing.Optional[typing.Union[str, pathlib.Path]]='graph.dot') -> None:\n BJ1H = F9aX.Digraph()\n for dhx_ in YKHO.lemma_graph.nodes():\n fdMZ = YKHO.ranks[dhx_]\n H5ew = dhx_.labe... | [
"0.8515151",
"0.8199279",
"0.8108621",
"0.8085823",
"0.789464",
"0.7818253",
"0.7784934",
"0.7740896",
"0.76864517",
"0.7653682",
"0.761866",
"0.7605101",
"0.75976443",
"0.7581502",
"0.7572607",
"0.75714535",
"0.75584215",
"0.72829944",
"0.72662574",
"0.7215733",
"0.7166016",... | 0.79281837 | 4 |
Write the resulting graph as .svg file. | def Wgf6(YKHO, vxC3):
pNZh = jth9.deepcopy(YKHO.graph)
for Q6kx in pNZh.get_nodes():
if 'image' in Q6kx.get_attributes():
Q6kx.set('tooltip', Q6kx.get('label'))
Q6kx.set('label', '')
zZcM = F9aX.Source(pNZh.to_string())
zZcM.engine = 'dot'
COpB = zZcM.pipe(format='svg... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def opie(YKHO, Ux0P):\n with open(Ux0P, 'wb') as nUeQ:\n nUeQ.write(YKHO.chart)",
"def zv6Z(YKHO, Ux0P):\n eHNT = open(Ux0P, 'wb')\n eHNT.write(YKHO.export_svg())\n eHNT.close()\n PCzT.write('saving SVG to file: %s\\n' % Ux0P)",
"def xkzz(YKHO, gIsw=None):\n swxq = YKHO._force_directed... | [
"0.838051",
"0.8253133",
"0.8011541",
"0.800183",
"0.7982664",
"0.79361165",
"0.7766392",
"0.75781333",
"0.7497296",
"0.74812865",
"0.7454878",
"0.74280244",
"0.7317253",
"0.7287489",
"0.71906185",
"0.71897244",
"0.7154609",
"0.71173483",
"0.70970124",
"0.7093153",
"0.7085632... | 0.78793454 | 6 |
Returns the string representation of the model | def gTzM(YKHO):
import simplejson as qQXR
if jKi7.PY2:
import sys
U3hF(sys)
sys.setdefaultencoding('utf-8')
return qQXR.dumps(yInN(YKHO), ensure_ascii=False) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__model)",
"def zAg0(YKHO):\n return str(YKHO.model)",
"def zAg0(YKHO):\n return YKHO.text",
"def zAg0(YKHO):\n oOUF = '-----------------------------------------------------------------------------------\\n'\n _2sc = YKHO.__class__.__name__\n oOUF += '\\t\\... | [
"0.86418265",
"0.85103965",
"0.7853324",
"0.77442306",
"0.7712258",
"0.76979405",
"0.765959",
"0.7637644",
"0.76218504",
"0.7607561",
"0.7606604",
"0.7606604",
"0.7606604",
"0.75990754",
"0.7585653",
"0.758149",
"0.7570811",
"0.7567585",
"0.75392604",
"0.75392604",
"0.7527967... | 0.0 | -1 |
Returns true if both objects are not equal | def Vdqg(YKHO, Elif):
return not YKHO == Elif | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO.__eq__(Elif)",
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif: object):\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif):\n if YKHO.__eq__(Elif):\n return False\n return True",
"def Vdqg(... | [
"0.8392633",
"0.8354901",
"0.82950056",
"0.8132309",
"0.81149805",
"0.8099986",
"0.809911",
"0.8097883",
"0.8097883",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8066694",
"0.80594814",
"0.805757",
... | 0.0 | -1 |
transforms RGB mask image to binary hair mask image. | def jv2q(ZHfW):
Q4ru = oyIN.array(ZHfW)
psKE = Q4ru == oyIN.array([255, 0, 0])
psKE = oyIN.all(psKE, axis=2).astype(oyIN.float32)
return hnIv.fromarray(psKE) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XNrW(YKHO, ZHfW):\n YKHO.binary_gray = oyIN.asarray(YKHO.orig_gray, dtype=oyIN.float32)\n YKHO.binary_gray[YKHO.sky_bool] = 1\n YKHO.binary_gray[YKHO.cloud_bool] = 100\n YKHO.binary_gray[ZHfW] = 0\n YKHO.binary_color = YKHO.orig_color.copy()\n YKHO.binary_color[YKHO.sky_bool, :] = [255, 0, 0]... | [
"0.67337364",
"0.64923424",
"0.6445381",
"0.6414788",
"0.6374384",
"0.6362745",
"0.63009495",
"0.62128943",
"0.62095314",
"0.61374617",
"0.61209494",
"0.60866195",
"0.6052376",
"0.6000682",
"0.598596",
"0.59666646",
"0.5949688",
"0.5947867",
"0.5945871",
"0.59387684",
"0.5911... | 0.7161065 | 0 |
Create an attribute named attr_name that calls _logical_op(self, other, op). | def kH5Y(hGI9, khtY):
def DMIq(YKHO, Elif):
return X9bI._logical_op(YKHO, Elif, khtY)
DMIq.__name__ = hGI9
hkS8[hGI9] = DMIq | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def PBau(YKHO, Elif, khtY):\n if hasattr(Elif, '__iter__'):\n Aofo = XTiz.empty(min(len(YKHO), len(Elif)), dtype=bool)\n for YRbF, (KCHu, z1Rg) in enumerate(zip(YKHO, Elif)):\n Aofo[YRbF] = khtY(KCHu, z1Rg)\n return Aofo\n else:\n Aofo = XTiz.empty(len(YKHO), dtype=bool... | [
"0.6910056",
"0.66813153",
"0.63842595",
"0.62914354",
"0.611776",
"0.61117244",
"0.6101816",
"0.6098517",
"0.6051088",
"0.60316026",
"0.60075414",
"0.60054475",
"0.60014194",
"0.5991762",
"0.5957238",
"0.5882295",
"0.58724886",
"0.58686954",
"0.58577985",
"0.5843703",
"0.584... | 0.83620244 | 0 |
Migration of a JSONrepresented city. | def T1ev(bTKY):
Zp9d = {'wikiname': bTKY['fields']['wikiname'], 'slug': bTKY['fields']['slug'], 'name': bTKY['fields']['name'], 'rankings': [float(bTKY['fields']['rating_factor_%d' % or8S]) for or8S in Ni9Y(1, 4)], 'timezone': u'UTC%s%d' % (u'' if bTKY['fields']['timezone'] < 0 else u'+', bTKY['fields']['timezone']... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def prIb(accd):\n j5sA = S8SU.get('City', accd)\n if j5sA is None:\n eTsH(404)\n return pz3A(j5sA.to_dict())",
"def j5sA(accd):\n j5sA = S8SU.get('City', accd)\n if j5sA is None:\n eTsH(404)\n if QePW.method == 'GET':\n return pz3A(j5sA.to_dict())\n elif QePW.method == '... | [
"0.65865296",
"0.6540663",
"0.65292996",
"0.64667237",
"0.64195657",
"0.63632226",
"0.63203305",
"0.6308277",
"0.62853163",
"0.62806207",
"0.62771493",
"0.62660235",
"0.62530977",
"0.6240371",
"0.6169917",
"0.6159611",
"0.6152592",
"0.61448824",
"0.6142061",
"0.61405843",
"0.... | 0.58795226 | 34 |
Reshapes 2D arrays to 1D | def WbcY(WKvO):
jzdc = WKvO.shape[0]
Fg_i = WKvO.shape[1]
return (WKvO.reshape(jzdc * Fg_i, 1), jzdc, Fg_i) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def b7l5(ezWE):\n if ezWE.ndim != 2:\n ezWE.shape = tTYv(ezWE)\n return ezWE",
"def q3V_(ezWE):\n ezWE = oyIN.moveaxis(ezWE, 0, -1)\n ezWE = oyIN.squeeze(ezWE)\n return ezWE",
"def xjRc(r5g_):\n return q3V_(r5g_, (jHsn, pvd3))",
"def q3V_(nPrm):\n return nPrm.reshape(1, nPrm.shape... | [
"0.7297934",
"0.72747743",
"0.7175094",
"0.71735984",
"0.7012653",
"0.70041114",
"0.69113517",
"0.6862302",
"0.68600816",
"0.6826297",
"0.68243545",
"0.68128544",
"0.68058294",
"0.6798696",
"0.67583424",
"0.6754706",
"0.66892064",
"0.6655359",
"0.66509384",
"0.665037",
"0.663... | 0.6696506 | 16 |
Truncates a word after a given number of chars | def WEKM(KCHu, mLGw):
u54L = int(mLGw)
vIwR = []
for GIN8 in KCHu.split():
if len(GIN8) > u54L:
vIwR.append(GIN8[:u54L] + '...')
else:
vIwR.append(GIN8)
return u' '.join(vIwR) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def PAqT(KCHu: str, u54L: int) -> str:\n V22M = KCHu.split(' ')\n if len(V22M) <= u54L:\n return KCHu\n else:\n return f'{' '.join(V22M[:u54L])} …'",
"def R9aW(KCHu, mLGw):\n KCHu = ILZP(KCHu)\n u54L = int(mLGw)\n if len(KCHu) > u54L:\n u54L = u54L - 3\n if KCHu[u54L... | [
"0.7799271",
"0.7638988",
"0.76089054",
"0.7605355",
"0.75705373",
"0.75471884",
"0.7543364",
"0.7542484",
"0.7529968",
"0.7525576",
"0.75157845",
"0.74797964",
"0.74284416",
"0.74209726",
"0.740251",
"0.7397046",
"0.7311091",
"0.7310373",
"0.72912735",
"0.7290686",
"0.721713... | 0.72859013 | 20 |
Returns a 3x3 rotation matrix suitable for rotating sets of x,y,z coordinates. Uses a righthanded coordinate system where roll is about the x axis, pitch about the y and yaw about the z, so a positive rotation will be clockwise when looking in the direction of the axis. Rotation uses an xyz convention, applying roll, t... | def SppC(YKHO):
J37F, avIK = (epAf.sin(YKHO.roll.val), epAf.cos(YKHO.roll.val))
dwyc, ve1H = (epAf.sin(YKHO.pitch.val), epAf.cos(YKHO.pitch.val))
ma1g, mJt5 = (epAf.sin(YKHO.yaw.val), epAf.cos(YKHO.yaw.val))
return aLMY(((mJt5, -ma1g, 0), (ma1g, mJt5, 0), (0, 0, 1))) * aLMY(((ve1H, 0, dwyc), (0, 1, 0), ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tMaO(xTkQ: torch.Tensor, H2HG: torch.Tensor, rKSe: torch.Tensor, hgjH: torch.Tensor) -> ht2j.Tensor:\n if len(xTkQ.shape) == len(H2HG.shape) == len(rKSe.shape) == 0:\n xTkQ = xTkQ.unsqueeze(dim=0)\n H2HG = H2HG.unsqueeze(dim=0)\n rKSe = rKSe.unsqueeze(dim=0)\n if len(xTkQ.shape) == l... | [
"0.75126195",
"0.7397268",
"0.72384477",
"0.7124221",
"0.7036933",
"0.70179176",
"0.6922201",
"0.68290216",
"0.6803191",
"0.67913973",
"0.67841136",
"0.67841136",
"0.6780201",
"0.676988",
"0.67598635",
"0.6743293",
"0.67404664",
"0.67110765",
"0.66985434",
"0.66928",
"0.66888... | 0.6523347 | 31 |
Can construct from singly or doubly nested iterable. Each inner item | def FIMM(YKHO, nPrm):
YKHO.data = tuple([tuple(WKvO) if kUz6(WKvO) else (WKvO,) for WKvO in nPrm])
YKHO.rows = len(YKHO.data)
YKHO.cols = len(YKHO.data[0]) if len(YKHO.data) > 0 else 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, OxJJ=[]):\n YKHO.root = None\n if not isinstance(OxJJ, (list, dict, tuple)):\n 'Checks if the iterable is a true iterable and inserts each value as a new node.'\n raise TypeError('Iterable must be a list, dict, or tuple')\n for YRbF in OxJJ:\n YKHO.insert(YRbF)",
"def... | [
"0.64559114",
"0.6356989",
"0.62601334",
"0.6235601",
"0.62310666",
"0.6208975",
"0.6202275",
"0.619953",
"0.6152655",
"0.6139083",
"0.61217713",
"0.61073565",
"0.6097349",
"0.60889137",
"0.6044414",
"0.60252845",
"0.60252506",
"0.6009514",
"0.598832",
"0.59845465",
"0.598426... | 0.0 | -1 |
Can subtract another matrix of the same size or any similar nested iterable. The result is a matrix. | def qjfR(YKHO, nGHW):
if not isinstance(nGHW, aLMY):
nGHW = aLMY(nGHW)
return YKHO._sub(nGHW) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vAfp(gpRq, E43s):\n if not gpRq:\n vb7U = []\n return vb7U\n if len(gpRq) != len(E43s) or len(gpRq[0]) != len(E43s[0]):\n return 'Only matrices of the same size can be subtracted'\n else:\n vb7U = SppC(len(gpRq), len(gpRq[0]), 0)\n for YRbF in range(len(gpRq)):\n ... | [
"0.7864925",
"0.78040904",
"0.771898",
"0.7613707",
"0.75769705",
"0.7567923",
"0.754651",
"0.7532396",
"0.7442211",
"0.73992246",
"0.73942924",
"0.7391995",
"0.73790306",
"0.7320948",
"0.7309386",
"0.7233749",
"0.7207701",
"0.71295005",
"0.70827967",
"0.70772433",
"0.7075938... | 0.73291713 | 13 |
Returns the intersection point of this line and the given Line2d as a Vector2d if the segments intersect, or None otherwise. Will return None if the lines are coincident. | def iQin(YKHO, zFiD):
ciZM = (zFiD.b[1] - zFiD.a[1]) * (YKHO.b[0] - YKHO.a[0]) - (zFiD.b[0] - zFiD.a[0]) * (YKHO.b[1] - YKHO.a[1])
if ciZM == 0:
return None
dwhH = (zFiD.b[0] - zFiD.a[0]) * (YKHO.a[1] - zFiD.a[1]) - (zFiD.b[1] - zFiD.a[1]) * (YKHO.a[0] - zFiD.a[0])
RpQt = (YKHO.b[0] - YKHO.a[0])... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Hs1B(YKHO, zFiD: Tuple[np.array, np.array]) -> h8nf[AzJI[float, oyIN.array, oyIN.array, float]]:\n jtyf, V70B = zFiD\n hQHm = YKHO.ro - jtyf\n jlSq = V70B - jtyf\n bUZ8 = oyIN.array([-YKHO.rd[1], YKHO.rd[0]])\n BJ1H = oyIN.dot(jlSq, bUZ8)\n if not oyIN.any(BJ1H):\n return None\n n2Q... | [
"0.8081382",
"0.8068263",
"0.7974957",
"0.79248786",
"0.7754521",
"0.7631844",
"0.7616198",
"0.7456514",
"0.7441599",
"0.7391993",
"0.739167",
"0.7226837",
"0.72225976",
"0.7200619",
"0.7200182",
"0.7118815",
"0.70469433",
"0.7035681",
"0.7026693",
"0.7023436",
"0.7022253",
... | 0.7645809 | 5 |
Takes a 3d vector representing a point in space and returns True if the point lies on this plane | def AQW1(YKHO, AU8u):
return (AU8u - YKHO.point).dot(YKHO.normal) == 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def x_Zf(YKHO, kEC0, AU8u, jDK_):\n WKvO, LVAh = jDK_\n P6bq = kEC0[0] - AU8u\n Ty9i = kEC0[1] - AU8u\n jzdc = P6bq[WKvO] * Ty9i[LVAh]\n Fg_i = P6bq[LVAh] * Ty9i[WKvO]\n return jzdc >= Fg_i",
"def xc3U(YKHO, AU8u) -> bool:\n if isinstance(AU8u, PvyL):\n J1b4 = (AU8u.x - YKHO.p.x) / YK... | [
"0.7651025",
"0.7227507",
"0.71526337",
"0.71373755",
"0.7097128",
"0.7096093",
"0.7075651",
"0.7035625",
"0.70127803",
"0.6920753",
"0.6916888",
"0.68347794",
"0.6809418",
"0.68086106",
"0.67939496",
"0.67915606",
"0.67710066",
"0.67650515",
"0.67514044",
"0.6751296",
"0.674... | 0.83199674 | 0 |
Takes a Line3d representing a line segment between two points and returns the 3d vector where it intersects this plane, or None if it does not intersect. Returns None if the line lies on the plane. | def Hs1B(YKHO, zFiD):
F4_u = zFiD.a
O_Up = zFiD.dir()
ciZM = O_Up.dot(YKHO.normal)
if ciZM == 0:
return None
Csk6 = (YKHO.point - F4_u).dot(YKHO.normal) / ciZM
if Csk6 < 0 or Csk6 > zFiD.length():
return None
return F4_u + O_Up * Csk6 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def blrU(aPd6, V6IE):\n Csk6 = V6IE.n.dot(aPd6.v)\n if not Csk6:\n return None\n P6bq = (V6IE.k - V6IE.n.dot(aPd6.p)) / Csk6\n if not aPd6._u_in(P6bq):\n return None\n return zMVZ(aPd6.p.x + P6bq * aPd6.v.x, aPd6.p.y + P6bq * aPd6.v.y, aPd6.p.z + P6bq * aPd6.v.z)",
"def Mo5q(zFiD, kE... | [
"0.777595",
"0.75574565",
"0.7228568",
"0.709626",
"0.70386404",
"0.703577",
"0.6875079",
"0.683015",
"0.67599726",
"0.67535466",
"0.67282844",
"0.6717947",
"0.6634886",
"0.6546912",
"0.65466046",
"0.6531458",
"0.64952093",
"0.6490842",
"0.64839816",
"0.64394176",
"0.64078975... | 0.722938 | 2 |
Pad a single encoded input or a batch of encoded inputs up to predefined length or to the max sequence length in the batch. Padding side (left/right) padding token ids are defined at the tokenizer level (with ``self.padding_side``, ``self.pad_token_id`` and ``self.pad_token_type_id``) | def hVLt(YKHO, H_2r: Union[BatchEncoding, List[BatchEncoding], Dict[str, EncodedInput], Dict[str, List[EncodedInput]], List[Dict[str, EncodedInput]]], dvgN=True, BcCR: Optional[int]=None, FIth: Optional[int]=None, Hlu9: Optional[bool]=None, ptD0=None, PJWX: bool=True) -> J5nJ:
if isinstance(H_2r, (list, tuple)) and... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hVLt(YKHO, H_2r: Union[BatchEncoding, List[BatchEncoding], Dict[str, EncodedInput], Dict[str, List[EncodedInput]], List[Dict[str, EncodedInput]]], dvgN: Union[bool, str, PaddingStrategy]=True, BcCR: Optional[int]=None, FIth: Optional[int]=None, Hlu9: Optional[bool]=None, ptD0: Optional[Union[str, TensorType]]=... | [
"0.8047334",
"0.75014305",
"0.7500408",
"0.7361219",
"0.7239913",
"0.7203061",
"0.7181596",
"0.71625537",
"0.6992944",
"0.6927919",
"0.69222546",
"0.6901208",
"0.67236584",
"0.67116755",
"0.670118",
"0.66659415",
"0.66551995",
"0.66343033",
"0.66190755",
"0.65917027",
"0.6558... | 0.7006979 | 8 |
Pad encoded inputs (on left/right and up to predefined length or max length in the batch) | def AeBf(YKHO, H_2r: Union[Dict[str, EncodedInput], BatchEncoding], BcCR: Optional[int]=None, s1rJ: str='LONGEST', FIth: Optional[int]=None, Hlu9: Optional[bool]=None) -> dict:
if Hlu9 is None:
Hlu9 = False
Be7K = H_2r['func1_input_ids']
FxG7 = H_2r['func1_mask_for_bottom']
hpGg = max([len(JfyU)... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zFJe(CK9p, zNig):\n return CK9p + [0] * (zNig - len(CK9p))",
"def VT3p(YKHO, wzH_, Rdw3):\n while len(YKHO.enc_input) < wzH_:\n YKHO.enc_input.append(Rdw3)\n while len(YKHO.enc_input_extend_vocab) < wzH_:\n YKHO.enc_input_extend_vocab.append(Rdw3)\n while len(YKHO.original_article_w... | [
"0.7514153",
"0.7432668",
"0.7329321",
"0.725169",
"0.7194471",
"0.71807075",
"0.71543163",
"0.71500474",
"0.7146103",
"0.71379036",
"0.7135984",
"0.7096075",
"0.7042798",
"0.70396817",
"0.702409",
"0.7019245",
"0.7000725",
"0.69516397",
"0.692998",
"0.6922662",
"0.6875461",
... | 0.6867614 | 21 |
Collate `examples` into a batch, using the information in `tokenizer` for padding if necessary. | def Asyf(_73Q, b0j5, FIth: Optional[int]=None):
if isinstance(_73Q[0], (list, tuple)):
_73Q = [ht2j.tensor(tTpl, dtype=ht2j.long) for tTpl in _73Q]
HOR4 = _73Q[0].size(0)
OrWg = all((WKvO.size(0) == HOR4 for WKvO in _73Q))
if OrWg and (FIth is None or HOR4 % FIth == 0):
return ht2j.stack... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Asyf(_73Q, b0j5, FIth: Optional[int]=None):\n if isinstance(_73Q[0], (list, tuple)):\n _73Q = [ht2j.tensor(tTpl, dtype=ht2j.long) for tTpl in _73Q]\n HOR4 = _73Q[0].size(0)\n OrWg = all((WKvO.size(0) == HOR4 for WKvO in _73Q))\n if OrWg and (FIth is None or HOR4 % FIth == 0):\n return... | [
"0.7527707",
"0.7372823",
"0.6981595",
"0.68110764",
"0.6746341",
"0.6645595",
"0.66419256",
"0.66326654",
"0.662929",
"0.66063696",
"0.65873605",
"0.6585807",
"0.6582629",
"0.65779513",
"0.6577462",
"0.6549868",
"0.65480715",
"0.65473425",
"0.65410924",
"0.65376663",
"0.6533... | 0.752084 | 1 |
Add a new experience to memory. | def H2v5(YKHO, hwkq):
gcJ8, u31v, NRKk, L749, om7H, lCq3 = hwkq
for KCHu, XP5J, jzdc, Mkmy, k0lF, QZcN in zip(gcJ8, u31v, NRKk, L749, om7H, lCq3):
YRbF = 0
while YRbF < YKHO.num_agents:
tTpl = YKHO.data(KCHu[YRbF, :], XP5J[YRbF, :].detach(), jzdc[YRbF, :], Mkmy[YRbF], k0lF[YRbF], QZc... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ilp5(YKHO, GsKL):\n YKHO.memory.append(GsKL)",
"def H2v5(YKHO, GsKL):\n YKHO.memory.append(GsKL)",
"def GsKL(YKHO, GsKL: Experience[ActionType]) -> None:\n YKHO.memory.append(GsKL)",
"def H2v5(YKHO, QTBn, XeOP, vOGg, rxHc, _ins):\n YKHO.memory.append(XlZM(QTBn, XeOP, vOGg, rxHc, _ins))",
"d... | [
"0.8763217",
"0.8755159",
"0.8509186",
"0.79707366",
"0.7879077",
"0.7878838",
"0.7878838",
"0.7709677",
"0.7708713",
"0.7609456",
"0.74958277",
"0.7470479",
"0.74537706",
"0.737918",
"0.73555547",
"0.730577",
"0.7283659",
"0.7276514",
"0.72636735",
"0.7246649",
"0.72328925",... | 0.0 | -1 |
Get the percent overlap of two gaussians, given their definitions, and intersection point. | def a4Si(XMlP, gpRq, E43s, QgyP, oD27):
return CkYf.cdf(XMlP, E43s, oD27) + (1.0 - CkYf.cdf(XMlP, gpRq, QgyP)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RWKu(YKHO, jzdc, Fg_i):\n jzdc = [float(exwG) for exwG in jzdc]\n jzdc.sort()\n Fg_i = [float(exwG) for exwG in Fg_i]\n Fg_i.sort()\n LXQN, Qpk_ = jzdc\n zXjw, xQwd = Fg_i\n if xQwd < LXQN:\n return 0\n if zXjw > Qpk_:\n return 0\n if zXjw >= LXQN and xQwd <= Qpk_:\n ... | [
"0.7390531",
"0.71830827",
"0.6956581",
"0.6667753",
"0.66594726",
"0.6645613",
"0.6636697",
"0.6581562",
"0.6524526",
"0.65130514",
"0.65078473",
"0.64360064",
"0.63874453",
"0.6380799",
"0.6364114",
"0.63599384",
"0.63351196",
"0.63168335",
"0.62970585",
"0.62904346",
"0.62... | 0.6983347 | 2 |
Prices is one asset's price data, in either DataFrame or Pandas Series | def daI_(n3gB, AVpI, uqvc='\\keras_model\\'):
SWox = T2IJ()
__n6, C3ST = SP5P(AVpI)
print(f'load data and model: {T2IJ() - SWox:0.4f}s')
SWox = T2IJ()
__n6 = n3gB(__n6)
BGtX = __n6.drop(columns='price')
BGtX = yti2(BGtX)
print(f'process dataset: {T2IJ() - SWox:0.4f}s')
SWox = T2IJ()
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def CgxO(YKHO, gDTG, B1Wx, UoOD):\n geh0 = G4JS.get(YKHO.BASE_URL + '/prices/{epic}/{resolution}/{numPoints}'.format(epic=gDTG, resolution=B1Wx, numPoints=UoOD), headers=YKHO.LOGGED_IN_HEADERS)\n nPrm = YKHO.parse_response(geh0.text)\n if YKHO.return_dataframe:\n nPrm['prices'] = rLdf.DataFrame(nPr... | [
"0.6790236",
"0.650595",
"0.6480746",
"0.63917446",
"0.6305257",
"0.6281968",
"0.62555486",
"0.6242601",
"0.6191881",
"0.6158811",
"0.6152591",
"0.61417836",
"0.6126807",
"0.60015994",
"0.5992167",
"0.5985267",
"0.5975033",
"0.59358245",
"0.5933079",
"0.5930324",
"0.58685285"... | 0.0 | -1 |
Prices is one asset's price data, in either DataFrame or Pandas Series | def hnnD(n3gB, tP7O, NIjm, Mp0L=30, uqvc='\\keras_model\\'):
SWox = T2IJ()
__n6, A18S = yRnS(tP7O, NIjm, uqvc)
C3ST = uyMl(A18S)
print(f'load data and model: {T2IJ() - SWox:0.4f}s')
SWox = T2IJ()
__n6 = n3gB(__n6)
__n6 = __n6.drop(columns='price_one')
__n6 = __n6.drop(columns='price_two'... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def CgxO(YKHO, gDTG, B1Wx, UoOD):\n geh0 = G4JS.get(YKHO.BASE_URL + '/prices/{epic}/{resolution}/{numPoints}'.format(epic=gDTG, resolution=B1Wx, numPoints=UoOD), headers=YKHO.LOGGED_IN_HEADERS)\n nPrm = YKHO.parse_response(geh0.text)\n if YKHO.return_dataframe:\n nPrm['prices'] = rLdf.DataFrame(nPr... | [
"0.67911094",
"0.6507594",
"0.64812374",
"0.6391563",
"0.6306707",
"0.62836367",
"0.62562793",
"0.6242138",
"0.61932915",
"0.61612344",
"0.6152862",
"0.6142382",
"0.6126651",
"0.6002739",
"0.59939533",
"0.5986964",
"0.59752727",
"0.5936988",
"0.5934105",
"0.5931054",
"0.58704... | 0.0 | -1 |
Converts a dict with "x", "y" (and optionally "z") attributes into a tuple that can be used to e.g. initialise a numpy array | def tB25(UfdM, type='numpy'):
ROpF = []
if type == 'numpy':
ROpF.append(int(UfdM['y']))
ROpF.append(int(UfdM['x']))
elif type == 'fiji':
ROpF.append(int(UfdM['x']))
ROpF.append(int(UfdM['y']))
else:
raise NotImplementedError("Type: {} not recognise, please specify... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def pTc2(YKHO):\n return (YKHO.x, YKHO.y, YKHO.z)",
"def azoT(o8Kj: dict) -> tuple:\n o8Kj = o8Kj or {}\n vEq1 = o8Kj.get('id', '')\n KndY = o8Kj.get('classes', [])\n LthG = [[WKvO, o8Kj[WKvO]] for WKvO in o8Kj if WKvO != 'classes' and WKvO != 'id']\n return (vEq1, KndY, LthG)",
"def DLpQ(cvi... | [
"0.6500814",
"0.64124006",
"0.64004487",
"0.6375317",
"0.60990304",
"0.60141957",
"0.59075654",
"0.58628887",
"0.5859685",
"0.5837008",
"0.58293027",
"0.5815779",
"0.5813527",
"0.5802462",
"0.5793783",
"0.5758677",
"0.5756972",
"0.57237595",
"0.5720189",
"0.5719852",
"0.57179... | 0.0 | -1 |
get the list of most recent trades for a particular symbol | async def watch_trades(YKHO, o61b: str, pw_q: Optional[int]=None, qoqK: Optional[int]=None, NArs={}):
await YKHO.load_markets()
o61b = YKHO.symbol(o61b)
mWFP = 'trade'
WZsM = await YKHO.watch_public(mWFP, o61b, NArs)
if YKHO.newUpdates:
qoqK = WZsM.getLimit(o61b, qoqK)
return YKHO.filter... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ooeb(YKHO, o61b, Kt_s=15):\n RA_F = JRYC.datetime.now() - JRYC.timedelta(minutes=15)\n sQg9 = []\n for IYUG in YKHO.trades.keys():\n if YKHO.trades[IYUG]['symbol'] != o61b:\n continue\n if IYUG < RA_F:\n break\n sQg9.append([YKHO.trades[IYUG]['quantity'], YKH... | [
"0.71393704",
"0.7105903",
"0.7097551",
"0.685329",
"0.6760904",
"0.6730296",
"0.669295",
"0.6634163",
"0.6634163",
"0.6634163",
"0.66293323",
"0.6617462",
"0.66110575",
"0.65693617",
"0.65642685",
"0.64636725",
"0.64636725",
"0.64636725",
"0.6421317",
"0.6414529",
"0.6398772... | 0.0 | -1 |
Age text box listener. | def ogm5(YKHO):
YKHO.resultsL.setText('') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def y_M0(YKHO, KAOR, BWXx):\n KAOR.text = BWXx\n YKHO.GetAge.insertValue(BWXx)",
"def DJSN(YKHO, *qIxc, **B2fa):\n pass",
"def _yIk(YKHO, *qIxc, **B2fa):\n pass",
"def ZJe_(KonM):\n if KonM > 110 or KonM == 0:\n Oz1B('clear')\n zi5e('age')\n XRsT = TMNs()\n ZJe_(Kon... | [
"0.7007074",
"0.68144846",
"0.66393787",
"0.6511181",
"0.649479",
"0.6466113",
"0.63431656",
"0.63431656",
"0.63431656",
"0.62799215",
"0.6252663",
"0.621115",
"0.61615723",
"0.61106205",
"0.6092984",
"0.596149",
"0.59548247",
"0.5954093",
"0.58839434",
"0.58807814",
"0.58436... | 0.69501585 | 1 |
Get the position of the OpenCV VideoCapture. Due to some internal workings of OpenCV, the actual position the capture object ends up at may differ from the requested position. | def np9b(YKHO) -> int:
YKHO.frame_number = YKHO._capture.get(XC5k.CAP_PROP_POS_FRAMES)
return YKHO.frame_number | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def p1NA() -> float:\n pass",
"def JY1I(YKHO):\n UcZ6 = ExMO.LONGLONG()\n if not ExMO.LucamPreviewAVIGetPositionFrame(YKHO._handle, UcZ6):\n raise brWd()\n return UcZ6.value",
"def QqKu(YKHO):\n return gnPz.buf_to_npy(YKHO._ptr.contents.cam_pos, (YKHO.ncam, 3))",
"def XoGc(YKHO):\n r... | [
"0.74660534",
"0.7383021",
"0.7324053",
"0.701203",
"0.6995733",
"0.6993633",
"0.6964933",
"0.69558465",
"0.6932461",
"0.6920526",
"0.6890015",
"0.68642014",
"0.68505067",
"0.68505067",
"0.68499106",
"0.6824867",
"0.68223614",
"0.68223614",
"0.68223614",
"0.68223614",
"0.6817... | 0.8043367 | 0 |
Returns a dictionary from parameter names to descriptions. Returns | def Rdgn(Emd4):
return dict(pi_res='phase interpolator resolution', lch='transistor channel length', wn='inverter0 NMOS width', wp='inverter0 PMOS width', nf_inv='inverter NMOS finger number', nf_tinv0='tri-inverter0 NMOS finger number', nf_tinv1='tri-inverter1 PMOS finger number', intent='transistor threshold', du... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MnWk(YKHO):\n aevO = YKHO.describe()\n return dict([(XP5J['key'], XP5J) for XP5J in aevO['parameters']])",
"def SGPK(YKHO):\n return dict(((G1Hx, getattr(YKHO, G1Hx)) for G1Hx in YKHO._parameter_names))",
"def SGPK(YKHO) -> cuzp[str, ImMB]:\n return {mWFP: getattr(YKHO, mWFP) for mWFP in YKHO.p... | [
"0.8323599",
"0.7416645",
"0.73098916",
"0.72821087",
"0.7112357",
"0.69728196",
"0.69145745",
"0.6907672",
"0.68064445",
"0.68014175",
"0.68006855",
"0.6749965",
"0.67406386",
"0.6739034",
"0.670004",
"0.66252285",
"0.65529186",
"0.6518889",
"0.65064925",
"0.6504026",
"0.649... | 0.64298505 | 27 |
A factory that returns the webdriver you want. | def YqyH(g7QD: str) -> yg6I:
J8oL = {'chrome': cSpz.Chrome, 'firefox': cSpz.Firefox}
HEPM = [H5ew for H5ew in J8oL.keys()]
FiN2 = ', '.join(HEPM[:-1])
FiN2 += f', and {HEPM[-1]}'
if g7QD not in J8oL:
raise Exception(f'The driver you selected ({g7QD}) is not in our list of drivers: {FiN2}')
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xigm(Wy9G: str) -> ngu_:\n TI1B = uAzu.get_driver(Wy9G)\n VLD1.set_driver(TI1B)\n GvpC(TI1B)\n return TI1B",
"def cSpz(YKHO):\n cSpz = Zk1O.get(browser=QGKT('chrome'), screen_size=YKHO.screen_size.value)\n YKHO.addCleanup(YKHO.finish_webdriver)\n return cSpz",
"def aDzh(YKHO) -> cSpz:\... | [
"0.74780333",
"0.74471885",
"0.7386131",
"0.73651165",
"0.7334973",
"0.7278539",
"0.7250872",
"0.7241945",
"0.72358996",
"0.72099984",
"0.7170152",
"0.7164836",
"0.7159448",
"0.71055186",
"0.7096061",
"0.70344096",
"0.7015181",
"0.6989365",
"0.6952038",
"0.6942389",
"0.693216... | 0.7015191 | 16 |
Get the latest data and use it to update our sensor state. | def QdZT(YKHO):
YKHO.data.update()
cdAh = YKHO.data.data
if YKHO.type == 'billno':
YKHO._state = cdAh.find('input', {'name': 'bill_no'}).get('value')
elif YKHO.type == 'amount':
YKHO._state = cdAh.find('input', {'id': 'amount'}).get('value')
elif YKHO.type == 'billdate':
YKHO... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QdZT(YKHO):\n YKHO._data.update()\n YKHO._data_date = YKHO._data.get_data_date()\n if YKHO._sensor_type == 'total':\n YKHO._state = YKHO._data.get_total_day()\n else:\n YKHO._state = YKHO._data.get_usage_hour(YKHO._hour)",
"def aDoo(YKHO):\n if YKHO.me.get_sensor_data():\n ... | [
"0.78422564",
"0.7497692",
"0.73961",
"0.7104456",
"0.709686",
"0.70897466",
"0.7073444",
"0.7020914",
"0.70063627",
"0.6985974",
"0.69317544",
"0.69154465",
"0.6892305",
"0.6888149",
"0.68475205",
"0.6805409",
"0.6800212",
"0.6763809",
"0.6763629",
"0.6718517",
"0.67072546",... | 0.0 | -1 |
pads string s on the right such that is has at least length target_len | def P0iS(KCHu, i7rd):
return KCHu + ' ' * (i7rd - len(KCHu)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def jyoK(KCHu, wzH_):\n try:\n Qwio = oyIN.pad(KCHu, (0, wzH_ - len(KCHu)), 'constant', constant_values=(0, 0))\n except ValueError as e:\n print('In exception!!')\n Qwio = KCHu[:wzH_]\n return Qwio",
"def CiY5(j93S, DB_8):\n a__r = len(j93S)\n if a__r > DB_8:\n return ... | [
"0.7105734",
"0.7045749",
"0.693528",
"0.693528",
"0.6899652",
"0.68689793",
"0.6814196",
"0.6779184",
"0.66677296",
"0.6627773",
"0.6614775",
"0.6567214",
"0.65387875",
"0.653868",
"0.6538293",
"0.6529885",
"0.64824975",
"0.64666665",
"0.64459544",
"0.64385414",
"0.6421052",... | 0.891787 | 0 |
Return the name of the securitygroup, to avoid conflicts with the other entities | def qFXZ(YKHO, _sef, Rci7):
return 'sg-' + _sef.name + '-' + Rci7 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RIk_(w2B8, hbFX, jeGQ=True):\n return _wd5(w2B8.network.find_security_group, hbFX, jeGQ)",
"def IXKo(YKHO) -> str:\n return qe4Y.get(YKHO, 'group_name')",
"def XZ_F(YKHO):\n return ''",
"def IXKo(YKHO):\n return YKHO._config['group']",
"def IXKo(YKHO) -> h8nf[str]:\n return qe4Y.get(YKHO... | [
"0.7901142",
"0.7679343",
"0.76193434",
"0.73826164",
"0.73795724",
"0.7352238",
"0.72889197",
"0.7268239",
"0.7268192",
"0.72430056",
"0.7218429",
"0.7216812",
"0.71768695",
"0.7139725",
"0.711891",
"0.7109758",
"0.7079644",
"0.70778114",
"0.70738125",
"0.706218",
"0.7051340... | 0.0 | -1 |
Return the ID of the Security group | def qkbz(YKHO, _sef, Rci7, X9mD=False):
TN1U = YKHO.data[YKHO.sg_name(_sef, Rci7)]
if X9mD and (not TN1U):
raise KeyError('No such %s exists' % LEXu.__class__.__name__)
return TN1U | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fEOc(YKHO) -> qe4Y.Output[h8nf[str]]:\n return qe4Y.get(YKHO, 'security_group_id')",
"def HfRg(YKHO):\n AzGG = YKHO.ec2_client.describe_security_groups(Filters=[YKHO._create_name_filter()])\n return AzGG['SecurityGroups'][0]['GroupId']",
"def fEOc(YKHO) -> h8nf[qe4Y.Input[str]]:\n return qe4Y.g... | [
"0.8527346",
"0.835863",
"0.82935536",
"0.82935536",
"0.8182109",
"0.8123809",
"0.80473703",
"0.80473703",
"0.8033086",
"0.8012092",
"0.787222",
"0.7857259",
"0.78356427",
"0.77976245",
"0.7774302",
"0.76943296",
"0.76943296",
"0.76933116",
"0.76933116",
"0.76933116",
"0.7693... | 0.0 | -1 |
1hot encode x with the max value n (computed from data if n is None). | def HDkg(WKvO, exwG=None, yDqo=oyIN.int):
WKvO = oyIN.asarray(WKvO)
exwG = oyIN.max(WKvO) + 1 if exwG is None else exwG
return oyIN.eye(exwG, dtype=yDqo)[WKvO] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zGX0(WKvO):\n return oyIN.eye(WKvO.max() + 1)[WKvO]",
"def zGX0(WKvO):\n KLLm = oyIN.eye(10)[WKvO]\n return KLLm",
"def vzTG(WKvO: DNDarray) -> _5mP:\n cDK5 = WKvO.shape[0]\n ROaS = ZsLl.max(WKvO).item() + 1\n KLLm = ZsLl.zeros((cDK5, ROaS), split=WKvO.split, device=WKvO.device, comm=WKvO... | [
"0.7813609",
"0.7580748",
"0.75490916",
"0.7420127",
"0.74077165",
"0.7393953",
"0.7368497",
"0.7343966",
"0.73223794",
"0.7295092",
"0.7293801",
"0.7289784",
"0.7239305",
"0.715733",
"0.71524364",
"0.71478236",
"0.71297896",
"0.71057945",
"0.70771873",
"0.70232886",
"0.69778... | 0.763158 | 1 |
Converts strings to integers if they're composed of digits; otherwise returns the strings unchanged. One way of sorting strings with numbers; it will mean that ``"11"`` is more than ``"2"``. | def Zn2L(l5Ny: str) -> uLKX[int, str]:
return int(l5Ny) if l5Ny.isdigit() else l5Ny | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TGDD(vIwR):\n return [int(KCHu) if KCHu.isdigit() else KCHu for KCHu in ZbWC.split('(\\\\d+)', vIwR)]",
"def OR17(KCHu):\n Zn2L = lambda KCHu: int(KCHu) if KCHu.isdigit() else KCHu.lower()\n return tuple((Zn2L(str) for str in ZbWC.split('(\\\\d+)', KCHu)))",
"def mSKC(vC9B):\n a8Pe = lambda l5N... | [
"0.73343843",
"0.70988303",
"0.685149",
"0.6845447",
"0.6833021",
"0.67715317",
"0.6759392",
"0.6755933",
"0.67478037",
"0.6689114",
"0.6631236",
"0.6629258",
"0.66102254",
"0.66057324",
"0.65981525",
"0.65652627",
"0.65652627",
"0.65652627",
"0.6560943",
"0.6560943",
"0.6560... | 0.0 | -1 |
Sort key function. Returns text split into string/number parts, for natural sorting; as per | def E4UZ(l5Ny: str) -> x1iM[uLKX[int, str]]:
return [Zn2L(Z9rn) for Z9rn in ZbWC.split('(\\d+)', l5Ny)] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TGDD():\n a8Pe = lambda l5Ny: int(l5Ny) if l5Ny.isdigit() else l5Ny\n l35E = lambda H5ew: [a8Pe(Z9rn) for Z9rn in ZbWC.split('([0-9]+)', H5ew)]\n return l35E",
"def qQ6j(l5Ny):\n return [Zn2L(Z9rn) for Z9rn in ZbWC.split('(\\\\d+)', l5Ny)]",
"def TGDD(H5ew):\n import re\n return [int(a1PO... | [
"0.8351717",
"0.81957823",
"0.7914616",
"0.7823286",
"0.7685589",
"0.7570679",
"0.75328606",
"0.75260293",
"0.7495673",
"0.7430552",
"0.7361139",
"0.7340031",
"0.73374563",
"0.7286027",
"0.7276802",
"0.7271949",
"0.72641075",
"0.725622",
"0.724884",
"0.72326666",
"0.71993095"... | 0.0 | -1 |
Translate token into string for display purposes. | def vIwR(YKHO):
return YKHO.chars + ' ' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return 'Token {}'.format(YKHO.token)",
"def zAg0(YKHO):\n return str(YKHO.token)",
"def zAg0(YKHO):\n return str(YKHO.token)",
"def zAg0(YKHO):\n return str(YKHO.token)",
"def yXnH(YKHO, eOtH: Token) -> str:\n l5Ny = eOtH.text\n return l5Ny if eOtH.name != u'control_word... | [
"0.7410384",
"0.7336295",
"0.7336295",
"0.7336295",
"0.72253394",
"0.71864736",
"0.716776",
"0.68631434",
"0.6837592",
"0.6828516",
"0.672918",
"0.6726713",
"0.67262685",
"0.67261225",
"0.66395026",
"0.6554708",
"0.65399486",
"0.65121293",
"0.6503395",
"0.6503395",
"0.6503395... | 0.0 | -1 |
If the encoder is bidirectional, do the following transformation. (directions layers, batch, hidden_size) > (layers, batch, directions hidden_size) | def S7uz(YKHO, MKlR):
if YKHO.bidirectional_encoder:
MKlR = ht2j.cat([MKlR[0:MKlR.size(0):2], MKlR[1:MKlR.size(0):2]], 2)
MKlR = YKHO.Wh(MKlR)
return MKlR | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def KVH6(YKHO, CK9p, Zode, F1y4):\n pass",
"def kNM6(YKHO):\n m013 = ZylS.nn.embedding_lookup(YKHO.embeddings, YKHO.encoder_inputs)\n if YKHO.enc_layers == 1:\n RmE0 = YKHO._single_rnn_(YKHO.num_units)\n LyWp = YKHO._single_rnn_(YKHO.num_units)\n o4Jx, (sQNG, FASL) = ZylS.nn.bidirec... | [
"0.643473",
"0.6404805",
"0.63984126",
"0.639491",
"0.62937903",
"0.62838584",
"0.6281388",
"0.6240283",
"0.6111456",
"0.6098136",
"0.6092646",
"0.6087487",
"0.60647464",
"0.60604596",
"0.6039252",
"0.6025125",
"0.5994782",
"0.5994541",
"0.5993852",
"0.5991577",
"0.5969362",
... | 0.0 | -1 |
Return a string representation of a date according to RFC 1123 (HTTP/1.1). The supplied date must be in UTC. | def o3Z1(JRYC):
XKrP = ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'][JRYC.weekday()]
x0eS = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'][JRYC.month - 1]
return '%s, %02d %s %04d %02d:%02d:%02d GMT' % (XKrP, JRYC.day, x0eS, JRYC.year, JRYC.hour, JRYC.minute, JRYC.s... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lhwL(_c1T):\n if _c1T.tzinfo is None:\n _c1T = FXGE.utc.localize(_c1T)\n return _c1T.isoformat()",
"def JvEs(_c1T):\n return _c1T.isoformat()",
"def GNAZ(_c1T):\n return _c1T.strftime('%a, %d %b %Y %H:%M:%S GMT')",
"def dcJF(_c1T):\n if _c1T is None:\n return None\n return... | [
"0.7477985",
"0.7371464",
"0.72989416",
"0.71498805",
"0.7012908",
"0.6991901",
"0.6932358",
"0.6910967",
"0.690445",
"0.68520266",
"0.68380743",
"0.68256915",
"0.67832017",
"0.67696774",
"0.6765298",
"0.67452866",
"0.6723569",
"0.6705091",
"0.6698021",
"0.66217643",
"0.66008... | 0.0 | -1 |
Initialize an ``InvalidatingAttr`` instance. | def FIMM(YKHO, wCZ6='invalidate'):
YKHO.invalidator = wCZ6
YKHO._attr_name = '_inval_attr_%d' % id(YKHO)
YKHO.attr_name = None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(Emd4, mWFP, gitN, _63S):\n for hGI9, YEnM in _63S.items():\n if isinstance(YEnM, Rdgp):\n YEnM.attr_name = hGI9",
"def o3cX(Emd4):\n G4r5 = tq_1.signature(Emd4.__init__)\n OXrK = list((mWFP for mWFP, QZ3r in G4r5.parameters.items() if QZ3r.kind not in (QZ3r.KEYWORD_ONLY, QZ3r.... | [
"0.66177243",
"0.5683703",
"0.5373325",
"0.5297594",
"0.52394366",
"0.5210982",
"0.51573753",
"0.51061684",
"0.5046904",
"0.50276923",
"0.5015238",
"0.49974176",
"0.49974176",
"0.4955306",
"0.4937555",
"0.493277",
"0.49121806",
"0.4872008",
"0.4862204",
"0.48577914",
"0.48476... | 0.7585266 | 0 |
Converts a comma separated string in a list. | def PNRb(NACC):
list = NACC.split(',')
return list | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def n0SL(BWXx):\n return BWXx.split(',')",
"def joTY(KCHu):\n if isinstance(KCHu, (list, tuple)):\n return KCHu\n Aofo = []\n DumB = KCHu.split(',')\n for YRbF in DumB:\n Aofo.append(YRbF.strip())\n return Aofo",
"def U643(YKHO, vIwR):\n if not ',' in vIwR:\n DkTm.prin... | [
"0.7918956",
"0.7805993",
"0.7704444",
"0.74843603",
"0.74746287",
"0.74654186",
"0.7398377",
"0.7375607",
"0.72394395",
"0.7237862",
"0.72004247",
"0.71552587",
"0.7150381",
"0.71291006",
"0.7105056",
"0.7086448",
"0.70479614",
"0.7046148",
"0.7035866",
"0.70256364",
"0.7009... | 0.8196861 | 0 |
Formats a numeric value as amount of bytes alongside the biggest bytebased unit from the list that represents the same amount without using decimals. | def Gu_3(BWXx: int, *, rYO3: Iterable[str]=U_JC) -> str:
if not rYO3:
return str(BWXx)
Z5kt = BWXx
wK9w = 0
rYO3 = tuple(rYO3)
while (Z5kt >= 1024 and Z5kt % 1024 == 0) and wK9w < len(rYO3) - 1:
Z5kt = int(Z5kt / 1024)
wK9w += 1
return f'{int(Z5kt)}{rYO3[wK9w]}' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cEzZ(mLGw):\n for WKvO in ['bytes', 'KB', 'MB', 'GB']:\n if mLGw < 1024.0:\n return '%3.1f%s' % (mLGw, WKvO)\n mLGw /= 1024.0\n return '%3.1f%s' % (mLGw, 'TB')",
"def XP9Z(WKvO: int):\n T4Wy = int(epAf.log(WKvO, 1024))\n WKvO /= 1024 ** T4Wy\n if WKvO >= 100:\n ... | [
"0.7590012",
"0.7368787",
"0.73601097",
"0.72507143",
"0.72148407",
"0.72062576",
"0.7185422",
"0.71788055",
"0.71692544",
"0.71600854",
"0.71600854",
"0.71600854",
"0.71600854",
"0.71600854",
"0.71600854",
"0.71498287",
"0.7138898",
"0.7137699",
"0.712461",
"0.71146995",
"0.... | 0.6569103 | 75 |
Attempts to return a stable hash of the value stable across processes. "Stable" here means that if `value` is equivalent in multiple invocations (across multiple processes), it should produce the same hash. To that end, what values are accepted are limited in scope. | def ytoC(BWXx: Any, *, mWFP: str='sha256') -> str:
return HBct.new(mWFP, qQXR.dumps(BWXx, indent=None, separators=(',', ':'), sort_keys=True, cls=bB6n).encode('utf-8')).hexdigest() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sAxw(YKHO, BWXx):\n return hash(BWXx) % YKHO.size",
"def GuaM(BWXx):\n try:\n return hash(BWXx)\n except TypeError:\n return id(BWXx)",
"def OoXC(YKHO, BWXx):\n Aofo = YKHO.__safe_modulo(YKHO.a * BWXx + YKHO.b, YKHO.prime)\n return YKHO.__safe_modulo(Aofo, YKHO.bucket_count)",
... | [
"0.67287415",
"0.6663283",
"0.6538234",
"0.6494597",
"0.6441036",
"0.63964206",
"0.62680036",
"0.6260089",
"0.6159556",
"0.60891485",
"0.60688055",
"0.6059086",
"0.5976964",
"0.59516823",
"0.59145916",
"0.58967614",
"0.5872369",
"0.5841901",
"0.5841901",
"0.57868826",
"0.5785... | 0.67217463 | 1 |
home page for CryptoVsMarket project | def d6pt():
return TvZl('index.html') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kZiy(QePW):\n return _1tc(QePW, 'crypto/index.html')",
"def kZiy():\n return TvZl('main.html')",
"def kZiy(QePW):\n QpfX = {'title': 'Home'}\n return _1tc(QePW, 'invi_cards/home.html', QpfX)",
"def kZiy():\n FWJU().authenticate()\n return TvZl('index.html')",
"def kZiy():\n return ... | [
"0.7867692",
"0.7605047",
"0.75559515",
"0.75240296",
"0.74916357",
"0.7469715",
"0.74646276",
"0.74450535",
"0.74284506",
"0.73861057",
"0.73799926",
"0.7376257",
"0.7376257",
"0.7333296",
"0.7319215",
"0.7317887",
"0.73119795",
"0.73059064",
"0.7305185",
"0.7292455",
"0.728... | 0.0 | -1 |
Calculate the kinetic friction energy accumulation in W per m^2 | def eghY(YKHO, GD_A=None, cU0b=None):
euyF('calculating e_a,kin')
VTcs = oyIN.multiply(YKHO.ball.press.sum(1), YKHO.rel_vel)
YKHO.ball.e_akin = oyIN.absolute(oyIN.divide(oyIN.multiply(VTcs, YKHO.ball.overroll_t_incr), YKHO.ball.no_overroll_t)) / 1000
YKHO.disk.e_akin = oyIN.absolute(oyIN.divide(oyIN.mul... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def np1B(YKHO):\n return 0.5 * YKHO.mass * oyIN.linalg.norm(YKHO.velocity) ** 2",
"def np1B(YKHO):\n lD1n = YKHO.velocity[0] ** 2 + YKHO.velocity[1] ** 2 + YKHO.velocity[2] ** 2\n return 0.5 * YKHO.mass * lD1n",
"def np1B() -> float:\n return sum(map(lambda YEnM: YEnM.kinetic_energy(), aPf_))",
"... | [
"0.73686385",
"0.7224741",
"0.699209",
"0.69422317",
"0.68840253",
"0.6865649",
"0.67091763",
"0.65380526",
"0.64770275",
"0.6448483",
"0.64241636",
"0.6405792",
"0.6404674",
"0.6379098",
"0.6376506",
"0.63755953",
"0.6361416",
"0.63606447",
"0.6328923",
"0.6271832",
"0.62637... | 0.0 | -1 |
Return True if an authorization has already been granted on the freebox. | def JVfd(YKHO):
return True if Hy7s.path.isfile(Dlx9) else False | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def em58():\n return True",
"def PVSl():\n return CmGq.User().IsAllowed('Regenerate Confirmation', 'Operation')",
"def qHTF(YKHO, QePW, tTee):\n eOtH = QePW.META.get(rLF8, '')\n if not eOtH or not E4Up:\n return False\n rJDA = QGEN.objects.filter(token=eOtH, revoked=False).first()\n if... | [
"0.7393001",
"0.7052075",
"0.69996864",
"0.6874889",
"0.6774935",
"0.67361987",
"0.66313726",
"0.66089493",
"0.66089493",
"0.6603256",
"0.6591856",
"0.65820307",
"0.6580569",
"0.65752363",
"0.6564802",
"0.65617853",
"0.65507996",
"0.6516566",
"0.65071803",
"0.64661515",
"0.64... | 0.72557306 | 1 |
The device unique id. | def PObu(YKHO):
DpZH = G4JS.get(YKHO._freebox_url + vp8q)
return DpZH.json()['uid'] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ShR8(YKHO) -> str:\n return YKHO._device.device_id",
"def ShR8(YKHO):\n return YKHO._device.device_id",
"def ShR8(YKHO):\n return YKHO._device.device_id",
"def ShR8(YKHO):\n return YKHO.device.id",
"def jf3N(YKHO):\n return YKHO.unique_id",
"def ShR8(YKHO):\n return YKHO._device.dev... | [
"0.93634444",
"0.9328172",
"0.9328172",
"0.92938846",
"0.9249815",
"0.92135555",
"0.9190598",
"0.9164957",
"0.9152667",
"0.9074744",
"0.9054947",
"0.8949258",
"0.8949258",
"0.8939851",
"0.8939851",
"0.8888881",
"0.8810209",
"0.8804333",
"0.8730267",
"0.86572254",
"0.8647791",... | 0.0 | -1 |
Uses the Haversine formula to calculate the distance between two coordinates given in the (latitude, longitude) in decimal format | def D0Sn(mAYH, pks6):
igSk = epAf.radians(mAYH[0])
TGuP = epAf.radians(pks6[0])
GgQG = epAf.radians(mAYH[1])
tk0B = epAf.radians(pks6[1])
HvcS = TGuP - igSk
GS7B = tk0B - GgQG
jzdc = epAf.pow(epAf.sin(HvcS / 2), 2) + epAf.cos(igSk) * epAf.cos(TGuP) * epAf.pow(epAf.sin(GS7B / 2), 2)
Z9rn ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dNcu(jtuy, kSJA, F3ew, m27z):\n kSJA, jtuy, m27z, F3ew = map(epAf.radians, [kSJA, jtuy, m27z, F3ew])\n J7Up = m27z - kSJA\n L3Pz = F3ew - jtuy\n jzdc = epAf.sin(L3Pz / 2) ** 2 + epAf.cos(jtuy) * epAf.cos(F3ew) * epAf.sin(J7Up / 2) ** 2\n Z9rn = 2 * epAf.asin(epAf.sqrt(jzdc))\n Csk6 = 6367 * Z... | [
"0.8404627",
"0.82676417",
"0.8228095",
"0.82096076",
"0.81539214",
"0.80978173",
"0.80675125",
"0.8020524",
"0.8013462",
"0.80006796",
"0.79969347",
"0.7989447",
"0.7982907",
"0.79807514",
"0.79807514",
"0.79164153",
"0.78962904",
"0.78948355",
"0.78926927",
"0.7878559",
"0.... | 0.0 | -1 |
returns the angle of the vector in radians | def zZvm(iArr):
WKvO, LVAh = iArr
Uyfy = LVAh / WKvO
return oyIN.arctan(Uyfy) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YylR(YKHO):\n PXGI = YKHO.unit()\n return epAf.atan2(PXGI.y, PXGI.x)",
"def Tbd6(YKHO, he6J):\n WKvO, LVAh = he6J\n return epAf.pi / 2 - epAf.atan2(LVAh, WKvO)",
"def kj80(YKHO, WKvO, LVAh):\n if WKvO == 0:\n if LVAh <= 0:\n YylR = 0\n else:\n YylR = epAf.... | [
"0.8337589",
"0.8276669",
"0.82441664",
"0.82114047",
"0.81587607",
"0.80779976",
"0.8047464",
"0.8041208",
"0.78879994",
"0.7847481",
"0.77870727",
"0.7783825",
"0.7765054",
"0.7732693",
"0.7724217",
"0.7679388",
"0.7672817",
"0.7662941",
"0.76623166",
"0.76593274",
"0.76586... | 0.83550847 | 0 |
This funcddtion safely pops from the front of the pending action queue. If the queue is empty, returns a null string to be handled by the move node else returns the popped queue element | def rOVm(YKHO):
try:
YKHO.active = YKHO.pending.pop(0).action
except IndexError as er:
zi3U.log_exception(D4AW, 'cmd_queue')
return 'null'
else:
return YKHO.active | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Ek8z(YKHO):\n try:\n return YKHO.pending[0]\n except IndexError as er:\n zi3U.log_exception(D4AW, 'cmd_queue')\n return 'null'",
"def he0F(gGq6):\n return gGq6.pop()",
"def lUw2(YKHO):\n try:\n return YKHO.pending[0].action\n except IndexError as er:\n zi3U... | [
"0.7183468",
"0.705142",
"0.70174736",
"0.6903844",
"0.6881346",
"0.6875158",
"0.68719774",
"0.68719774",
"0.6859403",
"0.6798815",
"0.67800945",
"0.67714876",
"0.67411125",
"0.67353517",
"0.6723008",
"0.669794",
"0.6638099",
"0.6620068",
"0.66060543",
"0.6587868",
"0.6572180... | 0.7082929 | 1 |
This function safely peeks at the front of the queue and returns what is sees. If the queue is empty, returns a null string | def lUw2(YKHO):
try:
return YKHO.pending[0].action
except IndexError as er:
zi3U.log_exception(D4AW, 'cmd_queue')
return 'null' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VnzS(gGq6):\n if FBfn(gGq6):\n raise IndexError('front on empty queue')\n return gGq6.front.value",
"def T7C_(YKHO):\n if YKHO.queue != []:\n return YKHO.queue[0]",
"def T7C_(YKHO):\n if YKHO.is_empty():\n print('WARNING:: Queue Empty!')\n return None\n return YKH... | [
"0.7875575",
"0.7858846",
"0.7826719",
"0.7826283",
"0.78187907",
"0.7773343",
"0.777107",
"0.7747904",
"0.7728729",
"0.7714216",
"0.7700848",
"0.76757765",
"0.7657462",
"0.76286644",
"0.75958383",
"0.75135565",
"0.7510968",
"0.75073576",
"0.7506931",
"0.7496417",
"0.7439323"... | 0.0 | -1 |
This function safely peeks at the front of the queue and returns what is sees. If the queue is empty, returns a null string | def Ek8z(YKHO):
try:
return YKHO.pending[0]
except IndexError as er:
zi3U.log_exception(D4AW, 'cmd_queue')
return 'null' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VnzS(gGq6):\n if FBfn(gGq6):\n raise IndexError('front on empty queue')\n return gGq6.front.value",
"def T7C_(YKHO):\n if YKHO.queue != []:\n return YKHO.queue[0]",
"def T7C_(YKHO):\n if YKHO.is_empty():\n print('WARNING:: Queue Empty!')\n return None\n return YKH... | [
"0.7874912",
"0.7858746",
"0.7827063",
"0.7826443",
"0.7819172",
"0.7773627",
"0.7770749",
"0.774816",
"0.7728887",
"0.7713835",
"0.77009606",
"0.76760435",
"0.76573014",
"0.7628308",
"0.75139356",
"0.75108683",
"0.75076115",
"0.7506973",
"0.74954873",
"0.7439319",
"0.7387247... | 0.7596845 | 14 |
Returns the last key found in a dictionary given a some value | def rNEI(YVL7, Awfa):
Aofo = None
for H5ew, wEf2 in YVL7.items():
if wEf2 == Awfa:
Aofo = H5ew
return Aofo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def pxMU(eUNp: dict):\n IKIq = list(eUNp.keys())\n S6Zc = IKIq[-1]\n return S6Zc",
"def IDOK(Op6c, wEf2):\n q0oN = max(lPQm(Op6c, '!', 'total energy'))\n return JR4R(Op6c, q0oN, wEf2)",
"def mexE(dict, BWXx):\n return [G1Hx for G1Hx, Ty9i in dict.items() if Ty9i == BWXx][0]",
"def mexE(fGC9... | [
"0.7528912",
"0.73715097",
"0.71603346",
"0.7073593",
"0.7060307",
"0.7059233",
"0.698102",
"0.69806665",
"0.69688064",
"0.6952553",
"0.6944741",
"0.6909107",
"0.6897427",
"0.68814975",
"0.6869407",
"0.6869407",
"0.6867256",
"0.68523735",
"0.68451184",
"0.68451184",
"0.683311... | 0.63059664 | 48 |
Gets number of packets that were not filterd per interval. | def VPhs(wsf4, PN8G, iPXw):
D7KI = oRi_(int)
ZbYx = []
for YRbF in range(0, len(wsf4)):
D7KI[YRbF] = 0
for aV2h in iPXw:
v9Lt = 0
EmMj = False
while v9Lt < len(wsf4) and EmMj == False:
if aV2h >= wsf4[v9Lt] and aV2h <= PN8G[v9Lt]:
D7KI[v9Lt] +=... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Kq25(YKHO):\n return YKHO.__in_packet_band_count",
"def O3h7(YKHO, f4IJ, _Pej, gwAu=95):\n COPr = oyIN.count_nonzero(f4IJ)\n kVwb = _Pej / 100 * gwAu\n W8Oh = _Pej\n GPal = W8Oh - COPr\n return not GPal > kVwb",
"def Nfa8(YKHO):\n return YKHO.count - YKHO._count_of_missing",
"def HzT... | [
"0.6398524",
"0.6372403",
"0.633941",
"0.6318146",
"0.62395227",
"0.61719143",
"0.61713505",
"0.61713505",
"0.61377823",
"0.60677016",
"0.6057159",
"0.6001995",
"0.5987231",
"0.59784377",
"0.5969628",
"0.5959111",
"0.59453523",
"0.5873112",
"0.5866714",
"0.5860129",
"0.584947... | 0.0 | -1 |
Environment matches one of the defined environments. Will return None if there is nothing defined for the current environment. | def DhuX(YKHO) -> h8nf[bool]:
return wPyM(YKHO.ctx, YKHO.environments, logger=YKHO.logger) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def I0_M(YKHO, GikI):\n return next((sEAN for sEAN in YKHO._environments if sEAN.name == GikI))",
"def sPGM(YKHO, i2I_):\n for sEAN in YKHO.environments:\n if sEAN.name == i2I_:\n return sEAN\n return None",
"def GikI(YKHO) -> h8nf[qe4Y.Input[GySg[str, qe4Y.Input[str]]]]:\n return... | [
"0.7026911",
"0.6851386",
"0.6837674",
"0.6776598",
"0.675779",
"0.675779",
"0.675779",
"0.6739517",
"0.6706824",
"0.6706824",
"0.6706824",
"0.6706824",
"0.6706824",
"0.6701302",
"0.6701302",
"0.6680677",
"0.65738285",
"0.65392256",
"0.64503837",
"0.64503837",
"0.6441708",
... | 0.7309141 | 0 |
Tests that credentials in environment variables are preferred to credentials stored in the citrination profile specified | def gQl6():
rJDA = 'mykey'
qpDA = 'mysite.citrination.com'
LKee()
Hy7s.environ[fkSs.CITRINATION_API_KEY] = rJDA
Hy7s.environ[fkSs.CITRINATION_SITE] = qpDA
Hy7s.environ[fkSs.CITRINATION_PROFILE] = 'test'
uFVf, uJRH = kWNQ(None, None, OD3d)
assert uFVf == rJDA
assert uJRH == qpDA
a... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rMOC():\n LKee()\n Hy7s.environ[fkSs.CITRINATION_API_KEY] = ''\n Hy7s.environ[fkSs.CITRINATION_SITE] = ''\n Hy7s.environ[fkSs.CITRINATION_PROFILE] = 'test'\n uFVf, uJRH = kWNQ(None, None, OD3d)\n assert uFVf == 'my_test_profile_key'\n assert uJRH == 'my_test_profile_site'\n aQj6()",
"... | [
"0.75089103",
"0.6850323",
"0.6835001",
"0.677395",
"0.66626704",
"0.6567438",
"0.65307087",
"0.65158564",
"0.65048295",
"0.63877684",
"0.6382492",
"0.6380907",
"0.6364154",
"0.63601995",
"0.6326612",
"0.6285352",
"0.627102",
"0.627102",
"0.627102",
"0.627102",
"0.627102",
... | 0.7889224 | 0 |
Test that is_valid_status returns correct values | def WTCE(YKHO):
d8aV = Ur1t(None)
assert not d8aV.is_valid_status(257)
assert d8aV.is_valid_status(0) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YB1H(YKHO) -> None:\n aEqx = True\n YKHO.status.status = 'VALID'\n n5sN = YKHO.status.is_valid()\n YKHO.assertEqual(aEqx, n5sN)",
"def ub1s(YKHO) -> None:\n aEqx = False\n YKHO.status.status = 'ACTIVE'\n n5sN = YKHO.status.is_valid()\n YKHO.assertEqual(aEqx, n5sN)",
"def a3G7(YKHO) ... | [
"0.83345515",
"0.8048244",
"0.7934773",
"0.78679407",
"0.7849141",
"0.7804887",
"0.7707963",
"0.76107293",
"0.76021606",
"0.76021606",
"0.74478287",
"0.7320312",
"0.72920996",
"0.72568506",
"0.7217686",
"0.7149429",
"0.70512277",
"0.70354825",
"0.7028588",
"0.7007124",
"0.700... | 0.73429453 | 11 |
Gets the absolute path of the root of the git repository. | def KZXb(YKHO):
bCYe = fGmS(['git', 'rev-parse', '--show-toplevel'], stdout=h5ye, stderr=h5ye)
yvT9, XObx = bCYe.communicate()
if XObx:
raise wOE_('Not a git repository.')
tk5Y = yvT9.decode('utf-8')[:-1]
mSqg = pmON.abspath(tk5Y)
return mSqg | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gUWx():\n kKm_ = Hy7s.path.dirname(Hy7s.path.abspath('__file__'))\n return Yn3K.check_output('git rev-parse --show-toplevel'.split(), cwd=kKm_, universal_newlines=True).rstrip()",
"def J1KI(pmON):\n FCN7 = tgM5.Repo(pmON, search_parent_directories=True)\n CYyW = FCN7.git.rev_parse('--show-topleve... | [
"0.8237639",
"0.8230223",
"0.8230223",
"0.8230223",
"0.81417644",
"0.8133444",
"0.80357176",
"0.80322695",
"0.80233383",
"0.80195564",
"0.79197985",
"0.7893299",
"0.7885513",
"0.78777254",
"0.78760076",
"0.78341836",
"0.7811413",
"0.7768573",
"0.76101893",
"0.7583631",
"0.757... | 0.8785904 | 0 |
Gets the current HEAD's hash. | def kxvN(YKHO):
with orSL(YKHO.root):
bCYe = fGmS(['git', 'rev-parse', '--verify', 'HEAD'], stdout=h5ye, stderr=h5ye)
yvT9, XObx = bCYe.communicate()
nZWj = yvT9.decode('utf-8')[:-1]
if not nZWj:
nZWj = '4b825dc642cb6eb9a060e54bf8d69288fbee4904'
return nZWj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hash(YKHO):\n return Hy7s.popen('git rev-parse HEAD').read().strip()",
"def hash(YKHO):\n return Hy7s.popen('git rev-parse HEAD').read().strip()",
"def OoXC():\n return WY3t('git rev-parse --short HEAD', capture=True)",
"def ab6P(YKHO):\n return YKHO.git('rev-parse', 'HEAD').strip()",
"def ... | [
"0.8120753",
"0.8120753",
"0.81200653",
"0.7915558",
"0.74754566",
"0.74610114",
"0.74586457",
"0.738955",
"0.72679317",
"0.72521794",
"0.72517264",
"0.718634",
"0.7144939",
"0.7134658",
"0.70876706",
"0.70608294",
"0.70489705",
"0.701407",
"0.69419295",
"0.6938192",
"0.69348... | 0.847144 | 0 |
RGB reader based on cv2.imread(). Just for consistency with normalmap and depthmap readers. | def ZfOD(pmON):
VMuU = XC5k.imread(str(pmON))
u_65 = XC5k.cvtColor(VMuU, XC5k.COLOR_BGR2RGB)
u_65 = u_65.transpose(2, 0, 1)
return ht2j.tensor(u_65, dtype=ht2j.float32) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ia5o(YKHO, p4m8):\n VXjJ = cE34(p4m8)\n if len(VXjJ.shape) == 2:\n VXjJ = qfpW.gray2rgb(VXjJ)\n VXjJ = VXjJ[..., :3]\n if VXjJ.dtype == 'uint8':\n VXjJ = VXjJ.astype(oyIN.float32) / 255\n return VXjJ",
"def tsdv(Ux0P):\n j3Lh = XC5k.imread(Ux0P)\n d7Eb = j3Lh[:, :, ::-1]\n ... | [
"0.7584",
"0.73938656",
"0.7280729",
"0.7232089",
"0.70188075",
"0.6946799",
"0.6920401",
"0.68692356",
"0.6866525",
"0.6807046",
"0.6790673",
"0.676099",
"0.67060506",
"0.66914815",
"0.6690282",
"0.6690282",
"0.6685936",
"0.66457283",
"0.66103417",
"0.6591725",
"0.65716755",... | 0.0 | -1 |
Read normalmap image from EXR format to tensor of form (3,H,W) | def f3sm(pmON):
UM5f = XC5k.imread(str(pmON), XC5k.IMREAD_ANYCOLOR | XC5k.IMREAD_ANYDEPTH)
UM5f = XC5k.cvtColor(UM5f, XC5k.COLOR_BGR2RGB)
UM5f = UM5f.transpose(2, 0, 1)
return ht2j.tensor(UM5f, dtype=ht2j.float32) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hIB4(YKHO, PDbj):\n onMt = YKHO._read_data_vector(PDbj)\n VjiZ = onMt.reshape(PDbj['Number of lines'], PDbj['Samps/line'])\n return VjiZ",
"def Eac9(pmON):\n sBUS = XC5k.imread(str(pmON), XC5k.IMREAD_ANYDEPTH)\n sBUS = oyIN.expand_dims(sBUS, axis=0)\n return ht2j.tensor(sBUS, dtype=ht2j.flo... | [
"0.6659891",
"0.6090798",
"0.6035614",
"0.59540296",
"0.5879292",
"0.58775777",
"0.5856147",
"0.58372134",
"0.5827468",
"0.58157116",
"0.58043206",
"0.57954735",
"0.57675946",
"0.5767115",
"0.5759479",
"0.5727887",
"0.5726574",
"0.5680978",
"0.5680601",
"0.5676267",
"0.566584... | 0.7430619 | 0 |
Constructor for the HLRLookupResponse class | def FIMM(YKHO, PQNv=None, qRjK=None, TeZt=None, KvA9=None, Ol1Q=None, EPiu=None, u9cQ=None, kdXA=None, yaJB=None, iCcE=None, wVO4=None, m59W=None, grkL=None, DZ0Q=None, Rci7=None, deqf=None, RJwH=None, VOsj=None, vxW9=None, aQPS=None, uvmn=None, XEZq=None, nES7=None):
YKHO.number_valid = PQNv
YKHO.international... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO):\n Wq02 = ['raw', 'updated_date', 'nameservers', 'registrar', 'whois_server', 'query', 'creation_date', 'emails', 'expiration_date', 'status', 'id', 'asn', 'asn_cidr', 'asn_country_code', 'asn_date', 'asn_registry', 'network.cidr', 'network.end_address', 'network.ip_version', 'network.handle', 'n... | [
"0.6595711",
"0.6594673",
"0.65074563",
"0.64770955",
"0.64719176",
"0.642985",
"0.64158964",
"0.64056665",
"0.637908",
"0.637908",
"0.637908",
"0.637908",
"0.62861574",
"0.62677765",
"0.62449956",
"0.6240477",
"0.61588436",
"0.6106211",
"0.60987055",
"0.60987055",
"0.6098705... | 0.0 | -1 |
Creates an instance of this model from a dictionary | def rQfz(Emd4, cmPJ):
if cmPJ is None:
return None
PQNv = cmPJ.get('numberValid')
qRjK = cmPJ.get('internationalCallingCode')
TeZt = cmPJ.get('mnc')
KvA9 = cmPJ.get('numberType')
Ol1Q = cmPJ.get('hlrValid')
EPiu = cmPJ.get('hlrStatus')
u9cQ = cmPJ.get('portedNetwork')
kdXA = ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rQfz(Emd4, cmPJ):\n if cmPJ == None:\n return None\n else:\n mWFP = cmPJ.get('name')\n l8cJ = cmPJ.get('generic_id')\n Gsi3 = cmPJ.get('therauptic_uses')\n PALZ = cmPJ.get('search_score')\n return Emd4(mWFP, l8cJ, Gsi3, PALZ)",
"def rQfz(Emd4, cmPJ):\n if cm... | [
"0.83717704",
"0.8335454",
"0.8215639",
"0.8169286",
"0.8169286",
"0.8147288",
"0.8051544",
"0.802922",
"0.80130595",
"0.79790455",
"0.79222333",
"0.79195154",
"0.7917697",
"0.79124105",
"0.7905466",
"0.7900461",
"0.78967464",
"0.7885628",
"0.78752494",
"0.78539485",
"0.78539... | 0.0 | -1 |
Calculates 'beta' the backward variable. The beta variable is a numpy array indexed by time, then state (TxN). beta[t][i] = the probability of being in state 'i' and then observing the symbols from t+1 to the end (T). | def GW7C(YKHO, pR3T):
UqYS = oyIN.zeros((len(pR3T), YKHO.n), dtype=YKHO.precision)
for KCHu in range(YKHO.n):
UqYS[len(pR3T) - 1][KCHu] = 1.0
for a1PO in range(len(pR3T) - 2, -1, -1):
for YRbF in range(YKHO.n):
for r845 in range(YKHO.n):
UqYS[a1PO][YRbF] += YKHO.A... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def X1Lh(a1PO):\n if a1PO == Kt_s - 1:\n nMvt = k0lF.shape[0]\n UqYS = oyIN.matrix(oyIN.ones([nMvt, 1]))\n return [kwsU(UqYS)]\n else:\n DUUN = X1Lh(a1PO + 1)\n uQDy = DUUN[-1]\n if C3ST == 'multinomial':\n u8I7 = tjUW[:, nPrm[a1PO + 1]]\n elif C3ST... | [
"0.7448419",
"0.72255725",
"0.6892291",
"0.68610597",
"0.67443657",
"0.67273057",
"0.6708521",
"0.67026764",
"0.67013586",
"0.6697785",
"0.66734093",
"0.66536134",
"0.6596382",
"0.658845",
"0.65574497",
"0.6555254",
"0.6549357",
"0.65207744",
"0.6501759",
"0.648502",
"0.64431... | 0.67743987 | 4 |
Return value associated with key k (raise KeyError if not found). | def OP2O(YKHO, G1Hx):
for ZfUD in YKHO.table:
if G1Hx == ZfUD.key:
return ZfUD.value
raise KeyError('Key Error:' + repr(G1Hx)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def OP2O(YKHO, G1Hx):\n for ZfUD in YKHO._table:\n if G1Hx == ZfUD._key:\n return ZfUD._value\n raise KeyError('Key Error: ' + repr(G1Hx))",
"def OP2O(YKHO, G1Hx):\n d6pt = YKHO._find_index(G1Hx, 0, len(YKHO._table) - 1)\n if d6pt == len(YKHO._table) or YKHO._table[d6pt]._key != G1H... | [
"0.77852386",
"0.7721448",
"0.76335907",
"0.75866455",
"0.75510144",
"0.753669",
"0.74631864",
"0.74445117",
"0.7439949",
"0.72666925",
"0.7254503",
"0.72279835",
"0.7210008",
"0.71036285",
"0.708909",
"0.7035132",
"0.70042384",
"0.6996226",
"0.69920677",
"0.6901462",
"0.6856... | 0.77888364 | 0 |
Convert polar coordinates to spherical one. | def kIfH(YKHO, LTIa):
alpX, GOKz = YKHO.convert_to_polar_coordinates(LTIa)
a2wL = 0.5 * i912.cos(alpX) * i912.sin(GOKz)
IlO3 = 0.5 * i912.sin(alpX) * i912.sin(GOKz)
i_bJ = 0.5 * i912.cos(GOKz)
XBw5 = i912.transpose(i912.stack((a2wL, IlO3, i_bJ)))
return XBw5 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def inJp(YKHO):\n Mkmy, q7In, rVnq = YKHO.convert_spherical()\n return fA8r(Mkmy * P6bq.m, q7In * P6bq.rad, rVnq * P6bq.rad)",
"def inJp(YKHO):\n Mkmy, q7In, rVnq = YKHO.convert_spherical()\n return fA8r(Mkmy * P6bq.m, q7In * P6bq.rad, rVnq * P6bq.rad)",
"def o3nL(zKTJ):\n r1VO, zvTx, paov = zKT... | [
"0.7521395",
"0.7521395",
"0.7302678",
"0.7216729",
"0.7159992",
"0.71458167",
"0.7130875",
"0.7130711",
"0.70747",
"0.706106",
"0.7058674",
"0.70498407",
"0.7025458",
"0.69534945",
"0.6938088",
"0.689474",
"0.68912673",
"0.68765634",
"0.6849273",
"0.6848086",
"0.6843975",
... | 0.7364247 | 2 |
Convert polar coordinates to spherical one. | def eUEN(YKHO, LTIa):
rOEa, alpX = YKHO.convert_to_polar_coordinates(LTIa)
a2wL = rOEa * i912.cos(alpX)
IlO3 = rOEa * i912.sin(alpX)
GBvt = i912.transpose(i912.stack((a2wL, IlO3)))
return GBvt | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def inJp(YKHO):\n Mkmy, q7In, rVnq = YKHO.convert_spherical()\n return fA8r(Mkmy * P6bq.m, q7In * P6bq.rad, rVnq * P6bq.rad)",
"def inJp(YKHO):\n Mkmy, q7In, rVnq = YKHO.convert_spherical()\n return fA8r(Mkmy * P6bq.m, q7In * P6bq.rad, rVnq * P6bq.rad)",
"def kIfH(YKHO, LTIa):\n alpX, GOKz = YKH... | [
"0.7522786",
"0.7522786",
"0.73648846",
"0.7302247",
"0.72170335",
"0.7160685",
"0.7145915",
"0.7131552",
"0.7130532",
"0.70749646",
"0.7061133",
"0.70600176",
"0.7050152",
"0.70247924",
"0.69538337",
"0.6938552",
"0.6895378",
"0.68902516",
"0.6877116",
"0.6849513",
"0.684840... | 0.0 | -1 |
Recursively update a dict. Subdict's won't be overwritten but also updated. | def fqV4(eJh7, QdZT):
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def C09e(tbx9, sUFK):\n for G1Hx, Ty9i in sUFK.items():\n if isinstance(Ty9i, g760.Mapping):\n Mkmy = C09e(tbx9.get(G1Hx, {}), Ty9i)\n tbx9[G1Hx] = Mkmy\n else:\n tbx9[G1Hx] = sUFK[G1Hx]\n return tbx9",
"def zKHP(V_1d, zZcM):\n for H5ew, BWXx in zZcM.items(... | [
"0.82137895",
"0.81258094",
"0.8078184",
"0.80136293",
"0.80100954",
"0.80061454",
"0.7978325",
"0.7962203",
"0.79549694",
"0.79391754",
"0.7916863",
"0.78962374",
"0.7889317",
"0.78828114",
"0.78753465",
"0.78711414",
"0.7867503",
"0.7780948",
"0.77245355",
"0.7574689",
"0.7... | 0.71485704 | 37 |