47 explicit Dtype(DtypeCode dtype_code,
49 const std::string &
name);
58 int64_t
ByteSize()
const {
return byte_size_; }
62 bool IsObject()
const {
return dtype_code_ == DtypeCode::Object; }
71 static constexpr
size_t max_name_len_ = 16;
72 DtypeCode dtype_code_;
74 char name_[max_name_len_];
91 inline const Dtype Dtype::FromType<float>() {
96 inline const Dtype Dtype::FromType<double>() {
101 inline const Dtype Dtype::FromType<int8_t>() {
106 inline const Dtype Dtype::FromType<int16_t>() {
111 inline const Dtype Dtype::FromType<int32_t>() {
116 inline const Dtype Dtype::FromType<int64_t>() {
121 inline const Dtype Dtype::FromType<uint8_t>() {
126 inline const Dtype Dtype::FromType<uint16_t>() {
131 inline const Dtype Dtype::FromType<uint32_t>() {
136 inline const Dtype Dtype::FromType<uint64_t>() {
141 inline const Dtype Dtype::FromType<bool>() {
#define LogError(...)
Definition: Logging.h:48
#define OPEN3D_API
Definition: Macro.h:31
static const Dtype UInt8
Definition: Dtype.h:29
static const Dtype Bool
Definition: Dtype.h:33
static const Dtype Int16
Definition: Dtype.h:26
DtypeCode GetDtypeCode() const
Definition: Dtype.h:60
static const Dtype UInt32
Definition: Dtype.h:31
static const Dtype Float64
Definition: Dtype.h:24
Dtype()
Definition: Dtype.h:45
static const Dtype Int32
Definition: Dtype.h:27
static const Dtype UInt16
Definition: Dtype.h:30
std::string ToString() const
Definition: Dtype.h:64
static const Dtype UInt64
Definition: Dtype.h:32
static const Dtype Float32
Definition: Dtype.h:23
bool IsObject() const
Definition: Dtype.h:62
static const Dtype Undefined
Definition: Dtype.h:22
int64_t ByteSize() const
Definition: Dtype.h:58
static const Dtype Int8
Definition: Dtype.h:25
static const Dtype FromType()
Definition: Dtype.h:54
DtypeCode
Definition: Dtype.h:36
static const Dtype Int64
Definition: Dtype.h:28
const Dtype UInt32
Definition: Dtype.cpp:50
const Dtype Int64
Definition: Dtype.cpp:47
const Dtype UInt16
Definition: Dtype.cpp:49
const Dtype Bool
Definition: Dtype.cpp:52
const Dtype Int32
Definition: Dtype.cpp:46
const Dtype Int16
Definition: Dtype.cpp:45
const Dtype Undefined
Definition: Dtype.cpp:41
const Dtype UInt8
Definition: Dtype.cpp:48
const Dtype Float64
Definition: Dtype.cpp:43
const Dtype UInt64
Definition: Dtype.cpp:51
const Dtype Int8
Definition: Dtype.cpp:44
const Dtype Float32
Definition: Dtype.cpp:42
bool operator==(const PointXYZ A, const PointXYZ B)
Definition: Cloud.h:157
constexpr bool operator!=(const optional< T > &x, const optional< T > &y)
Definition: Optional.h:631
Definition: PinholeCameraIntrinsic.cpp:16