torch.Storage¶
A 是单个
数据类型。torch.Storage
每torch.Tensor具有相同数据类型的相应存储。
-
class (*args, **kwargs)[来源]
torch.DoubleStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.FloatStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.HalfStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.LongStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.IntStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.ShortStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.CharStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.ByteStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.BoolStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.BFloat16Storage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.ComplexDoubleStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.ComplexFloatStorage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.QUInt8Storage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.QInt8Storage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.QInt32Storage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-
-
class (*args, **kwargs)[来源]
torch.QUInt4x2Storage¶ -
bfloat16()¶ 将此存储强制转换为 bfloat16 类型
-
bool()¶ 将此存储强制转换为 bool 类型
-
byte()¶ 将此存储强制转换为 byte 类型
-
char()¶ 将此存储强制转换为 char 类型
-
clone()¶ 返回此存储的副本
-
complex_double()¶ 将此存储转换为复杂的 double 类型
-
complex_float()¶ 将此存储强制转换为复杂的 float 类型
-
copy_(source, non_blocking=无)¶
-
cpu()¶ 如果此存储尚未在 CPU 上,则返回该存储的 CPU 副本
-
cuda(device=None, non_blocking=False, **kwargs)¶
-
data_ptr()¶
-
财产
device¶
-
double()¶ 将此存储强制转换为 double 类型
-
element_size()¶
-
fill_(价值)¶
-
float()¶ 将此存储强制转换为 float 类型
-
类方法 (*args, **kwargs
from_buffer)¶
-
classmethod (文件名、共享、大小
from_file)¶
-
get_device()¶
-
half()¶ 将此存储强制转换为 half 类型
-
int()¶ 将此存储转换为 int 类型
-
财产
is_cuda¶
-
is_pinned()¶
-
is_sparse= 假¶
-
long()¶ 将此存储强制转换为 long 类型
-
nbytes()¶
-
pickle_storage_type()¶
-
pin_memory()¶ 将存储复制到固定内存(如果尚未固定)。
-
resize_(大小)¶
将存储移动到共享内存。
对于共享内存中已有的存储和 CUDA,这是无作 存储,无需移动即可跨进程共享。 共享内存中的存储无法调整大小。
返回: self
-
short()¶ 将此存储转换为 short 类型
-
size()¶
-
tolist()¶ 返回包含此存储的元素的列表
-
type(dtype=无,non_blocking=False)¶
-