lordgamez commented on a change in pull request #1096:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1096#discussion_r644964876
##########
File path: extensions/tensorflow/CMakeLists.txt
##########
@@ -26,7 +26,7 @@ find_package(TensorFlow REQUIRED)
message("-- Found TensorFlow: ${TENSORFLOW_INCLUDE_DIRS}")
-include_directories(${TENSORFLOW_INCLUDE_DIRS})
+include_directories(SYSTEM ${TENSORFLOW_INCLUDE_DIRS})
Review comment:
Updated in 0185ef84c7e1855c3f73fecf608e37aa4bf66ef5
##########
File path: extensions/tensorflow/TFApplyGraph.cpp
##########
@@ -194,7 +197,7 @@ int64_t TFApplyGraph::GraphReadCallback::process(const
std::shared_ptr<io::BaseS
auto num_read = stream->read(reinterpret_cast<uint8_t
*>(&graph_proto_buf[0]),
static_cast<int>(stream->size()));
- if (num_read != stream->size()) {
+ if (static_cast<uint64_t>(num_read) != stream->size()) {
Review comment:
Updated in 0185ef84c7e1855c3f73fecf608e37aa4bf66ef5
##########
File path: extensions/tensorflow/TFExtractTopLabels.cpp
##########
@@ -133,8 +136,11 @@ int64_t
TFExtractTopLabels::LabelsReadCallback::process(const std::shared_ptr<io
while (total_read < stream->size()) {
auto read = stream->read(reinterpret_cast<uint8_t *>(&buf[0]),
static_cast<int>(buf_size));
+ if (read < 0) {
Review comment:
Updated in 0185ef84c7e1855c3f73fecf608e37aa4bf66ef5 I'll update it after
the merge
##########
File path: extensions/tensorflow/TFConvertImageToTensor.cpp
##########
@@ -325,7 +325,7 @@ int64_t
TFConvertImageToTensor::ImageReadCallback::process(const std::shared_ptr
auto num_read = stream->read(tensor_->flat<unsigned char>().data(),
static_cast<int>(stream->size()));
- if (num_read != stream->size()) {
+ if (static_cast<uint64_t>(num_read) != stream->size()) {
Review comment:
Thanks! Updated in 7f2abdc0ae7a9f55c07339edc9c9d84de409c4de
##########
File path: extensions/tensorflow/TFApplyGraph.cpp
##########
@@ -221,7 +224,7 @@ int64_t TFApplyGraph::TensorWriteCallback::process(const
std::shared_ptr<io::Bas
auto num_wrote = stream->write(reinterpret_cast<uint8_t
*>(&tensor_proto_buf[0]),
static_cast<int>(tensor_proto_buf.size()));
- if (num_wrote != tensor_proto_buf.size()) {
+ if (static_cast<uint64_t>(num_wrote) != tensor_proto_buf.size()) {
Review comment:
Updated in 7f2abdc0ae7a9f55c07339edc9c9d84de409c4de
##########
File path: extensions/tensorflow/TFExtractTopLabels.cpp
##########
@@ -156,7 +162,7 @@ int64_t
TFExtractTopLabels::TensorReadCallback::process(const std::shared_ptr<io
auto num_read = stream->read(reinterpret_cast<uint8_t
*>(&tensor_proto_buf[0]),
static_cast<int>(stream->size()));
- if (num_read != stream->size()) {
+ if (static_cast<uint64_t>(num_read) != stream->size()) {
Review comment:
Updated in 7f2abdc0ae7a9f55c07339edc9c9d84de409c4de
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]