language
stringclasses
2 values
func_code_string
stringlengths
63
466k
java
public static double quantile(double val, double loc, double scale, double shape1, double shape2) { if(!(val >= 0.) || !(val <= 1.)) { return Double.NaN; } if(val == 0.) { if(shape2 <= 0.) { return shape1 < 0. ? loc + scale / shape1 : Double.NEGATIVE_INFINITY; } else { ...
python
def Decompress(self, compressed_data): """Decompresses the compressed data. Args: compressed_data (bytes): compressed data. Returns: tuple(bytes, bytes): uncompressed data and remaining compressed data. Raises: BackEndError: if the BZIP2 compressed stream cannot be decompressed. ...
python
def _get_sender(*sender_params, **kwargs): """ Utility function acting as a Sender factory - ensures senders don't get created twice of more for the same target server """ notify_func = kwargs['notify_func'] with _sender_instances_lock: existing_sender = _sender_instances.get(sender_para...
java
@Requires({ "parent != null", "annotation != null", "owner != null", "utils.isContractAnnotation(annotation)" }) @Ensures("result != null") private ContractAnnotationModel createBlankContractModel(Element parent, AnnotationMirror annotation, boolean primary, ClassName owner) { ElementKin...
java
public List<Bucket> getBuckets() { List<Bucket> result = Lists.newArrayList(); for (File file : getBaseDir().listFiles()) { if (file.isDirectory()) { result.add(new Bucket(file)); } } return result; }
java
@SuppressWarnings("fallthrough") private void binarySort(Buffer a, int lo, int hi, int start, Comparator<? super K> c) { assert lo <= start && start <= hi; if (start == lo) start++; K key0 = s.newKey(); K key1 = s.newKey(); Buffer pivotStore = s.allocate(1); for ( ; start < hi; start++...
python
def list_auth_methods(self): """List all enabled auth methods. Supported methods: GET: /sys/auth. Produces: 200 application/json :return: The JSON response of the request. :rtype: dict """ api_path = '/v1/sys/auth' response = self._adapter.get( ...
python
def rollback(self, release): """Rolls back the release to the given version.""" r = self._h._http_resource( method='POST', resource=('apps', self.name, 'releases'), data={'rollback': release} ) return self.releases[-1]
java
protected void combineContentItem( String itemValue, String itemKey, StringBuffer content, Map<String, String> contentItems) { if (CmsStringUtil.isNotEmpty(itemValue)) { contentItems.put(itemKey, itemValue); content.append('\n'); content.appen...
python
def day_crumb(date): """ Crumb for a day. """ year = date.strftime('%Y') month = date.strftime('%m') day = date.strftime('%d') return Crumb(day, reverse('zinnia:entry_archive_day', args=[year, month, day]))
java
public void marshall(Player player, ProtocolMarshaller protocolMarshaller) { if (player == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(player.getPlayerId(), PLAYERID_BINDING); protocol...
java
private WritableRaster skyviewfactor( WritableRaster pitWR, double res ) { /* * evalutating the normal vector (in the center of the square compound * of 4 pixel. */ normalVectorWR = normalVector(pitWR, res); WritableRaster skyviewFactorWR = CoverageUtilities.createW...
java
protected void triggerEpochListeners(boolean epochStart, Model model, int epochNum){ Collection<TrainingListener> listeners; if(model instanceof MultiLayerNetwork){ MultiLayerNetwork n = ((MultiLayerNetwork) model); listeners = n.getListeners(); n.setEpochCount(epochN...
python
def start_monitoring(seconds_frozen=SECONDS_FROZEN, test_interval=TEST_INTERVAL): """Start monitoring for hanging threads. seconds_frozen - How much time should thread hang to activate printing stack trace - default(10) tests_interval - Sleep time of monitoring thread (in millisec...
python
def file_link(self, instance): ''' Renders the link to the student upload file. ''' sfile = instance.file_upload if not sfile: return mark_safe('No file submitted by student.') else: return mark_safe('<a href="%s">%s</a><br/>(<a href="%s" targe...
python
def add_elasticache_cluster(self, cluster, region): ''' Adds an ElastiCache cluster to the inventory and index, as long as it's nodes are addressable ''' # Only want available clusters unless all_elasticache_clusters is True if not self.all_elasticache_clusters and cluster['CacheCluster...
python
def get_field_context(self, bound_field): """ Returns the context which is used when rendering a form field to HTML. The generated template context will contain the following variables: * form: `Form` instance * field: `BoundField` instance of the field * field_id: Fiel...
java
public static void removeFromList(List<String> list, String value) { int foundIndex = -1; int i = 0; for (String id : list) { if (id.equalsIgnoreCase(value)) { foundIndex = i; break; } i++; } if (foundIndex != -1...
java
public void parse(InputStream script, Binding binding) { if (script==null) throw new IllegalArgumentException("No script is provided"); setBinding(binding); CompilerConfiguration cc = new CompilerConfiguration(); cc.setScriptBaseClass(ClosureScript.class.getName()); G...
python
def init_app(self, app): """Initialize Flask application.""" if self.entry_point_group: eps = sorted(pkg_resources.iter_entry_points( self.entry_point_group), key=attrgetter('name')) for ep in eps: app.logger.debug("Loading config for entry point {...
python
def is_valid_sid_for_chain(pid, sid): """Return True if ``sid`` can be assigned to the single object ``pid`` or to the chain to which ``pid`` belongs. - If the chain does not have a SID, the new SID must be previously unused. - If the chain already has a SID, the new SID must match the existing SID. ...
python
def dict_expand(d, prefix=None): """ Recursively expand subdictionaries returning dictionary dict_expand({1:{2:3}, 4:5}) = {(1,2):3, 4:5} """ result = {} for k, v in d.items(): if isinstance(v, dict): result.update(dict_expand(v, prefix=k)) else: result[k]...
python
def get_default_client(path=None, ui=None, **kwargs): """Get a client for a connected Trezor device. Returns a TrezorClient instance with minimum fuss. If no path is specified, finds first connected Trezor. Otherwise performs a prefix-search for the specified device. If no UI is supplied, instantiates...
java
protected Widget addMarker(String text) { Label label = new Label(text); label.addStyleName(CSS.marker()); getListItemWidget().addButton(label); return label; }
python
def _read_group_field(self, group, levels, field_type, field_size, decrypted_content): """This method handles the different fields of a group""" if field_type == 0x0000: # Ignored (commentar block) pass elif field_type == 0x0001: g...
java
public static String validateLicense(String licenseText) throws PGPException { licenseText = licenseText.trim().replaceAll("\\r|\\n", ""); licenseText = licenseText.replace("---- SCHNIPP (Armored PGP signed JSON as base64) ----",""); licenseText = licenseText.replace("---- SCHNAPP ----",""...
python
def hash(*cols): """Calculates the hash code of given columns, and returns the result as an int column. >>> spark.createDataFrame([('ABC',)], ['a']).select(hash('a').alias('hash')).collect() [Row(hash=-757602832)] """ sc = SparkContext._active_spark_context jc = sc._jvm.functions.hash(_to_seq(s...
python
def std_err(self): """Standard error of the estimate (SEE). A scalar. For standard errors of parameters, see _se_all, se_alpha, and se_beta. """ return np.sqrt(np.sum(np.square(self.resids), axis=0) / self.df_err)
java
public static <K, V> SetMultimap<K, V> constrainedSetMultimap( SetMultimap<K, V> multimap, MapConstraint<? super K, ? super V> constraint) { return new ConstrainedSetMultimap<K, V>(multimap, constraint); }
python
def step1c(self): """step1c() turns terminal y to i when there is another vowel in the stem.""" if self.ends("y") and self.vowelinstem(): self.b = self.b[: self.k] + "i" + self.b[self.k + 1 :]
python
def set_prefix(self, prefix): """ Set the prefix for the node (see Leaf class). DEPRECATED; use the prefix property directly. """ warnings.warn("set_prefix() is deprecated; use the prefix property", DeprecationWarning, stacklevel=2) self.prefix = pr...
java
public static SockJsFrame messageFrame(SockJsMessageCodec codec, String... messages) { String encoded = codec.encode(messages); return new SockJsFrame(encoded); }
python
def _set_dense_defaults_and_eval(kwargs): """ Sets default values in kwargs if kwargs are not already given. Evaluates all values using eval Parameters ----------- kwargs : dict Dictionary of dense specific keyword args Returns ------- : dict Default, evaluated dic...
python
def get_cloud_masks(self, X): """ Runs the cloud detection on the input images (dimension n_images x n x m x 10 or n_images x n x m x 13) and returns the raster cloud mask (dimension n_images x n x m). Pixel values equal to 0 indicate pixels classified as clear-sky, while values ...
python
def create_from_assocs(self, assocs, **args): """ Creates from a list of association objects """ amap = defaultdict(list) subject_label_map = {} for a in assocs: subj = a['subject'] subj_id = subj['id'] subj_label = subj['label'] ...
java
public void triangulate() { double minArea = 1000 * charLength * DOUBLE_PREC; newFaces.clear(); for (Iterator it = faces.iterator(); it.hasNext();) { Face face = (Face) it.next(); if (face.mark == Face.VISIBLE) { face.triangulate(newFaces, minArea); ...
java
private Event linkChainIdentifier(Event event) { if (event instanceof ChainableEvent) { ChainableEvent chainableEvent = (ChainableEvent)event; chainableEvent.setChainIdentifier(this.getChainIdentifier()); return chainableEvent; } return event; }
python
def get_boundaries(self, filter_type, value): """Compute the boundaries to pass to the sorted-set command depending of the filter type The third return value, ``exclude`` is always ``None`` because we can easily restrict the score to filter on in the sorted-set. For the parameters, see...
python
def prior_from_config(cp, prior_section='prior'): """Loads a prior distribution from the given config file. Parameters ---------- cp : pycbc.workflow.WorkflowConfigParser The config file to read. sections : list of str, optional The sections to retrieve the prior from. If ``None`` (...
python
def prepend(self, tr): """ Add a new transform to the beginning of this chain. Parameters ---------- tr : instance of Transform The transform to use. """ self.transforms.insert(0, tr) tr.changed.connect(self._subtr_changed) self._rebui...
java
public final ListProductsPagedResponse listProducts(LocationName parent) { ListProductsRequest request = ListProductsRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); return listProducts(request); }
java
public PagedList<VpnConnectionInner> listByVpnGatewayNext(final String nextPageLink) { ServiceResponse<Page<VpnConnectionInner>> response = listByVpnGatewayNextSinglePageAsync(nextPageLink).toBlocking().single(); return new PagedList<VpnConnectionInner>(response.body()) { @Override ...
python
def appendPoint(self, position=None, type="line", smooth=False, name=None, identifier=None, point=None): """ Append a point to the contour. """ if point is not None: if position is None: position = point.position type = point.type smoot...
python
def get_permission(self, username, virtual_host): """Get User permissions for the configured virtual host. :param str username: Username :param str virtual_host: Virtual host name :raises ApiError: Raises if the remote server encountered an error. :raises ApiConnectionError: Ra...
java
@Override public Runnable wrap(Runnable runnable) { if (isTracing()) { return new SpanContinuingTraceRunnable(this, this.traceKeys, this.spanNamer, runnable); } return runnable; }
python
def write_rst(self, prefix: str = "", suffix: str = "", heading_underline_char: str = "=", method: AutodocMethod = None, overwrite: bool = False, mock: bool = False) -> None: """ Writes the RST fi...
python
def delete(self, callback=None, errback=None): """ Delete the record from the zone, including all advanced configuration, meta data, etc. """ if not self.data: raise RecordException('record not loaded') def success(result, *args): if callback: ...
java
public synchronized E intern(@NonNull final E object) { return map.computeIfAbsent(object, o -> object); }
java
public static String packageNameOf(Class<?> clazz) { String name = clazz.getName(); int pos = name.lastIndexOf('.'); E.unexpectedIf(pos < 0, "Class does not have package: " + name); return name.substring(0, pos); }
python
def pinyin(hans, style=Style.TONE, heteronym=False, errors='default', strict=True): """将汉字转换为拼音. :param hans: 汉字字符串( ``'你好吗'`` )或列表( ``['你好', '吗']`` ). 可以使用自己喜爱的分词模块对字符串进行分词处理, 只需将经过分词处理的字符串列表传进来就可以了。 :type hans: unicode 字符串或字符串列表 :param style: 指定拼音风格,默认是 :p...
java
private static ModelNode getServerfactory(CommandContext ctx, String point, String name) throws OperationFormatException, IOException { DefaultOperationRequestBuilder builder = new DefaultOperationRequestBuilder(); builder.setOperationName(Util.READ_RESOURCE); for (String p : point.split("/")) {...
java
public com.google.protobuf.ByteString getUfsTypeBytes() { java.lang.Object ref = ufsType_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); ufsType_ = b; return b; ...
java
public static String getSingleValuedHeader( Map<String, List<String>> headers, String key) { List<String> values = headers.get(key); if (values == null) { return null; } if (values.size() > 1) { throw new IllegalArgumentException("Header with key [\"...
python
def obtain_token(self): """ Try to obtain token from all end-points that were ever used to serve the token. If the request returns 404 NOT FOUND, retry with older version of the URL. """ token_end_points = ('token/obtain', 'obtain-token', ...
python
def update(self, max_norm=None): """Updates parameters according to the installed optimizer and the gradients computed in the previous forward-backward batch. Gradients are clipped by their global norm if `max_norm` is set. Parameters ---------- max_norm: float, optional...
python
def clean_locks(root=None): ''' Remove unused locks that do not currently (with regard to repositories used) lock any package. root Operate on a different root directory. CLI Example: .. code-block:: bash salt '*' pkg.clean_locks ''' LCK = "removed" out = {LCK: 0}...
python
def read_data(self, file_handle): """Read the DATA segment of the FCS file.""" self._verify_assumptions() text = self.annotation if (self._data_start > self._file_size) or (self._data_end > self._file_size): raise ValueError(u'The FCS file "{}" is corrupted. Part of the data...
java
public synchronized static HortonMachine getInstance() { if (hortonMachine == null) { hortonMachine = new HortonMachine(null); hortonMachine.gatherInformations(); } return hortonMachine; }
python
def execute(self): """ Execute the actions necessary to perform a `molecule lint` and returns None. :return: None """ self.print_info() linters = [ l for l in [ self._config.lint, self._config.verifier.lint, ...
python
def h_kinetic(T, P, MW, Hvap, f=1): r'''Calculates heat transfer coefficient for condensation of a pure chemical inside a vertical tube or tube bundle, as presented in [2]_ according to [1]_. .. math:: h = \left(\frac{2f}{2-f}\right)\left(\frac{MW}{1000\cdot 2\pi R T} \right)^{0.5}\left...
python
def mergeConfig(args, testing=False): # pragma: no cover """ I take in a namespace created by the ArgumentParser in cmdline.main() and merge in options from configuration files. The config items only replace argument items that are set to default value. Returns: I return a new argparse.Namespace,...
java
@Deprecated public static <T> CombinableEitherMatcher<T> either(Matcher<? super T> matcher) { return CoreMatchers.either(matcher); }
java
private boolean isWorkAvailable() throws SIConnectionDroppedException { if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(this, tc, "isWorkAvailable"); final boolean isWork; if (terminate) { isWork = false; } else { isWork = (partiallySentTransmission...
python
async def generic_request(self, class_, iter_lines=False, iter_content=False, controller=None, parse_types=False, **kwargs): """Generic Space-Track query coroutine. The request class methods use this method internally; the public API is as follows: .. code...
python
def parse_header_part(self, data): """Extracts and converts the RFX common header part of all valid packets to a plain dictionary. RFX header part is the 4 bytes prior the sensor vendor specific data part. The RFX common header part contains respectively: - packet length ...
java
public static IsotopePattern sortAndNormalizedByIntensity(IsotopePattern isotopeP) { IsotopePattern isoNorma = normalize(isotopeP); return sortByIntensity(isoNorma); }
java
public TransactionalProtocolClient.PreparedOperation<T> retrievePreparedOperation(final long timeout, final TimeUnit timeUnit) throws InterruptedException { return queue.poll(timeout, timeUnit); }
python
def get_or_create_from_ip(ip): """ Get or create an entry using obtained information from an IP. Args: ip (str): IP address xxx.xxx.xxx.xxx. Returns: ip_info: an instance of IPInfo. """ data = ip_api_handler.get(ip) if data and any(v for ...
python
def get_credentials(username: str = None, **kwargs) -> dict: """ Calculate credentials for Axes to use internally from given username and kwargs. Axes will set the username value into the key defined with ``settings.AXES_USERNAME_FORM_FIELD`` and update the credentials dictionary with the kwargs given ...
python
def get_approximate_times(times: List[int]) -> List[int]: """ Given a list of times that follow a word such as ``about``, we return a list of times that could appear in the query as a result of this. For example if ``about 7pm`` appears in the utterance, then we also want to add ``1830`` and ``1930`...
python
def check(self): """Check for validity. :raises ValueError: - if not all lines are as long as the :attr:`number of needles <AYABInterface.machines.Machine.number_of_needles>` - if the contents of the rows are not :attr:`needle positions <AYABInterface.machin...
python
def _log_variables(self, epoch_data: EpochData): """ Log variables from the epoch data. .. warning:: At the moment, only scalars and dicts of scalars are properly formatted and logged. Other value types are ignored by default. One may set ``on_unknown_type`` to ...
python
def _display_layers(circ: Circuit, qubits: Qubits) -> Circuit: """Separate a circuit into groups of gates that do not visually overlap""" N = len(qubits) qubit_idx = dict(zip(qubits, range(N))) gate_layers = DAGCircuit(circ).layers() layers = [] lcirc = Circuit() layers.append(lcirc) un...
java
private Set<Class<?>> getClasses() { HashSet<Class<?>> result = new HashSet<Class<?>>(); // in case of override only the last global configuration must be analyzed JGlobalMap jGlobalMap = null; for (Class<?> clazz : getAllsuperClasses(configuredClass)) { // only if global configuration is n...
python
def func_timeout(timeout, func, args=(), kwargs=None): ''' func_timeout - Runs the given function for up to #timeout# seconds. Raises any exceptions #func# would raise, returns what #func# would return (unless timeout is exceeded), in which case it raises FunctionTimedOut @param timeout <f...
python
def pull_request(self, number): """Get the pull request indicated by ``number``. :param int number: (required), number of the pull request. :returns: :class:`PullRequest <github3.pulls.PullRequest>` """ json = None if int(number) > 0: url = self._build_url('p...
java
public MediaState getEpisodeAccountState(int tvID, int seasonNumber, int episodeNumber, String sessionID) throws MovieDbException { return tmdbEpisodes.getEpisodeAccountState(tvID, seasonNumber, episodeNumber, sessionID); }
java
public BagObject add (String key, Object object) { // separate the key into path components, the "local" key value is the first component, // so use that to conduct the search. If there is an element there, we want to get it, // otherwise we want to create it. String[] path = Key.spl...
java
public static Specification<JpaDistributionSet> byIds(final Collection<Long> distids) { return (targetRoot, query, cb) -> { final Predicate predicate = targetRoot.<Long> get(JpaDistributionSet_.id).in(distids); targetRoot.fetch(JpaDistributionSet_.modules, JoinType.LEFT); tar...
python
def sampling_query(sql, fields=None, count=5, sampling=None): """Returns a sampling query for the SQL object. Args: sql: the SQL object to sample fields: an optional list of field names to retrieve. count: an optional count of rows to retrieve which is used if a specific sampling is...
java
public InputStream open(String fileName) { try { URL urlToFile = new URL(url, fileName); return urlToFile.openStream(); } catch (MalformedURLException e) { throw new RuntimeException(String.format("error while forming new URL from URL %s and filename %s", url.getPath(...
python
def _epub_to_mobi( self, epubPath, deleteEpub=False): """*convert the give epub to mobi format using kindlegen* **Key Arguments:** - ``epubPath`` -- path to the epub book - ``deleteEpub`` -- delete the epub when mobi is generated. Default *Fal...
java
@SuppressWarnings({"PMD.AvoidCatchingThrowable","PMD.AvoidInstanceofChecksInCatchClause"}) public static Runnable swallowExceptions(Runnable in) { return () -> { try { in.run(); } catch (Error tt) { LOGGER.error("Error (will be rethrown)", tt); ...
java
private void replacePrototypeMemberDeclaration(PrototypeMemberDeclaration declar) { // x.prototype.y = ... -> t.y = ... Node assignment = declar.node.getFirstChild(); Node lhs = assignment.getFirstChild(); Node name = NodeUtil.newQName( compiler, PROTOTYPE_ALIAS + "." + declar.memberNa...
java
BraveSpan currentSpan() { BraveScope scope = currentScopes.get().peekFirst(); if (scope != null) { return scope.span(); } else { brave.Span braveSpan = tracer.currentSpan(); if (braveSpan != null) { return new BraveSpan(tracer, braveSpan); } } return null; }
java
@Override public EEnum getIfcDuctFittingTypeEnum() { if (ifcDuctFittingTypeEnumEEnum == null) { ifcDuctFittingTypeEnumEEnum = (EEnum) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI) .getEClassifiers().get(971); } return ifcDuctFittingTypeEnumEEnum; }
python
def fetch_all_snapshots(self): r""" Returns a generator that yields all of the snapshot images created from the droplet :rtype: generator of `Image`\ s :raises DOAPIError: if the API endpoint replies with an error """ api = self.doapi_manager for obj in a...
python
def video_augmentation(features, hue=False, saturate=False, contrast=False): """Augments video with optional hue, saturation and constrast. Args: features: dict, with keys "inputs", "targets". features["inputs"], 4-D Tensor, shape=(THWC) features["targets"], 4-D Tensor, shape=(THWC)...
python
def _process_include( self, file_path: Path, from_heading: str or None = None, to_heading: str or None = None, options={} ) -> str: '''Replace a local include statement with the file content. Necessary adjustments are applied to the con...
python
def add(self, class_name, name, **kwargs): """ Add a single component to the network. Adds it to component DataFrames. Parameters ---------- class_name : string Component class name in ["Bus","Generator","Load","StorageUnit","Store","ShuntImpedance","Line","...
java
public String getHomeRemoteImplClassName() { if (ivRemoteHomeInterface == null) return null; // ----------------------------------------------------------------------- // The component remote home implementation name was changed in EJB 2.x to // use the bean name and has...
java
public void populate(Map<byte[],byte[]> taskValues) { this.taskId = ByteUtil.getValueAsString(JobHistoryKeys.KEYS_TO_BYTES.get(JobHistoryKeys.TASKID), taskValues); this.type = ByteUtil.getValueAsString(JobHistoryKeys.KEYS_TO_BYTES.get(JobHistoryKeys.TASK_TYPE), taskValues); this.status = ByteUt...
java
private String expandRHS(final String lhs, int lineOffset) { final StringBuilder buf = new StringBuilder(); final String[] lines = lhs.split((lhs.indexOf("\r\n") >= 0 ? "\r\n":"\n"), -1 ); // since we assembled the string, we know li...
java
public ArrayList<OvhStatistics> serviceName_usageStatistics_GET(String serviceName, Date from, Date to) throws IOException { String qPath = "/license/office/{serviceName}/usageStatistics"; StringBuilder sb = path(qPath, serviceName); query(sb, "from", from); query(sb, "to", to); String resp = exec(qPath, "GET...
python
def _get_internal_delta(self): """ This is only supposed to be used by fitting/sampling engine, to get the initial step in internal representation :return: initial delta in internal representation """ if self._transformation is None: return self._delta els...
python
def ensure_ceph_keyring(service, user=None, group=None, relation='ceph', key=None): """Ensures a ceph keyring is created for a named service and optionally ensures user and group ownership. @returns boolean: Flag to indicate whether a key was successfully written ...
java
private void parseHeaders(ReadStream s) throws IOException { int version = version(); if (version < HTTP_1_0) { return; } if (version < HTTP_1_1) { killKeepalive("http client version less than 1.1: " + version); } byte []readBuffer = s.buffer(); int readOffset = s.offset(); ...
java
private void buttonResetActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonResetActionPerformed makeModelAndSetToTable(SystemFileExtensionManager.getInstance().getDefaultExtensionsAsCommaSeparatedString()); }
python
def upload(remote_location, remotes=None, ignores=None, static_root="/static/", prefix="", dry_run=False): # pylint:disable=too-many-arguments """ Upload resources to a stage server. """ if remotes is None: remotes, ignores = _resources_files( abs_paths=remote_location...
python
def show_proportions(adata): """Fraction of spliced/unspliced/ambiguous abundances Arguments --------- adata: :class:`~anndata.AnnData` Annotated data matrix. Returns ------- Prints the fractions of abundances. """ layers_keys = [key for key in ['spliced', 'unspliced', 'amb...