_id stringlengths 5 9 | text stringlengths 5 385k | title stringclasses 1
value |
|---|---|---|
doc_26500 |
Predict the labels (1 inlier, -1 outlier) of X according to the fitted model. Parameters
Xarray-like of shape (n_samples, n_features)
The data matrix. Returns
is_inlierndarray of shape (n_samples,)
Returns -1 for anomalies/outliers and +1 for inliers. | |
doc_26501 | tf.assert_greater
tf.debugging.assert_greater(
x, y, message=None, summarize=None, name=None
)
This Op checks that x[i] > y[i] holds for every pair of (possibly broadcast) elements of x and y. If both x and y are empty, this is trivially satisfied. If x is not greater than y element-wise, message, as well as the... | |
doc_26502 | See Migration guide for more details. tf.compat.v1.io.RaggedFeature.RowLengths
tf.io.RaggedFeature.RowLengths(
key
)
Attributes
key | |
doc_26503 |
Return whether the artist is to be rasterized. | |
doc_26504 | tf.compat.v1.keras.layers.experimental.preprocessing.TextVectorization(
max_tokens=None, standardize=text_vectorization.LOWER_AND_STRIP_PUNCTUATION,
split=text_vectorization.SPLIT_ON_WHITESPACE, ngrams=None,
output_mode=text_vectorization.INT, output_sequence_length=None,
pad_to_max_tokens=True, **kwarg... | |
doc_26505 |
Unwrap by taking the complement of large deltas with respect to the period. This unwraps a signal p by changing elements which have an absolute difference from their predecessor of more than max(discont, period/2) to their period-complementary values. For the default case where period is \(2\pi\) and discont is \(\pi... | |
doc_26506 |
Add a centered supxlabel to the figure. Parameters
tstr
The supxlabel text.
xfloat, default: 0.5
The x location of the text in figure coordinates.
yfloat, default: 0.01
The y location of the text in figure coordinates.
horizontalalignment, ha{'center', 'left', 'right'}, default: center
The horizonta... | |
doc_26507 | tf.compat.v1.Session(
target='', graph=None, config=None
)
A Session object encapsulates the environment in which Operation objects are executed, and Tensor objects are evaluated. For example: tf.compat.v1.disable_eager_execution() # need to disable eager in TF2.x
# Build a graph.
a = tf.constant(5.0)
b = tf.const... | |
doc_26508 |
Set the artist's clip path. Parameters
pathPatch or Path or TransformedPath or None
The clip path. If given a Path, transform must be provided as well. If None, a previously set clip path is removed.
transformTransform, optional
Only used if path is a Path, in which case the given Path is converted to a Tra... | |
doc_26509 | state should have been obtained from a previous call to getstate(), and setstate() restores the internal state of the generator to what it was at the time getstate() was called. | |
doc_26510 | Get the list of items for this view. This must be an iterable and may be a queryset (in which queryset-specific behavior will be enabled). | |
doc_26511 | Example: fav_color = request.session['fav_color'] | |
doc_26512 |
alias of numpy.bytes_ | |
doc_26513 |
Get whether the 3D axes panels are drawn. | |
doc_26514 | assert the mock has been called with the specified arguments. The assert passes if the mock has ever been called, unlike assert_called_with() and assert_called_once_with() that only pass if the call is the most recent one, and in the case of assert_called_once_with() it must also be the only call. >>> mock = Mock(retur... | |
doc_26515 |
Predict class probabilities for X. Parameters
X{array-like, sparse matrix} of shape (n_samples, n_features)
The input samples. Internally, it will be converted to dtype=np.float32 and if a sparse matrix is provided to a sparse csr_matrix. Returns
pndarray of shape (n_samples, n_classes)
The class probab... | |
doc_26516 |
Returns entropy of distribution, batched over batch_shape. Returns
Tensor of shape batch_shape. | |
doc_26517 | change the pixel format of an image convert(Surface=None) -> Surface convert(depth, flags=0) -> Surface convert(masks, flags=0) -> Surface Creates a new copy of the Surface with the pixel format changed. The new pixel format can be determined from another existing Surface. Otherwise depth, flags, and masks arguments ... | |
doc_26518 |
Roll provided date backward to next offset only if not on offset. Returns
TimeStamp
Rolled timestamp if not on offset, otherwise unchanged timestamp. | |
doc_26519 | Numeric code specifying the problem. This value can be passed to the ErrorString() function, or compared to one of the constants defined in the errors object. | |
doc_26520 |
Return a list of lines contained by the Axes. | |
doc_26521 |
Bases: skimage.viewer.canvastools.linetool.LineTool Widget for line selection in a plot. The thickness of the line can be varied using the mouse scroll wheel, or with the ‘+’ and ‘-‘ keys. Parameters
managerViewer or PlotPlugin.
Skimage viewer or plot plugin object.
on_movefunction
Function called whenever ... | |
doc_26522 |
Bases: matplotlib.artist.Artist propertylabel
propertymajor_ticklabels
propertymajor_ticks
set(*, agg_filter=<UNSET>, alpha=<UNSET>, animated=<UNSET>, clip_box=<UNSET>, clip_on=<UNSET>, clip_path=<UNSET>, gid=<UNSET>, in_layout=<UNSET>, label=<UNSET>, path_effects=<UNSET>, picker=<UNSET>, rasterized=<UN... | |
doc_26523 | """
May be applied as a `default=...` value on a serializer field.
Returns the current user.
"""
requires_context = True
def __call__(self, serializer_field):
return serializer_field.context['request'].user
When serializing the instance, default will be used if the object attribute or ... | |
doc_26524 |
Return a full array with the same shape and type as a given array. Parameters
aarray_like
The shape and data-type of a define these same attributes of the returned array.
fill_valuescalar
Fill value.
dtypedata-type, optional
Overrides the data type of the result.
order{‘C’, ‘F’, ‘A’, or ‘K’}, optional... | |
doc_26525 | This function is similar to the cast operator in C. It returns a new instance of type which points to the same memory block as obj. type must be a pointer type, and obj must be an object that can be interpreted as a pointer. | |
doc_26526 |
Alias for set_linestyle. | |
doc_26527 | Performs the SSL shutdown handshake, which removes the TLS layer from the underlying socket, and returns the underlying socket object. This can be used to go from encrypted operation over a connection to unencrypted. The returned socket should always be used for further communication with the other side of the connecti... | |
doc_26528 | Returns a date object containing the first day of the week after the date provided. This function can also return None or raise an Http404 exception, depending on the values of allow_empty and allow_future. | |
doc_26529 |
Define the picking behavior of the artist. Parameters
pickerNone or bool or float or callable
This can be one of the following:
None: Picking is disabled for this artist (default). A boolean: If True then picking will be enabled and the artist will fire a pick event if the mouse event is over the artist. A fl... | |
doc_26530 | See Migration guide for more details. tf.compat.v1.io.gfile.exists
tf.io.gfile.exists(
path
)
Args
path string, a path
Returns True if the path exists, whether it's a file or a directory. False if the path does not exist and there are no filesystem errors.
Raises
errors.OpError Pro... | |
doc_26531 | A file_wrapper takes an integer file descriptor and calls os.dup() to duplicate the handle so that the original handle may be closed independently of the file_wrapper. This class implements sufficient methods to emulate a socket for use by the file_dispatcher class. Availability: Unix. | |
doc_26532 | A set containing the names of the hash algorithms guaranteed to be supported by this module on all platforms. Note that ‘md5’ is in this list despite some upstream vendors offering an odd “FIPS compliant” Python build that excludes it. New in version 3.2. | |
doc_26533 |
Laguerre series whose graph is a straight line. Parameters
off, sclscalars
The specified line is given by off + scl*x. Returns
yndarray
This module’s representation of the Laguerre series for off + scl*x. See also numpy.polynomial.polynomial.polyline
numpy.polynomial.chebyshev.chebline
numpy.polyn... | |
doc_26534 | bytearray.zfill(width)
Return a copy of the sequence left filled with ASCII b'0' digits to make a sequence of length width. A leading sign prefix (b'+'/ b'-') is handled by inserting the padding after the sign character rather than before. For bytes objects, the original sequence is returned if width is less than or ... | |
doc_26535 | Sets the bit at the given position set_at((x, y)) -> None set_at((x, y), value=1) -> None
Parameters:
pos (tuple(int, int) or list[int, int]) -- the position of the bit to set
value (int) -- any nonzero int will set the bit to 1, 0 will set the bit to 0 (default is 1)
Returns:
None
Return type:
None... | |
doc_26536 |
Applies Instance Normalization over a 3D input (a mini-batch of 1D inputs with optional additional channel dimension) as described in the paper Instance Normalization: The Missing Ingredient for Fast Stylization. y=x−E[x]Var[x]+ϵ∗γ+βy = \frac{x - \mathrm{E}[x]}{ \sqrt{\mathrm{Var}[x] + \epsilon}} * \gamma + \beta
T... | |
doc_26537 | Wraps the single paragraph in text (a string) so every line is at most width characters long. Returns a list of output lines, without final newlines. Optional keyword arguments correspond to the instance attributes of TextWrapper, documented below. width defaults to 70. See the TextWrapper.wrap() method for additional ... | |
doc_26538 |
Local Otsu’s threshold value for each pixel. Parameters
image([P,] M, N) ndarray (uint8, uint16)
Input image.
selemndarray
The neighborhood expressed as an ndarray of 1’s and 0’s.
out([P,] M, N) array (same dtype as input)
If None, a new array is allocated.
maskndarray (integer or float), optional
M... | |
doc_26539 |
Display the filtered image on image viewer. If you don’t want to simply replace the displayed image with the filtered image (e.g., you want to display a transparent overlay), you can override this method. | |
doc_26540 | draw multiple contiguous straight line segments lines(surface, color, closed, points) -> Rect lines(surface, color, closed, points, width=1) -> Rect Draws a sequence of contiguous straight lines on the given surface. There are no endcaps or miter joints. For thick lines the ends are squared off. Drawing thick lines w... | |
doc_26541 | In-place version of less(). | |
doc_26542 |
Get vmin and vmax, and then clip at vcenter | |
doc_26543 | The HttpResponse class used when a Redirect is not found for the requested path or has a blank new_path value. Defaults to HttpResponseGone. | |
doc_26544 |
Convert an Internationalized Resource Identifier (IRI) portion to a URI portion that is suitable for inclusion in a URL. This is the algorithm from section 3.1 of RFC 3987#section-3.1, slightly simplified since the input is assumed to be a string rather than an arbitrary byte stream. Takes an IRI (string or UTF-8 byt... | |
doc_26545 | See Migration guide for more details. tf.compat.v1.raw_ops.Log
tf.raw_ops.Log(
x, name=None
)
I.e., \(y = \log_e x\). Example: x = tf.constant([0, 0.5, 1, 5]) tf.math.log(x) See: https://en.wikipedia.org/wiki/Logarithm
Args
x A Tensor. Must be one of the following types: bfloat16, half, float32, floa... | |
doc_26546 |
Generate a Vandermonde matrix. The columns of the output matrix are powers of the input vector. The order of the powers is determined by the increasing boolean argument. Specifically, when increasing is False, the i-th output column is the input vector raised element-wise to the power of N - i - 1. Such a matrix with... | |
doc_26547 |
Fill NA/NaN values using the specified method. Parameters
value:scalar, array-like
If a scalar value is passed it is used to fill all missing values. Alternatively, an array-like ‘value’ can be given. It’s expected that the array-like have the same length as ‘self’.
method:{‘backfill’, ‘bfill’, ‘pad’, ‘ffill’... | |
doc_26548 |
Return the mean accuracy on the given test data and labels. In multi-label classification, this is the subset accuracy which is a harsh metric since you require for each sample that each label set be correctly predicted. Parameters
Xarray-like of shape (n_samples, n_features)
Test samples.
yarray-like of shap... | |
doc_26549 | Like dict.values(), except this uses the same last-value logic as __getitem__() and returns an iterator instead of a view object. For example: >>> q = QueryDict('a=1&a=2&a=3')
>>> list(q.values())
['3'] | |
doc_26550 | class xml.sax.handler.ContentHandler
This is the main callback interface in SAX, and the one most important to applications. The order of events in this interface mirrors the order of the information in the document.
class xml.sax.handler.DTDHandler
Handle DTD events. This interface specifies only those DTD eve... | |
doc_26551 | Issue a warning, or maybe ignore it or raise an exception. The category argument, if given, must be a warning category class; it defaults to UserWarning. Alternatively, message can be a Warning instance, in which case category will be ignored and message.__class__ will be used. In this case, the message text will be st... | |
doc_26552 |
Update offset of the children and return the extent of the box. Parameters
rendererRendererBase subclass
Returns
width
height
xdescent
ydescent
list of (xoffset, yoffset) pairs | |
doc_26553 |
Draw random samples from a multivariate normal distribution. The multivariate normal, multinormal or Gaussian distribution is a generalization of the one-dimensional normal distribution to higher dimensions. Such a distribution is specified by its mean and covariance matrix. These parameters are analogous to the mean... | |
doc_26554 |
White kernel. The main use-case of this kernel is as part of a sum-kernel where it explains the noise of the signal as independently and identically normally-distributed. The parameter noise_level equals the variance of this noise. \[k(x_1, x_2) = noise\_level \text{ if } x_i == x_j \text{ else } 0\] Read more in th... | |
doc_26555 |
The microseconds of the datetime. Examples
>>> datetime_series = pd.Series(
... pd.date_range("2000-01-01", periods=3, freq="us")
... )
>>> datetime_series
0 2000-01-01 00:00:00.000000
1 2000-01-01 00:00:00.000001
2 2000-01-01 00:00:00.000002
dtype: datetime64[ns]
>>> datetime_series.dt.microsecond
0 ... | |
doc_26556 |
Bases: torch.distributions.distribution.Distribution Creates a Fisher-Snedecor distribution parameterized by df1 and df2. Example: >>> m = FisherSnedecor(torch.tensor([1.0]), torch.tensor([2.0]))
>>> m.sample() # Fisher-Snedecor-distributed with df1=1 and df2=2
tensor([ 0.2453])
Parameters
df1 (float or Tensor)... | |
doc_26557 |
Turn seed into a np.random.RandomState instance Parameters
seedNone, int or instance of RandomState
If seed is None, return the RandomState singleton used by np.random. If seed is an int, return a new RandomState instance seeded with seed. If seed is already a RandomState instance, return it. Otherwise raise Va... | |
doc_26558 |
Find artist objects. Recursively find all Artist instances contained in the artist. Parameters
match
A filter criterion for the matches. This can be
None: Return all objects contained in artist. A function with signature def match(artist: Artist) -> bool. The result will only contain artists for which the funct... | |
doc_26559 |
Bases: object Base class for plugins that interact with an ImageViewer. A plugin connects an image filter (or another function) to an image viewer. Note that a Plugin is initialized without an image viewer and attached in a later step. See example below for details. Parameters
image_viewerImageViewer
Window con... | |
doc_26560 | tf.metrics.Poisson Compat aliases for migration See Migration guide for more details. tf.compat.v1.keras.metrics.Poisson
tf.keras.metrics.Poisson(
name='poisson', dtype=None
)
metric = y_pred - y_true * log(y_pred)
Args
name (Optional) string name of the metric instance.
dtype (Optional) data type... | |
doc_26561 |
Return the row label of the minimum value. If multiple values equal the minimum, the first row label with that value is returned. Parameters
axis:int, default 0
For compatibility with DataFrame.idxmin. Redundant for application on Series.
skipna:bool, default True
Exclude NA/null values. If the entire Serie... | |
doc_26562 | This is a factory method which allows subclasses to define the precise type of socket they want. The default implementation creates a TCP socket (socket.SOCK_STREAM). | |
doc_26563 | Computes the normalized sinc of input. outi={1,if inputi=0sin(πinputi)/(πinputi),otherwise\text{out}_{i} = \begin{cases} 1, & \text{if}\ \text{input}_{i}=0 \\ \sin(\pi \text{input}_{i}) / (\pi \text{input}_{i}), & \text{otherwise} \end{cases}
Parameters
input (Tensor) – the input tensor. Keyword Arguments
out (... | |
doc_26564 | Return a new Policy instance whose attributes have the same values as the current instance, except where those attributes are given new values by the keyword arguments. | |
doc_26565 | Print a comparison between a and b and common subdirectories (recursively). | |
doc_26566 | An exception inheriting OSError and ValueError that is raised when an unsupported operation is called on a stream. | |
doc_26567 | Return True if there are only whitespace characters in the string and there is at least one character, False otherwise. A character is whitespace if in the Unicode character database (see unicodedata), either its general category is Zs (“Separator, space”), or its bidirectional class is one of WS, B, or S. | |
doc_26568 | A list of Template instances used to render the final content, in the order they were rendered. For each template in the list, use template.name to get the template’s file name, if the template was loaded from a file. (The name is a string such as 'admin/index.html'.) Not using Django templates? This attribute is only... | |
doc_26569 | Matrix multiplies a sparse tensor mat1 with a dense tensor mat2, then adds the sparse tensor input to the result. Note: This function is equivalent to torch.addmm(), except input and mat1 are sparse. Parameters
input (Tensor) – a sparse matrix to be added
mat1 (Tensor) – a sparse matrix to be matrix multiplied
ma... | |
doc_26570 | Creates the test databases. Returns a data structure that provides enough detail to undo the changes that have been made. This data will be provided to the teardown_databases() function at the conclusion of testing. The aliases argument determines which DATABASES aliases test databases should be set up for. If it’s not... | |
doc_26571 | bisect.insort(a, x, lo=0, hi=len(a))
Similar to insort_left(), but inserting x in a after any existing entries of x. | |
doc_26572 | See Migration guide for more details. tf.compat.v1.estimator.train_and_evaluate
tf.estimator.train_and_evaluate(
estimator, train_spec, eval_spec
)
This utility function trains, evaluates, and (optionally) exports the model by using the given estimator. All training related specification is held in train_spec, i... | |
doc_26573 | Pass to getrusage() to request resources consumed by the current thread. May not be available on all systems. New in version 3.2. | |
doc_26574 | Class which provides formatting services useful in implementing functions similar to the built-in repr(); size limits for different object types are added to avoid the generation of representations which are excessively long. | |
doc_26575 |
Bases: torch.distributions.transformed_distribution.TransformedDistribution Creates a RelaxedOneHotCategorical distribution parametrized by temperature, and either probs or logits. This is a relaxed version of the OneHotCategorical distribution, so its samples are on simplex, and are reparametrizable. Example: >>> m ... | |
doc_26576 | See Migration guide for more details. tf.compat.v1.init_scope
@tf_contextlib.contextmanager
tf.init_scope()
There is often a need to lift variable initialization ops out of control-flow scopes, function-building graphs, and gradient tapes. Entering an init_scope is a mechanism for satisfying these desiderata. In par... | |
doc_26577 |
Fit the clustering from features or affinity matrix, and return cluster labels. Parameters
X{array-like, sparse matrix} of shape (n_samples, n_features), or array-like of shape (n_samples, n_samples)
Training instances to cluster, or similarities / affinities between instances if affinity='precomputed'. If a sp... | |
doc_26578 |
Normalize value data in the [vmin, vmax] interval into the [0.0, 1.0] interval and return it. Parameters
value
Data to normalize.
clipbool
If None, defaults to self.clip (which defaults to False). Notes If not already initialized, self.vmin and self.vmax are initialized using self.autoscale_None(value). | |
doc_26579 |
Compute the 2-dimensional discrete Fourier Transform. This function computes the n-dimensional discrete Fourier Transform over any axes in an M-dimensional array by means of the Fast Fourier Transform (FFT). By default, the transform is computed over the last two axes of the input array, i.e., a 2-dimensional FFT. P... | |
doc_26580 |
Estimate log probability. Parameters
Xarray-like of shape (n_samples, n_features)
Input data. Returns
Cndarray of shape (n_samples, n_classes)
Estimated log probabilities. | |
doc_26581 |
Set the colormap for luminance data. Parameters
cmapColormap or str or None | |
doc_26582 |
Pads the input tensor using the reflection of the input boundary. For N-dimensional padding, use torch.nn.functional.pad(). Parameters
padding (int, tuple) – the size of the padding. If is int, uses the same padding in all boundaries. If a 4-tuple, uses (padding_left\text{padding\_left} , padding_right\text{padding... | |
doc_26583 | '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_26584 | Convert to a header value. Return type
str | |
doc_26585 |
Returns a copy of the calling offset object with n=1 and all other attributes equal. | |
doc_26586 |
Create a chararray. Note This class is provided for numarray backward-compatibility. New code (not concerned with numarray compatibility) should use arrays of type string_ or unicode_ and use the free functions in numpy.char for fast vectorized string operations instead. Versus a regular NumPy array of type str or ... | |
doc_26587 | operator.__isub__(a, b)
a = isub(a, b) is equivalent to a -= b. | |
doc_26588 |
Set both the edgecolor and the facecolor. Parameters
ccolor or list of rgba tuples
See also
Collection.set_facecolor, Collection.set_edgecolor
For setting the edge or face color individually. | |
doc_26589 |
Call this whenever the mappable is changed to notify all the callbackSM listeners to the 'changed' signal. | |
doc_26590 |
Execute a placeholder node. In Transformer, this is overridden to insert a new placeholder into the output graph. Parameters
target (Target) – The call target for this node. See Node for details on semantics
args (Tuple) – Tuple of positional args for this invocation
kwargs (Dict) – Dict of keyword arguments fo... | |
doc_26591 |
Return str(self). | |
doc_26592 |
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_26593 |
Bases: mpl_toolkits.axisartist.grid_helper_curvelinear.FloatingAxisArtistHelper nth_coord = along which coordinate value varies.
nth_coord = 0 -> x axis, nth_coord = 1 -> y axis | |
doc_26594 |
Compute the dot product of two or more arrays in a single function call, while automatically selecting the fastest evaluation order. multi_dot chains numpy.dot and uses optimal parenthesization of the matrices [1] [2]. Depending on the shapes of the matrices, this can speed up the multiplication a lot. If the first a... | |
doc_26595 | Returns a tensor with the same data and number of elements as self but with the specified shape. This method returns a view if shape is compatible with the current shape. See torch.Tensor.view() on when it is possible to return a view. See torch.reshape() Parameters
shape (tuple of python:ints or int...) – the desire... | |
doc_26596 | The numeric constant for the LZMA compression method. This requires the lzma module. New in version 3.3. Note The ZIP file format specification has included support for bzip2 compression since 2001, and for LZMA compression since 2006. However, some tools (including older Python releases) do not support these compre... | |
doc_26597 |
Apply this transformation on the given array of values. Parameters
valuesarray
The input values as NumPy array of length input_dims or shape (N x input_dims). Returns
array
The output values as NumPy array of length input_dims or shape (N x output_dims), depending on the input. | |
doc_26598 | Which headers can be shared by the browser to JavaScript code. | |
doc_26599 | Designates the name of the variable to use in the context. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.