Skip to content

Commit cc42af0

Browse files
committed
refactor: rename ToAtenDtype to ToAtenDataType
1 parent 24572c8 commit cc42af0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/torch/tensor_.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ inline at::ScalarType ToAtenUnsignedDataType(DataType dtype) {
4848

4949
} // namespace detail
5050

51-
inline at::ScalarType ToAtenDtype(DataType dtype) {
51+
inline at::ScalarType ToAtenDataType(DataType dtype) {
5252
switch (dtype) {
5353
case DataType::kInt8:
5454
return at::kChar;
@@ -88,7 +88,7 @@ inline at::Tensor ToAtenTensor(void* data, const Tensor::Shape& shape,
8888
std::vector<int64_t> at_shape(shape.begin(), shape.end());
8989
std::vector<int64_t> at_strides(strides.begin(), strides.end());
9090

91-
auto options = at::TensorOptions().dtype(ToAtenDtype(dtype));
91+
auto options = at::TensorOptions().dtype(ToAtenDataType(dtype));
9292

9393
if constexpr (kDev != Device::Type::kCpu) {
9494
std::string device_str =

0 commit comments

Comments
 (0)