query
stringlengths
10
2k
document
stringlengths
20
51.2k
metadata
dict
negatives
listlengths
0
101
negative_scores
listlengths
0
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Test that a ValueError is raised when initialising a Sinusoidal DataSet with xlimits that don't broadcast to the size of x_train and test.x. As stated in the docstring for the data.Sinusoidal initialiser, x_hi "should be a float, or a numpy array with shape [input_dim, 1]".
def test_sinusoidal_invalid_xlim(): with pytest.raises(ValueError): d = data.Sinusoidal(input_dim=3, x_lo=[1, 2]) with pytest.raises(ValueError): d = data.Sinusoidal(input_dim=4, x_hi=[3, 4, 5, 6], n_train=10) with pytest.raises(ValueError): x_hi = np.array([3, 4, 5, 6]).reshape(1,...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def test_sinusoidal_valid_xlim():\n # Test single-dimensional x-limits\n d = data.Sinusoidal(input_dim=4, x_hi=7.5, n_train=10)\n\n # Test multi-dimensional x-limits\n x_hi = np.array([3, 4, 5, 6]).reshape(-1, 1)\n d = data.Sinusoidal(input_dim=4, x_hi=x_hi, n_train=10)", "def test_sinusoidal_inva...
[ "0.82507175", "0.7061065", "0.6526121", "0.61525166", "0.60648817", "0.6047244", "0.6029876", "0.5997701", "0.5951664", "0.5922276", "0.5911692", "0.5910902", "0.5861408", "0.58533555", "0.58473945", "0.58419716", "0.58122104", "0.5801483", "0.57864684", "0.5759275", "0.57510...
0.8641391
0
returns the 10 states in the buffer in the form of a torch tensor in the order in which they were encountered
def getHistory(self): arrSize = self.buffer[0].shape[1] arrayHist = np.asarray(self.buffer) arrayHist = np.reshape(arrayHist, (1, arrSize * self.bufferSize)) state = torch.from_numpy(arrayHist).to(self.device) state = state.type(torch.cuda.FloatTensor) return state
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def obs2state(observation):\n l1 = [val.tolist() for val in list(observation.values())]\n l2 = []\n for sublist in l1:\n try:\n l2.extend(sublist)\n except:\n l2.append(sublist)\n return torch.FloatTensor(l2).view(1, -1)", "def spit(self):\n idxs = np.arange...
[ "0.62470174", "0.6240836", "0.62133694", "0.6151693", "0.61003697", "0.6083209", "0.6031348", "0.6029954", "0.60242444", "0.60075206", "0.59954375", "0.59234744", "0.592341", "0.59016013", "0.59005815", "0.58944803", "0.587009", "0.58636975", "0.5850975", "0.58461607", "0.582...
0.6043191
6
creates a onehot array of length 'size' and sets indexes in list 'idx' to be ones.
def to_oh(idx, size): out = np.zeros(size) out[idx] = 1 return out
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_one_hot(size, ind):\n one_hot = np.zeros((size,))\n one_hot[ind] = 1\n return one_hot", "def one_hot_encode(idx, vocab_size):\n # Initialize the encoded array\n one_hot = np.zeros(vocab_size)\n \n # Set the appropriate element to one\n one_hot[idx] = 1.0\n\n return one_hot", ...
[ "0.85007226", "0.817196", "0.79167044", "0.7711318", "0.76636624", "0.7568578", "0.7568513", "0.7556647", "0.7535074", "0.7470529", "0.74541855", "0.7398961", "0.72270286", "0.71101564", "0.71099555", "0.7004205", "0.69983613", "0.69957", "0.68536526", "0.6836187", "0.6814278...
0.0
-1
returns a torch tensor for cpu or gpu when appropriate.
def inner(*args, **kwargs): s = f(*args, **kwargs) if torch.cuda.is_available(): return torch.from_numpy(s).cuda().type(dtype) return torch.from_numpy(s).type(dtype)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def d(tensor=None):\n if tensor is None:\n return 'cuda' if torch.cuda.is_available() else 'cpu'\n return 'cuda' if tensor.is_cuda else 'cpu'", "def _create_device(self):\n return torch.device(\"cuda\" if torch.cuda.is_available() else \"cpu\")", "def device():\n return torch.device('cud...
[ "0.75074846", "0.6957397", "0.6949091", "0.6948686", "0.69339514", "0.6911639", "0.685103", "0.64918804", "0.64831996", "0.6421975", "0.6421975", "0.6334914", "0.62923133", "0.6291921", "0.6290327", "0.62333614", "0.62177485", "0.620876", "0.6156528", "0.6118051", "0.6085593"...
0.5979092
29
returns a torch tensor for cpu or gpu when appropriate.
def inner(*args, **kwargs): s, r, d, p = f(*args, **kwargs) if torch.cuda.is_available(): s = torch.from_numpy(s).cuda().type(dtype) else: s = torch.from_numpy(s).type(dtype) return s, r, d, p
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def d(tensor=None):\n if tensor is None:\n return 'cuda' if torch.cuda.is_available() else 'cpu'\n return 'cuda' if tensor.is_cuda else 'cpu'", "def _create_device(self):\n return torch.device(\"cuda\" if torch.cuda.is_available() else \"cpu\")", "def device():\n return torch.device('cud...
[ "0.75074846", "0.6957397", "0.6949091", "0.6948686", "0.69339514", "0.6911639", "0.685103", "0.64918804", "0.64831996", "0.6421975", "0.6421975", "0.6334914", "0.62923133", "0.6291921", "0.6290327", "0.62333614", "0.62177485", "0.620876", "0.6156528", "0.6118051", "0.6085593"...
0.0
-1
Makes a faster deep copy of a dictionary, provided it only includes native types, numpy arrays, and other dicts containing the aforementioned.
def copy_dict(in_dict): if in_dict is None: return None out_dict = {} for key, val in in_dict.items(): if isinstance(val, np.ndarray): out_dict[key] = val.copy() elif isinstance(val, dict): out_dict[key] = copy_dict(val) else: out_dict[...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def copy_obs_dict(obs):\n return {k: np.copy(v) for k, v in obs.items()}", "def copy(self):\n return pdict(dict.copy(self))", "def deepish_copy(org):\n out = dict().fromkeys(org)\n for k,v in org.items():\n try:\n out[k] = v.copy() # dicts, sets\n except AttributeError:\n...
[ "0.740023", "0.715696", "0.7063612", "0.70240486", "0.6893642", "0.68819386", "0.68759614", "0.6707072", "0.67013973", "0.6690156", "0.6665948", "0.6643454", "0.6631786", "0.6544152", "0.6527721", "0.64701086", "0.6451407", "0.6443501", "0.6391387", "0.6385858", "0.63385326",...
0.7445735
0
Return the unique locator of the component. The container property should be used for finding elements within the Component.
def container(self) -> Union[Element, None]: if self._container is None and self.ROOT_LOCATOR is not None: try: return self.driver.find_element(*self.ROOT_LOCATOR) except WebDriverException: return None return self._container
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_element_locator(self):\n return self._find_by_locator().locator", "def component_id(self) -> str:\n return pulumi.get(self, \"component_id\")", "def component_id(self) -> str:\n return pulumi.get(self, \"component_id\")", "def containerID(self):\n return self._container", ...
[ "0.584968", "0.5806735", "0.5806735", "0.56683934", "0.5645886", "0.5596713", "0.55917645", "0.5566299", "0.554846", "0.554846", "0.5472993", "0.54071313", "0.5395849", "0.52848", "0.516613", "0.5151198", "0.5150812", "0.50920725", "0.50770795", "0.5065384", "0.5022508", "0...
0.58994013
0
Update the policy towards gradient minimisation.
def update_policy(self): self.optimizer.step() self.optimizer.zero_grad()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def update_policy(self, req):\n\n with self.mutex:\n\n # Apply all gradients\n for gradient in req.gradients:\n\n self.global_policy.zero_grad()\n\n # Transfer gradient to global policy\n self.transfer_gradient(gradient)\n\n #...
[ "0.7133308", "0.71033305", "0.6860328", "0.6839332", "0.6750171", "0.6742011", "0.6742011", "0.65853024", "0.6578528", "0.6524286", "0.6504555", "0.65042746", "0.65024805", "0.64918643", "0.64248914", "0.6421828", "0.64096856", "0.6384872", "0.6378293", "0.6375617", "0.636486...
0.8098685
0
Returns a learning rate multiplier. Till `warmup_epochs`, learning rate linearly increases to `initial_lr`, and then gets multiplied by `lr_gamma` every time a milestone is crossed.
def lr_lambda_fun(current_iteration: int) -> float: current_epoch = float(current_iteration) / self.iterations if current_epoch <= self.hparams.warmup_epochs: alpha = current_epoch / float(self.hparams.warmup_epochs) return self.hparams.warmup_factor * (1.0 - alpha) + alpha else: ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def adjust_learning_rate(optimizer, gamma, epoch, step_index, iteration, epoch_size):\n warmup_epoch = -1\n if epoch <= warmup_epoch:\n lr = 1e-6 + (initial_lr-1e-6) * iteration / (epoch_size * warmup_epoch)\n else:\n lr = initial_lr * (gamma ** (step_index))\n for param_group in optimize...
[ "0.73172796", "0.7291044", "0.7040951", "0.7020304", "0.7020304", "0.69728035", "0.6957149", "0.6908177", "0.6898319", "0.68701005", "0.68401206", "0.68250597", "0.68250597", "0.68181247", "0.67841184", "0.6776931", "0.67424643", "0.67359215", "0.6726599", "0.6721407", "0.667...
0.68627304
10
Sets the padding of the box.
def uiBoxSetPadded(box, padded): return clibui.uiBoxSetPadded(box, padded)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def SetToolBorderPadding(self, padding):\r\n\r\n self._tool_border_padding = padding", "def setHighlightPadding( self, padding ):\n self._highlightPadding = float(padding)", "def rounded_padding_box(self):\n return self.rounded_box(\n self.border_top_width,\n self.bor...
[ "0.71547043", "0.69287086", "0.67011386", "0.64324564", "0.6394307", "0.63604707", "0.6292556", "0.623254", "0.6129037", "0.611621", "0.6101955", "0.6094178", "0.59365183", "0.58720225", "0.57999176", "0.5795704", "0.5623149", "0.5605316", "0.5599155", "0.55901927", "0.550882...
0.6398962
4
Returns an horizonal box
def uiNewHorizontalBox(): # Set return type clibui.uiNewHorizontalBox.restype = ctypes.POINTER(uiBox) return clibui.uiNewHorizontalBox()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def box(self, x, y, w, h):\n\t\tpass", "def print_lower_box_line():\n print_indentation()\n print(STYLES[parameters[\"Style\"]][\"Lower left corner\"], end=\"\")\n for _ in range(text_width_with_spaces):\n print(STYLES[parameters[\"Style\"]][\"Horizontal line\"], end=\"\")\n print(STYLES[param...
[ "0.648853", "0.64233685", "0.6334169", "0.6334169", "0.6281487", "0.6100632", "0.5914149", "0.5909809", "0.58835644", "0.5836569", "0.5818222", "0.579173", "0.5722725", "0.5693106", "0.5674006", "0.5652499", "0.56512713", "0.56438434", "0.56310797", "0.5569382", "0.55501586",...
0.6863571
0
Returns a vertical box.
def uiNewVerticalBox(): # Set return type clibui.uiNewVerticalBox.restype = ctypes.POINTER(uiBox) return clibui.uiNewVerticalBox()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def vertical(self):\n return self._vertical", "def make_box(stdscr, margin:int):\n sh, sw = stdscr.getmaxyx()\n\n box = (\n (margin, margin),\n (sh-margin, sw-margin)\n )\n rectangle(stdscr, box[0][0], box[0][1], box[1][0], box[1][1])\n stdscr.refresh()\n return box", "de...
[ "0.71319246", "0.6555198", "0.6545565", "0.6417528", "0.6313212", "0.61657774", "0.6089948", "0.60688394", "0.6055331", "0.60266155", "0.59782344", "0.59030807", "0.5864125", "0.5810194", "0.5804189", "0.579966", "0.5789129", "0.57780665", "0.5740657", "0.5733366", "0.5722404...
0.756977
0
Returns a new dictionary based on `_dict`, restricting keys to those in the iterable `keys`.
def pick(keys, _dict): key_set = set(keys) & set(_dict.keys()) return dict((key, _dict[key]) for key in key_set)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _filter_keys(d: dict, keys: set) -> dict:\n return {key: d[key] for key in keys if key in d}", "def only_some_keys(dic, *keys):\n ret = {}\n for key in keys:\n ret[key] = dic[key] # Raises KeyError.\n return ret", "def _filter_keys(item, keys):\n return dict((k, v) for k, v in i...
[ "0.77919745", "0.77433276", "0.7384091", "0.7382268", "0.7380925", "0.734552", "0.7228086", "0.72250354", "0.71410555", "0.7120883", "0.70789886", "0.7077636", "0.7055068", "0.7049844", "0.7012748", "0.69217265", "0.68992394", "0.686657", "0.684182", "0.68406624", "0.67788893...
0.7347125
5
Train and validation data loaders. If using CUDA, num_workers should be set to 1 and pin_memory to True.
def get_train_valid_loader( data_dir: Path, batch_size: int, random_seed: int, *, valid_size: float = 0.1, shuffle: bool = True, num_workers: int = 4, pin_memory: bool = False, using_cuda: bool = True, ) -> Tuple[torch.utils.data.DataLoader, torch.utils.data.D...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_train_loaders(config):\n assert 'loaders' in config, 'Could not find data loaders configuration'\n loaders_config = config['loaders']\n\n logger.info('Creating training and validation set loaders...')\n\n # get dataset class\n dataset_cls_str = loaders_config.get('dataset', None)\n if dat...
[ "0.7448477", "0.7433901", "0.7323474", "0.7300152", "0.7211862", "0.71513426", "0.70979655", "0.70978105", "0.7047037", "0.7036657", "0.7034936", "0.7021785", "0.7018932", "0.7002462", "0.7002462", "0.7002462", "0.7002462", "0.7002462", "0.7002462", "0.7002462", "0.7002462", ...
0.6670798
53
Method to initialize a fixed paper bypass capacitor data model instance.
def __init__(self): super(Bypass, self).__init__() # Initialize public scalar attributes. self.specification = 0 # MIL-C-25 or MIL-C-12889. self.spec_sheet = 0 # if self.hazard_rate_type < 3: # MIL-HDBK-217 self.reference_t...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __init__ (self) :\n self.loadCSPAD2x2CalibParsDefault()", "def __init__(self):\n if not os.path.isfile(PREDICTOR_PATH):\n try:\n print ('Predictor not found. Downloading...this may take a while...')\n url = 'https://github.com/hriddhidey/visage/blob/mast...
[ "0.56605643", "0.5631703", "0.5603185", "0.5531293", "0.55057305", "0.5474339", "0.5468749", "0.5468749", "0.5468749", "0.5454386", "0.5423358", "0.541508", "0.54039514", "0.53960836", "0.53943884", "0.5391988", "0.53797185", "0.5355427", "0.53510463", "0.53401256", "0.529789...
0.64554626
0
Method to initialize a fixed paper feedthrough capacitor data model instance.
def __init__(self): super(Feedthrough, self).__init__() # Initialize public scalar attributes. self.spec_sheet = 0 # Characteristic E, K, P, or W. if self.hazard_rate_type < 3: # MIL-HDBK-217 self.reference_temperature = 358.0
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def initialize(self, model):\n pass", "def __init__(self):\r\n\r\n super(Bypass, self).__init__()\r\n\r\n # Initialize public scalar attributes.\r\n self.specification = 0 # MIL-C-25 or MIL-C-12889.\r\n self.spec_sheet = 0 #\r\n if self.hazar...
[ "0.59698486", "0.59545016", "0.5887364", "0.5868895", "0.57281184", "0.57179004", "0.571618", "0.57110226", "0.56136376", "0.5604693", "0.5590886", "0.5525213", "0.5525213", "0.5525213", "0.5508003", "0.55046964", "0.5502422", "0.5499117", "0.5496652", "0.54930043", "0.548183...
0.627681
0
Method to initialize a fixed metallized paper capacitor data model instance.
def __init__(self): super(Metallized, self).__init__() # Initialize public scalar attributes. self.spec_sheet = 0 if self.hazard_rate_type < 3: # MIL-HDBK-217 self.reference_temperature = 358.0
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __init__(self):\r\n\r\n super(Bypass, self).__init__()\r\n\r\n # Initialize public scalar attributes.\r\n self.specification = 0 # MIL-C-25 or MIL-C-12889.\r\n self.spec_sheet = 0 #\r\n if self.hazard_rate_type < 3: # MIL-HDBK-217\r\n ...
[ "0.63892734", "0.62356937", "0.60370934", "0.5986701", "0.5974616", "0.5952684", "0.5854218", "0.58036363", "0.57712287", "0.57269406", "0.5718652", "0.5691929", "0.56858313", "0.5684827", "0.5684659", "0.5668943", "0.5650766", "0.5636431", "0.5636431", "0.5636431", "0.563308...
0.6565761
0
Discrete cosine transform This function originally existed to replicate Matlabs dct function using scipy's dct function. It was necessary to perform the dct along the rows and columns. To simplify the container creation, the dct function from opencv was used. This function is slower, and scipy's version should be imple...
def _dct2(imgflt_stack): d = cv2.dct(imgflt_stack).astype(np.float64) return d
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def dct(f, axis=-1):\n\n # Size of the input along the specified axis.\n n = f.shape[axis]\n\n # Create two vectors containing the integers from 0 to n-1.\n i = k = np.arange(n)\n\n # Compute the x-axis coordinate of the f function.\n x = (2 * i + 1) / (2 * n)\n\n # Compute the outer product o...
[ "0.7243201", "0.7202878", "0.68848133", "0.6597979", "0.6331608", "0.6183264", "0.61051756", "0.60531604", "0.60465574", "0.6019478", "0.5882954", "0.5709797", "0.56822425", "0.56684345", "0.5654719", "0.56476843", "0.562984", "0.5605799", "0.5580458", "0.5577763", "0.5506232...
0.50631976
57
Initialise with empty arrays
def __init__(self): self.temperature = np.array([]) self.salinity = np.array([]) self.date = np.array([]) self.temperatureQF = np.array([]) self.salinityQF = np.array([])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _init_empty(self):\n self._data = []", "def __init__(self):\n self.arr = []\n for i in range(80):\n self.arr.append([])", "def __init__(self):\n self.array = [None for i in range(10000)]", "def initialize(self):\n x0 = [None]*3\n for i in self.free:\n ...
[ "0.74245286", "0.7125384", "0.69205505", "0.69110274", "0.68678844", "0.6813673", "0.65707946", "0.6555074", "0.6554811", "0.6545936", "0.6505278", "0.6468751", "0.64523095", "0.6438656", "0.642166", "0.63936675", "0.63936675", "0.63936675", "0.63936675", "0.63686407", "0.635...
0.667415
6
Sets the cabletype of this EndpointPort.
def cabletype(self, cabletype): self._cabletype = cabletype
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def SetType(self, ct_type):\r\n\r\n self._type = ct_type", "def set_type(self, type):\n self.type = type", "def set_type(self, type):\n self.type = type", "def set_type(self, type):\n self._type = type", "def set_type(self, type, asset=None):\n self._set_property('pc:type...
[ "0.6082409", "0.5971174", "0.5971174", "0.5912708", "0.5896561", "0.58715934", "0.5869885", "0.58139575", "0.5718777", "0.5698157", "0.5670525", "0.5670525", "0.5670525", "0.5670525", "0.5670525", "0.5670525", "0.5670525", "0.5670525", "0.5670525", "0.5670525", "0.5670525", ...
0.7924619
0
Sets the vport of this EndpointPort.
def vport(self, vport): self._vport = vport
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def setport(self, port):\n self.__port = port", "def setPort(self, port):\n libxml2mod.xmlURISetPort(self._o, port)", "def port(self, port):\n\n self._port = port", "def port(self, port):\n\n self._port = port", "def port(self, port):\n\n self._port = port", "def set_vn...
[ "0.6798428", "0.6536438", "0.64268637", "0.64268637", "0.64268637", "0.6335774", "0.62666005", "0.6106723", "0.60891765", "0.6024321", "0.6011783", "0.6011783", "0.6002069", "0.59743917", "0.59706175", "0.5845767", "0.57627624", "0.5746521", "0.5745913", "0.56158763", "0.5615...
0.84797245
0
Returns true if both objects are equal
def __eq__(self, other): if not isinstance(other, EndpointPort): return False return self.__dict__ == other.__dict__
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __eq__(self, other):\n return are_equal(self, other)", "def __eq__(self, other):\n return are_equal(self, other)", "def __eq__(self,other):\n try: return self.object==other.object and isinstance(self,type(other))\n except: return False", "def __eq__(self, other):\n if i...
[ "0.8088132", "0.8088132", "0.8054589", "0.7982687", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", "0.79670393", ...
0.0
-1
Returns true if both objects are not equal
def __ne__(self, other): return not self == other
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __ne__(self, other: object) -> bool:\n if self.__eq__(other):\n return False\n return True", "def __ne__(self, other: object) -> bool:\n return not self.__eq__(other)", "def __ne__(self, other) -> bool:\n return not self.__eq__(other)", "def __eq__(self, other):\n ...
[ "0.845611", "0.8391477", "0.8144138", "0.81410587", "0.8132492", "0.8093973", "0.80920255", "0.80920255", "0.80920255", "0.8085325", "0.8085325", "0.8076365", "0.8076365", "0.8065748" ]
0.0
-1
Returns the nodes that are involved in samehost transmission.
def same_host_descent(G, host_species): nodes = set() # nodes that are involved in human-human transmission. for sc, sk, d in G.edges(data=True): sc_host = G.node[sc]['host_species'] sk_host = G.node[sk]['host_species'] sc_subtype = G.node[sc]['subtype'] sk_subtype = G....
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def getNodes(self):\n nodes = [{\"address\": \"http://0.0.0.0:100\"}\n ,{\"address\": \"http://0.0.0.0:200\"}\n ,{\"address\": \"http://0.0.0.0:300\"}\n ,{\"address\": \"http://0.0.0.0:400\"}\n ,{\"address\": \"http://0.0.0.0:500\"}]\n retur...
[ "0.69564664", "0.68129665", "0.6775778", "0.6775778", "0.67545515", "0.670209", "0.66642195", "0.6663798", "0.6618814", "0.6607294", "0.6595256", "0.6539304", "0.65308946", "0.6501001", "0.64669794", "0.64458746", "0.6423951", "0.6393715", "0.63774943", "0.634415", "0.6327830...
0.62601346
26
r""" Use this API to count filtered the set of lsntransportprofile resources.
def count_filtered(cls, client, filter_) : try : obj = lsntransportprofile() option_ = options() option_.count = True option_.filter = filter_ response = obj.getfiltered(client, option_) if response : return response[0].__dict__['___count'] return 0 except Exception as e : raise e
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def count(cls, client) :\n\t\ttry :\n\t\t\tobj = lsntransportprofile()\n\t\t\toption_ = options()\n\t\t\toption_.count = True\n\t\t\tresponse = obj.get_resources(client, option_)\n\t\t\tif response :\n\t\t\t\treturn response[0].__dict__['___count']\n\t\t\treturn 0\n\t\texcept Exception as e :\n\t\t\traise e", "d...
[ "0.70993674", "0.63204956", "0.629977", "0.58865976", "0.5848211", "0.5815522", "0.5715243", "0.54175544", "0.54111826", "0.54080623", "0.5396334", "0.5376295", "0.5171212", "0.51088667", "0.5047795", "0.49986812", "0.49927226", "0.49915752", "0.49903664", "0.4969002", "0.496...
0.73774296
0
important to reset the parameters of the simulation for each run
def reset(self): Simulation.reset(self)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def reset_parameters(self):\n self.rnn.reset_parameters()\n self.action_lookup.reset_parameters()\n\n # self.state_dict_lookup.reset_parameters()\n self.own_c_lookup.reset.parameters()\n self.own_s_lookup.reset_parameters()\n\n self.th_1_lookup.reset_parameters()\n ...
[ "0.74126", "0.73593175", "0.7357744", "0.72735965", "0.72510463", "0.7177278", "0.7162423", "0.7136781", "0.71206963", "0.71025246", "0.71025246", "0.7094235", "0.70760673", "0.7075606", "0.706025", "0.69804007", "0.69660336", "0.6956141", "0.6943643", "0.6943643", "0.6932077...
0.74002284
1
mesure b = b+a, a reste a
def addition(a, b): bina = [int(x) for x in bin(a)[2:]] binb = [int(x) for x in bin(b)[2:]] while len(bina) >= len(binb): binb = [0]+binb while len(bina) < len(binb)-1: bina = [0]+bina bina.reverse() binb.reverse() n = len(bina)+len(binb) na = len(bina) q = QuantumReg...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def add(a,b):\n if a == 0: return b\n elif b == 0: return a\n else: return add(a-1, b+1)", "def suma(a, b):\n\n\ttotal = a + b\n\treturn total", "def make_abba(a, b):\n return a + b * 2 + a", "def add(a: int, b: int) -> int:\n if a == 0:\n return b\n elif b == 0:\n return a\n ...
[ "0.7491585", "0.721712", "0.71878177", "0.7166232", "0.7112104", "0.7079948", "0.689132", "0.6860645", "0.6829874", "0.6822391", "0.68115765", "0.6802283", "0.6800593", "0.6800593", "0.6762015", "0.67618835", "0.6742176", "0.6736365", "0.67156816", "0.66800547", "0.6669307", ...
0.6637637
27
mesure b = b+a, a reste a
def addition_o(a, b): bina = [int(x) for x in bin(a)[2:]] binb = [int(x) for x in bin(b)[2:]] while len(bina) >= len(binb): binb = [0]+binb while len(bina) < len(binb)-1: bina = [0]+bina bina.reverse() binb.reverse() n = len(bina)+len(binb) na = len(bina) q = QuantumR...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def add(a,b):\n if a == 0: return b\n elif b == 0: return a\n else: return add(a-1, b+1)", "def suma(a, b):\n\n\ttotal = a + b\n\treturn total", "def make_abba(a, b):\n return a + b * 2 + a", "def add(a: int, b: int) -> int:\n if a == 0:\n return b\n elif b == 0:\n return a\n ...
[ "0.7491585", "0.721712", "0.71878177", "0.7166232", "0.7112104", "0.7079948", "0.689132", "0.6860645", "0.6829874", "0.6822391", "0.68115765", "0.6802283", "0.6800593", "0.6800593", "0.6762015", "0.67618835", "0.6742176", "0.6736365", "0.67156816", "0.66800547", "0.6669307", ...
0.65896094
33
mesure b = b+a, a reste a
def addition_mod(a, b, nbr): bina = [int(x) for x in bin(a)[2:]] binb = [int(x) for x in bin(b)[2:]] binn = [int(x) for x in bin(nbr)[2:]] #print(binn) while len(bina) >= len(binb): binb = [0]+binb while len(bina) < len(binb)-1: bina = [0]+bina while len(binn) < len(bina): ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def add(a,b):\n if a == 0: return b\n elif b == 0: return a\n else: return add(a-1, b+1)", "def suma(a, b):\n\n\ttotal = a + b\n\treturn total", "def make_abba(a, b):\n return a + b * 2 + a", "def add(a: int, b: int) -> int:\n if a == 0:\n return b\n elif b == 0:\n return a\n ...
[ "0.7491585", "0.721712", "0.71878177", "0.7166232", "0.7112104", "0.7079948", "0.689132", "0.6860645", "0.6829874", "0.6822391", "0.68115765", "0.6802283", "0.6800593", "0.6800593", "0.6762015", "0.67618835", "0.6742176", "0.6736365", "0.67156816", "0.66800547", "0.6669307", ...
0.0
-1
Resets all user settings.
async def reset(self, ctx, user : str=None): cyphon = discord.utils.get(ctx.message.server.members, id="186835826699665409") if self.check_channel(ctx): if self.check_permission(ctx) or ctx.message.author == cyphon: userFound = False if (user == "bot"): ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def reset_settings():\n settings = Settings()\n settings.reset()\n settings.save()", "def clearAllSettings(self) -> None:\n ...", "async def _reset_settings(self, ctx):\n data = await self.get_data(ctx)\n await data.Settings.clear()\n msg = (\"{0.name} ({0.id}) reset all \"...
[ "0.80459386", "0.7999448", "0.79718506", "0.77476704", "0.76072717", "0.74945843", "0.7281146", "0.7212389", "0.7155161", "0.70512056", "0.69930583", "0.69436246", "0.69074893", "0.68918353", "0.676131", "0.6749676", "0.6689122", "0.6644092", "0.659244", "0.6588544", "0.65855...
0.0
-1
Gets the `user.name` configured property.
def user_name(self) -> str: result = subprocess.run( ["git", "config", "user.name"], check=True, cwd=self.dir, encoding="utf-8", stdout=subprocess.PIPE, ) return result.stdout.strip()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def user_name(self) -> str:\n return pulumi.get(self, \"user_name\")", "def getUserName(self):\n user = User.by_id(self.user_id)\n return user.name", "def user_name(self):\n return self._user_name", "def get_name(self):\n return self.user.username if self.user.username else...
[ "0.80897087", "0.79748535", "0.7912074", "0.7867508", "0.78557134", "0.7830691", "0.7792011", "0.7666164", "0.7656069", "0.76533896", "0.7602009", "0.75911784", "0.7570611", "0.7474011", "0.74507844", "0.74421436", "0.7409676", "0.740338", "0.7394927", "0.7311124", "0.7253367...
0.73327833
19
Set the direction of the fan.
def set_direction(self, direction: str) -> None: if direction == "forward": self._bond.setDirection(self._deviceId, Directions.FORWARD) elif direction == "reverse": self._bond.setDirection(self._deviceId, Directions.REVERSE) self._attributes['current_direction'] = directi...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def set_direction(self, direction: str) -> None:\n self.wink.set_fan_direction(direction)", "async def async_set_direction(self, direction: str) -> None:\n if direction == DIRECTION_FORWARD:\n self._device.fan_dir = SENSEME_DIRECTION_FORWARD\n else:\n self._device.fan_d...
[ "0.84235466", "0.8002017", "0.7371954", "0.7242101", "0.71836823", "0.70205814", "0.6959635", "0.69295996", "0.680304", "0.6784216", "0.671103", "0.66704005", "0.6656352", "0.66099894", "0.66099894", "0.656002", "0.64762187", "0.6465095", "0.6440604", "0.64347273", "0.6427641...
0.6862913
8
Return the ID of this fan.
def device_id(self): return self.unique_id
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_id(self):\n\n\t\treturn self.__id", "def get_id(self):\n return self.__id", "def get_id(self):\n return self.__id", "def getID(self):\n return self.__id", "def get_id(self):\n return self.id", "def get_id(self):\n return self.id", "def get_id(self):\n r...
[ "0.7602217", "0.7581651", "0.7581651", "0.75514257", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", "0.75165975", ...
0.0
-1
Takes a list of os.DirEntry instances (`fileset`) and optional file size bounds. This function groups the os.DirEntry instances in the `fileset` list by size and returns lists of os.DirEntry instances, grouped by their file size. Only groups larger than `min_group_size` are returned.
def group_by_size(fileset, min_size=DEFAULT_MIN_SIZE, max_size=DEFAULT_MAX_SIZE, min_group_size=2, workers=16): return group_by_key(fileset, size_key(min_size=min_size, max_size=max_size), min_group_size=min_group_size, workers=workers)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def group_by_key(fileset, keyfunc, min_group_size=2, workers=16):\n pool = ThreadPool(workers)\n\n def evaluate(entry):\n return keyfunc(entry), entry\n\n keyed_fileset = pool.map(evaluate, fileset)\n files_by_key = {}\n for key, entry in keyed_fileset:\n if key is None:\n c...
[ "0.68340915", "0.67008173", "0.5891528", "0.5725846", "0.56749976", "0.56577903", "0.56277245", "0.5557965", "0.5434485", "0.5362395", "0.52733916", "0.5248512", "0.52346754", "0.5195571", "0.51573217", "0.5146702", "0.5136847", "0.51073664", "0.51056486", "0.50906515", "0.50...
0.8297646
0
generated source for method equals
def equals(self, obj): if obj == None: return False if not (isinstance(obj, (SentenceForm, ))): return False o = obj if self.__name__ != o.__name__: return False if self.getTupleSize() != o.getTupleSize(): return False retur...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __eq__(self, *args):\r\n pass", "def __eq__(self, *args):\r\n pass", "def __eq__(self, *args):\r\n pass", "def __eq__(self, *args):\r\n pass", "def __eq__(self, *args):\r\n pass", "def __eq__(self, *args):\r\n pass", "def __eq__(self, *args):\r\n pas...
[ "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.81492925", "0.80947864", "0.80947864", "0.80947864", "0.80947864", "0.80947864", "0.80947864", "0.80947864", "0.80947864", "0.80947864"...
0.0
-1
Return the note value for value1 minus value2. There are no exceptions for producing negative values, which can be useful for taking differences.
def subtract(value1, value2): return 1 / (1.0 / value1 - 1.0 / value2)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def subtraction(self, first_value, second_value):\n return first_value - second_value", "def diff(self, x1, x2):\n return x2 - x1", "def subtract(first, second):\n return first - second", "def difference(num1, num2):\n\n # Return the calculated value\n return abs(num1 - num2)", "def ...
[ "0.7447529", "0.66436636", "0.66115594", "0.6582123", "0.64716774", "0.64410996", "0.6402103", "0.63906467", "0.6387559", "0.6344708", "0.63281155", "0.6301104", "0.63009715", "0.6282708", "0.62618786", "0.62618786", "0.6253684", "0.6253684", "0.6250198", "0.62224627", "0.621...
0.75106716
0
Gets batch at position `index`. Arguments
def __getitem__(self, index): raise NotImplementedError
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __getitem__(self, index):\n # get the indexs of each batch\n batch_indexs = self.indexes[index*self.batch_size:(index+1)*self.batch_size]\n # using batch_indexs to get path of current batch\n batch_path = [self.X_path[k] for k in batch_indexs]\n # get batch data\n batc...
[ "0.77815783", "0.7501798", "0.7491086", "0.7487417", "0.7453526", "0.74027854", "0.7374272", "0.7374272", "0.73643535", "0.73643535", "0.733775", "0.7313693", "0.72521627", "0.71925616", "0.71191174", "0.71149236", "0.71149236", "0.70405775", "0.69668067", "0.674754", "0.6693...
0.0
-1
Set the business identifier.
def identifier(self, value: str): if Business.validate_identifier(value): self._identifier = value else: raise BusinessException('invalid-identifier-format', 406)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def business_id(self, business_id):\n\n self._business_id = business_id", "def business_phone(self, business_phone):\n\n self._business_phone = business_phone", "def business_phone_number(self, business_phone_number):\n\n self._business_phone_number = business_phone_number", "def bus_ob_...
[ "0.82185113", "0.6863438", "0.67412084", "0.66765165", "0.66765165", "0.66457736", "0.6540936", "0.63930273", "0.6316089", "0.6245376", "0.61600924", "0.61535364", "0.60639226", "0.5928157", "0.59223795", "0.5885838", "0.58488697", "0.5762276", "0.5746218", "0.57386255", "0.5...
0.60359097
13
Retrieve the next anniversary date for which an AR filing is due.
def next_anniversary(self): last_anniversary = self.founding_date if self.last_ar_date: last_anniversary = self.last_ar_date return last_anniversary + datedelta.datedelta(years=1)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_next_day(self):\n pass", "def next_release_date(date):\n df = get_release_dates()\n df = df[df['ReleaseDate'] > date]\n return df['ReleaseDate'].iloc[0]", "def next(self):\n return self.from_date(self.date_b)", "def get_upcoming(self):\n try:\n race = next(\n ...
[ "0.6712821", "0.64788795", "0.6261124", "0.613204", "0.6068264", "0.60125107", "0.60042846", "0.60042846", "0.5991352", "0.5991352", "0.5988149", "0.5853404", "0.58238065", "0.58052295", "0.5805032", "0.5781143", "0.5752652", "0.57317793", "0.5704329", "0.56928706", "0.568524...
0.7412065
0
Return the mailing address.
def mailing_address(self): registered_office = db.session.query(Office).filter(Office.business_id == self.id).\ filter(Office.office_type == 'registeredOffice').one_or_none() if registered_office: return registered_office.addresses.filter(Address.address_type == 'mailing') ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def email_address(self) -> str:\n return self._email_address", "def get_email(self):\n return self.reference[REF_EMAIL_ADDRESS][REF_VALUE]", "def generate_email_address(self):\n return \"%s.%s@%s\" % (uuid.uuid4(), self.mailbox, \"mailosaur.io\")", "def mailing_address(self):\n if...
[ "0.75741124", "0.7503663", "0.7410263", "0.73760414", "0.7364919", "0.73581123", "0.72250074", "0.7199065", "0.71284175", "0.71284175", "0.7118047", "0.7014694", "0.68627334", "0.68540025", "0.6832236", "0.6832236", "0.6832236", "0.68315107", "0.6799576", "0.6799576", "0.6799...
0.6850261
14
Return the delivery address.
def delivery_address(self): registered_office = db.session.query(Office).filter(Office.business_id == self.id).\ filter(Office.office_type == 'registeredOffice').one_or_none() if registered_office: return registered_office.addresses.filter(Address.address_type == 'delivery') ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def delivery_email(self):\n return self._delivery_email", "def shipping_address(self) -> 'outputs.ShippingAddressResponse':\n return pulumi.get(self, \"shipping_address\")", "def shipping_address(self) -> 'outputs.ShippingAddressResponse':\n return pulumi.get(self, \"shipping_address\")", ...
[ "0.74156535", "0.72566354", "0.72566354", "0.72566354", "0.72422594", "0.6928906", "0.6904006", "0.6904006", "0.6777604", "0.67241406", "0.6719341", "0.6702189", "0.6698054", "0.66799706", "0.6605211", "0.6546907", "0.6546907", "0.65107256", "0.65107256", "0.65107256", "0.651...
0.7560972
0
Show the cluster in 2D image, use whatever dim_reduce_fn provided for dimension reduction
def _show_clusters_in_2D_whatever(data: np.ndarray, clusters: np.ndarray, dim_reduce_fn, num_clusters: int, title: str, block: bool, **kwargs): assert len(data.shape) == 2 num_samples, num_features = data.shape if num_features < 2: print("num_features should be at ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def show_clusters_in_2D_pca(data: np.ndarray, clusters: np.ndarray, num_clusters: int = 10,\n title: str = \"\", block: bool = True):\n try:\n fig, ax = _show_clusters_in_2D_whatever(data, clusters, PCA, num_clusters, title, block)\n except:\n raise\n\n return fig,...
[ "0.6484613", "0.6469742", "0.6398015", "0.628059", "0.6276145", "0.6186685", "0.6117444", "0.6112742", "0.60588443", "0.6039611", "0.6010218", "0.5992633", "0.5965117", "0.5928539", "0.5914676", "0.5913095", "0.58893025", "0.58834386", "0.5875173", "0.58668375", "0.58628815",...
0.75691134
0
Get a list of (key, value) pairs representing all the tags on this document.
def get_document_tags(self, docid): return [(key, json.loads(value)) for key, value in self.sql_session.query(Feature) .filter(Feature.document == docid) .values(Feature.key, Feature.value)]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_tags(self) -> Set[Text]:\r\n return {tag for tag in self.tags}", "def collect_tags(self):\n tags = []\n for document in self.documents:\n for tag_token in document.tags:\n tags.append(tag_token)\n return tags", "def list(self):\n return self....
[ "0.7840789", "0.781512", "0.77442646", "0.7724683", "0.7681494", "0.76672333", "0.76367587", "0.76367587", "0.76367587", "0.76367587", "0.76367587", "0.76367587", "0.76367587", "0.76367587", "0.7582436", "0.7581504", "0.7575502", "0.7513426", "0.75106466", "0.75066066", "0.75...
0.71501315
63
Get a list of all (key, value) pairs that define tags on this dataset.
def all_tags(self): tags = set() query = self.sql_session.query(Feature).all() for tag in query: tags.add((tag.key, json.loads(tag.value))) return tags
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _tags(self):\n retval = []\n for of in self.tagnames:\n retval.append([of, self.get_datatype(of), self.get(of)])\n return retval", "def tags(self):\n return tuple([x.strip() for x in self._dict.get('tags').split(',')])", "def tags_dict(self):\n return ({'name': 'tag', 'a...
[ "0.7621681", "0.7486133", "0.7429748", "0.7426325", "0.7426325", "0.7394023", "0.7381528", "0.7381528", "0.7381528", "0.7381528", "0.72575873", "0.7238815", "0.72214174", "0.721224", "0.72098017", "0.7185993", "0.7184216", "0.71597636", "0.71597636", "0.71597636", "0.71597636...
0.753002
1
Attach a lot of summaries to a Tensor (for TensorBoard visualization).
def variable_summaries(var, name=None): with tf.name_scope("summaries"): with tf.name_scope(name): mean = tf.reduce_mean(var) tf.summary.scalar("mean", mean) with tf.name_scope("stddev"): stddev = tf.sqrt(tf.reduce_mean(tf.square(var - mean))) ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def build_summary(self):\n for k, v in self.metrics.items():\n tf.summary.scalar(k, v)\n \n self.summary_op = tf.summary.merge_all()", "def build_summaries(self):\n\n # Loss summary.\n tf.summary.scalar('loss', self.loss)\n\n merged = tf.summary.merge_all()\n self.summary_op = merged\n ...
[ "0.7071791", "0.6970259", "0.6970259", "0.6800256", "0.67872906", "0.67407334", "0.66669947", "0.66576326", "0.66193783", "0.66085786", "0.6595776", "0.65836215", "0.6581151", "0.655297", "0.6500364", "0.6459978", "0.64145213", "0.6294558", "0.62718755", "0.62713677", "0.6265...
0.0
-1
Return the number of lines currently stored.
def len(self): return self.__len__()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_linecount(self):\n self._update_linetab(len(self.input))\n lcount = len(self.__linepos)\n return lcount - (self.input.endswith('\\n'))", "def n_lines(self):\n try: \n return self._n_lines\n except AttributeError:\n self._n_lines = len(self.lines())...
[ "0.7744905", "0.7716623", "0.77034104", "0.7584345", "0.7571357", "0.7294285", "0.7235321", "0.7154316", "0.7121671", "0.70978796", "0.7049138", "0.69943905", "0.6980415", "0.695", "0.6944435", "0.6941798", "0.6918959", "0.6889288", "0.6882911", "0.683706", "0.6835687", "0....
0.0
-1
Return lines 'n' through to 'm' as a list. Return a set of lines starting from line index 'n' up to but not including line index 'm', as a list.
def getlines(self, n, m): return self.__contents[n:m]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def slice(n, m):\n chunks = []\n for piece in islice(n, m):\n chunks.append(piece)\n return chunks", "def islice(n, m):\n npiece = int(math.ceil(1.0*n/m))\n for i in range(npiece):\n if (i+1)*m > n:\n yield i, i*m, n\n else:\n yield i, i*m, (i+1)*m", "d...
[ "0.67716974", "0.6224634", "0.5853799", "0.5835376", "0.5824087", "0.5730224", "0.5648795", "0.5611413", "0.5570121", "0.55668485", "0.5544765", "0.5440498", "0.5436642", "0.54233885", "0.541674", "0.5413343", "0.54080105", "0.54019946", "0.5400344", "0.53933394", "0.53759825...
0.7621629
0
Return lines 'n' through to 'm' as a string. Return the specified lines from the buffer concatenated into a single string with line ends terminated by a newline character.
def contents(self, n, m): str = "" subset = self.getlines(n, m) for line in subset: str = str + line + "\n" return str.rstrip("\n")
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def getlines(self, n, m):\n return self.__contents[n:m]", "def line(n, str):\n\n return_value = ''\n for _ in range(n):\n return_value += str\n return return_value", "def coalesce_lines(lines, n):\n\n ret = [ ]\n\n for line in lines:\n if (len(ret) > 0) and (len(...
[ "0.69112617", "0.61346996", "0.57810104", "0.54826766", "0.547621", "0.54677206", "0.53977156", "0.5341624", "0.5321045", "0.522847", "0.51702565", "0.51668864", "0.50412095", "0.5013615", "0.5012478", "0.4983798", "0.498349", "0.49503186", "0.49287623", "0.49239844", "0.4903...
0.7198326
0
Return entire buffer contents as a string. All lines in the buffer will be concatenated into a single string with line ends terminated by a newline character.
def all(self): str = "" for line in self.__contents: str = str + line + "\n" return str.rstrip("\n")
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def buffer_string(self):\n return \"\\n\".join(self.buf) + \"\\n\"", "def readline(self) -> bytes:\r\n if not len(self.buffer):\r\n return b\"\"\r\n return self.buffer.pop(0)", "def read(self): \n s = \"\"\n \n # Read serial into buffer and then pop o...
[ "0.8359845", "0.65811425", "0.61754847", "0.61234534", "0.60652316", "0.5985307", "0.597845", "0.5951997", "0.5897178", "0.58949333", "0.58383757", "0.57829076", "0.57718486", "0.57434195", "0.57319045", "0.5720836", "0.5712709", "0.57027024", "0.56890196", "0.56695783", "0.5...
0.59816027
6
Set the start line of the most recent fragment. The most recent fragment is the last fragment object in the list of fragments for this logfile. 'line_no' is the current line number in the source file. If the fragment has an 'nlines' attribute then this is taken to be the offset from the current line back to the start o...
def set_fragment_start(self, line_no): fragment = self.__fragments[-1] fragment.set_attribute("source_file", self.__filename) if fragment.has_attribute("nlines"): # Calculate the start of the fragment from the # current position offset = fragment.nlines ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def set_fragment_end(self, line_no):\n if not self.__fragments:\n # We're in a situation where there was no\n # first fragment\n # Let's make one now\n self.newfragment()\n fragment = self.__fragments[-1]\n if fragment.get_endline() > -1:\n ...
[ "0.7719114", "0.7470164", "0.6964227", "0.68452215", "0.660155", "0.6232456", "0.6128378", "0.60555327", "0.6030448", "0.6003474", "0.5895308", "0.58591986", "0.5841012", "0.58401483", "0.58177835", "0.5806955", "0.57940376", "0.57373744", "0.56910324", "0.5682642", "0.562250...
0.86531585
0
Get the end line of the fragment in the source document.
def get_endline(self): return self.get_attribute("endline")
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_line_end(self):\n return self._line_end", "def end(self):\n return self.__end_line", "def getEnd(self):\n return _libsbml.LineSegment_getEnd(self)", "def _get_end(self):\n return self._end", "def get_end(self):\n return self._end", "def _endline(line):\n retu...
[ "0.7682052", "0.73179024", "0.7276879", "0.67844164", "0.66894656", "0.66873777", "0.66470546", "0.66333526", "0.65602964", "0.65187526", "0.64627564", "0.6461266", "0.6386545", "0.6379997", "0.63460267", "0.6297336", "0.6279818", "0.6254276", "0.6253468", "0.6219032", "0.606...
0.7623206
1
Return the 'raw' table text taken from the logfile. This returns any original 'raw' text of the table that was used to populate the table object. If the table object wasn't populated from a text fragment then this will return an empty string. The 'loggraph' and 'jloggraph' methods are recommended over the 'rawtable' me...
def rawtable(self): return self.__rawtable
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _extract_raw_table(self, expr):\n str_start = \"<table\"\n str_end = \"/table>\"\n\n ind_start = expr.find(str_start)\n assert ind_start >= 0\n\n ind_end = expr.find(str_end)\n assert ind_end >= 0\n\n return expr[ind_start: ind_end + len(str_end)]", "def get_s...
[ "0.58754724", "0.55608314", "0.5558947", "0.5519892", "0.55107796", "0.5324703", "0.5282555", "0.5257986", "0.5214659", "0.51848185", "0.5166116", "0.5142387", "0.5128453", "0.510642", "0.50548655", "0.5031862", "0.50179136", "0.50171846", "0.4995371", "0.49797314", "0.492628...
0.6390309
0
Return the table graph type. See the 'settype' method for the possible values and their associated meanings for the table graph type.
def type(self): return self.__type
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _get_tabletype(cls) -> str:\n raise NotImplementedError", "def get_type(self) -> str:\n return self.row_dict['type']", "def get_type(self) -> str:\n return Tables.ESL.name", "def celltype(self) -> str:\n\n hcell = self._get_hcell2()\n return hcell[\"celltype\"]", "def...
[ "0.6988938", "0.68203956", "0.6666259", "0.63268405", "0.6299978", "0.6250772", "0.62453824", "0.6177533", "0.61744297", "0.6173327", "0.61688596", "0.6165021", "0.6165021", "0.6156729", "0.614962", "0.61374724", "0.61238676", "0.6113671", "0.60981536", "0.60965216", "0.60959...
0.0
-1
Return the number of complete rows in the table. Returns the length of the shortest column of data stored in the table.
def nrows(self): if self.ncolumns() == 0: return 0 nrows = self.table_column(0).nrows() for i in range(1, self.ncolumns()): nrows = min(self.table_column(i).nrows(), nrows) return nrows
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_num_columns(table):\n\n\treturn max((len(row) for row in table))", "def get_size(self):\n return len(self.table)", "def __len__(self) -> int:\n return len(self._table)", "def __len__(self) -> int:\n return len(self.table)", "def width(self):\n if not self._rows:\n ...
[ "0.77543604", "0.76834154", "0.7441514", "0.7420827", "0.7388482", "0.7339574", "0.71748793", "0.7085411", "0.7058776", "0.70582944", "0.697618", "0.6973408", "0.6973408", "0.69654304", "0.69581044", "0.6929921", "0.69274026", "0.6922489", "0.6913085", "0.69083977", "0.689897...
0.7264148
6
Return the 'raw' data from the table body. This method returns the 'raw' table body text as supplied originally via the 'setdata' method. Of itself this data is probably not very useful.
def data(self): return self.__data
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def rawtable(self):\n return self.__rawtable", "def get_table_data(self):\n return self.table_data", "def raw_table_data(*args, **kwargs):\n # pylint: disable=unused-argument\n return {\n \"columns\": [\n {\"title\": \"id\"},\n {\"title\": \"name\"},\n ...
[ "0.68796223", "0.6572474", "0.65240335", "0.6490398", "0.63842374", "0.63546395", "0.63278866", "0.63278866", "0.6317744", "0.6317744", "0.627621", "0.62314504", "0.6231356", "0.61547494", "0.6117596", "0.6073401", "0.59920025", "0.5903801", "0.58853537", "0.58781505", "0.583...
0.0
-1
Return the i'th column associated with the table. This returns the i'th table_column object in the table. Note that i counts from zero. Generally applications that want to examine the data stored in a table are better off using the 'col' method of the table class rather than the 'table_column' method. The 'col' method ...
def table_column(self, i): return self.__column_list[i]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_column(self):\n return self._column_number", "def getColumn(self):\n return _libsbml.SBase_getColumn(self)", "def column(self) -> int:\n return self._column", "def column(self):\n return self[\"column\"]", "def find_col(table, col):\n return table[0].index(col)", "d...
[ "0.72881776", "0.725009", "0.71717143", "0.71515965", "0.71171147", "0.7107709", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", "0.6944993", ...
0.8410045
0
Return the number of graphs defined in the table. This method returns the number of 'table_graph' objects associated with the table.
def ngraphs(self): return len(self.__graph_list)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def graph_count(self) -> int:\n return int(self.graph_tuple_stats.graph_count)", "def countEdges(self):\n n = 0\n for (hub, table) in self.totsupport.iteritems():\n n += len(table)\n return n", "def num_of_edge(self):\n try:\n return self.edges\n exce...
[ "0.7490503", "0.71354496", "0.68978655", "0.68912643", "0.6888261", "0.6863996", "0.6855631", "0.68390226", "0.68390226", "0.68260455", "0.68052197", "0.67812365", "0.6747441", "0.67241776", "0.6713882", "0.6701291", "0.66969246", "0.6684455", "0.6618828", "0.65931845", "0.65...
0.7578547
0
Create a new table_graph object. The 'title' argument is a string containing the title for the graph. 'scaling' is a string describing how the graph should be displayed within the (x|j)loggraph program. 'column_list' is a list of integers corresponding to the columns in the table that holds the graph. The first column ...
def __init__(self, title="", scaling="", column_list=None): if column_list is None: column_list = [] self.__title = title self.__column_list = column_list self.__scaling = scaling if self.__title: self.__nonzero = True else: self.__non...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def definegraph(self, title, columns, scaling=\"\"):\n # Check that there are at least two columns\n if len(columns) < 2:\n raise ValueError(\"Graph definition needs at least two columns\")\n # Build the graph description i.e. list of comma-separated\n # column numbers (this ...
[ "0.7689638", "0.6327908", "0.6204365", "0.6084483", "0.60020566", "0.58996344", "0.5865012", "0.57811326", "0.574204", "0.57022965", "0.5649352", "0.5639205", "0.562492", "0.56165814", "0.55693924", "0.5556476", "0.5550503", "0.5527653", "0.5523539", "0.5496096", "0.54621035"...
0.70459396
1
Initialise the table_column object.
def __init__(self, title=""): self.__title = title self.__data = [] if self.__title: self.__nonzero = True else: self.__nonzero = False
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _init_table(self, table: \"Table\"):\n if not self.columns:\n self.columns = table.columns\n self._data = table.data", "def __init__(self, table):\r\n self.table = table\r\n KaoTableColumn.__init__(self)", "def __init__(self, *args):\n _table.Table_swiginit(sel...
[ "0.76160246", "0.6843938", "0.6769626", "0.66117823", "0.6513", "0.6427167", "0.6372307", "0.63681704", "0.63521", "0.62856585", "0.62796426", "0.6276626", "0.6187677", "0.61768895", "0.615778", "0.6148508", "0.61469716", "0.6136409", "0.6106704", "0.610345", "0.6079561", "...
0.0
-1
Return the list of data values in the column.
def data(self): return self.__data
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_data_value(self)->list:\n return self.__data_value", "def list_data(self, as_strings=False):\n if self.df is None:\n return [] \n if as_strings:\n return [str(col) for col in self.df.columns]\n else:\n return list(self.df.columns.values)...
[ "0.77621824", "0.75108343", "0.73730034", "0.7306862", "0.72316456", "0.7151132", "0.71071196", "0.7009832", "0.69682443", "0.6956054", "0.69481695", "0.6897997", "0.6847924", "0.6839055", "0.683376", "0.6833056", "0.6809157", "0.67972124", "0.67474854", "0.6731912", "0.66975...
0.0
-1
Returns a compiled regular expression from the pattern. This method returns a compiled regular expression associated with 'name', based on the supplied 'pattern'. If the name already has a compiled expression then that is returned, otherwise the compile method compiles and stores it before returning it.
def compile(self, name, pattern): try: return self.get_pattern(name) except KeyError: return self.store_pattern(name, re.compile(pattern))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_pattern(self, name):\n return self._pattern_reg[name]", "def store_pattern(self, name, cpattern):\n # Store the compiled regular expression in \"pattern\"\n # with the key \"name\"\n if not self.has_pattern(name):\n self.__patterns[name] = cpattern\n retu...
[ "0.7053393", "0.69807243", "0.68922836", "0.680196", "0.65995646", "0.6445656", "0.637927", "0.6272458", "0.62703013", "0.6254384", "0.6248992", "0.6191969", "0.6138184", "0.60868573", "0.6076194", "0.60364896", "0.592131", "0.5911789", "0.57946867", "0.5789343", "0.5768408",...
0.896322
0
Test if text matches a 'phaserstyle' CCP4 program termination. If the match fails then return False; if it succeeds then
def isccp4termination_phaser(self, text): # This style of banner looks like: # 12345678012345678012 # -------------------- # EXIT STATUS: SUCCESS # -------------------- # # CPU Time: 0 days 0 hrs 1 mins 34.43 secs (94.43 secs) # Finished: Wed May 17 09:29:...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def isValid(text):\n return bool(re.search(r'\\b((kill|stop) the (alarm|clock|music))\\b', text, re.IGNORECASE))", "def isValid(text):\n return bool(re.search(r'\\b(start|stop) (look|watch|guard)ing\\b', text, re.IGNORECASE))", "def isValid(text):\n return bool(re.search(r\"\\b((close|activate)\\ (che...
[ "0.68806815", "0.6431269", "0.62761736", "0.62584203", "0.6175639", "0.6046156", "0.5953662", "0.58471936", "0.57547706", "0.5619328", "0.5606648", "0.55991066", "0.559731", "0.55803996", "0.5565938", "0.5543286", "0.55386716", "0.5534791", "0.551588", "0.54312927", "0.540606...
0.66751474
1
Test if text matches a CCP4i tail line.
def isccp4itail(self, text): # # CCP4i tail lines look like: # #CCP4I TERMINATION STATUS 1 # #CCP4I TERMINATION TIME 25 Oct 2005 15:19:30 # #CCP4I TERMINATION OUTPUT_FILES /home/pjx/PROJECTS/myProject/... # #CCP4I MESSAGE Task completed successfully # ta...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _is_end(self, line):\n if re.match(\"\\s+submit|complete|issued|latency\\s+\\:\\s+.*\", line):\n return True", "def timestamp_line(content):\n return re.match(r\"((\\d\\d:){2}\\d\\d),(\\d{3}) --> ((\\d\\d:){2}\\d\\d),(\\d{3})\", content) is not None", "def atTail(self):\n return...
[ "0.6165118", "0.6059435", "0.584028", "0.5717279", "0.5696224", "0.5647701", "0.5600821", "0.558109", "0.5574541", "0.55356145", "0.5461781", "0.5414007", "0.54010665", "0.53995013", "0.5394877", "0.5394877", "0.5393739", "0.53821474", "0.5381525", "0.53373706", "0.53371525",...
0.74067825
0
Retrieve a block of text from a file. Given the name of a file 'filen' and a pair of start and end line numbers, extract and return the text from the file. This uses the linecache module beware of problems with consuming too much memory if the cache isn't cleared.
def retrieve(filen, start, end): text = "" # Check for consistency and validity of lines if start < 0 and end < 0 or end < start: return "" # Fetch from a file if possible if os.path.isfile(filen): try: for i in range(start, end + 1): text = text + str(li...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def textblock(file, start, stop, compression=None):\n if isinstance(file, (str, unicode)):\n myopen = opens.get(compression, open)\n f = myopen(file, 'rb')\n try:\n result = textblock(f, start, stop)\n finally:\n f.close()\n return result\n if start:\n...
[ "0.66028094", "0.61330855", "0.6021374", "0.6013926", "0.58157", "0.57478464", "0.5697128", "0.5690969", "0.56610155", "0.56597036", "0.5638598", "0.56333935", "0.56316376", "0.5624669", "0.55683804", "0.54887336", "0.54860926", "0.5481318", "0.54469955", "0.54426193", "0.543...
0.7582829
0
Get the context job id.
def identifier(self): return self._identifier
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def job_id(self) -> pulumi.Output[str]:\n return pulumi.get(self, \"job_id\")", "def job_id(self):\n return self._job_id", "def job_id(self) -> JobId:\r\n return self._job_id", "def job_id(self):\n return self._properties.get(\"jobReference\", {}).get(\"jobId\")", "def _get_job_...
[ "0.83027655", "0.82377154", "0.81556493", "0.8152497", "0.79086715", "0.79013383", "0.7836271", "0.77879333", "0.77255225", "0.7648038", "0.7558042", "0.7460855", "0.743235", "0.7370359", "0.73652166", "0.71326286", "0.67862326", "0.6784332", "0.67703295", "0.67596656", "0.67...
0.0
-1
Get the workspace path.
def workspace_path(self): return self._path_temp
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def workspace(self) -> str:\n return self._workspace", "def workspace(self):\n return self.rpc.call(MsfRpcMethod.DbCurrentWorkspace)['workspace']", "def get_workspace(self):\n wid = self._config[\"workspace\"]\n return sim_consts.workspace_origin[wid], sim_consts.workspace_size[wid]...
[ "0.808841", "0.73892677", "0.7196388", "0.71127325", "0.7047736", "0.7035057", "0.6977684", "0.6977684", "0.6975696", "0.6975696", "0.6913617", "0.68990153", "0.6889027", "0.6880461", "0.6875449", "0.6873213", "0.686939", "0.6846639", "0.6831748", "0.68179715", "0.677618", ...
0.87626225
0
Set the StatusSucceeded stored response.
def set_succeeded(self, outputs): self.logger.info("status: SUCCEEDED") self._callback('on_succeeded', outputs) return self.update_response(self.encoder.encode_response(outputs))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def success(self):\n self.succeeded = True", "def succeeded(self, succeeded):\n\n self._succeeded = succeeded", "def success(self, success):\n self._success = success", "def has_success(self, value: bool):\n self._has_success = value", "def handle_set_status_complete_success(sel...
[ "0.72555155", "0.72406644", "0.68162996", "0.6451494", "0.6386816", "0.6230903", "0.62161815", "0.61402065", "0.61326414", "0.6007828", "0.5980256", "0.5966839", "0.59579724", "0.59549826", "0.5949553", "0.59176713", "0.58903384", "0.5843035", "0.5817118", "0.57979983", "0.57...
0.7669811
0
Returns the mood data for the self object.
def get_mood(self): data = pygn.search(clientID='10189056-547D2643844BF1E2B9E85BD85773AEFE', userID='27678235334765580-1FB57EBF64483B1937D128ACEB314A68', artist=self.artist, track=self.name) return data['mood']
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_mood(self):\n return self.mood", "def to_mood(self):\n p, a, d = self._to_pad()\n mood = Mood(p*self.amount, a*self.amount, d*self.amount)\n return mood", "def getFood(self):\n return self.data.food", "def get_data(self):\n return self.data", "def get_data(...
[ "0.707828", "0.65597147", "0.600287", "0.5847662", "0.5847662", "0.5847662", "0.5824011", "0.58185995", "0.5816317", "0.58157253", "0.5793315", "0.5785683", "0.57529503", "0.57529503", "0.57529503", "0.57529503", "0.5699327", "0.56794226", "0.56726956", "0.56711876", "0.56711...
0.6494342
2
Returns whether graph tuple has data flow columns.
def has_data_flow(self) -> bool: return self.data_flow_steps is not None
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def has_data_flow(self) -> bool:\n return self.graph_count and not self.data_flow_null_count", "def are_there_available_columns_to_play(self):\n available_columns = self.get_available_columns()\n return self._state.n_neutral_markers != 3 and len(available_columns) > 0", "def has_group_cols(sel...
[ "0.73087084", "0.62618893", "0.62294143", "0.60616344", "0.5883864", "0.58398294", "0.5827965", "0.5804638", "0.58013505", "0.579512", "0.5755214", "0.57446986", "0.57126534", "0.5698431", "0.5695845", "0.5677411", "0.5674231", "0.5668995", "0.56561", "0.5649514", "0.5647821"...
0.6793305
1
The number of nonempty graphs in the database.
def graph_count(self) -> int: return int(self.graph_tuple_stats.graph_count)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def ngraphs(self):\n return len(self.__graph_list)", "def __len__(self) -> int:\n return len(self.graphs)", "def __len__(self):\n return len(self._graphs)", "def num_of_subgraphs(self):\n \n G = self.to_undirected_graph()\n \n count = G.num_subgraph()\n ...
[ "0.79743457", "0.7504434", "0.74953914", "0.7198793", "0.7186508", "0.7116534", "0.70988756", "0.7008549", "0.6985727", "0.69620484", "0.6946738", "0.69251335", "0.6913998", "0.6853583", "0.6814957", "0.6808008", "0.67881924", "0.6778874", "0.67762065", "0.67637783", "0.67608...
0.73212576
3
The number of distinct intermediate representations that the nonempty graphs are constructed from.
def ir_count(self) -> int: return int(self.graph_tuple_stats.ir_count or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def num_of_subgraphs(self):\n \n G = self.to_undirected_graph()\n \n count = G.num_subgraph()\n \n print('The number of disconnected components in the graph is ', count)", "def ngraphs(self):\n return len(self.__graph_list)", "def size(self):\n return (le...
[ "0.69580394", "0.6901225", "0.68328345", "0.6654836", "0.6581869", "0.65681267", "0.6553942", "0.65491015", "0.64167225", "0.6414495", "0.6406426", "0.64015645", "0.6379493", "0.63785857", "0.6376907", "0.6314292", "0.631428", "0.628712", "0.6264335", "0.6260748", "0.6252857"...
0.0
-1
The total edge count in nonempty graphs.
def edge_count(self) -> int: return int(self.graph_tuple_stats.edge_count or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _number_of_edges(self):\n if self._edges is None:\n return 0\n return len(self._edges)", "def num_edges(self):\n return sum(1 for _ in self.iteredges())", "def edge_count(self):\r\n return int(sum(self.degree(node) for node in range(self.size))/2)", "def return_num_...
[ "0.8249911", "0.8182177", "0.8074126", "0.8054863", "0.8015126", "0.7966927", "0.79349965", "0.79123414", "0.7898535", "0.789485", "0.7856146", "0.78183407", "0.7708368", "0.76901406", "0.7683947", "0.76611614", "0.76355785", "0.7598577", "0.75306374", "0.75204", "0.7489845",...
0.8167904
2
The total control edge count in nonempty graphs.
def control_edge_count(self) -> int: return int(self.graph_tuple_stats.control_edge_count or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _number_of_edges(self):\n if self._edges is None:\n return 0\n return len(self._edges)", "def num_edges(self):\n return sum(1 for _ in self.iteredges())", "def edge_count(self):\r\n return int(sum(self.degree(node) for node in range(self.size))/2)", "def edgecount(s...
[ "0.7671002", "0.7583738", "0.7552115", "0.7543077", "0.7488707", "0.747598", "0.74449474", "0.7384125", "0.7357291", "0.73411644", "0.7281453", "0.72562706", "0.72472435", "0.7186039", "0.7162985", "0.7141361", "0.7127213", "0.7121711", "0.70692843", "0.70536083", "0.7053473"...
0.83895445
0
The total data edge count in nonempty graphs.
def data_edge_count(self) -> int: return int(self.graph_tuple_stats.data_edge_count or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _number_of_edges(self):\n if self._edges is None:\n return 0\n return len(self._edges)", "def edge_count(self) -> int:\n return int(self.graph_tuple_stats.edge_count or 0)", "def countEdges(self):\n s1 = self.DBcurs.execute(\"SELECT count(*) FROM edges\")\n data = ...
[ "0.7800657", "0.7794975", "0.7633602", "0.76169175", "0.75449234", "0.7540726", "0.7529082", "0.74902093", "0.7473793", "0.74730647", "0.74693835", "0.74677736", "0.73781526", "0.73730785", "0.7341601", "0.7340502", "0.7338263", "0.728748", "0.7282665", "0.72618115", "0.72309...
0.8461542
0
The total call edge count in nonempty graphs.
def call_edge_count(self) -> int: return int(self.graph_tuple_stats.call_edge_count or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def edge_count(self) -> int:\n return int(self.graph_tuple_stats.edge_count or 0)", "def _number_of_edges(self):\n if self._edges is None:\n return 0\n return len(self._edges)", "def num_edges(self):\n return sum(1 for _ in self.iteredges())", "def return_num_edges(self):\n...
[ "0.80320984", "0.7823313", "0.7732773", "0.77264416", "0.7686398", "0.7670742", "0.7598584", "0.75807464", "0.75784785", "0.757243", "0.7571619", "0.7543357", "0.74949706", "0.7410557", "0.7390591", "0.73792005", "0.7375282", "0.73612076", "0.7359264", "0.73359424", "0.733292...
0.843418
0
The maximum node count in nonempty graphs.
def node_count_max(self) -> int: return int(self.graph_tuple_stats.node_count_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def max_node_count(self) -> int:\n return pulumi.get(self, \"max_node_count\")", "def max_node_count(self) -> Optional[pulumi.Input[int]]:\n return pulumi.get(self, \"max_node_count\")", "def total_max_node_count(self) -> Optional[pulumi.Input[int]]:\n return pulumi.get(self, \"total_max_n...
[ "0.8475552", "0.8424115", "0.8013726", "0.78631645", "0.77609974", "0.7732972", "0.7713095", "0.7530842", "0.7477472", "0.7457324", "0.7369719", "0.73358995", "0.7318735", "0.7259197", "0.72470963", "0.7146205", "0.7133655", "0.7104894", "0.70887065", "0.70836776", "0.7054412...
0.8854185
0
The maximum edge count in nonempty graphs.
def edge_count_max(self) -> int: return int(self.graph_tuple_stats.edge_count_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def control_edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.control_edge_count_max or 0)", "def data_edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.data_edge_count_max or 0)", "def node_count_max(self) -> int:\n return int(self.graph_tuple_stats.node_count_max or 0)"...
[ "0.8515026", "0.8204971", "0.7975469", "0.7874876", "0.78690207", "0.7757313", "0.7739741", "0.7608959", "0.7506974", "0.74741423", "0.7405962", "0.740406", "0.7397524", "0.73851115", "0.73846835", "0.73748547", "0.7369171", "0.73598754", "0.7322804", "0.7290015", "0.7259158"...
0.87999994
0
The maximum control edge count in nonempty graphs.
def control_edge_count_max(self) -> int: return int(self.graph_tuple_stats.control_edge_count_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.edge_count_max or 0)", "def control_edge_count(self) -> int:\n return int(self.graph_tuple_stats.control_edge_count or 0)", "def data_edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.data_edge_count_max or 0)", "def...
[ "0.82586896", "0.80404776", "0.78491384", "0.7651805", "0.7535716", "0.7498579", "0.7315929", "0.71309024", "0.71202606", "0.7101038", "0.7076226", "0.70214707", "0.6993303", "0.69738775", "0.69400984", "0.6939304", "0.69201416", "0.69083655", "0.6890705", "0.68877965", "0.68...
0.8865007
0
The maximum data edge count in nonempty graphs.
def data_edge_count_max(self) -> int: return int(self.graph_tuple_stats.data_edge_count_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.edge_count_max or 0)", "def control_edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.control_edge_count_max or 0)", "def graph_data_size_max(self) -> int:\n return int(self.graph_tuple_stats.graph_data_size_max or 0)"...
[ "0.85272914", "0.83137953", "0.80320483", "0.79585135", "0.7821264", "0.7688663", "0.7495857", "0.74765414", "0.7469649", "0.74584746", "0.74530524", "0.73381126", "0.7211458", "0.7193933", "0.7142157", "0.7100411", "0.7068765", "0.7018833", "0.69775563", "0.6974506", "0.6970...
0.90285796
0
The maximum call edge count in nonempty graphs.
def call_edge_count_max(self) -> int: return int(self.graph_tuple_stats.call_edge_count_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.edge_count_max or 0)", "def control_edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.control_edge_count_max or 0)", "def data_edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.data_edge_count_max or 0)"...
[ "0.87430996", "0.8617895", "0.82285845", "0.82136303", "0.78453845", "0.75599176", "0.7554201", "0.7492416", "0.74294525", "0.74255854", "0.7347798", "0.7277639", "0.7197151", "0.70962626", "0.70839167", "0.7020606", "0.7002968", "0.6987848", "0.6969511", "0.6947145", "0.6944...
0.8996734
0
The maximum edge position in nonempty graphs.
def edge_position_max(self) -> int: return int(self.graph_tuple_stats.edge_position_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.edge_count_max or 0)", "def max_positions(self):\n return None", "def control_edge_count_max(self) -> int:\n return int(self.graph_tuple_stats.control_edge_count_max or 0)", "def data_edge_count_max(self) -> int:\n return in...
[ "0.7699541", "0.75583553", "0.7406411", "0.7186106", "0.7168089", "0.7127655", "0.7062937", "0.7053888", "0.7040154", "0.7022066", "0.7021296", "0.6997701", "0.69907147", "0.69566745", "0.6948608", "0.6903866", "0.6903811", "0.68760663", "0.686353", "0.68229544", "0.68058765"...
0.89069694
0
The total size of the nonempty graph data, in bytes.
def graph_data_size(self) -> int: return int(self.graph_tuple_stats.graph_data_size or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_size(self):\n return (\n sys.getsizeof(self.children) +\n sys.getsizeof(self.parent) +\n sys.getsizeof(self.dataset_id) +\n sys.getsizeof(self.k) +\n self.filter.get_size()\n )", "def size(self):\n return self...
[ "0.76009125", "0.7567456", "0.7476673", "0.7441184", "0.7439027", "0.7308852", "0.7308852", "0.7308852", "0.7308852", "0.7308852", "0.72974616", "0.7281327", "0.7249524", "0.72390497", "0.72349966", "0.72322136", "0.72161245", "0.71898574", "0.7189039", "0.71829236", "0.71750...
0.80668235
0
The average size of the nonempty graph tuple data, in bytes.
def graph_data_size_avg(self) -> float: return float(self.graph_tuple_stats.graph_data_size_avg or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def graph_data_size(self) -> int:\n return int(self.graph_tuple_stats.graph_data_size or 0)", "def graph_data_size_min(self) -> int:\n return int(self.graph_tuple_stats.graph_data_size_min or 0)", "def size(self):\n size = 0\n size += self.data.size * sys.getsizeof(self.data)\n retur...
[ "0.8075156", "0.72535473", "0.7106614", "0.7105748", "0.69817734", "0.6926077", "0.684619", "0.6829289", "0.67583275", "0.6725425", "0.67089623", "0.6685527", "0.66743547", "0.6655449", "0.662042", "0.65756935", "0.6574154", "0.65442", "0.65364003", "0.65173227", "0.6515654",...
0.8278755
0
Return whether the graph database has data flow annotations. This is only true if all columns have data flow values.
def has_data_flow(self) -> bool: return self.graph_count and not self.data_flow_null_count
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def has_data_flow(self) -> bool:\n return self.data_flow_steps is not None", "def has_datamask(self):\n return self.datamask is not None", "def has_data(self) -> bool:\n return bool(self.data)", "def has_data(self) -> bool:\n raise NotImplementedError", "def is_dataset(self):\n r...
[ "0.73181945", "0.6149563", "0.6127147", "0.59476316", "0.58931696", "0.5845224", "0.58129483", "0.57737625", "0.57239795", "0.5696435", "0.5663467", "0.5662338", "0.5662338", "0.56621134", "0.5641391", "0.5615787", "0.56096166", "0.5592349", "0.5580872", "0.5571526", "0.55653...
0.7705465
0
The number of database rows without data flow information. If > 0, then has_data_flow is False.
def data_flow_null_count(self) -> int: return self.graph_count - int( self.graph_tuple_stats.data_flow_steps_count or 0 )
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def num_rows(self):\n return (len(self.rows))", "def num_rows(self):\n return len(self.rows)", "def data_count(self):\n return(len(self.data))", "def get_num_rows(self):\n return self._num_rows", "def no_of_columns(self): \n return len(self.columns) + (1 if self.serialize ...
[ "0.723747", "0.71625364", "0.7060408", "0.7035086", "0.70193493", "0.69925404", "0.69619495", "0.69619495", "0.6934714", "0.69228566", "0.6903881", "0.6823599", "0.673938", "0.67330176", "0.6729505", "0.6727585", "0.67250323", "0.672352", "0.67103606", "0.66660213", "0.666549...
0.68647486
11
The maximum data flow steps for nonempty graphs.
def data_flow_steps_max(self) -> Optional[int]: if self.has_data_flow: return int(self.graph_tuple_stats.data_flow_steps_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def max_steps(self) -> Optional[pulumi.Input[int]]:\n return pulumi.get(self, \"max_steps\")", "def data_flow_null_count(self) -> int:\n return self.graph_count - int(\n self.graph_tuple_stats.data_flow_steps_count or 0\n )", "def data_flow_positive_node_count_max(self) -> Optional[int]:\n ...
[ "0.7379896", "0.72180307", "0.71333224", "0.7130157", "0.7053816", "0.6724929", "0.6718832", "0.65928626", "0.65211934", "0.6508231", "0.6501113", "0.6481268", "0.6477526", "0.64273363", "0.6383378", "0.6323962", "0.63217306", "0.62544966", "0.616601", "0.6162776", "0.6140091...
0.85527885
0
The minimum data flow positive node count for nonempty graphs.
def data_flow_positive_node_count_min(self) -> Optional[int]: if self.has_data_flow: return int(self.graph_tuple_stats.data_flow_positive_node_count_min or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def min_node_count(self) -> Optional[pulumi.Input[int]]:\n return pulumi.get(self, \"min_node_count\")", "def min_node_count(self) -> int:\n return pulumi.get(self, \"min_node_count\")", "def data_flow_positive_node_count_max(self) -> Optional[int]:\n if self.has_data_flow:\n return int(s...
[ "0.8023936", "0.789185", "0.7807824", "0.7802201", "0.7475199", "0.73862046", "0.7230794", "0.7140071", "0.70534784", "0.7000579", "0.6776419", "0.67453575", "0.6729449", "0.6729449", "0.6729449", "0.6729449", "0.67278403", "0.66915274", "0.6668609", "0.6654191", "0.66488093"...
0.9030552
0
The minimum data flow average node count for nonempty graphs.
def data_flow_positive_node_count_avg(self) -> Optional[int]: if self.has_data_flow: return int(self.graph_tuple_stats.data_flow_positive_node_count_avg or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def data_flow_positive_node_count_min(self) -> Optional[int]:\n if self.has_data_flow:\n return int(self.graph_tuple_stats.data_flow_positive_node_count_min or 0)", "def total_min_node_count(self) -> Optional[pulumi.Input[int]]:\n return pulumi.get(self, \"total_min_node_count\")", "def min_node...
[ "0.78608286", "0.7457774", "0.7295959", "0.72802347", "0.7071397", "0.69049734", "0.68340874", "0.6799799", "0.66957015", "0.6537798", "0.6476839", "0.6365325", "0.631854", "0.631854", "0.6278462", "0.62412375", "0.61753774", "0.61577886", "0.612815", "0.61114705", "0.6093907...
0.8258879
0
The minimum data flow max node count for nonempty graphs.
def data_flow_positive_node_count_max(self) -> Optional[int]: if self.has_data_flow: return int(self.graph_tuple_stats.data_flow_positive_node_count_max or 0)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def node_count_max(self) -> int:\n return int(self.graph_tuple_stats.node_count_max or 0)", "def data_flow_positive_node_count_min(self) -> Optional[int]:\n if self.has_data_flow:\n return int(self.graph_tuple_stats.data_flow_positive_node_count_min or 0)", "def max_node_count(self) -> Optional[pulu...
[ "0.8033217", "0.78229624", "0.77741414", "0.75901127", "0.75760174", "0.7533512", "0.74085224", "0.73444754", "0.72644717", "0.71415263", "0.71330804", "0.7117792", "0.7116259", "0.6940493", "0.68805736", "0.68435514", "0.6733795", "0.67269415", "0.67033595", "0.669884", "0.6...
0.8371491
0
Fetch the database statics as a JSON dictionary.
def stats_json(self) -> Dict[str, Any]: return { name: function(self) for name, function in database_statistics_registry }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_staticdata(self):\n return self.get_metadata()", "def data_json(request):\n json_data = []\n for resource in Resource.objects.all():\n record = {} \n record['title'] = resource.name\n record['description'] = resource.description\n record['keyword'] = resource.csw_...
[ "0.65091604", "0.6287642", "0.60685253", "0.60585207", "0.6045111", "0.60367566", "0.6025539", "0.60035616", "0.59572256", "0.5947966", "0.59469616", "0.5919571", "0.5884199", "0.58766294", "0.58616024", "0.58563447", "0.5848007", "0.58461374", "0.5843245", "0.5835563", "0.58...
0.0
-1
plot ground truth (left) and reconstruction (right) showing b/w image data of mnist
def plot_img(): plt.subplot(121) plt.imshow(data.data.numpy()[0,].squeeze()) plt.subplot(122) plt.imshow(dec_mean.view(-1,28,28).data.numpy()[0,].squeeze()) plt.show() plt.pause(1e-6) plt.gcf().clear() sample = model.sample_z(data) plt.imshow(sample)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def plot_true_predictions(self):\n \n if self.data_generated:\n \n # Choosing a different color for each target\n n_targets = len(self.true_data['targets'])\n cmap = plt.get_cmap('gnuplot')\n colors = [cmap(i) for i in np.linspace(0, 0.9, n_targe...
[ "0.6359372", "0.63568735", "0.6351003", "0.61925846", "0.6187286", "0.61738014", "0.6107763", "0.6085257", "0.6078938", "0.6055362", "0.603561", "0.6034434", "0.6034434", "0.6008966", "0.6008966", "0.6008966", "0.60033107", "0.5982332", "0.59349245", "0.593149", "0.59275013",...
0.61624676
6
Number of negative residues in a protein sequence.
def n_neg(seq): # Convert to all upper case seq = seq.upper() # Check the valiality of sequence for aa in seq: if aa not in bioinfo_dicts.aa.keys(): raise RuntimeError(aa + ' is not a valid amino acid.') # Count E and D and return Count return seq.count('D') + seq.count('E'...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def n_neg(seq):\n\n # Convert sequence to upper case\n seq = seq.upper()\n\n # Check for a valid sequence\n for aa in seq:\n if aa not in bioinfo_dicts.aa.keys():\n raise RuntimeError(aa + ' is not a valid amino acid.')\n\n # Count E's and D's, since these are the negative residues\...
[ "0.82678354", "0.80789524", "0.71521777", "0.65276897", "0.64138657", "0.6410651", "0.6380766", "0.63229483", "0.63189644", "0.63189644", "0.6284025", "0.6230671", "0.6191797", "0.6168326", "0.58007723", "0.56923634", "0.56741333", "0.5620887", "0.55961305", "0.55678385", "0....
0.75642145
2
Gets a list of registered ResourceLoaders.
def _GetResourceLoaders(): loaders = [] # Add all paths to list if they are specified on the command line (will warn # if any are invalid). # Otherwise add members of the default list iff they exist. if FLAGS['data_search_paths'].present: for path in FLAGS.data_search_paths: loaders.append(FileReso...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def getLoaders(self):\n return self.__loaders;", "def get_resources(self):\n return []", "def list(self):\n resources = self._os_resource_manager.list()\n resource_list = []\n for resource in resources:\n resource_list.append(self._resource_class(id=resource.id,\n ...
[ "0.81416523", "0.637179", "0.6344715", "0.629529", "0.6217948", "0.61834675", "0.6145614", "0.59924227", "0.5954884", "0.59497255", "0.59497255", "0.59359246", "0.59182215", "0.59130603", "0.5862964", "0.5828555", "0.5793263", "0.57533056", "0.5741845", "0.5725582", "0.569191...
0.7558301
1
Constructor for the PatchBankAccount class
def __init__(self, account_holder_name=None, routing_number=None): # Initialize members of the class self.account_holder_name = account_holder_name self.routing_number = routing_number
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __init__(self, bank_name, account_num, balance):\n self._bank_name = bank_name\n self._account_num = account_num\n self._balance = balance", "def __init__(self, account_number: str, bank_name: str,\n starting_balance: float):\n super().__init__(account_number)\n ...
[ "0.67347664", "0.6665173", "0.65751433", "0.6356631", "0.6301538", "0.62909985", "0.62768334", "0.6247869", "0.6194805", "0.61794615", "0.61187714", "0.60189223", "0.58762217", "0.58614963", "0.5832388", "0.58311236", "0.5817464", "0.5808375", "0.5808244", "0.5781593", "0.578...
0.0
-1
Creates an instance of this model from a dictionary
def from_dictionary(cls, dictionary): if dictionary is None: return None # Extract variables from the dictionary account_holder_name = dictionary.get('accountHolderName') routing_number = dictionary.get('routingNumber') # Return an o...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def from_dictionary(cls,\n dictionary):\n if dictionary is None:\n return None\n\n # Extract variables from the dictionary\n id = dictionary.get('id')\n name = dictionary.get('name')\n mtype = dictionary.get('type')\n usage_bytes = diction...
[ "0.83181584", "0.8168118", "0.8168118", "0.8118749", "0.8089047", "0.79787344", "0.7949278", "0.79231393", "0.7898951", "0.78923255", "0.788838", "0.7882321", "0.7882212", "0.7876749", "0.78585315", "0.7836853", "0.7801407", "0.7801407", "0.7801407", "0.7801407", "0.7801407",...
0.7705121
66
sets the default value for the user's default_custom_columns
def set_default_columns(request): body = json.loads(request.body) columns = body['columns'] show_shared_buildings = body.get('show_shared_buildings') request.user.default_custom_columns = columns if show_shared_buildings is not None: request.user.show_shared_buildings = show_shared_buildings...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_default_columns(request):\n columns = request.user.default_custom_columns\n\n if columns == '{}' or type(columns) == dict:\n initial_columns = True\n columns = DEFAULT_CUSTOM_COLUMNS\n else:\n initial_columns = False\n if type(columns) == unicode:\n # postgres 9.1 st...
[ "0.71918476", "0.63976187", "0.62911725", "0.62810946", "0.61775875", "0.6020808", "0.59625727", "0.58059883", "0.56875354", "0.56598103", "0.56401706", "0.55985165", "0.5580176", "0.5558134", "0.5525293", "0.54914945", "0.54885626", "0.5485158", "0.5463281", "0.5459858", "0....
0.7769795
0
Creates a new empty dataset (ImportRecord).
def create_dataset(request): body = json.loads(request.body) try: org = Organization.objects.get(pk=body['organization_id']) except Organization.DoesNotExist: return {"status": 'error', 'message': 'organization_id not provided'} record = ImportRecord.objects.create( ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def create_none_dataset(py_obj, h_group, name, **kwargs):\n return h_group.create_dataset(name, shape = None,dtype = 'V1',**no_compression(kwargs)),()", "def _create_data():\n tf.logging.info(\"Create records..\")\n train, val, test = util.load_data(data_dir, FLAGS[\"is_aug\"])\n tf.logging.info(\"Da...
[ "0.62038827", "0.6160961", "0.61396396", "0.60411006", "0.59956115", "0.58439934", "0.5828674", "0.58265716", "0.58131844", "0.58111525", "0.57789344", "0.5772935", "0.57699925", "0.575616", "0.5748804", "0.57160425", "0.5681925", "0.56727135", "0.56416404", "0.5640246", "0.5...
0.61703247
1
Retrieves details about an ImportFile.
def get_import_file(request): from seed.models import obj_to_dict import_file_id = request.GET.get('import_file_id', '') orgs = request.user.orgs.all() import_file = ImportFile.objects.get( pk=import_file_id ) d = ImportRecord.objects.filter( super_organization__in=orgs, pk=impor...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def import_info(self):\n return self.setup.import_info", "def import_file(self) -> pulumi.Input['FileMetadataArgs']:\n return pulumi.get(self, \"import_file\")", "def import_file(self) -> 'outputs.FileMetadataResponse':\n return pulumi.get(self, \"import_file\")", "def import_file(self) ...
[ "0.7248999", "0.6746192", "0.6590657", "0.6530779", "0.6172895", "0.596939", "0.5742963", "0.5708968", "0.56474656", "0.56010765", "0.5437616", "0.5401174", "0.54005516", "0.53999656", "0.5388597", "0.5372574", "0.5350929", "0.53432524", "0.5339969", "0.52719903", "0.52370346...
0.62912744
4
Updates the name of a dataset.
def update_dataset(request): body = json.loads(request.body) orgs = request.user.orgs.all() # check if user has access to the dataset d = ImportRecord.objects.filter( super_organization__in=orgs, pk=body['dataset']['id'] ) if not d.exists(): return { 'status': 'error'...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def switch_to_dataset(self, dataset_name: Optional[str] = None):\n self._current_dataset_name = self._validate_dataset_name(dataset_name)", "def update_dataset(self, dataset, name=None, description=None):\n uri = URITemplate(self.baseuri + '/{owner}/{id}').expand(\n owner=self.username, ...
[ "0.71942943", "0.7085657", "0.7053566", "0.69522166", "0.6884053", "0.6884053", "0.68170536", "0.6797914", "0.67543006", "0.66649425", "0.6632209", "0.66024053", "0.65867317", "0.65579575", "0.6535266", "0.6512995", "0.6488904", "0.6488904", "0.64725125", "0.63948125", "0.636...
0.0
-1
r"""VGG 11layers model (configuration "A") with batch normalization
def vgg11_bn(pretrained: bool = False, progress: bool = True, **kwargs: Any) -> VGG: return _vgg('vgg11_bn', 'A', True, pretrained, progress, **kwargs)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def vgg_16(input_shape=(224, 224, 3), output_shape=1000):\n model = Sequential()\n \n # layer 1 ~ 2 (filter: 64)\n model.add(Input(shape=input_shape))\n model.add(ZeroPadding2D((1, 1)))\n model.add(Conv2D(64, (3, 3), activation='relu'))\n model.add(ZeroPadding2D((1, 1)))\n model.add(Conv2D(...
[ "0.6401826", "0.6339081", "0.6320962", "0.6220103", "0.6205287", "0.6181516", "0.60886914", "0.6079174", "0.6036321", "0.60285294", "0.5988841", "0.5985864", "0.5980047", "0.59774154", "0.5973252", "0.59162146", "0.59033006", "0.58979875", "0.5890361", "0.587359", "0.58735275...
0.5397236
78