반응형



Ubuntu 18.04에 MediaPipe를 설치하여 간단한 예제를 실행시켜 보는 과정을 다루고 있습니다. 



MediaPipe가 무엇인지 궁금하시면 다음 두  링크를 방문해보세요..


https://github.com/google/mediapipe


https://mediapipe.readthedocs.io/en/latest/ 



다음과 같은 것들을 할 수 있다고 합니다. . 이제 겨우 설치를 해봐서 이후 단계는 물어보셔도 아직 모릅니다 ^^;

Android, PC, Google Coral, Web을 위한 예제가 준비되어 있습니다.



Face Detection 

Multi-hand Tracking

Hand Tracking 

Hair Segmentation 

Object Detection

Object Detection and Tracking

Objectron: 3D Object Detection and Tracking

AutoFlip




최초작성 2020. 3. 29

              2020. 4. 2    hand tracking 예제 실행방법 추가 

              2020. 5. 8    bazel 2.0으로 변경된 점 반영





0. 진행하기전에 우분투의 패키지를 업그레이드 해주었습니다. 

꼭 해줘야 하는 작업은 아닌듯하지만 저는 습관적으로 해주는 편입니다. 


webnautes@webnautes-PC:~$ sudo apt-get update

webnautes@webnautes-PC:~$ sudo apt-get upgrade




1. 깃허브에서 MediaPipe를 다운로드합니다. 현재 디렉토리는  홈 디렉토리입니다.


webnautes@webnautes-PC:~$ pwd

/home/webnautes



webnautes@webnautes-PC:~$ git clone https://github.com/google/mediapipe.git




2. Bazel을 설치합니다. 2.x 버전은 아직 지원하지 않기 때문에  1.0.0 ~ 1.2.1 사이의 버전을 설치해야 한다고 합니다. 

   2.0 이상의 버전을 설치하는 것으로 변경되었습니다.  


2-1. 우선 C++ 컴파일러와  unzip, zip를 설치합니다. 이미 설치가 되있을 수도 있습니다. 

webnautes@webnautes-PC:~$ sudo apt install g++ unzip zip




2-2. jdk를 설치합니다. 

Ubuntu 16.04라면 OpenJDK 8을 설치하고 Ubuntu 18.04라면 OpenJDK 11을 설치합니다. 


sudo apt-get install openjdk-8-jdk

sudo apt-get install openjdk-11-jdk



Ubuntu 18.04를 사용중이라 OpenJDK 11을 설치했습니다. 

webnautes@webnautes-PC:~$ sudo apt-get install openjdk-11-jdk




2-3. https://github.com/bazelbuild/bazel/releases  에서 bazel 2.0 설치 파일을 다운로드 받아 설치를 진행합니다.


webnautes@webnautes-PC:~$ wget https://github.com/bazelbuild/bazel/releases/download/2.0.0/bazel-2.0.0-installer-linux-x86_64.sh


webnautes@webnautes-PC:~$ chmod +x bazel-2.0.0-installer-linux-x86_64.sh


webnautes@webnautes-PC:~$ ./bazel-2.0.0-installer-linux-x86_64.sh --user




2-4. ~/.bashrc 파일 끝에 다음처럼 경로를 추가해줍니다. 

export PATH="$PATH:$HOME/bin"


편집기를 열어 경로를 추가하고 환경에 반영해줍니다. 

webnautes@webnautes-PC:~$ nano ~/.bashrc 

webnautes@webnautes-PC:~$ source ~/.bashrc




3-1.  다음 포스트를 참고하여 OpenCV를 설치합니다.


Ubuntu 18.04에 OpenCV 4.2.0 설치하는 방법

https://webnautes.tistory.com/1186 




3-2. 깃허브에서 다운로드 받았던 mediapipe 디렉토리로 이동하여 


webnautes@webnautes-PC:~$ cd mediapipe


webnautes@webnautes-PC:~/mediapipe$ pwd

/home/webnautes/mediapipe




WORKSPACE 파일에서 다음 부분을 찾아 수정합니다.


수정전

new_local_repository(

    name = "linux_opencv",

    build_file = "@//third_party:opencv_linux.BUILD",

    path = "/usr",

)



수정후

new_local_repository(

    name = "linux_opencv",

    build_file = "@//third_party:opencv_linux.BUILD",

    path = "/usr/local",

)




opencv_linux.BUILD 파일을 수정합니다. 

현재 디렉토리를 기준으로 다음 위치에 있습니다.


webnautes@webnautes-PC:~/mediapipe$ find . | grep opencv_linux.BUILD

./third_party/opencv_linux.BUILD



수정전

cc_library(

    name = "opencv",

    srcs = glob(

        [

            "lib/x86_64-linux-gnu/libopencv_core.so",

            "lib/x86_64-linux-gnu/libopencv_calib3d.so",

            "lib/x86_64-linux-gnu/libopencv_features2d.so",

            "lib/x86_64-linux-gnu/libopencv_highgui.so",

            "lib/x86_64-linux-gnu/libopencv_imgcodecs.so",

            "lib/x86_64-linux-gnu/libopencv_imgproc.so",

            "lib/x86_64-linux-gnu/libopencv_video.so",

            "lib/x86_64-linux-gnu/libopencv_videoio.so",

        ],

    ),

    hdrs = glob(["include/opencv2/**/*.h*"]),

    includes = ["include"],



수정후


cc_library(

    name = "opencv",

    srcs = glob(

        [

            "lib/libopencv_core.so",

            "lib/libopencv_highgui.so",

            "lib/libopencv_imgcodecs.so",

            "lib/libopencv_imgproc.so",

            "lib/libopencv_video.so",

            "lib/libopencv_videoio.so",

        ],

    ),

    hdrs = glob(["include/opencv4/**/*.h*"]),

    includes = ["include/opencv4/"],





4. GPU 가속 관련 옵션 변경은 다음 링크의 4번을 참고하세요.

https://mediapipe.readthedocs.io/en/latest/install.html#installing-on-debian-and-ubuntu


테스트할 수 없어서 skip 합니다.




5. Hello World 예제를 실행시켜 봅니다. 


webnautes@webnautes-PC:~/mediapipe$ export GLOG_logtostderr=1



GPU를 사용할수 없어 CPU만 사용해보았습니다.

webnautes@webnautes-PC:~/mediapipe$ bazel run --define MEDIAPIPE_DISABLE_GPU=1 mediapipe/examples/desktop/hello_world:hello_world



GPU를 사용하려면 다음 링크의 5번을 참고하세요. 

https://mediapipe.readthedocs.io/en/latest/install.html#installing-on-debian-and-ubuntu



잠시 기다리면 다음과 같은 결과를 볼 수 있습니다. 

처음 실행시에만 다운로드 및 빌드(?) 작업을 해서 시간이 걸리고 그 다음부턴 바로 실행이 됩니다. 


INFO: Elapsed time: 244.546s, Critical Path: 145.35s

INFO: 452 processes: 452 linux-sandbox.

INFO: Build completed successfully, 457 total actions

INFO: Running command line: bazel-bin/mediapipe/examples/desktop/hello_world/helINFO: Build completed successfully, 457 total actions

I0508 21:58:08.414064 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414254 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414331 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414403 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414474 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414834 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414916 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414929 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414942 15028 hello_world.cc:56] Hello World!

I0508 21:58:08.414957 15028 hello_world.cc:56] Hello World!






6. 핸드 트래킹 예제를 컴파일하여 실행시켜봅니다. 


webnautes@webnautes-PC:~$ cd mediapipe/


webnautes@webnautes-PC:~/mediapipe$ pwd

/home/webnautes/mediapipe


webnautes@webnautes-PC:~/mediapipe$ bazel build -c opt --define MEDIAPIPE_DISABLE_GPU=1 mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu


webnautes@webnautes-PC:~/mediapipe$ GLOG_logtostderr=1 bazel-bin/mediapipe/examples/desktop/hand_tracking/hand_tracking_cpu --calculator_graph_config_file=mediapipe/graphs/hand_tracking/hand_tracking_desktop_live.pbtxt



조명이 어두운 편인데도 손이 잘 인식이 되네요.

이제 어떤 방식으로 MediaPipe를 사용하는지 살펴봐야 겠습니다. 







참고

https://mediapipe.readthedocs.io/en/latest/install.html#installing-on-debian-and-ubuntu 

https://docs.bazel.build/versions/master/install-ubuntu.html 

https://mediapipe.readthedocs.io/en/latest/hand_tracking_desktop.html




반응형

'Machine Learning & Deep Learning > MediaPipe' 카테고리의 다른 글

MediaPipe를 Ubuntu에 설치하는 방법  (19) 2020.03.29

포스트 작성시에는 문제 없었지만 이후 문제가 생길 수 있습니다.
댓글로 알려주시면 빠른 시일내에 답변을 드리겠습니다.

여러분의 응원으로 좋은 컨텐츠가 만들어집니다.
지금 본 내용이 도움이 되었다면 유튜브 구독 부탁드립니다. 감사합니다 : )

유튜브 구독하기


제가 쓴 책도 한번 검토해보세요.

  1. brothersoo 2020.04.16 17:50

    안녕하세요, 좋은 글 감사드립니다.

    차근차근 한단계씩 따라해 보았는데 마지막 hand tracking 예제를 실행하는 단계에서 문제가 생겼습니다.

    webnautes@webnautes-PC:~/mediapipe$ GLOG_logtostderr=1 bazel-bin/mediapipe/examples/desktop/hand_tracking/hand_tracking_cpu --calculator_graph_config_file=mediapipe/graphs/hand_tracking/hand_tracking_desktop_live.pbtxt

    위 코드를 실행시켰을 때 마지막에

    I0416 17:26:34.940616 15692 demo_run_graph_main.cc:53] Initialize the calculator graph.
    I0416 17:26:34.948133 15692 demo_run_graph_main.cc:57] Initialize the camera or load the video.
    [ WARN:0] global /home/brothersoo/opencv/opencv-4.2.0/modules/videoio/src/cap_gstreamer.cpp (480) isPipelinePlaying OpenCV | GStreamer warning: GStreamer: pipeline have not been created
    [ WARN:0] global /home/brothersoo/opencv/opencv-4.2.0/modules/videoio/src/cap_v4l.cpp (887) open VIDEOIO(V4L2:/dev/video0): can't open camera by index
    E0416 17:26:34.963476 15692 demo_run_graph_main.cc:146] Failed to run the graph: ; capture.isOpened()(mediapipe/examples/desktop/demo_run_graph_main.cc:65)

    이러한 코드가 뜨면서 실패를 하네요.
    검색을 해보니 이런저런 버전 차이때문에 그런거라는데 정확히 왜 그런지는 잘 모르겠습니다.

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.04.16 18:02 신고

      웹캠을 연결하고 하셨나요?

    • brothersoo 2020.04.16 18:31

      넵 웹캠이 있는 노트북으로 테스트 해보았고 웹캠을 따로 실행시에는 잘 작동했습니다. 다른 파이썬 예제를 테스트할 때에는 웹캠이 잘 작동했었습니다.

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.04.16 18:38 신고

      에러상으론 카메라를 열지 못한다네요.

  2. pooso95 2020.05.01 21:16

    안녕하세요. 이해하기 쉽게 글을 써 주셔서 천천히 따라하기 좋았습니다.

    마지막에 hello_world를 실행시키는데 오류가 발생했는데
    무슨 오류인지 정확한 원인을 잘 모르겠습니다ㅜㅜ

    조언을 구할 수 있을까요?

    <오류코드>
    ERROR: /home/user1/mediapipe/mediapipe/framework/deps/BUILD:194:1: C++ compilation of rule '//mediapipe/framework/deps:registration_token' failed (Exit 1) gcc failed: error executing command /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer '-std=c++0x' -MD -MF ... (remaining 25 argument(s) skipped)

    Use --sandbox_debug to see verbose messages from the sandbox
    gcc: error: unrecognized command line option '-std=c++14'
    Target //mediapipe/examples/desktop/hello_world:hello_world failed to build
    Use --verbose_failures to see the command lines of failed build steps.
    INFO: Elapsed time: 0.283s, Critical Path: 0.06s
    INFO: 0 processes.
    FAILED: Build did NOT complete successfully
    FAILED: Build did NOT complete successfully

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.05.01 21:23 신고

      사용하는 리눅스에 설치된 g++ 컴파일러가 c++14를 지원하지 못해서 발생한 에러로 보입니다. 전 우분투 18.04에서 테스트를 진행했습니다.

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.05.01 23:34 신고

      bazel clean하고 다시해보세요

  3. wizwiz 2020.05.07 16:17

    안녕하세요, 좋은 글 감사드립니다.
    따라 하다가 hello_world 예제 실행 부분에서 오류가 발생하였습니다 ㅠㅠ
    혹시 가능 하시다면 도움 부탁드립니다 ㅠ

    bazel run --define MEDIAPIPE_DISABLE_GPU=1 mediapipe/examples/desktop/hello_world:hello_world

    Starting local Bazel server and connecting to it...
    INFO: Options provided by the client:
    Inherited 'common' options: --isatty=1 --terminal_columns=80
    INFO: Reading rc options for 'run' from /home/wizner/mediapipe/.bazelrc:
    Inherited 'build' options: --jobs 128 --define=absl=1 --cxxopt=-std=c++14 --copt=-Wno-sign-compare --copt=-Wno-unused-function --copt=-Wno-uninitialized --copt=-Wno-unused-result --copt=-Wno-comment --copt=-Wno-return-type --copt=-Wno-unused-local-typedefs --copt=-Wno-ignored-attributes --experimental_repo_remote_exec --apple_platform_type=macos --apple_generate_dsym
    ERROR: Unrecognized option: --experimental_repo_remote_exec

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.05.07 21:11 신고

      혹시 bazel 1.2.1를 설치했나요.

    • wizwiz 2020.05.08 10:12

      네 써져있는대로 설치 하였습니다

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.05.08 18:55 신고

      확인해보니 bazel 2.0을 설치하도록 변경되었네요. 버전만 바꾸면 해결될 듯합니다.

  4. Kuha 2020.05.20 18:10

    Hello World 까지는 잘되었는데
    손트래킹을 빌드할때

    ERROR: /home/kds/mediapipe/mediapipe/examples/desktop/hand_tracking/BUILD:27:1: Linking of rule '//mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu' failed (Exit 1) gcc failed: error executing command /usr/bin/gcc @bazel-out/k8-opt/bin/mediapipe/examples/desktop/hand_tracking/hand_tracking_cpu-2.params

    와 같은 에러를 내뿜내요... 혹시 어떤것때문인지 도움을 주셨으면 합니다!

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.05.20 20:24 신고

      에러 내용이 안보입니다. 확인후 다시 올려주세요

    • Kuha 2020.05.20 21:19

      잘못올렸네요 다시 올립니다!

      kds@kds-VirtualBox:~/mediapipe$ bazel build -c opt --define MEDIAPIPE_DISABLE_GPU=1 mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu
      INFO: Analyzed target //mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu (0 packages loaded, 0 targets configured).
      INFO: Found 1 target...
      ERROR: /home/kds/mediapipe/mediapipe/examples/desktop/hand_tracking/BUILD:27:1: Linking of rule '//mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu' failed (Exit 1) gcc failed: error executing command /usr/bin/gcc @bazel-out/k8-opt/bin/mediapipe/examples/desktop/hand_tracking/hand_tracking_cpu-2.params

      Use --sandbox_debug to see verbose messages from the sandbox
      bazel-out/k8-opt/bin/mediapipe/examples/desktop/_objs/demo_run_graph_main/demo_run_graph_main.o:demo_run_graph_main.cc:function RunMPPGraph(): error: undefined reference to 'cv::namedWindow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
      bazel-out/k8-opt/bin/mediapipe/examples/desktop/_objs/demo_run_graph_main/demo_run_graph_main.o:demo_run_graph_main.cc:function RunMPPGraph(): error: undefined reference to 'cv::VideoCapture::open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
      bazel-out/k8-opt/bin/mediapipe/examples/desktop/_objs/demo_run_graph_main/demo_run_graph_main.o:demo_run_graph_main.cc:function RunMPPGraph(): error: undefined reference to 'cv::VideoWriter::open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int, double, cv::Size_<int>, bool)'
      bazel-out/k8-opt/bin/mediapipe/examples/desktop/_objs/demo_run_graph_main/demo_run_graph_main.o:demo_run_graph_main.cc:function RunMPPGraph(): error: undefined reference to 'cv::VideoWriter::write(cv::_InputArray const&)'
      bazel-out/k8-opt/bin/mediapipe/examples/desktop/_objs/demo_run_graph_main/demo_run_graph_main.o:demo_run_graph_main.cc:function RunMPPGraph(): error: undefined reference to 'cv::imshow(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::_InputArray const&)'
      bazel-out/k8-opt/bin/mediapipe/calculators/video/_objs/opencv_video_decoder_calculator/opencv_video_decoder_calculator.o:opencv_video_decoder_calculator.cc:function mediapipe::OpenCvVideoDecoderCalculator::Open(mediapipe::CalculatorContext*): error: undefined reference to 'cv::VideoCapture::VideoCapture(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int)'
      bazel-out/k8-opt/bin/mediapipe/calculators/video/_objs/opencv_video_encoder_calculator/opencv_video_encoder_calculator.o:opencv_video_encoder_calculator.cc:function mediapipe::OpenCvVideoEncoderCalculator::SetUpVideoWriter(float, int, int): error: undefined reference to 'cv::VideoWriter::VideoWriter(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int, double, cv::Size_<int>, bool)'
      bazel-out/k8-opt/bin/mediapipe/calculators/image/_objs/image_cropping_calculator/image_cropping_calculator.o:image_cropping_calculator.cc:function mediapipe::ImageCroppingCalculator::RenderCpu(mediapipe::CalculatorContext*): error: undefined reference to 'cv::getPerspectiveTransform(cv::_InputArray const&, cv::_InputArray const&, int)'
      bazel-out/k8-opt/bin/mediapipe/calculators/image/_objs/image_transformation_calculator/image_transformation_calculator.o:image_transformation_calculator.cc:function mediapipe::ImageTransformationCalculator::RenderCpu(mediapipe::CalculatorContext*): error: undefined reference to 'cv::getRotationMatrix2D_(cv::Point_<float>, double, double)'
      bazel-out/k8-opt/bin/mediapipe/util/_objs/annotation_renderer/annotation_renderer.o:annotation_renderer.cc:function mediapipe::AnnotationRenderer::DrawRectangle(mediapipe::RenderAnnotation const&): error: undefined reference to 'cv::rectangle(cv::_InputOutputArray const&, cv::Rect_<int>, cv::Scalar_<double> const&, int, int, int)'
      bazel-out/k8-opt/bin/mediapipe/util/_objs/annotation_renderer/annotation_renderer.o:annotation_renderer.cc:function mediapipe::AnnotationRenderer::DrawFilledRectangle(mediapipe::RenderAnnotation const&): error: undefined reference to 'cv::fillConvexPoly(cv::_InputOutputArray const&, cv::Point_<int> const*, int, cv::Scalar_<double> const&, int, int)'
      bazel-out/k8-opt/bin/mediapipe/util/_objs/annotation_renderer/annotation_renderer.o:annotation_renderer.cc:function mediapipe::AnnotationRenderer::DrawFilledRectangle(mediapipe::RenderAnnotation const&): error: undefined reference to 'cv::rectangle(cv::_InputOutputArray const&, cv::Rect_<int>, cv::Scalar_<double> const&, int, int, int)'
      bazel-out/k8-opt/bin/mediapipe/util/_objs/annotation_renderer/annotation_renderer.o:annotation_renderer.cc:function mediapipe::AnnotationRenderer::DrawGradientLine(mediapipe::RenderAnnotation const&): error: undefined reference to 'cv::rectangle(cv::_InputOutputArray const&, cv::Rect_<int>, cv::Scalar_<double> const&, int, int, int)'
      bazel-out/k8-opt/bin/mediapipe/util/_objs/annotation_renderer/annotation_renderer.o:annotation_renderer.cc:function mediapipe::AnnotationRenderer::DrawText(mediapipe::RenderAnnotation const&): error: undefined reference to 'cv::putText(cv::_InputOutputArray const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::Point_<int>, int, double, cv::Scalar_<double>, int, int, bool)'
      collect2: error: ld returned 1 exit status
      Target //mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu failed to build
      Use --verbose_failures to see the command lines of failed build steps.
      INFO: Elapsed time: 1.213s, Critical Path: 0.64s
      INFO: 0 processes.
      FAILED: Build did NOT complete successfully

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.05.20 22:56 신고

      opencv를 설치했나요? 못찾는 에러가 났네요

    • Kuha 2020.05.21 00:24

      네 페이스디텍트 예제는 작동하는걸 확인했습니다.

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.05.21 00:32 신고

      포스트한대로 따라하면 동작해야 하는데 이상하군요.. opencv 라이브러리를 못찾는 에러가 났습니다.

      find . | grep libopencv로 라이브러리 위치를 찾은후 다음처럼 라이브러리 경로를 설정해서 다시 해보세요

      export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/your/custom/path/

  5. wonjongbot 2020.06.26 16:11

    안녕하세요, hello 예제를 열면 에러가 나오네요. 무엇이 문제일까요? 감사합니다!
    /works/mediapipe/mediapipe$ bazel run --define MEDIAPIPE_DISABLE_GPU=1 mediapipe/examples/desktop/hello_world:hello_world
    INFO: Call stack for the definition of repository 'local_execution_config_python' which is a local_python_configure (rule definition at /home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/py/python_configure.bzl:275:26):
    - /home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/toolchains/remote_config/rbe_config.bzl:158:5
    - /home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/toolchains/remote_config/configs.bzl:6:5
    - /home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/tensorflow/workspace.bzl:93:5
    - /home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/tensorflow/workspace.bzl:77:5
    - /works/mediapipe/mediapipe/WORKSPACE:337:1
    ERROR: An error occurred during the fetch of repository 'local_execution_config_python':
    Traceback (most recent call last):
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/py/python_configure.bzl", line 208
    get_python_bin(repository_ctx)
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 44, in get_python_bin
    which(repository_ctx, "python")
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 29, in which
    execute(repository_ctx, <1 more arguments>)
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 208, in execute
    fail(<1 more arguments>)
    Repository command failed

    INFO: Call stack for the definition of repository 'rules_java' which is a http_archive (rule definition at /home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/bazel_tools/tools/build_defs/repo/http.bzl:292:16):
    - /home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/bazel_tools/tools/build_defs/repo/utils.bzl:205:9
    - /DEFAULT.WORKSPACE.SUFFIX:290:1
    ERROR: While resolving toolchains for target //mediapipe/examples/desktop/hello_world:hello_world: invalid registered toolchain '@local_execution_config_python//:py_toolchain': no such package '@local_execution_config_python//': Traceback (most recent call last):
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/py/python_configure.bzl", line 208
    get_python_bin(repository_ctx)
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 44, in get_python_bin
    which(repository_ctx, "python")
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 29, in which
    execute(repository_ctx, <1 more arguments>)
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 208, in execute
    fail(<1 more arguments>)
    Repository command failed

    ERROR: Analysis of target '//mediapipe/examples/desktop/hello_world:hello_world' failed; build aborted: invalid registered toolchain '@local_execution_config_python//:py_toolchain': no such package '@local_execution_config_python//': Traceback (most recent call last):
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/py/python_configure.bzl", line 208
    get_python_bin(repository_ctx)
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 44, in get_python_bin
    which(repository_ctx, "python")
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 29, in which
    execute(repository_ctx, <1 more arguments>)
    File "/home/frontis/.cache/bazel/_bazel_frontis/dc9843482fbedda2bc26c0230f8ac174/external/org_tensorflow/third_party/remote_config/common.bzl", line 208, in execute
    fail(<1 more arguments>)
    Repository command failed

    INFO: Elapsed time: 0.350s
    INFO: 0 processes.
    FAILED: Build did NOT complete successfully (10 packages loaded, 11 targets configured)
    FAILED: Build did NOT complete successfully (10 packages loaded, 11 targets configured)
    currently loading: @bazel_tools//tools/jdk

    • Favicon of https://webnautes.tistory.com BlogIcon webnautes 2020.06.26 21:53 신고

      버전업 되면서 바뀐점이 또 발생한 듯합니다.

      아래 링크를 참고하여 진행해보세요

      https://google.github.io/mediapipe/getting_started/install.html

+ Recent posts