tensorflow / tensorflow/text

build from source master branch fails

Open
#1,064 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
1.3k
Forks
379
Avg merge
3h 30m
Merged PRs (30d)
8

Description

Compiling the master branch fails with the following errors

./oss_scripts/run_build.sh
platform : Mac M1 (ARM 64)
bazel : 5.3.0

Has anyone build text wheel that would work with Apple M1 max ?

-- Error ---

In file included from tensorflow_text/core/kernels/byte_splitter_kernel.cc:15:
In file included from ./tensorflow_text/core/kernels/byte_splitter_kernel.h:19:
./tensorflow_text/core/kernels/byte_splitter_kernel_template.h:137:37: error: no member named 'FillOutputTensor' in 'tensorflow::text::ByteSplitterWithOffsetsOptflite::shim::Runtime::kTf'
SH_RETURN_IF_ERROR(this->template FillOutputTensor<unsigned char, uint8_t>(
~~~~ ^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/status_macros.h:53:31: note: expanded from macro 'SH_RETURN_IF_ERROR'
::absl::Status status = (VA_ARGS);
^~~~~~~~~~~
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/op_kernel.h:202:45: note: in instantiation of member function 'tensorflow::text::ByteSplitterWithOffsetsOptflite::shim::Runtime::kTf::Invoke' requested here
return static_cast<SubType&>(*this).Invoke(ctx);
^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/tf_op_shim.h:105:59: note: in instantiation of member function 'tflite::shim::OpKernelShim<tensorflow::text::ByteSplitterWithOffsetsOp, tflite::shim::Runtime::kTf>::Invoke' requested here
OP_REQUIRES_OK(c, ::tensorflow::FromAbslStatus(impl
->Invoke(&ctx)));
^
tensorflow_text/core/kernels/byte_splitter_kernel.cc:24:25: note: in instantiation of member function 'tflite::shim::TfOpKerneltensorflow::text::ByteSplitterWithOffsetsOp::Compute' requested here
ByteSplitterWithOffsetsOpKernel);
^
In file included from tensorflow_text/core/kernels/byte_splitter_kernel.cc:15:
In file included from ./tensorflow_text/core/kernels/byte_splitter_kernel.h:19:
./tensorflow_text/core/kernels/byte_splitter_kernel_template.h:139:37: error: no member named 'FillOutputTensor' in 'tensorflow::text::ByteSplitterWithOffsetsOptflite::shim::Runtime::kTf'
SH_RETURN_IF_ERROR(this->template FillOutputTensor<int64_t, int64_t>(
~~~~ ^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/status_macros.h:53:31: note: expanded from macro 'SH_RETURN_IF_ERROR'
::absl::Status _status = (VA_ARGS);
^~~~~~~~~~~
In file included from tensorflow_text/core/kernels/byte_splitter_kernel.cc:15:
In file included from ./tensorflow_text/core/kernels/byte_splitter_kernel.h:19:
./tensorflow_text/core/kernels/byte_splitter_kernel_template.h:141:37: error: no member named 'FillOutputTensor' in 'tensorflow::text::ByteSplitterWithOffsetsOptflite::shim::Runtime::kTf'
SH_RETURN_IF_ERROR(this->template FillOutputTensor<int32_t, int32_t>(
~~~~ ^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/status_macros.h:53:31: note: expanded from macro 'SH_RETURN_IF_ERROR'
::absl::Status _status = (VA_ARGS);
^~~~~~~~~~~
In file included from tensorflow_text/core/kernels/byte_splitter_kernel.cc:15:
In file included from ./tensorflow_text/core/kernels/byte_splitter_kernel.h:19:
./tensorflow_text/core/kernels/byte_splitter_kernel_template.h:143:37: error: no member named 'FillOutputTensor' in 'tensorflow::text::ByteSplitterWithOffsetsOptflite::shim::Runtime::kTf'
SH_RETURN_IF_ERROR(this->template FillOutputTensor<int32_t, int32_t>(
~~~~ ^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/status_macros.h:53:31: note: expanded from macro 'SH_RETURN_IF_ERROR'
::absl::Status _status = (VA_ARGS);
^~~~~~~~~~~
In file included from tensorflow_text/core/kernels/byte_splitter_kernel.cc:15:
In file included from ./tensorflow_text/core/kernels/byte_splitter_kernel.h:19:
./tensorflow_text/core/kernels/byte_splitter_kernel_template.h:305:22: error: no member named 'FillOutputTensor' in 'tensorflow::text::ByteSplitByOffsetsOptflite::shim::Runtime::kTf'
this->template FillOutputTensor<absl::string_view, tensorflow::tstring>(
~~~~ ^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/status_macros.h:53:31: note: expanded from macro 'SH_RETURN_IF_ERROR'
::absl::Status status = (VA_ARGS);
^~~~~~~~~~~
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/op_kernel.h:202:45: note: in instantiation of member function 'tensorflow::text::ByteSplitByOffsetsOptflite::shim::Runtime::kTf::Invoke' requested here
return static_cast<SubType&>(*this).Invoke(ctx);
^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/tf_op_shim.h:105:59: note: in instantiation of member function 'tflite::shim::OpKernelShim<tensorflow::text::ByteSplitByOffsetsOp, tflite::shim::Runtime::kTf>::Invoke' requested here
OP_REQUIRES_OK(c, ::tensorflow::FromAbslStatus(impl
->Invoke(&ctx)));
^
tensorflow_text/core/kernels/byte_splitter_kernel.cc:28:25: note: in instantiation of member function 'tflite::shim::TfOpKerneltensorflow::text::ByteSplitByOffsetsOp::Compute' requested here
ByteSplitByOffsetsOpKernel);
^
In file included from tensorflow_text/core/kernels/byte_splitter_kernel.cc:15:
In file included from ./tensorflow_text/core/kernels/byte_splitter_kernel.h:19:
./tensorflow_text/core/kernels/byte_splitter_kernel_template.h:307:37: error: no member named 'FillOutputTensor' in 'tensorflow::text::ByteSplitByOffsetsOptflite::shim::Runtime::kTf'
SH_RETURN_IF_ERROR(this->template FillOutputTensor<int32_t, int64_t>(
~~~~ ^
bazel-out/darwin_arm64-opt/bin/external/local_config_tf/include/tensorflow/lite/kernels/shim/status_macros.h:53:31: note: expanded from macro 'SH_RETURN_IF_ERROR'
::absl::Status _status = (VA_ARGS);
^~~~~~~~~~~
6 errors generated.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the failure on the reported Mac M1 setup by running oss_scripts/run_build.sh with Bazel 5.3.0. Then inspect tensorflow_text/core/kernels/byte_splitter_kernel_template.h and the referenced TensorFlow Lite shim headers to determine why FillOutputTensor is unavailable. Done means the master branch builds successfully and the requested Apple M1 wheel can be produced.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.