% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/creation-ops.R
\name{torch_scalar_tensor}
\alias{torch_scalar_tensor}
\title{Scalar tensor}
\usage{
torch_scalar_tensor(value, dtype = NULL, device = NULL, requires_grad = FALSE)
}
\arguments{
\item{value}{the value you want to use}

\item{dtype}{(\code{torch.dtype}, optional) the desired data type of returned tensor.        Default: if \code{NULL}, uses a global default (see \code{torch_set_default_tensor_type}).}

\item{device}{(\code{torch.device}, optional) the desired device of returned tensor.        Default: if \code{NULL}, uses the current device for the default tensor type        (see \code{torch_set_default_tensor_type}). \code{device} will be the CPU        for CPU tensor types and the current CUDA device for CUDA tensor types.}

\item{requires_grad}{(bool, optional) If autograd should record operations on the        returned tensor. Default: \code{FALSE}.}
}
\description{
Creates a singleton dimension tensor.
}
