| @@ -13,6 +13,4 @@ add_library(cpp-API OBJECT | |||||
| iterator.cc | iterator.cc | ||||
| transforms.cc | transforms.cc | ||||
| samplers.cc | samplers.cc | ||||
| de_tensor.cc | |||||
| execute.cc | |||||
| ) | ) | ||||
| @@ -38,18 +38,21 @@ | |||||
| #include "minddata/dataset/core/data_type.h" | #include "minddata/dataset/core/data_type.h" | ||||
| #include "minddata/dataset/core/tensor_shape.h" | #include "minddata/dataset/core/tensor_shape.h" | ||||
| #include "minddata/dataset/util/status.h" | #include "minddata/dataset/util/status.h" | ||||
| #include "minddata/dataset/include/de_tensor.h" | |||||
| #ifndef ENABLE_ANDROID | #ifndef ENABLE_ANDROID | ||||
| #include "proto/example.pb.h" | #include "proto/example.pb.h" | ||||
| #else | |||||
| #include "minddata/dataset/include/de_tensor.h" | |||||
| #endif | #endif | ||||
| #ifdef ENABLE_PYTHON | #ifdef ENABLE_PYTHON | ||||
| namespace py = pybind11; | namespace py = pybind11; | ||||
| #endif | #endif | ||||
| namespace mindspore { | namespace mindspore { | ||||
| #ifdef ENABLE_ANDROID | |||||
| namespace tensor { | namespace tensor { | ||||
| class DETensor; | class DETensor; | ||||
| } // namespace tensor | } // namespace tensor | ||||
| #endif | |||||
| namespace dataset { | namespace dataset { | ||||
| class Tensor; | class Tensor; | ||||
| template <typename T> | template <typename T> | ||||
| @@ -61,7 +64,9 @@ using offset_t = uint32_t; // type of offset va | |||||
| using TensorPtr = std::shared_ptr<Tensor>; | using TensorPtr = std::shared_ptr<Tensor>; | ||||
| class Tensor { | class Tensor { | ||||
| #ifdef ENABLE_ANDROID | |||||
| friend class tensor::DETensor; | friend class tensor::DETensor; | ||||
| #endif | |||||
| public: | public: | ||||
| Tensor() = delete; | Tensor() = delete; | ||||
| Tensor(const Tensor &other) = delete; | Tensor(const Tensor &other) = delete; | ||||
| @@ -38,18 +38,21 @@ | |||||
| #include "minddata/dataset/core/data_type.h" | #include "minddata/dataset/core/data_type.h" | ||||
| #include "minddata/dataset/core/tensor_shape.h" | #include "minddata/dataset/core/tensor_shape.h" | ||||
| #include "minddata/dataset/util/status.h" | #include "minddata/dataset/util/status.h" | ||||
| #include "minddata/dataset/include/de_tensor.h" | |||||
| #ifndef ENABLE_ANDROID | #ifndef ENABLE_ANDROID | ||||
| #include "proto/example.pb.h" | #include "proto/example.pb.h" | ||||
| #else | |||||
| #include "minddata/dataset/include/de_tensor.h" | |||||
| #endif | #endif | ||||
| #ifdef ENABLE_PYTHON | #ifdef ENABLE_PYTHON | ||||
| namespace py = pybind11; | namespace py = pybind11; | ||||
| #endif | #endif | ||||
| namespace mindspore { | namespace mindspore { | ||||
| #ifdef ENABLE_ANDROID | |||||
| namespace tensor { | namespace tensor { | ||||
| class DETensor; | class DETensor; | ||||
| } // namespace tensor | } // namespace tensor | ||||
| #endif | |||||
| namespace dataset { | namespace dataset { | ||||
| class Tensor; | class Tensor; | ||||
| template <typename T> | template <typename T> | ||||
| @@ -61,7 +64,9 @@ using offset_t = uint32_t; // type of offset va | |||||
| using TensorPtr = std::shared_ptr<Tensor>; | using TensorPtr = std::shared_ptr<Tensor>; | ||||
| class Tensor { | class Tensor { | ||||
| #ifdef ENABLE_ANDROID | |||||
| friend class tensor::DETensor; | friend class tensor::DETensor; | ||||
| #endif | |||||
| public: | public: | ||||
| Tensor() = delete; | Tensor() = delete; | ||||
| Tensor(const Tensor &other) = delete; | Tensor(const Tensor &other) = delete; | ||||
| @@ -138,7 +138,6 @@ if (BUILD_MINDDATA) | |||||
| include_directories(${TOP_DIR}/third_party/libjpeg-turbo/include) | include_directories(${TOP_DIR}/third_party/libjpeg-turbo/include) | ||||
| add_compile_definitions(ENABLE_ANDROID) | add_compile_definitions(ENABLE_ANDROID) | ||||
| add_compile_definitions(ENABLE_EAGER) | |||||
| add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/minddata) | add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/minddata) | ||||
| endif() | endif() | ||||