_id
stringlengths
5
9
text
stringlengths
5
385k
title
stringclasses
1 value
doc_15700
Return the Blackman window. The Blackman window is a taper formed by using the first three terms of a summation of cosines. It was designed to have close to the minimal leakage possible. It is close to optimal, only slightly worse than a Kaiser window. Parameters Mint Number of points in the output window. If z...
doc_15701
Renders a template from the template folder with the given context. Parameters template_name_or_list (Union[str, List[str]]) – the name of the template to be rendered, or an iterable with template names the first one existing will be rendered context (Any) – the variables that should be available in the context of...
doc_15702
A string representing the HTTP method used in the request. This is guaranteed to be uppercase. For example: if request.method == 'GET': do_something() elif request.method == 'POST': do_something_else()
doc_15703
URL decode a single string with the given charset and decode “+” to whitespace. Per default encoding errors are ignored. If you want a different behavior you can set errors to 'replace' or 'strict'. Parameters s (Union[str, bytes]) – The string to unquote. charset (str) – the charset of the query string. If set to...
doc_15704
Change the owner and group id of path to the numeric uid and gid. To leave one of the ids unchanged, set it to -1. This function can support specifying a file descriptor, paths relative to directory descriptors and not following symlinks. See shutil.chown() for a higher-level function that accepts names in addition to ...
doc_15705
Broadcast an array to a new shape. Parameters arrayarray_like The array to broadcast. shapetuple or int The shape of the desired array. A single integer i is interpreted as (i,). subokbool, optional If True, then sub-classes will be passed-through, otherwise the returned array will be forced to be a bas...
doc_15706
Set the semi-major (a) and semi-minor radii (b) of the annulus. Parameters rfloat or (float, float) The radius, or semi-axes: If float: radius of the outer circle. If two floats: semi-major and -minor axes of outer ellipse.
doc_15707
Return the size of the terminal window as (columns, lines), tuple of type terminal_size. The optional argument fd (default STDOUT_FILENO, or standard output) specifies which file descriptor should be queried. If the file descriptor is not connected to a terminal, an OSError is raised. shutil.get_terminal_size() is the ...
doc_15708
alias of flask.sessions.SecureCookieSession
doc_15709
method to control sprite behavior update(*args, **kwargs) -> None The default implementation of this method does nothing; it's just a convenient "hook" that you can override. This method is called by Group.update() with whatever arguments you give it. There is no need to use this method if not using the convenience m...
doc_15710
Bases: matplotlib.widgets.Widget A tool to adjust the subplot params of a matplotlib.figure.Figure. Parameters targetfigFigure The figure instance to adjust. toolfigFigure The figure instance to embed the subplot tool into.
doc_15711
save a png/jpg image to file (or file-like object) save_extended(Surface, filename) -> None save_extended(Surface, fileobj, namehint="") -> None This will save your Surface as either a PNG or JPEG image. Incase the image is being saved to a file-like object, this function uses the namehint argument to determine the f...
doc_15712
Set the number of channels.
doc_15713
Return the coefficient of determination \(R^2\) of the prediction. The coefficient \(R^2\) is defined as \((1 - \frac{u}{v})\), where \(u\) is the residual sum of squares ((y_true - y_pred) ** 2).sum() and \(v\) is the total sum of squares ((y_true - y_true.mean()) ** 2).sum(). The best possible score is 1.0 and it c...
doc_15714
Create an EnvBuilder with the given keyword arguments, and call its create() method with the env_dir argument. New in version 3.3. Changed in version 3.4: Added the with_pip parameter Changed in version 3.6: Added the prompt parameter
doc_15715
Call open() with method set to PUT. Parameters args (Any) – kw (Any) – Return type werkzeug.test.TestResponse
doc_15716
Return a m-column calendar for an entire year as a multi-line string. Optional parameters w, l, and c are for date column width, lines per week, and number of spaces between month columns, respectively. Depends on the first weekday as specified in the constructor or set by the setfirstweekday() method. The earliest yea...
doc_15717
self.float() is equivalent to self.to(torch.float32). See to(). Parameters memory_format (torch.memory_format, optional) – the desired memory format of returned Tensor. Default: torch.preserve_format.
doc_15718
Return the Bartlett window. The Bartlett window is very similar to a triangular window, except that the end points are at zero. It is often used in signal processing for tapering a signal, without generating too much ripple in the frequency domain. Parameters Mint Number of points in the output window. If zero ...
doc_15719
Check whether the provided array or dtype is of the timedelta64[ns] dtype. This is a very specific dtype, so generic ones like np.timedelta64 will return False if passed into this function. Parameters arr_or_dtype:array-like or dtype The array or dtype to check. Returns boolean Whether or not the array or...
doc_15720
Returns an empty set.
doc_15721
Draw a series of Gouraud triangles. Parameters points(N, 3, 2) array-like Array of N (x, y) points for the triangles. colors(N, 3, 4) array-like Array of N RGBA colors for each point of the triangles. transformmatplotlib.transforms.Transform An affine transform to apply to the points.
doc_15722
Compute the pruning path during Minimal Cost-Complexity Pruning. See Minimal Cost-Complexity Pruning for details on the pruning process. Parameters X{array-like, sparse matrix} of shape (n_samples, n_features) The training input samples. Internally, it will be converted to dtype=np.float32 and if a sparse matri...
doc_15723
Microscopy image of dermis and epidermis (skin layers). Hematoxylin and eosin stained slide at 10x of normal epidermis and dermis with a benign intradermal nevus. Returns skin(960, 1280, 3) RGB image of uint8 Notes This image requires an Internet connection the first time it is called, and to have the pooch p...
doc_15724
class ast.Nonlocal(names) global and nonlocal statements. names is a list of raw strings. >>> print(ast.dump(ast.parse('global x,y,z'), indent=4)) Module( body=[ Global( names=[ 'x', 'y', 'z'])], type_ignores=[]) >>> print(ast.dump(ast.parse...
doc_15725
Get the hatch linewidth.
doc_15726
tf.experimental.numpy.float32( *args, **kwargs ) Character code: 'f'. Canonical name: np.single. Alias on this platform: np.float32: 32-bit-precision floating-point number type: sign bit, 8 bits exponent, 23 bits mantissa. Methods all all() Not implemented (virtual attribute) Class generic exists solely to deriv...
doc_15727
The module records the running histogram of tensor values along with min/max values. calculate_qparams will calculate scale and zero_point. Parameters bins – Number of bins to use for the histogram upsample_rate – Factor by which the histograms are upsampled, this is used to interpolate histograms with varying r...
doc_15728
Return the IEEE 754-style remainder of x with respect to y. For finite x and finite nonzero y, this is the difference x - n*y, where n is the closest integer to the exact value of the quotient x / y. If x / y is exactly halfway between two consecutive integers, the nearest even integer is used for n. The remainder r = ...
doc_15729
sklearn.get_config() [source] Retrieve current values for configuration set by set_config Returns configdict Keys are parameter names that can be passed to set_config. See also config_context Context manager for global scikit-learn configuration. set_config Set global scikit-learn configuration.
doc_15730
moves the rectangle inside another, in place clamp_ip(Rect) -> None Same as the Rect.clamp() method, but operates in place.
doc_15731
Set the parameters of this estimator. The method works on simple estimators as well as on nested objects (such as Pipeline). The latter have parameters of the form <component>__<parameter> so that it’s possible to update each component of a nested object. Parameters **paramsdict Estimator parameters. Returns...
doc_15732
See torch.addcmul()
doc_15733
See torch.take()
doc_15734
Add a callback function that will be called whenever one of the Artist's properties changes. Parameters funccallable The callback function. It must have the signature: def func(artist: Artist) -> Any where artist is the calling Artist. Return values may exist but are ignored. Returns int The observer id ...
doc_15735
Return the delivery date of the message as a floating-point number representing seconds since the epoch.
doc_15736
Transforms this raster to a different spatial reference system (srs), which may be a SpatialReference object, or any other input accepted by SpatialReference (including spatial reference WKT and PROJ strings, or an integer SRID). It calculates the bounds and scale of the current raster in the new spatial reference syst...
doc_15737
Exception to be raised when a test fails. This is deprecated in favor of unittest-based tests and unittest.TestCase’s assertion methods.
doc_15738
Add one or more events at the specified positions.
doc_15739
Bases: skimage.graph._mcp.MCP Connect source points using the distance-weighted minimum cost function. A front is grown from each seed point simultaneously, while the origin of the front is tracked as well. When two fronts meet, create_connection() is called. This method must be overloaded to deal with the found edges ...
doc_15740
The size, in bytes, of the uploaded file.
doc_15741
Draw the Artist (and its children) using the given renderer. This has no effect if the artist is not visible (Artist.get_visible returns False). Parameters rendererRendererBase subclass. Notes This method is overridden in the Artist subclasses.
doc_15742
Reduce a mask to nomask when possible. Parameters None Returns None Examples >>> x = np.ma.array([[1,2 ], [3, 4]], mask=[0]*4) >>> x.mask array([[False, False], [False, False]]) >>> x.shrink_mask() masked_array( data=[[1, 2], [3, 4]], mask=False, fill_value=999999) >>> x.mask False
doc_15743
Computes the squared Mahalanobis distances of given observations. Parameters Xarray-like of shape (n_samples, n_features) The observations, the Mahalanobis distances of the which we compute. Observations are assumed to be drawn from the same distribution than the data used in fit. Returns distndarray of s...
doc_15744
draw all sprites in the right order onto the passed surface. draw(surface) -> Rect_list
doc_15745
Moves all model parameters and buffers to the GPU. This also makes associated parameters and buffers different objects. So it should be called before constructing optimizer if the module will live on GPU while being optimized. Parameters device (int, optional) – if specified, all parameters will be copied to that dev...
doc_15746
if self.request.version == 'v1': return AccountSerializerVersion1 return AccountSerializer Reversing URLs for versioned APIs The reverse function included by REST framework ties in with the versioning scheme. You need to make sure to include the current request as a keyword argument, like so. from rest...
doc_15747
tf.compat.v1.data.Dataset() A Dataset can be used to represent an input pipeline as a collection of elements and a "logical plan" of transformations that act on those elements. Args variant_tensor A DT_VARIANT tensor that represents the dataset. Attributes element_spec The type specification of an...
doc_15748
'blogs.blog': lambda o: "/blogs/%s/" % o.slug, 'news.story': lambda o: "/stories/%s/%s/" % (o.pub_year, o.slug), } The model name used in this setting should be all lowercase, regardless of the case of the actual model class name. ADMINS Default: [] (Empty list) A list of all the people who get code error noti...
doc_15749
Group DataFrame using a mapper or by a Series of columns. A groupby operation involves some combination of splitting the object, applying a function, and combining the results. This can be used to group large amounts of data and compute operations on these groups. Parameters by:mapping, function, label, or list o...
doc_15750
See Migration guide for more details. tf.compat.v1.raw_ops.ScatterDiv tf.raw_ops.ScatterDiv( ref, indices, updates, use_locking=False, name=None ) This operation computes # Scalar indices ref[indices, ...] /= updates[...] # Vector indices (for each i) ref[indices[i], ...] /= updates[i, ...] # High rank indices...
doc_15751
Set whether the legend box patch is drawn. Parameters bbool
doc_15752
Sequence containing all the type objects for proxies. This can make it simpler to test if an object is a proxy without being dependent on naming both proxy types.
doc_15753
Return the coefficient of determination \(R^2\) of the prediction. The coefficient \(R^2\) is defined as \((1 - \frac{u}{v})\), where \(u\) is the residual sum of squares ((y_true - y_pred) ** 2).sum() and \(v\) is the total sum of squares ((y_true - y_true.mean()) ** 2).sum(). The best possible score is 1.0 and it c...
doc_15754
Return a list of the names of the subplot parameters explicitly set in the GridSpec. This is a subset of the attributes of SubplotParams.
doc_15755
Check if the object is a number. Returns True when the object is a number, and False if is not. Parameters obj:any type The object to check if is a number. Returns is_number:bool Whether obj is a number or not. See also api.types.is_integer Checks a subgroup of numbers. Examples >>> from pand...
doc_15756
Get the transformation used for drawing y-axis labels, ticks and gridlines. The x-direction is in axis coordinates and the y-direction is in data coordinates. Note This transformation is primarily used by the Axis class, and is meant to be overridden by new kinds of projections that may need to place axis elements i...
doc_15757
Plot y versus x as lines and/or markers. Call signatures: plot([x], y, [fmt], *, data=None, **kwargs) plot([x], y, [fmt], [x2], y2, [fmt2], ..., **kwargs) The coordinates of the points or line nodes are given by x, y. The optional parameter fmt is a convenient way for defining basic formatting like color, marker and...
doc_15758
Returns True if and only if all elements are closed.
doc_15759
tf.reduce_max tf.math.reduce_max( input_tensor, axis=None, keepdims=False, name=None ) Reduces input_tensor along the dimensions given in axis. Unless keepdims is true, the rank of the tensor is reduced by 1 for each of the entries in axis, which must be unique. If keepdims is true, the reduced dimensions are re...
doc_15760
See Migration guide for more details. tf.compat.v1.app.flags.DEFINE_flag tf.compat.v1.flags.DEFINE_flag( flag, flag_values=_flagvalues.FLAGS, module_name=None ) By default, the global FLAGS 'FlagValue' object is used. Typical users will use one of the more specialized DEFINE_xxx functions, such as DEFINE_string ...
doc_15761
Theil-Sen Estimator: robust multivariate regression model. The algorithm calculates least square solutions on subsets with size n_subsamples of the samples in X. Any value of n_subsamples between the number of features and samples leads to an estimator with a compromise between robustness and efficiency. Since the nu...
doc_15762
See Migration guide for more details. tf.compat.v1.data.experimental.get_structure tf.data.experimental.get_structure( dataset_or_iterator ) Args dataset_or_iterator A tf.data.Dataset or an tf.data.Iterator. Returns A nested structure of tf.TypeSpec objects matching the structure of an element...
doc_15763
tf.compat.v1.nn.separable_conv2d( input, depthwise_filter, pointwise_filter, strides, padding, rate=None, name=None, data_format=None, dilations=None ) Performs a depthwise convolution that acts separately on channels followed by a pointwise convolution that mixes channels. Note that this is separability betwe...
doc_15764
tf.experimental.numpy.meshgrid( *xi, **kwargs ) Unsupported arguments: copy, sparse, indexing. This currently requires copy=True and sparse=False. See the NumPy documentation for numpy.meshgrid.
doc_15765
Return the visibility.
doc_15766
Method called to prepare the test fixture. This is called immediately before calling the test method; other than AssertionError or SkipTest, any exception raised by this method will be considered an error rather than a test failure. The default implementation does nothing.
doc_15767
See Migration guide for more details. tf.compat.v1.keras.preprocessing.image.save_img tf.keras.preprocessing.image.save_img( path, x, data_format=None, file_format=None, scale=True, **kwargs ) Arguments path Path or file object. x Numpy array. data_format Image data format, either "channels_...
doc_15768
The OS name, if it could be parsed from the string.
doc_15769
A named tuple that holds information about Python’s internal representation of integers. The attributes are read only. Attribute Explanation bits_per_digit number of bits held in each digit. Python integers are stored internally in base 2**int_info.bits_per_digit sizeof_digit size in bytes of the C type used to...
doc_15770
Hook method for deconstructing the class fixture after running all tests in the class.
doc_15771
Set the sizes of each member of the collection. Parameters sizesndarray or None The size to set for each element of the collection. The value is the 'area' of the element. dpifloat, default: 72 The dpi of the canvas.
doc_15772
Equivalent to put(obj, False).
doc_15773
Set whether to use offset notation. When formatting a set numbers whose value is large compared to their range, the formatter can separate an additive constant. This can shorten the formatted numbers so that they are less likely to overlap when drawn on an axis. Parameters valbool or float If False, do not use...
doc_15774
Binds the app context to the current context. Return type None
doc_15775
Binarize data (set feature values to 0 or 1) according to a threshold. Values greater than the threshold map to 1, while values less than or equal to the threshold map to 0. With the default threshold of 0, only positive values map to 1. Binarization is a common operation on text count data where the analyst can deci...
doc_15776
Update the theta position of the radius labels. Parameters valuenumber The angular position of the radius labels in degrees.
doc_15777
See Migration guide for more details. tf.compat.v1.raw_ops.AssignAdd tf.raw_ops.AssignAdd( ref, value, use_locking=False, name=None ) This operation outputs "ref" after the update is done. This makes it easier to chain operations that need to use the reset value. Args ref A mutable Tensor. Must be one o...
doc_15778
See Migration guide for more details. tf.compat.v1.image.random_crop, tf.compat.v1.random_crop tf.image.random_crop( value, size, seed=None, name=None ) Slices a shape size portion out of value at a uniformly chosen offset. Requires value.shape >= size. If a dimension should not be cropped, pass the full size of...
doc_15779
See Migration guide for more details. tf.compat.v1.math.scalar_mul tf.compat.v1.scalar_mul( scalar, x, name=None ) Intended for use in gradient code which might deal with IndexedSlices objects, which are easy to multiply by a scalar but more expensive to multiply with arbitrary tensors. Args scalar A 0-...
doc_15780
Draw samples from a Weibull distribution. Draw samples from a 1-parameter Weibull distribution with the given shape parameter a. \[X = (-ln(U))^{1/a}\] Here, U is drawn from the uniform distribution over (0,1]. The more common 2-parameter Weibull, including a scale parameter \(\lambda\) is just \(X = \lambda(-ln(U))...
doc_15781
Set the value of the named cookie-attribute.
doc_15782
Returns a tensor filled with the scalar value 0, with the same size as input. torch.zeros_like(input) is equivalent to torch.zeros(input.size(), dtype=input.dtype, layout=input.layout, device=input.device). Warning As of 0.4, this function does not support an out keyword. As an alternative, the old torch.zeros_like(in...
doc_15783
An unstructured triangular grid consisting of npoints points and ntri triangles. The triangles can either be specified by the user or automatically generated using a Delaunay triangulation. Parameters x, y(npoints,) array-like Coordinates of grid points. triangles(ntri, 3) array-like of int, optional For ea...
doc_15784
The transmute method is the very core of the ArrowStyle class and must be overridden in the subclasses. It receives the path object along which the arrow will be drawn, and the mutation_size, with which the arrow head etc. will be scaled. The linewidth may be used to adjust the path so that it does not pass beyond th...
doc_15785
Convert a 2D line to 3D.
doc_15786
Bases: matplotlib.colors.LogNorm Normalize a given value to the 0-1 range on a log scale. Parameters vmin, vmaxfloat or None If vmin and/or vmax is not given, they are initialized from the minimum and maximum value, respectively, of the first input processed; i.e., __call__(A) calls autoscale_None(A). clipboo...
doc_15787
Return the url.
doc_15788
See Migration guide for more details. tf.compat.v1.raw_ops.Less tf.raw_ops.Less( x, y, name=None ) Note: math.less supports broadcasting. More about broadcasting here Example: x = tf.constant([5, 4, 6]) y = tf.constant([5]) tf.math.less(x, y) ==> [False, True, False] x = tf.constant([5, 4, 6]) y = tf.constant...
doc_15789
Removes the pruning reparameterization from a module. The pruned parameter named name remains permanently pruned, and the parameter named name+'_orig' is removed from the parameter list. Similarly, the buffer named name+'_mask' is removed from the buffers. Note Pruning itself is NOT undone or reversed!
doc_15790
control which events are allowed on the queue set_blocked(type) -> None set_blocked(typelist) -> None set_blocked(None) -> None The given event types are not allowed to appear on the event queue. By default all events can be placed on the queue. It is safe to disable an event type multiple times. If None is passed as...
doc_15791
Compute the absolute values element-wise. This function returns the absolute values (positive magnitude) of the data in x. Complex values are not handled, use absolute to find the absolute values of complex data. Parameters xarray_like The array of numbers for which the absolute values are required. If x is a s...
doc_15792
Linear model fitted by minimizing a regularized empirical loss with SGD SGD stands for Stochastic Gradient Descent: the gradient of the loss is estimated each sample at a time and the model is updated along the way with a decreasing strength schedule (aka learning rate). The regularizer is a penalty added to the loss...
doc_15793
Cursor to use when the tool is active.
doc_15794
Bases: matplotlib.patches.RegularPolygon A polygon-approximation of a circle patch. Create a circle at xy = (x, y) with given radius. This circle is approximated by a regular polygon with resolution sides. For a smoother circle drawn with splines, see Circle. Valid keyword arguments are: Property Description ag...
doc_15795
Draw the Artist (and its children) using the given renderer. This has no effect if the artist is not visible (Artist.get_visible returns False). Parameters rendererRendererBase subclass. Notes This method is overridden in the Artist subclasses.
doc_15796
tf.compat.v1.keras.initializers.he_normal( seed=None ) With distribution="truncated_normal" or "untruncated_normal", samples are drawn from a truncated/untruncated normal distribution with a mean of zero and a standard deviation (after truncation, if used) stddev = sqrt(scale / n) where n is: number of input unit...
doc_15797
tf.distribute.experimental.coordinator.ClusterCoordinator( strategy ) This class is used to create fault-tolerant resources and dispatch functions to remote TensorFlow servers. Currently, this class is not supported to be used in a standalone manner. It should be used in conjunction with a tf.distribute strategy t...
doc_15798
Transform new data by linear interpolation Parameters Tarray-like of shape (n_samples,) or (n_samples, 1) Data to transform. Changed in version 0.24: Also accepts 2d array with 1 feature. Returns y_predndarray of shape (n_samples,) The transformed data
doc_15799
Bases: torch.distributions.transformed_distribution.TransformedDistribution Creates a RelaxedBernoulli distribution, parametrized by temperature, and either probs or logits (but not both). This is a relaxed version of the Bernoulli distribution, so the values are in (0, 1), and has reparametrizable samples. Example: ...