text
stringlengths
190
325k
Imports: ```python import json import typing ``` Type definitions: Input Types: dict Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(v1: dict): print('Started analog in/out') while not v1['stop']: v2 = input('analog i/o prompt >>>> ') if v2 == 'q' or v2 == 'quit' or...
Imports: ```python from math import gcd import random import typing ``` Type definitions: Input Types: Any, int Output Type: (int, int) Dependencies: ```python def v0(v1: int, v2: int) -> int: if v1 == 0: return (v2, 0, 1) else: (v3, v4, v5) = v0(v2 % v1, v1) return (v3, v5 - v2 // v1 *...
Imports: ```python import torch from torch import nn import typing ``` Type definitions: Input Types: int, int, List[Tuple[int, int]], bool Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: int, v2: int, v3: List[Tuple[int, int]], v4: bool): v5 = v2 v6 = v1 / v5 v7 = to...
Imports: ```python import os import re import typing ``` Type definitions: Input Types: List[str] Output Type: int Dependencies: ```python def v0(v1: str) -> int: with open(v1) as v2: v3 = v2.readlines() v4 = 0 v5 = False v6 = 0 for (v7, v8) in enumerate(v3): if v8.endswith(' '): ...
Imports: ```python from pymatgen.core.bonds import CovalentBond, get_bond_length from pymatgen.core.composition import Composition from pymatgen.core.lattice import Lattice, get_points_in_spheres from pymatgen.core.operations import SymmOp from pymatgen.core.periodic_table import DummySpecies, Element, Species, get_el_...
Imports: ```python import typing ``` Type definitions: Input Types: int Output Type: int Dependencies: ```python def v0(v1: int, v2: int) -> int: if v1 > v2: return 0 elif v1 == v2: return 1 elif (v1, v2) in dp: return dp[v1, v2] else: v3 = max(v0(v1 + 1, v2), v0(v1, v2 ...
Imports: ```python import logging import numpy as np import numpy.ma as ma import xarray as xr from numpy.polynomial.polynomial import Polynomial from scipy import ndimage as ndi from scipy.stats import norm, zscore import typing ``` Type definitions: Input Types: xr.DataArray, xr.DataArray, int, Any, Any Output Type:...
Imports: ```python import io from PIL import Image from PIL.Image import Image as PilImage import typing ``` Type definitions: ```python class v0(NamedTuple): v1: ID_PROCESSOR v2: str v3: str v4: str ``` Input Types: list[tuple[io.BytesIO, str]], v0 Output Type: Any Dependencies: ```python def v5(v6: li...
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: List[str] Dependencies: Function Name: v0 Function: ```python def v0(v1: str) -> List[str]: v1 = v1.strip(';') if v1 == '': return (v1, None, None) v2 = v1.split(';') v3 = v2[0].split(':')[1] in ['vnode', 'vno...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self) -> None: v1 = min((expiration for (v2, v3) in self._database.values())) self._database.close() print(f'IP Cache: Created {self._created}; Expired {self._e...
Imports: ```python import typing ``` Type definitions: Input Types: asyncpg.Connection, pathlib.Path Output Type: bool Dependencies: Function Name: v0 Function: ```python async def v0(v1: asyncpg.Connection, v2: pathlib.Path) -> bool: v3 = await v1.fetchrow('SELECT * FROM migrations WHERE script_name = $1 AND que...
Imports: ```python import tensorflow as tf import typing ``` Type definitions: Input Types: Union[tf.Tensor, tf.Variable], Union[tf.Tensor, tf.Variable], Union[int, Tuple[List[int], List[int]]] Output Type: Union[tf.Tensor, tf.Variable] Dependencies: Function Name: v0 Function: ```python def v0(v1: Union[tf.Tensor, t...
Imports: ```python import typing ``` Type definitions: Input Types: int, int, line_data.Line, int, int, 'ean_data.Ean', 'ean_data.AperiodicEan', Dict[line_data.Line, int] Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: int, v2: int, v3: line_data.Line, v4: int, v5: int, v6: 'ean...
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: dict Dependencies: Function Name: v0 Function: ```python async def v0(self, v1: str, **v2) -> dict: if 'data' not in v2: v3 = {'authorization_code': self._get_default_authorization_code_request_data, 'refresh_token': self...
Imports: ```python import copy import numpy as np from pymatgen.analysis.defects.corrections import FreysoldtCorrection, KumagaiCorrection import typing ``` Type definitions: Input Types: Any, Any, bool, Any, Any, Any Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(v1, v2, v3: bool=False, ...
Imports: ```python import typing ``` Type definitions: Input Types: Any, Any, Any Output Type: str Dependencies: ```python def v0(): while _input_ready(): _next_input() ``` ```python def v1(): v2 = _next_input() while len(v2) <= _MAX_ESCAPE_SEQUENCE_LENGTH and v2 in _ESCAPE_SEQUENCES[len(v2) - 1]: ...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: list[Node.Node] Dependencies: Function Name: v0 Function: ```python def v0(self) -> list[Node.Node]: self._eat('(') v1: list[Node.Node] = self.ArgumentList() if self.lookahead.type != ')' else [] self._eat(')') return v1...
Imports: ```python from re import X import typing ``` Type definitions: Input Types: pd.DataFrame Output Type: v1 Dependencies: Function Name: v0 Function: ```python def v0(v1: pd.DataFrame) -> v1: v1 = v1.drop(v1.index[v1['floors'] <= 0]) v1 = v1.drop(v1.index[v1['sqft_lot'] <= 0]) v1 = v1.drop(v1.index[...
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: List[str] Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str) -> List[str]: v2 = [v1] v3 = v1 while v3 != self.root: v4 = self.get_parent(v3) v2.append(v4) v3 = v4 return ...
Imports: ```python import pandas as pd import typing ``` Type definitions: Input Types: Output Type: pd.DataFrame Dependencies: Function Name: v0 Function: ```python def v0(self) -> pd.DataFrame: if self.directed: return pd.DataFrame({'in_degree': dict(self.G.in_degree(weight='weight')), 'out_degree': di...
Imports: ```python from datetime import datetime, timedelta, timezone import typing ``` Type definitions: Input Types: int Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(v1: int) -> str: v2 = datetime.strptime(str(datetime.now(timezone.utc)), '%Y-%m-%d %H:%M:%S.%f%z') return str(v...
Imports: ```python import typing ``` Type definitions: Input Types: List[Dict], str Output Type: List[Dict] Dependencies: ```python async def v0(v1: str) -> str: v2 = v1.split('@')[0] v2 = ''.join((e for v3 in v2 if v3.isalnum())) v4 = await generate_random_string() return f'cm{v2}{int(time.time())}{v4...
Imports: ```python import typing ``` Type definitions: Input Types: Dict, Any Output Type: Dict Dependencies: Function Name: v0 Function: ```python def v0(v1: Dict, v2=False) -> Dict: v3 = {} for v4 in v1: if v2 and (not v1[v4]): continue if v1[v4] is not None: v3[v4] =...
Imports: ```python import math import typing ``` Type definitions: Input Types: Any Output Type: Dict Dependencies: ```python def v0(v1, v2): return int(math.ceil(float(v1) / float(v2))) ``` Function Name: v3 Function: ```python def v3(v4) -> Dict: def v5(v6, v7): return int(math.ceil(float(v6) / floa...
Imports: ```python import pandas as pd import seaborn as sns import matplotlib.pyplot as plt import numpy as np import typing ``` Type definitions: Input Types: pd.DataFrame, str, str, int, str, str, Any Output Type: Any Dependencies: ```python def v0(v1: pd.DataFrame, v2: str): return pd.Series([_w for v3 in v1[v...
Imports: ```python import sys import typing ``` Type definitions: Input Types: str Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(v1: str): v2 = '' while v2 not in ['y', 'n', 'q']: print(f'[yellow]{v1}[Y/N/Q]?[/] ', end='') v2 = input('').lower() if v2 == 'q': ...
Imports: ```python from sklearn.cluster import KMeans from sklearn.decomposition import PCA from sklearn.model_selection import train_test_split from sklearn.preprocessing import MinMaxScaler, StandardScaler import typing ``` Type definitions: Input Types: pd.DataFrame, pd.DataFrame, str Output Type: Any Dependencies:...
Imports: ```python import numpy as np import torch import torch.nn.functional as F import typing ``` Type definitions: Input Types: torch.Tensor, Union[int, float] Output Type: Any Dependencies: ```python def v0(v1: torch.Tensor) -> torch.Tensor: v2 = v1[:, 0, ...] v3 = v1[:, 1, ...] v4 = v1[:, 2, ...] ...
Imports: ```python import typing ``` Type definitions: Input Types: Dict Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: Dict): v2 = v1.get('artifacts') if v2: v3 = v2[0] v3['uri'] = self.uri v3['metadata'] = self.metadata v2 = {'artifacts'...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self) -> None: if self.units == 'celsius': self.value = (self.value / 5 * 9 + 32).__round__(2) self.units = 'fahrenheit' else: v1 = "Not a v...
Imports: ```python import json import typing ``` Type definitions: Input Types: str, dict Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str, v2: dict) -> None: v3 = f'/dp/v1/collections/{v1}?visibility=PRIVATE' v4 = {'host': 'localhost', 'Content-Type': 'application/js...
Imports: ```python import typing ``` Type definitions: Input Types: bool Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(self, v1: bool) -> str: v2 = '✅' if v1 else '❌' return v2 ```
Imports: ```python import typing ``` Type definitions: Input Types: str, str, str, dict, list Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str, v2: str=None, v3: str=None, v4: dict=None, v5: list=None): if not self.validate_list_element(v1, v2, v3, v4, v5): return ...
Imports: ```python import os import typing ``` Type definitions: Input Types: Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(self) -> str: v1 = os.read(self.fileno, 1024) if v1 == b'': self._eof = True return '' return self._stdin_decoder.decode(v1) ```
Imports: ```python import numpy as np from scipy.ndimage import maximum_filter import typing ``` Type definitions: Input Types: np.ndarray, float Output Type: np.ndarray Dependencies: Function Name: v0 Function: ```python def v0(v1: np.ndarray, v2: float) -> np.ndarray: v3 = np.ones((1, 3, 3), dtype=bool) v3[...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: bool Dependencies: Function Name: v0 Function: ```python def v0(self) -> bool: self._state = self._player.update_state() self.__update_title() return True ```
Imports: ```python import typing ``` Type definitions: ```python class v0(Model): v1: str v2: Union[str, EntitlementTypeEnum] v3: str v4: Union[str, ItemTypeEnum] v5: str v6: str v7: Union[str, StatusEnum] v8: str v9: str v10: Union[str, AppTypeEnum] v11: str v12: List[st...
Imports: ```python import numpy as np import pandas as pd import plotly.graph_objects as go import plotly.express as px import plotly.io as pio import typing ``` Type definitions: Input Types: str Output Type: Any Dependencies: ```python def v0(v1: pd.DataFrame, v2: pd.Series, v3: str='../pearson_correletions.png') ->...
Imports: ```python import numpy as np import typing ``` Type definitions: Input Types: Output Type: [int] Dependencies: Function Name: v0 Function: ```python def v0(self) -> [int]: self.session.reset() v1 = self.session.current_state() v2 = 0 (v3, v4) = self.session.is_session_end() return np.arr...
Imports: ```python import typing ``` Type definitions: Input Types: int Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: int) -> None: if v1 >= 0 and v1 <= self.max_angle: self.dev.write('PAN|{}'.format(v1)) self._ready = False self.pan_angle = v1 ...
Imports: ```python import typing ``` Type definitions: ```python class v0: def __init__(self, v1=0, v2=None, v3=None): self.val = v1 self.left = v2 self.right = v3 ``` Input Types: v0 Output Type: bool Dependencies: ```python def v4(v5): if not v5: return 0 v6 = v4(v5.left) ...
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str): self._text = v1 self._preview.setPlainText(v1) ```
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: List[str] Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str) -> List[str]: v2: List[str] = [] v3 = self.get_control(v1) if v3.controls: v4 = self._get_all_controls_in_list(v3.controls, True)...
Imports: ```python import subprocess import typing ``` Type definitions: Input Types: list Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(v1: list) -> str: v2 = subprocess.Popen(v1, stdout=subprocess.PIPE, stderr=subprocess.PIPE) (v3, v4) = v2.communicate() if v4: rais...
Imports: ```python import logging import numpy as np import threading import typing ``` Type definitions: Input Types: Dict Output Type: Dict Dependencies: Function Name: v0 Function: ```python def v0(self, v1: Dict) -> Dict: v2 = np.array(v1['predictions']) v3 = self.mask.sum(axis=1) v4 = np.empty_like(v...
Imports: ```python import typing ``` Type definitions: Input Types: Dataset Output Type: Dict[str, dict] Dependencies: Function Name: v0 Function: ```python def v0(v1: Dataset) -> Dict[str, dict]: v2: Dict[str, dict] = dict() for v3 in v1: if v3['db_id'] not in v2: v2[v3['db_id']] = {'db_t...
Imports: ```python import sys from pathlib import Path import typing ``` Type definitions: Input Types: str Output Type: Path Dependencies: Function Name: v0 Function: ```python def v0(v1: str) -> Path: try: v2 = Path(sys._MEIPASS) except Exception: v2 = Path('.') return v2.joinpath(v1) ``...
Imports: ```python import typing ``` Type definitions: Input Types: str, Any Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str, v2): del benchmark self.previous_flops = v2['flops'] ```
Imports: ```python import typing ``` Type definitions: Input Types: List[hex] Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(v1: List[hex]): v2 = v1.copy() for v3 in range(len(v2)): v2[v3] = v1[(v3 + 1) % len(v1)] return v2 ```
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: Any Dependencies: Function Name: v0 Function: ```python async def v0(self, v1: str): v2 = {'tags': ['MX warm spare settings'], 'operation': 'swapNetworkWarmspare'} v3 = f'/networks/{v1}/swapWarmSpare' return await self._s...
Imports: ```python import typing ``` Type definitions: Input Types: str, str, str, str, int Output Type: dict Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str=None, v2: str=None, v3: str=None, v4: str=None, v5: int=100) -> dict: if self.loggingEnabled: self.logger.debug(f'Starting ...
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: Tuple[str, str] Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str) -> Tuple[str, str]: if v1 is None: self._sequence = None return (None, None) v2 = self.totalLength() if len(v1) < v...
Imports: ```python import typing ``` Type definitions: Input Types: 'Address' Output Type: 'Address' Dependencies: Function Name: v0 Function: ```python def v0(self, v1: 'Address') -> 'Address': v2: 'Address' = self._node_address_mapper.get(v1) if v2 is None: v2 = self._prev_node_address_mapper.get(v1...
Imports: ```python import typing ``` Type definitions: ```python v0 = Tuple[float, float, float] ``` Input Types: v0, v0, float Output Type: v0 Dependencies: Function Name: v1 Function: ```python def v1(v2: v0, v3: v0, v4: float) -> v0: v5 = [c + (g - c) * v4 for (v6, v7) in zip(v2, v3)] return (v5[0], v5[1], ...
Imports: ```python import shutil import typing ``` Type definitions: Input Types: pathlib.Path, Any Output Type: pathlib.Path Dependencies: Function Name: v0 Function: ```python def v0(self, v1: pathlib.Path, v2=False) -> pathlib.Path: if not v1.is_dir(): raise NotADirectoryError(v1) self.update_file_...
Imports: ```python import typing ``` Type definitions: Input Types: List[str], List[str] Output Type: None Dependencies: ```python def v0(v1): print('== ' + v1 + ' ==\n') ``` Function Name: v2 Function: ```python def v2(self, v3: List[str], v4: List[str]) -> None: if self.cli_version == 'NA': return ...
Imports: ```python import typing ``` Type definitions: Input Types: Path Output Type: T.List[Path] Dependencies: Function Name: v0 Function: ```python def v0(self, v1: Path) -> T.List[Path]: v2 = [] v3 = [] for v4 in v1.iterdir(): if v4.is_dir() and v4.name.startswith('lib'): v2 += [v4...
Imports: ```python import cv2 import typing ``` Type definitions: Input Types: str Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(v1: str): v2 = cv2.imread(v1, 0) if v2 is None: raise Exception('Failed to read image') (v3, v4) = v2.shape[:2] v5 = (v4 / 2, v3 / 2) ...
Imports: ```python import numpy as np import typing ``` Type definitions: Input Types: np.ndarray, int, int Output Type: np.ndarray Dependencies: ```python def v0(v1: np.ndarray, v2: int, v3: int) -> np.ndarray: return np.array([np.roll(row, v3) if r == v2 else row for (v4, v5) in enumerate(v1)]) ``` Function Name...
Imports: ```python import typing ``` Type definitions: ```python class v0(object): def __init__(self, v1: Group, v2: [Group]): self.group = v1 self.history = v2 self.update_score() def v3(self) -> int: self.score = self.group.score(self.history) return self.score d...
Imports: ```python import pandas as pd from datasets import load_dataset from os.path import join from datasets import DatasetDict import typing ``` Type definitions: Input Types: bool Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: bool) -> None: v2 = load_dataset('KBLab/su...
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: bool Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str) -> bool: while v1 != '' and 'abc' in v1: v1 = v1.replace('abc', '') return v1 == '' ```
Imports: ```python import torch import torch.nn.functional as F import typing ``` Type definitions: ```python v0 = torch.Tensor ``` Input Types: v0, Optional[int], int, Optional[int] Output Type: v0 Dependencies: Function Name: v1 Function: ```python def v1(v2: v0, v3: Optional[int]=None, v4: int=3, v5: Optional[int]=...
Imports: ```python import typing ``` Type definitions: Input Types: ClientGUIListBoxesData.ListBoxItem Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: ClientGUIListBoxesData.ListBoxItem): v2 = self._GetNamespaceColours() v3 = v1.GetRowsOfPresentationTextsWithNamespaces(se...
Imports: ```python import typing ``` Type definitions: Input Types: float, float, bool Output Type: 'SyntheticStreetScene' Dependencies: Function Name: v0 Function: ```python def v0(self, v1: float, v2: float, v3: bool) -> 'SyntheticStreetScene': if not v3: self._set_terrain_hill_single(v1, v2) else: ...
Imports: ```python import json import typing ``` Type definitions: Input Types: List[Dict], int, str Output Type: Any Dependencies: ```python def v0(v1, v2): for v3 in range(0, len(v1), v2): yield v1[v3:v3 + v2] ``` Function Name: v4 Function: ```python def v4(v5: List[Dict], v6: int, v7: str): v8 = 0 ...
Imports: ```python from math import sqrt, pow, cos, sin, tan, atan import numpy as np import typing ``` Type definitions: Input Types: pd.DataFrame Output Type: Any Dependencies: ```python def v0(v1: bool=False): v2 = START_ORBIT_TIMESTAMP if v1: v2 = START_ARRIVAL_TIMESTAMP v3 = pendulum.parse(v2)...
Imports: ```python import typing ``` Type definitions: Input Types: Optional[Path], str, Any Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: Optional[Path], v2: str, v3: Any, **v4): if v1 is None: return None return str(v1) ```
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(self) -> str: v1 = '' for v2 in self._opts.keys(): v1 += self._opts[v2].short return v1 ```
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self) -> None: self.SetY(self.GetY() - self.GetVel()) pass 'actualizar datos' ```
Imports: ```python import os, shutil import typing ``` Type definitions: Input Types: str, str, Any Output Type: str Dependencies: ```python def v0(v1: str, v2: str) -> str: (v3, v4) = os.path.split(v1) return os.path.join(v3, v2, v4) ``` Function Name: v5 Function: ```python def v5(v6: str, v7: str=None, v8=T...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(self) -> str: v1 = self._humanized(self.indent_size, self.close_void, self.i18nInstance, self.dictionary, self.do_not_translate, self.tag_translation) if self._forma...
Imports: ```python import typing ``` Type definitions: Input Types: sqlalchemy.engine.Row Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: sqlalchemy.engine.Row) -> None: for (v2, v3) in v1.items(): self[v2] = v3 ```
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str) -> None: if not isinstance(v1, self.__class__): raise TypeError(f'The comparison expect an {self.__class__}-type and no string!') ```
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, **v1) -> None: self._series = v1['Series'] self._categories = v1['Categories'] ```
Imports: ```python import pandas as pd import typing ``` Type definitions: ```python v0 = Union[pd.Series, float] ``` Input Types: v0, Optional[float] Output Type: Any Dependencies: Function Name: v1 Function: ```python def v1(v2: v0, v3: Optional[float]): if v3 is None: v4 = v2 elif isinstance(v2, pd....
Imports: ```python import numpy as np import typing ``` Type definitions: Input Types: float Output Type: np.ndarray Dependencies: Function Name: v0 Function: ```python def v0(self, v1: float) -> np.ndarray: v2 = np.zeros([3]) if self.next: v2 = v1 * np.array(self.next.pos) + (1 - v1) * np.array(self....
Imports: ```python import ast import typing ``` Type definitions: Input Types: ast.Attribute Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: ast.Attribute) -> None: if isinstance(v1.ctx, ast.Load): self.read(v1.attr, v1) self.generic_visit(v1) ```
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(self) -> str: with open(self.path, 'w') as v1: v1.write(self.badge) return self.path ```
Imports: ```python import typing ``` Type definitions: Input Types: Mapping[str, Collection[str]] Output Type: List[str] Dependencies: Function Name: v0 Function: ```python def v0(v1: Mapping[str, Collection[str]]) -> List[str]: if v1 is None: return [f'`paasta status --service {self.service} --{self.depl...
Imports: ```python import typing ``` Type definitions: Input Types: str Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str, **v2): if self.pinfo: if self.pinfo.design: if 'reuse_setup' in v2: if v2['reuse_setup']: self....
Imports: ```python import typing ``` Type definitions: Input Types: tk.Event Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: tk.Event) -> None: v2 = self.filename_combobox.get() self.service_file_data.text.delete(1.0, 'end') self.service_file_data.text.insert('end', ...
Imports: ```python import typing ``` Type definitions: Input Types: tuple, int, int Output Type: tuple Dependencies: ```python def v0(v1: tuple, v2: tuple, v3: int) -> tuple: if v1 is None or v2 is None: return None (v4, v5) = v1 (v6, v7) = v2 if v4 == v6: return double(v1, v3) v8 =...
Imports: ```python import typing ``` Type definitions: Input Types: argparse.Namespace Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: argparse.Namespace) -> None: v2 = 0 v3 = self.main_parser while True: if v3._subparsers is None: break i...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self) -> None: self.well.colonies = [] self.assertEqual(self.well.colony_sizes, []) ```
Imports: ```python import numpy as np import typing ``` Type definitions: Input Types: np.ndarray, np.ndarray Output Type: np.float64 Dependencies: Function Name: v0 Function: ```python def v0(self, v1: np.ndarray, v2: np.ndarray) -> np.float64: (v3, v4) = (v1[:3], self.axisangle_to_qtn(v1[3:])) (v5, v6) = (v...
Imports: ```python import typing ``` Type definitions: ```python v0 = TypedDict('BranchDict', {'docker_image': str, 'git_sha': str, 'desired_state': str, 'force_bounce': Optional[str]}, total=False) ``` Input Types: str, str Output Type: v0 Dependencies: Function Name: v1 Function: ```python def v1(self, v2: str, v3: ...
Imports: ```python import typing ``` Type definitions: Input Types: Any Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(v1) -> None: if v1.resource_name != 'no_errors': v2 = v1.report_xml.find('testcase') v3 = v1.expected_xml.find('testcase') assert len(v2.find...
Imports: ```python import typing ``` Type definitions: Input Types: str, str Output Type: Any Dependencies: ```python def v0(): global _test_env if _test_env: return _test_env v1 = TestEnvironment(**DEFAULT_ENV) return v1 ``` Function Name: v2 Function: ```python def v2(v3: str, v4: str): v...
Imports: ```python import numpy as np import typing ``` Type definitions: Input Types: np.ndarray, int Output Type: np.ndarray Dependencies: Function Name: v0 Function: ```python def v0(v1: np.ndarray, v2: int=384) -> np.ndarray: (v3, v4, v5) = v1.shape v6 = -v3 % v2 v7 = -v4 % v2 (v8, v9) = (int(np.f...
Imports: ```python import numpy as np import typing ``` Type definitions: Input Types: int Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(v1: int): import numpy as np v2 = np.ones(v1) v3 = np.zeros(v1) return v2[v1 - 1] + v3[v1 - 1] ```
Imports: ```python import typing ``` Type definitions: Input Types: Optional[int], Optional[int] Output Type: dict Dependencies: Function Name: v0 Function: ```python def v0(self, v1: Optional[int]=0, v2: Optional[int]=10) -> dict: v3 = {'page': str(v1), 'size': str(v2)} return self._APIsigned(endpoint=self.t...
Imports: ```python import typing ``` Type definitions: Input Types: str | None, int | None, str | None Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1: str | None=None, v2: int | None=None, v3: str | None=None, **v4) -> None: if v2 is None: self.set_percentage(1) ...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: str Dependencies: Function Name: v0 Function: ```python def v0(self) -> str: for v1 in self: self._yieldedSentence = 0 for v2 in self._SENTENCE_RGX.finditer(v1): (v3, v4) = v2.span() v5 = v1[s...
Imports: ```python import typing ``` Type definitions: ```python class v0: def __init__(self, v1: typing.Union[str, bytes], v2: typing.Union['URL', str, RawURL], *, v3: typing.Optional[QueryParamTypes]=None, v4: typing.Optional[HeaderTypes]=None, v5: typing.Optional[CookieTypes]=None, v6: typing.Optional[RequestCo...
Imports: ```python import typing ``` Type definitions: Input Types: Output Type: Any Dependencies: Function Name: v0 Function: ```python def v0(self, **v1) -> Any: v2 = True if not self.interface.outputs: v2 = False v3 = [] v4 = list(self._run_task.interface.inputs.keys())[0] if self._run_tas...
Imports: ```python import typing ``` Type definitions: Input Types: int Output Type: None Dependencies: Function Name: v0 Function: ```python async def v0(self, *, v1: int) -> None: self.embed.description = f'{self.CODEBLOCK_START}{self.header}{self.footer}{self.CODEBLOCK_END}' self.embed.clear_fields() f...
Imports: ```python import typing ``` Type definitions: Input Types: Union[Dict[Any, Any], Any], str, Any Output Type: None Dependencies: Function Name: v0 Function: ```python async def v0(self, v1: Union[Dict[Any, Any], Any], v2: str, v3: Any) -> None: v1 = self.__convert_filter(v1) self.__ensure_dict(v1) ...
Imports: ```python import logging import typing ``` Type definitions: Input Types: Any Output Type: None Dependencies: Function Name: v0 Function: ```python def v0(self, v1) -> None: v2 = f'error content: {v1}\n' logging.error(v2, exc_info=True) ```
Imports: ```python import scipy import statsmodels.api as sm import statsmodels.formula.api as smf import typing ``` Type definitions: Input Types: Any, Any, Any Output Type: Dict Dependencies: Function Name: v0 Function: ```python def v0(self, v1, v2, v3) -> Dict: v4 = dict() v5 = smf.glm(v2, data=v1, family...