text
stringlengths
78
104k
score
float64
0
0.18
def ui_extensions(self): """ Provides access to UI extensions management methods. API reference: https://www.contentful.com/developers/docs/references/content-management-api/#/reference/ui-extensions :return: :class:`EnvironmentUIExtensionsProxy <contentful_management.ui_extensions_pro...
0.008499
def import_settings_class(setting_name): """ Return the class pointed to be an app setting variable. """ config_value = getattr(settings, setting_name) if config_value is None: raise ImproperlyConfigured("Required setting not found: {0}".format(setting_name)) return import_class(config_...
0.005882
def from_intervals(cls, intervals): """ :rtype : Node """ if not intervals: return None node = Node() node = node.init_from_sorted(sorted(intervals)) return node
0.008734
def pull(self, images, file_name=None, save=True, **kwargs): '''pull an image from a s3 storage Parameters ========== images: refers to the uri given by the user to pull in the format <collection>/<namespace>. You should have an API that is able to retrieve a container bas...
0.007492
def createGroup(self, message, user_ids): """ Creates a group with the given ids :param message: The initial message :param user_ids: A list of users to create the group with. :return: ID of the new group :raises: FBchatException if request failed """ dat...
0.003378
def touch(args): """ find . -type l | %prog touch Linux commands `touch` wouldn't modify mtime for links, this script can. Use find to pipe in all the symlinks. """ p = OptionParser(touch.__doc__) opts, args = p.parse_args(args) fp = sys.stdin for link_name in fp: link_name...
0.001887
def get_last(self, num=10): """Returns last `num` of HN stories Downloads all the HN articles and returns them as Item objects Returns: `list` object containing ids of HN stories. """ max_item = self.get_max_item() urls = [urljoin(self.item_url, F"{i}.json"...
0.004219
def execute_django(self, soql, args=()): """ Fixed execute for queries coming from Django query compilers """ response = None sqltype = soql.split(None, 1)[0].upper() if isinstance(self.query, subqueries.InsertQuery): response = self.execute_insert(self.query)...
0.002979
def clean(self): """ Verifiy that the values entered into the two password fields match. Note that an error here will end up in ``non_field_errors()`` because it doesn't apply to a single field. """ if 'dob_day' in self.cleaned_data and 'dob_month' in \ ...
0.00533
def get_lambda_function_versions(self, function_name): """ Simply returns the versions available for a Lambda function, given a function name. """ try: response = self.lambda_client.list_versions_by_function( FunctionName=function_name ) ...
0.007389
def add_delta_deltas(filterbanks, name=None): """Compute time first and second-order derivative channels. Args: filterbanks: float32 tensor with shape [batch_size, len, num_bins, 1] name: scope name Returns: float32 tensor with shape [batch_size, len, num_bins, 3] """ delta_filter = np.array([2,...
0.011848
def FindPosition(node, addition, index=0): ''' Method to search for children according to their position in list. Similar functionality to above method, except this is for adding items to the tree according to the nodes limits on children or types of children they can have :param node: current node bein...
0.001707
def request_name(self): """Generate the name of the request.""" if self.static and not self.uses_request: return 'Empty' if not self.uses_request: return None if isinstance(self.uses_request, str): return self.uses_request return to_camel_ca...
0.005797
def _lower(string): """Custom lower string function. Examples: FooBar -> foo_bar """ if not string: return "" new_string = [string[0].lower()] for char in string[1:]: if char.isupper(): new_string.append("_") new_string.append(char.lower()) retur...
0.002933
def fetch_data(self, **var): """Retrieve data from CDMRemote for one or more variables.""" varstr = ','.join(name + self._convert_indices(ind) for name, ind in var.items()) query = self.query().add_query_parameter(req='data', var=varstr) return self._fetch(query...
0.006231
def load_config(paths=DEFAULT_CONFIG_PATHS): """Attempt to load config from paths, in order. Args: paths (List[string]): list of paths to python files Return: Config: loaded config """ config = Config() for path in paths: if os.path.isfile(path): config.load...
0.002841
def init_app(self, app): """This callback can be used to initialize an application for use with the OpenERP server. """ app.config.setdefault('OPENERP_SERVER', 'http://localhost:8069') app.config.setdefault('OPENERP_DATABASE', 'openerp') app.config.setdefault('OPENERP_DEF...
0.002384
def retrieve_files(): """Get list of files found in provided locations. Search through the paths provided to find files for processing. :returns: absolute path of filename :rtype: list """ all_files = [] for location in cfg.CONF.locations or []: # if local path then make sure it i...
0.001074
def S4U2self(self, user_to_impersonate, supp_enc_methods = [EncryptionType.DES_CBC_CRC,EncryptionType.DES_CBC_MD4,EncryptionType.DES_CBC_MD5,EncryptionType.DES3_CBC_SHA1,EncryptionType.ARCFOUR_HMAC_MD5,EncryptionType.AES256_CTS_HMAC_SHA1_96,EncryptionType.AES128_CTS_HMAC_SHA1_96]): #def S4U2self(self, user_to_imperson...
0.035565
def str_on_2_unicode_on_3(s): """ argparse is way too awesome when doing repr() on choices when printing usage :param s: str or unicode :return: str on 2, unicode on 3 """ if not PY3: return str(s) else: # 3+ if not isinstance(s, str): return str(s, encoding="u...
0.005831
def batched_index_select(target: torch.Tensor, indices: torch.LongTensor, flattened_indices: Optional[torch.LongTensor] = None) -> torch.Tensor: """ The given ``indices`` of size ``(batch_size, d_1, ..., d_n)`` indexes into the sequence dimension (dimension ...
0.006369
def has_sample(self, md5): """Checks if data store has this sample. Args: md5: The md5 digest of the required sample. Returns: True if sample with this md5 is present, else False. """ # The easiest thing is to simply get the sample and if that #...
0.004505
def command_repo_list(self): """Repositories list """ if len(self.args) == 1 and self.args[0] == "repo-list": RepoList().repos() else: usage("")
0.01
def register_fetcher(self, ctx_fetcher): """ Register another context-specialized fetcher :param Callable ctx_fetcher: A callable that will return the id or raise ExecutedOutsideContext if it was executed outside its context """ if ctx_fetcher not in self.ctx_fetchers: ...
0.008152
def cc_to_local_params(pitch, radius, oligo): """Returns local parameters for an oligomeric assembly. Parameters ---------- pitch : float Pitch of assembly radius : float Radius of assembly oligo : int Oligomeric state of assembly Returns ------- pitchloc : ...
0.001248
def convert_libraries_in_path(config_path, lib_path, target_path=None): """ This function resaves all libraries found at the spcified path :param lib_path: the path to look for libraries :return: """ for lib in os.listdir(lib_path): if os.path.isdir(os.path.join(lib_path, lib)) and not '...
0.005975
def collapse_umi(in_file): """collapse reads using UMI tags""" keep = defaultdict(dict) with open_fastq(in_file) as handle: for line in handle: if line.startswith("@"): m = re.search('UMI_([ATGC]*)', line.strip()) umis = m.group(0) seq = ha...
0.001395
def raw(self): """ Red, green, and blue components of the detected color, as a tuple. Officially in the range 0-1020 but the values returned will never be that high. We do not yet know why the values returned are low, but pointing the color sensor at a well lit sheet of ...
0.006932
def GetKeyByPath(self, key_path): """Retrieves the key for a specific path. Args: key_path (str): Windows Registry key path. Returns: WinRegistryKey: Windows Registry key or None if not available. Raises: RuntimeError: if the root key is not supported. """ root_key_path, _, ...
0.004044
def add_event(request): """ Public form to add an event. """ form = AddEventForm(request.POST or None) if form.is_valid(): instance = form.save(commit=False) instance.sites = settings.SITE_ID instance.submitted_by = request.user instance.approved = True instance.slug ...
0.001618
def _ensure_directory_exists(self, directory): """Ensure that the passed path exists.""" if not os.path.lexists(directory): os.makedirs(directory) return directory
0.01005
def get_security_group_id(name='', env='', region=''): """Get a security group ID. Args: name (str): Security Group name to find. env (str): Deployment environment to search. region (str): AWS Region to search. Returns: str: ID of Security Group, e.g. sg-xxxx. Raises: ...
0.001838
def handle(self, object, *args, **kw): ''' Calls each plugin in this PluginSet with the specified object, arguments, and keywords in the standard group plugin order. The return value from each successive invoked plugin is passed as the first parameter to the next plugin. The final return value is th...
0.004785
def authenticate(self, login=None, password=None): ''' Authenticated this client instance. ``login`` and ``password`` default to the environment variables ``MS_LOGIN`` and ``MS_PASSWD`` respectively. :param login: Email address associated with a microsoft account :para...
0.001196
def genExampleStar(binaryLetter='', heirarchy=True): """ generates example star, if binaryLetter is true creates a parent binary object, if heirarchy is true will create a system and link everything up """ starPar = StarParameters() starPar.addParam('age', '7.6') starPar.addParam('magB', '9.8')...
0.002992
def ics2task(): """Command line tool to convert from iCalendar to Taskwarrior""" from argparse import ArgumentParser, FileType from sys import stdin parser = ArgumentParser(description='Converter from iCalendar to Taskwarrior syntax.') parser.add_argument('infile', nargs='?', type=FileType('r'), de...
0.004255
def configure(self, mount_point, mfa_type='duo', force=False): """Configure MFA for a supported method. This endpoint allows you to turn on multi-factor authentication with a given backend. Currently only Duo is supported. Supported methods: POST: /auth/{mount_point}/mfa_co...
0.004142
def transform_member(self, node, results): """Transform for imports of specific module elements. Replaces the module to be imported from with the appropriate new module. """ mod_member = results.get("mod_member") pref = mod_member.prefix member = results.get...
0.000934
def _islice(self, min_pos, min_idx, max_pos, max_idx, reverse): """ Returns an iterator that slices `self` using two index pairs, `(min_pos, min_idx)` and `(max_pos, max_idx)`; the first inclusive and the latter exclusive. See `_pos` for details on how an index is converted to an...
0.001306
def cwd_decorator(func): """ decorator to change cwd to directory containing rst for this function """ def wrapper(*args, **kw): cur_dir = os.getcwd() found = False for arg in sys.argv: if arg.endswith(".rst"): found = arg break ...
0.001852
def MoveCursorToInnerPos(self, x: int = None, y: int = None, ratioX: float = 0.5, ratioY: float = 0.5, simulateMove: bool = True) -> tuple: """ Move cursor to control's internal position, default to center. x: int, if < 0, move to self.BoundingRectangle.right + x, if not None, ignore ratioX. ...
0.005638
def addExpression(self, datafields): """ Adds an Expression to the db. Datafields is a tuple in the order: id, rna_quantification_id, name, expression, is_normalized, raw_read_count, score, units, conf_low, conf_hi """ self._expressionValueList.append(datafields) ...
0.004854
def start(self, start_loop=True): """ Start a producer/consumer service """ txaio.start_logging() runner = self.setup_runner() if start_loop: try: runner.run(Component) except EventifyHandlerInitializationFailed as initError: ...
0.004103
def adjustStyleSheet( self ): """ Adjusts the stylesheet for this widget based on whether it has a \ corner radius and/or icon. """ radius = self.cornerRadius() icon = self.icon() if not self.objectName(): self.setStyleSheet('') ...
0.016746
def do_files_exist(filenames): """Whether any of the filenames exist.""" preexisting = [tf.io.gfile.exists(f) for f in filenames] return any(preexisting)
0.025157
def delete(self, event): """Delete an existing object""" try: data, schema, user, client = self._get_args(event) except AttributeError: return try: uuids = data['uuid'] if not isinstance(uuids, list): uuids = [uuids] ...
0.000853
def cancel_current_route( payment_state: InitiatorPaymentState, initiator_state: InitiatorTransferState, ) -> List[Event]: """ Cancel current route. This allows a new route to be tried. """ assert can_cancel(initiator_state), 'Cannot cancel a route after the secret is revealed' tra...
0.003824
def save(self, message): """ Add version to repo object store, set repo head to version sha. :param message: Message string. """ self.commit.message = message self.commit.tree = self.tree #TODO: store new blobs only for item in self.tree.items(): ...
0.005254
def load_module(self, path, squash=True): """Load values from a Python module. Example modue ``config.py``:: DEBUG = True SQLITE = { "db": ":memory:" } >>> c = ConfigDict() >>> c.load_module('config') ...
0.002281
def enkf(self): """ Loop over time windows and apply da :return: """ for cycle_index, time_point in enumerate(self.timeline): if cycle_index >= len(self.timeline) - 1: # Logging : Last Update cycle has finished break print...
0.003433
def format_image_iter( data_fetch, x_start=0, y_start=0, width=32, height=32, frame=0, columns=1, downsample=1 ): """Return the ANSI escape sequence to render a bitmap image. data_fetch Function that takes three arguments (x position, y position, and frame) and returns a Colour corresponding to...
0.02038
def getAllAsDict(self): """Return all the stats (dict).""" return {p: self._plugins[p].get_raw() for p in self._plugins}
0.014706
def _createCert(self, hostname, serial): """ Create a self-signed X.509 certificate. @type hostname: L{unicode} @param hostname: The hostname this certificate should be valid for. @type serial: L{int} @param serial: The serial number the certificate should have. ...
0.000825
def _log_control(self, s): """Write control characters to the appropriate log files""" if self.encoding is not None: s = s.decode(self.encoding, 'replace') self._log(s, 'send')
0.009434
def download_era5_for_gssha(main_directory, start_datetime, end_datetime, leftlon=-180, rightlon=180, toplat=90, bottomlat=-90, ...
0.004892
def to_log(self, step=1.0, start=None, stop=None, basis=None, field=None, field_function=None, dtype=None, table=None, legend=None, legend_field=None, matc...
0.003017
def reset(self): "Reset the hidden states." [r.reset() for r in self.rnns if hasattr(r, 'reset')] if self.qrnn: self.hidden = [self._one_hidden(l) for l in range(self.n_layers)] else: self.hidden = [(self._one_hidden(l), self._one_hidden(l)) for l in range(self.n_layers)]
0.026316
def intersection_spectrail_arcline(spectrail, arcline): """Compute intersection of spectrum trail with arc line. Parameters ---------- spectrail : SpectrumTrail object Instance of SpectrumTrail class. arcline : ArcLine object Instance of ArcLine class Returns ------- xr...
0.000896
def report(self, stream): """Writes an Xunit-formatted XML file The file includes a report of test errors and failures. """ self.stats['encoding'] = self.encoding self.stats['total'] = (self.stats['errors'] + self.stats['failures'] + self.stats['p...
0.001998
def tree_text(node): """ >>> tree_text(parse_minidom('<h1>one</h1>two<div>three<em>four</em></div>')) 'one two three four' """ text = [] for descendant in walk_dom(node): if is_text(descendant): text.append(descendant.nodeValue) return ' '.join(text)
0.006711
def pop_callback(obj): """Pop a single callback.""" callbacks = obj._callbacks if not callbacks: return if isinstance(callbacks, Node): node = callbacks obj._callbacks = None else: node = callbacks.first callbacks.remove(node) if not callbacks: ...
0.002639
def _pelita_member_filter(parent_name, item_names): """ Filter a list of autodoc items for which to generate documentation. Include only imports that come from the documented module or its submodules. """ filtered_names = [] if parent_name not in sys.modules: return item_names ...
0.00156
def handle_message(self, msg): """Handle a message from the server. Parameters ---------- msg : Message object The Message to dispatch to the handler methods. """ # log messages received so that no one else has to if self._logger.isEnabledFor(logging...
0.002347
def predictive_variance(self, mu,variance, predictive_mean=None, Y_metadata=None): """ Approximation to the predictive variance: V(Y_star) The following variance decomposition is used: V(Y_star) = E( V(Y_star|f_star)**2 ) + V( E(Y_star|f_star) )**2 :param mu: mean of posterior ...
0.015291
def twofilter_smoothing(self, t, info, phi, loggamma, linear_cost=False, return_ess=False, modif_forward=None, modif_info=None): """Two-filter smoothing. Parameters ---------- t: time, in range 0 <= t < T-1 info: SMC object...
0.005464
def installed(name, pkgs=None, user=None, install_global=False, env=None): ''' Verify that the given package is installed and is at the correct version (if specified). .. code-block:: yaml ShellCheck-0.3.5: cabal: - ...
0.000286
def remove(self, arr): """Removes an array from the list Parameters ---------- arr: str or :class:`InteractiveBase` The array name or the data object in this list to remove Raises ------ ValueError If no array with the specified array nam...
0.002677
def Concat(*args: Union[BitVec, List[BitVec]]) -> BitVec: """Create a concatenation expression. :param args: :return: """ # The following statement is used if a list is provided as an argument to concat if len(args) == 1 and isinstance(args[0], list): bvs = args[0] # type: List[BitVec]...
0.002347
def calculate_clock_angle(inst): """ Calculate IMF clock angle and magnitude of IMF in GSM Y-Z plane Parameters ----------- inst : pysat.Instrument Instrument with OMNI HRO data """ # Calculate clock angle in degrees clock_angle = np.degrees(np.arctan2(inst['BY_GSM'], inst['BZ_...
0.004367
def get_name(self): """Accessor to service_description attribute or name if first not defined :return: service name :rtype: str """ if hasattr(self, 'service_description'): return self.service_description if hasattr(self, 'name'): return self.name...
0.008219
def _remove_bottleneck(net_flux, path): """ Internal function for modifying the net flux matrix by removing a particular edge, corresponding to the bottleneck of a particular path. """ net_flux = copy.copy(net_flux) bottleneck_ind = net_flux[path[:-1], path[1:]].argmin() net_flux[path[...
0.002571
def get(self, **params): """Performs get request to the biomart service. Args: **params (dict of str: any): Arbitrary keyword arguments, which are added as parameters to the get request to biomart. Returns: requests.models.Response: Response from biomart...
0.003367
def _set_logger(self, name=None): """Adds a logger with a given `name`. If no name is given, name is constructed as `type(self).__name__`. """ if name is None: cls = self.__class__ name = '%s.%s' % (cls.__module__, cls.__name__) self._logger = lo...
0.005865
def get(self, branch='master', filename=''): """Retrieve _filename_ from GitLab. Args: branch (str): Git Branch to find file. filename (str): Name of file to retrieve relative to root of Git repository, or _runway_dir_ if specified. Returns: ...
0.00335
def trainHMM_computeStatistics(features, labels): ''' This function computes the statistics used to train an HMM joint segmentation-classification model using a sequence of sequential features and respective labels ARGUMENTS: - features: a numpy matrix of feature vectors (numOfDimensions x n_wi...
0.004012
def parse_table(document, tbl): "Parse table element." def _change(rows, pos_x): if len(rows) == 1: return rows count_x = 1 for x in rows[-1]: if count_x == pos_x: x.row_span += 1 count_x += x.grid_span return rows tab...
0.000806
def join(self, target): """join a channel""" password = self.config.passwords.get( target.strip(self.server_config['CHANTYPES'])) if password: target += ' ' + password self.send_line('JOIN %s' % target)
0.007752
def _filesec(self, files=None): """ Returns fileSec Element containing all files grouped by use. """ if files is None: files = self.all_files() filesec = etree.Element(utils.lxmlns("mets") + "fileSec") filegrps = {} for file_ in files: if ...
0.002331
def validate_value_type(value, spec): """ c_value_type = {'base': 'string', 'enumeration': ['Permit', 'Deny', 'Indeterminate']} {'member': 'anyURI', 'base': 'list'} {'base': 'anyURI'} {'base': 'NCName'} {'base': 'string'} ...
0.001164
def __set_no_protein(self, hgvs_string): """Set a flag for no protein expected. ("p.0" or "p.0?") Args: hgvs_string (str): hgvs syntax with "p." removed """ no_protein_list = ['0', '0?'] # no protein symbols if hgvs_string in no_protein_list: self.is_no_...
0.004706
def get_from_package(package_name, path): """ Get the absolute path to a file in a package. Parameters ---------- package_name : str e.g. 'mpu' path : str Path within a package Returns ------- filepath : str """ filepath = pkg_resources.resource_filename(pac...
0.002681
def read_igpar(self): """ Renders accessible: er_ev = e<r>_ev (dictionary with Spin.up/Spin.down as keys) er_bp = e<r>_bp (dictionary with Spin.up/Spin.down as keys) er_ev_tot = spin up + spin down summed er_bp_tot = spin up + spin down summed ...
0.001142
def reconnectUnitSignalsToModel(synthesisedUnitOrIntf, modelCls): """ Reconnect model signals to unit to run simulation with simulation model but use original unit interfaces for communication :param synthesisedUnitOrIntf: interface where should be signals replaced from signals from modelCls ...
0.002288
def filter_scanline(type, line, fo, prev=None): """Apply a scanline filter to a scanline. `type` specifies the filter type (0 to 4); `line` specifies the current (unfiltered) scanline as a sequence of bytes; `prev` specifies the previous (unfiltered) scanline as a sequence of bytes. `fo` specifies the ...
0.004292
def update(self, ip_address=values.unset, friendly_name=values.unset, cidr_prefix_length=values.unset): """ Update the IpAddressInstance :param unicode ip_address: An IP address in dotted decimal notation from which you want to accept traffic. Any SIP requests from this IP addres...
0.00571
def reqPnL(self, account: str, modelCode: str = '') -> PnL: """ Start a subscription for profit and loss events. Returns a :class:`.PnL` object that is kept live updated. The result can also be queried from :meth:`.pnl`. https://interactivebrokers.github.io/tws-api/pnl.html ...
0.002558
def get_nts_strpval(self, fmt="{:8.2e}"): """Given GOEA namedtuples, return nts w/P-value in string format.""" objntmgr = MgrNts(self.goea_results) dcts = objntmgr.init_dicts() # pylint: disable=line-too-long pval_flds = set(k for k in self._get_fieldnames(next(iter(self.goea_res...
0.005747
def process_read_exception(exc, path, ignore=None): ''' Common code for raising exceptions when reading a file fails The ignore argument can be an iterable of integer error codes (or a single integer error code) that should be ignored. ''' if ignore is not None: if isinstance(ignore, si...
0.001142
def get_weights(model_hparams, vocab_size, hidden_dim=None): """Create or get concatenated embedding or softmax variable. Args: model_hparams: HParams, model hyperparmeters. vocab_size: int, vocabulary size. hidden_dim: dim of the variable. Defaults to _model_hparams' hidden_size Returns: a lis...
0.010711
def threshold_monitor_hidden_threshold_monitor_security_policy_area_sec_area_value(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") threshold_monitor_hidden = ET.SubElement(config, "threshold-monitor-hidden", xmlns="urn:brocade.com:mgmt:brocade-threshold-monitor"...
0.005441
def _filter_variant_motif_res( motif_res, variant_start, variant_end, motif_length, seq, ): """ Remove MOODS motif hits that don't overlap the variant of interest. Parameters ---------- motif_res : list Result from MOODS search like [(21, 3.947748787969809), (-38...
0.007545
def _convert_eta_to_c(eta, ref_position): """ Parameters ---------- eta : 1D or 2D ndarray. The elements of the array should be this model's 'transformed' shape parameters, i.e. the natural log of (the corresponding shape parameter divided by the reference shape parameter). This ...
0.000395
def _register_endpoints(self, providers): """ Register methods to endpoints :type providers: list[str] :rtype: list[(str, ((satosa.context.Context, Any) -> satosa.response.Response, Any))] :param providers: A list of backend providers :return: A list of endpoint/method pa...
0.005076
def pick_two_individuals_eligible_for_crossover(population): """Pick two individuals from the population which can do crossover, that is, they share a primitive. Parameters ---------- population: array of individuals Returns ---------- tuple: (individual, individual) Two individual...
0.007763
def command(self, command, capture=True): """ Execute command on *Vim*. .. warning:: Do not use ``redir`` command if ``capture`` is ``True``. It's already enabled for internal use. If ``capture`` argument is set ``False``, the command execution becomes slightly faster. ...
0.001668
def recoverPubkeyParameter(message, digest, signature, pubkey): """ Use to derive a number that allows to easily recover the public key from the signature """ if not isinstance(message, bytes): message = bytes(message, "utf-8") # pragma: no cover for i in range(0, 4): if SECP256...
0.002091
def info(self, name, args): """Interfaces with the info dumpers (DBGFInfo). This feature is not implemented in the 4.0.0 release but it may show up in a dot release. in name of type str The name of the info item. in args of type str Arguments to...
0.005305
def find_indices(lst, element): """ Returns the indices for all occurrences of 'element' in 'lst'. Args: lst (list): List to search. element: Element to find. Returns: list: List of indices or values """ result = [] offset = -1 while True: try: ...
0.002273
def create_api_environment(self): """Get an instance of Api Environment services facade.""" return ApiEnvironment( self.networkapi_url, self.user, self.password, self.user_ldap)
0.008299
def froms(self): """Group metrics according to the `from` property. """ eax = {} for name, config in six.iteritems(self._metrics): from_ = self._get_property(config, 'from', default=self.stdout) eax.setdefault(from_, {})[name] = config return eax
0.006452