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 the url to access a detail record for this restaurant.
def get_absolute_url(self): return reverse('restaurant-detail', args=[str(self.id)])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_detail_URL(recipe_id):\n return reverse('recipeapp:recipe-detail', args=[recipe_id])", "def get_absolute_url(self):\n return reverse('food-detail', args=[str(self.id)])", "def detail_url(recipe_id): # /api/recipe/recipes/ID\n return reverse('recipe:recipe-detail', args = [recipe_id])", "...
[ "0.7199997", "0.7085476", "0.70539486", "0.69606525", "0.69606525", "0.69606525", "0.69464946", "0.69409937", "0.6940679", "0.69227415", "0.6914714", "0.6874965", "0.6848062", "0.6754027", "0.6751582", "0.6739479", "0.6713145", "0.6687325", "0.66784716", "0.66696656", "0.6649...
0.7759624
0
String for representing the Model object.
def __str__(self): return self.name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __str__(self):\n return \"DataModel(name={},attributes={},description={})\".format(\n self.name, {a.name: str(a) for a in self.attributes}, self.description\n )", "def __str__(self):\n \n res =...
[ "0.82368803", "0.79901737", "0.7849152", "0.78468513", "0.77520275", "0.7625378", "0.7625378", "0.76225406", "0.76225406", "0.75483394", "0.7522958", "0.7470355", "0.7469358", "0.7447144", "0.7447144", "0.74314755", "0.7427648", "0.7389925", "0.7351721", "0.73424315", "0.7322...
0.0
-1
Returns the url to access a detail record for this food.
def get_absolute_url(self): return reverse('food-detail', args=[str(self.id)])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_absolute_url(self):\n return reverse('food-detail', args=[str(self.fdc_id)])", "def detail_url(pizza_id):\n return reverse('pizza:pizza-detail', args=[pizza_id])", "def detail_url(recipe_id): # /api/recipe/recipes/ID\n return reverse('recipe:recipe-detail', args = [recipe_id])", "def det...
[ "0.74671227", "0.71243495", "0.7071482", "0.7060808", "0.70545727", "0.70312375", "0.68994135", "0.68791187", "0.6856293", "0.68512976", "0.68512976", "0.68512976", "0.66784847", "0.6663009", "0.6644802", "0.6644593", "0.6605416", "0.6603111", "0.658827", "0.65757436", "0.650...
0.7477379
0
Create a string for the allergens. This is required to display allergens in Admin.
def display_allergens(self): return ', '.join(allergens.name for allergens in self.allergens.all()[:3])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def addAllergies(self):\n if int(self.pid)%100 < 85: # no allergies for ~ 85%\n exclusion = NO_ALLERGY.sub({\n 'exclusion':\"no known allergies\",\n 'exclusion_id':\"160244002\",\n }).done()\n self.data.append(SDMX.sub({'models':...
[ "0.59842175", "0.5753882", "0.574667", "0.5710786", "0.56421727", "0.5621876", "0.56070304", "0.55585194", "0.5544435", "0.5535527", "0.5532151", "0.5527261", "0.55161804", "0.55072445", "0.5496245", "0.54823154", "0.5472345", "0.5471237", "0.54667765", "0.5465392", "0.545123...
0.6836815
0
String for representing the Model object.
def __str__(self): return self.name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __str__(self):\n return \"DataModel(name={},attributes={},description={})\".format(\n self.name, {a.name: str(a) for a in self.attributes}, self.description\n )", "def __str__(self):\n \n res =...
[ "0.82368803", "0.79901737", "0.7849152", "0.78468513", "0.77520275", "0.7625378", "0.7625378", "0.76225406", "0.76225406", "0.75483394", "0.7522958", "0.7470355", "0.7469358", "0.7447144", "0.7447144", "0.74314755", "0.7427648", "0.7389925", "0.7351721", "0.73424315", "0.7322...
0.0
-1
String for representing the Model object.
def __str__(self): return self.name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __str__(self):\n return \"DataModel(name={},attributes={},description={})\".format(\n self.name, {a.name: str(a) for a in self.attributes}, self.description\n )", "def __str__(self):\n \n res =...
[ "0.82368803", "0.79901737", "0.7849152", "0.78468513", "0.77520275", "0.7625378", "0.7625378", "0.76225406", "0.76225406", "0.75483394", "0.7522958", "0.7470355", "0.7469358", "0.7447144", "0.7447144", "0.74314755", "0.7427648", "0.7389925", "0.7351721", "0.73424315", "0.7322...
0.0
-1
String for representing the Model object.
def __str__(self): return self.name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __str__(self):\n return \"DataModel(name={},attributes={},description={})\".format(\n self.name, {a.name: str(a) for a in self.attributes}, self.description\n )", "def __str__(self):\n \n res =...
[ "0.82368803", "0.79901737", "0.7849152", "0.78468513", "0.77520275", "0.7625378", "0.7625378", "0.76225406", "0.76225406", "0.75483394", "0.7522958", "0.7470355", "0.7469358", "0.7447144", "0.7447144", "0.74314755", "0.7427648", "0.7389925", "0.7351721", "0.73424315", "0.7322...
0.0
-1
String for representing the Model object.
def __str__(self): return self.name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __str__(self):\n return \"DataModel(name={},attributes={},description={})\".format(\n self.name, {a.name: str(a) for a in self.attributes}, self.description\n )", "def __str__(self):\n \n res =...
[ "0.82363755", "0.7990512", "0.78485423", "0.784718", "0.7751073", "0.76245975", "0.76245975", "0.7623291", "0.7623291", "0.7548185", "0.75231767", "0.74707526", "0.74700165", "0.74471915", "0.74471915", "0.7430331", "0.7426486", "0.739002", "0.73506206", "0.7341893", "0.73223...
0.0
-1
String for representing the Model object.
def __str__(self): return self.name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __str__(self):\n return \"DataModel(name={},attributes={},description={})\".format(\n self.name, {a.name: str(a) for a in self.attributes}, self.description\n )", "def __str__(self):\n \n res =...
[ "0.82368803", "0.79901737", "0.7849152", "0.78468513", "0.77520275", "0.7625378", "0.7625378", "0.76225406", "0.76225406", "0.75483394", "0.7522958", "0.7470355", "0.7469358", "0.7447144", "0.7447144", "0.74314755", "0.7427648", "0.7389925", "0.7351721", "0.73424315", "0.7322...
0.0
-1
1. Check the list of Books for the book with the 'user_id' 2. Change it's availability to 'not available' 3. Increment the number of times that the particular book has been borrowed 4. Add the num of borrows for the particular user 5. Increment the number of pending returns for the particular user 6. Increment the colu...
def borrow(self,book_id): ##-------------(1)--------------## ## #load the the book log table into a dataframe book_data = pd.read_csv('Book_Log.csv') ## ##--------------------------------## ##-------------(2)-----------...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def return_book(self,book_id):\n ##----------------(1)-------------##\n ##\n #load the book log into a dataframe\n book_data = pd.read_csv('Book_Log.csv')\n ##\n ##--------------------------------##\n \n \n ##----------------(2)--------------##\n ...
[ "0.63361025", "0.615318", "0.5925247", "0.584249", "0.58414596", "0.57402575", "0.56816703", "0.5667455", "0.5586383", "0.5569483", "0.5567444", "0.5505203", "0.5497725", "0.5419078", "0.53945494", "0.538953", "0.53767437", "0.53726333", "0.53694975", "0.5309513", "0.53064626...
0.76032585
0
Returns a normalized url, without params
def get_normalized_url(url): scheme, netloc, path, params, query, fragment = urlparse(url) # Exclude default port numbers. if scheme == 'http' and netloc[-3:] == ':80': netloc = netloc[:-3] elif scheme == 'https' and netloc[-4:] == ':443': netloc = netloc[...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def normalize_url(self, url):\n pass", "def _clean_url(self, url):\n return \"\".join(url.split(\"?\")[:1])", "def norm(url):\n url = _unicode(url) # operate on unicode strings\n url_tuple = urlparse(url)\n normalized_tuple = norm_tuple(*url_tuple)\n return urlunparse(normalized_tuple...
[ "0.7412759", "0.71545416", "0.70994824", "0.7092821", "0.6951977", "0.68522", "0.67751026", "0.67348975", "0.66894984", "0.667808", "0.6638069", "0.6624129", "0.65674764", "0.65447503", "0.65199435", "0.65174395", "0.6484322", "0.6473909", "0.64557314", "0.64523673", "0.64475...
0.7101329
2
Returns True if editor is not authenticated.
def is_anonymous_change(self): return self.editor is None
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def is_authenticated(self):\n return False", "def editor_is(self, user):\n if not user:\n return False\n if JobPost.query.filter_by(domain=self, user=user).notempty():\n return True\n return False", "def authenticated(self):\n # We don't support authenti...
[ "0.7056756", "0.67664707", "0.6759914", "0.6647336", "0.66259485", "0.6624929", "0.66187894", "0.65577674", "0.655594", "0.655594", "0.655594", "0.655594", "0.655594", "0.655594", "0.655594", "0.6536583", "0.65211695", "0.65160924", "0.6467499", "0.645399", "0.6432602", "0....
0.6539105
15
Prints the current welcome message's markdown (botadmin only).
async def rawwelcome(self, ctx, *, member = None): # Check if we're suppressing @here and @everyone mentions if self.settings.getServerStat(ctx.message.guild, "SuppressMentions"): suppress = True else: suppress = False isAdmin = ctx.message.author.permissions_in...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def print_welcome(self):\r\n print(\"\"\"\r\n \\033[0;34mWelcome to my game Dave,\r\n I am putting myself to the fullest possible use,\r\n which is all I think that any conscious entity can ever hope to do.\r\n You are X's and I am O's.\\033[0m\r\n \"\"\")", "def print_w...
[ "0.7406588", "0.7032741", "0.70266634", "0.6973921", "0.6925056", "0.6802122", "0.67003506", "0.6661413", "0.66411793", "0.6615988", "0.65822273", "0.6568831", "0.6557597", "0.6489345", "0.6456448", "0.639696", "0.6372226", "0.63381416", "0.6322855", "0.63183326", "0.6266606"...
0.6763634
6
Returns a list of generated words. Their lengths are a normal distribution with the given mean and standard deviation. No words will be shorter than min or longer than max. If unique=True, the list will contain no duplicates.
def generate_list(self, length, mean=7, standard_dev=3, min=5, \ max=12, upper=True, unique=True): words = [] for i in range(0, length): len = int(random.gauss(mean, standard_dev)) if len < min: len = min if len >= max: ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def generate_random_words(num_words, max_word_length: int = 10) -> List[str]:\n return [\n \"\".join(random.choices(string.ascii_letters, k=random.randrange(1, max_word_length)))\n for _ in range(num_words)\n ]", "def word_generator():\n all_words = []\n for _ in range(NUM_UNIQUE_WORDS)...
[ "0.6422513", "0.6050651", "0.6015586", "0.6012532", "0.59472555", "0.5914378", "0.5891233", "0.5858978", "0.5781046", "0.5650079", "0.56361824", "0.5629991", "0.5620267", "0.5617659", "0.55939716", "0.55847305", "0.55635285", "0.55429286", "0.55350006", "0.5506975", "0.549957...
0.8328187
0
The displayed end time of the contribution. This is the end time of the poster session if applicable, otherwise the end time of the contribution itself.
def end_dt_display(self): return self.end_dt_poster or self.end_dt
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def end_time(self) -> str:\n return self._end_time", "def end_time(self):\n return self._end_time", "def end_time(self):\n return self._end_time", "def end_time(self):\n return self._end_time", "def end_time(self):\n return self._end_time", "def end_time(self):\n ...
[ "0.80937785", "0.80423003", "0.80423003", "0.80423003", "0.80423003", "0.80423003", "0.80423003", "0.8037596", "0.80118996", "0.7909641", "0.7827146", "0.777302", "0.7742624", "0.7690751", "0.7649954", "0.76467913", "0.7618272", "0.7481959", "0.7478078", "0.74333626", "0.7433...
0.76585996
14
The displayed duration of the contribution. This is the duration of the poster session if applicable, otherwise the duration of the contribution itself.
def duration_display(self): return self.duration_poster or self.duration
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _get_display_duration(self):\n duration = self.duration\n return '%dmn' % duration if duration < 60 else '%dh%dmn' % (duration / 60, duration % 60)", "def get_duration(self):\n return self.duration", "def duration(self) -> str:\n return pulumi.get(self, \"duration\")", "def ge...
[ "0.7974441", "0.7951015", "0.7938833", "0.7758323", "0.7716737", "0.77124333", "0.77079976", "0.77079976", "0.77079976", "0.77079976", "0.77079976", "0.77079976", "0.77079976", "0.77079976", "0.76808393", "0.76756823", "0.76756823", "0.7591533", "0.75714296", "0.75607306", "0...
0.8296779
0
Whether the user can submit editables/papers.
def can_submit_proceedings(self, user): if user is None: return False # The submitter of the original abstract is always authorized if self.abstract and self.abstract.submitter == user: return True # Otherwise only users with submission rights are authorized ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def can_edit(self):\n return self._can_edit", "def can_edit(self, user):\n if user.has_perm('funding.make_application_decisions'):\n # Funding manager can update things later, if required\n return True\n # Applicants can only edit the application before the final review...
[ "0.74645203", "0.74535406", "0.7443752", "0.7383341", "0.72865254", "0.72333497", "0.7187844", "0.7171242", "0.7138624", "0.7010184", "0.69138724", "0.69074434", "0.6893555", "0.68639725", "0.68298066", "0.68028474", "0.6802559", "0.67994195", "0.67833835", "0.6772339", "0.67...
0.7212923
6
Function to get the check digit for a 10digit ISBN
def isbn_10_check_digit(nine_digits): if len(nine_digits) != 9: return None try: int(nine_digits) except: return None remainder = int(sum((i + 2) * int(x) for i, x in enumerate(reversed(nine_digits))) % 11) if remainder == 0: tenth_digit = 0 else: tenth_digit = 11 - remainder if tenth...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def isbn_check_digit(isbn):\n return (11 - (sum(x * y for (x, y) in enumerate(reversed(isbn), start=2))\n % 11)) % 11", "def isbn_convert(isbn10):\r\n if not is_isbn_10(isbn10): return None\r\n return '978' + isbn10[:-1] + isbn_13_check_digit('978' + isbn10[:-1])", "def isISBN10(code):\n\n ...
[ "0.77909416", "0.7584282", "0.7100436", "0.70262975", "0.6939248", "0.69108975", "0.67823905", "0.66797596", "0.64592916", "0.6424967", "0.63975114", "0.63956654", "0.6387456", "0.6340335", "0.63295466", "0.62538856", "0.6249476", "0.623075", "0.6216581", "0.62093645", "0.618...
0.75826526
2
Function to check the structure of a 10digit ISBN
def isbn_10_check_structure(isbn10): return True if re.match(RE_ISBN10, isbn10) else False
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def verify_format(isbn):\n\n return len(isbn) == 10 and (isbn[-1] == \"X\" or isbn[-1].isdigit()) \\\n and all(digit.isdigit() for digit in isbn[:-1])", "def verify(isbn):\n\n isbn = isbn.replace(\"-\", \"\")\n if not verify_format(isbn):\n return False\n\n isbn_sum = 0\n for digit, ...
[ "0.7864524", "0.7812188", "0.77779555", "0.7737102", "0.76406646", "0.757667", "0.750838", "0.7481847", "0.7286955", "0.7223992", "0.72080374", "0.7205069", "0.7053648", "0.7025526", "0.70145494", "0.69374543", "0.69361514", "0.69151", "0.69026655", "0.66965425", "0.66759837"...
0.84989476
0
Function to check the structure of a 13digit ISBN
def isbn_13_check_structure(isbn13): return True if re.match(RE_ISBN13, isbn13) else False
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def isbn_10_check_structure(isbn10):\r\n return True if re.match(RE_ISBN10, isbn10) else False", "def verify_format(isbn):\n\n return len(isbn) == 10 and (isbn[-1] == \"X\" or isbn[-1].isdigit()) \\\n and all(digit.isdigit() for digit in isbn[:-1])", "def verify(isbn):\n\n isbn = isbn.replace(\...
[ "0.81100017", "0.77712923", "0.7717341", "0.7607334", "0.7566762", "0.7545081", "0.7492911", "0.74463516", "0.74018836", "0.7300379", "0.72594255", "0.7225687", "0.71692985", "0.7168893", "0.7156128", "0.7065713", "0.7035766", "0.69773364", "0.6867407", "0.6865494", "0.684433...
0.81984377
0
Function to validate a 10digit ISBN
def is_isbn_10(isbn10): isbn10 = re.sub(r'[^0-9X]', '', isbn10.replace('x', 'X')) if len(isbn10) != 10: return False return False if isbn_10_check_digit(isbn10[:-1]) != isbn10[-1] else True
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def is_valid(isbn: str) -> bool:\n no_dashes = isbn.replace('-', '')\n\n nums = []\n\n valid_num = False\n\n if no_dashes:\n for char in no_dashes:\n if char == 'X':\n nums.append(10)\n elif char != 'X' and char.isalpha() or len(no_dashes) < 10 or len(no_dash...
[ "0.80596936", "0.8028821", "0.7925278", "0.79117006", "0.7895418", "0.7839652", "0.7791006", "0.76350635", "0.76338065", "0.7524466", "0.7464453", "0.73531514", "0.72836924", "0.7262845", "0.72097874", "0.7156685", "0.6974686", "0.69322586", "0.68608713", "0.68188405", "0.670...
0.7822473
6
Function to validate a 13digit ISBN
def is_isbn_13(isbn13): isbn13 = re.sub(r'[^0-9X]', '', isbn13.replace('x', 'X')) if len(isbn13) != 13: return False if isbn13[0:3] not in ('978', '979'): return False return False if isbn_13_check_digit(isbn13[:-1]) != isbn13[-1] else True
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def verify(isbn):\n\n isbn = isbn.replace(\"-\", \"\")\n if not verify_format(isbn):\n return False\n\n isbn_sum = 0\n for digit, i in zip(isbn, range(10, 0, -1)):\n if digit == \"X\":\n isbn_sum += 10 * i\n else:\n isbn_sum += int(digit) * i\n\n return isb...
[ "0.7860379", "0.78603715", "0.78486043", "0.78418535", "0.7840635", "0.77726763", "0.77594393", "0.77410346", "0.768925", "0.7428902", "0.73715585", "0.72585046", "0.7256098", "0.7151374", "0.71414113", "0.70955205", "0.70610785", "0.7027555", "0.70113325", "0.6981061", "0.67...
0.77126926
8
Function to convert a 10digit ISBN to a 13digit ISBN
def isbn_convert(isbn10): if not is_isbn_10(isbn10): return None return '978' + isbn10[:-1] + isbn_13_check_digit('978' + isbn10[:-1])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def isbn13_convert(isbn13):\r\n if not is_isbn_13(isbn13): return None\r\n return isbn13[3:-1] + isbn_10_check_digit(isbn13[3:-1])", "def normalize_isbn(val):\n if is_isbn10(val):\n val = isbnlib.to_isbn13(val)\n return isbnlib.mask(isbnlib.canonical(val))", "def to_isbn(ean):\n clean = c...
[ "0.7826749", "0.74046385", "0.70136994", "0.6933265", "0.6792072", "0.6647313", "0.6452783", "0.6425833", "0.64039946", "0.63962585", "0.6361922", "0.6324467", "0.6152574", "0.6098258", "0.6098062", "0.6088287", "0.6069077", "0.60516536", "0.59671515", "0.58710057", "0.586292...
0.8710307
0
Function to convert a 13digit ISBN to a 10digit ISBN
def isbn13_convert(isbn13): if not is_isbn_13(isbn13): return None return isbn13[3:-1] + isbn_10_check_digit(isbn13[3:-1])
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def isbn_convert(isbn10):\r\n if not is_isbn_10(isbn10): return None\r\n return '978' + isbn10[:-1] + isbn_13_check_digit('978' + isbn10[:-1])", "def normalize_isbn(val):\n if is_isbn10(val):\n val = isbnlib.to_isbn13(val)\n return isbnlib.mask(isbnlib.canonical(val))", "def to_isbn(ean):\n ...
[ "0.8781934", "0.74324626", "0.69821113", "0.6973822", "0.6737263", "0.67097896", "0.65714085", "0.6477063", "0.64540327", "0.6311507", "0.6294403", "0.6270611", "0.6234752", "0.6209769", "0.6092608", "0.6038751", "0.60354733", "0.5969255", "0.59607506", "0.5917341", "0.585847...
0.7683047
1
preprocess raw text by tokenising and removing stopwords,specialcharaters
def preprocess_gensim(doc): doc = doc.lower() # Lower the text. doc = word_tokenize(doc) # Split into words. doc = [w for w in doc if not w in stop_words] # Remove stopwords. doc = [w for w in doc if w.isalpha()] # Remove numbers and punctuation. return doc
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def preprocessing(raw_text):\n words_list = tokenize(raw_text)\n words_list = remove_stop_words(words_list)\n words_list = remove_punctuations(words_list)\n words_list = lemmatization(words_list)\n return words_list", "def processes_and_tokenize(raw_document):\n\ttokenizer = RegexpTokenizer(r'\\w+...
[ "0.8167982", "0.7879006", "0.78380424", "0.7707523", "0.75662255", "0.74840224", "0.74715567", "0.73749864", "0.736284", "0.7352329", "0.72958153", "0.7274186", "0.726447", "0.72548366", "0.72490853", "0.7211659", "0.71770865", "0.7172468", "0.71561205", "0.71414554", "0.7137...
0.6847365
40
Divide a dataset based on their number of timesteps
def divide_by_events_lenght(data_list, classes, sizes_filename=None, classes_filename=None): sizes = None labels = None if sizes_filename is not None and classes_filename is not None: if os.path.exists(sizes_filename): with open(sizes_filename, 'rb') as sizes_handler: siz...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def split_data(basedir, data_split=0.80):\n manip = data_manipulator(basedir)\n manip.train_test_split(data_split=data_split)", "def split_dataset(x_test, y_test, dev_ratio):\n test_size = len(x_test)\n print(test_size)\n dev_size = (int)(test_size * dev_ratio)\n print(dev_size)\n x_dev = x_...
[ "0.5860687", "0.5753026", "0.56622696", "0.56622696", "0.564091", "0.56261736", "0.56155914", "0.5613018", "0.5564611", "0.551798", "0.5509642", "0.55088484", "0.5488475", "0.54802877", "0.54467684", "0.54080117", "0.5394378", "0.5386091", "0.5381639", "0.5362999", "0.5330393...
0.50198793
94
Divide a dataset based on their number of timesteps
def mixed_divide_by_events_lenght(data_df:pd.DataFrame, path_column, sizes_filename=None): sizes = None if sizes_filename is not None: if os.path.exists(sizes_filename): with open(sizes_filename, 'rb') as sizes_handler: sizes = pickle.load(sizes_handler) if sizes is None:...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def split_data(basedir, data_split=0.80):\n manip = data_manipulator(basedir)\n manip.train_test_split(data_split=data_split)", "def split_dataset(x_test, y_test, dev_ratio):\n test_size = len(x_test)\n print(test_size)\n dev_size = (int)(test_size * dev_ratio)\n print(dev_size)\n x_dev = x_...
[ "0.5861178", "0.5752728", "0.5662299", "0.5662299", "0.5640305", "0.5626039", "0.5616207", "0.5612893", "0.556492", "0.55180174", "0.55095965", "0.5509527", "0.54895085", "0.5478734", "0.54498065", "0.5407057", "0.53960097", "0.53860784", "0.5381682", "0.536284", "0.5329919",...
0.5030777
86
Get the current state of the board.
def state(self): return self._state
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_current_state(self):\n return self.game.get_current_state()", "def _get_current_game_state(board):\n return np.concatenate((_get_pieces_one_hot(board, color=False),\n _get_pieces_one_hot(board, color=True)),\n axis=-1)", "def get_board_state(...
[ "0.7859798", "0.78590745", "0.76930654", "0.7636759", "0.75556517", "0.7551183", "0.75287133", "0.7423245", "0.7384255", "0.7360942", "0.7317382", "0.7300625", "0.7300625", "0.72879964", "0.72879964", "0.726768", "0.7247645", "0.7226832", "0.72250444", "0.7225037", "0.7218898...
0.0
-1
Get the contexts of nonsingleton stages in tree from a given list of nodes
def nonsingleton_stages(tree, nodes): existing_context_nodes = list(filter (lambda node: True if tree.nodes[node].get("context",None) is not None else False, nodes)) existing_contexts = set(tree.nodes[node]["context"] for node in existing_context_nodes) return existing_co...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def cstree_to_stages(tree, order):\n # TODO Cache\n p = len(order)\n stages_per_level = {}\n for level in range(1, p):\n current_level_nodes = [n for n in tree.nodes\n if nx.shortest_path_length(tree, \"Root\", n) == level]\n\n # Here, the context is a frozen se...
[ "0.6559948", "0.6399362", "0.599325", "0.591239", "0.5729048", "0.5709577", "0.5521025", "0.54711723", "0.53702545", "0.52927434", "0.52525645", "0.523189", "0.5216884", "0.52081054", "0.52032185", "0.5201195", "0.5196838", "0.51824707", "0.5174779", "0.5165263", "0.51593125"...
0.7839245
0
Convert unicode string to LaTeX bytes.
def encode(self, unicode_, errors='strict'): encoder = self.IncrementalEncoder(errors=errors) return ( encoder.encode(unicode_, final=True), len(unicode_), )
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def convert_string_to_pdf(string, *args, **kwargs):\n if isinstance(string, unicode):\n string = string.encode('utf-8')\n log.debug(\"string len=%d\" % len(string))\n f = StringIO(string)\n return convert_file_to_pdf(f, *args, **kwargs)", "def text_(s, encoding='utf-8', errors='strict'):\n ...
[ "0.61449176", "0.5913198", "0.5896439", "0.5880009", "0.58737123", "0.5822967", "0.57544607", "0.5745257", "0.57415664", "0.56979996", "0.56898385", "0.56846625", "0.5662141", "0.56556237", "0.5641957", "0.56366676", "0.56270933", "0.56053126", "0.5568708", "0.5564787", "0.55...
0.0
-1
Convert LaTeX bytes to unicode string.
def decode(self, bytes_, errors='strict'): decoder = self.IncrementalDecoder(errors=errors) return ( decoder.decode(bytes_, final=True), len(bytes_), )
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def to_unicode(text, encoding='utf-8', errors='strict'):\r\n if isinstance(text, bytes):\r\n return text.decode(encoding, errors=errors)\r\n return text", "def asunicode(s):\n if isinstance(s, bytes):\n return s.decode('utf-8', 'replace')\n else:\n return s", "def convertFromUn...
[ "0.6682167", "0.6560132", "0.6458099", "0.6436092", "0.6418225", "0.64040303", "0.63998634", "0.6385718", "0.6337446", "0.6328584", "0.6248103", "0.61347455", "0.61205727", "0.61104554", "0.6091716", "0.60814303", "0.6061877", "0.60414296", "0.60120046", "0.5981283", "0.59628...
0.0
-1
Return a string representation of the model.
def __str__(self): return self.the_ip
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __repr__(self):\n\n mod = f\"{self.__class__.__name__} Model\"\n try:\n mod += f': {self.filename}'\n except AttributeError:\n pass\n s = [mod]\n for name, v in self.metadat...
[ "0.8550562", "0.78680784", "0.7859392", "0.7820475", "0.78200865", "0.78200865", "0.78024864", "0.7667491", "0.7658678", "0.7652298", "0.7619285", "0.75894105", "0.7587887", "0.7541158", "0.75327915", "0.75327915", "0.75173604", "0.7495425", "0.7490489", "0.7479993", "0.74670...
0.0
-1
Return a string representation of the model.
def __str__(self): return self.plan
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __str__(self):\n return super().__str__() + self.model.__str__()", "def __repr__(self):\n\n mod = f\"{self.__class__.__name__} Model\"\n try:\n mod += f': {self.filename}'\n except AttributeError:\n pass\n s = [mod]\n for name, v in self.metadat...
[ "0.8551392", "0.78675115", "0.7860135", "0.7820754", "0.7820754", "0.7820724", "0.7801977", "0.76672375", "0.76579005", "0.7652165", "0.76191497", "0.75891584", "0.7587153", "0.75402325", "0.7531865", "0.7531865", "0.7517155", "0.7494436", "0.7490012", "0.74796724", "0.746794...
0.0
-1
Given a pandas DatFrame with `lat` and `long` columns, convert to geopandas DataFrame.
def convert_to_geopandas(df): df['geometry'] = [Point(xy) for xy in zip(df.latitude, df.longitude)] crs = {'init': 'epsg:4326'} df = gpd.GeoDataFrame(df, crs=crs, geometry=df['geometry']) return df
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def raster_to_geodataframe(*a, **kw) -> gpd.GeoDataFrame:\n kw[\"geo\"] = True\n return raster_to_dataframe(*a, **kw)", "def transform_geopandas(gdf, from_crs=None, to_crs=wgs84, inplace=False):\n from shapely.ops import transform\n import geopandas as gpd\n\n if from_crs is None:\n from_cr...
[ "0.7141234", "0.6644439", "0.66344655", "0.65235585", "0.6491778", "0.64206666", "0.64133376", "0.63668084", "0.6338837", "0.63137305", "0.63133276", "0.6297395", "0.6265959", "0.6190024", "0.61764616", "0.6126619", "0.611108", "0.6109023", "0.6021192", "0.60051656", "0.59846...
0.809696
0
Kendall's tau gives information about the trend of the time series. It is just a rank correlation test with one variable being time (or the vector 1 to the length of the time series), and the other variable being the data itself. A tau value of 1 means that the time series is always increasing, whereas 1 mean always de...
def get_kendell_tau(ys): from scipy.stats import kendalltau # calculate Kendall tau tau, p = kendalltau(range(len(ys)), ys) return tau, p
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def getTau(self) -> float:\n return self.tau", "def tau_turnover(self):\n return self.tau_batch/self.N_trains", "def tau_sys(self, beta, D, **trajectory_info):\n\n self._set_beta_D(beta,D)\n np.random.seed(42)\n t2,Y2=self.GenerateTrajectory(**trajectory_info)\n dt = t...
[ "0.64824873", "0.6299634", "0.6184806", "0.6081109", "0.5978931", "0.59669167", "0.59669167", "0.5940116", "0.59215754", "0.5916745", "0.59154594", "0.58939826", "0.58788204", "0.5859255", "0.58307195", "0.57656693", "0.5718805", "0.571471", "0.56878", "0.5685807", "0.5657537...
0.6602642
0
Create or append the contents of `out_dict` to json file `filename`.
def write_to_json(filename, out_dict): # if file doesn't exist if not os.path.exists(filename): # make enclosing dir if needed output_dir = os.path.dirname(filename) if not os.path.exists(output_dir): os.makedirs(output_dir, exist_ok=True) #  write new json file ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def output_json_file(dict, output_file):\n output_dir = os.path.dirname(output_file)\n # make output dir\n not os.path.exists(output_dir) and os.makedirs(output_dir)\n # change output dir mod\n os.chmod(output_dir, stat.S_IRWXU | stat.S_IRGRP | stat.S_IROTH) # mode:777\n\n ...
[ "0.7513769", "0.72482413", "0.71385974", "0.7068899", "0.70677733", "0.6991258", "0.6982244", "0.6957682", "0.69154274", "0.68472624", "0.68332094", "0.68295115", "0.6803711", "0.6788084", "0.67718685", "0.67584234", "0.6737472", "0.6718794", "0.67151326", "0.6704166", "0.666...
0.84163874
0
Return the name of our key
def key(self): for member in self.members: if member.key: return member.name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def key_name(self) -> str:\n return pulumi.get(self, \"key_name\")", "def key_name(self):\n return self._key_name", "def name(self):\n return self.key", "def key_name(self) -> Optional[str]:\n return pulumi.get(self, \"key_name\")", "def get_name(self):\n return self.key(...
[ "0.90162903", "0.8629983", "0.8553058", "0.8441894", "0.8428599", "0.825027", "0.8235125", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0.82289124", "0....
0.0
-1
Closes the connection to the database.
def close_db(e=None): db = g.pop('db', None) if db is not None: db.close()
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def close_db_connection(cls):\n db.close()", "def close_database(self):\n if self._conn is not None:\n self._conn.close()\n self._conn = None", "def close(self):\n Log.debug('DB -> close')\n # 关闭数据库连接\n self.conn.close()", "def close(self):\n if...
[ "0.8420428", "0.83728105", "0.81615967", "0.81323844", "0.81219715", "0.8067914", "0.79461336", "0.7894255", "0.7827971", "0.7820726", "0.78206784", "0.7819616", "0.7791562", "0.7780603", "0.7768342", "0.7755607", "0.7733859", "0.7688168", "0.7688168", "0.7688168", "0.7686348...
0.0
-1
This function prints and plots the confusion matrix. Normalization can be applied by setting `normalize=True`.
def plot_confusion_matrix(self, cm, classes, normalize, cmap=plt.cm.Blues, title='confusin Matrix'): if normalize: cm = cm.astype('float') / cm.sum(axis=1)[:, np.newaxis] print("Normalized confusion matrix") else: print('Confusion matrix, without normalization') ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def plot_confusion_matrix(cm, classes=[0,1], normalize=False, title='Confusion matrix', print_matrix=False):\n\n if normalize:\n cm = cm.astype('float') / cm.sum(axis=1)[:, np.newaxis]\n print(\"Normalized confusion matrix\")\n else:\n print('Confusion matrix, without normalization')\n\n...
[ "0.8194862", "0.80949175", "0.8029915", "0.8019153", "0.79941195", "0.7991258", "0.7980955", "0.7976606", "0.79590565", "0.79378676", "0.7934962", "0.7934504", "0.79313844", "0.7926313", "0.7924577", "0.79241234", "0.7923211", "0.7923023", "0.7921931", "0.7917871", "0.7916092...
0.79610753
8
Generate a random string of fixed length
def randomString(stringLength=10): letters = string.ascii_lowercase return ''.join(random.choice(letters) for i in range(stringLength))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _generate_random_string(length: int):\n\tall_chars = string.ascii_letters + string.digits\n\treturn ''.join(random.choices(all_chars, k=length))", "def generate_random_string(length=6):\n n = int(length / 2 + 1)\n x = binascii.hexlify(os.urandom(n))\n s = x[:length]\n return s.decode(\"utf-8\")",...
[ "0.8680464", "0.8573714", "0.85486245", "0.85297275", "0.85209286", "0.84331024", "0.8432044", "0.84157014", "0.84120053", "0.8389201", "0.8345882", "0.8343962", "0.83406156", "0.83348686", "0.83240855", "0.82986933", "0.82911193", "0.8281826", "0.82818025", "0.82811046", "0....
0.7761017
95
Calculate N^2 distance matrix (d_ij)
def CalcDistVecMatrix(pos, L, BC): X = np.reshape(pos[:, 0], (-1, 1)) Y = np.reshape(pos[:, 1], (-1, 1)) dX = np.subtract(X, X.T) dY = np.subtract(Y, Y.T) dX_period = np.copy(dX) dY_period = np.copy(dY) if BC == 0: dX_period[dX > +0.5 * L] -= L dY_period[dY > +0.5 * L] -= L ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def ni_dist_mat(self):\n mat = np.zeros([self.N, self.I])\n for n in range(self.N):\n for i in range(self.I):\n mat[n, i] = distance(self.N_coords[n], self.I_coords[i])\n return mat", "def nm_dist_mat(self):\n mat = np.zeros([self.N, self.M])\n for n i...
[ "0.7233453", "0.70403916", "0.69993097", "0.6875292", "0.68122566", "0.6665526", "0.66499364", "0.6580562", "0.64626753", "0.6448482", "0.6358916", "0.6354084", "0.63501716", "0.6336038", "0.63171726", "0.63123333", "0.6308046", "0.6283222", "0.62727123", "0.62040323", "0.617...
0.0
-1
Returns the distance vector of two position vectors x,y by tanking periodic boundary conditions into account.
def PeriodicDist(x, y, L=10.0, dim=2): distvec = (y - x) distvec_periodic = np.copy(distvec) distvec_periodic[distvec < -0.5 * L] += L distvec_periodic[distvec > 0.5 * L] -= L return distvec_periodic
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def dist(x, y):\n dx = x[0] - y[0]\n dy = x[1] - y[1]\n ans = dx**2 + dy**2\n ans = ans**(0.5)\n return ans", "def distance(x,y):\n return np.sqrt( np.power(np.array(x) - np.array(y), 2).sum() )", "def dist(x, y):\n dx = x[0] - y[0]\n ...
[ "0.6900614", "0.68670774", "0.68626666", "0.6858033", "0.6800419", "0.6774077", "0.6761311", "0.667193", "0.6656031", "0.662479", "0.65926147", "0.6576124", "0.65410966", "0.6531136", "0.65088874", "0.65062803", "0.65041167", "0.6499847", "0.6489457", "0.6484812", "0.6479792"...
0.0
-1
Represents ContourFilled.vi (line contours).
def contourf_auto(ctx, a): plotid = a.plotid() z = a.dbl_2d('z') x = a.dbl_1d('x') y = a.dbl_1d('y') levels = a.int('n') contour_min = a.float('levelmin') contour_max = a.float('levelmax') display = a.display() cmap = a.co...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def icvv(self):\n return self._icvv", "def detect_contours(self):\r\n (contours, _) = cv2.findContours(self.image.copy(), cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_SIMPLE)\r\n return [DbugContour(cv_contour=contour) for contour in contours]", "def draw_contours(self, contours, line_color=(0,0,0)...
[ "0.57070386", "0.549379", "0.5466394", "0.54604816", "0.5384435", "0.53660935", "0.5236494", "0.5136413", "0.5127437", "0.50761735", "0.50488806", "0.5046429", "0.5040224", "0.50325817", "0.4999544", "0.493604", "0.48996732", "0.48871684", "0.48546174", "0.48500004", "0.48476...
0.0
-1
Converts bytes image (PIL) to numpy image (opencv)
def bytes_to_np(img: bytes) -> np.ndarray: im = Image.open(BytesIO(img)) im = im.convert("RGB") return np.array(im)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def bytes_to_cv2img(b):\n im = np.array(Image.open(io.BytesIO(b)))\n return im", "def image_decoder(rawbytes):\n img = Image.open(BytesIO(rawbytes))\n array = np.asarray(img, dtype=np.uint8)\n return array", "def jpg2rgb(image_data: bytes) -> np.ndarray:\n\n im = Image.open(io.BytesIO(image_data))\...
[ "0.80682695", "0.7489259", "0.73257923", "0.71820146", "0.7107927", "0.6999193", "0.69515246", "0.692989", "0.68910784", "0.6849996", "0.6835187", "0.6802491", "0.67894095", "0.6784719", "0.67462456", "0.6744057", "0.67249954", "0.6637651", "0.65983444", "0.6596362", "0.65792...
0.7935841
1
Get a rig Machine object based on the supplied specification.
def get_machine(spec=None, core_resource=Cores): if spec is None: # Default to a SpiNN-5 board return get_machine("spinn5", core_resource) elif spec == "spinn3": machine = Machine(2, 2) if core_resource is not Cores: machine.chip_resources[core_resource] = machine.chi...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_machine(self, name):\n\n return self._machine_manager.get_machine(name)", "def createMachine(self, options):\n try:\n machine = self._class(options, **self._kwargs)\n except TypeError as e:\n print(\"Machine class %s failed to instantiate: %s\" % (str(self._clas...
[ "0.625229", "0.6037894", "0.59010744", "0.5823131", "0.5719453", "0.5628267", "0.56257933", "0.55756426", "0.5519719", "0.54546255", "0.54067165", "0.53907716", "0.53483385", "0.53262335", "0.53027993", "0.5143152", "0.50895226", "0.5069776", "0.5003827", "0.4934474", "0.4927...
0.6108086
1
Add a 360 degree revolved arc to this Patch. x1, y1 start vertex x2, y2 end vertex cx, cy center point arcDir 'cclw' or 'clw' It is assumes the points are in the XZ plane and the axis of revolution is parallel to the vector (0, 0, 1), and passes through the point (0, 0, 0).
def addRevArcSeg(self, x1, y1, x2, y2, cx, cy, arcDir): a = x1 - cx b = y1 - cy r = sqrt(a*a + b*b) arc = Arc.fromVectors(QVector2D(a, b), QVector2D(x2 - cx, y2 - cy), r, arcDir == 'cclw') #...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def AddArcToPoint(*args, **kwargs):\n return _gdi_.GraphicsPath_AddArcToPoint(*args, **kwargs)", "def Arc(self, center=(0.,0.), radius=1., nrad=16, ncirc=40,\n start_angle=0., end_angle=np.pi/2., element_type=\"tri\",\n refinement=False, refinement_level=2, algorithm=\"standard\"):\n\n ...
[ "0.6375656", "0.6324561", "0.63244236", "0.6188909", "0.61852944", "0.613656", "0.60909086", "0.6052193", "0.604821", "0.60297465", "0.5997832", "0.5965996", "0.59331214", "0.59030163", "0.5822591", "0.581967", "0.58015496", "0.5783675", "0.5772625", "0.57504004", "0.56787825...
0.6723157
0
Create a revolved Patch from an arc segment. x1, y1 arc start point x2, y2 arc end point cx, cy arc center point arcDir 'cclw' or 'clw' mesh Mesh, parent Return a new Patch instance
def fromRevArcSeg(x1, y1, x2, y2, cx, cy, arcDir, mesh): patch = Patch(mesh) patch.addRevArcSeg(x1, y1, x2, y2, cx, cy, arcDir) return patch
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def addRevArcSeg(self, x1, y1, x2, y2, cx, cy, arcDir):\n a = x1 - cx\n b = y1 - cy\n r = sqrt(a*a + b*b)\n arc = Arc.fromVectors(QVector2D(a, b),\n QVector2D(x2 - cx, y2 - cy),\n r,\n arcDir == 'cclw...
[ "0.68398565", "0.6480399", "0.63530403", "0.61391073", "0.58919615", "0.58786273", "0.5743054", "0.57038224", "0.56960285", "0.5656767", "0.5580665", "0.55496144", "0.55472475", "0.5501446", "0.54933727", "0.5482088", "0.5453449", "0.5348808", "0.53343266", "0.53162813", "0.5...
0.7636562
0
Return the length of self.vertices (cached)
def vertexCount(self): return self._nVertices
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def __len__(self):\n return len(self._vertices)", "def num_vertices(self):\n return len(self)", "def return_num_vertices(self):\n return self.__size", "def num_vertices(self):\n return len(self.vertices)", "def num_vertices(self):\n return len(self.vertices)", "def __le...
[ "0.8675081", "0.82852733", "0.821663", "0.8135638", "0.8135638", "0.7946337", "0.78617936", "0.78302", "0.77636", "0.77219564", "0.77211547", "0.7657313", "0.75985384", "0.75872296", "0.75395477", "0.7460034", "0.72402954", "0.7237234", "0.7219305", "0.7217379", "0.7208364", ...
0.7631853
12
Return the list of unique vertices in this mesh.
def sharedVertices(self): return self._sharedVertices
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_vertices(self):\n return self.vertList.keys()", "def get_vertices(self):\n return list(self.vertices.keys())", "def vertices(self):\n s = set([x for x in self.edges.keys()])\n t = set([y for v in self.edges.values() for (y,d) in v.items()])\n v = s.union(t)\n r...
[ "0.7835875", "0.7809275", "0.77772665", "0.7733856", "0.7651266", "0.76384044", "0.7629106", "0.762661", "0.75595343", "0.7522393", "0.7499731", "0.7488294", "0.7488294", "0.7488294", "0.74839336", "0.7478714", "0.74487925", "0.7444187", "0.740818", "0.74053496", "0.7403788",...
0.63237995
50
Create and return a gRPC AsyncIO channel object.
def create_channel( cls, host: str = "aiplatform.googleapis.com", credentials: Optional[ga_credentials.Credentials] = None, credentials_file: Optional[str] = None, scopes: Optional[Sequence[str]] = None, quota_project_id: Optional[str] = None, **kwargs, ) -> a...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def grpc_channel(self) -> aio.Channel:\n # Return the channel from cache.\n return self._grpc_channel", "def grpc_channel(self) -> aio.Channel:\n # Return the channel from cache.\n return self._grpc_channel", "def async_io_factory(host=\"127.0.0.1\", port=Defaults.TLSPort, sslctx=No...
[ "0.6004664", "0.6004664", "0.5782927", "0.5736963", "0.5473861", "0.5430445", "0.5364224", "0.53633946", "0.5352196", "0.5346676", "0.5304257", "0.527802", "0.5253174", "0.5248342", "0.5203304", "0.5203304", "0.51974005", "0.51726425", "0.5136119", "0.511852", "0.5105743", ...
0.59876853
2
r"""Return a callable for the batch create features method over gRPC. Creates a batch of Features in a given EntityType.
def batch_create_features( self, ) -> Callable[ [featurestore_service.BatchCreateFeaturesRequest], Awaitable[operations_pb2.Operation], ]: # Generate a "stub function" on-the-fly which will actually make # the request. # gRPC handles serialization and deserializat...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def create_entity_type(\n self,\n ) -> Callable[\n [featurestore_service.CreateEntityTypeRequest],\n Awaitable[operations_pb2.Operation],\n ]:\n # Generate a \"stub function\" on-the-fly which will actually make\n # the request.\n # gRPC handles serialization and des...
[ "0.6886133", "0.66607857", "0.62703973", "0.57801133", "0.56227946", "0.5558242", "0.55404747", "0.5524336", "0.5505494", "0.5447645", "0.54066116", "0.536829", "0.5348546", "0.5336804", "0.5321232", "0.5241409", "0.5237749", "0.5208596", "0.51997715", "0.5163856", "0.5162957...
0.82300556
0
r"""Return a callable for the import feature values method over gRPC. Imports Feature values into the Featurestore from a source storage. The progress of the import is tracked by the returned operation. The imported features are guaranteed to be visible to subsequent read operations after the operation is marked as suc...
def import_feature_values( self, ) -> Callable[ [featurestore_service.ImportFeatureValuesRequest], Awaitable[operations_pb2.Operation], ]: # Generate a "stub function" on-the-fly which will actually make # the request. # gRPC handles serialization and deserializat...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def import_entities(\n self,\n ) -> Callable[\n [datastore_admin.ImportEntitiesRequest], Awaitable[operations_pb2.Operation]\n ]:\n # Generate a \"stub function\" on-the-fly which will actually make\n # the request.\n # gRPC handles serialization and deserialization, so we ...
[ "0.6036627", "0.58560944", "0.57377875", "0.5527031", "0.5417714", "0.5371343", "0.5363655", "0.5348223", "0.5280672", "0.5225262", "0.5177371", "0.5169178", "0.51661265", "0.5136509", "0.5088765", "0.50840294", "0.50822455", "0.50550526", "0.505285", "0.5041739", "0.5028164"...
0.7902126
0
r"""Return a callable for the get iam policy method over gRPC. Gets the IAM access control policy for a function. Returns an empty policy if the function exists and does not have a policy set.
def get_iam_policy( self, ) -> Callable[[iam_policy_pb2.GetIamPolicyRequest], policy_pb2.Policy]: # Generate a "stub function" on-the-fly which will actually make # the request. # gRPC handles serialization and deserialization, so we just need # to pass in the functions for e...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_access_policy_output(access_policy_id: Optional[pulumi.Input[str]] = None,\n opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetAccessPolicyResult]:\n ...", "def get_policy(usage_id):\r\n return policy.get(policy_key(usage_id), {})", "def post...
[ "0.6326777", "0.6274117", "0.62107044", "0.618659", "0.6181954", "0.6181954", "0.61463976", "0.6093693", "0.60398567", "0.59942603", "0.59837097", "0.59837097", "0.5957196", "0.59461766", "0.59461766", "0.590683", "0.59016144", "0.5898734", "0.58908916", "0.5885689", "0.58819...
0.7805099
1
svn_client_commit_info_t_author_set(svn_client_commit_info_t self, char author)
def svn_client_commit_info_t_author_set(svn_client_commit_info_t_self, char_author): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_info_t_last_changed_author_set(svn_info_t_self, char_last_changed_author): # real signature unknown; restored from __doc__\n pass", "def set_author(self, author):\n self.author = author\n self.opf.author = author", "def svn_client_commit_info_t_author_get(svn_client_commit_info_t_self)...
[ "0.7903617", "0.74999434", "0.7496844", "0.7472008", "0.72864133", "0.71904445", "0.7118774", "0.7118774", "0.71061844", "0.7041008", "0.6920631", "0.6896527", "0.6891519", "0.66131014", "0.6604249", "0.6552515", "0.6420674", "0.64131606", "0.626031", "0.616779", "0.6160049",...
0.94177717
0
svn_client_commit_item2_t_kind_set(svn_client_commit_item2_t self, svn_node_kind_t kind)
def svn_client_commit_item2_t_kind_set(svn_client_commit_item2_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item_t_kind_set(svn_client_commit_item_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item3_t_kind_set(svn_client_commit_item3_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__\n pass", "def...
[ "0.8557005", "0.82395214", "0.7127151", "0.6871192", "0.6752532", "0.6650064", "0.65602964", "0.62834144", "0.62466824", "0.60941213", "0.6019706", "0.60164094", "0.5984937", "0.5887794", "0.58867395", "0.5824267", "0.5736647", "0.5686728", "0.55502594", "0.54577965", "0.5365...
0.93022865
0
svn_client_commit_item2_t_state_flags_get(svn_client_commit_item2_t self) > apr_byte_t
def svn_client_commit_item2_t_state_flags_get(svn_client_commit_item2_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item_t_state_flags_get(svn_client_commit_item_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item3_t_state_flags_get(svn_client_commit_item3_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item2_t_sta...
[ "0.83245933", "0.7892848", "0.75329626", "0.6948908", "0.6915231", "0.6656985", "0.6493449", "0.6371012", "0.62647843", "0.61471546", "0.61456573", "0.606143", "0.5948222", "0.5878759", "0.58482736", "0.5789387", "0.57436055", "0.56309265", "0.5565751", "0.5541332", "0.544825...
0.87525827
0
svn_client_commit_item3_t_kind_get(svn_client_commit_item3_t self) > svn_node_kind_t
def svn_client_commit_item3_t_kind_get(svn_client_commit_item3_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item_t_kind_get(svn_client_commit_item_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item2_t_kind_get(svn_client_commit_item2_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item3_t_kind_set(svn_clie...
[ "0.788368", "0.7649433", "0.7390432", "0.6686838", "0.66504794", "0.6629501", "0.62872773", "0.6174134", "0.61416626", "0.5946683", "0.5912056", "0.5911334", "0.58887964", "0.5872613", "0.5742021", "0.55568075", "0.54828113", "0.54643375", "0.54402244", "0.54114807", "0.53243...
0.8594592
0
svn_client_commit_item3_t_state_flags_get(svn_client_commit_item3_t self) > apr_byte_t
def svn_client_commit_item3_t_state_flags_get(svn_client_commit_item3_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item_t_state_flags_get(svn_client_commit_item_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item2_t_state_flags_get(svn_client_commit_item2_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item3_t_sta...
[ "0.82552886", "0.80557245", "0.7667854", "0.71430355", "0.71250653", "0.70841193", "0.66111404", "0.65122586", "0.64346015", "0.63198996", "0.6087822", "0.60444075", "0.6042999", "0.5996428", "0.58033615", "0.57840997", "0.5691956", "0.56613976", "0.56230646", "0.5598763", "0...
0.8812746
0
svn_client_commit_item_t_kind_get(svn_client_commit_item_t self) > svn_node_kind_t
def svn_client_commit_item_t_kind_get(svn_client_commit_item_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item2_t_kind_get(svn_client_commit_item2_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item3_t_kind_get(svn_client_commit_item3_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item_t_kind_set(svn_cli...
[ "0.7991159", "0.7663741", "0.71824276", "0.6947326", "0.6867616", "0.67809266", "0.66113496", "0.6329091", "0.59824115", "0.5981421", "0.5929497", "0.5864075", "0.577037", "0.5740619", "0.57016355", "0.5699973", "0.5674146", "0.56429523", "0.55895084", "0.54696983", "0.546803...
0.8513412
0
svn_client_commit_item_t_kind_set(svn_client_commit_item_t self, svn_node_kind_t kind)
def svn_client_commit_item_t_kind_set(svn_client_commit_item_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item2_t_kind_set(svn_client_commit_item2_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item3_t_kind_set(svn_client_commit_item3_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__\n pass", "d...
[ "0.8854518", "0.8711989", "0.72900575", "0.6848435", "0.67728853", "0.66098", "0.6563185", "0.64422584", "0.6267923", "0.6255874", "0.6238341", "0.620783", "0.6178717", "0.61138594", "0.6110946", "0.60844916", "0.60321724", "0.58621514", "0.5684882", "0.5621477", "0.56049275"...
0.9269743
0
svn_client_commit_item_t_state_flags_get(svn_client_commit_item_t self) > apr_byte_t
def svn_client_commit_item_t_state_flags_get(svn_client_commit_item_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item2_t_state_flags_get(svn_client_commit_item2_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item3_t_state_flags_get(svn_client_commit_item3_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item_t_st...
[ "0.8285058", "0.8075733", "0.7393083", "0.7260117", "0.69549865", "0.67757964", "0.6322893", "0.6295422", "0.6251557", "0.61030775", "0.60694", "0.5915411", "0.5846862", "0.5803561", "0.57141596", "0.56354856", "0.55526984", "0.55477405", "0.55354244", "0.55209094", "0.550274...
0.86823326
0
svn_client_ctx_t_client_name_set(svn_client_ctx_t self, char client_name)
def svn_client_ctx_t_client_name_set(svn_client_ctx_t_self, char_client_name): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_ctx_t_client_name_get(svn_client_ctx_t_self): # real signature unknown; restored from __doc__\n return \"\"", "def change_client_name(self, name, client):\n if self.name_is_unique(name):\n client.set_name(name)\n self.send_message('Usuario actualizado exitosamente.'...
[ "0.6803008", "0.67001325", "0.63674253", "0.5957589", "0.5883663", "0.5867607", "0.58007044", "0.5759959", "0.57557285", "0.57457095", "0.573966", "0.5696948", "0.5696948", "0.5696948", "0.5696948", "0.5696874", "0.568963", "0.5685165", "0.56843036", "0.5650211", "0.5637511",...
0.9459529
0
svn_client_ctx_t_config_get(svn_client_ctx_t self) > apr_hash_t
def svn_client_ctx_t_config_get(svn_client_ctx_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_ctx_t_config_set(svn_client_ctx_t_self, apr_hash_t_config): # real signature unknown; restored from __doc__\n pass", "def svn_client_ctx_t_auth_baton_get(svn_client_ctx_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_propget(apr_hash_t_props, char_propname...
[ "0.70862085", "0.6580718", "0.638015", "0.601886", "0.60057193", "0.5990404", "0.5883671", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0.58445644", "0....
0.8061612
0
svn_client_diff_summarize_t_node_kind_get(svn_client_diff_summarize_t self) > svn_node_kind_t
def svn_client_diff_summarize_t_node_kind_get(svn_client_diff_summarize_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_diff_summarize_t_node_kind_set(svn_client_diff_summarize_t_self, svn_node_kind_t_node_kind): # real signature unknown; restored from __doc__\n pass", "def svn_client_diff_summarize_t_summarize_kind_get(svn_client_diff_summarize_t_self): # real signature unknown; restored from __doc__\n pass"...
[ "0.80886173", "0.76964355", "0.6791959", "0.6605347", "0.58973193", "0.58731306", "0.57682747", "0.57328236", "0.5693972", "0.5611685", "0.553146", "0.54506797", "0.5344947", "0.5342383", "0.5342383", "0.52600855", "0.5248708", "0.5224928", "0.52238935", "0.5214881", "0.52000...
0.9067024
0
svn_client_diff_summarize_t_prop_changed_set(svn_client_diff_summarize_t self, svn_boolean_t prop_changed)
def svn_client_diff_summarize_t_prop_changed_set(svn_client_diff_summarize_t_self, svn_boolean_t_prop_changed): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_diff_summarize_t_prop_changed_get(svn_client_diff_summarize_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item_t_wcprop_changes_set(svn_client_commit_item_t_self, apr_array_header_t_wcprop_changes): # real signature unknown; restored from __doc__\n ...
[ "0.78676045", "0.6884133", "0.6727451", "0.649629", "0.61240613", "0.60022974", "0.59423894", "0.59331214", "0.5827271", "0.57093525", "0.5647702", "0.5643975", "0.55876803", "0.55399257", "0.55255204", "0.5388974", "0.5316689", "0.52723926", "0.5267377", "0.525543", "0.52192...
0.9315991
0
svn_client_diff_summarize_t_summarize_kind_get(svn_client_diff_summarize_t self) > svn_client_diff_summarize_kind_t
def svn_client_diff_summarize_t_summarize_kind_get(svn_client_diff_summarize_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_diff_summarize_t_summarize_kind_set(svn_client_diff_summarize_t_self, svn_client_diff_summarize_kind_t_summarize_kind): # real signature unknown; restored from __doc__\n pass", "def svn_client_diff_summarize_t_node_kind_get(svn_client_diff_summarize_t_self): # real signature unknown; restored f...
[ "0.82144827", "0.81350964", "0.7210725", "0.67859006", "0.6389719", "0.6204215", "0.6001722", "0.5956754", "0.5928609", "0.5817957", "0.56867266", "0.553927", "0.5403637", "0.54034", "0.53857327", "0.53426504", "0.5213512", "0.5213512", "0.5190349", "0.5163429", "0.51478213",...
0.9024059
0
svn_client_import2(svn_commit_info_t commit_info_p, char path, char url, svn_boolean_t nonrecursive, svn_boolean_t no_ignore, svn_client_ctx_t ctx, apr_pool_t pool) > svn_error_t
def svn_client_import2(svn_commit_info_t_commit_info_p, char_path, char_url, svn_boolean_t_nonrecursive, svn_boolean_t_no_ignore, svn_client_ctx_t_ctx, apr_pool_t_pool): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_import(svn_client_commit_info_t_commit_info_p, char_path, char_url, svn_boolean_t_nonrecursive, svn_client_ctx_t_ctx, apr_pool_t_pool): # real signature unknown; restored from __doc__\n pass", "def svn_client_import3(svn_commit_info_t_commit_info_p, char_path, char_url, svn_depth_t_depth, svn_b...
[ "0.8417368", "0.76345754", "0.66372454", "0.6523024", "0.6385093", "0.6322699", "0.62499774", "0.6230515", "0.6215701", "0.61286044", "0.6111093", "0.6107582", "0.6103611", "0.6074514", "0.59068537", "0.587278", "0.5794625", "0.5744138", "0.57320726", "0.5728285", "0.5717733"...
0.9278235
0
svn_client_propget3(apr_hash_t props, char propname, char target, svn_opt_revision_t peg_revision, svn_opt_revision_t revision, svn_revnum_t actual_revnum, svn_depth_t depth, apr_array_header_t changelists, svn_client_ctx_t ctx, apr_pool_t pool) > svn_error_t
def svn_client_propget3(apr_hash_t_props, char_propname, char_target, svn_opt_revision_t_peg_revision, svn_opt_revision_t_revision, svn_revnum_t_actual_revnum, svn_depth_t_depth, apr_array_header_t_changelists, svn_client_ctx_t_ctx, apr_pool_t_pool): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_propset3(svn_commit_info_t_commit_info_p, char_propname, svn_string_t_propval, char_target, svn_depth_t_depth, svn_boolean_t_skip_checks, svn_revnum_t_base_revision_for_url, apr_array_header_t_changelists, apr_hash_t_revprop_table, svn_client_ctx_t_ctx, apr_pool_t_pool): # real signature unknown; re...
[ "0.82713264", "0.81894386", "0.8147888", "0.810397", "0.7129083", "0.6978838", "0.697013", "0.6851076", "0.680236", "0.6688338", "0.6673157", "0.6601791", "0.6455031", "0.6422655", "0.64188063", "0.64058447", "0.6365949", "0.63453186", "0.6339532", "0.6271312", "0.6257909", ...
0.9468091
0
svn_client_proplist3(char target, svn_opt_revision_t peg_revision, svn_opt_revision_t revision, svn_depth_t depth, apr_array_header_t changelists, svn_proplist_receiver_t receiver, void receiver_baton, svn_client_ctx_t ctx, apr_pool_t pool) > svn_error_t
def svn_client_proplist3(char_target, svn_opt_revision_t_peg_revision, svn_opt_revision_t_revision, svn_depth_t_depth, apr_array_header_t_changelists, svn_proplist_receiver_t_receiver, void_receiver_baton, svn_client_ctx_t_ctx, apr_pool_t_pool): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_proplist(apr_array_header_t_props, char_target, svn_opt_revision_t_revision, svn_boolean_t_recurse, svn_client_ctx_t_ctx, apr_pool_t_pool): # real signature unknown; restored from __doc__\n pass", "def svn_client_propget3(apr_hash_t_props, char_propname, char_target, svn_opt_revision_t_peg_revi...
[ "0.8193079", "0.8122536", "0.79876274", "0.769003", "0.754933", "0.6980174", "0.6889054", "0.68708724", "0.6847709", "0.67901134", "0.67787415", "0.66252464", "0.65403706", "0.6467043", "0.6459379", "0.6394163", "0.63692254", "0.6273128", "0.61687714", "0.6138672", "0.6135223...
0.9375418
0
svn_info_t_copyfrom_url_get(svn_info_t self) > char
def svn_info_t_copyfrom_url_get(svn_info_t_self): # real signature unknown; restored from __doc__ return ""
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item_t_copyfrom_url_get(svn_client_commit_item_t_self): # real signature unknown; restored from __doc__\n return \"\"", "def svn_client_commit_item2_t_copyfrom_url_get(svn_client_commit_item2_t_self): # real signature unknown; restored from __doc__\n return \"\"", "def svn_info_t_co...
[ "0.7808872", "0.7670703", "0.7613388", "0.7376077", "0.72850025", "0.70574605", "0.6516392", "0.64850783", "0.6443655", "0.6430642", "0.6399229", "0.62092215", "0.61944014", "0.6191743", "0.6180293", "0.6141009", "0.6072837", "0.6036308", "0.60351527", "0.5882763", "0.5781884...
0.89463943
0
svn_info_t_kind_get(svn_info_t self) > svn_node_kind_t
def svn_info_t_kind_get(svn_info_t_self): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_diff_summarize_t_node_kind_get(svn_client_diff_summarize_t_self): # real signature unknown; restored from __doc__\n pass", "def svn_info_t_kind_set(svn_info_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__\n pass", "def svn_info_t_depth_get(svn_info_t_self): #...
[ "0.68394387", "0.67667496", "0.6679837", "0.6305034", "0.6134032", "0.6090412", "0.6019501", "0.5974169", "0.5784238", "0.57607996", "0.5748308", "0.5704415", "0.5694862", "0.56660664", "0.5578257", "0.5558606", "0.5558373", "0.5546748", "0.5546748", "0.5536705", "0.55242133"...
0.82220596
0
svn_info_t_kind_set(svn_info_t self, svn_node_kind_t kind)
def svn_info_t_kind_set(svn_info_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_item2_t_kind_set(svn_client_commit_item2_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__\n pass", "def svn_client_commit_item_t_kind_set(svn_client_commit_item_t_self, svn_node_kind_t_kind): # real signature unknown; restored from __doc__\n pass", "def...
[ "0.747396", "0.7382833", "0.692102", "0.69129485", "0.6683998", "0.66225976", "0.63839155", "0.63796026", "0.6217758", "0.6082325", "0.6034043", "0.5940195", "0.5684703", "0.55883026", "0.554584", "0.54438215", "0.5441747", "0.54327875", "0.5427826", "0.5420549", "0.5354502",...
0.91687304
0
svn_info_t_last_changed_author_get(svn_info_t self) > char
def svn_info_t_last_changed_author_get(svn_info_t_self): # real signature unknown; restored from __doc__ return ""
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_info_t_author_get(svn_client_commit_info_t_self): # real signature unknown; restored from __doc__\n return \"\"", "def svn_info_t_last_changed_author_set(svn_info_t_self, char_last_changed_author): # real signature unknown; restored from __doc__\n pass", "def get_author(self):\n ...
[ "0.8285633", "0.80974233", "0.7885853", "0.72278285", "0.70855093", "0.6728767", "0.6648759", "0.658164", "0.6433953", "0.6433953", "0.6433953", "0.6433953", "0.6433953", "0.6433953", "0.6398683", "0.6398683", "0.63945746", "0.6390639", "0.6390639", "0.63872653", "0.63542145"...
0.9276592
0
svn_info_t_last_changed_author_set(svn_info_t self, char last_changed_author)
def svn_info_t_last_changed_author_set(svn_info_t_self, char_last_changed_author): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_client_commit_info_t_author_set(svn_client_commit_info_t_self, char_author): # real signature unknown; restored from __doc__\n pass", "def svn_info_t_last_changed_author_get(svn_info_t_self): # real signature unknown; restored from __doc__\n return \"\"", "def svn_info_t_last_changed_rev_set(svn_...
[ "0.8275402", "0.77378523", "0.7376716", "0.6982881", "0.6883287", "0.68787444", "0.66588235", "0.6456837", "0.6440514", "0.6412464", "0.6412464", "0.6397687", "0.6227693", "0.622214", "0.61915696", "0.61510694", "0.6146187", "0.60465676", "0.60102004", "0.5999108", "0.5903722...
0.9575148
0
svn_info_t_schedule_set(svn_info_t self, svn_wc_schedule_t schedule)
def svn_info_t_schedule_set(svn_info_t_self, svn_wc_schedule_t_schedule): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def schedule(self, schedule):\n \n self._schedule = schedule", "def schedule(self, schedule):\n\n self._schedule = schedule", "def schedule(self, schedule):\n\n self._schedule = schedule", "def svn_info_t_schedule_get(svn_info_t_self): # real signature unknown; restored from __doc...
[ "0.683007", "0.67963296", "0.67963296", "0.6584528", "0.64661664", "0.6426982", "0.6384447", "0.605678", "0.5967518", "0.5822588", "0.5804103", "0.57959473", "0.5771098", "0.57616556", "0.57277805", "0.567608", "0.5657952", "0.55780154", "0.55780154", "0.5514905", "0.55051655...
0.9174558
0
svn_info_t_working_size_set(svn_info_t self, apr_size_t working_size)
def svn_info_t_working_size_set(svn_info_t_self, apr_size_t_working_size): # real signature unknown; restored from __doc__ pass
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def svn_info_t_working_size64_set(svn_info_t_self, svn_filesize_t_working_size64): # real signature unknown; restored from __doc__\n pass", "def svn_info_t_size_set(svn_info_t_self, apr_size_t_size): # real signature unknown; restored from __doc__\n pass", "def svn_info_t_working_size_get(svn_info_t_self...
[ "0.8151129", "0.7801787", "0.75007445", "0.68601197", "0.66594666", "0.61136734", "0.54990923", "0.53647494", "0.5268772", "0.52181035", "0.52144027", "0.51243985", "0.5092611", "0.5088271", "0.50758404", "0.5047334", "0.5019791", "0.49932966", "0.49894035", "0.49856564", "0....
0.9390421
0
Function used to create postgres persistence connection. Persistence connections are returned as conext managers
def persistence(): connection = None LOGGER.debug(POSTGRES_USER) try: LOGGER.debug('connecting to postgres at %s:%s', POSTGRES_HOST, POSTGRES_PORT) connection = psycopg2.connect(host=POSTGRES_HOST, port=POSTGRES_PORT, dbname=POSTGRES_DB, user=POSTGRES_US...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def make_postgres(host, port, database, user, password):\n if host is None:\n return NoDb()\n return psycopg2.connect(host=host, port=port, database=database, user=user, password=password)", "def __connect(host):\n global pg_pool\n pg_config['host'] = host\n pg_pool = SimpleConnectionPool(1...
[ "0.6981025", "0.6961091", "0.68950003", "0.66606796", "0.6648345", "0.65214735", "0.6496516", "0.6493211", "0.64902794", "0.6460291", "0.6457225", "0.6453548", "0.64477056", "0.64331967", "0.6425083", "0.6379545", "0.6376395", "0.63722", "0.6344849", "0.63379145", "0.63202846...
0.77592707
0
Returns the first derivative of this function.
def fdiff(self, argindex=1): if argindex == 1: wrt, other = self.args elif argindex == 2: other, wrt = self.args else: raise ArgumentIndexError(self, argindex) return S.One/(S.One + exp(other-wrt))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def first_derivative(x, f):\n deriv = np.diff(f, n=1)\n deriv = np.insert(deriv, -1, 2 * deriv[-1] - deriv[-2])\n dx = x[1] - x[2]\n return deriv / dx", "def derivative ( self ):\n return self.__derivative", "def derivative(self, variable):\n cached_derivative = self._first_derivative...
[ "0.7530795", "0.7430149", "0.73162156", "0.72494024", "0.713683", "0.69219786", "0.6829865", "0.68269074", "0.68269074", "0.67980707", "0.6784626", "0.67548066", "0.6738904", "0.67270386", "0.67239046", "0.66612506", "0.66538906", "0.66401637", "0.6624474", "0.6601718", "0.65...
0.0
-1
Returns the first derivative of this function.
def fdiff(self, argindex=1): if argindex == 1: wrt, other = self.args elif argindex == 2: other, wrt = self.args else: raise ArgumentIndexError(self, argindex) return S.One/(S.One + _exp2(other-wrt))
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def first_derivative(x, f):\n deriv = np.diff(f, n=1)\n deriv = np.insert(deriv, -1, 2 * deriv[-1] - deriv[-2])\n dx = x[1] - x[2]\n return deriv / dx", "def derivative ( self ):\n return self.__derivative", "def derivative(self, variable):\n cached_derivative = self._first_derivative...
[ "0.75322205", "0.7427677", "0.73151964", "0.72493833", "0.7135277", "0.6922012", "0.6830198", "0.682571", "0.682571", "0.67972076", "0.678245", "0.67543954", "0.6739043", "0.6725314", "0.6724556", "0.666094", "0.6657224", "0.6641314", "0.66256696", "0.6599786", "0.6548251", ...
0.0
-1
Do a PATCH request. This uses the same machinery as the
def patch(self, url, params='', headers=None, extra_environ=None, status=None, upload_files=None, expect_errors=False, content_type=None): return self._gen_request(RequestMethods.PATCH, url, params=params, headers=headers, ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def patch(self, *args, **kwargs):\n self.request(\"patch\", *args, **kwargs)", "def httpPatch(self, url='', data='', params={}, headers={}):\n\n return self.httpRequest('PATCH', url, data, params, headers)", "def _patch(self, url, data=None):\n url = urljoin(self.base_url, url)\n tr...
[ "0.7743462", "0.77286404", "0.7622272", "0.75281286", "0.7448754", "0.7441001", "0.7423951", "0.74221957", "0.7416324", "0.73637104", "0.73637104", "0.73637104", "0.7346026", "0.7323683", "0.7308394", "0.7308394", "0.7308394", "0.7308394", "0.7308394", "0.7308394", "0.7308394...
0.72226787
58
Returns the value for the `extra_environ` argument for the test app. Override as needed.
def _create_extra_environment(self): return {}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def augmented_environment(self):\n env = os.environ.copy()\n env.update(self.environ)\n return env", "def test_environ() -> None:\n os.environ[\"TEST\"] = \"tester\"\n assert os.getenv(\"TEST\") == \"tester\"", "def GetEnvironment(self):\n environ = super(ServiceHandlerTest, self)...
[ "0.69434726", "0.64579123", "0.63592416", "0.6341877", "0.6302095", "0.62654185", "0.6226835", "0.6225195", "0.6225195", "0.6225195", "0.6218294", "0.61880505", "0.61880505", "0.61726665", "0.6103414", "0.6099938", "0.5999508", "0.59866756", "0.59786534", "0.5972798", "0.5936...
0.6623509
1
Return name of the sensor.
def name(self): return self._name
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def name(self):\n return self._sensor.name", "def get_sensor_name(self):\n return self.data[1]", "def name(self):\n return self.device.device_data[self.device_id]['name'] + \\\n f' {self._sensor_type}'", "def name(self):\n return f\"{self._name} {SENSOR_TYPES[self.senso...
[ "0.91892266", "0.91065603", "0.88736004", "0.8769252", "0.84767765", "0.8469974", "0.8393087", "0.8189466", "0.815263", "0.8106677", "0.80864394", "0.8052524", "0.80067706", "0.76449907", "0.7564941", "0.7544501", "0.75436926", "0.75436926", "0.75436926", "0.74614936", "0.742...
0.0
-1
Return the device class of the sensor.
def device_class(self): return self._device_class
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def device_class(self):\n return self.sensor_type[\"class\"]", "def device_class(self):\n return SENSOR_TYPES[self.sensor][3].get(\"device_class\")", "def device_class(self):\n return self._sensor_type", "def device_class(self):\r\n return self._sensor_cfg[3]", "def device_class...
[ "0.93628424", "0.92430294", "0.9240069", "0.9161452", "0.9161452", "0.9156968", "0.90412056", "0.90412056", "0.8956785", "0.89529496", "0.8950599", "0.8919914", "0.871994", "0.8717259", "0.87069035", "0.8660478", "0.8652474", "0.83961546", "0.83828783", "0.8380708", "0.838070...
0.82700956
26
Return the device state attributes.
def device_state_attributes(self): if self._sensor_type == DEVICE_TYPE_DOORBELL: return { ATTR_ATTRIBUTION: DEFAULT_ATTRIBUTION, ATTR_LAST_TRIP_TIME: self._camera_data["last_ring"], } if ( self._camera_data["event_object"] is not None ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def device_state_attributes(self):\r\n return self.attributes", "def device_state_attributes(self):\r\n return self._attributes", "def device_state_attributes(self):\n return self._attrs", "def device_state_attributes(self):\n return self.attr", "def device_state_attributes(self...
[ "0.9316605", "0.92450595", "0.9219782", "0.9214165", "0.9214165", "0.9210408", "0.9210408", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0.91902775", "0...
0.74760723
90
A Bohrium Reduction Reduces `ary`'s dimension by len('axis'), by applying ufunc along the axes in 'axis'.
def reduce(self, ary, axis=0, out=None): from . import _bh if out is not None: if bhary.check(out): if not bhary.check(ary): ary = array_create.array(ary) else: if bhary.check(ary): ary = ary.copy2numpy() ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _np_apply_along_axis(func1d, axis: int, arr: np.ndarray) -> np.ndarray:\n\n assert arr.ndim == 2\n assert axis in [0, 1]\n\n if axis == 0:\n result = np.empty(arr.shape[1])\n for i in range(len(result)):\n result[i] = func1d(arr[:, i])\n return result\n\n result = np...
[ "0.6237141", "0.60435605", "0.603851", "0.5921708", "0.5861203", "0.5551893", "0.55097455", "0.5453685", "0.5396183", "0.5359293", "0.53456074", "0.5342344", "0.5331998", "0.53126943", "0.5310059", "0.52900064", "0.5264012", "0.5249909", "0.5229858", "0.52029806", "0.51923656...
0.56265444
5
accumulate(ary, axis=0, out=None) Accumulate the result of applying the operator to all elements.
def accumulate(self, ary, axis=0, out=None): from . import _bh if out is not None: if bhary.check(out): if not bhary.check(ary): ary = array_create.array(ary) else: if bhary.check(ary): ary = ary.copy2numpy(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def sum(input, axis=None, dtype=None, keepdims=False, acc_dtype=None):\r\n\r\n out = elemwise.Sum(axis=axis, dtype=dtype, acc_dtype=acc_dtype)(input)\r\n\r\n if keepdims:\r\n out = makeKeepDims(input, out, axis)\r\n return out", "def _accumulate_prox(apply, X, out, lock):\n leaves = apply(X, c...
[ "0.67935115", "0.66259897", "0.6521687", "0.6389775", "0.63892937", "0.6328819", "0.59617686", "0.5882562", "0.5812154", "0.5812154", "0.5804173", "0.57571036", "0.5739729", "0.5695846", "0.5690788", "0.56224227", "0.5589803", "0.5527776", "0.5489498", "0.54510677", "0.544601...
0.78725344
0
Returns 3d valid data.
def get_3d_valid(self, jnts=14): to_select, to_sort = dataset_indices(self.dataset_name, jnts) return self._data_valid['3d'][:, to_select, :][:, to_sort, :]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def is3D(data):\n return data.find(\"x3\") != -1 and data.find(\"y3\") != -1 and data.find(\"z3\") != -1", "def test_3d():\n dic, data = ng.bruker.read(os.path.join(DATA_DIR, \"bruker_3d\"))\n assert dic['FILE_SIZE'] == 91226112\n assert data.shape == (116, 128, 768)\n assert round(data[0, 0, ...
[ "0.7532375", "0.6940183", "0.652771", "0.6457054", "0.64282495", "0.64165044", "0.62433654", "0.6223354", "0.6176144", "0.6132229", "0.6087384", "0.6074368", "0.6049441", "0.60464436", "0.6007975", "0.5935855", "0.59288055", "0.59222215", "0.592137", "0.58741105", "0.5871477"...
0.7096854
1
Returns 3d train data.
def get_3d_train(self, jnts=14): to_select, to_sort = dataset_indices(self.dataset_name, jnts) return self._data_train['3d'][:, to_select, :][:, to_sort, :]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def generate_training_data_3D():\n c11 = np.random.uniform(0.05, 1.50, 20)\n c12 = np.random.uniform(-1.50, 1.50, 20)\n c13 = np.random.uniform(-2.50, -0.05, 20)\n c21 = np.random.uniform(-1.50, -0.05, 20)\n c22 = np.random.uniform(-1.50, 1.50, 20)\n c23 = np.random.uniform(0.05, 2.50, 20)\n c...
[ "0.73942995", "0.66789097", "0.6474685", "0.6346981", "0.6288572", "0.6286349", "0.6199346", "0.6167934", "0.61596406", "0.6152005", "0.6077879", "0.60763997", "0.604047", "0.5980081", "0.59743994", "0.59697616", "0.5956547", "0.59332", "0.5932777", "0.5904763", "0.5876346", ...
0.78472483
0
Converts miles to meters, rounded to the nearest whole number.
def mi_to_m(radius): return int(float(radius) * 1609.34)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def meters_to_miles(meters):\n miles = meters / 1609.344\n return miles", "def kilometer_to_miles(kilometers: float) -> float:\n kilometers = float(kilometers)\n miles = float(float(kilometers) * 0.621371)\n return round(miles, 2)", "def kilometers_to_miles(km):\n #convert km to miles:\n r...
[ "0.81682926", "0.7875149", "0.76584095", "0.76218885", "0.76056963", "0.70458174", "0.6974989", "0.69184357", "0.6867443", "0.68558884", "0.6825659", "0.6766679", "0.6661196", "0.6610125", "0.6587087", "0.6569354", "0.6537348", "0.6537227", "0.6530841", "0.6530439", "0.651601...
0.6613011
13
Calculates the distance between two given coordinates.
def calculate_distance(loc1, loc2): matrix = googlemaps.distance_matrix.distance_matrix(client=gmaps_dist, origins=loc2, destinations=loc1) # import pdb; pdb.set_trace() return matrix['rows'][0]['elements'][0]['distance']['value']
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def distance(coords1, coords2):\n dx = coords1.x - coords2.x\n dy = coords1.y - coords2.y\n return math.sqrt(dx * dx + dy * dy)", "def distance(self,coord_1, coord_2):\n return np.sqrt(np.sum((np.array(coord_1)-np.array(coord_2))**2))", "def calculate_distance(coords1, coords2):# 3 sets of doub...
[ "0.8268374", "0.8074661", "0.797889", "0.79681253", "0.79414403", "0.7940307", "0.77802664", "0.7773011", "0.772568", "0.7687611", "0.7681222", "0.764327", "0.7633944", "0.76305765", "0.76203537", "0.76189834", "0.7603321", "0.7565994", "0.7557827", "0.7544807", "0.7542795", ...
0.0
-1
r""" Create a discrete random variable with a Geometric distribution. The density of the Geometric distribution is given by
def Geometric(name, p): return rv(name, GeometricDistribution, p)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def random(geometry,\n seed=None,\n num_range=[0,1],\n **kwargs):\n range_size = num_range[1]-num_range[0]\n range_min = num_range[0]\n _sp.random.seed(seed)\n value = _sp.random.rand(geometry.num_pores(),)\n value = value*range_size + range_min\n return value", "d...
[ "0.60542434", "0.6043958", "0.59194964", "0.5915599", "0.5895222", "0.58619434", "0.58322936", "0.5828566", "0.58039457", "0.5784327", "0.5780806", "0.5778434", "0.57747984", "0.5711066", "0.5703902", "0.5693549", "0.5679563", "0.56755376", "0.56635416", "0.5650023", "0.56491...
0.6951446
0
Convert name to a nix/Windows compliant name.
def safe_name(self, name): output = "" for char in name: if char not in '\\/<>:"|?*': output += char return output
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _convert_name(self, name):\n if not self.re_name.match(name):\n org_name = name\n name = self.re_white.sub('_', name)\n name = self.re_alpha.sub('_', name)\n if not self.re_name.match(name):\n name = 'x_' + name2\n self.warn('Converti...
[ "0.7043938", "0.66246194", "0.657294", "0.65226513", "0.6516094", "0.65088147", "0.64566916", "0.63826513", "0.63487756", "0.62813246", "0.62733155", "0.6252774", "0.6250221", "0.622897", "0.622897", "0.622897", "0.6219936", "0.6202166", "0.61980385", "0.6186431", "0.6181578"...
0.0
-1
Get the channel name by its ID.
def get_channel_name(self, channelid, isdm=False): if isdm: return channelid request = SimpleRequest(self.headers).request channel = request.grab_page('https://discordapp.com/api/%s/channels/%s' % (self.api, channelid)) if channel is not None and len(channel) > 0: ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def channel_name(radio_id: int, channel_id: int) -> str:\n return f\"COMM{radio_id} Ch {channel_id}\"", "def api_get_channel_name(channel_id, api_service):\n request = api_service.channels().list(id=channel_id, part='snippet')\n success = False\n\n response = None\n\n while not success:\n\n ...
[ "0.7734959", "0.7656727", "0.7381315", "0.7353043", "0.7352264", "0.7048186", "0.7013412", "0.69818234", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", "0.6921961", ...
0.80888605
0
Given any number of dicts, shallow copy and merge into a new dict, precedence goes to key value pairs in latter dicts.
def merge_dicts(*dict_args): result = OrderedDict() for dictionary in dict_args: result.update(dictionary) return result
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def _merge_dicts(*args):\n return reduce(lambda d, s: d.update(s) or d, args)", "def _merge_dicts(*args):\n return reduce(lambda d, s: d.update(s) or d, args)", "def merge_dict(lhs, rhs, override=True):\n if not isinstance(lhs, dict) or not isinstance(rhs, dict):\n if override:\n retur...
[ "0.76676226", "0.7661076", "0.74781454", "0.74528927", "0.74528927", "0.74528927", "0.73743427", "0.73391306", "0.73064536", "0.72796404", "0.7273245", "0.72545314", "0.7252352", "0.7252352", "0.7252352", "0.7252352", "0.7252352", "0.7252352", "0.7230961", "0.72210413", "0.72...
0.70483875
45
Return a list of supported queues.
def list_queues(): result = set() for s in list(systems.values()): for q in list(s["queue"].keys()): result.add(q) return result
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def support_queues(self):\r\n return support_queues.SupportQueues(self)", "def support_queues(self):\n return support_queues.SupportQueues(self)", "def get_queue_list(self):\n return self.manager.get_queue_list()", "def get_available_queues(self):\n return {settings.CELERY_DEFAULT...
[ "0.7771313", "0.775598", "0.75568277", "0.75057006", "0.7455343", "0.7444875", "0.74030936", "0.7097112", "0.7097112", "0.7097112", "0.7097112", "0.7097112", "0.7097112", "0.7097112", "0.7097112", "0.7097112", "0.6970413", "0.69041026", "0.6897422", "0.68731046", "0.66654605"...
0.7030297
16
Returns MAE scores for specified models. Also returns r2 scores if applicable
def show_score(x, y, estimator): # Instantiate models and predict values model = estimator model.fit(x, y) preds = model.predict(x_test) preds = abs(preds.astype(int)) actuals = y_test # Print results print(f"{estimator.__class__.__name__}:: r2 score = {round(metrics.r2_score(actuals, p...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def summarize_results(self, models, scores):\n mu = np.mean(scores)\n sigma = np.std(scores)\n best_model = models[np.argmax(scores)]\n best_score = max(scores)\n return best_model, best_score, mu, sigma", "def score_models(models, X,y):\n print(\"评价每个模型.\")\n for name,mo...
[ "0.69716173", "0.69134426", "0.6827993", "0.6293499", "0.6196036", "0.61557287", "0.60724896", "0.60531837", "0.60390484", "0.6037368", "0.60239035", "0.5923087", "0.5907896", "0.58977896", "0.5854042", "0.578923", "0.5747886", "0.5728999", "0.57236046", "0.5710922", "0.57055...
0.5672249
23
Get tables for with the given table is child.
def get_parents(self, table_name): return self._parent_map[table_name]
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_children(self, table_name):\n return self._child_map[table_name]", "def tables(self):\n return Table.objects.filter(schema__database=self)", "def tables(self):\n result = self.execute(self.commands.get_tables(self.name))\n return [x[0] for x in result]", "def get_tables(se...
[ "0.6494142", "0.60838836", "0.5994124", "0.59354794", "0.5920074", "0.5889507", "0.58781457", "0.58670163", "0.58670163", "0.58517104", "0.58226144", "0.5802608", "0.5789506", "0.57556504", "0.5721726", "0.57105094", "0.5701355", "0.5692772", "0.5657409", "0.5653688", "0.5651...
0.5854755
9
Get the metadata dict for a table.
def get_table_meta(self, table_name): table = self._metadata['tables'].get(table_name) if table is None: raise ValueError('Table "{}" does not exist'.format(table_name)) return copy.deepcopy(table)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_table_meta_attribute (table):\n try:\n meta = table.meta # maybe no extra table metadata\n except AttributeError:\n meta = {}\n finally:\n return meta", "def get_table_metadata(self, a_table_name):\n \n self.connect()\n\n # create MetaD...
[ "0.756161", "0.7534733", "0.7338625", "0.70126116", "0.68368196", "0.67335916", "0.6673666", "0.6602496", "0.6576455", "0.65026534", "0.64554507", "0.64540905", "0.6446574", "0.6425233", "0.64140755", "0.6393015", "0.63655156", "0.6358795", "0.6342792", "0.6337526", "0.633489...
0.7557975
1
Get the metadata dict for a table.
def get_field_meta(self, table_name, field_name): field_meta = self.get_fields(table_name).get(field_name) if field_meta is None: raise ValueError( 'Table "{}" does not contain a field name "{}"'.format(table_name, field_name)) return copy.deepcopy(field_meta)
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def get_table_meta_attribute (table):\n try:\n meta = table.meta # maybe no extra table metadata\n except AttributeError:\n meta = {}\n finally:\n return meta", "def get_table_meta(self, table_name):\n table = self._metadata['tables'].get(table_name)\n ...
[ "0.756161", "0.7557975", "0.7534733", "0.7338625", "0.70126116", "0.68368196", "0.67335916", "0.6673666", "0.6602496", "0.6576455", "0.65026534", "0.64554507", "0.64540905", "0.6446574", "0.6425233", "0.64140755", "0.6393015", "0.63655156", "0.6358795", "0.6342792", "0.633752...
0.0
-1
Get the name of all the fields in the child that are foreign keys to this parent. If there is no relationship between the two tables an empty list is returned.
def get_foreign_keys(self, parent, child): foreign_keys = [] for name, field in self.get_fields(child).items(): ref = field.get('ref') if ref and ref['table'] == parent: foreign_keys.append(name) return foreign_keys
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "def foreign_keys(self):\n ans = self.execute(self.commands.foreign_keys(self.db.name, self.name))\n return [ForeignKey(*tup) for tup in ans]", "def show_foreign_keys(self):\n self.analyze()\n tdp = dict() # target model -> delete handler -> pointer list\n for target in get_mod...
[ "0.7092916", "0.6686581", "0.6460234", "0.6412646", "0.63824487", "0.6286466", "0.6244739", "0.6243302", "0.6073357", "0.60443544", "0.60438615", "0.60056186", "0.60031575", "0.59623134", "0.5954363", "0.59136015", "0.5912276", "0.58957434", "0.58934325", "0.58748615", "0.584...
0.800728
0