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 |
|---|---|---|---|---|---|---|
Returns true if both objects are equal | def __eq__(self, other):
if not isinstance(other, LibraryItemQuery):
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.80886984",
"0.80886984",
"0.8055307",
"0.7983415",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
"0.79673034",
... | 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 |
Instantiates the ResNet, ResNetV2, and ResNeXt architecture. Optionally loads weights pretrained on ImageNet. Note that the data format convention used by the model is the one specified in your Keras config at `~/.keras/keras.json`. Arguments | def ResNet(
stack_fn: t.Callable,
preact: bool,
use_bias: bool,
model_name: str = 'resnet',
include_top: bool = True,
weights: t.Optional[str] = 'imagenet',
input_tensor=None,
input_shape=None,
pooling: t.Optional[str] = None,
classes: int = 1000,
norm_use: str = "bn",
**... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def resnet101(pretrained=False, **kwargs):\n model = ResNet(Bottleneck, [3, 4, 23, 3], **kwargs)\n if pretrained and os.path.exists(model_urls['resnet101']):\n model.load_state_dict(torch.load(model_urls['resnet101']), strict=False)\n return model",
"def resnet101(pretrained=False, **kwargs):\n ... | [
"0.69096047",
"0.68670166",
"0.68670166",
"0.68670166",
"0.68670166",
"0.68613476",
"0.68278134",
"0.68020064",
"0.6675086",
"0.6675086",
"0.6645166",
"0.6632695",
"0.6591586",
"0.6505662",
"0.64567226",
"0.644973",
"0.64368486",
"0.6394446",
"0.6394446",
"0.6394446",
"0.6386... | 0.6042627 | 60 |
Saves model checkpoint for inference/resuming training. | def save(self, model, ema_model, optimizer, epoch, step, best_wer,
is_best=False):
rank = 0
if dist.is_initialized():
dist.barrier()
rank = dist.get_rank()
if rank != 0:
return
# Checkpoint already saved
if not is_best and epoch ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def save(self, checkpoint) -> None:\r\n self.model.save(checkpoint)",
"def save_checkpoint(self):\n \n if not os.path.isdir(self.path + '/checkpoint/'):\n os.makedirs(self.path + '/checkpoint/')\n\n if self.saver == None:\n with self.graph.as_default():\n ... | [
"0.86611867",
"0.853128",
"0.8434493",
"0.8327421",
"0.8298874",
"0.8220758",
"0.8167562",
"0.8125202",
"0.8002463",
"0.7880603",
"0.7863927",
"0.7862251",
"0.77958524",
"0.7781288",
"0.77672905",
"0.77648544",
"0.7761933",
"0.7737647",
"0.77307796",
"0.7728945",
"0.7710973",... | 0.7584122 | 24 |
returns the result of a query as a Pandas DataFrame | def query_into_pandas(self, query, fields=None, parameters=None, names=None):
target_url = self.build_query(query, fields=fields, parameters=parameters)
col_id = 'columns'
col_names = None
if names is None:
# If the columns of the query are specified (used for 'tab' or 'txt'... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def get_query_result_to_df(self, query):\r\n try:\r\n return pd.read_sql_query(query, self.conn)\r\n except pd.pandas.io.sql.DatabaseError:\r\n print('Execution failed. Database error')",
"def query_to_df(query):\n df = pd.DataFrame(query.all())\n df.columns = [x['name']... | [
"0.82246584",
"0.8045982",
"0.794957",
"0.7831598",
"0.78008485",
"0.7789293",
"0.77883613",
"0.77691305",
"0.77013284",
"0.7527213",
"0.74218667",
"0.7372462",
"0.7371405",
"0.73660314",
"0.7364389",
"0.73187923",
"0.7281114",
"0.72751415",
"0.7272429",
"0.72698665",
"0.7263... | 0.6967948 | 36 |
Count the number of trees (represented by ``) encountered by moving along the path (i rise, i run) through the grid starting from i = 0 (at (0,0)) to i = height 1. | def collisions(grid_map, rise, run):
period = len(grid_map[0])
return sum(row[i * run % period] == '#' for i, row in enumerate(grid_map[::rise])) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def count_trees(matrix, dx, dy):\n\n # We begin in the upper left corner\n x = 0\n y = 0\n count = 0\n\n # We continue until y > [height of matrix]\n while(y < len(matrix)):\n if matrix[y][x] == '#':\n count += 1\n\n # X is special since it needs to be wrapped around\n ... | [
"0.7320269",
"0.6723722",
"0.66408914",
"0.6615365",
"0.6610997",
"0.6488801",
"0.6461549",
"0.6435356",
"0.64268124",
"0.6394908",
"0.6377559",
"0.6353479",
"0.6338055",
"0.63283724",
"0.6285659",
"0.6242612",
"0.62239015",
"0.6220524",
"0.6211241",
"0.62066877",
"0.61436784... | 0.0 | -1 |
Calculate the GC skew of a nucleotide sequence. s = (G C) / (G + C) | def gc_skew(dna):
gcount = dna.count('G') + dna.count('g')
ccount = dna.count('C') + dna.count('c')
if gcount + ccount == 0:
return 0.0
return float(gcount - ccount) / float(gcount + ccount) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def gc_skew(sequence):\n seq = sequence.upper()\n half = len(sequence) // 2\n genome = np.frombuffer(seq.encode() + seq.encode(), dtype='uint8')\n g = np.concatenate(([0], np.array(genome == ord('G'), dtype='uint8').cumsum()))\n c = np.concatenate(([0], np.array(genome == ord('C'), dtype='uint8').cu... | [
"0.80690074",
"0.7013551",
"0.67809993",
"0.65839326",
"0.6522133",
"0.65010285",
"0.622094",
"0.606174",
"0.6030877",
"0.59896547",
"0.59696555",
"0.58017576",
"0.5746916",
"0.57268304",
"0.56970817",
"0.5681315",
"0.56662315",
"0.5590456",
"0.5585766",
"0.5554906",
"0.55335... | 0.79286885 | 1 |
Computes logpdf of the multivariate normal with diagonal covariance. | def mvn_logpdf(X, mean, covar):
return -.5 * (T.log(2 * np.pi)
+ T.log(covar)
+ T.square(X - mean) / covar).sum(axis=1) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def log_marginal_likelihood_normal_pdf(self):\n noise_variance=self.params['noise_variance']['value']\n Kxx = self.C@self._Kernel(self.X, self.X, self.params)@self.C.T + (noise_variance+self.jitter) * np.eye(self.Y.shape[0])\n try:\n mu = np.linalg.solve(Kxx, self.Y)\n (s... | [
"0.7650791",
"0.7518232",
"0.7264359",
"0.71136975",
"0.6984139",
"0.6892641",
"0.68872046",
"0.683224",
"0.68237114",
"0.680583",
"0.68040025",
"0.67758095",
"0.6757443",
"0.67296195",
"0.66828567",
"0.6651995",
"0.6623439",
"0.662114",
"0.6590771",
"0.65814644",
"0.65814644... | 0.74092114 | 2 |
Transforation matrix from rotation matrix and translation vector. | def transform_from_rot_trans(R, t):
R = R.reshape(3, 3)
t = t.reshape(3, 1)
return np.hstack([R, t]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def transformation_matrix(self):\n t = np.array([[0.0], [0.0], [0.0]])\n Rt = np.hstack([self.rotation_matrix, t])\n return np.vstack([Rt, np.array([0.0, 0.0, 0.0, 1.0])])",
"def rotation_to_transformation_matrix(R):\n R = Matrix(R)\n T = R.col_insert(3, Matrix([0., 0., 0.]))\n T = ... | [
"0.77170706",
"0.73991954",
"0.7177244",
"0.71715957",
"0.70911086",
"0.70658827",
"0.6965859",
"0.69648105",
"0.6960624",
"0.69518447",
"0.6870948",
"0.6853344",
"0.683825",
"0.68235946",
"0.6795669",
"0.67954564",
"0.6759378",
"0.67547184",
"0.6735144",
"0.672982",
"0.67256... | 0.6471603 | 49 |
Rotation about the yaxis. | def roty(t):
c = np.cos(t)
s = np.sin(t)
return np.array([[c, 0, s],
[0, 1, 0],
[-s, 0, c]]) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def rot_y_deg(self):\n # TODO describe which axis this is\n return math.degrees(self._rot_y_rad)",
"def rot_y_rad(self):\n return self._rot_y_rad",
"def rotation_center_y(self, *args, **kwargs) -> Any:\n pass",
"def rotate_y(self, angle):\n angle *= np.pi / 180\n ret... | [
"0.7540491",
"0.7354875",
"0.71038026",
"0.7064436",
"0.70362157",
"0.6987531",
"0.6895273",
"0.6895273",
"0.68482006",
"0.6803898",
"0.6716447",
"0.6663338",
"0.6629219",
"0.6615279",
"0.6581418",
"0.6576087",
"0.65545076",
"0.6506294",
"0.63934934",
"0.63920045",
"0.6386639... | 0.0 | -1 |
Return laser PWM frequency. | def pwm_freq(self):
return self._pwm_freq | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def get_PWM_frequency(user_gpio):\n return _u2i(_pigpio_command(_control, _PI_CMD_PFG, user_gpio, 0))",
"def frequency(self):\n return self.reference_clock_speed / 4096 / self.prescale_reg",
"def get_ao_manual_control_freq( channel ):\n freq = float64(0)\n CALL('GetPhysicalChanAOManualControlFreq', chan... | [
"0.7335854",
"0.71027195",
"0.68662757",
"0.6780559",
"0.66896033",
"0.6611435",
"0.6593417",
"0.6513571",
"0.6489469",
"0.64576596",
"0.6385806",
"0.63641995",
"0.6303744",
"0.62910974",
"0.62662196",
"0.62243867",
"0.6212599",
"0.61851466",
"0.61366475",
"0.6117854",
"0.611... | 0.7988617 | 0 |
One hot encoder create a binary vector for each class | def _one_hot(self, proba, y):
hm_1hot = []
for label in np.unique(y):
mask_ = y == label
proba_tmp = proba.copy()
proba_tmp[~mask_] = 0
hm_y, auto_gamma = self._adjust_gamma(proba_tmp)
if self.verbose:
print('Adjusted gamma: ',... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def one_hot_encode(x, n_classes):\n return np.eye(n_classes)[x]",
"def one_hot_encoding(labels, num_classes=10):\n num_labels = labels.shape[0]\n encoded = np.zeros((num_labels, num_classes))\n encoded[np.arange(num_labels), labels[np.arange(num_labels)]] = 1\n \n return encoded",
"def one_ho... | [
"0.8143436",
"0.8030122",
"0.79617804",
"0.7941658",
"0.7930864",
"0.79169935",
"0.7779735",
"0.7773046",
"0.77466714",
"0.77144974",
"0.76853096",
"0.7680849",
"0.7655433",
"0.76497775",
"0.76247436",
"0.7624073",
"0.76195425",
"0.76072013",
"0.75895613",
"0.75873244",
"0.75... | 0.0 | -1 |
Lookup of scored variable names > NCANDA release names. Currently, this is an OrderedDict of 60+ name mappings for each form. | def set_post_score_renames(self):
raise NotImplementedError("Must be defined by subclass!") | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def getOqiVarNames( self ):\n\n if self.oqiVarNames:\n return self.oqiVarNames.keys()\n\n n = self.adb.get( \"nOqiVars\" )\n for indx in xrange( n ):\n name = self.adb.get( \"oqiVarName\",\n ... | [
"0.6255559",
"0.6220438",
"0.61314976",
"0.607819",
"0.60768753",
"0.6036701",
"0.590597",
"0.5892851",
"0.58853024",
"0.58842444",
"0.58527017",
"0.5805194",
"0.5732727",
"0.5710976",
"0.56867075",
"0.5670059",
"0.56681657",
"0.5660925",
"0.5627093",
"0.5585306",
"0.55824614... | 0.0 | -1 |
dump a smaller dataframe to a csv file I'm hoping I can use this to frequently trigger common df's to create graphs | def dump_to_csv(self, function, path, kwargs=None):
if not kwargs:
kwargs = {}
df_to_dump = function(self.df, **kwargs)
df_to_dump.to_csv(path) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def save_df(data_frame, file_path):\r\n data_frame.to_csv(file_path)\r\n return None",
"def save(df, save_preprocessed_dataframe_path, name):\n\n df.to_csv(save_preprocessed_dataframe_path + name + '.csv', index=False)",
"def save_dataframe(dataframe, filename):\n with open(filename, \"w\", encodin... | [
"0.7246539",
"0.7148962",
"0.71020144",
"0.6894424",
"0.68878436",
"0.6860834",
"0.67863345",
"0.67561346",
"0.67239696",
"0.67191696",
"0.6716653",
"0.6669605",
"0.66385615",
"0.6630256",
"0.66276693",
"0.66190135",
"0.6590145",
"0.652181",
"0.64933467",
"0.64925706",
"0.648... | 0.6776386 | 7 |
Get all projects for logged in admin | def get(self):
authenticated_user_id = token_auth.current_user()
orgs_dto = OrganisationService.get_organisations_managed_by_user_as_dto(
authenticated_user_id
)
if len(orgs_dto.organisations) < 1:
return {
"Error": "User is not a manager of the pr... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def get_all_projects():\n return jsonify(admin.get_all_projects(current_app.scoped_session()))",
"def get_projects(self):\n res = self.conn.cursor().execute(\"SELECT * FROM projects\")\n return res.fetchall()",
"def get_projects(self):\n return conf.projects",
"def get_projects(self):... | [
"0.797345",
"0.74227715",
"0.7369151",
"0.73287845",
"0.7296896",
"0.7292046",
"0.72218716",
"0.7181348",
"0.7170395",
"0.7168788",
"0.71269417",
"0.7094623",
"0.70770717",
"0.70725584",
"0.7012113",
"0.6969786",
"0.6944723",
"0.6918118",
"0.68930155",
"0.6876794",
"0.6869063... | 0.75182176 | 1 |
Returns true if the current request should be profiles. | def should_profile():
if util.dev_server:
return _config.should_profile_development()
else:
return _config.should_profile_production() | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _should_profile(self) -> bool:\n if \"profile\" in self._allowed_plugins:\n if not self._one_shot:\n raise ValueError(\n \"Profile plugin currently only supported for one shot.\"\n )\n logger.info(\"Profile plugin is enalbed.\")\n ... | [
"0.7499451",
"0.6561928",
"0.64208734",
"0.62351674",
"0.6181953",
"0.6069531",
"0.6067243",
"0.6025871",
"0.6011438",
"0.5991452",
"0.59394586",
"0.5894198",
"0.5894198",
"0.5894198",
"0.58836645",
"0.5881188",
"0.5835812",
"0.583181",
"0.5760288",
"0.5760288",
"0.5759542",
... | 0.75143254 | 0 |
GetOutput(itkVTKPolyDataReaderMD2_Superclass self) > itkMeshD2 GetOutput(itkVTKPolyDataReaderMD2_Superclass self, unsigned int idx) > itkMeshD2 | def GetOutput(self, *args) -> "itkMeshD2 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_GetOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GetOutput(self, *args) -> \"itkMeshF2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GetOutput(self, *args)",
"def GetOutput(self, *args) -> \"itkMeshD2 *\":\n return _itkMeshSourcePython.itkMeshSourceMD2_GetOutput(self, *args)",
"def GetOutput(self, *args) -> \"... | [
"0.7565955",
"0.7410332",
"0.71460557",
"0.7063892",
"0.6963732",
"0.68876576",
"0.6821838",
"0.6802253",
"0.67477465",
"0.6672652",
"0.66189194",
"0.65806973",
"0.6547658",
"0.6496008",
"0.643548",
"0.6397435",
"0.6378913",
"0.6345608",
"0.63299525",
"0.6300177",
"0.6295156"... | 0.78256303 | 0 |
SetOutput(itkVTKPolyDataReaderMD2_Superclass self, itkMeshD2 output) | def SetOutput(self, output: 'itkMeshD2') -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_SetOutput(self, output) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SetOutput(self, output: 'itkMeshF2') -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_SetOutput(self, output)",
"def SetOutput(self, output: 'itkMeshD2') -> \"void\":\n return _itkMeshSourcePython.itkMeshSourceMD2_SetOutput(self, output)",
"def SetOutput(se... | [
"0.8727152",
"0.8169562",
"0.8163437",
"0.80422777",
"0.79821557",
"0.79446983",
"0.77838796",
"0.76476085",
"0.7569438",
"0.73907334",
"0.7362632",
"0.7336517",
"0.729145",
"0.72375774",
"0.7164393",
"0.7131282",
"0.7051931",
"0.6986523",
"0.6950808",
"0.684901",
"0.6797034"... | 0.88948655 | 0 |
GraftOutput(itkVTKPolyDataReaderMD2_Superclass self, itkDataObject output) | def GraftOutput(self, *args) -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_GraftOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GraftOutput(self, *args)",
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_GraftOutput(self, *args)",
"def GraftOutp... | [
"0.8058812",
"0.80242264",
"0.79319966",
"0.7087974",
"0.6871498",
"0.68560195",
"0.6835544",
"0.6829121",
"0.68235105",
"0.6715286",
"0.6714992",
"0.6667811",
"0.6650473",
"0.6646845",
"0.6644759",
"0.65929776",
"0.6581092",
"0.65720075",
"0.6567729",
"0.6527402",
"0.6472063... | 0.82285905 | 0 |
GraftNthOutput(itkVTKPolyDataReaderMD2_Superclass self, unsigned int idx, itkDataObject output) | def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_GraftNthOutput(self, idx, output) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GraftNthOutput(self, idx, output)",
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDa... | [
"0.9083513",
"0.8988604",
"0.89809203",
"0.8607753",
"0.84884095",
"0.84701717",
"0.84634477",
"0.8395891",
"0.83740294",
"0.8356462",
"0.83443266",
"0.8313999",
"0.83067334",
"0.82864285",
"0.8253524",
"0.82298696",
"0.8224939",
"0.8196333",
"0.8188383",
"0.8173991",
"0.8129... | 0.9152759 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMD2_Superclass | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD2_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMD2_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD2_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2_Superclass *\":\n return _itkVTKPolyDataReade... | [
"0.8899241",
"0.8786322",
"0.8767721",
"0.8725587",
"0.86551094",
"0.86299604",
"0.8397479",
"0.82488835",
"0.8189745",
"0.8110676",
"0.80485433",
"0.79118115",
"0.78998065",
"0.77046007",
"0.7584203",
"0.7443038",
"0.7396807",
"0.7390999",
"0.73892707",
"0.7366644",
"0.73486... | 0.8913259 | 0 |
New() > itkVTKPolyDataReaderMD2_Superclass Create a new object of the class itkVTKPolyDataReaderMD2_Superclass and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parame... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMD2_Superclass.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF2_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD3_Superclass.__New_orig__()\n import itkTemplate\n ... | [
"0.7497407",
"0.73626",
"0.72328216",
"0.7045713",
"0.6869497",
"0.6705791",
"0.6527835",
"0.6523734",
"0.6384727",
"0.6376666",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0.6374453",
"0... | 0.76537305 | 0 |
itkVTKPolyDataReaderMD2_Superclass_cast(itkLightObject obj) > itkVTKPolyDataReaderMD2_Superclass | def itkVTKPolyDataReaderMD2_Superclass_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD2_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMF2_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD2_Superclass *\":\n return _itkVTKPolyDataReade... | [
"0.9211901",
"0.913794",
"0.9082544",
"0.89838356",
"0.89464337",
"0.88188916",
"0.8818143",
"0.8043076",
"0.8017878",
"0.79608184",
"0.7950957",
"0.76175857",
"0.7607719",
"0.75415945",
"0.74628025",
"0.740864",
"0.7387504",
"0.7383443",
"0.73831487",
"0.73829705",
"0.737971... | 0.94209033 | 0 |
GetOutput(itkVTKPolyDataReaderMD3_Superclass self) > itkMeshD3 GetOutput(itkVTKPolyDataReaderMD3_Superclass self, unsigned int idx) > itkMeshD3 | def GetOutput(self, *args) -> "itkMeshD3 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_GetOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GetOutput(self, *args) -> \"itkMeshF3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GetOutput(self, *args)",
"def GetOutput(self, *args) -> \"itkMeshD3 *\":\n return _itkMeshSourcePython.itkMeshSourceMD3_GetOutput(self, *args)",
"def GetOutput(self, *args) -> \"... | [
"0.76762426",
"0.762746",
"0.73278326",
"0.7293862",
"0.7128329",
"0.7067144",
"0.7021345",
"0.69944984",
"0.694114",
"0.6841038",
"0.68329537",
"0.6819809",
"0.6786473",
"0.6779153",
"0.67638165",
"0.6740463",
"0.66958106",
"0.66579425",
"0.6654051",
"0.6644396",
"0.66354126... | 0.7946725 | 0 |
GraftOutput(itkVTKPolyDataReaderMD3_Superclass self, itkDataObject output) | def GraftOutput(self, *args) -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_GraftOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GraftOutput(self, *args)",
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_GraftOutput(self, *args)",
"def GraftOutp... | [
"0.80498606",
"0.7892025",
"0.777266",
"0.7295339",
"0.70474106",
"0.7015617",
"0.70087224",
"0.69933796",
"0.6944142",
"0.6938721",
"0.68792623",
"0.6863867",
"0.68367636",
"0.6817156",
"0.67629486",
"0.67363757",
"0.6728983",
"0.6715933",
"0.66776294",
"0.66363466",
"0.6626... | 0.82942784 | 0 |
GraftNthOutput(itkVTKPolyDataReaderMD3_Superclass self, unsigned int idx, itkDataObject output) | def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_GraftNthOutput(self, idx, output) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GraftNthOutput(self, idx, output)",
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDa... | [
"0.91178215",
"0.90771985",
"0.9037523",
"0.86862624",
"0.8596121",
"0.8571035",
"0.85548854",
"0.85526574",
"0.8539767",
"0.84962326",
"0.8494114",
"0.84799546",
"0.8446787",
"0.84453815",
"0.8439696",
"0.8432819",
"0.84325653",
"0.834277",
"0.82672995",
"0.82451403",
"0.821... | 0.9192758 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMD3_Superclass | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD3_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMD3_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD3_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3_Superclass *\":\n return _itkVTKPolyDataReade... | [
"0.8929814",
"0.87880975",
"0.87311035",
"0.87239134",
"0.8657016",
"0.8628953",
"0.84934133",
"0.82655674",
"0.8227053",
"0.8149703",
"0.8106049",
"0.8073036",
"0.8063019",
"0.78866744",
"0.7850091",
"0.75564724",
"0.75233525",
"0.74636626",
"0.74522823",
"0.744384",
"0.7382... | 0.8925678 | 1 |
New() > itkVTKPolyDataReaderMD3_Superclass Create a new object of the class itkVTKPolyDataReaderMD3_Superclass and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parame... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMD3_Superclass.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF3_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD2_Superclass.__New_orig__()\n import itkTemplate\n ... | [
"0.7505802",
"0.7304393",
"0.7237327",
"0.7064481",
"0.68840706",
"0.6731178",
"0.6616509",
"0.6608776",
"0.6547274",
"0.6466984",
"0.6425684",
"0.6381668",
"0.6366585",
"0.63232774",
"0.63195664",
"0.63164234",
"0.6259594",
"0.62244123",
"0.6219139",
"0.6217396",
"0.62120694... | 0.7674137 | 0 |
itkVTKPolyDataReaderMD3_Superclass_cast(itkLightObject obj) > itkVTKPolyDataReaderMD3_Superclass | def itkVTKPolyDataReaderMD3_Superclass_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD3_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMF3_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD3_Superclass *\":\n return _itkVTKPolyDataReade... | [
"0.9218319",
"0.91419506",
"0.91376877",
"0.9002616",
"0.89657426",
"0.8939724",
"0.883336",
"0.7995239",
"0.7978971",
"0.79610413",
"0.79264283",
"0.7804264",
"0.77917254",
"0.7715287",
"0.7692945",
"0.7691938",
"0.76772267",
"0.75929564",
"0.7556416",
"0.75435215",
"0.75227... | 0.9429995 | 0 |
GetOutput(itkVTKPolyDataReaderMF2_Superclass self) > itkMeshF2 GetOutput(itkVTKPolyDataReaderMF2_Superclass self, unsigned int idx) > itkMeshF2 | def GetOutput(self, *args) -> "itkMeshF2 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GetOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GetOutput(self, *args) -> \"itkMeshD2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_GetOutput(self, *args)",
"def GetOutput(self, *args) -> \"itkMeshF3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GetOutput(self, *args)",
"def Get... | [
"0.7461596",
"0.74444616",
"0.74372834",
"0.69827044",
"0.6873026",
"0.67610544",
"0.6745673",
"0.6674018",
"0.6654089",
"0.6649646",
"0.65670836",
"0.65333444",
"0.6473299",
"0.6455045",
"0.64548343",
"0.64539176",
"0.64294076",
"0.6427616",
"0.6336909",
"0.6323785",
"0.6301... | 0.7892569 | 0 |
SetOutput(itkVTKPolyDataReaderMF2_Superclass self, itkMeshF2 output) | def SetOutput(self, output: 'itkMeshF2') -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_SetOutput(self, output) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def SetOutput(self, output: 'itkMeshD2') -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_SetOutput(self, output)",
"def SetOutput(self, output: 'itkMeshF3') -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_SetOutput(self, outp... | [
"0.8525188",
"0.84718144",
"0.8205276",
"0.80889446",
"0.8001851",
"0.7655989",
"0.75782824",
"0.75522506",
"0.7546922",
"0.7536396",
"0.75267583",
"0.7204722",
"0.715482",
"0.71456856",
"0.7132667",
"0.71174914",
"0.70717686",
"0.7030775",
"0.69265956",
"0.6873598",
"0.66488... | 0.89493793 | 0 |
GraftOutput(itkVTKPolyDataReaderMF2_Superclass self, itkDataObject output) | def GraftOutput(self, *args) -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GraftOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GraftOutput(self, *args)",
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_GraftOutput(self, *args)",
"def GraftOutp... | [
"0.8130288",
"0.80519474",
"0.7942176",
"0.6983942",
"0.6962713",
"0.6913136",
"0.67821646",
"0.67638755",
"0.6760897",
"0.6705427",
"0.66739273",
"0.6664917",
"0.6588142",
"0.6556453",
"0.6512404",
"0.6503565",
"0.6493518",
"0.6471571",
"0.64698035",
"0.6453795",
"0.64499056... | 0.82122236 | 0 |
GraftNthOutput(itkVTKPolyDataReaderMF2_Superclass self, unsigned int idx, itkDataObject output) | def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GraftNthOutput(self, idx, output) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GraftNthOutput(self, idx, output)",
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDa... | [
"0.90473384",
"0.9017333",
"0.88929665",
"0.85269374",
"0.84469825",
"0.8445318",
"0.83976495",
"0.83794045",
"0.83675045",
"0.8357868",
"0.8292287",
"0.8280899",
"0.8260153",
"0.82486194",
"0.8241042",
"0.8227177",
"0.8212291",
"0.8191821",
"0.8185502",
"0.81849027",
"0.8138... | 0.91227263 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMF2_Superclass | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF2_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMF2_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3_Superclass *\":\n return _itkVTKPolyDataReade... | [
"0.8905782",
"0.88501304",
"0.8833181",
"0.8755976",
"0.87391263",
"0.86269146",
"0.8564233",
"0.82617337",
"0.81217426",
"0.8025149",
"0.7977617",
"0.7750337",
"0.773953",
"0.7726464",
"0.7534636",
"0.747188",
"0.7471632",
"0.7462359",
"0.744899",
"0.74343425",
"0.74208295",... | 0.8956166 | 0 |
New() > itkVTKPolyDataReaderMF2_Superclass Create a new object of the class itkVTKPolyDataReaderMF2_Superclass and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parame... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMF2_Superclass.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF3_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD2_Superclass.__New_orig__()\n import itkTemplate\n ... | [
"0.74540746",
"0.7451178",
"0.7219186",
"0.70385236",
"0.6781204",
"0.67454123",
"0.670874",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"0.64998007",
"... | 0.76841676 | 0 |
itkVTKPolyDataReaderMF2_Superclass_cast(itkLightObject obj) > itkVTKPolyDataReaderMF2_Superclass | def itkVTKPolyDataReaderMF2_Superclass_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF2_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMD2_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD2_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_Superclass_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2_Superclass *\":\n return _itkVTKPolyDataReade... | [
"0.9209019",
"0.91556823",
"0.9045983",
"0.90078884",
"0.9002894",
"0.8940526",
"0.8859046",
"0.8091028",
"0.8065766",
"0.77564543",
"0.77114975",
"0.763564",
"0.7595573",
"0.7590069",
"0.7483078",
"0.7443146",
"0.7427711",
"0.7419046",
"0.74123347",
"0.74058944",
"0.7392639"... | 0.9407642 | 0 |
GetOutput(itkVTKPolyDataReaderMF3_Superclass self) > itkMeshF3 GetOutput(itkVTKPolyDataReaderMF3_Superclass self, unsigned int idx) > itkMeshF3 | def GetOutput(self, *args) -> "itkMeshF3 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GetOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GetOutput(self, *args) -> \"itkMeshD3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_GetOutput(self, *args)",
"def GetOutput(self, *args) -> \"itkMeshF3 *\":\n return _itkMeshSourcePython.itkMeshSourceMF3_GetOutput(self, *args)",
"def GetOutput(self, *args) -> \"... | [
"0.7605253",
"0.7574454",
"0.72822845",
"0.7034463",
"0.69938135",
"0.6920087",
"0.68826795",
"0.68763137",
"0.68497646",
"0.6827157",
"0.68025696",
"0.6785515",
"0.6771522",
"0.6754258",
"0.6721871",
"0.67161614",
"0.6715198",
"0.6676471",
"0.6665962",
"0.66621035",
"0.66533... | 0.79739124 | 0 |
GraftOutput(itkVTKPolyDataReaderMF3_Superclass self, itkDataObject output) | def GraftOutput(self, *args) -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GraftOutput(self, *args) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_GraftOutput(self, *args)",
"def GraftOutput(self, *args) -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GraftOutput(self, *args)",
"def GraftOutp... | [
"0.8193116",
"0.80728894",
"0.7882771",
"0.7145456",
"0.70911217",
"0.7047416",
"0.69091403",
"0.6900465",
"0.68852526",
"0.68651533",
"0.6801472",
"0.67880064",
"0.67750514",
"0.6749372",
"0.67479706",
"0.6732674",
"0.6722028",
"0.6709429",
"0.66856873",
"0.66558284",
"0.663... | 0.8276848 | 0 |
GraftNthOutput(itkVTKPolyDataReaderMF3_Superclass self, unsigned int idx, itkDataObject output) | def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> "void":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_GraftNthOutput(self, idx, output) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_Superclass_GraftNthOutput(self, idx, output)",
"def GraftNthOutput(self, idx: 'unsigned int', output: 'itkDataObject') -> \"void\":\n return _itkVTKPolyDa... | [
"0.9118962",
"0.9037907",
"0.89962023",
"0.8567844",
"0.8530509",
"0.84809345",
"0.84635574",
"0.84542704",
"0.8444793",
"0.8443348",
"0.84179914",
"0.83992505",
"0.8386719",
"0.83786374",
"0.8365915",
"0.8344877",
"0.8338573",
"0.8334218",
"0.83336526",
"0.82666224",
"0.8249... | 0.9147346 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMF3_Superclass | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF3_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMF3_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD3_Superclass *\":\n return _itkVTKPolyDataReade... | [
"0.8880769",
"0.8860972",
"0.8846147",
"0.87885773",
"0.8744392",
"0.87074065",
"0.858495",
"0.82612014",
"0.81695944",
"0.8086474",
"0.7974443",
"0.7971272",
"0.78686744",
"0.778145",
"0.7674847",
"0.76176256",
"0.7581959",
"0.75680834",
"0.75572324",
"0.7534214",
"0.7437519... | 0.89582354 | 0 |
New() > itkVTKPolyDataReaderMF3_Superclass Create a new object of the class itkVTKPolyDataReaderMF3_Superclass and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parame... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMF3_Superclass.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD3_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF2_Superclass.__New_orig__()\n import itkTemplate\n ... | [
"0.7511705",
"0.7454827",
"0.716506",
"0.7080661",
"0.68261373",
"0.68255913",
"0.6726769",
"0.6639363",
"0.6623955",
"0.65387344",
"0.648878",
"0.6481108",
"0.6430881",
"0.6407402",
"0.64049613",
"0.63674617",
"0.632797",
"0.63156235",
"0.6301327",
"0.62682337",
"0.6264734",... | 0.7702708 | 0 |
itkVTKPolyDataReaderMF3_Superclass_cast(itkLightObject obj) > itkVTKPolyDataReaderMF3_Superclass | def itkVTKPolyDataReaderMF3_Superclass_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF3_Superclass *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_Superclass_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMD3_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD3_Superclass *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_Superclass_cast(obj)",
"def itkVTKPolyDataReaderMF2_Superclass_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2_Superclass *\":\n... | [
"0.92584705",
"0.9166564",
"0.91571593",
"0.90275896",
"0.8992779",
"0.895428",
"0.88146317",
"0.8041499",
"0.8030828",
"0.7877269",
"0.7839337",
"0.7809416",
"0.77590144",
"0.76929086",
"0.76866615",
"0.7660918",
"0.7635396",
"0.7633004",
"0.75632817",
"0.75449896",
"0.75317... | 0.94046533 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMD2 | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD2 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMD2_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_cast(obj)",
... | [
"0.87414837",
"0.8495271",
"0.84810925",
"0.8470628",
"0.8453387",
"0.8280795",
"0.8135715",
"0.7659763",
"0.7578301",
"0.7322849",
"0.7265699",
"0.72569704",
"0.72541624",
"0.7230701",
"0.72121894",
"0.71700263",
"0.71563697",
"0.7108633",
"0.70956486",
"0.70845443",
"0.7084... | 0.8709035 | 1 |
New() > itkVTKPolyDataReaderMD2 Create a new object of the class itkVTKPolyDataReaderMD2 and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parameter in the first input... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMD2.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD2_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF2.__New_orig__()\n import itkTemplate\n itkTemplat... | [
"0.7486866",
"0.73218215",
"0.7263431",
"0.7194011",
"0.7152605",
"0.69301796",
"0.68870574",
"0.65817034",
"0.6515586",
"0.6255528",
"0.62154335",
"0.6162841",
"0.61564505",
"0.6093685",
"0.60682404",
"0.60270506",
"0.6008142",
"0.5998347",
"0.5996243",
"0.5976526",
"0.59478... | 0.76431096 | 0 |
itkVTKPolyDataReaderMD2_cast(itkLightObject obj) > itkVTKPolyDataReaderMD2 | def itkVTKPolyDataReaderMD2_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD2 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_cast(obj)",
"def itkVTKPolyDataReaderMF2_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_cast(obj)",
... | [
"0.9036641",
"0.8935557",
"0.87376827",
"0.87362945",
"0.8613084",
"0.8373323",
"0.8343494",
"0.7937828",
"0.77196705",
"0.7515895",
"0.75017166",
"0.7407971",
"0.7325445",
"0.7261453",
"0.7253458",
"0.72441167",
"0.7207243",
"0.7187209",
"0.7185671",
"0.7163868",
"0.7121509"... | 0.92964 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMD3 | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD3 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMD3_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_cast(obj)",
"def itkVTKPolyDataReaderMF3_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataRe... | [
"0.88322234",
"0.8581361",
"0.8562512",
"0.84067816",
"0.8323035",
"0.8252179",
"0.8125859",
"0.77662826",
"0.7697816",
"0.74000424",
"0.7369259",
"0.7333734",
"0.7327789",
"0.7314455",
"0.72977877",
"0.7259937",
"0.72378284",
"0.7231993",
"0.7229094",
"0.72043824",
"0.717575... | 0.87587047 | 1 |
New() > itkVTKPolyDataReaderMD3 Create a new object of the class itkVTKPolyDataReaderMD3 and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parameter in the first input... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMD3.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD3_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF3.__New_orig__()\n import itkTemplate\n itkTemplat... | [
"0.7589382",
"0.7430372",
"0.7234539",
"0.7088116",
"0.6909038",
"0.68806165",
"0.6869146",
"0.6811405",
"0.67039937",
"0.64034563",
"0.637145",
"0.63443244",
"0.63183194",
"0.6250091",
"0.6233647",
"0.6229986",
"0.6209305",
"0.6208201",
"0.61582375",
"0.6131584",
"0.60642546... | 0.77531445 | 0 |
itkVTKPolyDataReaderMD3_cast(itkLightObject obj) > itkVTKPolyDataReaderMD3 | def itkVTKPolyDataReaderMD3_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMD3 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_cast(obj)",
"def itkVTKPolyDataReaderMF3_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_cast(obj)",
... | [
"0.90688264",
"0.902042",
"0.8805617",
"0.86281925",
"0.8570097",
"0.835789",
"0.83568907",
"0.8041917",
"0.7882096",
"0.7600457",
"0.7539861",
"0.7472747",
"0.74631554",
"0.7455751",
"0.7371662",
"0.73672736",
"0.7358708",
"0.73418427",
"0.72996604",
"0.7276977",
"0.72605306... | 0.9330801 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMF2 | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF2 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMF2_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_cast(obj)",
... | [
"0.8716079",
"0.85788625",
"0.84647256",
"0.8448525",
"0.8351125",
"0.83135295",
"0.82161355",
"0.7488672",
"0.74479705",
"0.7431858",
"0.7423658",
"0.73602676",
"0.735614",
"0.7353466",
"0.72860634",
"0.7261479",
"0.72512937",
"0.7245262",
"0.71902835",
"0.7152248",
"0.71474... | 0.8731354 | 0 |
New() > itkVTKPolyDataReaderMF2 Create a new object of the class itkVTKPolyDataReaderMF2 and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parameter in the first input... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMF2.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF2_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD2.__New_orig__()\n import itkTemplate\n itkTemplat... | [
"0.7575653",
"0.7440162",
"0.73664784",
"0.73589516",
"0.7297517",
"0.7071608",
"0.70371974",
"0.6672244",
"0.65829754",
"0.6525233",
"0.63202345",
"0.62582713",
"0.625329",
"0.6208995",
"0.6194301",
"0.6182085",
"0.6155835",
"0.6110843",
"0.6102939",
"0.60577106",
"0.6057163... | 0.7761501 | 0 |
itkVTKPolyDataReaderMF2_cast(itkLightObject obj) > itkVTKPolyDataReaderMF2 | def itkVTKPolyDataReaderMF2_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF2 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_cast(obj)",
"def itkVTKPolyDataReaderMD2_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD2_cast(obj)",
... | [
"0.90805286",
"0.8894714",
"0.8820932",
"0.8791773",
"0.8781079",
"0.8530374",
"0.84897333",
"0.7698802",
"0.76301163",
"0.75587326",
"0.75576854",
"0.7525522",
"0.75089854",
"0.74666303",
"0.7434812",
"0.7418323",
"0.740602",
"0.73314315",
"0.72916275",
"0.72887737",
"0.7270... | 0.9299841 | 0 |
cast(itkLightObject obj) > itkVTKPolyDataReaderMF3 | def cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF3 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def itkVTKPolyDataReaderMF3_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_cast(obj)",
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF2 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF2_cast(obj)",
... | [
"0.8782228",
"0.8534416",
"0.8530838",
"0.8496905",
"0.8434184",
"0.82364905",
"0.8055068",
"0.75656736",
"0.7548002",
"0.7487407",
"0.7465692",
"0.74095064",
"0.74002165",
"0.73897666",
"0.73869264",
"0.7297321",
"0.7293979",
"0.7288291",
"0.7275806",
"0.72640616",
"0.726271... | 0.8777374 | 1 |
New() > itkVTKPolyDataReaderMF3 Create a new object of the class itkVTKPolyDataReaderMF3 and set the input and the parameters if some named or nonnamed arguments are passed to that method. New() tries to assign all the non named parameters to the input of the new objects the first non named parameter in the first input... | def New(*args, **kargs):
obj = itkVTKPolyDataReaderMF3.__New_orig__()
import itkTemplate
itkTemplate.New(obj, *args, **kargs)
return obj | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMF3_Superclass.__New_orig__()\n import itkTemplate\n itkTemplate.New(obj, *args, **kargs)\n return obj",
"def New(*args, **kargs):\n obj = itkVTKPolyDataReaderMD3.__New_orig__()\n import itkTemplate\n itkTemplat... | [
"0.75816745",
"0.7492749",
"0.74230224",
"0.7205986",
"0.7007809",
"0.6875884",
"0.68169224",
"0.6810148",
"0.67864287",
"0.6690951",
"0.66608864",
"0.6542589",
"0.6515128",
"0.64522505",
"0.6364156",
"0.6328759",
"0.6315082",
"0.62795043",
"0.62166333",
"0.619559",
"0.618998... | 0.78172106 | 0 |
itkVTKPolyDataReaderMF3_cast(itkLightObject obj) > itkVTKPolyDataReaderMF3 | def itkVTKPolyDataReaderMF3_cast(obj: 'itkLightObject') -> "itkVTKPolyDataReaderMF3 *":
return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_cast(obj) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMF3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMF3_cast(obj)",
"def itkVTKPolyDataReaderMD3_cast(obj: 'itkLightObject') -> \"itkVTKPolyDataReaderMD3 *\":\n return _itkVTKPolyDataReaderPython.itkVTKPolyDataReaderMD3_cast(obj)",
... | [
"0.91032755",
"0.90036005",
"0.8833847",
"0.87552774",
"0.86872655",
"0.834996",
"0.83138585",
"0.78661996",
"0.77133703",
"0.7642773",
"0.7632494",
"0.7603585",
"0.7598717",
"0.7519145",
"0.7511102",
"0.750184",
"0.7459812",
"0.74407727",
"0.74397993",
"0.74324274",
"0.73969... | 0.9357763 | 0 |
MagicMock is a subclass of Mock with all the magic methods precreated. | def test_magic_mock():
class Empty:
pass
empty = Empty()
empty.abc = MagicMock(return_value="abc") # type: ignore
assert empty.abc("hi") == "abc" # type: ignore
empty.abc.assert_called_with("hi") # type: ignore | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def patch(*args, **kwargs):\n kwargs.setdefault('autospec', True)\n return mock.patch.object(*args, **kwargs)",
"def mock(self, patches=None, **kwargs_patches):\n return Mock(patches, **kwargs_patches)",
"def mock_decorator():\n\n def test_method(func):\n @wraps(func)\n def inner_meth... | [
"0.6544546",
"0.6449324",
"0.6239497",
"0.6209602",
"0.61835164",
"0.6124654",
"0.6087282",
"0.6070763",
"0.6063072",
"0.60474205",
"0.6011741",
"0.6009641",
"0.5996382",
"0.5982019",
"0.59813994",
"0.59813994",
"0.5975996",
"0.5964876",
"0.59270227",
"0.5921619",
"0.5921",
... | 0.6317938 | 2 |
Return the metadata type. | def type(self):
return self._getValue('type') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def get_type(self):\r\n return self.mm_type + self.meta_model.get_type()",
"def get_metadata_type(output_type: Any) -> str:\n if output_type is str or output_type is AnyStr:\n return \"String\"\n if output_type is datetime.datetime or output_type is datetime.date:\n ret... | [
"0.74593997",
"0.7444839",
"0.73110116",
"0.7295682",
"0.72877115",
"0.72877115",
"0.72747433",
"0.72747433",
"0.72710264",
"0.7259731",
"0.72483194",
"0.72287965",
"0.72178274",
"0.72178274",
"0.7198608",
"0.7192919",
"0.7189528",
"0.7159251",
"0.713134",
"0.71228117",
"0.71... | 0.7449201 | 1 |
The shortTitle is a short description of the object. Update the shortTitle if a new shortTitle is specified. Return the shortTitle if defined, or None if undefined. | def shortTitle(self, newShortTitle=None):
if newVersion != None:
self._setValue('shortTitle', newShortTitle)
return self._getValue('shortTitle') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def shortTitle(self, newShortTitle=None):\n pass",
"def short_title(self):\n if hasattr(self, \"title\"):\n return self.title\n else:\n return \"\"",
"def short_name_or_full(self):\n return self.short_name or self.title",
"def short_title(self):\r\n re... | [
"0.7917882",
"0.7774514",
"0.6874072",
"0.6737595",
"0.6659757",
"0.6442439",
"0.6411836",
"0.6377967",
"0.63419014",
"0.6313807",
"0.6286144",
"0.6263659",
"0.62376696",
"0.6219245",
"0.61717993",
"0.6160221",
"0.61513495",
"0.6082564",
"0.6074802",
"0.60710245",
"0.60552",
... | 0.80576783 | 0 |
The description is a text string detailing the object. Update the description if a new description is specified. Return the description if defined, or None if undefined. | def description(self, newDescription=None):
if newDescription != None:
self._setValue('description', newDescription)
return self._getValue('description') | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def description(self, newDescription=None):\n pass",
"def description(self, description) :\n\t\ttry :\n\t\t\tself._description = description\n\t\texcept Exception as e:\n\t\t\traise e",
"def description(self) -> Optional[str]:\n return pulumi.get(self, \"description\")",
"def description(self) ... | [
"0.7563857",
"0.74566925",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",
"0.74221635",... | 0.74020684 | 24 |
generate a tukey window The Tukey window, also known as the tapered cosine window, can be regarded as a cosine lobe of width \alpha N / 2 that is convolved with a rectangle window of width (1 \alpha / 2). At \alpha = 1 it becomes rectangular, and at \alpha = 0 it becomes a Hann window. | def tukey(N, alpha):
# Special cases
if alpha <= 0:
return np.ones(N) #rectangular window
elif alpha >= 1:
return np.hanning(N)
# Normal case
x = np.linspace(0, 1, N)
w = np.ones(x.shape)
# first condition 0 <= x < alpha/2
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def window(k, w, x0):\n return 2.*w * sinc(k*w) * (np.cos(k*x0) + 1.j*np.sin(k*x0))",
"def make_2d_butterworth_window(width, height, u, v, n):\n xcenter = np.ceil(width / 2.0) - 1.0\n ycenter = np.int16(np.ceil(height / 2.0) - 1)\n xlist = np.arange(width) - xcenter\n window = 1.0 / (1.0 + np.powe... | [
"0.6123079",
"0.6069517",
"0.57309806",
"0.5634106",
"0.55732507",
"0.5570335",
"0.5516712",
"0.55072755",
"0.5504281",
"0.549766",
"0.5489958",
"0.5485636",
"0.54792583",
"0.5409747",
"0.5404319",
"0.52704805",
"0.5197016",
"0.51784706",
"0.517535",
"0.5157841",
"0.515018",
... | 0.7058109 | 0 |
Generate a dictionary to turn punctuation into tokens. | def token_lookup():
token_list = {".": "||Period||",
",": "||Comma||",
'"': "|Quotation_Mark||",
";": "||Semicolon||",
"!": "||Exclamation_Mark||",
"?": "||Question_Mark||",
"(": "... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def preprocessing(self, tokens):\n\n return ({word: True for word in tokens})",
"def word_map(text):\n\n # Replace puncation with words\n s = text.replace('.', \" :period:\")\n s = s.replace('\\n', \"\")\n s = s.replace('\"', \" :quote:\")\n s = s.replace(',', \" :comma:\")\n s = s.repla... | [
"0.6529177",
"0.65043074",
"0.64284104",
"0.63942623",
"0.6292388",
"0.623719",
"0.61057144",
"0.61048883",
"0.60892695",
"0.59828925",
"0.59764075",
"0.5968627",
"0.5912908",
"0.58588994",
"0.5834462",
"0.5818921",
"0.57934797",
"0.5783206",
"0.57639056",
"0.57485324",
"0.56... | 0.56958723 | 21 |
Find all roots for a node. | def ancestry_of(self, kw):
pending = [kw]
ancestry = []
while pending:
kkw = pending.pop()
parents = self.parents_of(kkw)
if kkw not in parents:
ancestry.append(kkw)
pending.extend(parents)
return ancestry | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def roots(self):\n if not self.__roots:\n self.__roots = set()\n for n in self.__nodes:\n if n not in self.__reverse_map:\n self.__roots.add(n)\n return self.__roots",
"def roots (self, reset=False):\n if reset or (self.__roots is None)... | [
"0.7399542",
"0.7267046",
"0.7136152",
"0.7110152",
"0.70334584",
"0.6974785",
"0.6947743",
"0.6945859",
"0.6905767",
"0.6862827",
"0.6481292",
"0.6478781",
"0.64249945",
"0.6420068",
"0.6397872",
"0.6372357",
"0.6341288",
"0.63390905",
"0.6290985",
"0.62661415",
"0.62269086"... | 0.0 | -1 |
Find all roots for a node. | def roots_of(self, kw):
return [kkw for kkw in self.ancestry_of(kw) if not self.getNode(kkw).edgein] | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def roots(self):\n if not self.__roots:\n self.__roots = set()\n for n in self.__nodes:\n if n not in self.__reverse_map:\n self.__roots.add(n)\n return self.__roots",
"def roots (self, reset=False):\n if reset or (self.__roots is None)... | [
"0.7398364",
"0.72655565",
"0.7135279",
"0.7107754",
"0.7032968",
"0.69740725",
"0.6946324",
"0.6944733",
"0.69052577",
"0.68611765",
"0.6480848",
"0.6479287",
"0.64193",
"0.6396972",
"0.63715076",
"0.63402283",
"0.6336544",
"0.6289143",
"0.62650514",
"0.622471",
"0.6210218",... | 0.6424635 | 12 |
Selects a random suitable pizza. | def choose_pizza(pizzas):
possible_pizzas = []
for i in pizzas.keys():
suitable = True
for element in pizzas[i]:
if "tuna" in element:
suitable = False
elif "garlic sauce" in element:
suitable = False
elif "anchovy" in element... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def touching_choice(self,p):\n choose = random.sample(part,2)\n\n return choose",
"def pickup(pizza: str) -> None:\n print(f'{pizza} is ready for pick-up!')\n sleep(randint(3, 7))",
"def randomly_pick_recipe(cls):\n return random.choice(cls._recipes)",
"def touching_choice(self,p):... | [
"0.6617889",
"0.64611375",
"0.6438095",
"0.6391295",
"0.63050854",
"0.6301065",
"0.62923485",
"0.6194881",
"0.6154273",
"0.61065793",
"0.6062163",
"0.6060672",
"0.60568607",
"0.60478884",
"0.60453904",
"0.6029532",
"0.60213864",
"0.5991342",
"0.598643",
"0.5951526",
"0.594663... | 0.7406807 | 0 |
Finds a pizza that does not contain seafood nor garlic sauce. | def main():
splitted_file = convert_input_to_list()
encyclopedia_of_pizza = parse_pizza_info(splitted_file)
pizza_winner = choose_pizza(encyclopedia_of_pizza)
print_winner(pizza_winner) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def test_only_pos_that_not_match(self):\n eq_(None, grepit(\"naranja\", [\"ob\"]))",
"def choose_pizza(pizzas):\n possible_pizzas = []\n for i in pizzas.keys():\n suitable = True\n for element in pizzas[i]:\n if \"tuna\" in element:\n suitable = False\n ... | [
"0.6210843",
"0.599138",
"0.5942159",
"0.57794756",
"0.5722697",
"0.5686044",
"0.552888",
"0.5516223",
"0.5504535",
"0.54979724",
"0.53136116",
"0.52783865",
"0.52015996",
"0.51658916",
"0.51584053",
"0.51329756",
"0.5120957",
"0.5087453",
"0.5069459",
"0.50654685",
"0.505593... | 0.0 | -1 |
Gets the namespace under which a plugin is importable. | def get_plugin_namespace(plugin_name: str) -> str:
return f'napari.plugins.{plugin_name}' | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def namespace(self):\n assert self._namespace\n return self._namespace",
"def get_namespace(self) -> str:\n return self._namespace",
"def namespace(self):\n return self._namespace",
"def namespace (self) :\n\n return self.__namespace__",
"def namespace(self):\n return self.__k... | [
"0.6810391",
"0.6672802",
"0.66024816",
"0.65657693",
"0.6518123",
"0.6388743",
"0.63323057",
"0.6261576",
"0.62601054",
"0.62545574",
"0.6237234",
"0.6237234",
"0.6237234",
"0.61565757",
"0.61565757",
"0.61565757",
"0.61565757",
"0.61565757",
"0.61565757",
"0.61565757",
"0.6... | 0.68189514 | 0 |
Removes stones with zero liberties from the board. | def remove_stones_with_zero_liberties(self):
for pos in BOARD_POSITIONS:
if self.board[pos[0]][pos[1]].liberty == 0:
self.board[pos[0]][pos[1]] = Stone(color=0, pos=(pos[0], pos[1]))
self.state[pos[0]][pos[1]] = 0 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def remove_numbers(self):\n for i in range(len(self.board.board[0])):\n while self.board.board[i].count(0) < 6:\n random_val = random.randint(0, 8)\n self.board.update_board((i, random_val), 0)",
"def trim_zeros(x):\n assert len(x.shape) == 2\n return x[~np.a... | [
"0.64137113",
"0.63456213",
"0.63293874",
"0.6228331",
"0.60316753",
"0.59938043",
"0.599121",
"0.5985142",
"0.5911929",
"0.59046763",
"0.5899423",
"0.58507985",
"0.5841387",
"0.5817163",
"0.58100194",
"0.5809996",
"0.5790554",
"0.5788706",
"0.5779393",
"0.57780707",
"0.57757... | 0.8482506 | 0 |
Finds the legal moves possible in the current state of the board. | def legal_moves_generator(self, custom=False):
possible_moves = self.null_positions
possible_moves.add('PASS')
temp_state = np.array(self.state)
illegal_moves = set()
for pos in possible_moves:
illegal = True
if pos != 'PASS':
ortho... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def get_legal_moves(self):\n # for each square in the castle figure out if an moves can occur from it.\n moves = []\n allowed = [self.turn]\n if self.turn == DEFENDER:\n allowed.extend((KING, CASTLE_OCCUPIED))\n it = np.nditer(self.board_state, flags=['multi_index'])\n... | [
"0.8075349",
"0.7984954",
"0.79392046",
"0.7845153",
"0.78070545",
"0.77825946",
"0.7757998",
"0.7719685",
"0.7700662",
"0.7664667",
"0.7663939",
"0.7653433",
"0.76327014",
"0.76248264",
"0.7596899",
"0.75809056",
"0.7540602",
"0.75276464",
"0.74966204",
"0.74842787",
"0.7481... | 0.6866031 | 71 |
Creates a new H2ODataWrapper based on this PandasDataWrapper and returns it as a new object | def to_h2o(self, factor_columns_list=None):
from mercury_ml.common.data_wrappers.h2o import H2ODataWrapper
import h2o
df_h2o = h2o.H2OFrame(self.underlying)
# convert columns
if not factor_columns_list:
factor_columns_list = []
for factor_column_name in fac... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def make_dataset(self, df, **kwargs):\n\t\treturn df",
"def pandas_container(self, column1, column2):\n\n column_1_name = column1\n column_2_name = column2\n\n column_1 = self.data_dict[column_1_name]\n column_2 = self.data_dict[column_2_name]\n\n wrapped_data = pd.DataFrame({'... | [
"0.56470215",
"0.5639382",
"0.54764575",
"0.5430153",
"0.52927595",
"0.52926236",
"0.52635384",
"0.5263526",
"0.5234273",
"0.5200349",
"0.51831913",
"0.51702476",
"0.5157576",
"0.51383305",
"0.51364076",
"0.5112698",
"0.51043946",
"0.50977105",
"0.50977105",
"0.50977105",
"0.... | 0.6820072 | 0 |
Creates a new H2ODataWrapper based on this PandasDataWrapper and returns it as a new object | def to_h2o_sparkling(self, spark_session_params=None, factor_columns_list=None, h2o_sparkling_params=None):
if spark_session_params is None:
spark_session_params = {}
if h2o_sparkling_params is None:
h2o_sparkling_params = {}
return self.to_spark(spark_session_params).... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def to_h2o(self, factor_columns_list=None):\n\n from mercury_ml.common.data_wrappers.h2o import H2ODataWrapper\n import h2o\n df_h2o = h2o.H2OFrame(self.underlying)\n\n # convert columns\n if not factor_columns_list:\n factor_columns_list = []\n\n for factor_col... | [
"0.681963",
"0.56484973",
"0.56400836",
"0.5477601",
"0.5429924",
"0.52947354",
"0.5293732",
"0.52645326",
"0.526258",
"0.52350265",
"0.51998395",
"0.5183499",
"0.5171745",
"0.51593184",
"0.5137983",
"0.5137274",
"0.51120806",
"0.510614",
"0.5098753",
"0.5098753",
"0.5098753"... | 0.0 | -1 |
Sets the submit_text of this FormDisplay. | def submit_text(self, submit_text):
self._submit_text = submit_text | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def set_text(self, text):\n\n self.text = text",
"def setText(self, text):\n assert self.isLabel(text)\n self._text = text",
"def SetText(self, text):\r\n\r\n self._text = text",
"def set_text(self, text):\n self._label.setText(text)",
"def display_text(self, display_text... | [
"0.6230147",
"0.6141961",
"0.6074783",
"0.6030911",
"0.6005871",
"0.5973163",
"0.5929744",
"0.5853988",
"0.5847077",
"0.58351403",
"0.5825793",
"0.5800701",
"0.57803506",
"0.57727206",
"0.575958",
"0.575958",
"0.575958",
"0.575958",
"0.575958",
"0.575958",
"0.5747479",
"0.5... | 0.82573324 | 0 |
Returns true if both objects are equal | def __eq__(self, other):
if not isinstance(other, FormDisplay):
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 |
pour u E [0,4], et x E [0,1] , retourne (x1.0)mu(1x) , cad f(x) | def exo2_1(x,mu):
return (x*1.0)*mu*(1-x) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def F_nu_mu_1(self, x, E_p):\n\n L = np.log(E_p/1e3)\n\n B_prime = 1.75 + 0.204*L + 0.010*L*L\n beta_prime = 1./(1.67 + 0.111*L + 0.0038*L*L)\n k_prime = 1.07 - 0.086*L + 0.002*L*L\n\n y = x/0.427 #1-(m_mu/m_pi)^2\n\n # mask values for x>0.427 due to numerical problems\n ... | [
"0.6667444",
"0.65900034",
"0.65715104",
"0.6551377",
"0.65379065",
"0.642",
"0.6365841",
"0.6355873",
"0.6251566",
"0.6220782",
"0.6202644",
"0.618833",
"0.6153686",
"0.6133279",
"0.61130416",
"0.6096846",
"0.6091273",
"0.6088507",
"0.6083179",
"0.60758233",
"0.60651076",
... | 0.70365596 | 0 |
f( mu, n, X0, Y0) = [X0,...,Xn] , [Y0,...,Yn] | def exo4_q1(mu,n,x0,y0):
#liste.append([x0,y0])
absc = x0
ordn = y0
L = np.array([absc])
M = np.array([ordn])
for i in range(0,n):
absc = exo2_1(absc,mu)
ordn = exo2_1(ordn,mu)
L = np.append(L,[absc])
M = np.append(M,[ordn])
return L,M | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def Generate_Custom(f, n, m):\n return np.fromfunction(np.vectorize(f, otypes=[float]), (n,m))",
"def sample2d(f, x_args):\n try:\n f = sympify(f)\n except SympifyError:\n raise ValueError(\"f could not be interpreted as a SymPy function\")\n try:\n x, x_min, x_max, x_n = x_args\... | [
"0.64159024",
"0.5812967",
"0.57931745",
"0.5712494",
"0.570316",
"0.568376",
"0.5609767",
"0.56034136",
"0.5534028",
"0.55303925",
"0.5467179",
"0.54524845",
"0.54505366",
"0.5435652",
"0.5429671",
"0.54147846",
"0.54042244",
"0.53855187",
"0.5361368",
"0.53556645",
"0.53535... | 0.5000023 | 74 |
Computes the precision for the specified values of k | def accuracy(output, target, topk=(1,)):
maxk = max(topk)
batch_size = target.size(0)
_, pred = output.topk(maxk, 1, True, True)
pred = pred.t()
correct = pred.eq(target.view(1, -1).expand_as(pred))
res = []
for k in topk:
correct_k = correct[:k].view(-1).float().sum(0)
res... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def precision(gt, pred, k):\n k = min(len(pred), k)\n den = min(len(gt), k)\n return sum([int(pred[i] in gt) for i in range(k)]) / den",
"def precision_at_k(r, k):\n assert k >= 1\n r = np.asarray(r)[:k] != 0\n if r.size != k:\n raise ValueError('Relevance score length < k')\... | [
"0.76427615",
"0.74189496",
"0.7418079",
"0.72710466",
"0.72456723",
"0.72446615",
"0.7237539",
"0.72213703",
"0.7210107",
"0.7058935",
"0.6852219",
"0.6786084",
"0.67836976",
"0.6768417",
"0.67273885",
"0.67181736",
"0.67181736",
"0.67181736",
"0.67181736",
"0.67181736",
"0.... | 0.0 | -1 |
Determine the current state of the game board. Return a 2d array specifiying the contents of each of the nine spaces, one of {'X', 'O', ' '} | def analyzeGameBoard(image, debug=False):
image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)
image = cv2.GaussianBlur(image, (5, 5), 0)
binary = cv2.threshold(image, 0, 255, cv2.THRESH_BINARY + cv2.THRESH_OTSU)[1]
edges = cv2.Canny(binary, 1, 254)
if debug:
cv2.imshow("Image", image... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def print_game_state(board):\r\n print(board)\r\n illegal_moves = [(0, 0), (2, 0), (0, 4), (2, 4)]\r\n for i in range(board.shape[0]):\r\n buffer = ''\r\n for j in range(board.shape[1]):\r\n if board[i][j] == 1:\r\n buffer += 'X\\t'\r\n elif board[i][j] =... | [
"0.7393186",
"0.7322825",
"0.7207247",
"0.7070738",
"0.7037436",
"0.68568105",
"0.6679788",
"0.6659444",
"0.6599657",
"0.65424776",
"0.6526163",
"0.6526163",
"0.6522095",
"0.6518275",
"0.6515954",
"0.6500045",
"0.64878094",
"0.6484265",
"0.64600533",
"0.64159447",
"0.64099646... | 0.0 | -1 |
(BST) > BSTNode Return the node with the maximum item. | def max_node(self):
node = self.root
while node.right is not None:
node = node.right
return _BSTNode(node.item) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def find_max(self) -> TreeNode:\n node = self.root\n while True:\n if not node.right:\n return node\n node = node.right",
"def find_max(self, node):\n current_node = node\n while current_node.right:\n current_node = current_node.right\n ... | [
"0.7581815",
"0.74274635",
"0.7354308",
"0.73281574",
"0.7260425",
"0.71796757",
"0.7087274",
"0.70816684",
"0.70703083",
"0.70024675",
"0.6994365",
"0.6938479",
"0.6934177",
"0.6877817",
"0.6871364",
"0.6813651",
"0.6768462",
"0.67452246",
"0.6681714",
"0.66711605",
"0.66516... | 0.7904138 | 0 |
Return triple of rgb arrays with values in [0,255]. | def generate_lut(self):
r,g,b=(Numeric.zeros(256),Numeric.zeros(256),Numeric.zeros(256))
for i in Numeric.arange(256):
r_,g_,b_=self.colfct(i/255.0) # these are from [0,1]
r[i],g[i],b[i]=int(255*r_),int(255*g_),int(255*b_)
return r,g,b | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def convert_to_RGB_255(colors):\n return (colors[0]*255.0, colors[1]*255.0, colors[2]*255.0)",
"def RGB255(RGB):\r\n return [round((RGB[0]*255), 2),\r\n round((RGB[1]*255), 2),\r\n round((RGB[2]*255), 2)]",
"def _rgb(x, y, z):\n rgb = np.array([x, y, z]).T\n rgb -= rgb.min(0)\... | [
"0.7371524",
"0.7180467",
"0.71791095",
"0.71109664",
"0.6859726",
"0.6808685",
"0.6724802",
"0.6700201",
"0.6690083",
"0.6679489",
"0.66475743",
"0.6633295",
"0.6577773",
"0.655747",
"0.6464138",
"0.64076596",
"0.64043146",
"0.64039576",
"0.6400883",
"0.63744974",
"0.6368134... | 0.6427059 | 15 |
Return triple of rgb arrays with values in [0, N1]. | def generate_lut(self, N=256):
r, g, b = (Numeric.zeros(N), Numeric.zeros(N), Numeric.zeros(N))
N_ = N - 1.0
for i in xrange(N):
r_, g_, b_ = self.colfct(i/N_) # these are from [0,1]
r[i], g[i], b[i] = int(N_*r_), int(N_*g_), int(N_*b_)
return r, g, b | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def three_different_np_images():\n rgb1 = np.zeros((32, 32, 3), dtype=np.uint8)\n rgb1[..., 0] = 192\n rgb1[..., 1] = 0\n rgb1[..., 2] = 0\n # img1 = Image.fromarray(rgb1)\n\n rgb2 = np.zeros((32, 32, 3), dtype=np.uint8)\n rgb2[..., 0] = 0\n rgb2[..., 1] = 192\n rgb2[..., 2] = 0\n # i... | [
"0.65134555",
"0.6347064",
"0.6264882",
"0.6161125",
"0.6158883",
"0.6155012",
"0.6107067",
"0.6064268",
"0.6053658",
"0.6018676",
"0.60112756",
"0.60098255",
"0.5957375",
"0.5904041",
"0.589689",
"0.5824173",
"0.58207226",
"0.58168095",
"0.5784413",
"0.57803327",
"0.572678",... | 0.5825533 | 15 |
Reads in an image from filename, turns it into a tensor and reshapes into (299, 299, 3). | def load_and_prep_image(filename, img_shape=299, rescale=False):
# Decode it into a tensor
# img = tf.io.decode_image(filename) # no channels=3 means model will break for some PNG's (4 channels)
img = tf.io.decode_image(filename, channels=3) # make sure there's 3 colour channels (for PNG's)
# Resize the image
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def load(filename):\n img = image.load_img(filename, target_size=(299, 299))\n np_image = image.img_to_array(img)\n np_image = np.array(np_image).astype('float32')/255\n\n # Make to a rank 4 tensor (1, 299, 299, 3) -> 1 is for the batch size\n np_image = np.expand_dims(np_image, axis=0)\n\n retur... | [
"0.78931165",
"0.75098985",
"0.7451722",
"0.73167723",
"0.7247266",
"0.7186059",
"0.7154297",
"0.71338934",
"0.7103383",
"0.7057282",
"0.70292854",
"0.69997466",
"0.6970498",
"0.69280916",
"0.6880437",
"0.68657404",
"0.68518114",
"0.6849971",
"0.68150556",
"0.6795102",
"0.670... | 0.70489293 | 10 |
Returns only the secret manager environment variables | def getSecretKeys():
secretKeys = dict()
for (key, value) in os.environ.items():
if( key.startswith("SM_")):
secretKeys[key] = value
if(bool(secretKeys)):
return secretKeys
else:
raise ValueError("Secrets Manager environment variable key not found, make sure there is ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def get_secrets():\n client = datastore.Client()\n query = client.query(kind='env_vars')\n entity = query.fetch()\n secrets = list(entity)[0]\n return secrets",
"def _generate_environment(self):\n envvars = {}\n for key in self.envvars:\n try:\n envvars[key]... | [
"0.7749702",
"0.7638858",
"0.725929",
"0.7230415",
"0.7041672",
"0.7001886",
"0.6913427",
"0.6913427",
"0.6913427",
"0.6913427",
"0.6912439",
"0.6872183",
"0.6832454",
"0.6810126",
"0.6806407",
"0.67984784",
"0.6779426",
"0.6687913",
"0.6631657",
"0.6631614",
"0.66103256",
... | 0.7896043 | 0 |
Update all connections between inventories and partners. | def cron_partner_ids(self):
pass | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def update_clients():\n if rabbit.leader_node_is_ready() or rabbit.client_node_is_ready():\n for rid in relation_ids('amqp'):\n for unit in related_units(rid):\n amqp_changed(relation_id=rid, remote_unit=unit)",
"def update_parties(self, *parties) -> None:\n\n for party... | [
"0.6423025",
"0.5923021",
"0.5878535",
"0.58710843",
"0.5833907",
"0.5817358",
"0.5745909",
"0.5580736",
"0.5565052",
"0.5550001",
"0.55255425",
"0.5504712",
"0.5492508",
"0.5459178",
"0.5438756",
"0.54308575",
"0.5430078",
"0.5428772",
"0.53994554",
"0.5385043",
"0.538307",
... | 0.0 | -1 |
Opens a csv file (given the filepath, and returns a pandas dataframe. | def read_register():
print("Please select a downloaded register file")
filename = filepicker()
if ".csv" not in filename:
print("You must select a .csv file, exported from Google forms")
register = pd.read_csv(filename)
return register | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def read_csv(path):\n return pd.read_csv(path)",
"def create_dataframe_from_csv(path_to_csv_file):\r\n df = pd.read_csv(path_to_csv_file)\r\n return df",
"def csv_to_df(self, path=None):\n # reads the csv file and puts it to the dataframe\n df = pd.read_csv(path)\n return df",
"... | [
"0.8111571",
"0.7910136",
"0.7845038",
"0.7818083",
"0.77358514",
"0.77358514",
"0.77358514",
"0.7727968",
"0.7714524",
"0.7695587",
"0.7631245",
"0.7559079",
"0.75470084",
"0.75372016",
"0.74834514",
"0.739366",
"0.73862445",
"0.73745096",
"0.73202187",
"0.72602165",
"0.7260... | 0.0 | -1 |
Reads a string written in binary format by my C++ code fobj file object opened for binary input endian '>' for bigendian, '' for littleendian. | def read_string(fobj, endian=''):
(nchar,) = struct.unpack(endian + 'i', fobj.read(4))
(string,) = struct.unpack(endian + str(nchar) + 's', fobj.read(nchar))
return string | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def read_string(fobj, endian=''):\n nchar = struct.unpack(endian + 'i', fobj.read(4))[0]\n strng = struct.unpack(endian + str(nchar) + 's', fobj.read(nchar))[0]\n return strng.decode('utf-8')",
"def test_file_bin_readwrite(self):\n FileWriter(self.binary_path).write_bin(self.binary_string)\n ... | [
"0.7180277",
"0.68159616",
"0.6643514",
"0.65566814",
"0.6242192",
"0.62269455",
"0.6112488",
"0.60400647",
"0.60342276",
"0.6026922",
"0.6004609",
"0.5996812",
"0.5985823",
"0.5977885",
"0.5951624",
"0.5929289",
"0.59199274",
"0.5878069",
"0.5864597",
"0.5845981",
"0.5829406... | 0.72449124 | 0 |
Create a line on ASCII canvas. | def line(self, x0, y0, x1, y1, char): # noqa: C901, PLR0912
# pylint: disable=too-many-arguments, too-many-branches
if x0 > x1:
x1, x0 = x0, x1
y1, y0 = y0, y1
dx = x1 - x0
dy = y1 - y0
if dx == 0 and dy == 0:
self.point(x0, y0, char)
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _createline(self):\n return self.cv.create_line(0, 0, 0, 0, fill=\"\", width=2,\n capstyle = TK.ROUND)",
"def DrawLine(p_length: int, p_character: str):\n print(p_character * p_length)\n return",
"def _draw_line_text(self):\n self._line_text.set_text(se... | [
"0.74452263",
"0.72564155",
"0.68333524",
"0.68165535",
"0.6811968",
"0.6811563",
"0.67502075",
"0.6735151",
"0.6728024",
"0.6707519",
"0.66031116",
"0.6585592",
"0.6578478",
"0.6576426",
"0.65622663",
"0.65552676",
"0.6508881",
"0.6506265",
"0.6488892",
"0.64880717",
"0.6473... | 0.63287455 | 29 |
Create a box on ASCII canvas. | def box(self, x0, y0, width, height):
assert width > 1
assert height > 1
width -= 1
height -= 1
for x in range(x0, x0 + width):
self.point(x, y0, "-")
self.point(x, y0 + height, "-")
for y in range(y0, y0 + height):
self.point(x0, y,... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def draw_box(stdscr, y, x, height, width, mode=0):\n if mode == 0:\n stdscr.addstr(y, x, \"┌\" + \"─\" * (width - 1) + \"┐\")\n stdscr.addstr(y + height, x, \"└\" + \"─\" * (width - 1) + \"┘\")\n for i in range(y + 1, y + height):\n stdscr.addstr(i, x, \"│\")\n stdscr.... | [
"0.74674064",
"0.70528483",
"0.668777",
"0.66729355",
"0.66608834",
"0.65444124",
"0.6533382",
"0.6514449",
"0.6401938",
"0.6390322",
"0.63638747",
"0.6357063",
"0.6354085",
"0.63375926",
"0.6333395",
"0.63129395",
"0.63129395",
"0.6304258",
"0.6294071",
"0.6277221",
"0.62725... | 0.6057886 | 30 |
Compares the long values a and b. a the first value b the second value 0 if a equals b; a number greater than 0 if a is greater than b; a number less than 0 if a is less than b. | def compare(self, a: long, b: long) -> int:
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def compare(a,b):\r\n if a>b:\r\n return 1\r\n elif a==b:\r\n return 0\r\n else:\r\n return -1",
"def _cmp(a, b): # pylint: disable=invalid-name\n return (a > b) - (a < b)",
"def sorted_are_equal(a, b):\n\n def int_sort(x):\n return sorted(x.astype(numpy.in... | [
"0.6561186",
"0.6556885",
"0.6396266",
"0.62705976",
"0.6171968",
"0.6160134",
"0.6142136",
"0.61334467",
"0.61285096",
"0.6045454",
"0.60405517",
"0.6004897",
"0.5999775",
"0.59800375",
"0.5976553",
"0.5921585",
"0.5915178",
"0.5899496",
"0.5879748",
"0.5871604",
"0.58539724... | 0.8173744 | 0 |
When a user is created, creates a profile related to that user. | def create_profile(sender, **kwargs):
# I import profile here cause i can't import it right in the top.
from .profiles import Profile
user = kwargs['instance']
Profile.objects.get_or_create(user=user) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def create_user_profile(sender, instance, created, **kwargs):\n if created:\n Profile.objects.create(user=instance)",
"def create_user_profile(sender, instance, created, **kwargs):\n if created:\n Profile.objects.create(user=instance)",
"def create_user_profile(sender, instance, created, **... | [
"0.85266054",
"0.85266054",
"0.85266054",
"0.8494233",
"0.84809387",
"0.8420165",
"0.8367438",
"0.83298385",
"0.8294773",
"0.8199257",
"0.81830037",
"0.81641245",
"0.8102185",
"0.8093885",
"0.8076879",
"0.8019159",
"0.79860955",
"0.79778206",
"0.7977293",
"0.79002047",
"0.789... | 0.7929395 | 19 |
'column_name' is a property that is equal to name | def test_column_name(self):
field = self.base_field
sch = SchemaField(field)
self.assertEqual(sch.name, sch.column_name)
self.assertNotEqual(sch.column_name, sch.title) | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _get_column(self, name):\r\n return self.column(name)",
"def _get_column(cls, name):\r\n return cls._columns[name]",
"def set_column_name(self, name):\r\n self.column_name = name",
"def set_column_name(self, name):\r\n self.column_name = name",
"def columnName(self):\n ... | [
"0.68297845",
"0.67737013",
"0.66889936",
"0.66889936",
"0.6676321",
"0.66703624",
"0.66172576",
"0.65761775",
"0.6570523",
"0.6519329",
"0.64228064",
"0.64118993",
"0.6408646",
"0.6408646",
"0.6406926",
"0.6363627",
"0.6357995",
"0.6239745",
"0.6205296",
"0.616581",
"0.61639... | 0.6678288 | 4 |
The cast should strip leading and trailing spaces | def test_space_stripping(self):
descriptor = clone(SPECIES_OBSERVATION_SCHEMA)
species_name = 'Chubby Bat'
record = {
'Observation Date': "18/08/2016",
'Latitude': -32,
'Longitude': 115,
'Species Name': ' Chubby Bat '
}
schema = S... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _strip(obj):\n return obj.translate(None, STRIP_CHARS)",
"def strip_space():\n pass",
"def squeeze(value):\r\n return re.sub(r\"[\\x00-\\x20]+\", \" \", value).strip()",
"def strip(value):\n return value.strip()",
"def normalize(s):\n return s.strip(inline_whitespace)",
"def trim_white... | [
"0.6732112",
"0.67285657",
"0.661408",
"0.640236",
"0.6375577",
"0.6252442",
"0.62503505",
"0.6231329",
"0.608969",
"0.6080383",
"0.60372525",
"0.600782",
"0.59785384",
"0.59785384",
"0.5977028",
"0.5973525",
"0.59649533",
"0.5962335",
"0.59398043",
"0.5935763",
"0.59215444",... | 0.5426105 | 83 |
get the value of property _CaptureMode | def CaptureMode(self):
if self.force_auto_sync:
self.get('CaptureMode')
return self._CaptureMode | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def state(self):\n return self._camera_data[\"recording_mode\"]",
"def get_mode(self):\r\n return self.mode",
"def getmode(self):\n return self.mode",
"def getMode(self):\n return self._mode",
"def mode(self):\r\n return self._mode",
"def mode(self):\r\n return s... | [
"0.7321415",
"0.7140151",
"0.7036411",
"0.68275505",
"0.68213433",
"0.68213433",
"0.68213433",
"0.6783859",
"0.6768667",
"0.6730493",
"0.6727176",
"0.6710562",
"0.6675019",
"0.6675019",
"0.6675019",
"0.6672326",
"0.6654987",
"0.65902793",
"0.65605944",
"0.6482549",
"0.6474639... | 0.8189759 | 0 |
get the value of property _CurrentDataFile | def CurrentDataFile(self):
if self.force_auto_sync:
self.get('CurrentDataFile')
return self._CurrentDataFile | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def _get_current_data(self, filename):\n with open(filename, 'rb') as handle:\n data_current = pickle.load(handle)\n return data_current",
"def path(self):\n return self._data_file",
"def read_fname(self):\n return self.read_value()",
"def __repr__(self):\n\n ret... | [
"0.7083209",
"0.7025984",
"0.69429374",
"0.6884861",
"0.6858723",
"0.6674693",
"0.66379803",
"0.6561348",
"0.65574896",
"0.6527233",
"0.6501532",
"0.6491245",
"0.64588654",
"0.6425095",
"0.6423876",
"0.6423876",
"0.6423876",
"0.6351888",
"0.6325862",
"0.6323015",
"0.6305197",... | 0.84159374 | 0 |
get the value of property _FcsError | def FcsError(self):
if self.force_auto_sync:
self.get('FcsError')
return self._FcsError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def error(self):\n return self['error']",
"def error(self):\n return self.get('error')",
"def error(self):\n return self._error",
"def error(self):\n return self._error",
"def error(self):\n return self._error",
"def get_error(self):\n return self.e",
"def err(... | [
"0.7402284",
"0.7368934",
"0.713005",
"0.713005",
"0.713005",
"0.70477885",
"0.6935985",
"0.6874871",
"0.68298143",
"0.67070925",
"0.6664679",
"0.6659829",
"0.6635107",
"0.6611822",
"0.65786064",
"0.65548575",
"0.652452",
"0.65240204",
"0.65226746",
"0.6458368",
"0.6449635",
... | 0.7969079 | 0 |
get the value of property _PayloadError | def PayloadError(self):
if self.force_auto_sync:
self.get('PayloadError')
return self._PayloadError | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def error(self):\n return self.get('error')",
"def error(self):\n return self['error']",
"def getError(self):\n \n return self.resp[\"error\"]",
"def error(self):\n error = self._wrapped.error\n if error:\n return error\n\n return self.json['respons... | [
"0.76542264",
"0.757172",
"0.71746737",
"0.6934536",
"0.6896672",
"0.681858",
"0.681858",
"0.681858",
"0.6786542",
"0.67611414",
"0.6738766",
"0.6734245",
"0.6712056",
"0.6648239",
"0.6543758",
"0.65139353",
"0.64743966",
"0.64743966",
"0.64743966",
"0.644765",
"0.644765",
... | 0.8170627 | 0 |
get the value of property _MaxRealtimeCaptureFrameCount | def MaxRealtimeCaptureFrameCount(self):
if self.force_auto_sync:
self.get('MaxRealtimeCaptureFrameCount')
return self._MaxRealtimeCaptureFrameCount | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def capture_limit(self):\n return self._capture_limit",
"def get(self, flag: int):\n if flag == cv2.CAP_PROP_FRAME_COUNT:\n return self.length",
"def max_fps(self):\n return self._max_fps",
"def realFrameNumber(self, callback=None):\n count = 0\n theoreticalFrameNumber =... | [
"0.73337346",
"0.6933367",
"0.69224566",
"0.68968475",
"0.6725852",
"0.6722396",
"0.6618974",
"0.63821393",
"0.6331278",
"0.6321719",
"0.6293928",
"0.6257474",
"0.6141899",
"0.611079",
"0.6071713",
"0.60681796",
"0.60611916",
"0.6054133",
"0.6043673",
"0.60153574",
"0.6012315... | 0.89010715 | 0 |
Return True if this role grants a user the given permission, else return False. | def has_permission(self, permission):
return permission in self._permissions | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def can(self, perm):\n return self.role is not None and self.role.has_permission(perm)",
"def can(self, perm):\n return self.role.has_permissions(perm)",
"def has_perm(self, user):\n return True",
"def has_permission(self, user, permission, roles=None):\n if roles is None:\n ... | [
"0.7496682",
"0.7337404",
"0.7316838",
"0.71328896",
"0.7131372",
"0.7131372",
"0.7075798",
"0.70475703",
"0.7033389",
"0.7019936",
"0.6963657",
"0.6941966",
"0.69271415",
"0.69117796",
"0.6911622",
"0.6853027",
"0.6836064",
"0.68236864",
"0.67787224",
"0.67295206",
"0.672952... | 0.6355179 | 53 |
Return the unit of measurement of this entity, if any | def unit_of_measurement(self):
if self._coordinator.data:
return self._coordinator.data['unit']
return None | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def unit_of_measurement(self):\n return self._metadata[1]",
"def unit_of_measurement(self):\n return self._tasmota_entity.unit",
"def unit_of_measurement(self):\n return self._unit",
"def unit_of_measurement(self):\n return self._unit",
"def unit_of_measurement(self):\n r... | [
"0.85816234",
"0.8490196",
"0.8466205",
"0.8466205",
"0.8466205",
"0.8466205",
"0.8466205",
"0.8466205",
"0.8466205",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.84655553",
"0.8... | 0.841988 | 23 |
Loads the train/test datasets and puts them in PyTorch dataloaders. LibriSpeechDataset uses index caching to access more rapidly the data. | def load_data(batch_size=batch_size):
trainset = LibriSpeechDataset(training_set, int(LIBRISPEECH_SAMPLING_RATE * n_seconds))
testset = LibriSpeechDataset(validation_set, int(LIBRISPEECH_SAMPLING_RATE * n_seconds), stochastic=False)
train_loader = DataLoader(trainset, batch_size=batch_size, num_workers=1, ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def loadData(self):\n batch_size = 256\n \n #if self.conv_sg == True:\n # batch_size = 1 \n \n download = True\n root = self.root + self.dataset\n if self.dataset == \"MNIST\": \n transform = transforms.Compose([transforms.ToTensor(), tra... | [
"0.7341351",
"0.7338942",
"0.7173391",
"0.71011335",
"0.70840114",
"0.69458437",
"0.68755144",
"0.6825737",
"0.6804497",
"0.68008566",
"0.6791674",
"0.6772057",
"0.6757341",
"0.67260754",
"0.67102593",
"0.67025644",
"0.6697447",
"0.66964084",
"0.6693197",
"0.6678607",
"0.6673... | 0.7453603 | 0 |
Returns the element filtered by zoom level. An input integer or float gets returned as is. An input string is checked whether it starts with "zoom". Then, the provided zoom level gets parsed and compared with the actual zoom level. If zoom levels match, the element gets returned. | def _element_at_zoom(name, element, zoom):
# If element is a dictionary, analyze subitems.
if isinstance(element, dict):
sub_elements = element
out_elements = {}
for sub_name, sub_element in sub_elements.iteritems():
out_element = _element_at_zoom(sub_name, sub_element, zoom)... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def zoom(self):\n return self['zoom']",
"def _strip_zoom(input_string, strip_string):\n element_zoom = input_string.strip(strip_string)\n try:\n return int(element_zoom)\n except:\n raise SyntaxError",
"def normalize_zoomlvl(lvl):\n if lvl < gMinZoomLevel:\n return gMinZ... | [
"0.58302087",
"0.5794801",
"0.5750986",
"0.57000405",
"0.568859",
"0.5534435",
"0.55237454",
"0.5335024",
"0.5214547",
"0.52113694",
"0.5208109",
"0.51764035",
"0.51531607",
"0.5125161",
"0.5107781",
"0.5047452",
"0.50266266",
"0.49858359",
"0.49783036",
"0.4973665",
"0.49563... | 0.76253253 | 0 |
GIVEN a Flask application WHEN the '/group/' page is requested (GET) THEN check the response is valid | def test_group_pass(client):
response = client.get('/group/group_a')
assert response.status_code == 202 | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"def test_list_group_404(self):\n resp = self.app.get('/groups/thisgroupdoesntexist')\n assert resp.status_code == 404",
"def user_should_get_an_ok_response():\n assert web_app.validate_reponse()",
"def test_request_groups_group(self):\n response = requests.get(self.url + '/groups/Human'... | [
"0.62772584",
"0.6201879",
"0.59967685",
"0.59186316",
"0.5913966",
"0.58341765",
"0.57952684",
"0.5771906",
"0.57506394",
"0.5625238",
"0.5603559",
"0.5569217",
"0.556543",
"0.5552809",
"0.55525106",
"0.5525633",
"0.5516717",
"0.5513089",
"0.5500008",
"0.5453972",
"0.5441912... | 0.6147906 | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.