id
stringlengths
16
145
text
stringlengths
1
179k
title
stringclasses
1 value
pytorch_torch_tensor_functions/Pytorch_Documentations_4_1.txt
kI0MUMxMUUyQUQzREIxQzRENUFFNUM5NiI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOkUxNkJENjdGQjNGMDExRTJBRDNEQjFDNEQ1QUU1Qzk2IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOkUxNkJENjgwQjNGMDExRTJBRDNEQjFDNEQ1QUU1Qzk2Ii8+IDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+hfPRaQAAB6lJR...
pytorch_torch_tensor_functions/Pytorch_Documentations_57_19.txt
eibull ` , ` RelaxedBernoulli ` and ` RelaxedOneHotCategorical ` ` arg_constraints ` _= {}_ ¶ ` cdf ` ( _value_ ) [ [source] ](_modules/torch/distributions/transformed_distribution.html#TransformedDistribution.cdf) ¶ Computes the cumulative distribution function by inverting the transform(s) and co...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_332_0.txt
# torch.Tensor.to_mkldnn ¶ Tensor. to_mkldnn ( ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns a copy of the tensor in ` torch.mkldnn ` layout.
pytorch_torch_tensor_functions/Pytorch_Documentations_59_0.txt
[ ](https://pytorch.org/) * [ Get Started ](https://pytorch.org/get-started) * Ecosystem [ Models (Beta) Discover, publish, and reuse pre-trained models ](https://pytorch.org/hub) [ Tools & Libraries Explore the ecosystem of tools and libraries ](https://pytorch.org/ecosystem) * [ Mobile ](https://pytorch....
pytorch_torch_tensor_functions/Pytorch_Documentations_2_0.txt
[ ](https://pytorch.org/) * [ Get Started ](https://pytorch.org/get-started) * Ecosystem [ Models (Beta) Discover, publish, and reuse pre-trained models ](https://pytorch.org/hub) [ Tools & Libraries Explore the ecosystem of tools and libraries ](https://pytorch.org/ecosystem) * [ Mobile ](https://pytorch....
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_59_0.txt
# torch.Tensor.untyped_storage ¶ Tensor. untyped_storage ( ) → [ torch.UntypedStorage ](../storage.html#torch.UntypedStorage "torch.UntypedStorage") ¶ Returns the underlying [ ` UntypedStorage ` ](../storage.html#torch.UntypedStorage "torch.UntypedStorage") .
pytorch_torch_tensor_functions/Pytorch_Documentations_12_3.txt
ds that share part/whole of the GraphTask. Custom Python ` autograd.function ` is automatically thread safe because of GIL. for built-in C++ Autograd Nodes(e.g. AccumulateGrad, CopySlices) and custom ` autograd::Function ` , the Autograd Engine uses thread mutex locking to protect thread safety on autograd Nodes tha...
pytorch_torch_tensor_functions/Pytorch_Documentations_19_3.txt
eMo * ![](/assets/images/logo-github.svg) * * NeMo: a toolkit for conversational AI. ](https://github.com/NVIDIA/NeMo) [ * MONAI * ![](/assets/images/logo-github.svg) * * MONAI provides domain-optimized foundational capabilities for developing healthcare imaging training workflows. ](https://monai...
pytorch_torch_tensor_functions/Pytorch_Documentations_11_2.txt
of the project such as a domain api (i.e. Torch Vision)?** This is absolutely possible. The first step is to start contributing to the existing project area and contributing to its health and success. In addition to this, you can make a proposal through a GitHub issue for new functionality or changes to improve the pr...
pytorch_torch_tensor_functions/Pytorch_Documentations_49_19.txt
er(). ` q_per_channel_scales ` ( ) → Tensor ¶ Given a Tensor quantized by linear (affine) per-channel quantization, returns a Tensor of scales of the underlying quantizer. It has the number of elements that matches the corresponding dimensions (from q_per_channel_axis) of the tensor. ` q_per_channel_zero_po...
pytorch_torch_tensor_functions/Pytorch_Documentations_27_7.txt
e nearest integer. [ ` fmod ` ](generated/torch.fmod.html#torch.fmod "torch.fmod") | Computes the element-wise remainder of division. [ ` frac ` ](generated/torch.frac.html#torch.frac "torch.frac") | Computes the fractional portion of each element in ` input ` . [ ` imag ` ](generated/torch.imag.html#tor...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_52_0.txt
# torch.Tensor.is_complex ¶ Tensor. is_complex ( ) → [ bool ](https://docs.python.org/3/library/functions.html#bool "\(in Python v3.12\)") ¶ Returns True if the data type of ` self ` is a complex data type.
pytorch_torch_tensor_functions/Pytorch_Documentations_20_1.txt
.com/apaszke) ) * Soumith Chintala ( [ soumith ](https://github.com/soumith) ) * Edward Yang ( [ ezyang ](https://github.com/ezyang) ) * Greg Chanan ( [ gchanan ](https://github.com/gchanan) ) * Dmytro Dzhulgakov ( [ dzhulgakov ](https://github.com/dzhulgakov) ) * (sunsetting) Sam Gross ( [ colesbur...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_367_0.txt
# torch.gather ¶ torch. gather ( _ input _ , _ dim _ , _ index _ , _ * _ , _ sparse_grad = False _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Gathers values along an axis specified by dim . For a 3-D tensor the output is specified by: out[i...
pytorch_torch_tensor_functions/Pytorch_Documentations_47_13.txt
s} H i n 1 ​ = in1_features and ∗ * ∗ > means any number of additional dimensions. All but the last dimension of the > inputs should be the same. > > * input2: ( N , ∗ , H i n 2 ) (N, *, H_{in2}) ( N , ∗ , H > i n 2 ​ ) where H i n 2 = in2_features > H_{in2}=\text{in2\\_features...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_224_0.txt
# torch.ne ¶ torch. ne ( _ input _ , _ other _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Computes input ≠ other \text{input} \neq \text{other} input  = other element-wise. The second argument can be a number or a tensor whose shape is [ broad...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_503_0.txt
# torch.Tensor.greater ¶ Tensor. greater ( _ other _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶
pytorch_torch_tensor_functions/Pytorch_Documentations_48_10.txt
** ( [ _bool_ ](https://docs.python.org/3/library/functions.html#bool "\(in Python v3.8\)") _,_ _default False_ ) – [DEPRECATED. use operator_export_type] export the model in aten mode. If using aten mode, all the ops original exported by the functions in symbolic_opset<version>.py are exported as ATen ops. * **exp...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_157_0.txt
# torch.Tensor.is_conj ¶ Tensor. is_conj ( ) → [ bool ](https://docs.python.org/3/library/functions.html#bool "\(in Python v3.12\)") ¶ Returns True if the conjugate bit of ` self ` is set to true.
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_356_0.txt
# torch.Tensor.item ¶ Tensor. item ( ) → number ¶ Returns the value of this tensor as a standard Python number. This only works for tensors with one element. For other cases, see [ ` tolist() ` ](torch.Tensor.tolist.html#torch.Tensor.tolist "torch.Tensor.tolist") . This operation is not differentiabl...
pytorch_torch_tensor_functions/Pytorch_Documentations_21_1.txt
libraries. ## Extending [ ` torch.autograd ` ](../autograd.html#module-torch.autograd "torch.autograd") ¶ Adding operations to [ ` autograd ` ](../autograd.html#module-torch.autograd "torch.autograd") requires implementing a new [ ` Function ` ](../autograd.html#torch.autograd.Function "torch.autograd.Function")...
pytorch_torch_tensor_functions/Pytorch_Documentations_37_11.txt
le ` ( _*args_ ) [ [source] ](_modules/torch/autograd/function.html#_ContextMethodMixin.mark_non_differentiable) ¶ Marks outputs as non-differentiable. **This should be called at most once, only from inside the** ` forward() ` **method, and all arguments should be outputs.** This will mark outputs as not re...
pytorch_torch_tensor_functions/Pytorch_Documentations_51_1.txt
* [ PyTorch ](https://pytorch.org) * [ Get Started ](/get-started) * [ Features ](/features) * [ Ecosystem ](/ecosystem) * [ Blog ](/blog) * [ Contributing ](https://github.com/pytorch/pytorch/blob/master/CONTRIBUTING.md) * [ Security ](https://github.com/pytorch/pytorch/security/policy) * [ Resources ]...
pytorch_torch_tensor_functions/Pytorch_Documentations_33_3.txt
e isn’t categorized properly comment and let the team know. ## About open source development ¶ If this is your first time contributing to an open source project, some aspects of the development process may seem unusual to you. * **There is no way to “claim” issues.** People often want to “claim” an issue when th...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_16_0.txt
# torch.subtract ¶ torch. subtract ( _ input _ , _ other _ , _ * _ , _ alpha = 1 _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Alias for [ ` torch.sub() ` ](torch.sub.html#torch.sub "torch.sub") .
pytorch_torch_tensor_functions/Pytorch_Documentations_58_55.txt
ution (class in torch.distributions.transformed_distribution) ](distributions.html#torch.distributions.transformed_distribution.TransformedDistribution) * [ Transformer (class in torch.nn) ](generated/torch.nn.Transformer.html#torch.nn.Transformer) * [ TransformerDecoder (class in torch.nn) ](generated/torch.nn.Tra...
pytorch_torch_tensor_functions/Pytorch_Documentations_7_12.txt
as: if Symmetric: s = 2 max ⁡ ( ∣ x min ∣ , x max ) / ( Q max − Q min ) z = { 0 if dtype is qint8 128 otherwise Otherwise: s = ( x max − x min ) / ( Q max − Q min ) z = Q min − round ( x min / s ) \begin{aligned} \text{if Symmetric:}&\\\ &s = 2 \max(|x_\text{min...
pytorch_torch_tensor_functions/Pytorch_Documentations_9_2.txt
ble_backward_tutorial.html) * [ Fusing Convolution and Batch Norm using Custom Function ](intermediate/custom_function_conv_bn_tutorial.html) * [ Custom C++ and CUDA Extensions ](advanced/cpp_extension.html) * [ Extending TorchScript with Custom C++ Operators ](advanced/torch_script_custom_ops.html) * [ Extendi...
pytorch_torch_tensor_functions/Pytorch_Documentations_26_0.txt
[ ](https://pytorch.org/) * [ Get Started ](https://pytorch.org/get-started) * Ecosystem [ Models (Beta) Discover, publish, and reuse pre-trained models ](https://pytorch.org/hub) [ Tools & Libraries Explore the ecosystem of tools and libraries ](https://pytorch.org/ecosystem) * [ Mobile ](https://pytorch....
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_221_0.txt
# torch.Tensor.short ¶ Tensor. short ( _ memory_format = torch.preserve_format _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶
pytorch_torch_tensor_functions/Pytorch_Documentations_49_4.txt
.torch.dtype "torch.torch.dtype") and [ ` torch.device ` ](tensor_attributes.html#torch.torch.device "torch.torch.device") as this tensor. Parameters * **size** ( _int..._ ) – a list, tuple, or ` torch.Size ` of integers defining the shape of the output tensor. * **dtype** ( [ ` torch.dtype ` ](tensor_...
pytorch_torch_tensor_functions/Pytorch_Documentations_35_5.txt
der that they appear in ` self ` . Python 2 does not support Ellipsis but one may use a string literal instead ( ` '...' ` ). Parameters **names** ( _iterable of str_ ) – The desired dimension ordering of the output tensor. May contain up to one Ellipsis that is expanded to all unmentioned dim names of ` sel...
pytorch_torch_tensor_functions/Pytorch_Documentations_61_1.txt
d [ ` torch.cuda.amp.GradScaler ` ](../amp.html#torch.cuda.amp.GradScaler "torch.cuda.amp.GradScaler") together. Instances of [ ` torch.cuda.amp.autocast ` ](../amp.html#torch.cuda.amp.autocast "torch.cuda.amp.autocast") enable autocasting for chosen regions. Autocasting automatically chooses the precision for GPU o...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_54_0.txt
# torch.Tensor.long ¶ Tensor. long ( _ memory_format = torch.preserve_format _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶
pytorch_torch_tensor_functions/Pytorch_Documentations_55_0.txt
[ ](https://pytorch.org/) * [ Get Started ](https://pytorch.org/get-started) * [ Ecosystem ](https://pytorch.org/ecosystem) * Edge [ About PyTorch Edge ](https://pytorch.org/edge) [ ExecuTorch ](https://pytorch.org/executorch) * [ Blog ](https://pytorch.org/blog/) * [ Tutorials ](https://pytorch.org/tuto...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_357_0.txt
# torch.movedim ¶ torch. movedim ( _ input _ , _ source _ , _ destination _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Moves the dimension(s) of ` input ` at the position(s) in ` source ` to the position(s) in ` destination ` . Other dimensions of ` input ` that are not explic...
pytorch_torch_tensor_functions/Pytorch_Documentations_3_1.txt
rch.html#FloatStorage) ¶ ` bfloat16 ` ( ) ¶ Casts this storage to bfloat16 type ` bool ` ( ) ¶ Casts this storage to bool type ` byte ` ( ) ¶ Casts this storage to byte type ` char ` ( ) ¶ Casts this storage to char type ` clone ` ( ) ¶ Returns a copy of this stor...
pytorch_torch_tensor_functions/Pytorch_Documentations_47_1.txt
everal input planes. See [ ` Conv1d ` ](generated/torch.nn.Conv1d.html#torch.nn.Conv1d "torch.nn.Conv1d") for details and output shape. Note In some circumstances when using the CUDA backend with CuDNN, this operator may select a nondeterministic algorithm to increase performance. If this is undesirable, you can tr...
pytorch_torch_tensor_functions/Pytorch_Documentations_20_0.txt
[ ](https://pytorch.org/) * [ Get Started ](https://pytorch.org/get-started) * Ecosystem [ Models (Beta) Discover, publish, and reuse pre-trained models ](https://pytorch.org/hub) [ Tools & Libraries Explore the ecosystem of tools and libraries ](https://pytorch.org/ecosystem) * [ Mobile ](https://pytorch....
pytorch_torch_tensor_functions/Pytorch_Documentations_64_1.txt
file is a zip file, it will be automatically decompressed. If the object is already present in model_dir , it’s deserialized and returned. The default value of model_dir is ` <hub_dir>/checkpoints ` where hub_dir is the directory returned by [ ` get_dir() ` ](hub.html#torch.hub.get_dir "torch.hub.get_dir") . ...
pytorch_torch_tensor_functions/Pytorch_Documentations_30_0.txt
If you are not redirected automatically, follow this [ link to the latest documentation ](/elastic/latest) . If you want to view documentation for a particular version, follow this [ link ](versions.html) .
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_150_0.txt
# torch.Tensor.log ¶ Tensor. log ( ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶
pytorch_torch_tensor_functions/Pytorch_Documentations_58_12.txt
tim.lr_scheduler) ](optim.html#torch.optim.lr_scheduler.CosineAnnealingWarmRestarts) * [ CosineEmbeddingLoss (class in torch.nn) ](generated/torch.nn.CosineEmbeddingLoss.html#torch.nn.CosineEmbeddingLoss) * [ CosineSimilarity (class in torch.nn) ](generated/torch.nn.CosineSimilarity.html#torch.nn.CosineSimilarity) ...
pytorch_torch_tensor_functions/Pytorch_Documentations_41_1.txt
/blog/high-performance-llama/) * [ Naver Case Study: Transition From High-Cost GPUs to Intel CPUs and oneAPI powered Software with performance ](https://pytorch.org/blog/ml-model-server-resource-saving/) * [ Run multiple generative AI models on GPU using Amazon SageMaker multi-model endpoints with TorchServe and ...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_427_0.txt
# torch.floor ¶ torch. floor ( _ input _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns a new tensor with the floor of the elements of ` input ` , the largest integer less than or equal to each element. For integer inputs, follows the array-api conv...
pytorch_torch_tensor_functions/Pytorch_Documentations_28_0.txt
[ ](https://pytorch.org/) * [ Get Started ](https://pytorch.org/get-started) * Ecosystem [ Models (Beta) Discover, publish, and reuse pre-trained models ](https://pytorch.org/hub) [ Tools & Libraries Explore the ecosystem of tools and libraries ](https://pytorch.org/ecosystem) * [ Mobile ](https://pytorch....
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_132_0.txt
# torch.Tensor.scatter_reduce ¶ Tensor. scatter_reduce ( _ dim _ , _ index _ , _ src _ , _ reduce _ , _ * _ , _ include_self = True _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Out-of-place version of [ ` torch.Tensor.scatter_reduce_() ` ](torch.Tensor.scatter_reduce_.html#to...
pytorch_torch_tensor_functions/Pytorch_Documentations_49_9.txt
nsor_attributes.html#torch.torch.memory_format "torch.torch.memory_format") , optional) – the desired memory format of returned Tensor. Default: ` torch.preserve_format ` . ` cross ` ( _other_ , _dim=-1_ ) → Tensor ¶ See [ ` torch.cross() ` ](generated/torch.cross.html#torch.cross "torch.cross") ` cuda ` ...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_77_0.txt
# torch.sqrt ¶ torch. sqrt ( _ input _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns a new tensor with the square-root of the elements of ` input ` . out i = input i \text{out}_{i} = \sqrt{\text{input}_{i}} out i ​ = input i ​ ​ Parame...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_26.txt
) ](tensors.html#torch.Tensor.irfft) * [ is_available() (in module torch.cuda) ](cuda.html#torch.cuda.is_available) * [ (in module torch.distributed) ](distributed.html#torch.distributed.is_available) * [ is_coalesced() (torch.sparse.FloatTensor method) ](sparse.html#torch.sparse.FloatTensor.is_coalesced) * [...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_35_0.txt
# torch.Tensor.exp ¶ Tensor. exp ( ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶
pytorch_torch_tensor_functions/Pytorch_Documentations_6_2.txt
ps://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf) * Stay Connected * Email Address [ ](https://www.facebook.com/pytorch) [ ](https://twitter.com/pytorch) [ ](https://www.youtube.com/pytorch) To analyze traffic and optimize your experience, we serve cookies on this site. By clicking or navi...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_352_0.txt
# torch.cosh ¶ torch. cosh ( _ input _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns a new tensor with the hyperbolic cosine of the elements of ` input ` . out i = cosh ⁡ ( input i ) \text{out}_{i} = \cosh(\text{input}_{i}) out i ​ = c...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_54.txt
buted.html#module-torch.distributed) * [ torch.distributed.autograd (module) ](rpc.html#module-torch.distributed.autograd) * [ torch.distributed.launch (module) ](distributed.html#module-torch.distributed.launch) * [ torch.distributed.optim (module) ](rpc.html#module-torch.distributed.optim) * [ torch.distribut...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_1_0.txt
# torch.istft ¶ torch. istft ( _ input _ , _ n_fft _ , _ hop_length = None _ , _ win_length = None _ , _ window = None _ , _ center = True _ , _ normalized = False _ , _ onesided = None _ , _ length = None _ , _ return_complex = False _ ) → Tensor: ¶ Inverse short time Fourier...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_56.txt
) * [ uniform_() (in module torch.nn.init) ](nn.init.html#torch.nn.init.uniform_) * [ (torch.Tensor method) ](tensors.html#torch.Tensor.uniform_) * [ unique() (in module torch) ](generated/torch.unique.html#torch.unique) * [ (torch.Tensor method) ](tensors.html#torch.Tensor.unique) * [ unique_consecutive(...
pytorch_torch_tensor_functions/Pytorch_Documentations_3_2.txt
n v3.8\)") ) – If ` True ` , and the source is in pinned memory and destination is on the GPU or vice versa, the copy is performed asynchronously with respect to the host. Otherwise, the argument has no effect. * ****kwargs** – For compatibility, may contain the key ` async ` in place of the ` non_blocking ` arg...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_495_0.txt
# torch.conj ¶ torch. conj ( _ input _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns a view of ` input ` with a flipped conjugate bit. If ` input ` has a non-complex dtype, this function just returns ` input ` . Note ` torch.conj() ` performs a lazy conjugation, but the a...
pytorch_torch_tensor_functions/Pytorch_Documentations_35_2.txt
pagate names** : _unify_ the names to select which one to propagate. In the case of ` x + y ` , ` unify('X', None) = 'X' ` because ` 'X' ` is more specific than ` None ` . >>> (x + y).names ('X',) >>> (x + x).names ('X',) For a comprehensive list of name inference rules, see [ ...
pytorch_torch_tensor_functions/Pytorch_Documentations_21_6.txt
ke to implement your overrides using a ` __torch_function__ ` implementation along these lines, you will need to explicitly implement the full ` torch ` API or the entire subset of the API that you care about for your use case. This may be a tall order as the full ` torch ` API is quite extensive. Another option is...
pytorch_torch_tensor_functions/Pytorch_Documentations_10_2.txt
t50 model trained with mixed precision using Tensor Cores. ![](/assets/images/nvidia_logo.png) ](/hub/nvidia_deeplearningexamples_resnet50/) [ * ResNeXt101 * * ![](/assets/images/logo-github.svg) * * ResNet with bottleneck 3x3 Convolutions substituted by 3x3 Grouped Convolutions, trained with mixed precis...
pytorch_torch_tensor_functions/Pytorch_Documentations_49_30.txt
mize your experience, we serve cookies on this site. By clicking or navigating, you agree to allow our usage of cookies. As the current maintainers of this site, Facebook’s Cookies Policy applies. Learn more, including about available controls: [ Cookies Policy ](https://www.facebook.com/policies/cookies/) . ![](_stat...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_465_0.txt
# torch.Tensor.dense_dim ¶ Tensor. dense_dim ( ) → [ int ](https://docs.python.org/3/library/functions.html#int "\(in Python v3.12\)") ¶ Return the number of dense dimensions in a [ sparse tensor ](../sparse.html#sparse-docs) ` self ` . Note Returns ` len(self.shape) ` if ` self ` is not a sparse t...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_52.txt
#torch.distributions.relaxed_categorical.RelaxedOneHotCategorical.support) * [ (torch.distributions.studentT.StudentT attribute) ](distributions.html#torch.distributions.studentT.StudentT.support) * [ (torch.distributions.von_mises.VonMises attribute) ](distributions.html#torch.distributions.von_mises.VonMises....
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_392_0.txt
# torch.round ¶ torch. round ( _ input _ , _ * _ , _ decimals = 0 _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Rounds elements of ` input ` to the nearest integer. For integer inputs, follows the array-api convention of returning a copy of the input tensor. ...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_40.txt
domUnstructured.html#torch.nn.utils.prune.RandomUnstructured.prune) * [ PruningContainer (class in torch.nn.utils.prune) ](generated/torch.nn.utils.prune.PruningContainer.html#torch.nn.utils.prune.PruningContainer) * [ ps_roi_align() (in module torchvision.ops) ](torchvision/ops.html#torchvision.ops.ps_roi_align) ...
pytorch_torch_tensor_functions/Pytorch_Documentations_56_0.txt
[ ](https://pytorch.org/) * [ Get Started ](https://pytorch.org/get-started) * Ecosystem [ Models (Beta) Discover, publish, and reuse pre-trained models ](https://pytorch.org/hub) [ Tools & Libraries Explore the ecosystem of tools and libraries ](https://pytorch.org/ecosystem) * [ Mobile ](https://pytorch....
pytorch_torch_tensor_functions/Pytorch_Documentations_32_1.txt
hort, if a PyTorch operation supports broadcast, then its Tensor arguments can be automatically expanded to be of equal sizes (without making copies of the data). ## General semantics ¶ Two tensors are “broadcastable” if the following rules hold: * Each tensor has at least one dimension. * When iterating ove...
pytorch_torch_tensor_functions/Pytorch_Documentations_37_17.txt
e serve cookies on this site. By clicking or navigating, you agree to allow our usage of cookies. As the current maintainers of this site, Facebook’s Cookies Policy applies. Learn more, including about available controls: [ Cookies Policy ](https://www.facebook.com/policies/cookies/) . ![](_static/images/pytorch-x.svg...
pytorch_torch_tensor_functions/Pytorch_Documentations_49_13.txt
4, 5, 6], [7, 8, 9]], dtype=torch.float) >>> index = torch.tensor([0, 4, 2]) >>> x.index_add_(0, index, t) tensor([[ 2., 3., 4.], [ 1., 1., 1.], [ 8., 9., 10.], [ 1., 1., 1.], [ 5., 6., 7.]]) ` index_add ` ( _tensor1_ , _dim_ , _...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_425_0.txt
# torch.amax ¶ torch. amax ( _ input _ , _ dim _ , _ keepdim = False _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns the maximum value of each slice of the ` input ` tensor in the given dimension(s) ` dim ` . Note The difference between ` ma...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_321_0.txt
# torch.Tensor.cuda ¶ Tensor. cuda ( _ device = None _ , _ non_blocking = False _ , _ memory_format = torch.preserve_format _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns a copy of this object in CUDA memory. If this object is already in CUDA memory and on the correct ...
pytorch_torch_tensor_functions/Pytorch_Documentations_27_4.txt
whose mean and standard deviation are given. [ ` poisson ` ](generated/torch.poisson.html#torch.poisson "torch.poisson") | Returns a tensor of the same size as ` input ` with each element sampled from a Poisson distribution with rate parameter given by the corresponding element in ` input ` i.e., [ ` rand ` ...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_388_0.txt
# torch.Tensor.rsqrt ¶ Tensor. rsqrt ( ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_176_0.txt
# torch.Tensor.cosh ¶ Tensor. cosh ( ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶
pytorch_torch_tensor_functions/Pytorch_Documentations_52_9.txt
` . [ ` prune.custom_from_mask ` ](generated/torch.nn.utils.prune.custom_from_mask.html#torch.nn.utils.prune.custom_from_mask "torch.nn.utils.prune.custom_from_mask") | Prunes tensor corresponding to parameter called ` name ` in ` module ` by applying the pre-computed mask in ` mask ` . [ ` prune.remove `...
pytorch_torch_tensor_functions/Pytorch_Documentations_24_4.txt
A tuple containing copies of the ` tensor ` , placed on devices corresponding to indices from ` devices ` . ` torch.cuda.comm. ` ` broadcast_coalesced ` ( _tensors_ , _devices_ , _buffer_size=10485760_ ) [ [source] ](_modules/torch/cuda/comm.html#broadcast_coalesced) ¶ Broadcasts a sequence tensors to the s...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_299_0.txt
# torch.Tensor.put_ ¶ Tensor. put_ ( _ index _ , _ source _ , _ accumulate = False _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Copies the elements from ` source ` into the positions specified by ` index ` . For the purpose of indexing, the ` self ` tensor is treated as if it ...
pytorch_torch_tensor_functions/Pytorch_Documentations_7_18.txt
u r e s ) * Bias: ( o u t _ f e a t u r e s ) (out\\_features) ( o u t _ f e a t u r e s ) * Output: ( N , ∗ , o u t _ f e a t u r e s ) (N, *, out\\_features) ( N , ∗ , o u t _ f e a t u r e s ) ` torch.nn.quantized.functional. ` ` conv1d ...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_474_0.txt
# torch.Tensor.masked_scatter ¶ Tensor. masked_scatter ( _ mask _ , _ tensor _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Out-of-place version of [ ` torch.Tensor.masked_scatter_() ` ](torch.Tensor.masked_scatter_.html#torch.Tensor.masked_scatter_ "torch.Tensor.masked_scatter_") N...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_79_0.txt
# torch.logaddexp ¶ torch. logaddexp ( _ input _ , _ other _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Logarithm of the sum of exponentiations of the inputs. Calculates pointwise log ⁡ ( e x \+ e y ) \log\left(e^x + e^y\right) lo g ( e x ...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_41.txt
nstructured() (in module torch.nn.utils.prune) ](generated/torch.nn.utils.prune.random_unstructured.html#torch.nn.utils.prune.random_unstructured) * [ RandomAffine (class in torchvision.transforms) ](torchvision/transforms.html#torchvision.transforms.RandomAffine) * [ RandomApply (class in torchvision.transforms) ]...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_450_0.txt
# torch.Tensor.map_ ¶ Tensor. map_ ( _ tensor _ , _ callable _ ) ¶ Applies ` callable ` for each element in ` self ` tensor and the given [ ` tensor ` ](torch.tensor.html#torch.tensor "torch.tensor") and stores the results in ` self ` tensor. ` self ` tensor and the given [ ` tensor ` ](torch.ten...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_156_0.txt
# torch.outer ¶ torch. outer ( _ input _ , _ vec2 _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Outer product of ` input ` and ` vec2 ` . If ` input ` is a vector of size n n n and ` vec2 ` is a vector of size m m m , then ` out ` must be a m...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_39_0.txt
# torch.orgqr ¶ torch. orgqr ( _ input _ , _ tau _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Alias for [ ` torch.linalg.householder_product() ` ](torch.linalg.householder_product.html#torch.linalg.householder_product "torch.linalg.householder_product") .
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_241_0.txt
# torch.nansum ¶ torch. nansum ( _ input _ , _ * _ , _ dtype = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns the sum of all elements, treating Not a Numbers (NaNs) as zero. Parameters **input** ( [ _Tensor_ ](../tensors.html#torch.Tensor "torch.Tensor") ) – th...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_15.txt
size() (torch.FloatStorage method) ](storage.html#torch.FloatStorage.element_size) * [ (torch.Tensor method) ](tensors.html#torch.Tensor.element_size) * [ ELU (class in torch.nn) ](generated/torch.nn.ELU.html#torch.nn.ELU) * [ (class in torch.nn.quantized) ](quantization.html#torch.nn.quantized.ELU) * [ elu...
pytorch_torch_tensor_functions/Pytorch_Documentations_22_4.txt
on. ` ` is_ninja_available ` ( ) [ [source] ](_modules/torch/utils/cpp_extension.html#is_ninja_available) ¶ Returns ` True ` if the [ ninja ](https://ninja-build.org/) build system is available on the system, ` False ` otherwise. [ Next ![](_static/images/chevron-right-orange.svg) ](data.html "torch.utils.d...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_284_0.txt
# torch.cumprod ¶ torch. cumprod ( _ input _ , _ dim _ , _ * _ , _ dtype = None _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Returns the cumulative product of elements of ` input ` in the dimension ` dim ` . For example, if ` input ` is a vector of size ...
pytorch_torch_tensor_functions/Pytorch_Documentations_58_10.txt
h.jit.ScriptModule.html#torch.jit.ScriptModule.code) * [ code_with_constants() (torch.jit.ScriptModule property) ](generated/torch.jit.ScriptModule.html#torch.jit.ScriptModule.code_with_constants) * [ collect_all() (in module torch.futures) ](futures.html#torch.futures.collect_all) * [ ColorJitter (class in torch...
pytorch_torch_tensor_functions/Pytorch_Documentations_24_7.txt
statistics, we also provide some simple event counters: * ` "num_alloc_retries" ` : number of failed ` cudaMalloc ` calls that result in a cache flush and retry. * ` "num_ooms" ` : number of out-of-memory errors thrown. Parameters **device** ( [ _torch.device_ ](tensor_attributes.html#torch.torch.dev...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_258_0.txt
# torch.hypot ¶ torch. hypot ( _ input _ , _ other _ , _ * _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Given the legs of a right triangle, return its hypotenuse. out i = input i 2 \+ other i 2 \text{out}_{i} = \sqrt{\text{input}_{i}^{2} + \text{othe...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_455_0.txt
# torch.corrcoef ¶ torch. corrcoef ( _ input _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Estimates the Pearson product-moment correlation coefficient matrix of the variables given by the ` input ` matrix, where rows are the variables and columns are the observations. Note The co...
pytorch_torch_tensor_functions/Solve_CUDA_out_of_memory_2_1.txt
mize speed and efficiency, while reducing memory usage and maintaining the neural network performance. Many parts of deep learning models, like activation functions, are less sensitive to precision. Therefore, carrying out these computations in half- precision (float16) can lead to a reduced memory footprint and faste...
pytorch_torch_tensor_functions/Pytorch_Documentations_9_3.txt
(intermediate/dist_pipeline_parallel_tutorial.html) * [ Implementing Batch RPC Processing Using Asynchronous Executions ](intermediate/rpc_async_execution.html) * [ Combining Distributed DataParallel with Distributed RPC Framework ](advanced/rpc_ddp_tutorial.html) * [ Training Transformer models using Distributed...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_84_0.txt
# torch.div ¶ torch. div ( _ input _ , _ other _ , _ * _ , _ rounding_mode = None _ , _ out = None _ ) → [ Tensor ](../tensors.html#torch.Tensor "torch.Tensor") ¶ Divides each element of the input ` input ` by the corresponding element of ` other ` . out i = input i other i \text{out...
pytorch_torch_tensor_functions/Pytorch_Documentations_7_6.txt
ated in favor of * ` interpolate() ` ### Quantized dtypes and quantization schemes ¶ * ` torch.qscheme ` — Type to describe the quantization scheme of a tensor. Supported types: * ` torch.per_tensor_affine ` — per tensor, asymmetric * ` torch.per_channel_affine ` — per channel, asymmetric ...
pytorch_torch_tensor_functions/pytorch_torch_tensor_functions_172_0.txt
# torch.Tensor.is_sparse ¶ Tensor. is_sparse ¶ Is ` True ` if the Tensor uses sparse COO storage layout, ` False ` otherwise.
pytorch_torch_tensor_functions/Pytorch_Documentations_7_23.txt
` ` ReLU ` ( _inplace=False_ ) [ [source] ](_modules/torch/nn/quantized/modules/activation.html#ReLU) ¶ Applies quantized rectified linear unit function element-wise: ReLU ( x ) = max ⁡ ( x 0 , x ) \text{ReLU}(x)= \max(x_0, x) ReLU ( x ) = max ( x 0 ​ , x ) , where x 0 x_0 x 0 ...
pytorch_torch_tensor_functions/Pytorch_Documentations_16_5.txt
Python int containing the number of recent consecutive unskipped steps. If this instance is not enabled, returns an empty dict. Note If you wish to checkpoint the scaler’s state after a particular iteration, ` state_dict() ` should be called after ` update() ` . ` step ` ( _optimizer_ , _*args_ , _**kwargs_ ...