query stringlengths 10 3.6k | document stringlengths 19 61.4k | metadata dict | negatives listlengths 0 101 | negative_scores listlengths 0 101 | document_score stringlengths 3 10 | document_rank stringclasses 102
values |
|---|---|---|---|---|---|---|
Return a queryset of with related fields. | def k66M(YKHO):
return YKHO.queryset().select_related('image').prefetch_related('authors', 'categories') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rEuK(YKHO, ihsR, xylm):\n xDcj = YKHO.model.objects.select_related(*ihsR) if len(ihsR) else YKHO.model.objects\n xDcj = xDcj.prefetch_related(*xylm) if len(xylm) else xDcj\n xDcj = xDcj.annotate(**YKHO.include)\n return xDcj",
"def tJ18(YKHO):\n Aofo = []\n if YKHO['name'] != None:\n ... | [
"0.69294244",
"0.6857692",
"0.6675372",
"0.66136235",
"0.6612176",
"0.6577206",
"0.6465894",
"0.6455258",
"0.6439515",
"0.6383593",
"0.6370642",
"0.63489354",
"0.6324296",
"0.62965614",
"0.62830126",
"0.6280996",
"0.62657833",
"0.6165763",
"0.61640686",
"0.61603105",
"0.61032... | 0.65834844 | 5 |
If the status of the entry is not PUBLISHED, a preview is requested, so we check if the user has the 'can_view_all' permission or if it's an author of the entry. | def AMX5(YKHO, SR0I=None):
umWR = SR0I or YKHO.get_queryset()
YEnM = Iofl(umWR, slug=YKHO.kwargs.get('slug', ''))
if YEnM.is_visible:
return YEnM
if YKHO.request.user not in [taDc for taDc in YEnM.authors.all()]:
for Uvf2 in YKHO.permissions_required:
if not YKHO.request.user... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def yg9t(CBIr):\n if CBIr.is_authenticated and CBIr.is_active and CBIr.is_staff:\n return True\n return False",
"def Qh7G(YKHO, CBIr):\n return CBIr.has_perm('agenda.can_see')",
"def KKMP(YKHO, CBIr):\n return True",
"def rjN5(YKHO, CBIr, XkTm, Slbv):\n if not XkTm.is_under_review():\n ... | [
"0.67526895",
"0.67521596",
"0.6556264",
"0.64143735",
"0.6413414",
"0.6313495",
"0.6304207",
"0.6300576",
"0.6267087",
"0.6242798",
"0.6203541",
"0.6121337",
"0.60879236",
"0.60814244",
"0.60723",
"0.60635877",
"0.60631686",
"0.6060827",
"0.6048731",
"0.60215795",
"0.6016981... | 0.0 | -1 |
Overridde the get_queryset method to do some validations and build the search queryset. | def k66M(YKHO):
VECZ = YKHO.model_cls.published.none()
if YKHO.request.GET:
YKHO.pattern = YKHO.request.GET.get('q', '')
if len(YKHO.pattern) < 3:
YKHO.error = bGrB('The pattern is too short')
else:
zt4Y = JZKz.parseString(YKHO.pattern)
VECZ = YKHO.mod... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def k66M(YKHO):\n umWR = super().get_queryset()\n HI6H = YKHO.request.GET.get('search_box')\n if HI6H is not None:\n umWR = umWR.search_by(HI6H)\n return umWR",
"def k66M(YKHO):\n umWR = super(XZMq, YKHO).get_queryset()\n umWR = YKHO.pre_search(umWR)\n if not YKHO.is_valid():\n ... | [
"0.809329",
"0.77335596",
"0.75037104",
"0.74745685",
"0.73438495",
"0.7299719",
"0.7280401",
"0.72262883",
"0.7217715",
"0.72121865",
"0.71623135",
"0.71607935",
"0.71605796",
"0.7157986",
"0.7138896",
"0.7138896",
"0.71294045",
"0.7039188",
"0.7032896",
"0.7026869",
"0.6999... | 0.0 | -1 |
Return pandas.DataFrame with filename data. | def bmW4(ABDL, sEAN='stage', mXDZ=None):
_PsJ = I3lW(ABDL, env=sEAN, pattern=mXDZ)
J6gM = []
for IznC in _PsJ:
if not ABDL == 'hk':
J6gM.append(sb8h(IznC))
else:
J6gM.append(o8xG(IznC))
jQ3Z = rLdf.DataFrame([IznC.as_series() for IznC in J6gM])
if ABDL != 'hk'... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _OdL(VqRE):\n I1iR = [qQXR.loads(eHNT) for eHNT in open(VqRE).readlines()]\n return rLdf.DataFrame(I1iR)",
"def _OdL(YKHO, MVVZ):\n gAll = {nUeQ.split('.')[0]: {'Date': nUeQ.split('.')[1], 'File': nUeQ} for nUeQ in MVVZ}\n jQ3Z = rLdf.DataFrame(gAll).T\n jQ3Z['Date'] = rLdf.to_datetime(jQ3Z['D... | [
"0.77002174",
"0.74857867",
"0.7412501",
"0.7384472",
"0.72650456",
"0.7207427",
"0.71808136",
"0.70936745",
"0.7061037",
"0.70224553",
"0.69458497",
"0.69425535",
"0.69010794",
"0.68461174",
"0.6835604",
"0.68334365",
"0.68062496",
"0.6785133",
"0.67844063",
"0.6783056",
"0.... | 0.0 | -1 |
Computes the backward pass for an affine layer. | def Kt1o(zYcP, wyyA):
WKvO, yzQ0, Fg_i = wyyA
Jw7X, ncXl, NCls = (None, None, None)
OOcW = WKvO.shape
XEYF = WKvO.reshape(OOcW[0], oyIN.prod(OOcW[1:]))
Jw7X = oyIN.dot(zYcP, yzQ0.T)
ncXl = oyIN.dot(XEYF.T, zYcP)
NCls = oyIN.sum(zYcP, axis=0)
Jw7X = Jw7X.reshape(OOcW)
return (Jw7X, nc... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wxmU(zYcP, wyyA):\n A45l, GhMp = wyyA\n SG6Y = fhcK.relu_backward(zYcP, GhMp)\n Jw7X, ncXl, NCls = fhcK.affine_backward(SG6Y, A45l)\n return (Jw7X, ncXl, NCls)",
"def Kt1o(zYcP, wyyA):\n WKvO, yzQ0, Fg_i = wyyA\n Jw7X, ncXl, NCls = (None, None, None)\n aWf9 = oyIN.prod(WKvO[0].shape)\n ... | [
"0.7518896",
"0.751513",
"0.7310849",
"0.73015374",
"0.73015374",
"0.73015374",
"0.73015374",
"0.7243401",
"0.7177609",
"0.7174102",
"0.7173503",
"0.71661735",
"0.71319",
"0.7106919",
"0.70978165",
"0.708432",
"0.7068546",
"0.70449376",
"0.70409757",
"0.6993727",
"0.6986414",... | 0.68831414 | 26 |
Computes the forward pass for a layer of rectified linear units (ReLUs). | def wN5Y(WKvO):
yvT9 = None
yvT9 = oyIN.maximum(0.0, WKvO)
wyyA = WKvO
return (yvT9, wyyA) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def drfk(YKHO):\n\n def XVC9(yR_P, g6LF, EYyA):\n \"\"\"\n If there is a negative gradient, change it to zero\n \"\"\"\n nWP1 = YKHO.forward_relu_outputs[-1]\n nWP1[nWP1 > 0] = 1\n e1d4 = nWP1 * ht2j.clamp(g6LF[0], min=0.0)\n del YKHO.forward_relu_outputs... | [
"0.67765754",
"0.6630487",
"0.6603554",
"0.6524658",
"0.65097666",
"0.64478433",
"0.6385381",
"0.62672025",
"0.62047166",
"0.6179713",
"0.61535424",
"0.61385596",
"0.6061572",
"0.6055216",
"0.6048094",
"0.6047937",
"0.6018342",
"0.59974337",
"0.59908754",
"0.59696555",
"0.596... | 0.0 | -1 |
Computes the backward pass for a layer of rectified linear units (ReLUs). | def PPFh(zYcP, wyyA):
Jw7X, WKvO = (None, wyyA)
Jw7X = zYcP
zYcP[WKvO <= 0] = 0.0
return Jw7X | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def PPFh(YKHO, gEpz, wyyA):\n WKvO = wyyA\n WKvO = oyIN.array(WKvO, copy=True)\n WKvO[WKvO <= 0] = 0\n WKvO[WKvO > 0] = 1\n cf5c = gEpz * WKvO\n return cf5c",
"def ZD5u(OaeV, pwN3):\n N77f, lQ3t, P6bq, OCi3 = OaeV.saved_tensors\n begE = P6bq.device\n SGf8 = 1e-10\n Ro40, = ht2j.auto... | [
"0.70408076",
"0.69492865",
"0.6897997",
"0.6847812",
"0.6847812",
"0.6847714",
"0.6841497",
"0.68197685",
"0.67684674",
"0.6757756",
"0.67559105",
"0.6755458",
"0.67431223",
"0.6740171",
"0.6716221",
"0.67097867",
"0.6700681",
"0.6697073",
"0.6697073",
"0.6688005",
"0.666655... | 0.65111107 | 44 |
A naive implementation of the forward pass for a max pooling layer. | def gORb(WKvO, cjPb):
ywwl, Nq1b, C7Ls, XcU5 = WKvO.shape
ZdOB = cjPb['pool_height']
dvGM = cjPb['pool_width']
_0fC = cjPb['stride']
lo2K = (C7Ls - ZdOB) / _0fC + 1
aZiX = (XcU5 - dvGM) / _0fC + 1
yvT9 = oyIN.random.randn(ywwl, Nq1b, lo2K, aZiX)
for YRbF in Ni9Y(ywwl):
for Z9rn i... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gORb(WKvO, cjPb):\n yvT9 = None\n ywwl, Nq1b, C7Ls, XcU5 = WKvO.shape\n dvGM = cjPb['pool_width']\n ZdOB = cjPb['pool_height']\n _0fC = cjPb['stride']\n nAIO = int((XcU5 - dvGM) / _0fC + 1)\n Ya8v = int((C7Ls - ZdOB) / _0fC + 1)\n yvT9 = oyIN.zeros((ywwl, Nq1b, Ya8v, nAIO))\n for YRb... | [
"0.8176104",
"0.7984787",
"0.7854871",
"0.76688087",
"0.763123",
"0.75106704",
"0.7398416",
"0.73303866",
"0.7267503",
"0.7173863",
"0.7142943",
"0.7042369",
"0.70236975",
"0.7022948",
"0.696239",
"0.68989724",
"0.689837",
"0.68944407",
"0.6884486",
"0.6883826",
"0.688134",
... | 0.7866907 | 2 |
NOT USED FOR ASSIGNMENT_07 Returns a dict containing information about customers who have rented a product based on the provided product_id. | def wB74(Mc9N):
styl = {}
try:
with ufJ1:
cKaD = ufJ1.connection.assignment_07
by8Z = cKaD.rental.aggregate([{'$lookup': {'from': 'customer', 'localField': 'user_id', 'foreignField': 'user_id', 'as': 'customer_rentals'}}, {'$match': {'product_id': Mc9N}}])
except TypeError as... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def t0Dr(Mc9N):\n bo34.info(f'Perparing rental dict for product_id: {Mc9N}...')\n NBgo = []\n with ufJ1:\n _ig9 = eval(hp1l.connect_string)\n AXEx = _ig9['rental']\n ugMh = _ig9['customers']\n xDcj = {'product_id': Mc9N}\n for LcUJ in AXEx.find(xDcj):\n xDcj =... | [
"0.7795496",
"0.7388176",
"0.72028625",
"0.685471",
"0.6852489",
"0.63175374",
"0.5973188",
"0.5707278",
"0.55884176",
"0.55630213",
"0.55298024",
"0.552132",
"0.5489038",
"0.54152846",
"0.5413372",
"0.53690314",
"0.53402364",
"0.53297937",
"0.5327381",
"0.5304467",
"0.519002... | 0.76678 | 1 |
Returns a list of subscription from self This is the list of clients you want to push to | def eAqE(YKHO):
return YKHO._roster.get_my_subscriptions() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VOru(YKHO, zb3C):\n return YKHO.hub.get_subscriptions(YKHO.get_private_key(), zb3C)",
"def VOru(YKHO):\n bD7m = '{}/v2/subscriptions'.format(YKHO.url)\n Mkmy = G4JS.get(bD7m, headers=YKHO.headers_v2)\n return Mkmy.json()",
"def VOru(YKHO):\n return YKHO.subscriptions.all()",
"def VOru(YKHO... | [
"0.75346535",
"0.74282503",
"0.7373272",
"0.72040546",
"0.7200954",
"0.71670425",
"0.714462",
"0.7103709",
"0.70590115",
"0.70528764",
"0.70007014",
"0.69982475",
"0.69904065",
"0.6983954",
"0.69731414",
"0.6959992",
"0.6929606",
"0.69161993",
"0.6878904",
"0.68626046",
"0.68... | 0.7015008 | 10 |
Calculate maximum value and units for axes | def vxX5(YKHO):
TKGt, wmQo = YKHO._get_extremes()
YKHO.y_axis.min = TKGt
YKHO.y_axis.max = wmQo
YKHO.y_axis._max_min()
if not None in [KCHu.xvalues for KCHu in YKHO]:
TKGt, wmQo = YKHO._get_extremes('xvalues')
YKHO.x_axis.min = TKGt
YKHO.x_axis.max = wmQo
YKHO.x_axis.... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rwK9(YKHO):\n return YKHO.get_max_value(YKHO.Y_INDEX)",
"def rwK9(YKHO) -> _ABP.FloatingValue:\n return IPme.GeoYMax(YKHO).to_expr()",
"def c4gB(YKHO):\n return max((YKHO(0).y, 0), (YKHO(1).y, 1))[1]",
"def zt1J(YKHO):\n return YKHO.__maxx",
"def QlQI(YKHO, wl_9, BWXx):\n if wl_9 in YKHO... | [
"0.68784446",
"0.6845525",
"0.6694852",
"0.66816413",
"0.6577773",
"0.6567726",
"0.655792",
"0.65421635",
"0.6515711",
"0.6503462",
"0.6477138",
"0.64684176",
"0.6414913",
"0.6398861",
"0.63963366",
"0.63290495",
"0.6316894",
"0.6316176",
"0.6298949",
"0.6268864",
"0.62591434... | 0.6087633 | 33 |
Calculate the maximum and minimum values of all series for an axis 'values' for columns 'xvalues for rows | def weJV(YKHO, hkS8='values'):
sN3Z = [0]
Rq6T = [0]
for KCHu in YKHO:
if KCHu is not None:
sN3Z.append(KCHu.max(hkS8))
Rq6T.append(KCHu.min(hkS8))
return (min(Rq6T), max(sN3Z)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ipRy(jQ3Z):\n Np5D, T8H5 = (jQ3Z.max(axis=0), jQ3Z.min(axis=0))\n B3YC = (Np5D + T8H5) / 2\n wjxF = (Np5D - T8H5) / 2\n return (jQ3Z - B3YC) / wjxF",
"def EFA2(YKHO):\n return YKHO.xvar.minmax()",
"def vxX5(YKHO):\n TKGt, wmQo = YKHO._get_extremes()\n YKHO.y_axis.min = TKGt\n YKHO.y... | [
"0.66076225",
"0.6471945",
"0.6391276",
"0.63118863",
"0.63118863",
"0.6278994",
"0.62640023",
"0.6240948",
"0.61388075",
"0.6135382",
"0.60807997",
"0.60373276",
"0.60211396",
"0.599636",
"0.59920996",
"0.59727955",
"0.59036803",
"0.5894996",
"0.5865304",
"0.5854356",
"0.584... | 0.67006063 | 0 |
Render index.html. Initialization is performed asynchronously in initialize() function | def F_xU():
return TvZl('index.html', token=iCQW.token) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def b8V_():\n return TvZl('index.html')",
"def b8V_():\n return TvZl('index.html')",
"def d6pt():\n return TvZl('index.html')",
"def d6pt():\n return TvZl('index.html')",
"def d6pt(YKHO):\n return TvZl('main/index.html')",
"def d6pt():\n return TvZl('index.html')",
"def d6pt(YKHO):\n ... | [
"0.75924486",
"0.75924486",
"0.7591326",
"0.7551682",
"0.75433177",
"0.75417954",
"0.7518462",
"0.75141764",
"0.75141764",
"0.74949324",
"0.74949324",
"0.74817026",
"0.7464088",
"0.7463117",
"0.74486864",
"0.7441125",
"0.7441125",
"0.7441125",
"0.7441125",
"0.7441125",
"0.744... | 0.0 | -1 |
Return left most child of node | def XNuE(exwG):
if exwG == None:
return None
while exwG.left:
exwG = exwG.left
return exwG | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fwcI(YKHO):\n if YKHO.left_child == None:\n return YKHO\n else:\n return YKHO.left_child.get_leftmost_child()",
"def cdj0(YKHO, dQgj):\n aUGN = 2 * dQgj + 1\n if aUGN > len(YKHO.table) - 1:\n return None\n return aUGN",
"def cdj0(YKHO, oeNL):\n return 2 * oeNL",
"de... | [
"0.8373466",
"0.8092487",
"0.7894623",
"0.78901035",
"0.78861636",
"0.7878979",
"0.77989924",
"0.77989924",
"0.77493393",
"0.7655658",
"0.7477981",
"0.74518734",
"0.73323846",
"0.7313927",
"0.7293937",
"0.72797036",
"0.72629493",
"0.7237921",
"0.722071",
"0.72177696",
"0.7172... | 0.81857544 | 1 |
Get all squares that the piece is allowed to move to. | def QOdN(YKHO, iBIi):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def m0ig(YKHO):\n cZjl = []\n for WKvO in range(8):\n for LVAh in range(8):\n if YKHO.squares[WKvO][LVAh].piece and YKHO.squares[WKvO][LVAh].piece.color != YKHO.turn:\n y4m8 = YKHO.squares[WKvO][LVAh].piece.actions(YKHO, (WKvO, LVAh), True)\n if YKHO.squares[WK... | [
"0.76842695",
"0.7368328",
"0.7188977",
"0.71851486",
"0.7123327",
"0.6980735",
"0.6973738",
"0.69532406",
"0.68959486",
"0.6884979",
"0.6863356",
"0.6856457",
"0.68420833",
"0.6835366",
"0.68254775",
"0.6800773",
"0.6796985",
"0.6759987",
"0.66899514",
"0.66875696",
"0.66840... | 0.5999273 | 84 |
takes a df and a column label and graphs the distribution (continuous) for display | def THiq(jQ3Z, UXqs):
uuEx.set(style='white', palette='pastel')
LZpg, MPlV = QrM1.subplots(2, 1, figsize=(6, 6))
MPlV[1].get_shared_x_axes().join(MPlV[1], MPlV[0])
MPlV[1].set_aspect(aspect=25)
uuEx.distplot(jQ3Z[UXqs], ax=MPlV[0], kde=False, norm_hist=False, color='teal')
uuEx.boxplot(data=jQ3Z... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Di6E(jQ3Z, iVRZ='', leAC='', co3n=2, zURN=None):\n xJ2h = iEax.Box(y=jQ3Z[iVRZ], name='Box')\n ojtC = iEax.Histogram(x=jQ3Z[iVRZ], name='x')\n LZpg = bWeC.make_subplots(rows=1, cols=co3n)\n LZpg.append_trace(xJ2h, 1, 1)\n LZpg.append_trace(ojtC, 1, 2)\n LZpg['layout'].update(height=300, title... | [
"0.7023969",
"0.6924712",
"0.68914557",
"0.6811562",
"0.6736705",
"0.6688884",
"0.6558738",
"0.65332896",
"0.65221244",
"0.6514445",
"0.6382259",
"0.6260457",
"0.6255712",
"0.6186859",
"0.61838603",
"0.61682355",
"0.6149696",
"0.6143714",
"0.61169505",
"0.6096046",
"0.6086158... | 0.6594989 | 6 |
Deterministic string representation of the API instance for etag_cache. | def wHJl(YKHO) -> str:
return f'Superset.tags.api.TagRestApi@v{YKHO.appbuilder.app.config['VERSION_STRING']}{YKHO.appbuilder.app.config['VERSION_SHA']}' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BMqV(YKHO):\n return ''",
"def ajCK(YKHO) -> qe4Y.Output[str]:\n return qe4Y.get(YKHO, 'etag')",
"def ajCK(YKHO) -> qe4Y.Output[str]:\n return qe4Y.get(YKHO, 'etag')",
"def ajCK(YKHO) -> qe4Y.Output[str]:\n return qe4Y.get(YKHO, 'etag')",
"def ajCK(YKHO) -> qe4Y.Output[str]:\n return qe4... | [
"0.7271256",
"0.7237793",
"0.7237793",
"0.7237793",
"0.7237793",
"0.7237793",
"0.7237793",
"0.7237793",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.7158001",
"0.6865036",
"0.6862543",
"... | 0.6192034 | 55 |
Returns the derivative of x^2 (2x) at the input. | def VS3m(WKvO):
return 2 * WKvO | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eGBw(YKHO, WKvO, WbhW=None):\n return 2 * kLQb(-WKvO ** 2) / PZyS(mM0K)",
"def VVyp(Y7fn, WKvO, LVAh):\n O5iP = (Y7fn - WKvO[1] + (Y7fn - WKvO[2])) / ((WKvO[0] - WKvO[1]) * (WKvO[0] - WKvO[2])) * LVAh[0] + (Y7fn - WKvO[0] + (Y7fn - WKvO[2])) / ((WKvO[1] - WKvO[0]) * (WKvO[1] - WKvO[2])) * LVAh[1] + (Y7... | [
"0.7365888",
"0.70614064",
"0.68726707",
"0.66712064",
"0.6648913",
"0.66283107",
"0.65764946",
"0.6571925",
"0.6523418",
"0.6518763",
"0.64251024",
"0.6420016",
"0.6417492",
"0.6384178",
"0.6384178",
"0.63834196",
"0.63289374",
"0.6325209",
"0.6280928",
"0.6278116",
"0.62667... | 0.7727061 | 0 |
Can set an initial value | def mV0F(YKHO):
YKHO.assertIsNotNone(D2Uy(YKHO.node.name, YKHO.node)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def N8Fv(YKHO, BWXx):\n pass",
"async def set_init(YKHO, BWXx: int | float) -> bool:\n return await YKHO.set_value(BWXx, True)",
"def gKOw(YKHO, *qIxc):\n return _VfD.Trigger_setInitialValue(YKHO, *qIxc)",
"def UXGE(YKHO):\n YKHO.setValue(YKHO.default_value)",
"def N8Fv(YKHO, _J6_):\n YKHO.i... | [
"0.74489254",
"0.73642826",
"0.729574",
"0.71966565",
"0.71024",
"0.7064471",
"0.6984856",
"0.69269264",
"0.6819281",
"0.68124104",
"0.6798877",
"0.6793031",
"0.6787336",
"0.6781171",
"0.67532694",
"0.672437",
"0.6709393",
"0.6669517",
"0.66654336",
"0.6660875",
"0.65987414",... | 0.0 | -1 |
Calculates accuracy between truth labels and predictions. | def Y5Qs(Y8eF, aMgO):
gXXc = ht2j.eq(Y8eF, aMgO).sum().item()
YAq3 = gXXc / len(aMgO) * 100
return YAq3 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vjyh(aTLP, Crrw):\n gXXc = aTLP == Crrw\n return gXXc.sum().float() / gXXc.shape[0]",
"def vjyh(Crrw, N6Z1, TFPw):\n b0wT = ZylS.equal(x=N6Z1, y=Crrw)\n return ZylS.reduce_mean(ZylS.cast(b0wT, ZylS.float32))",
"def vjyh(N6Z1, s8RJ):\n return CCGu(s8RJ, N6Z1, average='micro') * 100",
"def v... | [
"0.87130684",
"0.8674318",
"0.86644745",
"0.854912",
"0.8523707",
"0.8471912",
"0.84568554",
"0.8359756",
"0.8356954",
"0.8356954",
"0.8336963",
"0.8286955",
"0.823785",
"0.8215967",
"0.8213891",
"0.82086533",
"0.81754017",
"0.8170142",
"0.8160432",
"0.8146372",
"0.81450003",... | 0.80693346 | 23 |
Makes a prediction on a target image with a trained model and plots the image. | def gGag(C3ST: torch.nn.Module, QMAG: str, tGDF: List[str]=None, SZFh=None, begE: torch.device='cuda' if ht2j.cuda.is_available() else 'cpu'):
raOl = TTda.io.read_image(str(QMAG)).type(ht2j.float32)
raOl = raOl / 255.0
if SZFh:
raOl = SZFh(raOl)
C3ST.to(begE)
C3ST.eval()
with ht2j.infere... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BJwj(QMAG, C3ST, u6fe=True):\n obA2, vmpX = WIpT(QMAG)\n N6Z1 = C3ST.predict(vmpX)\n o3Uj = YAZl.CLASS_NAMES[oyIN.argmax(N6Z1)]\n if u6fe:\n QrM1.imshow(obA2)\n QrM1.title(o3Uj)\n QrM1.axis('off')\n QrM1.show()\n return print(f'Predictiona: {o3Uj}')\n else:\n ... | [
"0.73935586",
"0.7305404",
"0.73018754",
"0.72295403",
"0.72130954",
"0.7087915",
"0.70708907",
"0.7033366",
"0.7011689",
"0.69591796",
"0.695727",
"0.6886043",
"0.6883472",
"0.68523306",
"0.6839481",
"0.68180704",
"0.68079",
"0.6800002",
"0.6764993",
"0.6712348",
"0.6710486"... | 0.7004525 | 9 |
Initialize Conversation objects from utterances and conversations metadata | def r_W4(rrSk, VDnN, lzTP):
Rbcl = oRi_(list)
for P6bq in VDnN.values():
W3PT = P6bq.root
Rbcl[W3PT].append(P6bq.id)
_pwN = {}
for zmV6 in Rbcl:
UGqp = lzTP.get(zmV6, None)
p1wE = n9Bx(owner=rrSk, id=zmV6, utterances=Rbcl[zmV6], meta=UGqp)
_pwN[zmV6] = p1wE
re... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eTRn(rrSk, VDnN, Ikh1, b6vO, g5mS):\n if len(Ikh1) > 0:\n Z729 = 'user' if 'user' in Ikh1[0] else 'speaker'\n for YRbF, P6bq in enumerate(Ikh1):\n P6bq = oRi_(lambda: None, P6bq)\n hIZ_ = P6bq[Z729]\n if hIZ_ not in b6vO:\n b6vO[hIZ_] = xyOc(owner=rrSk, id=P6bq[Z729... | [
"0.64719737",
"0.6312043",
"0.5735298",
"0.5610898",
"0.55534637",
"0.53624684",
"0.5338579",
"0.52947074",
"0.52843666",
"0.52603316",
"0.52556956",
"0.51028484",
"0.50719315",
"0.50575566",
"0.50543827",
"0.50524753",
"0.49875817",
"0.49830174",
"0.49307454",
"0.49234688",
... | 0.73922026 | 0 |
Add an element to the right side of the deque. | def SStx(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def i6Ec(YKHO, ZfUD):\n Z8g1 = o7DN(ZfUD)\n Z8g1.set_prev(YKHO.tail)\n if not YKHO.head:\n YKHO.head = Z8g1\n else:\n YKHO.tail.set_next(Z8g1)\n YKHO.tail = Z8g1\n YKHO.size += 1",
"def _tIi(YKHO, _tIi):\n YKHO.ptr.right(_tIi)",
"def qG47(YKHO, XP5J, tTpl):\n Q6kx = YKHO._... | [
"0.7211239",
"0.6879419",
"0.68729764",
"0.67506486",
"0.6747833",
"0.6699432",
"0.66625094",
"0.6488386",
"0.6420433",
"0.63702494",
"0.6360207",
"0.61647016",
"0.61568594",
"0.61564976",
"0.6152562",
"0.61409235",
"0.6139617",
"0.6115813",
"0.6100973",
"0.6063185",
"0.60482... | 0.0 | -1 |
Add an element to the left side of the deque. | def rwLV(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QbC9(YKHO, ZfUD):\n Z8g1 = o7DN(ZfUD)\n Z8g1.set_next(YKHO.head)\n if not YKHO.tail:\n YKHO.tail = Z8g1\n else:\n YKHO.head.set_prev(Z8g1)\n YKHO.head = Z8g1\n YKHO.size += 1",
"def LFlW(YKHO, LFlW):\n YKHO.ptr.left(LFlW)",
"def rwLV(YKHO, ZfUD):\n X1Cd = o7DN(ZfUD, YK... | [
"0.7578942",
"0.72930163",
"0.7192541",
"0.7124159",
"0.69704235",
"0.6962643",
"0.691528",
"0.6893327",
"0.6889453",
"0.6862317",
"0.68484277",
"0.68254745",
"0.68217516",
"0.6815901",
"0.678616",
"0.67832494",
"0.6776716",
"0.6770491",
"0.6747985",
"0.6660849",
"0.6660849",... | 0.6691957 | 19 |
Return a shallow copy of a deque. | def jth9(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def x_Tf():\n from deque import Deque\n yDQN = Deque()\n return yDQN",
"def jth9(YKHO):\n return jth9.deepcopy(YKHO)",
"def _qLf(YKHO):\n return YKHO.copy()",
"def d3pW():\n from deque import Deque\n JhGC = Deque(iterable=[1, 2, 3])\n return JhGC",
"def jth9(YKHO):\n piAD = _qLf(... | [
"0.6349479",
"0.6222582",
"0.6202566",
"0.61991954",
"0.61713153",
"0.6131602",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61220014",
... | 0.0 | -1 |
D.index(value, [start, [stop]]) > integer return first index of value. Raises ValueError if the value is not present. | def d6pt(YKHO, BWXx, yKcO=None, JCyR=None):
return 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def d6pt(YKHO, BWXx, yKcO=0, JCyR=-1):\n return YKHO.elem.index(BWXx, yKcO, JCyR)",
"def d6pt(YKHO, U6D_, yKcO=0, Os4s=None):\n if Os4s is None:\n Os4s = YKHO._length\n if Os4s < 0:\n Os4s = YKHO._convert_negative_index(Os4s)\n yKcO = min(YKHO._length, max(0, yKcO))\n Os4s = min(YKHO... | [
"0.7962",
"0.6861745",
"0.6848216",
"0.68206054",
"0.66506827",
"0.6420335",
"0.6407462",
"0.6382083",
"0.6328646",
"0.62298006",
"0.62259185",
"0.62259185",
"0.6210666",
"0.6164073",
"0.61577684",
"0.61506253",
"0.61481315",
"0.61431164",
"0.6141292",
"0.6053241",
"0.602599"... | 0.76280576 | 1 |
Remove and return the rightmost element. | def BEuN(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FKg7(YKHO):\n if YKHO.length > 0:\n return YKHO.container.pop()\n else:\n return None",
"def BEuN(YKHO):\n return YKHO.popleft()",
"def Tvdt(YKHO):\n if YKHO.right_child == None:\n return YKHO\n else:\n return YKHO.right_child.get_rightmost_child()",
"def LDrE(Y... | [
"0.73805934",
"0.73023766",
"0.723817",
"0.7237201",
"0.72228837",
"0.70214623",
"0.6952377",
"0.69155926",
"0.69030625",
"0.6889738",
"0.68426186",
"0.6801426",
"0.67690605",
"0.67616796",
"0.6740858",
"0.67065924",
"0.66904616",
"0.66624075",
"0.66527665",
"0.66457117",
"0.... | 0.0 | -1 |
Remove and return the leftmost element. | def ITjG(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ITjG(YKHO):\n try:\n return YKHO._values.shift()\n except IndexError:\n raise IndexError('Cannot popleft from empty deque.')",
"def ITjG(YKHO):\n BWXx = YKHO.buffer[YKHO.start]\n YKHO.buffer[YKHO.start] = None\n YKHO.start = (YKHO.start + 1) % len(YKHO.buffer)\n return BWXx",
... | [
"0.7609626",
"0.75820863",
"0.7551782",
"0.741619",
"0.72918886",
"0.72882265",
"0.7263307",
"0.7103135",
"0.70737004",
"0.70367336",
"0.69823164",
"0.6924246",
"0.69142276",
"0.6897082",
"0.6897082",
"0.68950117",
"0.6892438",
"0.68749774",
"0.6861141",
"0.68471754",
"0.6830... | 0.68395156 | 20 |
Rotate the deque n steps to the right (default n=1). If n is negative, rotates left. | def N0Pp(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def N0Pp(vC9B, exwG=1):\n return vC9B[exwG:] + vC9B[:exwG]",
"def N0Pp(vC9B, exwG):\n return vC9B[exwG:] + vC9B[:exwG]",
"def N0Pp(vC9B, exwG):\n return vC9B[exwG:] + vC9B[:exwG]",
"def xCBs(WKvO, exwG):\n return oLG2.roll(WKvO, exwG)",
"def N0Pp(vC9B: list, exwG: int) -> list:\n return vC9B... | [
"0.7280998",
"0.7242433",
"0.7242433",
"0.72422236",
"0.688598",
"0.6872007",
"0.65214753",
"0.62785167",
"0.6202677",
"0.6085774",
"0.6080543",
"0.60671383",
"0.60642844",
"0.60639775",
"0.60504407",
"0.6032023",
"0.603172",
"0.60310507",
"0.6016403",
"0.597926",
"0.59378105... | 0.0 | -1 |
Return a shallow copy of a deque. | def FzJk(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def x_Tf():\n from deque import Deque\n yDQN = Deque()\n return yDQN",
"def jth9(YKHO):\n return jth9.deepcopy(YKHO)",
"def _qLf(YKHO):\n return YKHO.copy()",
"def d3pW():\n from deque import Deque\n JhGC = Deque(iterable=[1, 2, 3])\n return JhGC",
"def jth9(YKHO):\n piAD = _qLf(... | [
"0.6349479",
"0.6222582",
"0.6202566",
"0.61991954",
"0.61713153",
"0.6131602",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61279",
"0.61220014",
... | 0.0 | -1 |
Move an existing element to the end (or beginning if last==False). Raises KeyError if the element does not exist. When last=True, acts like a fast version of self[key]=self.pop(key). | def ft4c(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def BEuN(YKHO, XVAW=True):\n if not YKHO:\n raise KeyError('set is empty')\n H5ew = reversed(YKHO).next() if XVAW else iter(YKHO).next()\n YKHO.discard(H5ew)\n return H5ew",
"def NpNj(YKHO, H5ew, BWXx):\n try:\n BWXx = YKHO.pop(H5ew)\n except KeyError:\n if len(YKHO) >= YKH... | [
"0.6572634",
"0.6126293",
"0.5957631",
"0.59374195",
"0.5841973",
"0.5804189",
"0.57495236",
"0.5743748",
"0.5637006",
"0.56087834",
"0.5578949",
"0.5516298",
"0.54809946",
"0.5474769",
"0.54682726",
"0.54682726",
"0.54430443",
"0.5415699",
"0.54154366",
"0.54134846",
"0.5402... | 0.0 | -1 |
Return repr for the module. The method is deprecated. The import machinery does the job itself. | def NlD_(yR_P):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NlD_(*qIxc, **YSA3):\n pass",
"def wHJl(YKHO) -> str:\n return f'<Module[{YKHO.path}]>'",
"def wHJl(YKHO):\n Rci7 = hkS8(YKHO, '__spec__.origin', '__file__', '__package__')\n mWFP = hkS8(YKHO, '__name__', 'name')\n QNO6 = oeVg(YKHO, PkNZ) and 'class-module' or 'module'\n yvT9 = f'<{QNO6} ... | [
"0.77780753",
"0.75000393",
"0.7397742",
"0.6893594",
"0.6770432",
"0.65819037",
"0.65785617",
"0.6530933",
"0.65229046",
"0.64664763",
"0.6382374",
"0.6342514",
"0.63051796",
"0.6303653",
"0.6292959",
"0.62465495",
"0.6232956",
"0.61731946",
"0.6146407",
"0.6121847",
"0.6023... | 0.8110311 | 2 |
Calculate pressure at specified loading. The Virial model calculates the pressure directly. | def CJ2p(YKHO, UQjK):
return UQjK * XTiz.exp(-XTiz.log(YKHO.params['K']) + YKHO.params['A'] * UQjK + YKHO.params['B'] * UQjK ** 2 + YKHO.params['C'] * UQjK ** 3) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def CJ2p(YKHO, UQjK):\n return UQjK / (YKHO.params['K'] * (YKHO.params['n_m'] - UQjK))",
"def UQjK(YKHO, CJ2p):\n iZHj = YKHO.params['K'] * CJ2p\n return YKHO.params['n_m'] * iZHj / (1.0 + iZHj)",
"def UQjK(YKHO, CJ2p):\n\n def MCGS(WKvO):\n return (YKHO.pressure(WKvO) - CJ2p) ** 2\n V5ju... | [
"0.82703584",
"0.68636125",
"0.6701423",
"0.6674728",
"0.646471",
"0.62407786",
"0.62407786",
"0.62407786",
"0.6091799",
"0.6011328",
"0.6011328",
"0.5980501",
"0.5977851",
"0.5957151",
"0.59392357",
"0.58457243",
"0.5834206",
"0.5801399",
"0.57670504",
"0.5747486",
"0.572263... | 0.7911134 | 1 |
Returns the index of the given start date. Subclasses should define default behavior for start = None. That isn't handled here. Start can be a string or an integer if self.data.dates is None. | def z0bI(YKHO, yKcO):
YdD0 = YKHO.data.dates
if isinstance(yKcO, str):
if YdD0 is None:
raise ValueError('Got a string for start and dates is None')
fg5K = YKHO._str_to_date(yKcO)
YKHO.data.predict_start = fg5K
try:
yKcO = YKHO._get_dates_loc(YdD0, fg5K)
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def d6pt(YKHO, BWXx: Any, yKcO: int=0, JCyR: int=9223372036854775807) -> int:\n if isinstance(BWXx, str):\n BWXx = getattr(YKHO, BWXx)\n return super().index(BWXx, yKcO, JCyR)",
"def WXb2(Nqlg, gepq, eiFi):\n if gepq > eiFi:\n raise RuntimeError('start date must be earlier than end date')\... | [
"0.6237462",
"0.6043197",
"0.6005817",
"0.59620655",
"0.5915492",
"0.58372396",
"0.5765468",
"0.57453346",
"0.5734087",
"0.57179147",
"0.5700057",
"0.56639326",
"0.56639326",
"0.5638481",
"0.5627662",
"0.56263804",
"0.5608273",
"0.5594991",
"0.5594771",
"0.5572557",
"0.554843... | 0.61722726 | 1 |
Renormalize so that the peak is at a value of unity and the minimum value is zero. | def X8dm(YKHO):
YKHO.data -= YKHO.data.min()
YKHO.data /= YKHO.data.max()
return YKHO | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZhUX(YKHO):\n PyDY = 0\n z5Xd = 1e+99\n for exwG in YKHO.graph:\n if exwG.flux > PyDY:\n PyDY = exwG.flux\n if exwG.flux < z5Xd:\n z5Xd = exwG.flux\n for exwG in YKHO.graph:\n exwG.flux = (exwG.flux - z5Xd) / (PyDY - z5Xd)",
"def pmQu(EcVT):\n EcVT = ... | [
"0.7011616",
"0.69631946",
"0.67227876",
"0.6571013",
"0.65204656",
"0.65025663",
"0.6429963",
"0.6407749",
"0.63928366",
"0.63769186",
"0.6375997",
"0.6359423",
"0.6350038",
"0.634922",
"0.63451254",
"0.63389987",
"0.6326537",
"0.63177603",
"0.62938243",
"0.6293164",
"0.6281... | 0.63666284 | 11 |
Create a new ConvolutionEngine. This object is used to perform the convolution of two things, the instance should be discarded after doing so. | def FIMM(YKHO, dg7v, iYf1=None, xcGI=(abs,), T8ck=2, prgu='linear_ramp'):
YKHO.c1 = dg7v
YKHO.c2 = iYf1
YKHO.spatial_finalization = xcGI
YKHO.Q = T8ck
YKHO.pad_method = prgu
YKHO.spatial_x = None
YKHO.spatial_y = None
YKHO.spatial_data = None
YKHO.kspace_x = None
YKHO.kspace_y = ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def yIp6(YKHO, Elif):\n tTpl = OWo1(YKHO, Elif)\n return tTpl.fire()",
"def P79G(YKHO, Elif, Tuqy='full'):\n if not YKHO.compatible(Elif):\n raise ValueError('{} instances must be compatible (have bins of equal size and shape) to compute a convolution-matching instance'.format(YKHO.__class__.__na... | [
"0.7475505",
"0.6174127",
"0.6107349",
"0.6016498",
"0.60063165",
"0.59907496",
"0.58912903",
"0.58325094",
"0.56420857",
"0.55642307",
"0.5531239",
"0.5506164",
"0.5476493",
"0.5464612",
"0.5434323",
"0.5413375",
"0.54105914",
"0.54087013",
"0.5408339",
"0.54005736",
"0.5334... | 0.0 | -1 |
check_extent() > None Makes sure left limit is less than right limit, and lower limit is less than upper limit. In other words, ensures that, immediately after the | def sigR(YKHO):
if YKHO.lower_left.x > YKHO.upper_right.x:
QwYt = YKHO.lower_left.x
YKHO.lower_left.x = YKHO.upper_right.x
YKHO.upper_right.y = QwYt
if YKHO.lower_left.y > YKHO.upper_right.y:
D0Ie = YKHO.lower_left.y
YKHO.lower_left.y = YKHO.upper_right.y
YKHO.upp... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Pxfb(YKHO, BWXx, aO5V):\n assert aO5V == 0 or aO5V == 1\n if aO5V == 0:\n assert BWXx >= 0 and BWXx < YKHO.w\n else:\n assert BWXx >= 0 and BWXx < YKHO.h",
"def GfdN(YKHO):\n YKHO.lower_bound(0.0005)\n YKHO.upper_bound(500.0)",
"def wSU0(WKvO, LVAh, yzQ0, MKlR, nvGN, dzj5):\n ... | [
"0.6588729",
"0.6540092",
"0.6471849",
"0.64596236",
"0.64591676",
"0.63633776",
"0.6347359",
"0.62776583",
"0.62022114",
"0.6195664",
"0.61871344",
"0.6115332",
"0.6110427",
"0.610017",
"0.60153145",
"0.6003828",
"0.6001943",
"0.6001682",
"0.5999328",
"0.59796566",
"0.596419... | 0.78591186 | 0 |
K correction factor to take into account tidal influences of the host star on the planetary atmosphere (from Erkaev et al. 2007). | def p1Na(pZOX, BJ28, ExrV, xMZ1):
XqV_ = PtXs.au.cgs.value
dv_w = PtXs.M_sun.cgs.value
Z01g = PtXs.M_earth.cgs.value
asqo = PtXs.R_earth.cgs.value
if type(BJ28) == float or type(BJ28) == oyIN.float64:
MO7a = pZOX * XqV_ * (BJ28 * Z01g / (3 * (ExrV * dv_w))) ** (1.0 / 3)
nMvt = 1.0 - ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def R7OK(YKHO):\n YKHO.k = -oyIN.array([YKHO.sth * YKHO.cphi, YKHO.sth * YKHO.sphi, YKHO.cth])\n return",
"def RihL(S0LS):\n return 5.0 / 9.0 * (S0LS + 459.67)",
"def eHNT(G1Hx):\n return G1Hx * G1Hx * G1Hx * G1Hx * _sei(G1Hx, Us3Y) * rmEC(0, G1Hx * Mkmy)",
"def eHNT(G1Hx):\n return G1Hx * G1H... | [
"0.69367003",
"0.6742401",
"0.6543646",
"0.65199226",
"0.6505585",
"0.6487021",
"0.6443187",
"0.63847476",
"0.6373113",
"0.63443893",
"0.63209134",
"0.6300363",
"0.6297922",
"0.6291968",
"0.62908477",
"0.6276572",
"0.6276572",
"0.6275026",
"0.62507194",
"0.6226852",
"0.622254... | 0.0 | -1 |
Compute softmax values for each sets of scores in x. | def N93T(WKvO):
uw5A = oyIN.exp(WKvO - oyIN.max(WKvO))
return uw5A / uw5A.sum() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def N93T(YKHO, cCrA):\n MvhI = oyIN.sum(oyIN.exp(cCrA), axis=1, keepdims=True)\n N93T = oyIN.exp(cCrA) / MvhI\n return N93T",
"def N93T(WKvO):\n j1LR = oyIN.exp(oyIN.asarray(WKvO))\n return j1LR / j1LR.sum(0)",
"def N93T(cCrA):\n XeFQ = oyIN.exp(cCrA)\n return XeFQ / oyIN.sum(XeFQ)",
"de... | [
"0.7796294",
"0.7760558",
"0.7759004",
"0.77567077",
"0.76577055",
"0.76577055",
"0.76577055",
"0.76577055",
"0.7585655",
"0.743143",
"0.7407772",
"0.73941606",
"0.7358175",
"0.73174125",
"0.72689486",
"0.72623265",
"0.72614294",
"0.7256868",
"0.723019",
"0.7214918",
"0.72017... | 0.71583456 | 23 |
Apply tilde expansion and absolutization to a path. | def gD9D(XP5J):
return Hy7s.path.abspath(Hy7s.path.expanduser(XP5J)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Z9ps(pmON):\n if '~' in pmON:\n return pmON.replace('~', hIOi('~'))\n else:\n return pmON",
"def VFZ9(pmON):\n return Hy7s.path.abspath(Hy7s.path.expanduser(pmON))",
"def dg8x(YKHO, pmON: Path) -> GkAb:\n return pmON.expanduser().absolute()",
"def bkQF(pmON):\n return Hy7s.pa... | [
"0.67730457",
"0.6398044",
"0.6370247",
"0.6354947",
"0.6306585",
"0.62351656",
"0.6195385",
"0.6143859",
"0.613771",
"0.61351126",
"0.6110445",
"0.609976",
"0.6091502",
"0.6034954",
"0.6021564",
"0.6001014",
"0.5976358",
"0.5938867",
"0.59254164",
"0.5916585",
"0.59038025",
... | 0.62935954 | 5 |
Return a list of default configuration dirs. | def rUGL(bNKA=None, N3HV=None, Fst3='.conf.d'):
return ERsZ(bNKA, N3HV, Fst3) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JEyV():\n Ux0P = Hy7s.path.join(Hy7s.path.expanduser('~'), '.gfail_defaults')\n if Hy7s.path.exists(Ux0P):\n lWPh = g59n(Ux0P)\n print('Default paths currently set to:\\n')\n for H5ew in lWPh:\n print('\\t%s = %s' % (H5ew, lWPh[H5ew]))\n else:\n print('No default... | [
"0.7522569",
"0.750033",
"0.7335641",
"0.69914",
"0.6967185",
"0.6923748",
"0.6782982",
"0.666451",
"0.64998895",
"0.64862853",
"0.64281577",
"0.6369673",
"0.63662153",
"0.63626176",
"0.6311698",
"0.6271214",
"0.62463325",
"0.6245975",
"0.6234872",
"0.61764896",
"0.6172697",
... | 0.6039685 | 26 |
Check if default is a reference to another var. | def lDPY(YKHO):
if isinstance(YKHO.default, str):
TCZ_ = YKHO.default.replace('\\$', '').replace('$$', '')
return '$' in TCZ_
return False | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Sfv2(YKHO):\n return YKHO.default is not None",
"def IXMJ(Q6kx):\n return bool(isinstance(Q6kx, Ziit.Referential) and Q6kx.get(o_8Q, None))",
"def pJQr(YKHO):\n if 'N' in YKHO.ref:\n return False\n else:\n return True",
"def Sfv2(YKHO):\n return YKHO._default is not None",
... | [
"0.60578936",
"0.60276395",
"0.599565",
"0.5985731",
"0.59614575",
"0.59157443",
"0.58454174",
"0.58381283",
"0.57921386",
"0.5720587",
"0.5720587",
"0.5720587",
"0.5659847",
"0.5643267",
"0.5641084",
"0.5606325",
"0.5597429",
"0.5592746",
"0.557228",
"0.55702686",
"0.5562748... | 0.7120536 | 0 |
Clear an override an opt's default value. Clear a previously set override of the default value of given option. | def Drtk(YKHO, mWFP, uOe2=None):
zQ_Q = YKHO._get_opt_info(mWFP, uOe2)
zQ_Q.pop('default', None) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XDGF(YKHO, mWFP, uOe2=None):\n zQ_Q = YKHO._get_opt_info(mWFP, uOe2)\n zQ_Q.pop('override', None)",
"def qpwt(YKHO):\n for U34r, uOe2 in YKHO._all_opt_infos():\n U34r.pop('default', None)\n U34r.pop('override', None)",
"async def _opt_default(YKHO, OaeV, MTKo):\n try:\n UY9... | [
"0.77190924",
"0.7266398",
"0.6248375",
"0.6074347",
"0.6028291",
"0.59844416",
"0.5972622",
"0.5948366",
"0.5909248",
"0.5894575",
"0.5894575",
"0.58872086",
"0.5825965",
"0.57462126",
"0.5731998",
"0.57185876",
"0.55860066",
"0.5575102",
"0.55405176",
"0.5508069",
"0.549443... | 0.7840706 | 0 |
Return the location where the option is being set. | def hbd3(YKHO, mWFP, uOe2=None):
evI5 = iTlN(uOe2) if uOe2 is not None else None
BWXx, hksT = YKHO._do_get(mWFP, evI5, None)
return hksT | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hbd3(YKHO):\n return YKHO._overridden_location or YKHO.get_default_location()",
"def Rci7(YKHO) -> h8nf[str]:\n return qe4Y.get(YKHO, 'location')",
"def Rci7(YKHO) -> h8nf[str]:\n return qe4Y.get(YKHO, 'location')",
"def Rci7(YKHO) -> h8nf[str]:\n return qe4Y.get(YKHO, 'location')",
"def Rc... | [
"0.6903988",
"0.68077296",
"0.68077296",
"0.68077296",
"0.67958254",
"0.6782258",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
"0.67711407",
... | 0.68130344 | 1 |
Construct a StrSubWrapper object. | def FIMM(YKHO, Fv2L, uOe2=None, _63S=None):
YKHO.conf = Fv2L
YKHO.group = uOe2
YKHO.namespace = _63S | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, *qIxc):\n PZpo.TStrStrH_swiginit(YKHO, PZpo.new_TStrStrH(*qIxc))",
"def FIMM(YKHO, *qIxc):\n PZpo.TRStr_swiginit(YKHO, PZpo.new_TRStr(*qIxc))",
"def FIMM(YKHO, *qIxc):\n PZpo.TStr_swiginit(YKHO, PZpo.new_TStr(*qIxc))",
"def FIMM(YKHO, *qIxc):\n PZpo.TStrStrVPr_swiginit(YKHO, PZpo.n... | [
"0.6118421",
"0.6054913",
"0.59066266",
"0.59055626",
"0.58551246",
"0.58251697",
"0.5819487",
"0.58181006",
"0.57857084",
"0.5747632",
"0.56739867",
"0.5666752",
"0.56566304",
"0.5653858",
"0.564312",
"0.56256175",
"0.5624805",
"0.5565181",
"0.55109197",
"0.5497292",
"0.5495... | 0.0 | -1 |
Check if the string is a URL. Arguments | def XdzF(KCHu: str) -> bool:
return KVWQ(KCHu).netloc != '' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XdzF(vIwR):\n return 'http' in vIwR",
"def yto3(vIwR):\n try:\n KVWQ(vIwR)\n return True\n except:\n return False",
"def c7sp(str):\n return True if nkF6.match(str[1:-1] if Vsny(str) else str) else False",
"def rx9o(YKHO, bD7m):\n if type(bD7m) == str:\n return ... | [
"0.8706335",
"0.84683204",
"0.8213185",
"0.7959005",
"0.78763884",
"0.77912563",
"0.77738255",
"0.7770804",
"0.76906246",
"0.76355165",
"0.76232296",
"0.7603492",
"0.76028913",
"0.76008725",
"0.75710624",
"0.7571053",
"0.7384039",
"0.7357395",
"0.73455817",
"0.7325443",
"0.73... | 0.8188321 | 3 |
Returns an SCDynamicStore instance | def eF8r():
return zpvD(None, 'crankd', qCmT, None) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oxS6(YKHO):\n return YKHO._store",
"def niGF(Emd4):\n eOIA = Emd4.get_store_path()\n VUF1 = aPQn(eOIA)\n return VUF1",
"def VUF1(YKHO) -> APqt:\n if YKHO._store is None:\n YKHO._store = HaQG(url=YKHO.url, serializer=YKHO.serializer, **YKHO.storage_options)\n return YKHO._store",
... | [
"0.6690807",
"0.6508678",
"0.6349258",
"0.6334613",
"0.6252112",
"0.6189263",
"0.61643934",
"0.6145207",
"0.61362004",
"0.6114552",
"0.6102535",
"0.60670835",
"0.5862045",
"0.58321494",
"0.576417",
"0.57110476",
"0.56993306",
"0.5699004",
"0.56539637",
"0.5620685",
"0.5608460... | 0.7644329 | 0 |
Applies Nonmax suppression (NMS) to set of boxes | def bp7k(cCrA, oUSw, KndY, asK2=10, PKpG=0.5):
fdJV = ZylS.constant(asK2, dtype=ZylS.int32)
RWZp = ZylS.image.non_max_suppression(oUSw, cCrA, fdJV, PKpG)
cCrA = ZylS.gather(cCrA, RWZp)
oUSw = ZylS.gather(oUSw, RWZp)
KndY = ZylS.gather(KndY, RWZp)
return (cCrA, oUSw, KndY) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zh61(c8oy, PKpG, gwAu, s_HA='corners'):\n assert type(c8oy) == list\n c8oy = [FlUN for FlUN in c8oy if FlUN[1] > gwAu]\n c8oy = sorted(c8oy, key=lambda WKvO: WKvO[1], reverse=True)\n qIa5 = []\n while c8oy:\n Nhh0 = c8oy.pop(0)\n KIsf = c8oy.copy()\n c8oy = []\n for F... | [
"0.76230794",
"0.76126164",
"0.74127907",
"0.7306879",
"0.71079224",
"0.71008795",
"0.70298326",
"0.70005816",
"0.69779086",
"0.6936501",
"0.6912464",
"0.68846273",
"0.68759656",
"0.6837655",
"0.6809186",
"0.6785253",
"0.6781637",
"0.6781637",
"0.6773558",
"0.66929877",
"0.66... | 0.6980498 | 8 |
Convert YOLO box predictions to bounding box corners. | def xZPR(mZ3_, FWeA):
KjRz = mZ3_ - FWeA / 2.0
iesS = mZ3_ + FWeA / 2.0
return ZylS.concat([KjRz[..., 1:2], KjRz[..., 0:1], iesS[..., 1:2], iesS[..., 0:1]], axis=-1) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xZPR(mZ3_, FWeA):\n KjRz = mZ3_ - FWeA / 2.0\n iesS = mZ3_ + FWeA / 2.0\n return nMvt.concatenate([KjRz[..., 1:2], KjRz[..., 0:1], iesS[..., 1:2], iesS[..., 0:1]])",
"def GSU9(mZ3_, FWeA):\n KjRz = mZ3_ - FWeA / 2.0\n iesS = mZ3_ + FWeA / 2.0\n return nMvt.concatenate([KjRz[..., 1:2], KjRz[... | [
"0.68267363",
"0.6787722",
"0.66186357",
"0.6260657",
"0.6246353",
"0.6168256",
"0.6139021",
"0.61005795",
"0.5996188",
"0.5984095",
"0.5943488",
"0.58923995",
"0.58608633",
"0.5853569",
"0.5853427",
"0.5842434",
"0.58124983",
"0.58112895",
"0.5796839",
"0.5789817",
"0.578578... | 0.667874 | 2 |
Return the correct original file name of a module. | def kA3c(yR_P):
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def AItA(Ux0P: str) -> str:\n return '.'.join(S1zJ(Ux0P).split(Hy7s.path.sep)[2:]).replace('.pyi', '').replace('.__init__', '')",
"def pqZE(yR_P, Ux0P):\n pmON, bGrB = Hy7s.path.split(yR_P.__file__)\n return Hy7s.path.join(pmON, Ux0P)",
"def ZUSD():\n from inspect import getmodulename, getfile\n ... | [
"0.7862815",
"0.75469196",
"0.7430269",
"0.729606",
"0.726982",
"0.726982",
"0.7207016",
"0.71916175",
"0.7174461",
"0.6998774",
"0.6980778",
"0.6938439",
"0.6910649",
"0.6898447",
"0.68801963",
"0.687956",
"0.6859904",
"0.6847839",
"0.6843535",
"0.68314177",
"0.68002087",
... | 0.65315896 | 29 |
Initialize the networkgit config user.email. | def FIMM(YKHO, Gzv5=(3, 32, 32), gt4n=[32], Y3Wb=[100], jTqs=10, QJWG=7, QIk7=0.001, lQ3t=0, hr1G=0, SOyF=False, yDqo=oyIN.float32):
YKHO.params = {}
YKHO.use_dropout = hr1G > 0
YKHO.use_batch_norm = SOyF
YKHO.conv_params = {'stride': 1, 'pad': (QJWG - 1) // 2}
YKHO.pool_params = {'pool_height': 2, ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XYtg(vC92):\n print('::initializing email creds...')\n RBFf = AOO4.getpass()\n bTKY = {'tardigrade': {'username': vC92, 'password': RBFf}}\n VqRE = rW6z + 'config'\n hZLL(VqRE, bTKY)",
"def LlH2() -> str:\n print('Email address not configured.\\nPlease enter your email: ')\n D3lj = HwRy.... | [
"0.70603883",
"0.63110435",
"0.60520756",
"0.6023001",
"0.59611225",
"0.59531945",
"0.5931013",
"0.58767384",
"0.58584696",
"0.5823041",
"0.5774297",
"0.5745315",
"0.57134986",
"0.5713046",
"0.5696215",
"0.5696215",
"0.5696215",
"0.5696215",
"0.5696215",
"0.5696215",
"0.56962... | 0.0 | -1 |
Sets self._inside_brackets to True if left bracket found. | def WYGP(YKHO, eOtH: tokenize.TokenInfo) -> None:
YKHO._bracket_stack.append(jCo2())
YKHO._current_ctx = YKHO._bracket_stack[-1] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QZQ5():\n Csk6 = WTdB().current_buffer.document\n return bool(Csk6.cursor_position == 0 or Csk6.char_before_cursor.isspace() or Csk6.char_before_cursor in '([{')",
"def fpuL(YKHO):\n return YKHO.left",
"def iTun(YKHO) -> bool:\n tdYf = False\n UTQj = False\n if YKHO.boolean_expression:\n ... | [
"0.60813683",
"0.58550274",
"0.5800551",
"0.5731238",
"0.57227486",
"0.5668241",
"0.55835974",
"0.5552061",
"0.5541748",
"0.55388975",
"0.55388975",
"0.5519901",
"0.55025023",
"0.5473584",
"0.54630464",
"0.5410604",
"0.5410123",
"0.5381645",
"0.53460515",
"0.5308878",
"0.5277... | 0.6285612 | 0 |
if search has nested dicts, remove them | def DiWw(TgwQ):
JmmR = ['w', 'l', 'i', 'n', 'f', 'p', 'x', 's']
if not TgwQ:
return
if isinstance(TgwQ, Uwyb):
return TgwQ
if TgwQ.get('t'):
return TgwQ
Yop_ = {}
for zHCd, lvR3 in TgwQ.items():
if len(zHCd) == 1 and zHCd in JmmR:
zHCd = 'm%s' % zHCd
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def NI8o(nPrm: Dict):\n Qla2 = ['title', 'published_at', 'identifier']\n for H5ew in list(nPrm):\n if H5ew not in Qla2:\n nPrm.pop(H5ew)",
"def Kf8X(uxij, QXNb):\n for G1Hx in QXNb:\n if isinstance(QXNb[G1Hx], dict):\n if G1Hx in uxij and type(uxij[G1Hx]) is mb_k.Sect... | [
"0.7018232",
"0.6561164",
"0.63609487",
"0.6350369",
"0.6308525",
"0.6303163",
"0.61509377",
"0.6096511",
"0.60937995",
"0.60914725",
"0.6041254",
"0.5969095",
"0.5960998",
"0.5947356",
"0.5933058",
"0.59080493",
"0.5887565",
"0.5875051",
"0.5849548",
"0.5839574",
"0.5776645"... | 0.0 | -1 |
Test generate_random_sphere_vector to verify that the object normalized_vector is a 3D array with nonzero components and a norm of one. | def _l5O():
FMhG = njNO.generate_random_sphere_vector()
assert isinstance(FMhG, oyIN.ndarray)
assert FMhG.shape == (3,)
for UksD in FMhG:
assert UksD != 0.0
assert oyIN.isclose(oyIN.linalg.norm(FMhG), 1.0) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZGbh():\n he6J = oyIN.random.standard_normal(3)\n return he6J / oyIN.linalg.norm(he6J)",
"def AU1D():\n t3eI = oyIN.random.RandomState(0)\n for exwG in range(1, 6):\n Ty9i = zTi3.random_vector(t3eI, exwG)\n P6bq = zTi3.norm_vector(Ty9i)\n Xgmb(oyIN.linalg.norm(P6bq), 1)",
"... | [
"0.79352826",
"0.7224374",
"0.6926471",
"0.6906835",
"0.6901551",
"0.684564",
"0.67936563",
"0.6673033",
"0.6651192",
"0.6604039",
"0.6603412",
"0.6575389",
"0.6544342",
"0.6538467",
"0.6474279",
"0.64473206",
"0.6388019",
"0.6329042",
"0.63280094",
"0.6316557",
"0.63050807",... | 0.90886253 | 0 |
Find completion matches for the given text. Given the user's input text and a collection of available completions, find completions matching the last word of the text. If `start_only` is True, the text will match an available completion only at the beginning. Otherwise, a completion is considered a match if the text ap... | def f3rC(l5Ny, xUwc, Dsks=False, DrBN=True, IKR4=None):
XVAW = jpUh(l5Ny, include='most_punctuations')
l5Ny = XVAW.lower()
m8fs = []
if DrBN:
njyT = '.*?'.join(map(ZbWC.escape, l5Ny))
lvR3 = ZbWC.compile('(%s)' % njyT)
for ZfUD in sorted(xUwc):
Mkmy = lvR3.search(ZfUD... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zPaf(YKHO, KnbE, dO5a, xAU6):\n if YKHO.should_hide_completions(original_text=KnbE, remaining_text=dO5a, allowed_suffixes=(' ', '.')):\n return []\n return [(MTKo, len(dO5a)) for MTKo in xAU6 if MTKo.startswith(dO5a) and (not MTKo.startswith('_'))]",
"def yQKN(YKHO, l5Ny, zFiD, YQdB, FVKd, JD1k=... | [
"0.5681952",
"0.5329823",
"0.527169",
"0.52684486",
"0.5164248",
"0.5139905",
"0.5139905",
"0.5129241",
"0.51232123",
"0.5080964",
"0.5075695",
"0.50329864",
"0.50222737",
"0.49978027",
"0.49869835",
"0.4973639",
"0.49638003",
"0.49585158",
"0.49314818",
"0.49203762",
"0.4902... | 0.659969 | 0 |
Decorator that caches return value of method based on args and kwargs, cache value stored in the object instance | def s3PB(JfyU: _t.Callable) -> zKuU.Callable:
mWFP: zKuU.Text = f'__cache_{JfyU.__name__}'
def h3Xc(YKHO, *qIxc, **B2fa):
Aofo = getattr(YKHO, mWFP, None)
if Aofo is None or Aofo[0] != qIxc or Aofo[1] != B2fa:
Aofo = (qIxc, B2fa, JfyU(YKHO, *qIxc, **B2fa))
setattr(YKHO, ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def h3Xc(*qIxc, **B2fa):\n Aofo = CJUp.try_get(mWFP, NKcE, qIxc, B2fa, **xAU6)\n if Aofo is not None:\n return Aofo\n Aofo = NKcE(*qIxc, **B2fa)\n CJUp.try_set(mWFP, Aofo, NKcE, qIxc, B2fa, **xAU6)\n return Aofo",
"def YNSV(YKHO, *qIxc, **B2fa):\n if YKHO.use_cache:\n wyyA = MbDg(... | [
"0.80784196",
"0.80025035",
"0.76318836",
"0.7538034",
"0.7505437",
"0.74832314",
"0.7473139",
"0.7456825",
"0.741934",
"0.73985386",
"0.73948026",
"0.7358792",
"0.7347225",
"0.73286",
"0.7301686",
"0.72526693",
"0.72483146",
"0.72456825",
"0.7228972",
"0.72104114",
"0.716637... | 0.77771443 | 2 |
Returns a function that maps each index in 0, 1, ..., n1 to a distinct RGB color; the keyword argument name must be a standard mpl colormap name. | def tRp2(exwG, mWFP='hsv'):
return QrM1.cm.get_cmap(mWFP, exwG) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tRp2(exwG, mWFP='jet'):\n return QrM1.cm.get_cmap(mWFP, exwG)",
"def tRp2(exwG, mWFP='Paired'):\n return QrM1.cm.get_cmap(mWFP, exwG)",
"def tRp2(exwG, mWFP='hsv'):\n return QrM1.cm.get_cmap(mWFP, exwG)",
"def tRp2(exwG, mWFP='hsv'):\n return QrM1.cm.get_cmap(mWFP, exwG)",
"def tRp2(exwG, m... | [
"0.7025025",
"0.6943994",
"0.69275856",
"0.69275856",
"0.69275856",
"0.67215765",
"0.65778434",
"0.65096295",
"0.64259195",
"0.6359199",
"0.6328814",
"0.62854236",
"0.6180951",
"0.6138011",
"0.61124665",
"0.60948807",
"0.6041402",
"0.60194355",
"0.59901917",
"0.59601426",
"0.... | 0.69756675 | 2 |
Return a learning rate scheduler | def RwOA(K0do, y7GR):
def qoQE(qtWj):
V9LS = 1.0 - max(0, qtWj + y7GR.epoch_count - y7GR.n_epochs) / float(y7GR.n_epochs_decay + 1)
return V9LS
IesV = hc6Z.LambdaLR(K0do, lr_lambda=qoQE)
return IesV | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RwOA(K0do, y7GR):\n NVLf = y7GR.epochs - y7GR.lr_linear\n uLqY = y7GR.lr_policy\n if uLqY == 'linear':\n\n def EAQd(qtWj):\n return 1.0 - max(0, qtWj - NVLf) / float(y7GR.lr_linear + 1)\n IesV = hc6Z.LambdaLR(K0do, lr_lambda=EAQd)\n elif uLqY == 'step':\n IesV = hc6Z... | [
"0.79357445",
"0.7631841",
"0.7620658",
"0.7587395",
"0.7579604",
"0.7452581",
"0.744563",
"0.74281615",
"0.7386596",
"0.73817253",
"0.7357768",
"0.7288603",
"0.7218676",
"0.7204649",
"0.7161282",
"0.71557266",
"0.71433187",
"0.7125463",
"0.7121791",
"0.71167016",
"0.71072483... | 0.7450352 | 6 |
Initialize network weights. Possibilities are 'Normal' and 'Xavier' | def vB93(Zxma, exny=0.02):
def yOVV(r8hN):
mPQc = r8hN.__class__.__name__
if hasattr(r8hN, 'weight') and (mPQc.find('Conv') != -1 or mPQc.find('Linear') != -1):
DbxN.normal_(r8hN.weight.data, 0.0, exny)
if hasattr(r8hN, 'bias') and r8hN.bias is not None:
DbxN... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def C0Lv(YKHO):\n pass",
"def vB93(YKHO) -> None:\n U78l.init.kaiming_normal_(YKHO._U)\n U78l.init.kaiming_normal_(YKHO._W)\n U78l.init.kaiming_normal_(YKHO._V)\n U78l.init.normal_(YKHO._b)",
"def dGkD(YKHO):\n U78l.init.xavier_normal_(YKHO.out.weight)",
"def vJuA(YKHO):\n raise NotImple... | [
"0.81939334",
"0.8158301",
"0.8110464",
"0.80753744",
"0.79489106",
"0.791322",
"0.7900379",
"0.78920627",
"0.77977157",
"0.7767634",
"0.7767634",
"0.7767634",
"0.7752601",
"0.7694178",
"0.76760465",
"0.76733345",
"0.7660916",
"0.7644418",
"0.762559",
"0.7623797",
"0.7615727"... | 0.7370748 | 55 |
Create label tensors with the same size as the input. | def PpUY(YKHO, o3Uj, nbSS):
if nbSS:
zvoY = YKHO.real_label
else:
zvoY = YKHO.fake_label
return zvoY.expand_as(o3Uj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wl12(cDK5):\n return (oyIN.ones([cDK5, 1]), oyIN.zeros([cDK5, 1]))",
"def nAMM(j9VG, XqwL, jTqs, KLLm=True, D5gV='seg'):\n with ZylS.name_scope('label_encode'):\n j9VG = ZylS.image.resize_nearest_neighbor(j9VG, XqwL)\n if D5gV == 'seg':\n j9VG = ZylS.squeeze(j9VG, squeeze_dims=... | [
"0.7334109",
"0.7140496",
"0.71153593",
"0.7086969",
"0.70147705",
"0.69324046",
"0.6846251",
"0.68401986",
"0.67875797",
"0.6771887",
"0.6746952",
"0.6703911",
"0.6692927",
"0.66772044",
"0.65051234",
"0.6464831",
"0.6432414",
"0.6425861",
"0.64061236",
"0.63710165",
"0.6313... | 0.0 | -1 |
Adds a vertex to the graph | def ohmD(YKHO, SLBp):
YKHO.vertices.append(SLBp)
YKHO.vertex_edge[SLBp] = [] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ohmD(YKHO, SLBp):\n raise NotImplementedError",
"def ohmD(YKHO, oqUi):\n pass",
"def ohmD(YKHO, SLBp):\n if SLBp.id not in YKHO.vertices.keys():\n YKHO.vertices[SLBp.id] = SLBp",
"def ohmD(YKHO, niHF: n):\n rJkO = Yegm(niHF)\n YKHO._graph[rJkO.name] = rJkO",
"def ohmD(YKHO, SLBp):... | [
"0.8787163",
"0.85861397",
"0.8467963",
"0.8440575",
"0.8350336",
"0.82913667",
"0.82033414",
"0.81121296",
"0.81121296",
"0.8089776",
"0.80505913",
"0.8043786",
"0.7982978",
"0.7977509",
"0.7963215",
"0.7961272",
"0.796055",
"0.79558057",
"0.79527986",
"0.78824633",
"0.78582... | 0.84251016 | 4 |
Adds an edge to the graph | def rz7z(YKHO, TtyH, RVDX):
YKHO.vertex_edge[TtyH].append(RVDX)
cnOs = k91E(TtyH, RVDX)
if RVDX not in YKHO.vertex_edge:
YKHO.edges.append(cnOs) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rz7z(YKHO, D70y):\n if YKHO.has_edge(D70y) == 0:\n YKHO.__graph_dict[D70y[0]].append(D70y[1])",
"def rz7z(YKHO, D70y):\n zZcM = D70y.get_source()\n e1vZ = D70y.get_destination()\n if not (zZcM in YKHO.edges and e1vZ in YKHO.edges):\n raise ValueError('Node not in graph')\n YKHO.e... | [
"0.8500494",
"0.8482894",
"0.8313779",
"0.82899714",
"0.8272254",
"0.82677686",
"0.82669777",
"0.82085985",
"0.8175204",
"0.8161914",
"0.8152684",
"0.8150967",
"0.8071292",
"0.80292875",
"0.8000602",
"0.7971441",
"0.7953097",
"0.7943503",
"0.7910237",
"0.789463",
"0.7860954",... | 0.78532517 | 21 |
Creates a new FFNN model to represent a policy. Implements all needed methods from tf.keras.Model. | def FIMM(YKHO, uqvc: Path, gqIb: int, b0Ix: float, IStE: int, YDYE: str='relu'):
super(o40T, YKHO).__init__()
YKHO.model_path = uqvc
YKHO.layer_size = gqIb
YKHO.output_size = EDoJ
YKHO.input_size = Gzv5
YKHO.learning_rate = b0Ix
YKHO.hidden_layers_count = IStE
YKHO.activation = YDYE
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eLpg(YKHO) -> ZylS.keras.models.Model:\n raise NotImplementedError()",
"def N9DT(YKHO):\n with ZylS.name_scope('policy_network'):\n with ZylS.variable_scope('policy_network'):\n C3ST = ZylS.keras.Sequential(name='policy_network_model')\n C3ST.add(ZylS.keras.layers.Dense(YKH... | [
"0.69288975",
"0.6927684",
"0.6668381",
"0.656694",
"0.65594894",
"0.6511043",
"0.63573056",
"0.6342833",
"0.6316973",
"0.62949574",
"0.6283353",
"0.62771636",
"0.6260603",
"0.6205826",
"0.620048",
"0.6187116",
"0.6172914",
"0.6167201",
"0.6165835",
"0.6118449",
"0.61008894",... | 0.0 | -1 |
returns true if the cmyk values are between 0 and 255 | def tcRf(Z9rn, r8hN, LVAh, G1Hx):
hLAO = 0
oS1e = 255
lxx3 = True
for wEf2 in (Z9rn, r8hN, LVAh, G1Hx):
if wEf2 >= hLAO and wEf2 <= 255:
pass
else:
lxx3 = False
return lxx3 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oO6r(BWXx):\n return 0 <= BWXx <= 255",
"def pfcg(d7Eb: ndarray) -> bool:\n return all(d7Eb >= 0)",
"def eC4J(SGPE):\n return all([oO6r(Z9rn) and Myyj(Z9rn) for Z9rn in SGPE])",
"def xzCw(LlSf, wEf2):\n exwG = 80\n gwAu = 4\n while gwAu >= 0:\n if len(xMux[LlSf]) > exwG and wEf2 ... | [
"0.7696764",
"0.6565392",
"0.64692634",
"0.63556695",
"0.63285995",
"0.6285347",
"0.6242104",
"0.6236757",
"0.6173846",
"0.6173846",
"0.61536485",
"0.6117954",
"0.60981804",
"0.6077521",
"0.6021677",
"0.60151637",
"0.60123754",
"0.5974014",
"0.5965677",
"0.5964167",
"0.595889... | 0.7365734 | 1 |
Initialiseert een nieuwe hashmap met gegeven grootte n. Type geeft | def FIMM(YKHO, type, exwG):
YKHO.type = type
if type == 'sep':
YKHO.items = [AdFl()] * exwG
else:
YKHO.items = [None] * exwG
YKHO.n = exwG | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def HPC4(YKHO, map):\n super(gakr, YKHO).__init__()\n YKHO.__init__()\n o4OS(map)",
"def FIMM(YKHO):\n YKHO.map = {}",
"def FIMM(YKHO):\n YKHO._map = {}",
"def FIMM(YKHO):\n super(gakr, YKHO).__init__()\n uIcm()",
"def FIMM(YKHO):\n YKHO.hashmap = {}",
"def FIMM(YKHO):\n YKHO.h... | [
"0.68588626",
"0.6810968",
"0.6698458",
"0.6683915",
"0.6640655",
"0.6640655",
"0.6618927",
"0.65846485",
"0.64746755",
"0.64397156",
"0.63330406",
"0.6309619",
"0.6301957",
"0.6301225",
"0.62196916",
"0.62196916",
"0.61573774",
"0.61573774",
"0.61573774",
"0.61573774",
"0.61... | 0.0 | -1 |
Returns List[Category] List of all categories that could potentially returned by classify() | def LeZt(YKHO):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LeZt(YKHO) -> x1iM[qZuN]:\n return list(set(YKHO.mapping.values()))",
"def LeZt(YKHO):\n h50c = YKHO.game_categories.all()\n return [gigf.category for gigf in h50c]",
"def UMnH(YKHO):\n LeZt = []\n for yeXE in YKHO.attributes:\n hkS8 = getattr(YKHO, yeXE, False)\n if hkS8 is Tr... | [
"0.7509363",
"0.74593574",
"0.7377025",
"0.72826576",
"0.72070694",
"0.7142708",
"0.71337545",
"0.7092652",
"0.7066633",
"0.70282346",
"0.7025826",
"0.6975605",
"0.6932335",
"0.69284004",
"0.6925354",
"0.69179225",
"0.68683857",
"0.68316513",
"0.68314976",
"0.6820639",
"0.681... | 0.6858113 | 17 |
All unique categories used in this classifier | def LeZt(YKHO) -> x1iM[qZuN]:
return list(set(YKHO.mapping.values())) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LeZt(YKHO):\n return sorted(YKHO.dictData.keys())",
"def t2bL(YKHO):\n return PG_7(YKHO.categorical_hyperparameters_64)",
"def LeZt(YKHO):\n return YKHO.__categories",
"def zG33(YKHO):\n return YKHO.categories.keys()",
"def LeZt(YKHO):\n pass",
"def LeZt(YKHO):\n return YKHO._catego... | [
"0.7506106",
"0.73227334",
"0.7208265",
"0.72041124",
"0.72034353",
"0.7166425",
"0.71495",
"0.71364886",
"0.7104631",
"0.7028423",
"0.69927675",
"0.6977006",
"0.696788",
"0.69555587",
"0.6951241",
"0.69501936",
"0.6931314",
"0.6906976",
"0.68834436",
"0.68730456",
"0.6836062... | 0.7444617 | 1 |
Return the dot product of u and v | def yKrh(P6bq, Ty9i):
BFdY = []
for YRbF in range(len(P6bq)):
BFdY.append(P6bq[YRbF] * Ty9i[YRbF])
return sum(BFdY) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def s2vS(P6bq, Ty9i):\n return P6bq[0] * Ty9i[0] + P6bq[1] * Ty9i[1] + P6bq[2] * Ty9i[2]",
"def uYbU(P6bq, Ty9i):\n U5bT = 0.0\n for YRbF in range(len(P6bq)):\n U5bT += float(float(P6bq[YRbF]) * float(Ty9i[YRbF]))\n return U5bT",
"def X6_J(YKHO, Ty9i):\n return YKHO.x * Ty9i.x + YKHO.y * ... | [
"0.88434124",
"0.87971246",
"0.84556437",
"0.8388875",
"0.8314668",
"0.82218444",
"0.8206603",
"0.8158425",
"0.8104789",
"0.80998814",
"0.80542636",
"0.8036317",
"0.800122",
"0.800122",
"0.800122",
"0.800122",
"0.800122",
"0.7995578",
"0.79905415",
"0.7988564",
"0.7980413",
... | 0.82813966 | 5 |
Return list of pythagorean triples as nondescending tuples of ints from 1 to n. Assume n is positive. | def K_24(exwG):
P5tZ = []
for YRbF in range(1, exwG + 1):
for r845 in range(1, exwG + 1):
for G1Hx in range(1, exwG + 1):
if YRbF ** 2 + r845 ** 2 == G1Hx ** 2 and YRbF <= r845 <= G1Hx:
P5tZ.append((YRbF, r845, G1Hx))
return P5tZ | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def K_24(exwG):\n vC9B = []\n for Z9rn in range(1, exwG + 1):\n for Fg_i in range(1, Z9rn):\n for jzdc in range(1, Fg_i):\n if jzdc * jzdc + Fg_i * Fg_i == Z9rn * Z9rn:\n vC9B.append((jzdc, Fg_i, Z9rn))\n return vC9B",
"def bso2(exwG):\n for mLGw in... | [
"0.8094776",
"0.72984177",
"0.727847",
"0.7146135",
"0.6965781",
"0.67307967",
"0.66383916",
"0.648162",
"0.6431071",
"0.6350643",
"0.6244063",
"0.6171055",
"0.611668",
"0.6079294",
"0.6068943",
"0.6055166",
"0.604777",
"0.60399395",
"0.602407",
"0.60153395",
"0.6008699",
"... | 0.7996597 | 1 |
Apply the four rules of the game to the current game grid. Creates a new_grid to be manipulated by the rules. Nested forloop runs through the rows and columns of a 2D list. Each neighbor of the cell of interest is identified and neighbor totals are calculated. If statements are used to implement the rules of the game. | def ysMt(Cs6h, YDwv, Gmep):
P5uO = [[0] * (YDwv + 1) for YRbF in range(Gmep + 1)]
for YRbF in range(Gmep):
for r845 in range(YDwv):
K3QL = Cs6h[YRbF - 1][r845 - 1]
CN9P = Cs6h[YRbF - 1][r845]
HPKV = Cs6h[YRbF - 1][r845 + 1]
LFlW = Cs6h[YRbF][r845 - 1]
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tlUU(YKHO):\n Vjhr.fill(GGX1)\n for rdlD in YKHO.grid:\n for VmPb in rdlD:\n if VmPb.root:\n qfpW = mk8g\n elif VmPb.goal:\n qfpW = Uah8\n elif VmPb.value:\n qfpW = jqrj\n elif VmPb.visited:\n q... | [
"0.6495653",
"0.64484656",
"0.642264",
"0.6191768",
"0.6130129",
"0.6080801",
"0.6049253",
"0.59872615",
"0.59566456",
"0.58835655",
"0.5882744",
"0.58461547",
"0.5834441",
"0.57707757",
"0.57700586",
"0.5746112",
"0.57235205",
"0.5721528",
"0.57213503",
"0.57207745",
"0.5719... | 0.6888119 | 0 |
Revert all settings to their defaults. Database settings do not automatically apply to open connections. | def GfX1(YKHO):
YKHO.config = {'dbuser': Zrbc.DEFAULT_DBUSER, 'dbname': Zrbc.DEFAULT_DBNAME, 'dbpassword': Zrbc.DEFAULT_DBPASSWORD, 'dbhost': Zrbc.DEFAULT_DBHOST} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zfBO():\n gCuF = hp1l()\n gCuF.reset()\n gCuF.save()",
"def SiRx(YKHO):\n YKHO.manager.delete_all()\n for mWFP, wEf2 in QhLw.items():\n wEf2['name'] = mWFP\n wEf2['default_value'] = wEf2['value']\n YKHO.manager.from_dict(wEf2)",
"def Bi2V(YKHO):\n YKHO.db.reset_databa... | [
"0.74593943",
"0.7051543",
"0.6810418",
"0.67957395",
"0.6638111",
"0.6580477",
"0.64899087",
"0.6472318",
"0.64488715",
"0.64437187",
"0.6438868",
"0.64087504",
"0.6351835",
"0.6312363",
"0.63119817",
"0.6279463",
"0.6278628",
"0.6267052",
"0.6263454",
"0.6231329",
"0.618367... | 0.64831877 | 7 |
Close the open database connection | def DDI8(YKHO):
if YKHO.conn is not None:
YKHO.conn.close()
YKHO.conn = None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def yZlT(Emd4):\n NCls.close()",
"def YzkT(YKHO):\n if YKHO._conn is not None:\n YKHO._conn.close()\n YKHO._conn = None",
"def DDI8(YKHO):\n if YKHO._dbopen:\n YKHO._dbcon.close()",
"def DDI8(YKHO):\n RdPg.debug('DB -> close')\n YKHO.conn.close()",
"def EM8p(YKHO):\n ... | [
"0.888187",
"0.86910784",
"0.8661716",
"0.8572991",
"0.8401916",
"0.8352514",
"0.82957244",
"0.8284722",
"0.8247352",
"0.8231512",
"0.8221038",
"0.817572",
"0.8142638",
"0.8135985",
"0.8135985",
"0.8135985",
"0.81020117",
"0.8054716",
"0.80532515",
"0.8031756",
"0.80248314",
... | 0.0 | -1 |
Need this to use == operator | def xa14(YKHO, Elif):
if type(Elif) == type(''):
return YKHO.word == Elif
return YKHO.word == Elif.word | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YKHO, *qIxc):\n pass",
"def xa14(YK... | [
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7765659",
"0.7722746",
"... | 0.0 | -1 |
Test case for projects_id_comments_patch You can't put the entire List | def zBso(YKHO):
bNKA = jY1u()
geh0 = YKHO.client.open('/project-tracker/projects/{id}/comments'.format(id=56), method='PATCH', data=qQXR.dumps(bNKA), content_type='application/json')
YKHO.assert200(geh0, 'Response body is : ' + geh0.data.decode('utf-8')) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GGAq(YKHO):\n pass",
"def tpHO(YKHO):\n pass",
"def XLUE(YKHO):\n bNKA = jY1u()\n geh0 = YKHO.client.open('/project-tracker/projects/{id}/comments'.format(id=56), method='POST', data=qQXR.dumps(bNKA), content_type='application/json')\n YKHO.assert200(geh0, 'Response body is : ' + geh0.data.d... | [
"0.7005537",
"0.6911109",
"0.6698229",
"0.66503316",
"0.662829",
"0.6614505",
"0.6596675",
"0.65016913",
"0.6436199",
"0.6340969",
"0.62965775",
"0.62892133",
"0.62499595",
"0.6141073",
"0.6132673",
"0.6094428",
"0.6094136",
"0.60626733",
"0.60514086",
"0.6017415",
"0.6001806... | 0.75987107 | 0 |
Test case for projects_put You shouldn't put the entire List | def TOZS(YKHO):
bNKA = oPx1()
geh0 = YKHO.client.open('/project-tracker/projects', method='PUT', data=qQXR.dumps(bNKA), content_type='application/json')
YKHO.assert200(geh0, 'Response body is : ' + geh0.data.decode('utf-8')) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def g3tq(YKHO):\n for IDBL in oPx1.objects.all():\n _6nv.objects.create(user=YKHO.user, project=IDBL)\n YKHO.user.save()\n YKHO.story.projects.add(*list(oPx1.objects.filter(projecttranslation__name__in=(\"Finding a Bite: Food Access in the Children's Corridor\", 'Redeveloping The Holly: From Gang V... | [
"0.83744097",
"0.8195241",
"0.8106585",
"0.7228424",
"0.71508354",
"0.7128427",
"0.705452",
"0.67779267",
"0.6715903",
"0.66805834",
"0.6666764",
"0.6637439",
"0.6603797",
"0.66016567",
"0.66016567",
"0.6554031",
"0.65434396",
"0.65143204",
"0.65113086",
"0.6491051",
"0.64766... | 0.70465624 | 7 |
Return the version of the Processing Block Device. | def DpZH(YKHO):
return FrIB | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def oLI0(YKHO):\n TRdr = eME6(YKHO._pb_id)\n return TRdr.version",
"def DpZH(YKHO):\n nPrm = YKHO._ftdi.spi_read(YKHO.VERSION_ADDR, len=1, burst='fixed')\n return nPrm[0] & YKHO.VERSION_MASK",
"def MONY(YKHO):\n pyJd = YKHO.parser_invoker.get_firmware_version_command_bytes(YKHO.sequence_id, YKHO... | [
"0.7834875",
"0.74734384",
"0.7226713",
"0.71845275",
"0.7135659",
"0.7054146",
"0.70400465",
"0.7019371",
"0.698877",
"0.69734764",
"0.69401723",
"0.68796974",
"0.68760043",
"0.6811419",
"0.67835605",
"0.67699826",
"0.6728901",
"0.6724566",
"0.671848",
"0.66900724",
"0.66681... | 0.71394897 | 4 |
Return the Processing block ID for this device. | def IgBf(YKHO):
return YKHO._pb_id | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def njFg(YKHO):\n TRdr = eME6(YKHO._pb_id)\n return TRdr.sbi_id",
"def VDR9(YKHO):\n return YKHO._block_id",
"def vi8b(YKHO):\n return YKHO.attr_map['ProcessingBlockList']",
"def oLI0(YKHO):\n TRdr = eME6(YKHO._pb_id)\n return TRdr.version",
"def a5zH(YKHO):\n return YKHO.blockNum",
... | [
"0.7039438",
"0.6580052",
"0.65137804",
"0.6424397",
"0.62915796",
"0.62824583",
"0.62824583",
"0.6210337",
"0.6184827",
"0.60902727",
"0.60077965",
"0.5856252",
"0.5838093",
"0.5792409",
"0.5729835",
"0.5678293",
"0.56738454",
"0.56352526",
"0.5625952",
"0.5613813",
"0.55568... | 0.5912305 | 11 |
Set the PB Id for this device. | def IgBf(YKHO, IgBf: str):
YKHO.set_state(ilBV.ON)
YKHO._pb_id = IgBf | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def IgBf(YKHO):\n return YKHO._pb_id",
"def V_9M(YKHO, LZbL):\n pass",
"def ekm0(YKHO, eEzR):\n YKHO._id = eEzR",
"def f6Qh(YKHO, BWXx):\n pass",
"def sMcj(YKHO, sMcj):\n YKHO._player_b_id = sMcj",
"def id(YKHO, BWXx):\n YKHO._id = BWXx",
"def V_9M(YKHO, id):\n YKHO.data['id'] = id... | [
"0.64966524",
"0.61853826",
"0.6152964",
"0.6044323",
"0.6015985",
"0.6005453",
"0.5963273",
"0.59582216",
"0.58882314",
"0.5859666",
"0.5859666",
"0.5805439",
"0.57847154",
"0.5782313",
"0.57800746",
"0.5720057",
"0.5719524",
"0.57154655",
"0.5713418",
"0.56911194",
"0.55721... | 0.73184115 | 0 |
Return the PB configuration. | def tmlS(YKHO):
TRdr = eME6(YKHO._pb_id)
return qQXR.dumps(TRdr.config) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wOGa(YKHO) -> qe4Y.Output['outputs.BrokerConfiguration']:\n return qe4Y.get(YKHO, 'configuration')",
"def iRm2(Emd4):\n if Emd4.pb_singleton is None:\n with open(WncU.FLAGS.conf, 'r') as CAYp:\n Emd4.pb_singleton = C5Bg.Merge(CAYp.read(), PBLf.Config())\n Yoqy.info('Get con... | [
"0.76365185",
"0.7633313",
"0.74884564",
"0.7473088",
"0.7473088",
"0.73817724",
"0.7318932",
"0.7239872",
"0.7233952",
"0.72292024",
"0.72205544",
"0.7214669",
"0.7179086",
"0.7162158",
"0.71597296",
"0.71597296",
"0.71597296",
"0.71597296",
"0.71597296",
"0.71597296",
"0.71... | 0.81213135 | 0 |
pick one beyond minimal value in a list. return the index of the element | def Bh7v(jzdc):
iesy = []
r8hN = oyIN.min(jzdc)
for YRbF, tTpl in enumerate(jzdc):
if tTpl == r8hN:
iesy.append(YRbF)
return iesy[tuKI.randint(0, len(iesy) - 1)] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XcNI(list):\n return Qpvm(list, -1)",
"def UA9m(Emd4, yv6U: list) -> int:\n return yv6U.index(min(yv6U))",
"def kc5j(IqQl):\n if len(IqQl) == 0:\n raise Exception('List must contain at least 1 element')\n ZSml = 0\n for YRbF in range(1, len(IqQl)):\n if IqQl[YRbF] < IqQl[ZSml]:... | [
"0.85527766",
"0.8157126",
"0.76822233",
"0.75406045",
"0.7499388",
"0.7395434",
"0.7367144",
"0.73029804",
"0.72871995",
"0.7240269",
"0.7239049",
"0.72320753",
"0.72235835",
"0.7215573",
"0.7135333",
"0.71179044",
"0.70990556",
"0.7092684",
"0.70821023",
"0.70224696",
"0.70... | 0.62468237 | 86 |
Initialize source loss module. | def FIMM(YKHO, _rWM, M_Qc, TOGf, vIbS, ofOj, a3Qb=0, hbUd=-0.15):
super(j8Dp, YKHO).__init__()
YKHO.cheaptrick = Kfcp(sampling_rate=_rWM, hop_size=M_Qc, fft_size=TOGf, f0_floor=vIbS, f0_ceil=ofOj, uv_threshold=a3Qb, q1=hbUd)
YKHO.loss = U78l.MSELoss() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RnSz(YKHO):\n pass",
"def FIMM(YKHO, KZ52, GT2U):\n super().__init__()\n YKHO.modules = KZ52\n YKHO.loss_fn = GT2U",
"def FIMM(YKHO, JZXy):\n YKHO._source = JZXy",
"def RnSz(YKHO):\n return ht2j.nn.MSELoss()",
"def FIMM(YKHO):\n super(QoUQ, YKHO).__init__()",
"def IcbR(YKHO, Z9rn... | [
"0.71451145",
"0.6502135",
"0.63599026",
"0.62476224",
"0.6222252",
"0.6204144",
"0.6143606",
"0.6143606",
"0.61238533",
"0.61194986",
"0.6092342",
"0.6028665",
"0.59298074",
"0.59224313",
"0.59224313",
"0.5902171",
"0.5869834",
"0.58684933",
"0.5866831",
"0.58570147",
"0.583... | 0.54401165 | 50 |
Verify that the Unpacker has a reasonable state when it is first constructed. | def MuNt(GPtr, AZgw, uv4j):
N1VT = AZgw.MagicMock()
XP5J = h0YP(GPtr, N1VT)
assert XP5J.last_work_begin_timestamp is XP5J.last_work_end_timestamp | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uABQ(YKHO):\n pass",
"def f5N9(YKHO):\n YKHO.assertEquals(0, YKHO._error_count)\n YKHO.assertEquals(0, len(YKHO._error_messages))",
"def tgbc(YKHO):\n pass",
"def hjOo():\n with trZe.raises(TypeError):\n h0YP()",
"def zPKT(YKHO) -> None:\n O33O(YKHO.struct_class)",
"def zPKT(... | [
"0.6263604",
"0.62551486",
"0.6254808",
"0.6216785",
"0.61777383",
"0.61777383",
"0.6158712",
"0.61534536",
"0.61313677",
"0.61311907",
"0.611405",
"0.5982184",
"0.5978936",
"0.5948849",
"0.5830854",
"0.58068204",
"0.57835066",
"0.57656497",
"0.57650167",
"0.5762708",
"0.5758... | 0.6736872 | 0 |
Verify that the Unpacker has no additional state to offer. | def iHIR(GPtr, AZgw, uv4j):
N1VT = AZgw.MagicMock()
XP5J = h0YP(GPtr, N1VT)
assert XP5J._do_status() == {} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tgbc(YKHO):\n pass",
"def Hhhz(YKHO, kFUR):\n QkGZ = NWkS.Advisory(errata_id=123, errata_state='QE')\n QkGZ.ensure_state('QE')\n kFUR.assert_not_called()",
"def XTef(YKHO):\n pass",
"def Gwg3(YKHO):\n YKHO._basket.verify_if_basket_is_empty()",
"def EcDi(YKHO):\n pass",
"def bfng(... | [
"0.6599915",
"0.6227758",
"0.6219967",
"0.6165108",
"0.6077323",
"0.6067991",
"0.59909546",
"0.5981062",
"0.59618324",
"0.59585756",
"0.5951633",
"0.59358555",
"0.5933014",
"0.5928011",
"0.5909257",
"0.5899416",
"0.589422",
"0.58827335",
"0.58677477",
"0.5838934",
"0.5831037"... | 0.0 | -1 |
Test that _update_bundle_in_lta_db updates the status of the bundle in the LTA DB. | async def test_unpacker_update_bundle_in_lta_db(GPtr, AZgw, uv4j):
N1VT = AZgw.MagicMock()
TxK5 = AZgw.patch('rest_tools.client.RestClient', new_callable=zrRO)
XP5J = h0YP(GPtr, N1VT)
assert await XP5J._update_bundle_in_lta_db(TxK5, {'uuid': 'c4b345e4-2395-4f9e-b0eb-9cc1c9cdf003'})
TxK5.request.asse... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def WqtB(YKHO):\n YKHO.bndl.ticket = None\n _ASj.check_bundle(YKHO.bndl, ticket_ref='ticket', file_ref='flat_file', retrieve_ref='phagesdb', retain_ref='mysql')\n UHFx = uiv6(YKHO.bndl, 'error', 'warning')\n with YKHO.subTest():\n YKHO.assertEqual(len(YKHO.bndl.evaluations), 1)\n with YKHO.su... | [
"0.6499748",
"0.6375098",
"0.63195056",
"0.62923455",
"0.62595326",
"0.61508405",
"0.61508405",
"0.61508405",
"0.6130336",
"0.6129345",
"0.60776377",
"0.60384524",
"0.6009847",
"0.6008804",
"0.59955597",
"0.5994568",
"0.59913254",
"0.59864956",
"0.5981181",
"0.593282",
"0.589... | 0.71887296 | 0 |
Test that _delete_manifest_metadata will delete metadata of either version. | def mMmY(GPtr, AZgw, uv4j):
N1VT = AZgw.MagicMock()
XP5J = h0YP(GPtr, N1VT)
wXpS = AZgw.patch('os.remove')
wXpS.side_effect = [NameError, None]
XP5J._delete_manifest_metadata('0869ea50-e437-443f-8cdb-31a350f88e57')
wXpS.assert_called_with('/tmp/lta/testing/unpacker/outbox/0869ea50-e437-443f-8cdb... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def aNo5(GPtr, AZgw, uv4j):\n N1VT = AZgw.MagicMock()\n XP5J = h0YP(GPtr, N1VT)\n wXpS = AZgw.patch('os.remove')\n wXpS.side_effect = [NameError, NameError]\n with trZe.raises(NameError):\n XP5J._delete_manifest_metadata('0869ea50-e437-443f-8cdb-31a350f88e57')\n wXpS.assert_called_with('/t... | [
"0.68494916",
"0.6320009",
"0.6316312",
"0.62980163",
"0.6202315",
"0.5990099",
"0.59865844",
"0.59578156",
"0.5951433",
"0.594975",
"0.5945878",
"0.5921927",
"0.5902222",
"0.58407366",
"0.5838764",
"0.583026",
"0.58298224",
"0.58037287",
"0.5794836",
"0.57929486",
"0.579052"... | 0.74787045 | 0 |
Test that _delete_manifest_metadata will throw on an unknown version. | def aNo5(GPtr, AZgw, uv4j):
N1VT = AZgw.MagicMock()
XP5J = h0YP(GPtr, N1VT)
wXpS = AZgw.patch('os.remove')
wXpS.side_effect = [NameError, NameError]
with trZe.raises(NameError):
XP5J._delete_manifest_metadata('0869ea50-e437-443f-8cdb-31a350f88e57')
wXpS.assert_called_with('/tmp/lta/testi... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def mMmY(GPtr, AZgw, uv4j):\n N1VT = AZgw.MagicMock()\n XP5J = h0YP(GPtr, N1VT)\n wXpS = AZgw.patch('os.remove')\n wXpS.side_effect = [NameError, None]\n XP5J._delete_manifest_metadata('0869ea50-e437-443f-8cdb-31a350f88e57')\n wXpS.assert_called_with('/tmp/lta/testing/unpacker/outbox/0869ea50-e43... | [
"0.7372555",
"0.6441587",
"0.62728256",
"0.6213908",
"0.6173617",
"0.61352557",
"0.6132365",
"0.6121432",
"0.6107993",
"0.61024123",
"0.6098416",
"0.6049859",
"0.60365367",
"0.6020899",
"0.5971693",
"0.59376717",
"0.5902457",
"0.5899617",
"0.589082",
"0.5890105",
"0.58641493"... | 0.7510625 | 0 |
Test that _read_manifest_metadata will throw on an unknown version. | def CLQg(GPtr, AZgw, uv4j):
N1VT = AZgw.MagicMock()
XP5J = h0YP(GPtr, N1VT)
lpD4 = AZgw.patch('lta.unpacker.Unpacker._read_manifest_metadata_v2')
lpD4.side_effect = [None]
LY3J = AZgw.patch('lta.unpacker.Unpacker._read_manifest_metadata_v3')
LY3J.side_effect = [None]
with trZe.raises(Excepti... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def iF4m(nUM0, GPtr, AZgw, uv4j):\n N1VT = AZgw.MagicMock()\n nUM0.side_effect = NameError\n XP5J = h0YP(GPtr, N1VT)\n assert not XP5J._read_manifest_metadata_v3('0869ea50-e437-443f-8cdb-31a350f88e57')",
"def OlsA(nUM0, GPtr, AZgw, uv4j):\n N1VT = AZgw.MagicMock()\n nUM0.side_effect = NameError... | [
"0.7169583",
"0.7081144",
"0.6739161",
"0.6642735",
"0.64975154",
"0.6303252",
"0.6300239",
"0.6251104",
"0.62317026",
"0.61887234",
"0.61170816",
"0.61137027",
"0.6109315",
"0.6099843",
"0.60819846",
"0.60760486",
"0.6066707",
"0.6066453",
"0.6053334",
"0.6042419",
"0.604208... | 0.73456854 | 0 |
Test that _read_manifest_metadata_v3 will not throw when unable to read metadata. | def iF4m(nUM0, GPtr, AZgw, uv4j):
N1VT = AZgw.MagicMock()
nUM0.side_effect = NameError
XP5J = h0YP(GPtr, N1VT)
assert not XP5J._read_manifest_metadata_v3('0869ea50-e437-443f-8cdb-31a350f88e57') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Ayls(GPtr, AZgw, uv4j):\n N1VT = AZgw.MagicMock()\n XP5J = h0YP(GPtr, N1VT)\n lpD4 = AZgw.patch('lta.unpacker.Unpacker._read_manifest_metadata_v2')\n lpD4.side_effect = [None]\n LY3J = AZgw.patch('lta.unpacker.Unpacker._read_manifest_metadata_v3')\n LY3J.side_effect = [{'some': 'object'}]\n ... | [
"0.6892553",
"0.6883256",
"0.6865995",
"0.65582126",
"0.65180963",
"0.63612777",
"0.6188923",
"0.6170187",
"0.60026217",
"0.59894437",
"0.59743226",
"0.5963816",
"0.59482044",
"0.58974534",
"0.5895962",
"0.5818921",
"0.58149624",
"0.58108026",
"0.5777837",
"0.5769291",
"0.576... | 0.75113803 | 0 |
This function prints and plots the confusion matrix. Normalization can be applied by setting `normalize=True`. | def LwSz(Bcwd, KndY, NkkI=False, leAC='Confusion matrix', iMGt=QrM1.cm.Blues):
if NkkI:
Bcwd = Bcwd.astype('float') / Bcwd.sum(axis=1)[:, oyIN.newaxis]
print('Normalized confusion matrix')
else:
print('Confusion matrix, without normalization')
print(Bcwd)
QrM1.imshow(Bcwd, interp... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def LwSz(Bcwd, KndY=[0, 1], NkkI=False, leAC='Confusion matrix', RMso=False):\n if NkkI:\n Bcwd = Bcwd.astype('float') / Bcwd.sum(axis=1)[:, oyIN.newaxis]\n print('Normalized confusion matrix')\n else:\n print('Confusion matrix, without normalization')\n if RMso:\n print(Bcwd)"... | [
"0.8194862",
"0.80949175",
"0.8029915",
"0.8019153",
"0.79941195",
"0.7991258",
"0.7980955",
"0.7976606",
"0.79610753",
"0.79590565",
"0.79378676",
"0.7934962",
"0.7934504",
"0.79313844",
"0.7926313",
"0.7924577",
"0.79241234",
"0.7923211",
"0.7923023",
"0.7921931",
"0.791787... | 0.7856715 | 42 |
Returns the Young Modulus of a material in N/m^2 | def KajZ(Mx95):
if Mx95 == 'mild':
return 200000000000.0
elif Mx95 == 'al':
return 69000000000.0
else:
raise ValueError('Invalid material `' + Mx95 + "'") | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def jh8S(__n6: np.ndarray) -> KajZ:\n lEb0: int = len(__n6) // 10\n RgqX = oyIN.argmax([__n6[YRbF + lEb0][1] - __n6[YRbF][1] for YRbF in range(len(__n6) - lEb0)])\n nEGB = __n6[RgqX]\n C1wN = __n6[RgqX + lEb0]\n jDtP = (C1wN[1] - nEGB[1]) / (C1wN[0] - nEGB[0])\n return KajZ(jDtP, nEGB, C1wN)",
... | [
"0.67148286",
"0.61187845",
"0.58572924",
"0.5819239",
"0.579422",
"0.5661844",
"0.559946",
"0.5591879",
"0.55850786",
"0.5577663",
"0.5567218",
"0.55623007",
"0.5491746",
"0.5478498",
"0.5471267",
"0.5455068",
"0.54468375",
"0.54108715",
"0.54105854",
"0.5386188",
"0.5383324... | 0.8423878 | 0 |
Returns the density of a material in kg/m^3 | def MPRT(Mx95):
if Mx95 == 'mild':
return 7850.0
elif Mx95 == 'al':
return 2700.0
else:
raise ValueError('Invalid material `' + Mx95 + "'") | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def InLe(YKHO):\n return 0.001 * YKHO.molar_mass * YKHO.pressure / (K6Rf * YKHO.temperature)",
"def CmwO(YKHO):\n return YKHO._density_kg_m3",
"def M92e(YKHO):\n return YKHO._density_kg_m3 / 1000.0",
"def wYgR(YKHO):\n return YKHO.electron_density * 1000000.0",
"def KhUB(*qIxc):\n return EdJ... | [
"0.78450173",
"0.7577004",
"0.75337845",
"0.75139385",
"0.68572533",
"0.67514986",
"0.6707994",
"0.67074585",
"0.66710615",
"0.6592827",
"0.6582313",
"0.6472921",
"0.6445674",
"0.6445674",
"0.6445674",
"0.6412132",
"0.633474",
"0.63141286",
"0.6308918",
"0.6267133",
"0.623077... | 0.7671926 | 1 |
Returns the deflection of a horizontal cantilever of length L made from the material described by I and E, under a distributed uniform load q. | def Rf4K(pdhd, ut5U, aPd6, vexM):
yzQ0 = vexM * aPd6 ** 4 / (8 * ut5U * pdhd)
return yzQ0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XD_g(pdhd, ut5U, aPd6):\n nMvt = 2.0\n vuvg = oyIN.pi ** 2 * ut5U * pdhd / (nMvt * aPd6) ** 2\n return vuvg",
"def YhBf(BHsk, pdhd, jSF5):\n he6J = BHsk[1, :] - BHsk[0, :]\n jHsn = he6J[0] / oyIN.linalg.norm(he6J)\n pvd3 = he6J[1] / oyIN.linalg.norm(he6J)\n aPd6 = oyIN.linalg.norm(he6J)\... | [
"0.55021435",
"0.53189874",
"0.52113706",
"0.5087749",
"0.50627816",
"0.5025136",
"0.4990624",
"0.4911095",
"0.4907491",
"0.481666",
"0.48159784",
"0.47943085",
"0.47663116",
"0.47565433",
"0.47562125",
"0.4755256",
"0.4752054",
"0.46714708",
"0.46163446",
"0.4614189",
"0.461... | 0.6460688 | 0 |
Return an iterator which schedules after each iteration. This can prevent eventlet thread starvation. | def ILab(qaOp):
try:
for yOAJ in qaOp:
N5MO(0)
yield yOAJ
except Exception as err:
tO9_ = bGrB('Error: cooperative_iter exception %(error)s') % dict(error=XObx)
na1r.error(tO9_)
raise | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vs4Q(YKHO):\n while True:\n if YKHO.stop:\n return\n for ZfUD in YKHO.get_next_batch():\n yield ZfUD",
"def Vs4Q(YKHO):\n N1p7 = YKHO.first()\n while N1p7 is not None:\n yield N1p7.element()\n N1p7 = YKHO.after(N1p7)",
"def n2fR(oHE7: Iterable[Any]... | [
"0.6472814",
"0.63899297",
"0.6330288",
"0.6251689",
"0.6220062",
"0.61972934",
"0.61830074",
"0.6165581",
"0.6139348",
"0.60712504",
"0.60712504",
"0.5949444",
"0.5936542",
"0.59117055",
"0.5899739",
"0.58811164",
"0.5871774",
"0.5859907",
"0.5859188",
"0.5843484",
"0.584262... | 0.55949634 | 48 |
Return an iterator to a filelike obj which yields fixed size chunks | def wghX(ytgA, ztRo=65536):
while True:
yOAJ = ytgA.read(ztRo)
if yOAJ:
yield yOAJ
else:
break | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def WaSS(nUeQ: io.BytesIO, ztRo: int=64 * 1024):\n while True:\n nPrm = nUeQ.read(ztRo)\n if not nPrm:\n break\n yield nPrm",
"def XsmD(Vu7S, ztRo=1024):\n while True:\n yOAJ = Vu7S.read(ztRo)\n if not yOAJ:\n return\n yield yOAJ",
"def XsmD... | [
"0.80395174",
"0.79308766",
"0.79308766",
"0.79298854",
"0.78477174",
"0.78453135",
"0.78411007",
"0.7777719",
"0.77432054",
"0.7733398",
"0.772871",
"0.772871",
"0.772871",
"0.772871",
"0.772837",
"0.77246517",
"0.77110773",
"0.7650436",
"0.7646451",
"0.7521083",
"0.7502705"... | 0.78066623 | 7 |
r""" Calculates a cross product (or vector product) of two vectors in tridimensional Cartesian coordinates. | def wnaF(jzdc, Fg_i):
return (jzdc[1] * Fg_i[2] - jzdc[2] * Fg_i[0], jzdc[2] * Fg_i[0] - jzdc[0] * Fg_i[2], jzdc[0] * Fg_i[1] - jzdc[1] * Fg_i[0]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wnaF(hQHm, jlSq):\n return _J6W.CG3dVector(hQHm[1] * jlSq[2] - jlSq[1] * hQHm[2], hQHm[2] * jlSq[0] - jlSq[2] * hQHm[0], hQHm[0] * jlSq[1] - jlSq[0] * hQHm[1])",
"def dcUW(WKvO, LVAh):\n if len(WKvO) != len(LVAh):\n raise ValueError('vector lengths differ')\n elif len(WKvO) > 3:\n rais... | [
"0.80790997",
"0.7866993",
"0.78176665",
"0.7773975",
"0.76691467",
"0.7623997",
"0.7544347",
"0.75053585",
"0.7362339",
"0.7339407",
"0.7335022",
"0.7329031",
"0.72843534",
"0.72762126",
"0.7262948",
"0.72450465",
"0.7104131",
"0.70906115",
"0.70492136",
"0.7021942",
"0.7007... | 0.74273777 | 8 |
Draw detected bounding boxes. | def _1rj(Xn71, _2sc, l40E, Wc20, eCpO, ytgA, knl1=0.5):
ecnw = {'left': 20, 'right': -20, 'front': 40, 'back': 0, 'resolution': 0.05}
noZV = oyIN.where(l40E[:, -1] >= knl1)[0]
if len(noZV) == 0:
return
Xn71 = Xn71[:, :, (2, 1, 0)]
if t7Mi:
LZpg, aNZO = QrM1.subplots(figsize=(12, 12))... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def sGG5(YKHO, NncF, hlel):\n for YRbF, edvT in enumerate(NncF):\n if edvT[2] > hlel.shape[1] or edvT[3] > hlel.shape[0] or edvT[0] < 0 or (edvT[1] < 0):\n continue\n XC5k.rectangle(oyIN.asarray(hlel), (edvT[0], edvT[1]), (edvT[2], edvT[3]), YKHO.colors[YRbF % len(YKHO.colors)], thickne... | [
"0.77598673",
"0.7638101",
"0.7510348",
"0.72977304",
"0.7150563",
"0.7103931",
"0.7101873",
"0.7083905",
"0.7020769",
"0.6993739",
"0.6974172",
"0.69637305",
"0.6859061",
"0.68521667",
"0.68319523",
"0.6830371",
"0.6809837",
"0.6805064",
"0.67750585",
"0.6774759",
"0.6742592... | 0.62219393 | 66 |
Build the inference graph and return a restore function. | def Mx4h(YKHO, dyeT, JMdk, V1C0):
YKHO.build_model()
FwwX = ZylS.train.ExponentialMovingAverage(0)
mK7E = FwwX.variables_to_restore(moving_avg_variables=[])
pnFH = {}
for H5ew, BWXx in mK7E.items():
if H5ew.split('/')[1] != 'State':
if 'alex_branch' not in H5ew:
i... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def hLQf(YKHO, pNZh):\n raise NotImplementedError()",
"def wBIE(YKHO):\n if YKHO._restored_model:\n return\n with YKHO.eval_graph.graph.as_default():\n x8fl = YKHO._find_last_checkpoint()\n jkyf = ZylS.train.Saver()\n jkyf.restore(YKHO._get_shared_session(train=False), x8fl)\... | [
"0.644398",
"0.6046613",
"0.5920403",
"0.5917145",
"0.574831",
"0.57001007",
"0.56683636",
"0.5567141",
"0.55618656",
"0.5517357",
"0.5481409",
"0.54638994",
"0.5452468",
"0.5444272",
"0.54388434",
"0.54125607",
"0.5385506",
"0.53719145",
"0.5359336",
"0.5335948",
"0.5302787"... | 0.5282441 | 25 |
Crop search images from the input image based on the last target position 1. The input image is scaled such that the area of target&context takes up to (scale_factor z_image_size) ^ 2 2. Crop an image patch as large as x_image_size centered at the target center. 3. If the cropped image region is beyond the boundary of ... | def i6oS(YKHO):
t9da = 127
Lkng = 255
ZwDX = 0.5
FE8A = 3
m_03 = oyIN.arange(FE8A) - cX4W(FE8A)
assert oyIN.sum(m_03) == 0, 'scales should be symmetric'
u7Zz = [1.0375 ** WKvO for WKvO in m_03]
viXW = ZylS.shape(YKHO.image)
nd5I = YKHO.target_bbox_feed[0:2]
SFa2 = YKHO.target_bbo... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def UYga(YKHO, LNo8, hgjH, zNig):\n fXzF, JPqE = hgjH\n wJAG, dEV_ = zNig\n Jarx, do44, FJP9 = LNo8.shape\n nJ9F = max(0, JPqE - dEV_ // 2)\n o4D3 = min(JPqE + dEV_ // 2, do44)\n nxyw = max(0, fXzF - wJAG // 2)\n si3g = min(fXzF + wJAG // 2, Jarx)\n Po4F = oyIN.array((int(nJ9F), int(nxyw), ... | [
"0.6662073",
"0.66186655",
"0.65173113",
"0.648923",
"0.63262296",
"0.62926817",
"0.6170863",
"0.6157938",
"0.6146192",
"0.61245394",
"0.61235154",
"0.6109681",
"0.60947025",
"0.609179",
"0.6091693",
"0.6066206",
"0.6057071",
"0.60365117",
"0.5987331",
"0.5971059",
"0.5943617... | 0.0 | -1 |
Test that we can handle invalid credentials. | async def test_form_invalid_auth(ajET: HomeAssistant):
Aofo = await ajET.config_entries.flow.async_init(Sugg, context={'source': kzTJ.SOURCE_USER})
assert Aofo['type'] == 'form'
assert Aofo['errors'] == {}
with Po4F('homeassistant.components.jellyfin.client_wrapper.ConnectionManager.connect_to_address',... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tGTl(YKHO):\n pass",
"def dOPl(YKHO):\n YKHO.user = {'username': 'testuserother', 'password': 'testpassword'}\n geh0 = YKHO.app.post('/auth/login/', data=YKHO.user)\n YKHO.assertEqual(geh0.status_code, 403)\n hlel = qQXR.loads(geh0.data.decode('utf-8'))\n YKHO.assertIn('Error: Invalid usern... | [
"0.82380414",
"0.7977701",
"0.79609525",
"0.7865408",
"0.7822999",
"0.7789407",
"0.75698763",
"0.75510335",
"0.7486272",
"0.74727374",
"0.73838264",
"0.73685277",
"0.7355993",
"0.7337308",
"0.73361886",
"0.7324551",
"0.7316063",
"0.7306323",
"0.7293369",
"0.72780913",
"0.7266... | 0.0 | -1 |
r"""Test for physical limits on GHI using the QCRad criteria. Test is applied to each GHI value. A GHI value passes if value > lower bound and value < upper bound. Lower bounds are constant for all tests. Upper bounds are calculated as | def uxE1(uwuO, Qfcr, Qd1_, c5uu=None):
if not c5uu:
c5uu = i69W
Lvir = QVZI(Qd1_, Qfcr, c5uu['ghi_ub'])
gPOp = C8Km.util.check_limits(uwuO, c5uu['ghi_lb'], Lvir)
return gPOp | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nuOa(WKvO, nEeK, ekgN):\n return WKvO >= nEeK and WKvO <= ekgN",
"def v61A(nPrm, C3ST, zAyo, Ze6a, ABDL=0.05, rU28=2e-12, LL2J=0.0001, Vx1B=False, **tURH):\n wyyA = {}\n\n def x_uD(DYPL):\n if DYPL not in wyyA:\n wyyA[DYPL] = r4nh(DYPL, nPrm, C3ST, return_expected_set=True, **tURH)... | [
"0.6575862",
"0.6303228",
"0.6134751",
"0.59900814",
"0.5861906",
"0.5856983",
"0.5749124",
"0.5735105",
"0.57121015",
"0.57084155",
"0.57033944",
"0.56618595",
"0.56572485",
"0.5634657",
"0.5609499",
"0.55907905",
"0.55706996",
"0.5570658",
"0.5559892",
"0.5553685",
"0.55536... | 0.5860386 | 5 |