_id
stringlengths
5
9
text
stringlengths
5
385k
title
stringclasses
1 value
doc_28400
Sets the number of columns used by the curses library when converting a tab character to spaces as it adds the tab to a window. New in version 3.9.
doc_28401
See Migration guide for more details. tf.compat.v1.raw_ops.ResizeBilinear tf.raw_ops.ResizeBilinear( images, size, align_corners=False, half_pixel_centers=False, name=None ) Input images can be of different types but output images are always float. Args images A Tensor. Must be one of the following type...
doc_28402
on a Plugin instance. The Plugin will delegate action based on the widget’s parameter type specified by its ptype attribute, which can be: 'arg' : positional argument passed to Plugin's `filter_image` method. 'kwarg' : keyword argument passed to Plugin's `filter_image` method. 'plugin' : attribute of Plugin. You'll pr...
doc_28403
'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_28404
bbox(item, column=None) Returns the bounding box (relative to the treeview widget’s window) of the specified item in the form (x, y, width, height). If column is specified, returns the bounding box of that cell. If the item is not visible (i.e., if it is a descendant of a closed item or is scrolled offscreen), retu...
doc_28405
Determines whether the given object represents a scalar data-type. Parameters repany If rep is an instance of a scalar dtype, True is returned. If not, False is returned. Returns outbool Boolean result of check whether rep is a scalar dtype. See also issubsctype, issubdtype, obj2sctype, sctype2ch...
doc_28406
The method the request was made with, such as GET.
doc_28407
Indicates if an interval is empty, meaning it contains no points. New in version 0.25.0. Returns bool or ndarray A boolean indicating if a scalar Interval is empty, or a boolean ndarray positionally indicating if an Interval in an IntervalArray or IntervalIndex is empty. Examples An Interval that contains p...
doc_28408
Makes an OPTIONS request on the provided path and returns a Response object. Useful for testing RESTful interfaces. When data is provided, it is used as the request body, and a Content-Type header is set to content_type. The follow, secure and extra arguments act the same as for Client.get().
doc_28409
Bases: matplotlib.dates.DateLocator Parameters tzdatetime.tzinfo staticget_unit_generic(freq)[source] tick_values(vmin, vmax)[source] Return the values of the located ticks given vmin and vmax. Note To get tick locations with the vmin and vmax values defined automatically for the associated axis simp...
doc_28410
Return the current context for the active thread.
doc_28411
Similar to redirect_stdout() but redirecting sys.stderr to another file or file-like object. This context manager is reentrant. New in version 3.5.
doc_28412
Extract a diagonal or construct a diagonal array. See the more detailed documentation for numpy.diagonal if you use this function to extract a diagonal and wish to write to the resulting array; whether it returns a copy or a view depends on what version of numpy you are using. Parameters varray_like If v is a 2...
doc_28413
For each element in self, return a copy with the trailing characters removed. See also char.rstrip
doc_28414
from myapp.serializers import UserSerializer from rest_framework import generics from rest_framework.permissions import IsAdminUser class UserList(generics.ListCreateAPIView): queryset = User.objects.all() serializer_class = UserSerializer permission_classes = [IsAdminUser] For more complex cases you migh...
doc_28415
See Migration guide for more details. tf.compat.v1.raw_ops.ImageSummary tf.raw_ops.ImageSummary( tag, tensor, max_images=3, bad_color=_execute.make_tensor(\n 'dtype: DT_UINT8 tensor_shape { dim { size: 4 } } int_val: 255 int_val: 0 int_val: 0 int_val: 255'\n , 'bad_color'), name=None ) The summary ...
doc_28416
A mixin for modules that lazily initialize parameters, also known as “lazy modules.” Modules that lazily initialize parameters, or “lazy modules”, derive the shapes of their parameters from the first input(s) to their forward method. Until that first forward they contain torch.nn.UninitializedParameter`s that should ...
doc_28417
Test whether input is an instance of MaskedArray. This function returns True if x is an instance of MaskedArray and returns False otherwise. Any object is accepted as input. Parameters xobject Object to test. Returns resultbool True if x is a MaskedArray. See also isMA Alias to isMaskedArray. is...
doc_28418
Returns the initial seed for generating random numbers as a Python long.
doc_28419
The get_ordering method takes a request as parameter and is expected to return a list or tuple for ordering similar to the ordering attribute. For example: class PersonAdmin(admin.ModelAdmin): def get_ordering(self, request): if request.user.is_superuser: return ['name', 'rank'] else: ...
doc_28420
Represent the path as a file URI. ValueError is raised if the path isn’t absolute. >>> p = PurePosixPath('/etc/passwd') >>> p.as_uri() 'file:///etc/passwd' >>> p = PureWindowsPath('c:/Windows') >>> p.as_uri() 'file:///c:/Windows'
doc_28421
Returns the number of non-fixed hyperparameters of the kernel.
doc_28422
Return a list of all registered formats for unpacking. Each element of the returned sequence is a tuple (name, extensions, description). By default shutil provides these formats: zip: ZIP file (unpacking compressed files works only if the corresponding module is available). tar: uncompressed tar file. gztar: gzip’e...
doc_28423
class sklearn.gaussian_process.kernels.Sum(k1, k2) [source] The Sum kernel takes two kernels \(k_1\) and \(k_2\) and combines them via \[k_{sum}(X, Y) = k_1(X, Y) + k_2(X, Y)\] Note that the __add__ magic method is overridden, so Sum(RBF(), RBF()) is equivalent to using the + operator with RBF() + RBF(). Read more i...
doc_28424
Returns sum(x*y) - sum(x) * sum(y)/N (“sum of products” of independent times dependent variable) as a float, or default if there aren’t any matching rows.
doc_28425
tf.compat.v1.TextLineReader( skip_header_lines=None, name=None ) Newlines are stripped from the output. See ReaderBase for supported methods. Args skip_header_lines An optional int. Defaults to 0. Number of lines to skip from the beginning of every file. name A name for the operation (optional). ...
doc_28426
Eliminates all but the first element from every consecutive group of equivalent elements. See torch.unique_consecutive()
doc_28427
Set the font family. May be either a single string, or a list of strings in decreasing priority. Each string may be either a real font name or a generic font class name. If the latter, the specific font names will be looked up in the corresponding rcParams. If a Text instance is constructed with fontfamily=None, then...
doc_28428
Removes the file from the model instance and deletes the underlying file. If save is True, the model’s save() method will be called once the file is deleted.
doc_28429
Returns a tzinfo instance that represents a time zone with a fixed offset from UTC. offset is a datetime.timedelta or an integer number of minutes. Use positive values for time zones east of UTC and negative values for west of UTC.
doc_28430
Return the left endpoints of each Interval in the IntervalArray as an Index.
doc_28431
Get the text size.
doc_28432
Appends items from the string, interpreting the string as an array of machine values (as if it had been read from a file using the fromfile() method). New in version 3.2: fromstring() is renamed to frombytes() for clarity.
doc_28433
The SSLSession for this SSL connection. The session is available for client and server side sockets after the TLS handshake has been performed. For client sockets the session can be set before do_handshake() has been called to reuse a session. New in version 3.6.
doc_28434
[Deprecated] Return a hashable tuple of properties. Not intended to be human readable, but useful for backends who want to cache derived information about text (e.g., layouts) and need to know if the text has changed. Notes Deprecated since version 3.5.
doc_28435
tf.experimental.numpy.iinfo( int_type ) Machine limits for integer types. Attributes bits : int The number of bits occupied by the type. min : int The smallest integer expressible by the type. max : int The largest integer expressible by the type. Parameters int_type : integer type, dtype, or instance The kind of ...
doc_28436
tf.compat.v1.logging.vlog( level, msg, *args, **kwargs )
doc_28437
Bases: matplotlib.widgets.AxesWidget A GUI neutral set of check buttons. For the check buttons to remain responsive you must keep a reference to this object. Connect to the CheckButtons with the on_clicked method. Attributes axAxes The parent axes for the widget. labelslist of Text rectangleslist of Rectang...
doc_28438
Get the edge color of the Figure rectangle.
doc_28439
In-place version of trunc()
doc_28440
Receive notification of the beginning of a document. The SAX parser will invoke this method only once, before any other methods in this interface or in DTDHandler (except for setDocumentLocator()).
doc_28441
A Rule represents one URL pattern. There are some options for Rule that change the way it behaves and are passed to the Rule constructor. Note that besides the rule-string all arguments must be keyword arguments in order to not break the application on Werkzeug upgrades. string Rule strings basically are just norma...
doc_28442
Get the parameters of an estimator from the ensemble. Returns the parameters given in the constructor as well as the estimators contained within the estimators parameter. Parameters deepbool, default=True Setting it to True gets the various estimators and the parameters of the estimators as well.
doc_28443
Get the bounds of the spine.
doc_28444
An immutable MultiDict. Changelog New in version 0.5. copy() Return a shallow mutable copy of this object. Keep in mind that the standard library’s copy() function is a no-op for this class like for any other python immutable type (eg: tuple).
doc_28445
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_28446
Skip to the end of the chunk. All further calls to read() for the chunk will return b''. If you are not interested in the contents of the chunk, this method should be called so that the file points to the start of the next chunk.
doc_28447
Refine a field defined on the encapsulated triangulation. Parameters z(npoints,) array-like Values of the field to refine, defined at the nodes of the encapsulated triangulation. (n_points is the number of points in the initial triangulation) triinterpolatorTriInterpolator, optional Interpolator used for fi...
doc_28448
See Migration guide for more details. tf.compat.v1.keras.activations.deserialize tf.keras.activations.deserialize( name, custom_objects=None ) Args name The name of the activation function. custom_objects Optional {function_name: function_obj} dictionary listing user-provided activation functions....
doc_28449
Set the edgecolor(s) of the LineCollection. Parameters ccolor or list of colors Single color (all lines have same color), or a sequence of rgba tuples; if it is a sequence the lines will cycle through the sequence.
doc_28450
See Migration guide for more details. tf.compat.v1.keras.layers.PReLU tf.keras.layers.PReLU( alpha_initializer='zeros', alpha_regularizer=None, alpha_constraint=None, shared_axes=None, **kwargs ) It follows: f(x) = alpha * x for x < 0 f(x) = x for x >= 0 where alpha is a learned array with the same shape as...
doc_28451
Generate an S curve dataset. Read more in the User Guide. Parameters n_samplesint, default=100 The number of sample points on the S curve. noisefloat, default=0.0 The standard deviation of the gaussian noise. random_stateint, RandomState instance or None, default=None Determines random number generation...
doc_28452
The value of the step parameter (or 1 if the parameter was not supplied)
doc_28453
Return the barrier to the default, empty state. Any threads waiting on it will receive the BrokenBarrierError exception. Note that using this function may require some external synchronization if there are other threads whose state is unknown. If a barrier is broken it may be better to just leave it and create a new on...
doc_28454
See torch.eq()
doc_28455
Compute chi-squared stats between each non-negative feature and class. This score can be used to select the n_features features with the highest values for the test chi-squared statistic from X, which must contain only non-negative features such as booleans or frequencies (e.g., term counts in document classification...
doc_28456
Create the Jinja environment based on jinja_options and the various Jinja-related methods of the app. Changing jinja_options after this will have no effect. Also adds Flask-related globals and filters to the environment. Changelog Changed in version 0.11: Environment.auto_reload set in accordance with TEMPLATES_AUTO_R...
doc_28457
Read data from the stream until separator is found. On success, the data and separator will be removed from the internal buffer (consumed). Returned data will include the separator at the end. If the amount of data read exceeds the configured stream limit, a LimitOverrunError exception is raised, and the data is left i...
doc_28458
Return the Colormap instance.
doc_28459
Subclass of TurtleScreen, with four methods added.
doc_28460
Return self+=value.
doc_28461
Return the Colormap instance.
doc_28462
Return the proleptic Gregorian ordinal of the date, where January 1 of year 1 has ordinal 1. For any date object d, date.fromordinal(d.toordinal()) == d.
doc_28463
tf.experimental.numpy.any( a, axis=None, keepdims=None ) Unsupported arguments: out. See the NumPy documentation for numpy.any.
doc_28464
Register a Blueprint on the application. Keyword arguments passed to this method will override the defaults set on the blueprint. Calls the blueprint’s register() method after recording the blueprint in the application’s blueprints. Parameters blueprint (Blueprint) – The blueprint to register. url_prefix – Bluepri...
doc_28465
See Migration guide for more details. tf.compat.v1.raw_ops.ChooseFastestDataset tf.raw_ops.ChooseFastestDataset( input_datasets, num_experiments, output_types, output_shapes, name=None ) Args input_datasets A list of at least 2 Tensor objects with type variant. num_experiments An int. output_t...
doc_28466
Integrate. Return a series instance that is the definite integral of the current series. Parameters mnon-negative int The number of integrations to perform. karray_like Integration constants. The first constant is applied to the first integration, the second to the second, and so on. The list of values must...
doc_28467
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_28468
A bit-width name for this data-type. Un-sized flexible data-type objects do not have this attribute. Examples >>> x = np.dtype(float) >>> x.name 'float64' >>> x = np.dtype([('a', np.int32, 8), ('b', np.float64, 6)]) >>> x.name 'void640'
doc_28469
Mean Tweedie deviance regression loss. Read more in the User Guide. Parameters y_truearray-like of shape (n_samples,) Ground truth (correct) target values. y_predarray-like of shape (n_samples,) Estimated target values. sample_weightarray-like of shape (n_samples,), default=None Sample weights. powerf...
doc_28470
Reduce and scatter a list of tensors to the whole group. Only nccl backend is currently supported. Each tensor in output_tensor_list should reside on a separate GPU, as should each list of tensors in input_tensor_lists. Parameters output_tensor_list (List[Tensor]) – Output tensors (on different GPUs) to receive ...
doc_28471
Clear the cache. Use this function if you no longer need lines from files previously read using getline().
doc_28472
Returns a new tensor with the reciprocal of the square-root of each of the elements of input. outi=1inputi\text{out}_{i} = \frac{1}{\sqrt{\text{input}_{i}}} Parameters input (Tensor) – the input tensor. Keyword Arguments out (Tensor, optional) – the output tensor. Example: >>> a = torch.randn(4) >>> a tensor([...
doc_28473
See Migration guide for more details. tf.compat.v1.raw_ops.QuantizedMatMulWithBiasAndRequantize tf.raw_ops.QuantizedMatMulWithBiasAndRequantize( a, b, bias, min_a, max_a, min_b, max_b, min_freezed_output, max_freezed_output, Toutput=tf.dtypes.quint8, transpose_a=False, transpose_b=False, input_quant_mode=...
doc_28474
Set the agg filter. Parameters filter_funccallable A filter function, which takes a (m, n, 3) float array and a dpi value, and returns a (m, n, 3) array.
doc_28475
Return whether automatic mode for offset notation is active. This returns True if set_useOffset(True); it returns False if an explicit offset was set, e.g. set_useOffset(1000). See also ScalarFormatter.set_useOffset
doc_28476
Set the Axes locator. Parameters locatorCallable[[Axes, Renderer], Bbox] Examples using matplotlib.axes.Axes.set_axes_locator HBoxDivider demo
doc_28477
Information about the memory layout of the array. Notes The flags object can be accessed dictionary-like (as in a.flags['WRITEABLE']), or by using lowercased attribute names (as in a.flags.writeable). Short flag names are only supported in dictionary access. Only the WRITEBACKIFCOPY, UPDATEIFCOPY, WRITEABLE, and ALIG...
doc_28478
See Migration guide for more details. tf.compat.v1.tpu.experimental.embedding.FeatureConfig tf.tpu.experimental.embedding.FeatureConfig( table: tf.tpu.experimental.embedding.TableConfig, max_sequence_length: int = 0, name: Optional[Text] = None ) This class holds the configuration data for a single embed...
doc_28479
Return index of first occurrence of maximum over requested axis. NA/null values are excluded. Parameters axis:{0 or ‘index’, 1 or ‘columns’}, default 0 The axis to use. 0 or ‘index’ for row-wise, 1 or ‘columns’ for column-wise. skipna:bool, default True Exclude NA/null values. If an entire row/column is NA,...
doc_28480
Check whether an array-like or dtype is of the Period dtype. Parameters arr_or_dtype:array-like or dtype The array-like or dtype to check. Returns boolean Whether or not the array-like or dtype is of the Period dtype. Examples >>> is_period_dtype(object) False >>> is_period_dtype(PeriodDtype(freq="D"...
doc_28481
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_28482
class sklearn.neighbors.DistanceMetric DistanceMetric class This class provides a uniform interface to fast distance metric functions. The various metrics can be accessed via the get_metric class method and the metric string identifier (see below). Examples >>> from sklearn.neighbors import DistanceMetric >>> dist = ...
doc_28483
See torch.lt().
doc_28484
get the additional flags used for the Surface get_flags() -> int Returns a set of current Surface features. Each feature is a bit in the flags bitmask. Typical flags are HWSURFACE, RLEACCEL, SRCALPHA, and SRCCOLORKEY. Here is a more complete list of flags. A full list can be found in SDL_video.h SWSURFACE 0x0000...
doc_28485
Create a new dictionary with keys from iterable and values set to value. fromkeys() is a class method that returns a new dictionary. value defaults to None. All of the values refer to just a single instance, so it generally doesn’t make sense for value to be a mutable object such as an empty list. To get distinct value...
doc_28486
template_name: 'django/forms/widgets/splithiddendatetime.html' Similar to SplitDateTimeWidget, but uses HiddenInput for both date and time.
doc_28487
Bases: mpl_toolkits.axisartist.axislines.AxisArtistHelper._Base Helper class for a fixed (in the axes coordinate) axis. nth_coord = along which coordinate value varies in 2D, nth_coord = 0 -> x axis, nth_coord = 1 -> y axis get_axislabel_pos_angle(axes)[source] Return the label reference position in transAxes. ge...
doc_28488
Test whether the mouse event occurred in the collection. Returns bool, dict(ind=itemlist), where every item in itemlist contains the event.
doc_28489
Get the current data Returns verts3dlength-3 tuple or array-like The current data as a tuple or array-like.
doc_28490
Read bytes into a pre-allocated, writable bytes-like object b and return the number of bytes read. For example, b might be a bytearray. Like read(), multiple reads may be issued to the underlying raw stream, unless the latter is interactive. A BlockingIOError is raised if the underlying raw stream is in non blocking-mo...
doc_28491
A decorator that is used to register custom template test. You can specify a name for the test, otherwise the function name will be used. Example: @app.template_test() def is_prime(n): if n == 2: return True for i in range(2, int(math.ceil(math.sqrt(n))) + 1): if n % i == 0: return F...
doc_28492
Check whether all characters in each string are whitespace. This is equivalent to running the Python string method str.isspace() for each element of the Series/Index. If a string has zero characters, False is returned for that check. Returns Series or Index of bool Series or Index of boolean values with the same ...
doc_28493
Label a bar plot. Adds labels to bars in the given BarContainer. You may need to adjust the axis limits to fit the labels. Parameters containerBarContainer Container with all the bars and optionally errorbars, likely returned from bar or barh. labelsarray-like, optional A list of label texts, that should be...
doc_28494
Returns a self.response_class instance. If any keyword arguments are provided, they will be passed to the constructor of the response class. Calls get_template_names() to obtain the list of template names that will be searched looking for an existent template.
doc_28495
Returns a list of all hyperparameter specifications.
doc_28496
See Migration guide for more details. tf.compat.v1.raw_ops.FilterDataset tf.raw_ops.FilterDataset( input_dataset, other_arguments, predicate, output_types, output_shapes, name=None ) The predicate function must return a scalar boolean and accept the following arguments: One tensor for each component of an e...
doc_28497
Compute the N-dimensional discrete Fourier Transform. This function computes the N-dimensional discrete Fourier Transform over any number of axes in an M-dimensional array by means of the Fast Fourier Transform (FFT). Parameters aarray_like Input array, can be complex. ssequence of ints, optional Shape (len...
doc_28498
Returns a list of files named ‘fname’ from 1) System-wide directory (directory-location of this module) 2) Users HOME directory (os.environ[‘HOME’]) 3) Local directory
doc_28499
Generates a sample_shape shaped sample or sample_shape shaped batch of samples if the distribution parameters are batched.