_id stringlengths 5 9 | text stringlengths 5 385k | title stringclasses 1
value |
|---|---|---|
doc_2900 |
pygame module for drawing shapes EXPERIMENTAL!: This API may change or disappear in later pygame releases. If you use this, your code may break with the next pygame release. The pygame package does not import gfxdraw automatically when loaded, so it must imported explicitly to be used. import pygame
import pygame.... | |
doc_2901 |
The minutes of the datetime. Examples
>>> datetime_series = pd.Series(
... pd.date_range("2000-01-01", periods=3, freq="T")
... )
>>> datetime_series
0 2000-01-01 00:00:00
1 2000-01-01 00:01:00
2 2000-01-01 00:02:00
dtype: datetime64[ns]
>>> datetime_series.dt.minute
0 0
1 1
2 2
dtype: int64 | |
doc_2902 | class sklearn.decomposition.SparsePCA(n_components=None, *, alpha=1, ridge_alpha=0.01, max_iter=1000, tol=1e-08, method='lars', n_jobs=None, U_init=None, V_init=None, verbose=False, random_state=None) [source]
Sparse Principal Components Analysis (SparsePCA). Finds the set of sparse components that can optimally reco... | |
doc_2903 |
The bbox of the character (B) as a tuple (llx, lly, urx, ury). | |
doc_2904 |
Return the standard horizontal stem width as float, or None if not specified in AFM file. | |
doc_2905 | Return fillstate (True if filling, False else). >>> turtle.begin_fill()
>>> if turtle.filling():
... turtle.pensize(5)
... else:
... turtle.pensize(3) | |
doc_2906 |
Return the Patch's axis-aligned extents as a Bbox. | |
doc_2907 | Return the result of rotating the digits of the first operand by an amount specified by the second operand. The second operand must be an integer in the range -precision through precision. The absolute value of the second operand gives the number of places to rotate. If the second operand is positive then rotation is t... | |
doc_2908 |
An array object represents a multidimensional, homogeneous array of fixed-size items. An associated data-type object describes the format of each element in the array (its byte-order, how many bytes it occupies in memory, whether it is an integer, a floating point number, or something else, etc.) Arrays should be con... | |
doc_2909 |
Evaluate a 3-D Hermite_e series at points (x, y, z). This function returns the values: \[p(x,y,z) = \sum_{i,j,k} c_{i,j,k} * He_i(x) * He_j(y) * He_k(z)\] The parameters x, y, and z are converted to arrays only if they are tuples or a lists, otherwise they are treated as a scalars and they must have the same shape a... | |
doc_2910 | Loop over the format_string and return an iterable of tuples (literal_text, field_name, format_spec, conversion). This is used by vformat() to break the string into either literal text, or replacement fields. The values in the tuple conceptually represent a span of literal text followed by a single replacement field. I... | |
doc_2911 |
Return a list of the child Artists of this Artist. | |
doc_2912 | draw a filled circle filled_circle(surface, x, y, r, color) -> None Draws a filled circle on the given surface. For an unfilled circle use circle().
Parameters:
surface (Surface) -- surface to draw on
x (int) -- x coordinate of the center of the circle
y (int) -- y coordinate of the center of the circle
r ... | |
doc_2913 | tf.experimental.numpy.ones(
shape, dtype=float
)
Unsupported arguments: order. See the NumPy documentation for numpy.ones. | |
doc_2914 | Helper object to deal with Flask applications. This is usually not necessary to interface with as it’s used internally in the dispatching to click. In future versions of Flask this object will most likely play a bigger role. Typically it’s created automatically by the FlaskGroup but you can also manually create it and ... | |
doc_2915 |
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_2916 | Return the effective group id of the current process. This corresponds to the “set id” bit on the file being executed in the current process. Availability: Unix. | |
doc_2917 |
Bases: tornado.web.RequestHandler get()[source] | |
doc_2918 |
Keep only the elements where filter_fn applied to function name returns True. | |
doc_2919 | The name of a GET field containing the URL to redirect to after log out. Defaults to 'next'. Overrides the next_page URL if the given GET parameter is passed. | |
doc_2920 | Dictionary mapping filename extensions to non-standard, but commonly found MIME types. | |
doc_2921 |
Decode the input into a string of unicode symbols. The decoding strategy depends on the vectorizer parameters. Parameters
docstr
The string to decode. Returns
doc: str
A string of unicode symbols. | |
doc_2922 |
Set whether the artist uses clipping. When False artists will be visible outside of the axes which can lead to unexpected results. Parameters
bbool | |
doc_2923 | Return the event loop associated with the server object. New in version 3.7. | |
doc_2924 | The HTTP reason phrase for the response. It uses the HTTP standard’s default reason phrases. Unless explicitly set, reason_phrase is determined by the value of status_code. | |
doc_2925 |
Construct an array from a text file, using regular expression parsing. The returned array is always a structured array, and is constructed from all matches of the regular expression in the file. Groups in the regular expression are converted to fields of the structured array. Parameters
filepath or file
Filenam... | |
doc_2926 | See Migration guide for more details. tf.compat.v1.raw_ops.DatasetToGraph
tf.raw_ops.DatasetToGraph(
input_dataset, stateful_whitelist=[], allow_stateful=False,
strip_device_assignment=False, name=None
)
Returns a graph representation for input_dataset.
Args
input_dataset A Tensor of type variant. A... | |
doc_2927 |
Scalar method identical to the corresponding array attribute. Please see ndarray.ravel. | |
doc_2928 | os.spawnle(mode, path, ..., env)
os.spawnlp(mode, file, ...)
os.spawnlpe(mode, file, ..., env)
os.spawnv(mode, path, args)
os.spawnve(mode, path, args, env)
os.spawnvp(mode, file, args)
os.spawnvpe(mode, file, args, env)
Execute the program path in a new process. (Note that the subprocess module provides ... | |
doc_2929 | tf.gradients(
ys, xs, grad_ys=None, name='gradients', gate_gradients=False,
aggregation_method=None, stop_gradients=None,
unconnected_gradients=tf.UnconnectedGradients.NONE
)
tf.gradients is only valid in a graph context. In particular, it is valid in the context of a tf.function wrapper, where code is exe... | |
doc_2930 | Set all fields of the record to 0, through MsiRecordClearData(). | |
doc_2931 |
Project the data by using matrix product with the random matrix Parameters
X{ndarray, sparse matrix} of shape (n_samples, n_features)
The input data to project into a smaller dimensional space. Returns
X_new{ndarray, sparse matrix} of shape (n_samples, n_components)
Projected array. | |
doc_2932 |
Return the picking behavior of the artist. The possible values are described in set_picker. See also
set_picker, pickable, pick | |
doc_2933 |
Return a copy of the array. Parameters
order{‘C’, ‘F’, ‘A’, ‘K’}, optional
Controls the memory layout of the copy. ‘C’ means C-order, ‘F’ means F-order, ‘A’ means ‘F’ if a is Fortran contiguous, ‘C’ otherwise. ‘K’ means match the layout of a as closely as possible. (Note that this function and numpy.copy are ve... | |
doc_2934 | os.O_NOINHERIT
os.O_SHORT_LIVED
os.O_TEMPORARY
os.O_RANDOM
os.O_SEQUENTIAL
os.O_TEXT
The above constants are only available on Windows. | |
doc_2935 |
Returns the (complex) conjugate transpose of self. Equivalent to np.transpose(self) if self is real-valued. Parameters
None
Returns
retmatrix object
complex conjugate transpose of self Examples >>> x = np.matrix(np.arange(12).reshape((3,4)))
>>> z = x - 1j*x; z
matrix([[ 0. +0.j, 1. -1.j, 2. -2.j, ... | |
doc_2936 | ipaddress.ip_address(address)
Return an IPv4Address or IPv6Address object depending on the IP address passed as argument. Either IPv4 or IPv6 addresses may be supplied; integers less than 2**32 will be considered to be IPv4 by default. A ValueError is raised if address does not represent a valid IPv4 or IPv6 address.... | |
doc_2937 | The SMTP server refused to accept the message data. | |
doc_2938 |
Alias for get_facecolor. | |
doc_2939 | Calls flush(), sets the target to None and clears the buffer. | |
doc_2940 | class sklearn.ensemble.VotingClassifier(estimators, *, voting='hard', weights=None, n_jobs=None, flatten_transform=True, verbose=False) [source]
Soft Voting/Majority Rule classifier for unfitted estimators. Read more in the User Guide. New in version 0.17. Parameters
estimatorslist of (str, estimator) tuples
... | |
doc_2941 | Returns the Well-Known Text of the geometry (an OGC standard). | |
doc_2942 |
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_2943 |
Draw a Path instance using the given affine transform. | |
doc_2944 |
Return an image showing the differences between two images. New in version 0.16. Parameters
image1, image22-D array
Images to process, must be of the same shape.
methodstring, optional
Method used for the comparison. Valid values are {‘diff’, ‘blend’, ‘checkerboard’}. Details are provided in the note sect... | |
doc_2945 | Returns an aware datetime that represents the same point in time as value in timezone, value being a naive datetime. If timezone is set to None, it defaults to the current time zone. Deprecated since version 4.0: When using pytz, the pytz.AmbiguousTimeError exception is raised if you try to make value aware during a D... | |
doc_2946 | Returns a list of strings ready for printing. Each string in the resulting list corresponds to a single frame from the stack. Each string ends in a newline; the strings may contain internal newlines as well, for those items with source text lines. For long sequences of the same frame and line, the first few repetitions... | |
doc_2947 | See Migration guide for more details. tf.compat.v1.raw_ops.QuantizedResizeBilinear
tf.raw_ops.QuantizedResizeBilinear(
images, size, min, max, align_corners=False, half_pixel_centers=False, name=None
)
Input images and output images must be quantized types.
Args
images A Tensor. Must be one of the follo... | |
doc_2948 |
Return dict of savefig file formats supported by this backend. | |
doc_2949 | Called when the incoming data stream matches the termination condition set by set_terminator(). The default method, which must be overridden, raises a NotImplementedError exception. The buffered input data should be available via an instance attribute. | |
doc_2950 | set the overlay pixel data display((y, u, v)) -> None display() -> None Display the YUV data in SDL's overlay planes. The y, u, and v arguments are strings of binary data. The data must be in the correct format used to create the Overlay. If no argument is passed in, the Overlay will simply be redrawn with the curren... | |
doc_2951 | Example: fav_color = request.session.get('fav_color', 'red') | |
doc_2952 | turtle.pos()
Return the turtle’s current location (x,y) (as a Vec2D vector). >>> turtle.pos()
(440.00,-0.00) | |
doc_2953 |
Apply map_fn to all of the function names. This can be used to regularize function names (e.g. stripping irrelevant parts of the file path), coalesce entries by mapping multiple functions to the same name (in which case the counts are added together), etc. | |
doc_2954 |
Set storage-indexed locations to corresponding values. Sets self._data.flat[n] = values[n] for each n in indices. If values is shorter than indices then it will repeat. If values has some masked values, the initial mask is updated in consequence, else the corresponding values are unmasked. Parameters
indices1-D a... | |
doc_2955 |
Register a custom accessor on Series objects. Parameters
name:str
Name under which the accessor should be registered. A warning is issued if this name conflicts with a preexisting attribute. Returns
callable
A class decorator. See also register_dataframe_accessor
Register a custom accessor on DataF... | |
doc_2956 | See torch.minimum() | |
doc_2957 | All arguments are optional, and all except for m should be specified in keyword form. Test examples in docstrings in functions and classes reachable from module m (or module __main__ if m is not supplied or is None), starting with m.__doc__. Also test examples reachable from dict m.__test__, if it exists and is not Non... | |
doc_2958 | Fills self tensor with elements samples from the normal distribution parameterized by mean and std. | |
doc_2959 |
Leave-P-Out cross-validator Provides train/test indices to split data in train/test sets. This results in testing on all distinct samples of size p, while the remaining n - p samples form the training set in each iteration. Note: LeavePOut(p) is NOT equivalent to KFold(n_splits=n_samples // p) which creates non-overl... | |
doc_2960 |
Add a colorbar to a plot. Parameters
mappable
The matplotlib.cm.ScalarMappable (i.e., AxesImage, ContourSet, etc.) described by this colorbar. This argument is mandatory for the Figure.colorbar method but optional for the pyplot.colorbar function, which sets the default to the current image. Note that one can cre... | |
doc_2961 |
Raise a Hermite series to a power. Returns the Hermite series c raised to the power pow. The argument c is a sequence of coefficients ordered from low to high. i.e., [1,2,3] is the series P_0 + 2*P_1 + 3*P_2. Parameters
carray_like
1-D array of Hermite series coefficients ordered from low to high.
powinteger
... | |
doc_2962 |
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_2963 | Read at most size bytes from the chunk (less if the read hits the end of the chunk before obtaining size bytes). If the size argument is negative or omitted, read all data until the end of the chunk. An empty bytes object is returned when the end of the chunk is encountered immediately. | |
doc_2964 |
Set the width of the rectangle. | |
doc_2965 |
Return the decision path in the tree. New in version 0.18. 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.
check_inputbool, default=True
Allow to bypa... | |
doc_2966 | Sets the current object instance (self.object). | |
doc_2967 |
Called when this tool gets used. This method is called by ToolManager.trigger_tool. Parameters
eventEvent
The canvas event that caused this tool to be called.
senderobject
Object that requested the tool to be triggered.
dataobject
Extra data. | |
doc_2968 |
TransformerEncoderLayer is made up of self-attn and feedforward network. This standard encoder layer is based on the paper “Attention Is All You Need”. Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advan... | |
doc_2969 |
Create a circle level set with binary values. Parameters
image_shapetuple of positive integers
Shape of the image
centertuple of positive integers, optional
Coordinates of the center of the circle given in (row, column). If not given, it defaults to the center of the image.
radiusfloat, optional
Radius ... | |
doc_2970 | See class documentation. | |
doc_2971 | Draws binary random numbers (0 or 1) from a Bernoulli distribution. The input tensor should be a tensor containing probabilities to be used for drawing the binary random number. Hence, all values in input have to be in the range: 0≤inputi≤10 \leq \text{input}_i \leq 1 . The ith\text{i}^{th} element of the output tenso... | |
doc_2972 | See Migration guide for more details. tf.compat.v1.raw_ops.SparseMatMul
tf.raw_ops.SparseMatMul(
a, b, transpose_a=False, transpose_b=False, a_is_sparse=False,
b_is_sparse=False, name=None
)
The inputs must be two-dimensional matrices and the inner dimension of "a" must match the outer dimension of "b". Both... | |
doc_2973 | Process a single command keystroke. Here are the supported special keystrokes:
Keystroke Action
Control-A Go to left edge of window.
Control-B Cursor left, wrapping to previous line if appropriate.
Control-D Delete character under cursor.
Control-E Go to right edge (stripspaces off) or end of line (stripspa... | |
doc_2974 | Checks whether there is a global language file for the given language code (e.g. ‘fr’, ‘pt_BR’). This is used to decide whether a user-provided language is available. | |
doc_2975 | closes a midi stream, flushing any pending buffers. close() -> None PortMidi attempts to close open streams when the application exits. Note This is particularly difficult under Windows. | |
doc_2976 | bytearray.lower()
Return a copy of the sequence with all the uppercase ASCII characters converted to their corresponding lowercase counterpart. For example: >>> b'Hello World'.lower()
b'hello world'
Lowercase ASCII characters are those byte values in the sequence b'abcdefghijklmnopqrstuvwxyz'. Uppercase ASCII charac... | |
doc_2977 |
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_2978 | A non-recursive lock object: a close analog of threading.Lock. Once a process or thread has acquired a lock, subsequent attempts to acquire it from any process or thread will block until it is released; any process or thread may release it. The concepts and behaviors of threading.Lock as it applies to threads are repli... | |
doc_2979 |
Return the topmost SubplotSpec instance associated with the subplot. | |
doc_2980 | The epilogue attribute acts the same way as the preamble attribute, except that it contains text that appears between the last boundary and the end of the message. As with the preamble, if there is no epilog text this attribute will be None. | |
doc_2981 | Base class for creating enumerated constants that can be combined using the bitwise operators without losing their IntFlag membership. IntFlag members are also subclasses of int. | |
doc_2982 | Return a string object containing two hexadecimal digits for each byte in the instance. >>> bytearray(b'\xf0\xf1\xf2').hex()
'f0f1f2'
New in version 3.5. Changed in version 3.8: Similar to bytes.hex(), bytearray.hex() now supports optional sep and bytes_per_sep parameters to insert separators between bytes in the h... | |
doc_2983 |
Bases: matplotlib.scale.LogScale Provide an arbitrary scale with user-supplied function for the axis and then put on a logarithmic axes. Parameters
axismatplotlib.axis.Axis
The axis for the scale.
functions(callable, callable)
two-tuple of the forward and inverse functions for the scale. The forward functio... | |
doc_2984 | The maximum size (in bytes) of the swap space that may be reserved or used by all of this user id’s processes. This limit is enforced only if bit 1 of the vm.overcommit sysctl is set. Please see tuning(7) for a complete description of this sysctl. Availability: FreeBSD 9 or later. New in version 3.4. | |
doc_2985 | Returns a compression object, to be used for compressing data streams that won’t fit into memory at once. level is the compression level – an integer from 0 to 9 or -1. A value of 1 (Z_BEST_SPEED) is fastest and produces the least compression, while a value of 9 (Z_BEST_COMPRESSION) is slowest and produces the most. 0 ... | |
doc_2986 |
Alias for get_markerfacecolor. | |
doc_2987 | bytearray.strip([chars])
Return a copy of the sequence with specified leading and trailing bytes removed. The chars argument is a binary sequence specifying the set of byte values to be removed - the name refers to the fact this method is usually used with ASCII characters. If omitted or None, the chars argument defa... | |
doc_2988 | Returns the east asian width assigned to the character chr as string. | |
doc_2989 |
Return indices that are non-zero in the flattened version of a. This is equivalent to np.nonzero(np.ravel(a))[0]. Parameters
aarray_like
Input data. Returns
resndarray
Output array, containing the indices of the elements of a.ravel() that are non-zero. See also nonzero
Return the indices of the n... | |
doc_2990 | See Migration guide for more details. tf.compat.v1.raw_ops.ZerosLike
tf.raw_ops.ZerosLike(
x, name=None
)
Args
x A Tensor. a tensor of type T.
name A name for the operation (optional).
Returns A Tensor. Has the same type as x. | |
doc_2991 | display various pixelarray generated effects pixelarray.main() -> None Display various pixelarray generated effects. | |
doc_2992 | def make_variables(k, initializer):
return (tf.Variable(initializer(shape=[k], dtype=tf.float32)),
tf.Variable(initializer(shape=[k, k], dtype=tf.float32)))
v1, v2 = make_variables(3, tf.zeros_initializer())
v1
<tf.Variable ... shape=(3,) ... numpy=array([0., 0., 0.], dtype=float32)>
v2
<tf.Variable ... sha... | |
doc_2993 |
Remove artists that are connected to the image viewer. | |
doc_2994 | @abc.abstractmethod
@tf_contextlib.contextmanager
as_default(
step=None
)
Returns a context manager that enables summary writing. For convenience, if step is not None, this function also sets a default value for the step parameter used in summary-writing functions elsewhere in the API so that it need not be explic... | |
doc_2995 | Add a new action at the beginning. See append() for explanations of the arguments. | |
doc_2996 | Returns a tensor with the same size as input filled with fill_value. torch.full_like(input, fill_value) is equivalent to torch.full(input.size(), fill_value, dtype=input.dtype, layout=input.layout, device=input.device). Parameters
input (Tensor) – the size of input will determine size of the output tensor.
fill_va... | |
doc_2997 |
A Grouper allows the user to specify a groupby instruction for an object. This specification will select a column via the key parameter, or if the level and/or axis parameters are given, a level of the index of the target object. If axis and/or level are passed as keywords to both Grouper and groupby, the values pass... | |
doc_2998 | Draw a border around the edges of the window. Each parameter specifies the character to use for a specific part of the border; see the table below for more details. Note A 0 value for any parameter will cause the default character to be used for that parameter. Keyword parameters can not be used. The defaults are list... | |
doc_2999 | Bind bye() method to mouse clicks on the Screen. If the value “using_IDLE” in the configuration dictionary is False (default value), also enter mainloop. Remark: If IDLE with the -n switch (no subprocess) is used, this value should be set to True in turtle.cfg. In this case IDLE’s own mainloop is active also for the cl... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.