[go: nahoru, domu]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake Error: could not find requested file BuildFlatBuffers when cmake the lite kernel test #69753

Open
zoghin opened this issue Jun 14, 2024 · 2 comments
Assignees
Labels
comp:lite TF Lite related issues stale This label marks the issue/pr stale - to be closed automatically if no activity stat:awaiting response Status - Awaiting response from author TF 2.16 type:bug Bug

Comments

@zoghin
Copy link
zoghin commented Jun 14, 2024

Issue type

Bug

Have you reproduced the bug with TensorFlow Nightly?

No

Source

source

TensorFlow version

master

Custom code

No

OS platform and distribution

linux Ubuntu 20.0

Mobile device

No response

Python version

No response

Bazel version

No response

GCC/compiler version

cmake

CUDA/cuDNN version

No response

GPU model and memory

yes

Current behavior?

cmake command:
cmake ../tensorflow/lite/ -DTFLITE_KERNEL_TEST=ON -DTFLITE_ENABLE_GPU=ON -DTFLITE_ENABLE_INSTALL=ON

erro info:
-- Found PythonInterp: /usr/bin/python (found version "3.8.2")
CMake Error at kernels/CMakeLists.txt:27 (include):
include could not find requested file:

BuildFlatBuffers

CMake Error at kernels/CMakeLists.txt:53 (build_flatbuffers):
Unknown CMake command "build_flatbuffers".

Standalone code to reproduce the issue

lite/kernels/CMakeLists.txt
 15 message("==== cmake for lit kernel test===")
 16 find_package(googletest REQUIRED)
 17 find_package(nsync REQUIRED)
 18 find_package(re2 REQUIRED)
 19
 20 # Generate the mutable schema_generated.h header for tests.
 21 set(SCHEMA_FILE ${TFLITE_SOURCE_DIR}/schema/schema.fbs)
 22 set(SCHEMA_GENERATED_ROOT ${CMAKE_CURRENT_BINARY_DIR}/schema)
 23 set(SCHEMA_GENERATED_PATH ${SCHEMA_GENERATED_ROOT}/tensorflow/lite/schema/mutable)
 24 set(SCHEMA_GENERATED_FILE ${SCHEMA_GENERATED_PATH}/schema_generated.h)
 25
 26 # Use the util function in flatbuffer to generate the schema header.
 27 include(BuildFlatBuffers)
 28
 29 # For cross-compilation purposes a natively compiled 'flatc' compiler is required
 30 if(${CMAKE_CROSSCOMPILING})
The file BuildFlatBuffers must be include as showed in the line 27, But it couldnot be found!

Relevant log output

-- Found PythonInterp: /usr/bin/python (found version "3.8.2")
CMake Error at kernels/CMakeLists.txt:27 (include):
  include could not find requested file:

    BuildFlatBuffers


CMake Error at kernels/CMakeLists.txt:53 (build_flatbuffers):
  Unknown CMake command "build_flatbuffers".
@sushreebarsa
Copy link
Contributor

@zoghin Could you please make sure that FlatBuffers are installed and available on your system? Kindly ensure the paths to FlatBuffers scripts and modules are correct as well and let us know?
Thank you!

@sushreebarsa sushreebarsa added the stat:awaiting response Status - Awaiting response from author label Jun 19, 2024
Copy link

This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you.

@github-actions github-actions bot added the stale This label marks the issue/pr stale - to be closed automatically if no activity label Jun 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp:lite TF Lite related issues stale This label marks the issue/pr stale - to be closed automatically if no activity stat:awaiting response Status - Awaiting response from author TF 2.16 type:bug Bug
Projects
None yet
Development

No branches or pull requests

2 participants