From d7fa4b95b550267b395eb52365e40168057ddead Mon Sep 17 00:00:00 2001 From: MediaPipe Team Date: Tue, 16 May 2023 08:53:33 -0700 Subject: [PATCH] Internal change. PiperOrigin-RevId: 532474319 --- mediapipe/framework/formats/tensor.cc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/mediapipe/framework/formats/tensor.cc b/mediapipe/framework/formats/tensor.cc index 9d75bcbaf..0445712c5 100644 --- a/mediapipe/framework/formats/tensor.cc +++ b/mediapipe/framework/formats/tensor.cc @@ -117,8 +117,8 @@ MtlBufferView MtlBufferView::GetReadView(const Tensor& tensor, << "Tensor must be written prior to read from."; LOG_IF(FATAL, !(tensor.valid_ & (Tensor::kValidCpu | Tensor::kValidMetalBuffer))) - << "Tensor conversion between different GPU resources is not supported " - "yet."; + << "Tensor conversion between different GPU backing formats is not " + "supported yet."; auto lock(absl::make_unique(&tensor.view_mutex_)); tensor.valid_ |= Tensor::kValidMetalBuffer; AllocateMtlBuffer(tensor, [command_buffer device]); @@ -164,8 +164,8 @@ Tensor::OpenGlTexture2dView Tensor::GetOpenGlTexture2dReadView() const { LOG_IF(FATAL, valid_ == kValidNone) << "Tensor must be written prior to read from."; LOG_IF(FATAL, !(valid_ & (kValidCpu | kValidOpenGlTexture2d))) - << "Tensor conversion between different GPU resources is not supported " - "yet."; + << "Tensor conversion between different GPU backing formats is not " + "supported yet."; auto lock = absl::make_unique(&view_mutex_); AllocateOpenGlTexture2d(); if (!(valid_ & kValidOpenGlTexture2d)) { @@ -335,7 +335,8 @@ Tensor::OpenGlBufferView Tensor::GetOpenGlBufferReadView() const { kValidAHardwareBuffer | #endif // MEDIAPIPE_TENSOR_USE_AHWB kValidOpenGlBuffer))) - << "Tensor conversion between different GPU resources is not supported."; + << "Tensor conversion between different GPU backing formats is not " + "supported yet."; auto lock(absl::make_unique(&view_mutex_)); AllocateOpenGlBuffer(); if (!(valid_ & kValidOpenGlBuffer)) {