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 |
|---|---|---|---|---|---|---|
Constructs a new com.oonics cdsl from given L{ComoonicsCdslRepository} and nodes. The constructor gets the needed nodes either from list (nodes) or from a given L{ComoonicsClusterInfo} but never from both! You can optional assign the creation timestamp manually. Additional the constructor is setting the default values ... | def FIMM(YKHO, zZcM, Hghu, DuMD, AWLI=None, Ziit=None, E3oo=None, Kg9y=False, RUFc=True, Kr79=True):
YKHO.reldir = Hy7s.getcwd()
YKHO._stripped = False
YKHO.logger = xPtQ.getLogger('comoonics.cdsl.ComCdsl.ComoonicsCdsl')
if Kr79 and (not YKHO._stripped):
zZcM = DuMD.stripsrc(zZcM, realpath=RUFc)... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, zZcM, Hghu, DuMD, AWLI=None, Ziit=None, E3oo=None, Kg9y=False):\n import xml.dom\n YKHO.nodes = None\n YKHO.src = YjPv(zZcM)\n YKHO.type = Hghu\n YKHO.cdslRepository = DuMD\n YKHO.clusterinfo = AWLI\n YKHO.logger = xPtQ.getLogger('comoonics.cdsl.ComCdsl.Cdsl')\n if E3oo != No... | [
"0.71507704",
"0.60291994",
"0.59704",
"0.5793857",
"0.57922906",
"0.5552139",
"0.55400586",
"0.5516831",
"0.53728974",
"0.5358035",
"0.5323422",
"0.53159463",
"0.5287707",
"0.5255791",
"0.5228723",
"0.52029294",
"0.51912016",
"0.5168908",
"0.5162963",
"0.51507616",
"0.514986... | 0.7340775 | 0 |
Load the specified model [[version]]. | def uyMl(YKHO):
YKHO.model = ZylS.keras.models.load_model(YKHO.model_path + f'RC_model_v{YKHO.version}.model') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tyeH(YKHO, DpZH: str=None) -> 'Model':\n boHx = lefo.get_model_repo(YKHO)\n boHx.load(model=YKHO, version=DpZH)\n return YKHO",
"def pv0b(YKHO, DpZH: int) -> None:\n YKHO._table.load_version(DpZH)",
"def Cmc8(Emd4, u0sQ, DpZH):\n return u0sQ.load()",
"def wX8m(YKHO, Ux0P=None, DpZH=None, v... | [
"0.7922484",
"0.7262836",
"0.7203275",
"0.70158905",
"0.6921715",
"0.69064397",
"0.69064397",
"0.6878474",
"0.6849172",
"0.68343705",
"0.6824065",
"0.6817897",
"0.6744571",
"0.67286664",
"0.67286664",
"0.67286664",
"0.67286664",
"0.6711535",
"0.66865903",
"0.6685931",
"0.6676... | 0.67304814 | 13 |
Assert that get_local_file_for_report is a simple passthrough. | def IPk3(YKHO):
g0Ak = YKHO.create_oci_downloader_with_mocked_values()
VUVw = YKHO.cost_file_path
JDwv = VUVw.replace('/', '_')
aqKe = g0Ak.get_local_file_for_report(VUVw)
YKHO.assertEqual(aqKe, JDwv) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GXcN(YKHO):\n return True",
"def VE3H(YKHO):\n hvL1 = _rEN.objects.create(datafile=IXDF(YKHO.filename, 'Coffee is delicious!'), source=YKHO.path_source, sharename=YKHO.sharename)\n YKHO.assertEqual(UHRq(hvL1.get_datafile_url()), '{}://{}{}'.format(gCuF.REFINERY_URL_SCHEME, HAC5.objects.get_current()... | [
"0.6609638",
"0.6323701",
"0.6145655",
"0.5969341",
"0.5936853",
"0.59030795",
"0.5889903",
"0.5877116",
"0.585474",
"0.5843631",
"0.57689524",
"0.57689524",
"0.56922114",
"0.5681707",
"0.5681426",
"0.5661535",
"0.5661506",
"0.5655552",
"0.5654143",
"0.5641446",
"0.5633763",
... | 0.74556273 | 0 |
Test if subscriber edit works as expected | def yqxx(YKHO):
emU_, TISt = YKHO._add_subscriber('IMSI11111')
YKHO.assertEqual(YKHO._store.get_subscriber_data(emU_), TISt)
YKHO.assertEqual(YKHO._store._cache_list(), [emU_])
with YKHO._store.edit_subscriber(emU_) as zbDt:
zbDt.lte.auth_key = b'5678'
YKHO.assertEqual(YKHO._store.get_subscr... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def fwbx(YKHO):\n oWcl = 2\n Fn_2 = '000'\n uP3D = '00000'\n qpDA = HAC5.objects.get(id=1)\n dnK9 = ntk4(oWcl, Fn_2, uP3D, qpDA)\n print(dnK9)\n YKHO.assertTrue(dnK9)",
"def Kasu(YKHO):\n D5uW = 'Test Edit Publisher'\n SgBP = 'http://www.example.com/edit-publisher/'\n tF2v = 'edit-p... | [
"0.719711",
"0.6735219",
"0.6677225",
"0.667465",
"0.6595062",
"0.65299207",
"0.6471859",
"0.6467421",
"0.6303302",
"0.6287222",
"0.6267636",
"0.62590367",
"0.62518144",
"0.62473416",
"0.6208891",
"0.6196944",
"0.61845416",
"0.61675143",
"0.6148968",
"0.61400884",
"0.6139554"... | 0.7665626 | 0 |
Initialize the Index Analyzer. | def FIMM(YKHO, V_s1, dqiQ):
super(UVis, YKHO).__init__(V_s1, dqiQ)
YKHO.intel = {}
YKHO.yeti_api_root = wk5E.config.get('YETI_API_ROOT')
YKHO.yeti_api_key = wk5E.config.get('YETI_API_KEY')
YKHO.yeti_indicator_labels = wk5E.config.get('YETI_INDICATOR_LABELS', []) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO) -> None:\n YKHO.resources_path = Hy7s.path.join(Hy7s.path.dirname(xAKo), 'resources')\n with open(Hy7s.path.join(YKHO.resources_path, 'index_info.json'), 'r') as cnTr:\n YKHO.index_config = qQXR.load(cnTr)\n YKHO.current_global_index = None\n YKHO.GLOBAL_INDEX_INTERVAL = jaOU\n ... | [
"0.7425721",
"0.7224529",
"0.7224529",
"0.7168353",
"0.7168353",
"0.7168353",
"0.71070117",
"0.7045436",
"0.6937496",
"0.68099254",
"0.67915463",
"0.6759593",
"0.67400396",
"0.66372776",
"0.66233647",
"0.66156274",
"0.66096956",
"0.6606075",
"0.65973467",
"0.65970653",
"0.659... | 0.0 | -1 |
Retrieves a list of indicators associated to a given entity. | def MYFF(YKHO, g2g3):
dixj = G4JS.post(YKHO.yeti_api_root + '/entities/{0:s}/neighbors/'.format(g2g3), headers={'X-Yeti-API': YKHO.yeti_api_key})
if dixj.status_code != 200:
return []
Z0oU = []
for AAbN in dixj.json().get('vertices', {}).values():
if AAbN['type'] == 'x-regex' and set(YKH... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FMrR(x0hE: Client, qoqK=None, vgXP=None):\n ikfC = x0hE.build_iterator(qoqK, vgXP)\n return ikfC",
"def tNg1(YKHO, if3b: str='Indicators', NArs: dict=None) -> x1iM:\n NArs = NArs or {}\n try:\n bD7m = f'/v4/{gAu2[if3b]}'\n geh0 = YKHO._http_request(method='GET', url_suffix=bD7m, tim... | [
"0.655762",
"0.6164885",
"0.61644083",
"0.5999883",
"0.5885113",
"0.58556175",
"0.57984126",
"0.5634988",
"0.5519085",
"0.5485876",
"0.5482592",
"0.5478628",
"0.542854",
"0.5396721",
"0.5370713",
"0.5353638",
"0.533774",
"0.5335818",
"0.5304671",
"0.5294913",
"0.52921945",
... | 0.4965183 | 38 |
Get the address for a classical register. | def gczd(Z9rn):
if not (isinstance(Z9rn, iL8K) or isinstance(Z9rn, (list, levz))):
raise TypeError('c should be an int or list or Addr')
if isinstance(Z9rn, list) and (len(Z9rn) != 1 or not isinstance(Z9rn[0], int)):
raise ValueError('if c is a list, it should be of 1 int')
if isinstance(Z9r... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ceuN(YKHO) -> RnTg.program.model.address.Address:\n ...",
"def ceuN(YKHO) -> RnTg.program.model.address.Address:\n ...",
"def ceuN(YKHO) -> RnTg.program.model.address.Address:\n ...",
"def vAkW(YKHO):\n raise NotImplementedError",
"def lQ3t(YKHO, rRzo):\n return YKHO.regs[rRzo]",
"def ... | [
"0.70522237",
"0.70522237",
"0.70522237",
"0.6990167",
"0.69528663",
"0.69111884",
"0.69034463",
"0.68521357",
"0.6827523",
"0.6795793",
"0.67881554",
"0.67881554",
"0.67881554",
"0.67825985",
"0.67825985",
"0.675583",
"0.6748038",
"0.67229635",
"0.6697024",
"0.66644776",
"0.... | 0.0 | -1 |
Create a cell with hidden state and memory zoneout. If this class is used to wrap a Dropout cell, then it will override the output Dropout but maintain input Dropout. If a Dropout cell wraps a Zoneout cell, then both Dropout and Zoneout will be applied to the outputs. This function assumes that LSTM Cells are using the... | def FIMM(YKHO, VmPb, WWRv=1.0, EGpF=1.0, yokr=None, LT6S=True):
if isinstance(WWRv, float) and (not (WWRv >= 0.0 and WWRv <= 1.0)):
raise ValueError('Parameter memory_cell_keep_prob must be between 0 and 1: %d' % WWRv)
if isinstance(EGpF, float) and (not (EGpF >= 0.0 and EG... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, VmPb, WWRv=1.0, EGpF=1.0, yokr=None, LT6S=True, **B2fa):\n super(DL4C, YKHO).__init__(**B2fa)\n if isinstance(WWRv, float) and (not 0.0 <= WWRv <= 1.0):\n raise ValueError('Parameter memory_cell_keep_prob must be between 0 and 1: %d' % WWRv)\n if isinstance(EGpF, float) and (not 0.0 ... | [
"0.75232095",
"0.6769459",
"0.6720653",
"0.66611004",
"0.6456445",
"0.627242",
"0.621293",
"0.61597615",
"0.6109425",
"0.59687805",
"0.59463966",
"0.58953744",
"0.5861767",
"0.5827386",
"0.5815764",
"0.5802401",
"0.57598215",
"0.5708692",
"0.5683884",
"0.5612572",
"0.5605345"... | 0.62104416 | 7 |
Returns this blog's URL and domain. | def ozj4(YKHO, OUVJ):
return (YKHO.url, YKHO.key.id()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rK2Y(YKHO):\n raise NotImplementedError",
"def zrIJ(YKHO):\n ht58, GbKX, *bGrB = YKHO.components\n return m7V9(uRlK.parse.urlunsplit((ht58, GbKX, '', '', '')))",
"def UWNm(YKHO) -> str:\n return YKHO.request.host_url",
"def zrIJ(YKHO):\n hyEb = KVWQ(YKHO.url)\n return '%s://%s' % (hyEb.... | [
"0.7258827",
"0.7230118",
"0.71630955",
"0.71500623",
"0.7129801",
"0.7069671",
"0.7066249",
"0.70388865",
"0.7034683",
"0.7034683",
"0.70151436",
"0.69939226",
"0.69614464",
"0.69461876",
"0.69245803",
"0.6902549",
"0.6862701",
"0.6839611",
"0.68372905",
"0.6787548",
"0.6774... | 0.0 | -1 |
Generate a hash presentation for the provided plain text password. | def qzFd(YKHO, cVwz):
return YKHO._hasher.hash(cVwz) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def OoXC(bHqp: str) -> str:\n return B8ni.hashpw(bHqp, B8ni.gensalt())",
"def qzFd(YKHO, M56W):\n NTfD = qxeD.uuid4().hex\n hNw5 = YKHO.get_hash(NTfD, M56W)\n return NTfD + '$' + hNw5",
"def SV6u(dQrR):\n r8hN = FOht.new()\n r8hN.update(fj5c.str_to_bytes(P4t4.config.get('PWD_SALT')))\n r8h... | [
"0.7468994",
"0.7201801",
"0.71953475",
"0.7119826",
"0.68801165",
"0.68436146",
"0.6822993",
"0.68013597",
"0.6791495",
"0.6777237",
"0.6770634",
"0.6682069",
"0.6668535",
"0.6633732",
"0.6631636",
"0.66150254",
"0.6597719",
"0.6587109",
"0.65566117",
"0.6553545",
"0.65494",... | 0.73169833 | 1 |
Creates an empty BST. | def FIMM(YKHO, ZKAx=rvhu):
YKHO.node_class = ZKAx
YKHO.root = None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def WNcL():\n return UmtR()",
"def j6mc():\n kcpT = UmtR(5)\n kcpT.insert(10)\n kcpT.insert(1)\n kcpT.insert(9)\n kcpT.insert(3)\n kcpT.insert(6)\n kcpT.insert(2)\n kcpT.insert(4)\n kcpT.insert(8)\n kcpT.insert(7)\n return kcpT",
"def s_fx():\n from bst import Tree\n k... | [
"0.7832857",
"0.74070275",
"0.74068004",
"0.72196764",
"0.71010876",
"0.70857155",
"0.69469875",
"0.68618023",
"0.68260205",
"0.6775896",
"0.6758248",
"0.6748789",
"0.6728831",
"0.67184216",
"0.66808194",
"0.66796464",
"0.66456497",
"0.6628553",
"0.66196954",
"0.6531575",
"0.... | 0.6055101 | 40 |
The node with the given key in this BST. | def neBz(YKHO, H5ew):
return YKHO.root and YKHO.root.find(H5ew) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def IyQV(YKHO, H5ew):\n \"\"\"Takes an integer representing a key in the tree.\n Returns a node in the tree that contains the given key.\"\"\"\n XP5J = YKHO.root\n while XP5J and XP5J.key != H5ew:\n if H5ew < XP5J.key:\n XP5J = XP5J.left\n else:\n XP5J = XP5J.rig... | [
"0.85340035",
"0.826778",
"0.8266112",
"0.8243921",
"0.81512034",
"0.8139652",
"0.8139652",
"0.81052023",
"0.8035026",
"0.7885612",
"0.7839608",
"0.78082925",
"0.76968586",
"0.7670314",
"0.766462",
"0.7660018",
"0.763385",
"0.7610734",
"0.7606828",
"0.76035935",
"0.7563474",
... | 0.0 | -1 |
Inserts a node into the subtree rooted at this node. | def JPHp(YKHO, H5ew):
Q6kx = YKHO.node_class(H5ew)
if YKHO.root is None:
YKHO.root = Q6kx
return Q6kx
return YKHO.root.insert(Q6kx) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zEoa(YKHO, Q6kx):\n YKHO._insert_node(Q6kx, YKHO.root)",
"def JPHp(YKHO, Q6kx):\n if not type(Q6kx) == o7DN:\n Q6kx = o7DN(Q6kx)\n if not YKHO.root:\n YKHO.root = Q6kx\n else:\n YKHO._insert_recursive(YKHO.root, Q6kx)",
"def zEoa(YKHO, Q6kx: TreeNode):\n YKHO.insert_path... | [
"0.84230274",
"0.82739556",
"0.80224013",
"0.78107786",
"0.7740392",
"0.773985",
"0.77310485",
"0.7644019",
"0.7637566",
"0.7630259",
"0.76126426",
"0.7608562",
"0.7586803",
"0.7553728",
"0.7553134",
"0.7526692",
"0.7525744",
"0.7521783",
"0.7501646",
"0.74958897",
"0.7495701... | 0.70921355 | 53 |
Get or set the position of the square. | def dQgj(YKHO):
return YKHO.__position | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def dQgj(YKHO):\n return YKHO._Square__position",
"def dQgj(YKHO):\n return YKHO._Square__position",
"def blVz(YKHO):\n return YKHO._pos",
"def u8AJ(YKHO, oeNL):\n YKHO._pos = oeNL",
"def TwAD(YKHO):\n YKHO.x = YKHO.col * sGMQ + sGMQ // 2\n YKHO.y = YKHO.row * sGMQ + sGMQ // 2",
"def bl... | [
"0.7761973",
"0.7761973",
"0.76316273",
"0.72926843",
"0.7258397",
"0.69127655",
"0.68048567",
"0.67441815",
"0.6727386",
"0.6718699",
"0.6714193",
"0.6708692",
"0.6660001",
"0.6655652",
"0.66357064",
"0.6622066",
"0.6622066",
"0.6622066",
"0.6622066",
"0.6584461",
"0.6584461... | 0.63360703 | 54 |
Returns the current square area. | def f0tD(YKHO):
return YKHO.__size ** 2 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def f0tD(YKHO):\n return YKHO._Square__size ** 2",
"def f0tD(YKHO):\n return YKHO._Square__size ** 2",
"def f0tD(YKHO):\n return YKHO.__width * YKHO.__height",
"def f0tD(YKHO):\n return YKHO.h * YKHO.w",
"def f0tD(YKHO):\n return YKHO.__width * YKHO.__height",
"def f0tD(YKHO):\n return ... | [
"0.8475426",
"0.8377859",
"0.82965326",
"0.829468",
"0.82938564",
"0.82772475",
"0.82772475",
"0.82772475",
"0.82608664",
"0.82562566",
"0.82562566",
"0.8236908",
"0.82298374",
"0.82298374",
"0.82245374",
"0.82245374",
"0.82245374",
"0.82245374",
"0.8209012",
"0.8209012",
"0.... | 0.78616124 | 84 |
This method is called when a class is subclassed. The default implementation does nothing. It may be overridden to extend subclasses. | def kblH(YKHO, *qIxc, **B2fa):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def b8V_(YKHO):\n print('Subclass and over-ride this method.')",
"def FIMM(YKHO):\n super().__init__(None)",
"def FIMM(YKHO):\n pass",
"def hQ7u(YKHO, *qIxc, **B2fa):\n pass",
"def hQ7u(YKHO, *qIxc, **B2fa):\n pass",
"def hQ7u(YKHO, *qIxc, **B2fa):\n pass",
"def hQ7u(YKHO, *qIxc, **B2... | [
"0.7978994",
"0.7120676",
"0.7114939",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
"0.70904213",
... | 0.0 | -1 |
Checks if the current channel or user is ignored. Bot owners and guild managers can bypass this. | async def __global_check_once(YKHO, OaeV: NabCtx):
if OaeV.guild is None:
return True
if await tZoW.is_owner(OaeV):
return True
if OaeV.author_permissions.manage_guild:
return True
return not await YKHO.is_ignored(OaeV.pool, OaeV) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def ignored_channel_or_guild(YKHO, OaeV: commands.Context) -> bool:\n awnO = OaeV.channel.permissions_for(OaeV.author)\n bkSu = isinstance(OaeV.channel, ZOrr.abc.PrivateChannel) or awnO.manage_guild or await OaeV.bot.is_owner(OaeV.author) or await OaeV.bot.is_admin(OaeV.author)\n if bkSu:\n r... | [
"0.7795993",
"0.711791",
"0.71024835",
"0.6768026",
"0.67538935",
"0.67445076",
"0.67345315",
"0.6715419",
"0.6627156",
"0.6616395",
"0.6555079",
"0.6551429",
"0.6551429",
"0.6551429",
"0.65077025",
"0.64809483",
"0.644235",
"0.63699716",
"0.6321694",
"0.6292461",
"0.62911457... | 0.6590163 | 10 |
Shows a list of ignored channels and users. | async def ignore_list(YKHO, OaeV: NabCtx):
xDcj = 'SELECT entry_id FROM ignored_entry WHERE server_id = $1'
usx6 = await OaeV.pool.fetch(xDcj, OaeV.guild.id)
VECZ = [pVLs(OaeV.guild, tTpl[0]) for tTpl in usx6]
if not VECZ:
await OaeV.send('There are no ignored entries in this server.')
r... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def display_ignoredchannel(YKHO, OaeV):\n Fjim = await YKHO.config.guild(OaeV.guild).ignored_channels()\n if not Fjim:\n return await OaeV.send('No channels are being ignored.')\n if len(Fjim) > 1:\n Ol8d = 'Channels on ignorelist:'\n else:\n Ol8d = 'Channel on ignorelist:'\n... | [
"0.78814536",
"0.73781",
"0.66595006",
"0.6516035",
"0.6292125",
"0.61832756",
"0.6151022",
"0.6040077",
"0.6001298",
"0.596997",
"0.5886956",
"0.58716065",
"0.5856894",
"0.5848878",
"0.58158404",
"0.5755581",
"0.5752932",
"0.5748462",
"0.57362026",
"0.57121575",
"0.5705643",... | 0.55914366 | 29 |
Makes the bot say a message. If it's used directly on a text channel, the bot will delete the command's message and repeat it itself. Note that deleting the message requires `Manage Messages` permissions in the channel. If it's used on a private message, the bot will ask on which channel he should say the message. Each... | async def makesay(YKHO, OaeV: NabCtx, *, Ol8d: str):
if OaeV.is_private:
eC5J = []
SS7a = []
CFyp = None
mLGw = 1
for N5z6 in YKHO.bot.guilds:
taDc = N5z6.get_member(OaeV.author.id)
PnQA = YKHO.bot.get_member(YKHO.bot.user.id, N5z6)
if taDc... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def say(YKHO, OaeV, YwkQ: Optional[TextChannel]=None, *, l5Ny: str):\n if not YwkQ:\n YwkQ = OaeV.channel\n try:\n await OaeV.message.delete()\n except Exception:\n pass\n finally:\n await YwkQ.send(l5Ny)",
"async def say(YKHO, OaeV, *, Ol8d: str):\n try:\n ... | [
"0.7705467",
"0.76185995",
"0.7411374",
"0.7303154",
"0.7281443",
"0.72216386",
"0.71885115",
"0.71014065",
"0.7083791",
"0.70791656",
"0.70331764",
"0.7030018",
"0.69740653",
"0.696502",
"0.6959585",
"0.6959585",
"0.6851912",
"0.6802797",
"0.676609",
"0.6709436",
"0.6706261"... | 0.6512235 | 35 |
Checks if the current context is ignored. A context could be ignored because either the channel or the user are in the ignored list. | async def is_ignored(Emd4, w2B8, OaeV: NabCtx):
xDcj = 'SELECT True FROM ignored_entry WHERE server_id=$1 AND (entry_id=$2 OR entry_id=$3);'
return await w2B8.fetchrow(xDcj, OaeV.guild.id, OaeV.channel.id, OaeV.author.id) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"async def ignored_channel_or_guild(YKHO, OaeV: commands.Context) -> bool:\n awnO = OaeV.channel.permissions_for(OaeV.author)\n bkSu = isinstance(OaeV.channel, ZOrr.abc.PrivateChannel) or awnO.manage_guild or await OaeV.bot.is_owner(OaeV.author) or await OaeV.bot.is_admin(OaeV.author)\n if bkSu:\n r... | [
"0.7121506",
"0.6760109",
"0.6719912",
"0.6719912",
"0.66787916",
"0.6579927",
"0.6561122",
"0.6544915",
"0.64246386",
"0.6414963",
"0.633266",
"0.625335",
"0.6082214",
"0.59796846",
"0.5942662",
"0.5933853",
"0.58730805",
"0.5840988",
"0.582595",
"0.57458305",
"0.5733017",
... | 0.5627387 | 31 |
Convenience method for error response body | def H3xS(JBvl=500, Ol8d=None, nPrm=None):
return gJfj(status='error', status_code=JBvl, message=Ol8d, data=nPrm) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P1dF(YKHO, P1dF, Ol8d=None):\n return pz3A({'error': P1dF.status_code, 'message': P1dF.body or Ol8d})",
"def P1dF(YKHO, P1dF, Ol8d=None):\n return YKHO._jsonify({'error': P1dF.status_code, 'message': P1dF.body or Ol8d}, '')",
"def Ipbc(YKHO, P1dF):\n return eOg6(P1dF)",
"def RdjZ(Zjhd: dict) -> ... | [
"0.7693917",
"0.7690315",
"0.7675932",
"0.74805886",
"0.7451648",
"0.7292147",
"0.7239284",
"0.7209805",
"0.71792734",
"0.71768904",
"0.7161424",
"0.7159097",
"0.7155836",
"0.71497756",
"0.712273",
"0.7104673",
"0.7104287",
"0.7089937",
"0.7087514",
"0.70799714",
"0.7036187",... | 0.7045052 | 20 |
Generates the characters from `c1` to `c2`, inclusive. | def KbDL(dg7v, iYf1):
for Z9rn in range(ord(dg7v), ord(iYf1) + 1):
yield chr(Z9rn) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def KbDL(dg7v, iYf1):\n for Z9rn in Ni9Y(ord(dg7v), ord(iYf1) + 1):\n yield chr(Z9rn)",
"def KbDL(dg7v, iYf1):\n for Z9rn in Ni9Y(ord(dg7v), ord(iYf1) + 1):\n yield chr(Z9rn)",
"def KbDL(dg7v, iYf1):\n for Z9rn in Ni9Y(ord(dg7v), ord(iYf1) + 1):\n yield chr(Z9rn)",
"def KbDL(dg7... | [
"0.8356534",
"0.8356534",
"0.8356534",
"0.8356534",
"0.8331273",
"0.83226156",
"0.8204458",
"0.6699442",
"0.6647206",
"0.61913",
"0.5943554",
"0.59274966",
"0.59238946",
"0.5885765",
"0.5748631",
"0.5706302",
"0.56295216",
"0.5601662",
"0.555903",
"0.55176365",
"0.5477277",
... | 0.83031625 | 6 |
Loads model and return it without DataParallel table. | def uyMl(pmON, I5o3):
if Hy7s.path.isfile(pmON):
vauY = ht2j.load(pmON)
ywwl = vauY['state_dict']['top_layer.bias'].size()
PCa9 = 'sobel.0.weight' in vauY['state_dict'].keys()
C3ST = FYrf.vgg16(pretrained=None)
C3ST.classifier = U78l.Sequential(U78l.Linear(512 * 7 * 7, 4096),... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uyMl():\n return None",
"def uyMl():\n return",
"def uyMl():\n pass",
"def uyMl():\n pass",
"def uyMl(YKHO):\n with YKHO._wl:\n return YKHO._e.load_model()",
"def uyMl(YKHO):\n NotImplementedError()",
"def uyMl(YKHO):\n pass",
"def uyMl(YKHO):\n pass",
"def uyMl(Y... | [
"0.7883188",
"0.7785034",
"0.7628681",
"0.7628681",
"0.75084066",
"0.743676",
"0.7391774",
"0.7391774",
"0.7391774",
"0.7391774",
"0.7347385",
"0.7267801",
"0.71716595",
"0.7038426",
"0.7031104",
"0.7009149",
"0.69933736",
"0.69740635",
"0.69575405",
"0.6951241",
"0.6948648",... | 0.0 | -1 |
Get a list of nodes and return a sorted version of it such that every node in the returned list comes after its predecessors in the graph that contains them. | def u_ys(YKHO, Ziit, aaHl):
kXSl = []
while len(Ziit) > 0:
ZNsy = 0
for Q6kx in Ziit:
if not Q6kx.isReady(aaHl):
Ziit[ZNsy] = Q6kx
ZNsy += 1
else:
kXSl.append(Q6kx)
aaHl[Q6kx] = True
del Ziit[ZNsy:]
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _Ypz(YKHO) -> list:\n Ylbp = []\n azXi = set()\n\n def K2kF(WKvO):\n azXi.add(WKvO)\n for LVAh in YKHO._graph[WKvO]:\n if LVAh not in azXi:\n K2kF(LVAh)\n Ylbp.append(WKvO)\n for Ty9i in YKHO._graph:\n if Ty9i not in azXi:\n K2kF(Ty9i... | [
"0.71168953",
"0.7042392",
"0.69949156",
"0.6938998",
"0.690035",
"0.67938197",
"0.67817533",
"0.67580855",
"0.6716388",
"0.6705476",
"0.6691364",
"0.66793245",
"0.6631187",
"0.66116565",
"0.65753543",
"0.65502524",
"0.6543255",
"0.6534537",
"0.65110177",
"0.6501907",
"0.6495... | 0.65085447 | 19 |
returns best move calculated till depth given | def FSwB(iBIi: GameState, qi10: int) -> AzJI[float, P_ka]:
Oik8 = ITS7()
global eval_time, moves_cnt, evals_cnt
fgxT = 0
fuuY = 0
nHBr = 0
oLdq = iBIi.getValidMoves()
u54L = len(oLdq)
Rf07 = max(1, u54L // 6)
TmLH: x1iM[x1iM[P_ka]] = []
iIZ1: x1iM[ASOO] = []
twdA: x1iM[MAqI] ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Jwcz(YKHO, iBIi):\n if iBIi.get_number_of_moves_made() < 7:\n qi10 = 5\n elif iBIi.get_number_of_moves_made() < 15:\n qi10 = 6\n else:\n qi10 = 7\n if YKHO.ai_level == 3:\n rb7a = min(qi10, KHMu)\n elif YKHO.ai_level == 2:\n rb7a = min(qi10, JR4J)\n else:\n ... | [
"0.7873701",
"0.7789582",
"0.7686803",
"0.76757026",
"0.76702535",
"0.765915",
"0.76179343",
"0.761634",
"0.75646156",
"0.75396144",
"0.7508496",
"0.7471517",
"0.7446386",
"0.74362326",
"0.7369043",
"0.73592615",
"0.72704995",
"0.72645754",
"0.72374225",
"0.7205462",
"0.72045... | 0.6881888 | 52 |
Searches for key in the cached dictionary Uses fuzzywuzzy to find similar results, updated the TriggerInstance and returns the found trigger. | def nLY7(H5ew, DVsZ):
kUBT = NBjn.extract(H5ew, hbci[str(DVsZ)], processor=None, scorer=IYPf.ratio, limit=1)
if kUBT[0][1] > 90:
H5ew = kUBT[0][0]
with mnO2.open(Z9rn.SHELVE_TRIGGERS) as NCls:
nPrm = NCls[str(DVsZ)]
iqFZ = nPrm[H5ew]
iqFZ.num_of_uses += 1
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def EOaT(YKHO, H5ew):\n return YKHO.lookup[H5ew]",
"def EOaT(YKHO, H5ew):\n return YKHO.lookup[H5ew]",
"def neBz(YKHO, H5ew):\n EmMj = YKHO.search(H5ew)\n if EmMj.key == H5ew:\n return EmMj\n return None",
"def ijxN(YKHO, JyK9):\n UzPC.close()\n YKHO.keywords = {}\n YKHO.catego... | [
"0.5684037",
"0.5684037",
"0.56136423",
"0.5558047",
"0.53916085",
"0.5257792",
"0.5210354",
"0.51886135",
"0.5168354",
"0.5155462",
"0.5153192",
"0.5137107",
"0.5100538",
"0.50921553",
"0.50653225",
"0.5028621",
"0.5020526",
"0.5013143",
"0.5005017",
"0.49929917",
"0.4986966... | 0.67956096 | 0 |
Generation of four digit random number | def gTYQ():
global _hidden_number
r9W3 = []
for Ko6S in range(rhDx):
_9an = 1 if Ko6S == 0 else 0
r9W3.append(ajWY(_9an, 9))
return r9W3 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gkKB():\n return str(ajWY(1000, 9999)).zfill(4)",
"def ZCYd(exwG=4):\n bqSJ = 10 ** (exwG - 1)\n W4ky = 10 ** exwG - 1\n return str(ajWY(bqSJ, W4ky))",
"def dM2g():\n mSrU = tuKI.randint(10 ** 8, 10 ** 9)\n return f'0{mSrU}'",
"def ir9U():\n WKvO = YKHO.gs[0] * 2 & 255\n jzdc = WK... | [
"0.79765385",
"0.7774454",
"0.73904234",
"0.73552305",
"0.7283753",
"0.7181498",
"0.7113229",
"0.71109873",
"0.70786893",
"0.70679647",
"0.70626676",
"0.7044653",
"0.7039135",
"0.7039135",
"0.7035582",
"0.7029017",
"0.7017073",
"0.69732636",
"0.69701993",
"0.69685394",
"0.696... | 0.0 | -1 |
Testing StatusUpdate.is_mutable_by with anonymous user | def M894(YKHO):
lnN1 = YKHO.create_review_request()
G2uS = YKHO.create_status_update(lnN1)
YKHO.assertFalse(G2uS.is_mutable_by(fCU0())) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def iUQ3(YKHO):\n lnN1 = YKHO.create_review_request()\n G2uS = YKHO.create_status_update(lnN1)\n YKHO.assertTrue(G2uS.is_mutable_by(G2uS.user))",
"def u9wV(YKHO):\n g_7i = mv1M.objects.create(username='other-user')\n lnN1 = YKHO.create_review_request()\n G2uS = YKHO.create_status_update(lnN1)\n... | [
"0.8155139",
"0.7996921",
"0.7835565",
"0.7553182",
"0.73759985",
"0.66526306",
"0.6575005",
"0.657036",
"0.64169896",
"0.640302",
"0.6334172",
"0.6325104",
"0.62931514",
"0.62454766",
"0.62071615",
"0.6206385",
"0.6188133",
"0.6141595",
"0.61238",
"0.6118901",
"0.6095685",
... | 0.89254016 | 0 |
Testing StatusUpdate.is_mutable_by with owner | def iUQ3(YKHO):
lnN1 = YKHO.create_review_request()
G2uS = YKHO.create_status_update(lnN1)
YKHO.assertTrue(G2uS.is_mutable_by(G2uS.user)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def u9wV(YKHO):\n g_7i = mv1M.objects.create(username='other-user')\n lnN1 = YKHO.create_review_request()\n G2uS = YKHO.create_status_update(lnN1)\n YKHO.assertFalse(G2uS.is_mutable_by(g_7i))",
"def SfpN(YKHO):\n g_7i = mv1M.objects.create(username='other-user')\n g_7i.user_permissions.add(CXiN... | [
"0.8173176",
"0.7989794",
"0.7704432",
"0.7260297",
"0.6801771",
"0.6779081",
"0.64529264",
"0.64293635",
"0.6341576",
"0.63222885",
"0.6308206",
"0.6300045",
"0.6292418",
"0.6289154",
"0.6281364",
"0.6254526",
"0.6251008",
"0.6246361",
"0.6238999",
"0.62353146",
"0.62212425"... | 0.9099363 | 0 |
Testing StatusUpdate.is_mutable_by with other user | def u9wV(YKHO):
g_7i = mv1M.objects.create(username='other-user')
lnN1 = YKHO.create_review_request()
G2uS = YKHO.create_status_update(lnN1)
YKHO.assertFalse(G2uS.is_mutable_by(g_7i)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def iUQ3(YKHO):\n lnN1 = YKHO.create_review_request()\n G2uS = YKHO.create_status_update(lnN1)\n YKHO.assertTrue(G2uS.is_mutable_by(G2uS.user))",
"def SfpN(YKHO):\n g_7i = mv1M.objects.create(username='other-user')\n g_7i.user_permissions.add(CXiN.objects.get(codename='change_statusupdate'))\n ... | [
"0.87525505",
"0.8594535",
"0.8008382",
"0.79462403",
"0.7582163",
"0.67457813",
"0.67191637",
"0.66577536",
"0.65724736",
"0.6514673",
"0.64827144",
"0.64566237",
"0.6418252",
"0.64025515",
"0.63997436",
"0.63782895",
"0.6342769",
"0.63077193",
"0.62965244",
"0.62929106",
"0... | 0.87380683 | 1 |
Testing StatusUpdate.is_mutable_by with other user with change_statusupdate permission | def SfpN(YKHO):
g_7i = mv1M.objects.create(username='other-user')
g_7i.user_permissions.add(CXiN.objects.get(codename='change_statusupdate'))
lnN1 = YKHO.create_review_request()
G2uS = YKHO.create_status_update(lnN1)
YKHO.assertTrue(G2uS.is_mutable_by(g_7i)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def iUQ3(YKHO):\n lnN1 = YKHO.create_review_request()\n G2uS = YKHO.create_status_update(lnN1)\n YKHO.assertTrue(G2uS.is_mutable_by(G2uS.user))",
"def u9wV(YKHO):\n g_7i = mv1M.objects.create(username='other-user')\n lnN1 = YKHO.create_review_request()\n G2uS = YKHO.create_status_update(lnN1)\n... | [
"0.853695",
"0.84334314",
"0.79982626",
"0.756331",
"0.69896394",
"0.69393784",
"0.69262415",
"0.6580329",
"0.6491937",
"0.6464043",
"0.64511853",
"0.6390412",
"0.63804114",
"0.6332569",
"0.6321259",
"0.63118804",
"0.6301077",
"0.6278686",
"0.6278212",
"0.6273559",
"0.6240829... | 0.8868086 | 0 |
Testing StatusUpdate.is_mutable_by with other user on same LocalSite with change_statusupdate permission | def yITO(YKHO):
lnN1 = YKHO.create_review_request(with_local_site=True)
G2uS = YKHO.create_status_update(lnN1)
g_7i = mv1M.objects.create(username='other-user')
qpDA = lnN1.local_site
qpDA.users.add(g_7i)
Gyd1 = g_7i.get_site_profile(qpDA)
Gyd1.permissions = {'reviews.change_statusupdate': T... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SfpN(YKHO):\n g_7i = mv1M.objects.create(username='other-user')\n g_7i.user_permissions.add(CXiN.objects.get(codename='change_statusupdate'))\n lnN1 = YKHO.create_review_request()\n G2uS = YKHO.create_status_update(lnN1)\n YKHO.assertTrue(G2uS.is_mutable_by(g_7i))",
"def u9wV(YKHO):\n g_7i ... | [
"0.8337042",
"0.7877368",
"0.78335315",
"0.72661424",
"0.679321",
"0.6702548",
"0.66923404",
"0.6644496",
"0.6562805",
"0.6461707",
"0.6345261",
"0.6135751",
"0.6134145",
"0.6131047",
"0.6123316",
"0.60872996",
"0.6041954",
"0.6038517",
"0.59635746",
"0.5961343",
"0.5925115",... | 0.86420965 | 0 |
Adds two numbers that are represented as Strings Takes two numbers, each represented as a string, and finds the sum. The numbers, as with the result, can be significantly large (above max integer size). | def H2v5(jzdc, Fg_i):
jzdc = jzdc[::-1]
Fg_i = Fg_i[::-1]
QAki = 0
mSrU = []
for YRbF in range(0, max(len(jzdc), len(Fg_i))):
D9cM = 0 if len(jzdc) <= YRbF else int(jzdc[YRbF])
edvT = 0 if len(Fg_i) <= YRbF else int(Fg_i[YRbF])
Aofo = D9cM + edvT + QAki
wQKG = Aofo % ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kaRx(Y0Fj, Pb4f):\n j93S = list(Y0Fj)\n Nqp_ = list(Pb4f)\n lX69 = len(j93S) - 1\n lb_w = len(Nqp_) - 1\n Aofo = 0\n ounV = 1\n if j93S[0] == '0' or Nqp_[0] == '0':\n return None\n while lX69 >= 0 or lb_w >= 0:\n if lX69 >= 0 and (not j93S[lX69].isdigit()):\n re... | [
"0.8160145",
"0.7530814",
"0.74722725",
"0.73384786",
"0.73376065",
"0.71675795",
"0.70221716",
"0.6908308",
"0.69012773",
"0.68999827",
"0.6811705",
"0.6781064",
"0.67605287",
"0.6714824",
"0.669307",
"0.6664914",
"0.6662589",
"0.6649698",
"0.6632143",
"0.6617386",
"0.659288... | 0.73432016 | 3 |
Generates a random number of size n. Generates a random number containing digits. This number is represented as a string to enable generating very large numbers. | def C6M2(exwG):
ANfV = str(tuKI.randint(1, 9)) + ''.join([str(tuKI.randint(0, 9)) for bGrB in range(1, exwG)])
return ANfV | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZCYd(exwG=4):\n bqSJ = 10 ** (exwG - 1)\n W4ky = 10 ** exwG - 1\n return str(ajWY(bqSJ, W4ky))",
"def oYcK(exwG):\n bqSJ = 10 ** (exwG - 1)\n W4ky = 10 ** exwG - 1\n return tuKI.randint(bqSJ, W4ky)",
"def BWvy(exwG):\n P8oC = vIwR.ascii_letters + vIwR.digits\n Mkmy = ''\n for YRb... | [
"0.83104306",
"0.8132888",
"0.7974217",
"0.792067",
"0.7800077",
"0.7783429",
"0.7773737",
"0.7744536",
"0.77111113",
"0.76495475",
"0.7646355",
"0.7646355",
"0.76113766",
"0.75859517",
"0.7545056",
"0.7498611",
"0.7495935",
"0.74185175",
"0.74098057",
"0.7364058",
"0.7351299... | 0.7910271 | 4 |
Wraps scipy.stats kendalltau function. | def DPA2(rLWh, RfF2):
def i8OE(WKvO, LVAh):
if WKvO.ndim == 1:
WKvO = oyIN.reshape(WKvO, [1, WKvO.shape[0]])
if LVAh.ndim == 1:
LVAh = oyIN.reshape(LVAh, [1, LVAh.shape[0]])
lGYN = oyIN.zeros((WKvO.shape[0], 1), dtype=oyIN.float32)
for YRbF in range(WKvO.shap... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def H4gQ(bEXe):\n from scipy.stats import kendalltau\n jmzt, XP5J = kendalltau(range(len(bEXe)), bEXe)\n return (jmzt, XP5J)",
"def Qh2t(YKHO, DWJ0=0, *q7In):\n if not any(q7In):\n q7In = YKHO._fittedParams\n return YKHO._kTau(DWJ0, *q7In)",
"def qmno(YKHO, *qIxc):\n return gQS9.sys_dy... | [
"0.65121424",
"0.5794295",
"0.57684165",
"0.5675592",
"0.56690943",
"0.56373054",
"0.56222904",
"0.5593836",
"0.5560896",
"0.55271804",
"0.5520134",
"0.5402853",
"0.53756636",
"0.53595686",
"0.5337518",
"0.5327578",
"0.53185207",
"0.53180295",
"0.52941436",
"0.52901125",
"0.5... | 0.0 | -1 |
Gets the id of this Session. | def id(YKHO) -> int:
return YKHO._id | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def id(YKHO):\n return YKHO._session_id",
"def fBNT(YKHO):\n if 'id' not in cuiw:\n YKHO._allocate_new_session()\n return cuiw['id']",
"def JkXK(YKHO):\n return YKHO._session_id",
"def JkXK(YKHO):\n return YKHO._session.session_id if YKHO._session else None",
"def cZq3(YKHO):\n ret... | [
"0.8901797",
"0.861571",
"0.83949053",
"0.8357228",
"0.83473253",
"0.826619",
"0.8265845",
"0.8069348",
"0.8052669",
"0.8052669",
"0.8026883",
"0.79547715",
"0.78681517",
"0.78681517",
"0.78681517",
"0.78261995",
"0.78122044",
"0.78122044",
"0.78122044",
"0.78122044",
"0.7812... | 0.0 | -1 |
Sets the token of this Session. | def eOtH(YKHO, eOtH: str):
YKHO._token = eOtH | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SQxU(YKHO, eOtH):\n YKHO.__token = eOtH",
"def SQxU(YKHO, eOtH):\n YKHO.__token = eOtH",
"def SQxU(YKHO, eOtH):\n YKHO.validateToken()\n YKHO.token = eOtH",
"def SQxU(YKHO, eOtH):\n YKHO.__token = eOtH\n return None",
"def mDCx(YKHO, eOtH):\n YKHO._token = k5QJ(eOtH)",
"def eOtH(... | [
"0.85458714",
"0.85458714",
"0.8323832",
"0.8312584",
"0.80442405",
"0.79652834",
"0.79652834",
"0.79256034",
"0.7827649",
"0.78158104",
"0.7567861",
"0.7537077",
"0.75238305",
"0.75215197",
"0.7509784",
"0.7433624",
"0.7426266",
"0.7366325",
"0.71964747",
"0.7175098",
"0.709... | 0.79112166 | 8 |
Decay learning rate by a factor of 0.3 every lr_decay_epoch epochs. | def hc6Z(K0do, qtWj, DJmW=b0Ix, jnHZ=jnHZ):
tspZ = DJmW * 0.3 ** (qtWj // jnHZ)
if qtWj % jnHZ == 0:
print('LR is set to {}'.format(tspZ))
for Lwm5 in K0do.param_groups:
Lwm5['lr'] = tspZ
return K0do | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def pwoX(qtWj, b0Ix):\n return b0Ix / 1.1",
"def PjIb(YKHO):\n if YKHO.decay:\n YKHO.lr = YKHO.decay * YKHO.lr",
"def LaAs(qtWj):\n TyPQ = 0.25\n Gn2V = 15.0\n return RaGq * epAf.pow(1 - TyPQ, epAf.floor(qtWj / Gn2V))",
"def biVQ(qtWj, lvfV):\n oLNr = aF2y\n paSp = qtWj * lvfV\n ... | [
"0.80628896",
"0.7963146",
"0.79107004",
"0.7868826",
"0.7792009",
"0.7598975",
"0.7590643",
"0.75886065",
"0.75800884",
"0.7496887",
"0.7493936",
"0.7451815",
"0.7448513",
"0.7433679",
"0.7410531",
"0.7410531",
"0.7399846",
"0.7364267",
"0.7364267",
"0.7364267",
"0.73555464"... | 0.0 | -1 |
This function retreives a specific user from the database. | def fbl9(Emd4, id):
return GhOX.query(mv1M).filter(mv1M.user_id == id).first() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def TKWP(uJjO):\n return xyx6.find_one({'user_id': uJjO})",
"def TKWP(CBIr):\n Pe9W = 'select users.id from users where name = :name;'\n return FgzD(Pe9W, CBIr, one=True)",
"def TKWP(NCls: Session, uJjO: int):\n return NCls.query(FYrf.User).filter(FYrf.User.id == uJjO).first()",
"def TKWP(NCls: S... | [
"0.84269524",
"0.83042777",
"0.8209338",
"0.8209338",
"0.81443536",
"0.81233996",
"0.80984795",
"0.8039518",
"0.80271417",
"0.80228525",
"0.79624",
"0.79155433",
"0.79129153",
"0.78976005",
"0.78892756",
"0.78768075",
"0.7851876",
"0.784818",
"0.78076184",
"0.77920055",
"0.77... | 0.0 | -1 |
Just compute the error | def crsw(FgvF, EcIH, nPrm, oHE7, PJWX=False):
SItB = 0
for bGrB, pJsJ in oHE7:
WKvO, ZHfW, LVAh = EcIH([nPrm[0][a1PO] for a1PO in pJsJ], XTiz.array(nPrm[1])[pJsJ], maxlen=None)
aTLP = FgvF(WKvO, ZHfW)
x6A0 = XTiz.array(nPrm[1])[pJsJ]
SItB += (aTLP == x6A0).sum()
SItB = 1.0 - ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Gv3L(YKHO):\n Ty9i = (YKHO.u - YKHO.old_u).flat\n return oyIN.sqrt(oyIN.dot(Ty9i, Ty9i))",
"def RDdK(YKHO, pan_):\n pass",
"def RDdK(YKHO, qqrj):\n wGcT = YKHO._meanFibersFr - YKHO._meanFiringRateProfile\n P1dF = qqrj - wGcT\n return P1dF",
"def XObx(YKHO):\n if YKHO.total == 0:\n ... | [
"0.79839134",
"0.7976165",
"0.795395",
"0.7796089",
"0.77596885",
"0.7653143",
"0.7626866",
"0.7580889",
"0.7558794",
"0.75180954",
"0.7437892",
"0.7381876",
"0.73558754",
"0.7335474",
"0.73296154",
"0.7322699",
"0.73124576",
"0.73123217",
"0.7308957",
"0.73005223",
"0.723911... | 0.0 | -1 |
Prints when user first joined the server. | async def joined(OaeV, *, mS46: discord.Member):
await OaeV.send('{0} joined on {0.joined_at}'.format(mS46)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def vApJ(YKHO, UzPC, tvqc):\n ClB8 = \"Hi, I'm \" + YKHO.__get_colored_text('3', str(UzPC.get_nickname())) + ' your bot. Send ' + YKHO.__get_colored_text(YKHO.color_num, '!help') + ' to get a list of commands.'\n if not YKHO.__first_start:\n UzPC.privmsg(YKHO.__config.CHANNEL, ClB8)\n YKHO.__on... | [
"0.6930042",
"0.6742248",
"0.6572532",
"0.65236753",
"0.6513635",
"0.6509272",
"0.6488665",
"0.6473002",
"0.6455478",
"0.64445925",
"0.64445925",
"0.6434782",
"0.64240223",
"0.64217544",
"0.6420095",
"0.6404428",
"0.6404428",
"0.64031404",
"0.6402567",
"0.63972694",
"0.639726... | 0.60991365 | 69 |
Convert from a local name to a globally unique name. | def EhfE(YKHO, oeNL, q_w6, WmM4=None):
assert isinstance(oeNL, ATGq), '{!r} must be a TilePos'.format(oeNL)
oWrg = (oeNL, q_w6)
return YKHO.netname2globalname.get(oWrg, WmM4) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def uD9m(mWFP):\n return mWFP",
"def oXsj(mWFP, NkkI=False):\n if NkkI:\n mWFP = uD9m(mWFP)\n return Z89i(mWFP[0].lower() + mWFP[1:])",
"def ZGgV(mWFP: str) -> str:\n WKvO = ZbWC.sub('[^()+./\\\\w-]+', '_', mWFP.replace('\\\\', '/').replace('${', '_').replace('{', '_').replace('}', '_').rstr... | [
"0.69121504",
"0.6678222",
"0.6673417",
"0.6663253",
"0.6662337",
"0.6644219",
"0.6637995",
"0.65938455",
"0.65232986",
"0.6518641",
"0.65094113",
"0.6506332",
"0.64722973",
"0.6465278",
"0.642785",
"0.6408524",
"0.6404947",
"0.6387251",
"0.6372676",
"0.6356081",
"0.6355298",... | 0.689165 | 1 |
Creates and saves a User with the given email and password. | def xWi2(YKHO, D3lj, jTXt, **wdCM):
if not D3lj:
raise ValueError("L'adresse email doit être renseignée")
D3lj = YKHO.normalize_email(D3lj)
CBIr = YKHO.model(email=D3lj, **wdCM)
CBIr.set_password(jTXt)
CBIr.save(using=YKHO._db)
return CBIr | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xWi2(YKHO, D3lj, jTXt, **wdCM):\n if not D3lj:\n raise ValueError('The email must be set')\n D3lj = YKHO.normalize_email(D3lj)\n CBIr = YKHO.model(email=D3lj, **wdCM)\n CBIr.set_password(jTXt)\n CBIr.save()",
"def lYUQ(YKHO, D3lj: str, jTXt: str, **wdCM: dict):\n if not D3lj:\n ... | [
"0.87203795",
"0.8471124",
"0.8462932",
"0.84520763",
"0.84274495",
"0.84224284",
"0.84208685",
"0.84165066",
"0.8410754",
"0.8409538",
"0.8409538",
"0.8401648",
"0.84014827",
"0.8391565",
"0.83900344",
"0.83900344",
"0.83900344",
"0.83900344",
"0.83900344",
"0.83900344",
"0.... | 0.82994825 | 93 |
Wraps hidden states in new Tensors, to detach them from their history. | def IOWm(MKlR):
if isinstance(MKlR, ht2j.Tensor):
return MKlR.detach()
else:
return tuple((IOWm(Ty9i) for Ty9i in MKlR)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YmeV(YKHO):\n YKHO.hidden = (ht2j.zeros(1, YKHO.batch_size, YKHO.hidden_size), ht2j.zeros(1, YKHO.batch_size, YKHO.hidden_size))",
"def eIRW(Zode):\n if isinstance(Zode, ht2j.Tensor):\n return Zode.detach()\n else:\n return tuple((eIRW(Ty9i) for Ty9i in Zode))",
"def MAw8(YKHO):\n ... | [
"0.6880629",
"0.64517695",
"0.6377572",
"0.63079625",
"0.62515086",
"0.6233768",
"0.62034684",
"0.61984754",
"0.61882585",
"0.61882585",
"0.6126888",
"0.61185306",
"0.60700804",
"0.6000492",
"0.5997249",
"0.5995625",
"0.5969928",
"0.59628063",
"0.59474343",
"0.5938205",
"0.59... | 0.5675689 | 41 |
Initialize a new collection for the given model and associated data. | def FIMM(YKHO, C3ST, nPrm):
YKHO.model = C3ST
if not YKHO.model.resource in nPrm:
tO9_ = 'The data set does not contain `%s`'
raise KeyError(tO9_ % YKHO.model.resource)
if not isinstance(nPrm[YKHO.model.resource], list):
tO9_ = 'The data does not contain a list of `%s`.'
rais... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FIMM(YKHO, C3ST: Type[ModelType]):\n YKHO.model = C3ST\n YKHO.collection = YKHO.model.__collection_name__(C3ST)",
"def aQD0(YKHO, FYrf=None):\n if FYrf is None:\n FYrf = []\n return LRdN(FYrf)",
"def FIMM(YKHO, xUwc: Optional[list]=None):\n if isinstance(xUwc, list):\n YKHO._da... | [
"0.7560091",
"0.68319196",
"0.65742546",
"0.64163744",
"0.6402471",
"0.63043153",
"0.6302916",
"0.62671643",
"0.6236863",
"0.6235572",
"0.6177548",
"0.6114615",
"0.6109106",
"0.60915375",
"0.60915375",
"0.60915375",
"0.6087153",
"0.6083302",
"0.6065836",
"0.6025151",
"0.60239... | 0.66090745 | 2 |
''' Initialize the object and clean out the diffs path. This class requires Pillow to be installed, but you can remove that dependency with a subclass that overrides the create_painter() method. A good way to use this class is to create a session fixture and regular | def FIMM(YKHO, DYok: typing.Optional[Path]=None, QePW=None, t07F=True):
YKHO.diffs_path = DYok
YKHO.request = QePW
YKHO.is_displayed = t07F
YKHO.diff = None
YKHO.diff_files = set()
YKHO.tolerance = 3
YKHO.blur_radius = 1
YKHO.diff_count = 0
YKHO.max_diff = 0
YKHO.file_prefixes = ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FCbF(YKHO):\n if Hy7s.path.exists(tklC):\n RDuA.rmtree(tklC)\n Hy7s.mkdir(tklC)\n Tv_S = Hy7s.path.join(Hy7s.path.dirname(xAKo), '4x8.png')\n YKHO.file1 = YKHO.File(open(Tv_S, 'rb'), name='4x8.png')\n rklQ = Hy7s.path.join(Hy7s.path.dirname(xAKo), '8x4.png')\n YKHO.file2 = YKHO.File(op... | [
"0.5845483",
"0.5742851",
"0.5646154",
"0.5564886",
"0.5551454",
"0.5542016",
"0.55119413",
"0.5441788",
"0.5401224",
"0.53469706",
"0.5345632",
"0.53276145",
"0.53262824",
"0.5326169",
"0.5324132",
"0.52822906",
"0.52691776",
"0.5226311",
"0.5221333",
"0.52168405",
"0.521457... | 0.6242185 | 0 |
Save a graph to a PNG file. | def yRIh(yvY1, Ux0P):
hCTi = Ux0P + '.dot'
grem(yvY1, hCTi)
UE3f = Ux0P + '.png'
HCmI = 'dot -n -Tpng {} > {}'.format(hCTi, UE3f)
Hy7s.system(HCmI) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def yJCP(Ux0P):\n VXjJ = T0lF.pl.p.getImage()\n raTq = jscH + Ux0P\n q5_s.WriteImage(raTq, VXjJ, 'png')\n return 'saved plot as %s' % raTq",
"def utX4(LZpg, kCaJ, weqM=uEgT):\n QrM1.savefig(kCaJ, facecolor=LZpg.get_facecolor(), dpi=weqM)",
"def utX4(YKHO, pNZh, pmON, weqM=100):\n LZpg = QrM1.... | [
"0.8216674",
"0.806845",
"0.7948728",
"0.7874293",
"0.78275144",
"0.767778",
"0.7592643",
"0.7588077",
"0.7553648",
"0.7538848",
"0.75261605",
"0.74974436",
"0.7435995",
"0.7400328",
"0.73543376",
"0.730002",
"0.72696364",
"0.72656727",
"0.72645515",
"0.7258477",
"0.7245546",... | 0.7347136 | 15 |
Odd or Even? Kata | def ebpd(ezWE):
return 'even' if sum(ezWE) % 2 == 0 else 'odd' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def kYZq(WKvO):\n return WKvO % 2",
"def C_CQ(WKvO):\n return WKvO % 2 != 0",
"def XHAY(WKvO):\n return WKvO % 2 != 0",
"def wlbi(YRbF):\n return YRbF % 2 != 0",
"def C_CQ(WKvO):\n return not int(WKvO) % 2 == 0",
"def W9Go(exwG):\n if exwG % 2 == 1:\n return True\n else:\n ... | [
"0.80245924",
"0.7995549",
"0.7935125",
"0.7921019",
"0.790406",
"0.78970855",
"0.78065914",
"0.77951026",
"0.77542216",
"0.7739167",
"0.7711496",
"0.7696507",
"0.76845896",
"0.76577353",
"0.7615542",
"0.7598728",
"0.75724214",
"0.7563757",
"0.75570065",
"0.75570065",
"0.7552... | 0.71123064 | 50 |
Generate a random string ID | def Kn3U(zNig=24):
KoG3 = vIwR.ascii_lowercase + vIwR.digits
return ''.join((tuKI.choice(KoG3) for YRbF in range(zNig))) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Kn3U():\n return ''.join(tuKI.choices(vIwR.ascii_uppercase + vIwR.ascii_lowercase + vIwR.digits, k=8))",
"def ZsIR():\n return str(kxTZ())",
"def Kn3U() -> str:\n gLiZ = list('0123456789')\n KCHu = ''\n for WKvO in range(16):\n KCHu += tuKI.choice(gLiZ)\n return KCHu",
"def Kn3U(... | [
"0.9110944",
"0.88759863",
"0.885398",
"0.8768855",
"0.8714871",
"0.87086296",
"0.86818975",
"0.8653157",
"0.86204344",
"0.85890466",
"0.858547",
"0.8569048",
"0.8531938",
"0.8515176",
"0.84525657",
"0.8452557",
"0.83904916",
"0.8376786",
"0.8323235",
"0.82555985",
"0.8254837... | 0.8286128 | 19 |
Returns list of tuples for given `counts` of labels. | def C6M2(BWz1):
if sum(BWz1) == 0:
return [()]
BWz1 = tuple(BWz1)
if BWz1 in wyyA:
return wyyA[BWz1]
jpwO = []
for YRbF, UHFx in enumerate(BWz1):
if UHFx == 0:
continue
xici = list(BWz1)
xici[YRbF] -= 1
xici = tuple(xici)
CBZq = C6M... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Ffz0(YKHO, Crrw):\n if len(set(Crrw)) != 2:\n print('List labels does not contain exactly 2 unique labels.')\n exit()\n iXcw = {}\n UHFx = 0\n for YRbF in Crrw:\n if not YRbF in iXcw:\n iXcw[YRbF] = UHFx\n UHFx += 1\n Aofo = [0] * len(Crrw)\n for YRb... | [
"0.6633446",
"0.6347311",
"0.63107294",
"0.62530303",
"0.6225826",
"0.617566",
"0.6155473",
"0.6148795",
"0.61412746",
"0.61296856",
"0.6102247",
"0.60378385",
"0.6020093",
"0.60059476",
"0.5990294",
"0.5986545",
"0.59814215",
"0.5943242",
"0.5915806",
"0.59006566",
"0.588995... | 0.6268344 | 3 |
Normalizes the weights (as sympy.Rational) in dictionary of weights. | def FWlN(_mSQ):
r8o1 = sum(jKi7.itervalues(_mSQ))
return {YRbF: FCE9.Rational(upAO, r8o1) for YRbF, upAO in jKi7.iteritems(_mSQ)} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def FWlN(sGX5):\n O7kA = {}\n for H5ew in sGX5:\n hkxX = sGX5[H5ew].split()\n Nbfw = 0\n for BWXx in hkxX:\n JchH = BWXx.split(':')\n Nbfw += float(JchH[1]) * float(JchH[1])\n VEjp = epAf.sqrt(Nbfw)\n for BWXx in hkxX:\n JchH = BWXx.split(':... | [
"0.7364593",
"0.6885917",
"0.67444986",
"0.6631414",
"0.6491423",
"0.6426639",
"0.6426639",
"0.64222884",
"0.6408945",
"0.6388519",
"0.63611555",
"0.6355627",
"0.62796855",
"0.6254394",
"0.6219058",
"0.6156625",
"0.6056583",
"0.6049823",
"0.60482913",
"0.60415584",
"0.6039112... | 0.8430717 | 0 |
Return a list (int) of all incoming CAN frame ids for this node, according to the CAN configutation. | def Nxu5(YKHO):
Aofo = []
for Pb5J, pnzj in YKHO.can_config.framedefinitions.items():
if not pnzj.is_outbound(YKHO.can_config.ego_node_ids):
Aofo.append(Pb5J)
Aofo.sort()
return Aofo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def R8lk(YKHO):\n Aofo = []\n for Pb5J, pnzj in YKHO.can_config.framedefinitions.items():\n if pnzj.is_outbound(YKHO.can_config.ego_node_ids):\n Aofo.append(Pb5J)\n Aofo.sort()\n return Aofo",
"def jd3n(YKHO):\n qD5E = []\n for Pb5J, pnzj in YKHO.can_config.framedefinitions.it... | [
"0.69835764",
"0.67393774",
"0.6440439",
"0.6390342",
"0.6248155",
"0.618522",
"0.61486894",
"0.60838956",
"0.6053272",
"0.60453707",
"0.6020164",
"0.60131854",
"0.5887514",
"0.5885359",
"0.5850355",
"0.5846058",
"0.5781439",
"0.5770645",
"0.57492715",
"0.5745544",
"0.5741074... | 0.81118256 | 0 |
Return a list (int) of all outgoing CAN frame ids for this node, according to the CAN configutation. | def R8lk(YKHO):
Aofo = []
for Pb5J, pnzj in YKHO.can_config.framedefinitions.items():
if pnzj.is_outbound(YKHO.can_config.ego_node_ids):
Aofo.append(Pb5J)
Aofo.sort()
return Aofo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Nxu5(YKHO):\n Aofo = []\n for Pb5J, pnzj in YKHO.can_config.framedefinitions.items():\n if not pnzj.is_outbound(YKHO.can_config.ego_node_ids):\n Aofo.append(Pb5J)\n Aofo.sort()\n return Aofo",
"def qtEK(YKHO) -> qe4Y.Output[bdIy[int]]:\n return qe4Y.get(YKHO, 'channel_ids')",... | [
"0.7260513",
"0.6250867",
"0.59156775",
"0.5884419",
"0.57379574",
"0.57214195",
"0.57065994",
"0.5696392",
"0.56928414",
"0.5681162",
"0.5681141",
"0.56613994",
"0.56417847",
"0.5633552",
"0.5622881",
"0.5577535",
"0.55542296",
"0.5511377",
"0.550237",
"0.550237",
"0.5501923... | 0.81225604 | 0 |
Initialise Flask application, save the current application context for the duration of a single test and yield a testing client for making requests to the endpoints exposed by the application | def FCbF(YKHO):
YKHO.test_app = LUif(DATABASE_NAME='test_analytics_2', TESTING=True)
YKHO.testing_client = YKHO.test_app.test_client()
YKHO.testing_client_context = YKHO.test_app.app_context()
YKHO.testing_client_context.push() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P4t4():\n wMcu = LUif(LV7V)\n OaeV = wMcu.test_request_context()\n OaeV.push()\n yield wMcu\n OaeV.pop()",
"def P4t4():\n wMcu = LUif(testing=True)\n OaeV = wMcu.test_request_context()\n OaeV.push()\n yield wMcu\n OaeV.pop()",
"def P4t4():\n Hy7s.environ['FLASK_ENV'] = 'tes... | [
"0.8374517",
"0.8354914",
"0.8280104",
"0.8040132",
"0.79895",
"0.7829814",
"0.76505065",
"0.7649839",
"0.76393634",
"0.7610589",
"0.75982434",
"0.75911796",
"0.75441915",
"0.7513415",
"0.75087863",
"0.75081235",
"0.74800706",
"0.74182475",
"0.74039716",
"0.73964757",
"0.7394... | 0.0 | -1 |
Clear terminal and return to application. | def JPYU(YKHO, qIxc):
Emd4()
return True | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cDHD() -> None:\n bGrB = Hy7s.system('cls') if Hy7s.name == 'nt' else Hy7s.system('clear')",
"def KnLO():\n if mWFP == 'nt':\n bGrB = Oz1B('cls')\n else:\n bGrB = Oz1B('clear')",
"def cDHD() -> None:\n Hy7s.system('cls' if Hy7s.name == 'nt' else 'clear')",
"def cDHD():\n Hy7s... | [
"0.81400603",
"0.80642056",
"0.80552256",
"0.8004126",
"0.77261096",
"0.76146686",
"0.76117516",
"0.75981456",
"0.75714165",
"0.7550329",
"0.75094414",
"0.749988",
"0.74736166",
"0.74650246",
"0.746269",
"0.7461831",
"0.7461092",
"0.7443284",
"0.7440462",
"0.743274",
"0.74108... | 0.0 | -1 |
Creates and saves a User with the given email and password. | def xWi2(YKHO, D3lj, jTXt, _Kb1, **wdCM):
wzkt = rIAI.now()
if not D3lj:
raise ValueError('The given email must be set')
D3lj = YKHO.normalize_email(D3lj)
CBIr = YKHO.model(email=D3lj, is_admin=_Kb1, is_active=True, date_joined=wzkt, **wdCM)
CBIr.set_password(jTXt)
CBIr.save(using=YKHO._... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def xWi2(YKHO, D3lj, jTXt, **wdCM):\n if not D3lj:\n raise ValueError('The email must be set')\n D3lj = YKHO.normalize_email(D3lj)\n CBIr = YKHO.model(email=D3lj, **wdCM)\n CBIr.set_password(jTXt)\n CBIr.save()",
"def lYUQ(YKHO, D3lj: str, jTXt: str, **wdCM: dict):\n if not D3lj:\n ... | [
"0.87203795",
"0.8471124",
"0.8462932",
"0.84520763",
"0.84274495",
"0.84224284",
"0.84208685",
"0.84165066",
"0.8410754",
"0.8409538",
"0.8409538",
"0.8401648",
"0.84014827",
"0.8391565",
"0.83900344",
"0.83900344",
"0.83900344",
"0.83900344",
"0.83900344",
"0.83900344",
"0.... | 0.0 | -1 |
Returns the first_name plus the last_name, with a space in between. | def xpqj(YKHO):
jeLr = '%s %s' % (YKHO.first_name, YKHO.last_name)
return jeLr.strip() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def e1yb(c9ua, zp3f):\n eHMM = c9ua + ' ' + zp3f\n return eHMM",
"def xpqj(YKHO):\n return (YKHO.first_name + ' ' + YKHO.last_name).strip()",
"def zFMy(YKHO):\n return (YKHO.first_name or '') + (YKHO.first_name and ' ' or '') + (YKHO.last_name or '')",
"def e1yb(c9ua, zp3f):\n eHMM = c9ua.titl... | [
"0.8288836",
"0.81803834",
"0.8114534",
"0.8077555",
"0.8035423",
"0.80339295",
"0.80315596",
"0.80087924",
"0.8008028",
"0.80068004",
"0.80020875",
"0.7996379",
"0.7991398",
"0.7980801",
"0.79804915",
"0.7961816",
"0.7953743",
"0.79460365",
"0.79460365",
"0.7943404",
"0.7943... | 0.0 | -1 |
Redefines function so that DjangoModelPermissions does not use get_queryset() just to get the model if self.queryset is already available. For this reason, self.queryset should be set to model.objects.none() if get_queryset is implemented in the view. | def HI6K(YKHO, tTee):
assert hasattr(tTee, 'get_queryset') or getattr(tTee, 'queryset', None) is not None, 'Cannot apply {} on a view that does not set `.queryset` or have a `.get_queryset()` method.'.format(YKHO.__class__.__name__)
SR0I = getattr(tTee, 'queryset', None)
if SR0I is None:
SR0I = tTee... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def k66M(YKHO):\n return super(MM7r, YKHO).get_queryset() if YKHO.public_modes else YKHO.private_queryset",
"def k66M(YKHO):\n if YKHO.queryset is not None:\n return YKHO.queryset._clone()\n if YKHO.model is not None:\n return YKHO.model._default_manager.all()\n raise rqaQ(\"'%s' must d... | [
"0.784193",
"0.75477153",
"0.7452933",
"0.73592114",
"0.7347923",
"0.7187394",
"0.7138218",
"0.7132333",
"0.7008766",
"0.6987547",
"0.69664884",
"0.696374",
"0.6951189",
"0.69381595",
"0.69361573",
"0.6920951",
"0.6913329",
"0.6913329",
"0.68498695",
"0.6812664",
"0.6780671",... | 0.6480665 | 49 |
Converts an inverse depth map to a colormap for visualization. | def ZaBV(mHYw, WuUW=None, yArv=95, MYQr='plasma', vUps=False):
if o_3q(mHYw):
if len(mHYw.shape) == 3:
mHYw = mHYw.squeeze(0)
mHYw = mHYw.detach().cpu().numpy()
Bcwd = tRp2(MYQr)
if WuUW is None:
WuUW = oyIN.percentile(mHYw[mHYw > 0] if vUps else mHYw, yArv)
mHYw /= W... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def tZdy(rb7a: Union[Tensor, np.ndarray], VtCk: Optional[Union[Tensor, np.ndarray, Any]]=None, d4t2: Optional[Union[Tensor, np.ndarray, Any]]=None) -> oyIN.ndarray:\n if isinstance(rb7a, llWB):\n rb7a = cdzj(rb7a)\n if VtCk is None:\n VtCk = 0.0\n if d4t2 is None:\n d4t2 = rb7a.max()\... | [
"0.6929125",
"0.65476197",
"0.6475184",
"0.6404344",
"0.62407243",
"0.6186964",
"0.6178452",
"0.6136289",
"0.5893473",
"0.5866396",
"0.5865154",
"0.58587736",
"0.58542836",
"0.58539397",
"0.585282",
"0.5824719",
"0.5824719",
"0.5812063",
"0.5809041",
"0.58040994",
"0.58040994... | 0.6285838 | 4 |
Read JSON data from a file using fiona | def Ueki(YKHO):
raise NotImplementedError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def CQ2n(YKHO, WhwQ):\n with open(WhwQ) as eHNT:\n nPrm = qQXR.load(eHNT)\n eHNT.close()\n return nPrm",
"def ZAQi():\n with open(nC76) as Vu7S:\n return qQXR.load(Vu7S)",
"def HQP9(gIsw, W2jy='geojson', JJv9='/'):\n print('reading geojson formatted dataset from file:{}.json'.forma... | [
"0.70134133",
"0.68380123",
"0.680981",
"0.679219",
"0.6776922",
"0.67485875",
"0.6730405",
"0.66926277",
"0.6670819",
"0.66573095",
"0.6643623",
"0.6635748",
"0.66105306",
"0.66093445",
"0.65761155",
"0.65578526",
"0.65447843",
"0.65384954",
"0.6521113",
"0.65210056",
"0.651... | 0.0 | -1 |
return the current rating of player p | def lcsm(YKHO, XP5J):
if XP5J not in YKHO.ratings.keys():
raise ValueError('Player not exist')
return YKHO.ratings[XP5J] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def lcsm(YKHO):\n return YKHO.rating",
"def lcsm(YKHO) -> int:\n return YKHO.rating",
"def lcsm(YKHO):\n return YKHO.__rating",
"def RrWF(YKHO):\n return YKHO._rating",
"def lcsm(YKHO):\n if YKHO.num_ratings == 0:\n return 0\n else:\n return YKHO.avg_rating",
"def lcsm():\... | [
"0.743853",
"0.74176604",
"0.73855066",
"0.7255668",
"0.7144107",
"0.71138",
"0.6918748",
"0.69044423",
"0.68631953",
"0.68306553",
"0.67371",
"0.6705834",
"0.66242033",
"0.6578859",
"0.6530492",
"0.6497214",
"0.648579",
"0.6480137",
"0.6460634",
"0.6427801",
"0.6410799",
"... | 0.8475979 | 0 |
returns an dictionary of spending per JEDI CLIN for a portfolio { | def pgr2(Emd4, HVIF):
if HVIF.name in Emd4.FIXTURE_SPEND_DATA:
UQOp = oRi_(lambda: oRi_(ZjSO))
for SCWY in Emd4.FIXTURE_SPEND_DATA[HVIF.name]['applications']:
for GikI in SCWY['environments']:
for ca5T, Fp9O in GikI['spending']['this_month'].items():
U... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wy1y(YKHO, HVIF, _c1T):\n Aofo = T74E.objects.filter(portfolio__name=HVIF, transaction_type='b', date__lte=_c1T) | T74E.objects.filter(portfolio__name=HVIF, transaction_type='s', date__lte=_c1T)\n FL53 = {}\n for ZfUD in Aofo:\n if ZfUD.id not in FL53.keys():\n FL53[ZfUD.id] = ZjSO(0... | [
"0.68845046",
"0.6810731",
"0.6722961",
"0.6665237",
"0.6463035",
"0.6307613",
"0.6174115",
"0.6109153",
"0.606866",
"0.59952873",
"0.59575903",
"0.59296274",
"0.5907779",
"0.5905044",
"0.5793909",
"0.5793062",
"0.5775075",
"0.57376426",
"0.5736718",
"0.57359034",
"0.56764466... | 0.774844 | 0 |
Stop the stats manager. | def JCyR(YKHO) -> None:
if YKHO._update_stats_task_is_running:
assert YKHO._update_stats_task is not None, 'Call start before calling stop.'
YKHO._update_stats_task_is_running = False
YKHO._update_stats_task.join() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JCyR():\n global instance\n gCuF = kZw_.context.scene.renderplus.stats\n gCuF.total = KAOR.total()\n if KAOR.is_animation():\n gCuF.slowest = KAOR.slowest_frame()\n gCuF.fastest = KAOR.fastest_frame()\n gCuF.average = KAOR.average_frame(gCuF.total)\n if gCuF.save_file:\n... | [
"0.7750756",
"0.74140406",
"0.7344218",
"0.7308017",
"0.7121527",
"0.7096883",
"0.7058288",
"0.69843125",
"0.69821894",
"0.69116974",
"0.69116974",
"0.69106895",
"0.68751824",
"0.68341625",
"0.68004954",
"0.6794126",
"0.6734907",
"0.6733533",
"0.6732885",
"0.6732885",
"0.6723... | 0.7304007 | 4 |
Lookup the source field of a destination. | def a_2H(yFgu, n8P7):
for Jyyj in n8P7.get('fields'):
if Jyyj.get('dest') == yFgu:
return Jyyj.get('source') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MvAC(YKHO, fNTl: Table, BjT8: str) -> str:\n sOjC = getattr(YKHO, f'{YKHO.src_dialect}_{YKHO.dest_dialect}_fields_{fNTl.name}', getattr(YKHO, f'default_fields_{fNTl.name}', {}))\n return sOjC.get(BjT8, BjT8)",
"def XqiZ(YKHO) -> h8nf[qe4Y.Input[str]]:\n return qe4Y.get(YKHO, 'destination_field')",
... | [
"0.67875564",
"0.6344657",
"0.61448365",
"0.60205144",
"0.5959164",
"0.5945839",
"0.58910185",
"0.5802964",
"0.57939345",
"0.5788975",
"0.5787459",
"0.5786244",
"0.57796925",
"0.5742047",
"0.56857425",
"0.5675713",
"0.56737494",
"0.5664209",
"0.56204945",
"0.5612156",
"0.5604... | 0.85212857 | 0 |
Get interwiki link to missing_commonscat_page for the same country. | def w_By(r1zf, DuqQ):
Aofo = ''
for (gtfI, wvN7), n8P7 in RBN8.countries.items():
if r1zf == gtfI and DuqQ != wvN7:
if n8P7.get('missingCommonscatPage'):
Aofo += '[[{lang}:{page}]]\n'.format(lang=wvN7, page=n8P7.get('missingCommonscatPage'))
return Aofo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QW83(bg4R, kb8p, qRB_, aFKM=None, P2CS=1000):\n d9Yv = ':c:Commons:Monuments_database/Missing_commonscat_links'\n l5Ny = BJsk.instruction_header(d9Yv)\n SV4W = 0\n eyOY = 0\n if not bg4R:\n l5Ny += BJsk.done_message(d9Yv, 'missing commonscat')\n else:\n for qegl, zSv7 in bg4R.it... | [
"0.69460636",
"0.63516563",
"0.62814057",
"0.608027",
"0.59747565",
"0.56572515",
"0.56373763",
"0.5609334",
"0.54868",
"0.54101914",
"0.51356554",
"0.5114394",
"0.5097854",
"0.50960094",
"0.5068085",
"0.5058501",
"0.5058501",
"0.5058501",
"0.50375473",
"0.5034487",
"0.501139... | 0.7820537 | 0 |
Retrieve all commons categories in the tracking category. dict of commons categories with category_sort_key as key and category name as value. category_sort_key contains the monument id. | def UrkF(WhPe, w2B8, N1p7):
xDcj = 'SELECT page_title, cl_sortkey_prefix FROM page JOIN categorylinks ON page_id=cl_from WHERE page_namespace=14 AND page_is_redirect=0 AND cl_to=%s'
N1p7.execute(xDcj, (WhPe,))
return BJsk.process_sort_key_query_result(N1p7) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zG33(YKHO) -> ld92[cuzp]:\n return YKHO.client.send('Tracing.getCategories', {})",
"def ZRgY():\n zSv7 = U8Lr()\n for rdlD in TtaC.category.categories:\n BDa2 = Ms0G.category_scope[rdlD[2]]\n zSv7[rdlD[3]] = qZuN(rdlD[3], rdlD[0], BDa2, rdlD[1], rdlD[4])\n return zSv7",
"def pi1E(... | [
"0.6832562",
"0.66675884",
"0.6652961",
"0.66526747",
"0.6598373",
"0.654984",
"0.65259105",
"0.64009726",
"0.63747835",
"0.63505876",
"0.63041466",
"0.6301242",
"0.629173",
"0.6277883",
"0.62673026",
"0.626127",
"0.6259965",
"0.6254919",
"0.6254919",
"0.6254545",
"0.62419266... | 0.6881227 | 0 |
Initialisation of the Temperature sensor object. | def FIMM(YKHO, FGW3, jGRS=None, ovGo=None, i1I_=None, PJWX=0, DpZH=BtDU, oEge=None, frp4=False):
YKHO._number = int(FGW3)
YKHO._status = None
if jGRS is not None:
YKHO._status = str(jGRS).strip()
YKHO._temperature = None
super(OR52, YKHO).__init__(appname=i1I_, verbose=PJWX, version=DpZH, ba... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YV9F(YKHO, ovGo):\n YKHO.temperature = ovGo",
"def FIMM(YKHO, ovGo):\n if ovGo < 0:\n raise ValueError('Invalid temperature value, T >= 0')\n YKHO.temperature = ovGo",
"def FIMM(YKHO, ovGo=None, CJ2p=None):\n YKHO.temperature = ovGo\n YKHO.pressure = CJ2p\n return",
"def FIMM(YKH... | [
"0.7979566",
"0.79126585",
"0.77561855",
"0.7711264",
"0.7700621",
"0.75114244",
"0.7200205",
"0.7193088",
"0.7191729",
"0.6997135",
"0.6936086",
"0.69254947",
"0.6873625",
"0.67669433",
"0.67564404",
"0.6660105",
"0.66062963",
"0.65821254",
"0.65760946",
"0.65727097",
"0.655... | 0.7325688 | 6 |
The current temperature in degree Celsius. | def ovGo(YKHO):
return YKHO._temperature | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def QGow(YKHO):\n return YKHO.temp",
"def CMHP(YKHO) -> float:\n return YKHO.component.temperature",
"def ovGo(YKHO):\n YKHO._read_temperature()\n return YKHO._t_fine / 5120.0",
"def rcrL(YKHO) -> float:\n TZ_R = float(YKHO.__reading[rO6F['temperature']])\n return RV7L(TZ_R)",
"def ovGo(Y... | [
"0.88778734",
"0.8464881",
"0.84087294",
"0.83860946",
"0.83497125",
"0.83217186",
"0.83217186",
"0.8306346",
"0.8281031",
"0.8249822",
"0.8249591",
"0.82428104",
"0.82170635",
"0.8203617",
"0.8190567",
"0.8190262",
"0.8179506",
"0.8174712",
"0.8154892",
"0.81541985",
"0.8154... | 0.8128321 | 32 |
The Id of the Megaraid controller. | def nuPx(YKHO):
return YKHO._adapter | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def VtE3(YKHO):\n return YKHO.controller_id",
"def X4tE(YKHO) -> str:\n return YKHO._controller_id",
"def ShR8(YKHO):\n return YKHO._controller.unique_id",
"def unpH(YKHO):\n return YKHO.id",
"def id(YKHO) -> int:\n return qe4Y.get(YKHO, 'id')",
"def id(YKHO) -> int:\n return qe4Y.get(Y... | [
"0.8024861",
"0.79139453",
"0.71949613",
"0.68864244",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",
"0.67609346",... | 0.0 | -1 |
The number of temperature sensors in the enclosure. | def RNng(YKHO):
return YKHO._nr_temp_sensors | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JcRt(YKHO) -> int:\n return YKHO.dss_obj.SensorsI(gk2W.c_int32(0), gk2W.c_int32(0))",
"def EMkd(YKHO):\n return YKHO.nodeCount",
"def F_vk(YKHO) -> int:\n return YKHO._temp_osbits",
"def UHFx(YKHO) -> int:\n return YKHO.pressure['count']",
"def TvDW(YKHO):\n return YKHO.n_sensors",
"de... | [
"0.7383705",
"0.73284894",
"0.7297376",
"0.71441257",
"0.7006693",
"0.69467956",
"0.69408494",
"0.6809538",
"0.6764151",
"0.66940606",
"0.66427535",
"0.66412187",
"0.66161335",
"0.65923876",
"0.6576511",
"0.65605307",
"0.65421903",
"0.6540013",
"0.65296656",
"0.6517754",
"0.6... | 0.8421842 | 0 |
The number of mounted physical drives in the enclosure. | def K1WH(YKHO):
return YKHO._nr_pds | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def eNmU(YKHO) -> int:\n return qe4Y.get(YKHO, 'disk_count')",
"def Tch4(YKHO) -> float:\n return qe4Y.get(YKHO, 'drive_count')",
"def IaTk(YKHO):\n return YKHO._get_component('disk_length')",
"def Tch4(YKHO) -> h8nf[float]:\n return qe4Y.get(YKHO, 'drive_count')",
"def UTqa(YKHO) -> int:\n ... | [
"0.8103308",
"0.7851371",
"0.76595277",
"0.75750893",
"0.7163221",
"0.7119628",
"0.711558",
"0.7065316",
"0.70096886",
"0.6927947",
"0.6847676",
"0.6843006",
"0.6812442",
"0.6781098",
"0.6770019",
"0.67342675",
"0.67270863",
"0.66802186",
"0.66410995",
"0.66346824",
"0.660682... | 0.0 | -1 |
The number of voltage sensors in the enclosure. | def S75F(YKHO):
return YKHO._nr_voltage_sensors | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def JcRt(YKHO) -> int:\n return YKHO.dss_obj.SensorsI(gk2W.c_int32(0), gk2W.c_int32(0))",
"def SOHb(YKHO):\n Yh3e = LSY_(YKHO._pin)\n Yh3e.atten(Yh3e.ATTN_11DB)\n sum = 0\n for WKvO in range(0, YKHO._ADC_READS):\n sum += Yh3e.read()\n return YKHO._RESISTOR_RATIO * (sum * YKHO._REFERENCE_... | [
"0.681985",
"0.67755824",
"0.6773268",
"0.6762194",
"0.67532396",
"0.66971105",
"0.66424286",
"0.6631628",
"0.66061753",
"0.65925604",
"0.6578177",
"0.65772873",
"0.65591645",
"0.6526639",
"0.6526639",
"0.65131253",
"0.65131253",
"0.65131253",
"0.65131253",
"0.65131253",
"0.6... | 0.8444773 | 0 |
The type of the enclosure. | def urjp(YKHO):
return YKHO._enc_type | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def type(YKHO):\n return YKHO.__type",
"def type(YKHO):\n return YKHO.__type",
"def type(YKHO):\n return YKHO.__type",
"def type(YKHO):\n return YKHO.__type",
"def type(YKHO):\n return YKHO.__type",
"def type(YKHO):\n return YKHO.__type",
"def type(YKHO):\n return YKHO.__type",
"... | [
"0.7198898",
"0.7198898",
"0.71899736",
"0.7149108",
"0.7130844",
"0.7130844",
"0.7130844",
"0.7130844",
"0.7102807",
"0.70865005",
"0.70710737",
"0.70308775",
"0.7017837",
"0.69894046",
"0.69894046",
"0.69894046",
"0.69894046",
"0.69894046",
"0.69894046",
"0.69894046",
"0.69... | 0.68240017 | 80 |
The product name of the enclosure. | def n8KJ(YKHO):
return YKHO._product_name | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def os_e(YKHO):\n if YKHO._productName:\n return YKHO._productName\n else:\n return YKHO.name()",
"def n8KJ(YKHO):\n return YKHO._product_name.decode('utf8')",
"def gO1D(YKHO):\n return '%s (%s)' % (YKHO.name, 'Contract')",
"def yxSE(YKHO):\n return YKHO._product_name",
"def gO... | [
"0.8001673",
"0.794837",
"0.7947742",
"0.77928835",
"0.7683724",
"0.76592547",
"0.7617115",
"0.7506941",
"0.7493205",
"0.7384198",
"0.7318883",
"0.72347885",
"0.7225262",
"0.72037506",
"0.72037506",
"0.718795",
"0.71572375",
"0.70396924",
"0.68608564",
"0.67796427",
"0.674994... | 0.815714 | 0 |
Sets the bundle_name of this UpgradeTaskProperties. | def qqaY(YKHO, qqaY):
if qqaY is None:
raise ValueError('Invalid value for `bundle_name`, must not be `None`')
YKHO._bundle_name = qqaY | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rnyF(YKHO, ZRYA):\n YKHO.user_set_human_name = ZRYA",
"def qqaY(YKHO) -> str:\n return qe4Y.get(YKHO, 'bundle_name')",
"def irWf(YKHO, wHSX):\n if wHSX.xdata.get('name'):\n YKHO.LintError('explicit-bundle-name', 'Deprecated explicit bundle name in %s' % wHSX.name)\n if wHSX.name.endswith... | [
"0.6760874",
"0.6341522",
"0.5944619",
"0.59236795",
"0.5909214",
"0.5866218",
"0.58009154",
"0.578865",
"0.5738128",
"0.56838197",
"0.5626712",
"0.56234664",
"0.5589548",
"0.5542353",
"0.5535983",
"0.5532922",
"0.5525182",
"0.550374",
"0.54994583",
"0.5458183",
"0.5447748",
... | 0.71823204 | 0 |
Returns the string representation of the model | def gTzM(YKHO):
return CgYo.pformat(YKHO.to_dict()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__model)",
"def zAg0(YKHO):\n return str(YKHO.model)",
"def zAg0(YKHO):\n return YKHO.text",
"def zAg0(YKHO):\n oOUF = '-----------------------------------------------------------------------------------\\n'\n _2sc = YKHO.__class__.__name__\n oOUF += '\\t\\... | [
"0.86418265",
"0.85103965",
"0.7853324",
"0.77442306",
"0.7712258",
"0.76979405",
"0.765959",
"0.7637644",
"0.76218504",
"0.7607561",
"0.7606604",
"0.7606604",
"0.7606604",
"0.75990754",
"0.7585653",
"0.758149",
"0.7570811",
"0.7567585",
"0.75392604",
"0.75392604",
"0.7527967... | 0.0 | -1 |
Returns true if both objects are not equal | def Vdqg(YKHO, Elif):
return not YKHO == Elif | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO.__eq__(Elif)",
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif: object):\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif):\n if YKHO.__eq__(Elif):\n return False\n return True",
"def Vdqg(... | [
"0.8393829",
"0.83557564",
"0.8296152",
"0.8133522",
"0.81153053",
"0.8100911",
"0.8100133",
"0.8098902",
"0.8098902",
"0.80937666",
"0.80937666",
"0.80937666",
"0.80937666",
"0.8086338",
"0.8086338",
"0.8086338",
"0.8086338",
"0.8086338",
"0.8067774",
"0.80598664",
"0.805856... | 0.0 | -1 |
Log Errors caused by Updates. | def P1dF(QdZT, QpfX):
bo34.warning('Update "%s" caused error "%s"', QdZT, QpfX.error) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def P1dF(JyK9, QdZT, P1dF):\n bo34.warning('Error: \"%s\" caused error \"%s\"', QdZT, P1dF)\n bo34.setLevel(G9jH.DEBUG)",
"def rP1w(QdZT, QpfX):\n bo34.warning(f'Update \"{QdZT}\" caused error {QpfX.error}\"')",
"def P1dF(QdZT, QpfX):\n G9jH.error('Update \"%s\" caused error \"%s\"', QdZT, QpfX.err... | [
"0.7895395",
"0.788395",
"0.78750193",
"0.7873498",
"0.78300834",
"0.7790406",
"0.7785151",
"0.77837753",
"0.77837753",
"0.77837753",
"0.77837753",
"0.77837753",
"0.7781314",
"0.77660847",
"0.77220625",
"0.77220625",
"0.7721968",
"0.77089256",
"0.76969343",
"0.76579255",
"0.7... | 0.7746185 | 19 |
Colormap from sequence of RGB values | def EfY7(Q6uT, wEf2, mWFP):
Z5Q9 = []
jlxe = []
pPPK = []
for Ty9i, fvDH in zip(wEf2, Q6uT):
if len(fvDH) == 3:
TRVV, kVU1, _qjy = fvDH
J1b4, IZ6w, kYGz = fvDH
elif len(fvDH) == 2:
(TRVV, kVU1, _qjy), (J1b4, IZ6w, kYGz) = fvDH
else:
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ZkU0(AIZ9=None, RgIj=None, mLww=None, cKYz=None, nYgc=None, sfMc=None, oePV=None):\n if AIZ9 is None:\n AIZ9 = 32\n if RgIj is None:\n RgIj = 0\n if mLww is None:\n mLww = 255\n if cKYz is None:\n cKYz = 0\n if nYgc is None:\n nYgc = 255\n if sfMc is None:\n... | [
"0.76758987",
"0.74878657",
"0.72446465",
"0.70939386",
"0.7065381",
"0.70417345",
"0.703441",
"0.7032898",
"0.7032898",
"0.7014179",
"0.7007631",
"0.7004618",
"0.70031065",
"0.70031065",
"0.70031065",
"0.6994092",
"0.6988928",
"0.69780236",
"0.69663465",
"0.69557583",
"0.693... | 0.7271642 | 2 |
Create colormap for twoway interaction | def N82L(MxXY, MFF8=0.1, B4DR=0.5, mWFP=None, yfUf=None):
if yfUf is None:
yfUf = oyIN.linspace(MFF8, MFF8 + 1, MxXY, False) % 1.0
B4DR *= 0.5 / MxXY
Xtuq = []
for MKlR in yfUf:
dAzm = (MKlR - B4DR) % 1
FEpM = (MKlR + B4DR) % 1
Xtuq.append((XrjU(0, 100, dAzm), XrjU(50, 10... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zqA1(exwG):\n if int(exwG / 2) == exwG / 2:\n YDb9 = 1\n NS9S = exwG / 2\n H3Vo = exwG / 2\n else:\n YDb9 = 2\n NS9S = (exwG - 1) / 2\n H3Vo = (exwG - 1) / 2\n e8YW = QrM1.cm.Blues_r(oyIN.linspace(0, 1, int(NS9S)))\n hBek = QrM1.cm.YlOrRd(oyIN.linspace(0, 1... | [
"0.7176825",
"0.6720473",
"0.66817784",
"0.66744655",
"0.6658603",
"0.6574229",
"0.6517806",
"0.64761335",
"0.64553785",
"0.64553785",
"0.6380138",
"0.6326902",
"0.6318975",
"0.6314593",
"0.62885594",
"0.6253315",
"0.623908",
"0.6203503",
"0.61915284",
"0.6177341",
"0.6171235... | 0.6764966 | 1 |
Hash a new password to bcrypt. | def cDCx(YKHO, uGpu):
YKHO.password = B8ni.encrypt(uGpu) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def qzFd(YKHO, jTXt):\n NTfD = B8ni.gensalt()\n YKHO.password = B8ni.hashpw(jTXt.encode('utf8'), NTfD)",
"def jTXt(YKHO, uGpu):\n YKHO.pass_hash = B8ni.encrypt(uGpu)",
"def qzFd(jTXt):\n return B8ni.hashpw(jTXt, B8ni.gensalt())",
"def a2tF(jTXt):\n return B8ni.hashpw(jTXt.encode('utf-8'), B8ni... | [
"0.8557258",
"0.82309455",
"0.79959697",
"0.79836965",
"0.79619664",
"0.79281676",
"0.79204893",
"0.7917807",
"0.7838186",
"0.77874815",
"0.7782618",
"0.7782618",
"0.77744985",
"0.7768688",
"0.77388316",
"0.768425",
"0.7672439",
"0.76608974",
"0.76519686",
"0.7634051",
"0.761... | 0.75817865 | 21 |
Create timestamp string of current local time. Returns str Timestamp string | def saqZ():
E3oo = ITS7.strftime('%d-%b-%Y_%H-%M%p', ITS7.localtime())
return E3oo | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def wpbf():\n Elpc = qcWV.datetime.now(rIAI('America/Los_Angeles'))\n return Elpc.strftime('%Y%m%d_%H%M%S')",
"def yc2n(E3oo=None):\n if E3oo is None:\n ejIZ = zwKp(qcWV.now())\n else:\n ejIZ = zwKp(qcWV.fromtimestamp(E3oo))\n return ejIZ",
"def ItX3():\n xfFb = ITS7.localtime()... | [
"0.8196819",
"0.8131831",
"0.7932539",
"0.78762496",
"0.78403383",
"0.7839415",
"0.78010124",
"0.7699242",
"0.76992285",
"0.76913744",
"0.7690817",
"0.7666534",
"0.7663042",
"0.76488936",
"0.7622556",
"0.7601705",
"0.75498164",
"0.754249",
"0.7521144",
"0.75110847",
"0.750988... | 0.7434615 | 31 |
Clean column names. Takes all column names, converts them to lowercase, then replaces all spaces with underscores. By default, column names are converted to string types. This can be switched off by passing in `enforce_string=False`. This method does not mutate the original DataFrame. | def _v1W(jQ3Z: pd.DataFrame, nbHg: Optional[Union[str, bool]]=None, fMMn: str='lower', Xjnh: bool=False, dEDD: bool=True, wk9k: bool=True, bPVj: bool=True, yWbO: int=None) -> rLdf.DataFrame:
i7mz = list(jQ3Z.columns)
if bPVj:
jQ3Z = jQ3Z.rename(columns=str)
jQ3Z = jQ3Z.rename(columns=lambda WKvO: li... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def ihEx(YKHO, jQ3Z):\n jQ3Z.rename(columns=lambda WKvO: str(WKvO).strip().replace(' ', '_').lower(), inplace=True)\n return jQ3Z",
"def djuA(jQ3Z):\n ZLJ_ = jQ3Z.columns if hasattr(jQ3Z, 'columns') else jQ3Z\n ZLJ_ = [Z9rn.lower().replace(' ', '_') for Z9rn in ZLJ_]\n return ZLJ_",
"def fKUY(bO... | [
"0.82129246",
"0.8212325",
"0.8002163",
"0.7730288",
"0.75279963",
"0.7507184",
"0.748016",
"0.74538594",
"0.73735887",
"0.7307127",
"0.7273282",
"0.7265157",
"0.7248792",
"0.72459203",
"0.7142494",
"0.7111833",
"0.7111833",
"0.706154",
"0.70600045",
"0.7000826",
"0.69302773"... | 0.71201915 | 15 |
Remove special characters from column name. | def Kxgf(AAHb: Hashable) -> str:
return ''.join((ZfUD for ZfUD in str(AAHb) if ZfUD.isalnum() or '_' in ZfUD)) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Kxgf(AAHb: Hashable) -> str:\n return ''.join((ZfUD for ZfUD in str(AAHb) if ZfUD.isalnum() or '_' in ZfUD))",
"def xqiW(z0q4):\n return IbNF(z0q4.replace('/', ''))",
"def _vHC(WKvO, Qg73=None):\n njyT = ZbWC.compile('[^A-Za-z0-9_ ]')\n if Qg73 is None:\n WKvO = njyT.sub('_', WKvO)\n ... | [
"0.810862",
"0.7722736",
"0.77057093",
"0.7488708",
"0.7483277",
"0.73935556",
"0.7321197",
"0.7306797",
"0.729298",
"0.729298",
"0.72898763",
"0.7259179",
"0.7154935",
"0.7028432",
"0.7016673",
"0.6981361",
"0.691198",
"0.688023",
"0.6833163",
"0.6771749",
"0.6742687",
"0.... | 0.8090709 | 1 |
Remove accents from a DataFrame column name. Inspired from [StackOverflow][so]. | def XpER(AAHb: str) -> str:
return ''.join((sZqf for sZqf in zVCt.normalize('NFD', AAHb) if not zVCt.combining(sZqf))) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def XpER(AAHb: str) -> str:\n return ''.join((vC9B for vC9B in zVCt.normalize('NFD', AAHb) if not zVCt.combining(vC9B)))",
"def fKUY(bOBl):\n Gfpc = lambda WKvO: ZbWC.sub('[^a-zA-Z0-9 \\n\\\\.]', '-', WKvO.lower())\n rqWw = lambda WKvO: zVCt.normalize('NFD', WKvO).encode('ascii', 'ignore').decode('utf-8... | [
"0.73337376",
"0.705133",
"0.6780023",
"0.67018735",
"0.6701695",
"0.65999943",
"0.6469914",
"0.63984096",
"0.63079613",
"0.6298292",
"0.6298292",
"0.6293398",
"0.6273785",
"0.6260956",
"0.62485284",
"0.62059766",
"0.6178479",
"0.6165826",
"0.6110078",
"0.6092233",
"0.6069819... | 0.7322621 | 1 |
Strip underscores from DataFrames column names. Underscores can be stripped from the beginning, end or both. | def MO0i(jQ3Z: pd.DataFrame, nbHg: Union[str, bool]=None) -> rLdf.DataFrame:
jQ3Z = jQ3Z.rename(columns=lambda WKvO: _IdR(WKvO, nbHg))
return jQ3Z | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def MO0i(jQ3Z, nbHg=None):\n mV4g = [None, 'left', 'right', 'both', 'l', 'r', True]\n if nbHg not in mV4g:\n raise efZb(f'strip_underscores must be one of: {mV4g}')\n if nbHg in ['left', 'l']:\n jQ3Z = jQ3Z.rename(columns=lambda WKvO: WKvO.lstrip('_'))\n elif nbHg in ['right', 'r']:\n ... | [
"0.807079",
"0.77645886",
"0.76506776",
"0.7624892",
"0.75205845",
"0.75130403",
"0.74939203",
"0.74939203",
"0.74080396",
"0.7373447",
"0.7339595",
"0.7323933",
"0.73080623",
"0.7238642",
"0.7209996",
"0.71349883",
"0.71291125",
"0.7062374",
"0.69756275",
"0.69341975",
"0.69... | 0.7753202 | 2 |
Get the notification setting for the login group. Return True if the group should get the notification. | def BRyC(DiwT, N5z6):
A6Ra = skd3.get_project_setting('department_work_order_notification', server=N5z6)
dnZu = A6Ra.get(DiwT, 'False')
return dnZu == 'True' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rNrN(YKHO) -> h8nf[qe4Y.Input[bool]]:\n return qe4Y.get(YKHO, 'notifications_enabled')",
"def rNrN(YKHO) -> h8nf[qe4Y.Input[bool]]:\n return qe4Y.get(YKHO, 'notifications_enabled')",
"def RAsr(YKHO) -> h8nf[qe4Y.Input['AlertGroupConfigurationArgs']]:\n return qe4Y.get(YKHO, 'group_configuration')"... | [
"0.5921406",
"0.5921406",
"0.588068",
"0.588068",
"0.58065367",
"0.57351214",
"0.5619227",
"0.5575564",
"0.54332525",
"0.54177505",
"0.5403657",
"0.53882855",
"0.5266191",
"0.5258337",
"0.5256088",
"0.52487075",
"0.5245311",
"0.5211141",
"0.519243",
"0.5178632",
"0.51751786",... | 0.78384864 | 0 |
Gets the identifier of this RuntimeManifest. A unique identifier for the manifest | def Ilxn(YKHO):
return YKHO._identifier | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def YN9m(YKHO):\n return YKHO._manifest_id",
"def id(YKHO) -> str:\n return YKHO.data[PtXs.MANIFEST_APP_ID]",
"def ra_X(YKHO) -> str:\n return qe4Y.get(YKHO, 'manifest_name')",
"def VyW9(YKHO):\n fd3g = YKHO.manifest.find('package')['unique-identifier']\n TMgG = YKHO.manifest.find(id=fd3g).con... | [
"0.8301749",
"0.78944993",
"0.7014816",
"0.6930093",
"0.67692566",
"0.6687113",
"0.6664849",
"0.66409683",
"0.6622045",
"0.6621763",
"0.6603331",
"0.65475696",
"0.6540354",
"0.653535",
"0.65295404",
"0.6500598",
"0.6469207",
"0.6453155",
"0.6425741",
"0.6425741",
"0.64052767"... | 0.6232466 | 45 |
Gets the agent_type of this RuntimeManifest. The type of the runtime binary, e.g., 'minifijava' or 'minificpp' | def Tpgu(YKHO):
return YKHO._agent_type | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def mE5q(YKHO):\n return YKHO.__agentType",
"def YWSi(YKHO):\n return HsDU[YKHO.name].value()",
"def AaOY(bo34=None):\n try:\n cQdE = Hy7s.environ['INSTALLER_TYPE']\n except KeyError:\n if bo34:\n bo34.error('Impossible to retrieve the installer type')\n cQdE = 'Unkn... | [
"0.7074494",
"0.66443145",
"0.60976505",
"0.57452404",
"0.57438195",
"0.5695543",
"0.5686199",
"0.5625656",
"0.5529047",
"0.5528788",
"0.5528788",
"0.55192935",
"0.55147064",
"0.55021656",
"0.55021656",
"0.5494508",
"0.5494508",
"0.5494508",
"0.5494508",
"0.5494508",
"0.54945... | 0.7428257 | 0 |
Gets the version of this RuntimeManifest. The version of the runtime binary, e.g., '1.0.1' | def DpZH(YKHO):
return YKHO._version | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def DpZH(YKHO) -> str:\n return YKHO.manifest['version']",
"def kaPv(YKHO):\n return YKHO._env.get_version()",
"def RB1Y(YKHO) -> qe4Y.Output[str]:\n return qe4Y.get(YKHO, 'runtime_version')",
"def bgym(YKHO) -> str:\n return YKHO.manifest['manifest']",
"def kaPv(YKHO):\n return YKHO.get_sin... | [
"0.7708844",
"0.74777645",
"0.74587697",
"0.7416657",
"0.7303796",
"0.7270513",
"0.72377694",
"0.7198032",
"0.7177293",
"0.7162392",
"0.70654255",
"0.70632744",
"0.7045499",
"0.7045499",
"0.7045499",
"0.70363456",
"0.70358574",
"0.7017525",
"0.7017525",
"0.7015846",
"0.700620... | 0.0 | -1 |
Sets the version of this RuntimeManifest. The version of the runtime binary, e.g., '1.0.1' | def DpZH(YKHO, DpZH):
YKHO._version = DpZH | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def v_xh(YKHO, DpZH=None):\n if DpZH is not None:\n YKHO.version = DpZH\n GPtr.setvalue(YKHO.app.lower(), 'version', YKHO.version)",
"def R2V2(YKHO, DpZH):\n YKHO.version = DpZH",
"def R2V2(YKHO, DpZH):\n YKHO._version = DpZH",
"def dPFR(YKHO, DpZH):\n YKHO.version = DpZH",
"def d... | [
"0.722552",
"0.7024961",
"0.69721967",
"0.69499034",
"0.68549407",
"0.6851472",
"0.6816073",
"0.6780406",
"0.6768413",
"0.67372465",
"0.67258894",
"0.67258894",
"0.66494954",
"0.66494954",
"0.66494954",
"0.6645088",
"0.66006154",
"0.6568139",
"0.652116",
"0.652116",
"0.650753... | 0.63523203 | 29 |
Gets the scheduling_defaults of this RuntimeManifest. Scheduling defaults for components defined in this manifest | def Y5H4(YKHO):
return YKHO._scheduling_defaults | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def RXGj(YKHO) -> h8nf['outputs.StandardAppVersionAutomaticScalingStandardSchedulerSettings']:\n return qe4Y.get(YKHO, 'standard_scheduler_settings')",
"def Y5H4(YKHO, Y5H4):\n YKHO._scheduling_defaults = Y5H4",
"def QXkN(YKHO) -> h8nf[qe4Y.Input[bdIy[qe4Y.Input['HostPoolScheduledAgentUpdatesScheduleArgs... | [
"0.6438916",
"0.63469225",
"0.59114575",
"0.58530825",
"0.5761115",
"0.56978935",
"0.56309485",
"0.5611256",
"0.55858034",
"0.5553204",
"0.5539065",
"0.54988575",
"0.54960614",
"0.5455547",
"0.54430276",
"0.5432276",
"0.54298246",
"0.54298246",
"0.54231274",
"0.5396138",
"0.5... | 0.8132765 | 0 |
Returns the string representation of the model | def gTzM(YKHO):
return EyO9(YKHO.to_dict()) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zAg0(YKHO):\n return str(YKHO.__model)",
"def zAg0(YKHO):\n return str(YKHO.model)",
"def zAg0(YKHO):\n return YKHO.text",
"def zAg0(YKHO):\n oOUF = '-----------------------------------------------------------------------------------\\n'\n _2sc = YKHO.__class__.__name__\n oOUF += '\\t\\... | [
"0.86418265",
"0.85103965",
"0.7853324",
"0.77442306",
"0.7712258",
"0.76979405",
"0.765959",
"0.7637644",
"0.76218504",
"0.7607561",
"0.7606604",
"0.7606604",
"0.7606604",
"0.75990754",
"0.7585653",
"0.758149",
"0.7570811",
"0.7567585",
"0.75392604",
"0.75392604",
"0.7527967... | 0.0 | -1 |
Returns true if both objects are not equal | def Vdqg(YKHO, Elif):
return not YKHO == Elif | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO.__eq__(Elif)",
"def Vdqg(YKHO, Elif: object) -> bool:\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif: object):\n return not YKHO == Elif",
"def Vdqg(YKHO, Elif):\n if YKHO.__eq__(Elif):\n return False\n return True",
"def Vdqg(... | [
"0.8392633",
"0.8354901",
"0.82950056",
"0.8132309",
"0.81149805",
"0.8099986",
"0.809911",
"0.8097883",
"0.8097883",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8092252",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8085141",
"0.8066694",
"0.80594814",
"0.805757",
... | 0.0 | -1 |
Recursively merge dict2 into dict1, returning the new dict1. keys keys to care about when checking for conflicts. Other keys take the value from the second dict. merge_lists whether to ignore conflicts between list values and merge instead | def roQF(WbPA, S69B, sjXb=None, gKI6=True):
for H5ew, BWXx in WbPA.items():
if H5ew in S69B:
zWAq = S69B[H5ew]
if BWXx != zWAq and (sjXb is None or H5ew not in sjXb):
if isinstance(BWXx, list) and gKI6:
BWXx = BWXx + zWAq
elif isins... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def k1Ji(LFlW: t.Dict[str, t.Any], _tIi: t.Dict[str, t.Any]) -> a1PO.Dict[str, a1PO.Any]:\n for H5ew, BWXx in LFlW.items():\n if H5ew in _tIi:\n if isinstance(BWXx, g760.abc.Mapping) and isinstance(_tIi[H5ew], g760.abc.Mapping):\n _tIi[H5ew] = k1Ji(BWXx, _tIi[H5ew])\n XIcQ = ... | [
"0.76464844",
"0.75352246",
"0.7411333",
"0.7281275",
"0.7257093",
"0.72209156",
"0.71706915",
"0.7170071",
"0.71619475",
"0.71578765",
"0.7131457",
"0.7101439",
"0.70763344",
"0.70484394",
"0.70431507",
"0.7032923",
"0.7031593",
"0.7002917",
"0.6999348",
"0.6975254",
"0.6931... | 0.80962735 | 0 |
this method tests that a question can be added to the platform | def tuZt(YKHO):
with YKHO.client as x0hE:
QePW = inWi(x0hE, **Uyix)
geh0 = qQXR.loads(QePW.data.decode())
YKHO.assertIn('User created successfully', geh0['message'])
YKHO.assertEqual(QePW.status_code, 201) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nc2h(YKHO):\n pass",
"def rXME(YKHO):\n pass",
"def pMxF(YKHO):\n pass",
"def it6l(YKHO):\n pass",
"def eOjU(YKHO):\n LhkH.objects.create(question='q1', tel_num=2, status=1)\n YKHO.receive('message', YKHO.lookup_connections('2')[0])\n YKHO.assertEqual(LhkH.objects.all()[0].status, ... | [
"0.7899987",
"0.77644",
"0.7169477",
"0.7030808",
"0.7014457",
"0.6975487",
"0.6969964",
"0.69689924",
"0.6923812",
"0.6869084",
"0.6819977",
"0.680985",
"0.6754468",
"0.6752113",
"0.67491543",
"0.67438656",
"0.67405766",
"0.670344",
"0.66723543",
"0.66560394",
"0.6646844",
... | 0.0 | -1 |
this method tests that a question can be added to the platform | def IttA(YKHO):
with YKHO.client as x0hE:
QePW = inWi(x0hE, **Of0q)
geh0 = qQXR.loads(QePW.data.decode())
YKHO.assertIn("User 'geneowak' already exists", geh0['message'])
YKHO.assertEqual(QePW.status_code, 400) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nc2h(YKHO):\n pass",
"def rXME(YKHO):\n pass",
"def pMxF(YKHO):\n pass",
"def it6l(YKHO):\n pass",
"def eOjU(YKHO):\n LhkH.objects.create(question='q1', tel_num=2, status=1)\n YKHO.receive('message', YKHO.lookup_connections('2')[0])\n YKHO.assertEqual(LhkH.objects.all()[0].status, ... | [
"0.7900608",
"0.7765107",
"0.71715343",
"0.70321715",
"0.70157176",
"0.69761866",
"0.69701403",
"0.69678867",
"0.6925701",
"0.6869847",
"0.6819623",
"0.6809708",
"0.67561895",
"0.67534024",
"0.6751408",
"0.6743108",
"0.6741759",
"0.67040163",
"0.6673754",
"0.6656322",
"0.6646... | 0.0 | -1 |
this method tests that a question can be added to the platform | def UHFF(YKHO):
with YKHO.client as x0hE:
QePW = MC83(x0hE, **Of0q)
geh0 = qQXR.loads(QePW.data.decode())
YKHO.assertIn('Login successful', geh0['message'])
YKHO.assertEqual(QePW.status_code, 200) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def nc2h(YKHO):\n pass",
"def rXME(YKHO):\n pass",
"def pMxF(YKHO):\n pass",
"def it6l(YKHO):\n pass",
"def eOjU(YKHO):\n LhkH.objects.create(question='q1', tel_num=2, status=1)\n YKHO.receive('message', YKHO.lookup_connections('2')[0])\n YKHO.assertEqual(LhkH.objects.all()[0].status, ... | [
"0.7899987",
"0.77644",
"0.7169477",
"0.7030808",
"0.7014457",
"0.6975487",
"0.6969964",
"0.69689924",
"0.6923812",
"0.6869084",
"0.6819977",
"0.680985",
"0.6754468",
"0.6752113",
"0.67491543",
"0.67438656",
"0.67405766",
"0.670344",
"0.66723543",
"0.66560394",
"0.6646844",
... | 0.0 | -1 |
Test that a form with draft status is only visible to staff. | def HQX4(YKHO):
gCuF.DEBUG = True
NtEF = 'test'
jTXt = 'test'
mv1M.objects.create_superuser(NtEF, '', jTXt)
YKHO.client.logout()
S3dM = Y509.objects.create(title='Draft', status=y2WA)
if OmBO:
S3dM.sites.add(YKHO._site)
S3dM.save()
geh0 = YKHO.client.get(S3dM.get_absolute... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Iw6c(YKHO) -> bool:\n return bool(YKHO.request.user.is_staff)",
"def emy_(YKHO):\n DTd6 = YKHO.scope_ids.user_id is None\n return getattr(YKHO.xmodule_runtime, 'user_is_staff', False) and (not DTd6) and (not YKHO.no_submission)",
"def ejzn(YKHO):\n YKHO.assertFalse(YKHO.created_user.is_staff)",... | [
"0.66270787",
"0.65490884",
"0.628301",
"0.6276855",
"0.6170362",
"0.61542743",
"0.60983294",
"0.6051256",
"0.6022782",
"0.6007478",
"0.5984466",
"0.5979637",
"0.59652877",
"0.59652877",
"0.59652877",
"0.5962192",
"0.5962192",
"0.5960952",
"0.59495515",
"0.5948915",
"0.593607... | 0.6917994 | 0 |
Test that the different formats for the ``render_built_form`` tag all work. | def iYBS(YKHO):
L03z = Y509.objects.create(title='Tags', status=c2Jl)
QePW = type(str(''), (), {'META': {}, 'user': fCU0()})()
QpfX = K1Ja(QePW, {'form': L03z})
rPXJ = '{%% load forms_builder_tags %%}{%% render_built_form %s %%}'
x7JD = ('form', 'form=form', 'id=form.id', 'slug=form.slug')
for f... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def KffU(YKHO):\n if Lpna:\n raise G8rZ()\n _hkX = YKHO.app.post('/display_form')\n assert 'id=\"my_form_title.label\"' in _hkX, _hkX\n assert 'class=\"fieldlabel required\"' in _hkX, _hkX\n assert 'Title' in _hkX, _hkX",
"def QmTI(YKHO):\n assert IkWL.Form().validate_render({})[0] is Tr... | [
"0.6955188",
"0.661441",
"0.6158381",
"0.6132688",
"0.610613",
"0.6038028",
"0.59790003",
"0.5926804",
"0.5914158",
"0.5906997",
"0.5814384",
"0.5808548",
"0.5804993",
"0.5793552",
"0.5781382",
"0.57548857",
"0.5699025",
"0.5696514",
"0.56946313",
"0.56917006",
"0.56814474",
... | 0.6660569 | 1 |